Merge pull request #271 from pruiz/xamarin-bug-4108
authorMiguel de Icaza <miguel@gnome.org>
Fri, 25 May 2012 00:11:23 +0000 (17:11 -0700)
committerMiguel de Icaza <miguel@gnome.org>
Fri, 25 May 2012 00:11:23 +0000 (17:11 -0700)
Fix for Xamarin's bug #4108 (BrowserCaps compatibility problem with MS.NET)

1711 files changed:
.gitmodules [new file with mode: 0644]
LICENSE
Makefile.am
README
configure.in
data/Makefile.am
data/aspnetwebstack.pc.in [new file with mode: 0644]
data/system.web.mvc3.pc.in [new file with mode: 0644]
eglib/src/gpath.c
eglib/src/gstr.c
eglib/src/gunicode.c
eglib/test/path.c
eglib/test/string-util.c
external/Newtonsoft.Json [new submodule]
external/aspnetwebstack [new submodule]
external/cecil [new submodule]
libgc/darwin_stop_world.c
libgc/include/gc.h
libgc/include/private/pthread_support.h
libgc/pthread_stop_world.c
libgc/pthread_support.c
libgc/solaris_threads.c
libgc/win32_threads.c
man/mono.1
mcs/.gitignore
mcs/build/executable.make
mcs/build/rules.make
mcs/build/tests.make
mcs/class/Accessibility/Accessibility-net_2_0.csproj
mcs/class/Accessibility/Accessibility-net_4_0.csproj
mcs/class/Accessibility/Accessibility-net_4_5.csproj
mcs/class/Commons.Xml.Relaxng/Commons.Xml.Relaxng-net_2_0.csproj
mcs/class/Commons.Xml.Relaxng/Commons.Xml.Relaxng-net_4_0.csproj
mcs/class/Commons.Xml.Relaxng/Commons.Xml.Relaxng-net_4_5.csproj
mcs/class/Commons.Xml.Relaxng/Commons.Xml.Relaxng-tests-net_2_0.csproj
mcs/class/Commons.Xml.Relaxng/Commons.Xml.Relaxng-tests-net_4_0.csproj
mcs/class/Commons.Xml.Relaxng/Commons.Xml.Relaxng-tests-net_4_5.csproj
mcs/class/Compat.ICSharpCode.SharpZipLib/Compat.ICSharpCode.SharpZipLib-net_2_0.csproj
mcs/class/Cscompmgd/Cscompmgd-net_2_0.csproj
mcs/class/Cscompmgd/Cscompmgd-net_4_0.csproj
mcs/class/Cscompmgd/Cscompmgd-net_4_5.csproj
mcs/class/Cscompmgd/Cscompmgd-tests-net_2_0.csproj
mcs/class/Cscompmgd/Cscompmgd-tests-net_4_0.csproj
mcs/class/Cscompmgd/Cscompmgd-tests-net_4_5.csproj
mcs/class/CustomMarshalers/CustomMarshalers-net_2_0.csproj
mcs/class/CustomMarshalers/CustomMarshalers-net_4_0.csproj
mcs/class/CustomMarshalers/CustomMarshalers-net_4_5.csproj
mcs/class/I18N/CJK/I18N.CJK-net_2_0.csproj
mcs/class/I18N/CJK/I18N.CJK-net_4_0.csproj
mcs/class/I18N/CJK/I18N.CJK-net_4_5.csproj
mcs/class/I18N/CJK/I18N.CJK-tests-net_2_0.csproj
mcs/class/I18N/CJK/I18N.CJK-tests-net_4_0.csproj
mcs/class/I18N/CJK/I18N.CJK-tests-net_4_5.csproj
mcs/class/I18N/Common/I18N-net_2_0.csproj
mcs/class/I18N/Common/I18N-net_4_0.csproj
mcs/class/I18N/Common/I18N-net_4_5.csproj
mcs/class/I18N/MidEast/I18N.MidEast-net_2_0.csproj
mcs/class/I18N/MidEast/I18N.MidEast-net_4_0.csproj
mcs/class/I18N/MidEast/I18N.MidEast-net_4_5.csproj
mcs/class/I18N/Other/I18N.Other-net_2_0.csproj
mcs/class/I18N/Other/I18N.Other-net_4_0.csproj
mcs/class/I18N/Other/I18N.Other-net_4_5.csproj
mcs/class/I18N/Rare/I18N.Rare-net_2_0.csproj
mcs/class/I18N/Rare/I18N.Rare-net_4_0.csproj
mcs/class/I18N/Rare/I18N.Rare-net_4_5.csproj
mcs/class/I18N/West/I18N.West-net_2_0.csproj
mcs/class/I18N/West/I18N.West-net_4_0.csproj
mcs/class/I18N/West/I18N.West-net_4_5.csproj
mcs/class/I18N/West/I18N.West-tests-net_2_0.csproj
mcs/class/I18N/West/I18N.West-tests-net_4_0.csproj
mcs/class/I18N/West/I18N.West-tests-net_4_5.csproj
mcs/class/IBM.Data.DB2/IBM.Data.DB2-net_2_0.csproj
mcs/class/IBM.Data.DB2/IBM.Data.DB2-net_4_0.csproj
mcs/class/IBM.Data.DB2/IBM.Data.DB2-net_4_5.csproj
mcs/class/ICSharpCode.SharpZipLib/ICSharpCode.SharpZipLib-net_2_0.csproj
mcs/class/ICSharpCode.SharpZipLib/ICSharpCode.SharpZipLib-net_4_0.csproj
mcs/class/ICSharpCode.SharpZipLib/ICSharpCode.SharpZipLib-net_4_5.csproj
mcs/class/IKVM.Reflection/Assembly.cs
mcs/class/IKVM.Reflection/Binder.cs
mcs/class/IKVM.Reflection/ConstructorInfo.cs
mcs/class/IKVM.Reflection/CustomAttributeData.cs
mcs/class/IKVM.Reflection/Emit/AssemblyBuilder.cs
mcs/class/IKVM.Reflection/Emit/EventBuilder.cs
mcs/class/IKVM.Reflection/Emit/MethodBuilder.cs
mcs/class/IKVM.Reflection/Emit/ModuleBuilder.cs
mcs/class/IKVM.Reflection/Emit/ParameterBuilder.cs
mcs/class/IKVM.Reflection/Emit/PropertyBuilder.cs
mcs/class/IKVM.Reflection/Enums.cs
mcs/class/IKVM.Reflection/EventInfo.cs
mcs/class/IKVM.Reflection/FieldInfo.cs
mcs/class/IKVM.Reflection/GenericWrappers.cs
mcs/class/IKVM.Reflection/MarshalSpec.cs
mcs/class/IKVM.Reflection/MemberInfo.cs
mcs/class/IKVM.Reflection/Metadata/Tables.cs
mcs/class/IKVM.Reflection/MethodBase.cs
mcs/class/IKVM.Reflection/MethodInfo.cs
mcs/class/IKVM.Reflection/MethodSignature.cs
mcs/class/IKVM.Reflection/Missing.cs
mcs/class/IKVM.Reflection/Module.cs
mcs/class/IKVM.Reflection/ParameterInfo.cs
mcs/class/IKVM.Reflection/PropertyInfo.cs
mcs/class/IKVM.Reflection/PropertySignature.cs
mcs/class/IKVM.Reflection/Reader/AssemblyReader.cs
mcs/class/IKVM.Reflection/Reader/EventInfoImpl.cs
mcs/class/IKVM.Reflection/Reader/GenericTypeParameter.cs
mcs/class/IKVM.Reflection/Reader/ModuleReader.cs
mcs/class/IKVM.Reflection/Reader/PEReader.cs
mcs/class/IKVM.Reflection/Reader/PropertyInfoImpl.cs
mcs/class/IKVM.Reflection/Reader/ResourceModule.cs
mcs/class/IKVM.Reflection/Type.cs
mcs/class/IKVM.Reflection/TypeNameParser.cs
mcs/class/IKVM.Reflection/Universe.cs
mcs/class/IKVM.Reflection/Writer/ModuleWriter.cs
mcs/class/IKVM.Reflection/Writer/PEWriter.cs
mcs/class/IKVM.Reflection/Writer/ResourceSection.cs
mcs/class/Makefile
mcs/class/Managed.Windows.Forms/Makefile
mcs/class/Managed.Windows.Forms/System.Windows.Forms-net_2_0.csproj
mcs/class/Managed.Windows.Forms/System.Windows.Forms-net_4_0.csproj
mcs/class/Managed.Windows.Forms/System.Windows.Forms-net_4_5.csproj
mcs/class/Managed.Windows.Forms/System.Windows.Forms-tests-net_2_0.csproj
mcs/class/Managed.Windows.Forms/System.Windows.Forms-tests-net_4_0.csproj
mcs/class/Managed.Windows.Forms/System.Windows.Forms-tests-net_4_5.csproj
mcs/class/Managed.Windows.Forms/System.Windows.Forms/Clipboard.cs
mcs/class/Managed.Windows.Forms/System.Windows.Forms/ListBox.cs
mcs/class/Managed.Windows.Forms/System.Windows.Forms/Theme.cs
mcs/class/Managed.Windows.Forms/System.Windows.Forms/ThemeWin32Classic.cs
mcs/class/Managed.Windows.Forms/System.Windows.Forms/TreeNodeCollection.cs
mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUI.cs
mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUICarbon.cs
mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUIDriver.cs
mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUIWin32.cs
mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUIX11.cs
mcs/class/Managed.Windows.Forms/Test/System.Windows.Forms/ClipboardTest.cs
mcs/class/Managed.Windows.Forms/Test/System.Windows.Forms/ListBoxTest.cs
mcs/class/Microsoft.Build.Engine/Makefile
mcs/class/Microsoft.Build.Engine/Microsoft.Build.BuildEngine/Import.cs
mcs/class/Microsoft.Build.Engine/Microsoft.Build.BuildEngine/Project.cs
mcs/class/Microsoft.Build.Engine/Microsoft.Build.Engine-net_2_0.csproj
mcs/class/Microsoft.Build.Engine/Microsoft.Build.Engine-net_3_5.csproj
mcs/class/Microsoft.Build.Engine/Microsoft.Build.Engine-net_4_0.csproj
mcs/class/Microsoft.Build.Engine/Microsoft.Build.Engine-net_4_5.csproj
mcs/class/Microsoft.Build.Engine/Microsoft.Build.Engine-tests-net_2_0.csproj
mcs/class/Microsoft.Build.Engine/Microsoft.Build.Engine-tests-net_3_5.csproj
mcs/class/Microsoft.Build.Engine/Microsoft.Build.Engine-tests-net_4_0.csproj
mcs/class/Microsoft.Build.Engine/Microsoft.Build.Engine-tests-net_4_5.csproj
mcs/class/Microsoft.Build.Framework/Microsoft.Build.Framework-net_2_0.csproj
mcs/class/Microsoft.Build.Framework/Microsoft.Build.Framework-net_3_5.csproj
mcs/class/Microsoft.Build.Framework/Microsoft.Build.Framework-net_4_0.csproj
mcs/class/Microsoft.Build.Framework/Microsoft.Build.Framework-net_4_5.csproj
mcs/class/Microsoft.Build.Framework/Microsoft.Build.Framework-tests-net_2_0.csproj
mcs/class/Microsoft.Build.Framework/Microsoft.Build.Framework-tests-net_3_5.csproj
mcs/class/Microsoft.Build.Framework/Microsoft.Build.Framework-tests-net_4_0.csproj
mcs/class/Microsoft.Build.Framework/Microsoft.Build.Framework-tests-net_4_5.csproj
mcs/class/Microsoft.Build.Tasks/Makefile
mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-net_2_0.csproj
mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-net_3_5.csproj
mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-net_4_0.csproj
mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-net_4_5.csproj
mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-tests-net_2_0.csproj
mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-tests-net_3_5.csproj
mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-tests-net_4_0.csproj
mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-tests-net_4_5.csproj
mcs/class/Microsoft.Build.Utilities/Makefile
mcs/class/Microsoft.Build.Utilities/Microsoft.Build.Utilities-net_2_0.csproj
mcs/class/Microsoft.Build.Utilities/Microsoft.Build.Utilities-net_3_5.csproj
mcs/class/Microsoft.Build.Utilities/Microsoft.Build.Utilities-net_4_0.csproj
mcs/class/Microsoft.Build.Utilities/Microsoft.Build.Utilities-net_4_5.csproj
mcs/class/Microsoft.Build.Utilities/Microsoft.Build.Utilities-tests-net_2_0.csproj
mcs/class/Microsoft.Build.Utilities/Microsoft.Build.Utilities-tests-net_3_5.csproj
mcs/class/Microsoft.Build.Utilities/Microsoft.Build.Utilities-tests-net_4_0.csproj
mcs/class/Microsoft.Build.Utilities/Microsoft.Build.Utilities-tests-net_4_5.csproj
mcs/class/Microsoft.Build/Makefile
mcs/class/Microsoft.Build/Microsoft.Build-net_4_0.csproj
mcs/class/Microsoft.Build/Microsoft.Build-net_4_5.csproj
mcs/class/Microsoft.Build/Microsoft.Build-tests-net_4_0.csproj
mcs/class/Microsoft.Build/Microsoft.Build-tests-net_4_5.csproj
mcs/class/Microsoft.CSharp/Microsoft.CSharp-net_4_0.csproj
mcs/class/Microsoft.CSharp/Microsoft.CSharp-net_4_5.csproj
mcs/class/Microsoft.CSharp/Microsoft.CSharp.RuntimeBinder/DynamicContext.cs
mcs/class/Microsoft.VisualC/Microsoft.VisualC-net_2_0.csproj
mcs/class/Microsoft.VisualC/Microsoft.VisualC-net_4_0.csproj
mcs/class/Microsoft.VisualC/Microsoft.VisualC-net_4_5.csproj
mcs/class/Microsoft.Web.Infrastructure/Microsoft.Web.Infrastructure-net_4_0.csproj
mcs/class/Microsoft.Web.Infrastructure/Microsoft.Web.Infrastructure-net_4_5.csproj
mcs/class/Mono.C5/Mono.C5-net_2_0.csproj
mcs/class/Mono.C5/Mono.C5-net_4_0.csproj
mcs/class/Mono.C5/Mono.C5-net_4_5.csproj
mcs/class/Mono.C5/Mono.C5-tests-net_2_0.csproj
mcs/class/Mono.C5/Mono.C5-tests-net_4_0.csproj
mcs/class/Mono.C5/Mono.C5-tests-net_4_5.csproj
mcs/class/Mono.CSharp/Makefile
mcs/class/Mono.CSharp/Mono.CSharp-net_2_0.csproj
mcs/class/Mono.CSharp/Mono.CSharp-net_4_0.csproj
mcs/class/Mono.CSharp/Mono.CSharp-net_4_5.csproj
mcs/class/Mono.CSharp/Mono.CSharp-tests-net_2_0.csproj
mcs/class/Mono.CSharp/Mono.CSharp-tests-net_4_0.csproj
mcs/class/Mono.CSharp/Mono.CSharp-tests-net_4_5.csproj
mcs/class/Mono.CSharp/Mono.CSharp.csproj
mcs/class/Mono.Cairo/Mono.Cairo-net_2_0.csproj
mcs/class/Mono.Cairo/Mono.Cairo-net_4_0.csproj
mcs/class/Mono.Cairo/Mono.Cairo-net_4_5.csproj
mcs/class/Mono.Cecil.Mdb/Makefile
mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb-net_2_0.csproj
mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb-net_4_0.csproj
mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb-net_4_5.csproj
mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb.dll.sources
mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb/AssemblyInfo.cs [deleted file]
mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb/MdbReader.cs [deleted file]
mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb/MdbWriter.cs [deleted file]
mcs/class/Mono.Cecil/.gitignore [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil-net_2_0.csproj
mcs/class/Mono.Cecil/Mono.Cecil-net_4_0.csproj
mcs/class/Mono.Cecil/Mono.Cecil-net_4_5.csproj
mcs/class/Mono.Cecil/Mono.Cecil.Cil/Code.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/CodeReader.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/CodeWriter.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/Document.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/ExceptionHandler.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/ILProcessor.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/Instruction.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/MethodBody.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/OpCode.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/OpCodes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/SequencePoint.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/Symbols.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/VariableDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Cil/VariableReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/BlobHeap.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Buffers.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/CodedIndex.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/ElementType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/GuidHeap.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Heap.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/MetadataToken.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Row.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/StringHeap.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/TableHeap.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/TokenType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/UserStringHeap.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Utilities.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/BinaryStreamReader.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/BinaryStreamWriter.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/ByteBuffer.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/ByteBufferEqualityComparer.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/DataDirectory.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/Image.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/ImageReader.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/ImageWriter.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/Section.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.PE/TextMap.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil.dll.sources
mcs/class/Mono.Cecil/Mono.Cecil/ArrayType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/AssemblyDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/AssemblyFlags.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/AssemblyHashAlgorithm.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/AssemblyInfo.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/AssemblyLinkedResource.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/AssemblyNameDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/AssemblyNameReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/AssemblyReader.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/AssemblyWriter.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/BaseAssemblyResolver.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/CallSite.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/CustomAttribute.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/DefaultAssemblyResolver.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/EmbeddedResource.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/EventAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/EventDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/EventReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ExportedType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/FieldAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/FieldDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/FieldReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/FileAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/FunctionPointerType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/GenericInstanceMethod.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/GenericInstanceType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/GenericParameter.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/GenericParameterAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/IConstantProvider.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ICustomAttributeProvider.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/IGenericInstance.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/IGenericParameterProvider.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/IMarshalInfoProvider.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/IMemberDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/IMetadataScope.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/IMetadataTokenProvider.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/IMethodSignature.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/Import.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/LinkedResource.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ManifestResourceAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MarshalInfo.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MemberDefinitionCollection.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MemberReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MetadataResolver.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MetadataSystem.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MethodAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MethodCallingConvention.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MethodDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MethodImplAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MethodReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MethodReturnType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MethodSemanticsAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/MethodSpecification.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/Modifiers.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ModuleDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ModuleKind.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ModuleReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/NativeType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/PInvokeAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/PInvokeInfo.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ParameterAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ParameterDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ParameterDefinitionCollection.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ParameterReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/PinnedType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/PointerType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/PropertyAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/PropertyDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/PropertyReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/ReferenceType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/Resource.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/SecurityDeclaration.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/SentinelType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/TargetRuntime.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/TypeAttributes.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/TypeDefinition.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/TypeDefinitionCollection.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/TypeParser.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/TypeReference.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/TypeSpecification.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/TypeSystem.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Cecil/VariantType.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Collections.Generic/Collection.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Collections.Generic/ReadOnlyCollection.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Security.Cryptography/CryptoConvert.cs [deleted file]
mcs/class/Mono.Cecil/Mono.Security.Cryptography/CryptoService.cs [deleted file]
mcs/class/Mono.Cecil/Mono/Actions.cs [deleted file]
mcs/class/Mono.Cecil/Mono/Empty.cs [deleted file]
mcs/class/Mono.Cecil/Mono/Funcs.cs [deleted file]
mcs/class/Mono.Cecil/NOTES.txt [deleted file]
mcs/class/Mono.Cecil/README [deleted file]
mcs/class/Mono.Cecil/System.Runtime.CompilerServices/ExtensionAttribute.cs [deleted file]
mcs/class/Mono.Cecil/mono.snk [deleted file]
mcs/class/Mono.Cecil/revision [deleted file]
mcs/class/Mono.Cecil/update.rb [deleted file]
mcs/class/Mono.CodeContracts/Makefile
mcs/class/Mono.CodeContracts/Mono.CodeContracts-net_4_5.csproj
mcs/class/Mono.CodeContracts/Mono.CodeContracts-tests-net_4_5.csproj
mcs/class/Mono.CompilerServices.SymbolWriter/Mono.CompilerServices.SymbolWriter-net_2_0.csproj
mcs/class/Mono.CompilerServices.SymbolWriter/Mono.CompilerServices.SymbolWriter-net_4_0.csproj
mcs/class/Mono.CompilerServices.SymbolWriter/Mono.CompilerServices.SymbolWriter-net_4_5.csproj
mcs/class/Mono.Data.Sqlite/.gitignore [new file with mode: 0644]
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite-net_2_0.csproj
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite-net_4_0.csproj
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite-net_4_5.csproj
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite-tests-net_2_0.csproj
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite-tests-net_4_0.csproj
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite-tests-net_4_5.csproj
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite_2.0/SQLiteBase.cs
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite_2.0/SQLiteConvert.cs
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite_2.0/SQLiteDataReader.cs
mcs/class/Mono.Data.Sqlite/Mono.Data.Sqlite_2.0/UnsafeNativeMethods.cs
mcs/class/Mono.Data.Sqlite/Test/SqliteCommandUnitTests.cs
mcs/class/Mono.Data.Sqlite/Test/SqliteDataReaderTest.cs
mcs/class/Mono.Data.Tds/Makefile
mcs/class/Mono.Data.Tds/Mono.Data.Tds-net_2_0.csproj
mcs/class/Mono.Data.Tds/Mono.Data.Tds-net_4_0.csproj
mcs/class/Mono.Data.Tds/Mono.Data.Tds-net_4_5.csproj
mcs/class/Mono.Data.Tds/Mono.Data.Tds.Protocol/TdsConnectionPool.cs
mcs/class/Mono.Data.Tds/Mono.Data.Tds_test.dll.sources [new file with mode: 0644]
mcs/class/Mono.Data.Tds/Test/bug-4786.cs [new file with mode: 0644]
mcs/class/Mono.Debugger.Soft/Makefile
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft-net_2_0.csproj
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft-net_4_0.csproj
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft-net_4_5.csproj
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft-tests-net_2_0.csproj
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft-tests-net_4_0.csproj
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft-tests-net_4_5.csproj
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft.dll.sources
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/AppDomainMirror.cs
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/Connection.cs
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/ILExceptionHandler.cs [new file with mode: 0644]
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/MethodBodyMirror.cs
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/MethodMirror.cs
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/PointerValue.cs [new file with mode: 0644]
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/PrimitiveValue.cs
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/TypeMirror.cs
mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/VirtualMachine.cs
mcs/class/Mono.Debugger.Soft/Test/dtest-app.cs
mcs/class/Mono.Debugger.Soft/Test/dtest.cs
mcs/class/Mono.Http/Mono.Http-net_2_0.csproj
mcs/class/Mono.Http/Mono.Http-net_4_0.csproj
mcs/class/Mono.Http/Mono.Http-net_4_5.csproj
mcs/class/Mono.Management/Mono.Management-net_2_0.csproj
mcs/class/Mono.Management/Mono.Management-net_4_0.csproj
mcs/class/Mono.Management/Mono.Management-net_4_5.csproj
mcs/class/Mono.Messaging.RabbitMQ/Mono.Messaging.RabbitMQ-net_2_0.csproj
mcs/class/Mono.Messaging.RabbitMQ/Mono.Messaging.RabbitMQ-net_4_0.csproj
mcs/class/Mono.Messaging.RabbitMQ/Mono.Messaging.RabbitMQ-net_4_5.csproj
mcs/class/Mono.Messaging.RabbitMQ/Mono.Messaging.RabbitMQ-tests-net_2_0.csproj
mcs/class/Mono.Messaging.RabbitMQ/Mono.Messaging.RabbitMQ-tests-net_4_0.csproj
mcs/class/Mono.Messaging.RabbitMQ/Mono.Messaging.RabbitMQ-tests-net_4_5.csproj
mcs/class/Mono.Messaging/Mono.Messaging-net_2_0.csproj
mcs/class/Mono.Messaging/Mono.Messaging-net_4_0.csproj
mcs/class/Mono.Messaging/Mono.Messaging-net_4_5.csproj
mcs/class/Mono.Messaging/Mono.Messaging-tests-net_2_0.csproj
mcs/class/Mono.Messaging/Mono.Messaging-tests-net_4_0.csproj
mcs/class/Mono.Messaging/Mono.Messaging-tests-net_4_5.csproj
mcs/class/Mono.Options/Makefile
mcs/class/Mono.Options/Mono.Options-net_2_0.csproj
mcs/class/Mono.Options/Mono.Options-net_4_0.csproj
mcs/class/Mono.Options/Mono.Options-net_4_5.csproj
mcs/class/Mono.Options/Mono.Options-tests-net_2_0.csproj
mcs/class/Mono.Options/Mono.Options-tests-net_4_0.csproj
mcs/class/Mono.Options/Mono.Options-tests-net_4_5.csproj
mcs/class/Mono.Parallel/Makefile
mcs/class/Mono.Parallel/Mono.Parallel-net_4_0.csproj
mcs/class/Mono.Parallel/Mono.Parallel-net_4_5.csproj
mcs/class/Mono.Parallel/Mono.Parallel-tests-net_4_0.csproj
mcs/class/Mono.Parallel/Mono.Parallel-tests-net_4_5.csproj
mcs/class/Mono.Posix/Mono.Posix-build.csproj
mcs/class/Mono.Posix/Mono.Posix-net_2_0.csproj
mcs/class/Mono.Posix/Mono.Posix-net_4_0.csproj
mcs/class/Mono.Posix/Mono.Posix-net_4_5.csproj
mcs/class/Mono.Posix/Mono.Posix-tests-net_2_0.csproj
mcs/class/Mono.Posix/Mono.Posix-tests-net_4_0.csproj
mcs/class/Mono.Posix/Mono.Posix-tests-net_4_5.csproj
mcs/class/Mono.Posix/Test/Mono.Unix/UnixGroupTest.cs
mcs/class/Mono.Posix/Test/Mono.Unix/UnixUserTest.cs
mcs/class/Mono.Security.Win32/Mono.Security.Win32-net_2_0.csproj
mcs/class/Mono.Security.Win32/Mono.Security.Win32-net_4_0.csproj
mcs/class/Mono.Security.Win32/Mono.Security.Win32-net_4_5.csproj
mcs/class/Mono.Security/Mono.Security-build.csproj
mcs/class/Mono.Security/Mono.Security-net_2_0.csproj
mcs/class/Mono.Security/Mono.Security-net_4_0.csproj
mcs/class/Mono.Security/Mono.Security-net_4_5.csproj
mcs/class/Mono.Security/Mono.Security-tests-net_2_0.csproj
mcs/class/Mono.Security/Mono.Security-tests-net_4_0.csproj
mcs/class/Mono.Security/Mono.Security-tests-net_4_5.csproj
mcs/class/Mono.Security/Mono.Security.Cryptography/ARC4Managed.cs
mcs/class/Mono.Security/Mono.Security.Cryptography/SHA224Managed.cs
mcs/class/Mono.Security/Mono.Security.Protocol.Tls.Handshake.Server/TlsServerCertificateRequest.cs
mcs/class/Mono.Security/Mono.Security.Protocol.Tls/SslServerStream.cs
mcs/class/Mono.Security/Test/Mono.Security.Cryptography/MD2Test.cs
mcs/class/Mono.Security/Test/Mono.Security.Cryptography/MD4Test.cs
mcs/class/Mono.Security/Test/Mono.Security.Protocol.Ntlm/Type3MessageTest.cs
mcs/class/Mono.Security/Test/Mono.Security.X509/X509CertificateTest.cs
mcs/class/Mono.Security/Test/Mono.Security.X509/X509CrlTest.cs
mcs/class/Mono.Simd/Mono.Simd-net_2_0.csproj
mcs/class/Mono.Simd/Mono.Simd-net_4_0.csproj
mcs/class/Mono.Simd/Mono.Simd-net_4_5.csproj
mcs/class/Mono.Tasklets/Mono.Tasklets-net_2_0.csproj
mcs/class/Mono.Tasklets/Mono.Tasklets-net_4_0.csproj
mcs/class/Mono.Tasklets/Mono.Tasklets-net_4_5.csproj
mcs/class/Mono.Web/Mono.Web-net_2_0.csproj
mcs/class/Mono.Web/Mono.Web-net_4_0.csproj
mcs/class/Mono.Web/Mono.Web-net_4_5.csproj
mcs/class/Mono.WebBrowser/Mono.WebBrowser-net_2_0.csproj
mcs/class/Mono.WebBrowser/Mono.WebBrowser-net_4_0.csproj
mcs/class/Mono.WebBrowser/Mono.WebBrowser-net_4_5.csproj
mcs/class/Mono.Xml.Ext/Makefile
mcs/class/Moonlight.Build.Tasks/Moonlight.Build.Tasks-net_2_0.csproj
mcs/class/Moonlight.Build.Tasks/Moonlight.Build.Tasks-net_4_0.csproj
mcs/class/Moonlight.Build.Tasks/Moonlight.Build.Tasks-net_4_5.csproj
mcs/class/Novell.Directory.Ldap/Novell.Directory.Ldap-net_2_0.csproj
mcs/class/Novell.Directory.Ldap/Novell.Directory.Ldap-net_4_0.csproj
mcs/class/Novell.Directory.Ldap/Novell.Directory.Ldap-net_4_5.csproj
mcs/class/Novell.Directory.Ldap/Novell.Directory.Ldap-tests-net_2_0.csproj
mcs/class/Novell.Directory.Ldap/Novell.Directory.Ldap-tests-net_4_0.csproj
mcs/class/Novell.Directory.Ldap/Novell.Directory.Ldap-tests-net_4_5.csproj
mcs/class/Npgsql/Npgsql-net_2_0.csproj
mcs/class/Npgsql/Npgsql-net_4_0.csproj
mcs/class/Npgsql/Npgsql-net_4_5.csproj
mcs/class/Npgsql/Npgsql-tests-net_2_0.csproj
mcs/class/Npgsql/Npgsql-tests-net_4_0.csproj
mcs/class/Npgsql/Npgsql-tests-net_4_5.csproj
mcs/class/OpenSystem.C/OpenSystem.C-net_2_0.csproj
mcs/class/OpenSystem.C/OpenSystem.C-net_4_0.csproj
mcs/class/OpenSystem.C/OpenSystem.C-net_4_5.csproj
mcs/class/PEAPI/PEAPI-net_2_0.csproj
mcs/class/PEAPI/PEAPI-net_4_0.csproj
mcs/class/PEAPI/PEAPI-net_4_5.csproj
mcs/class/RabbitMQ.Client/src/client/RabbitMQ.Client-net_2_0.csproj
mcs/class/RabbitMQ.Client/src/client/RabbitMQ.Client-net_4_0.csproj
mcs/class/RabbitMQ.Client/src/client/RabbitMQ.Client-net_4_5.csproj
mcs/class/System.ComponentModel.Composition/System.ComponentModel.Composition-net_4_0.csproj
mcs/class/System.ComponentModel.Composition/System.ComponentModel.Composition-net_4_5.csproj
mcs/class/System.ComponentModel.DataAnnotations/System.ComponentModel.DataAnnotations-net_2_0.csproj
mcs/class/System.ComponentModel.DataAnnotations/System.ComponentModel.DataAnnotations-net_4_0.csproj
mcs/class/System.ComponentModel.DataAnnotations/System.ComponentModel.DataAnnotations-net_4_5.csproj
mcs/class/System.ComponentModel.DataAnnotations/System.ComponentModel.DataAnnotations-tests-net_2_0.csproj
mcs/class/System.ComponentModel.DataAnnotations/System.ComponentModel.DataAnnotations-tests-net_4_0.csproj
mcs/class/System.ComponentModel.DataAnnotations/System.ComponentModel.DataAnnotations-tests-net_4_5.csproj
mcs/class/System.Configuration.Install/System.Configuration.Install-net_2_0.csproj
mcs/class/System.Configuration.Install/System.Configuration.Install-net_4_0.csproj
mcs/class/System.Configuration.Install/System.Configuration.Install-net_4_5.csproj
mcs/class/System.Configuration/System.Configuration-net_2_0.csproj
mcs/class/System.Configuration/System.Configuration-net_4_0.csproj
mcs/class/System.Configuration/System.Configuration-net_4_5.csproj
mcs/class/System.Configuration/System.Configuration-tests-net_2_0.csproj
mcs/class/System.Configuration/System.Configuration-tests-net_4_0.csproj
mcs/class/System.Configuration/System.Configuration-tests-net_4_5.csproj
mcs/class/System.Configuration/System.Configuration/Configuration.cs
mcs/class/System.Core/System.Core-build.csproj
mcs/class/System.Core/System.Core-net_2_0.csproj
mcs/class/System.Core/System.Core-net_4_0.csproj
mcs/class/System.Core/System.Core-net_4_5.csproj
mcs/class/System.Core/System.Core-tests-net_2_0.csproj
mcs/class/System.Core/System.Core-tests-net_4_0.csproj
mcs/class/System.Core/System.Core-tests-net_4_5.csproj
mcs/class/System.Core/System.Linq.Parallel.QueryNodes/QueryConcatNode.cs
mcs/class/System.Core/mobile_System.Core.dll.sources
mcs/class/System.Data.DataSetExtensions/System.Data.DataSetExtensions-net_2_0.csproj
mcs/class/System.Data.DataSetExtensions/System.Data.DataSetExtensions-net_4_0.csproj
mcs/class/System.Data.DataSetExtensions/System.Data.DataSetExtensions-net_4_5.csproj
mcs/class/System.Data.Linq/System.Data.Linq-net_2_0.csproj
mcs/class/System.Data.Linq/System.Data.Linq-net_4_0.csproj
mcs/class/System.Data.Linq/System.Data.Linq-net_4_5.csproj
mcs/class/System.Data.Linq/System.Data.Linq-tests-net_2_0.csproj
mcs/class/System.Data.Linq/System.Data.Linq-tests-net_4_0.csproj
mcs/class/System.Data.Linq/System.Data.Linq-tests-net_4_5.csproj
mcs/class/System.Data.Linq/src/DbLinq/Data/Linq/DataContext.cs
mcs/class/System.Data.OracleClient/System.Data.OracleClient-net_2_0.csproj
mcs/class/System.Data.OracleClient/System.Data.OracleClient-net_4_0.csproj
mcs/class/System.Data.OracleClient/System.Data.OracleClient-net_4_5.csproj
mcs/class/System.Data.OracleClient/System.Data.OracleClient-tests-net_2_0.csproj
mcs/class/System.Data.OracleClient/System.Data.OracleClient-tests-net_4_0.csproj
mcs/class/System.Data.OracleClient/System.Data.OracleClient-tests-net_4_5.csproj
mcs/class/System.Data.Services.Client/System.Data.Services.Client-net_2_0.csproj
mcs/class/System.Data.Services.Client/System.Data.Services.Client-net_4_0.csproj
mcs/class/System.Data.Services.Client/System.Data.Services.Client-net_4_5.csproj
mcs/class/System.Data.Services/Makefile
mcs/class/System.Data.Services/System.Data.Services-net_2_0.csproj
mcs/class/System.Data.Services/System.Data.Services-net_4_0.csproj
mcs/class/System.Data.Services/System.Data.Services-net_4_5.csproj
mcs/class/System.Data.Services/System.Data.Services-tests-net_2_0.csproj
mcs/class/System.Data.Services/System.Data.Services-tests-net_4_0.csproj
mcs/class/System.Data.Services/System.Data.Services-tests-net_4_5.csproj
mcs/class/System.Data/Makefile
mcs/class/System.Data/System.Data-net_2_0.csproj
mcs/class/System.Data/System.Data-net_4_0.csproj
mcs/class/System.Data/System.Data-net_4_5.csproj
mcs/class/System.Data/System.Data-tests-net_2_0.csproj
mcs/class/System.Data/System.Data-tests-net_4_0.csproj
mcs/class/System.Data/System.Data-tests-net_4_5.csproj
mcs/class/System.Data/System.Data/ForeignKeyConstraint.cs
mcs/class/System.Data/Test/System.Data/ForeignKeyConstraintTest.cs
mcs/class/System.Design/Makefile
mcs/class/System.Design/System.Design-net_2_0.csproj
mcs/class/System.Design/System.Design-net_4_0.csproj
mcs/class/System.Design/System.Design-net_4_5.csproj
mcs/class/System.Design/System.Design-tests-net_2_0.csproj
mcs/class/System.Design/System.Design-tests-net_4_0.csproj
mcs/class/System.Design/System.Design-tests-net_4_5.csproj
mcs/class/System.DirectoryServices/System.DirectoryServices-net_2_0.csproj
mcs/class/System.DirectoryServices/System.DirectoryServices-net_4_0.csproj
mcs/class/System.DirectoryServices/System.DirectoryServices-net_4_5.csproj
mcs/class/System.DirectoryServices/System.DirectoryServices-tests-net_2_0.csproj
mcs/class/System.DirectoryServices/System.DirectoryServices-tests-net_4_0.csproj
mcs/class/System.DirectoryServices/System.DirectoryServices-tests-net_4_5.csproj
mcs/class/System.Drawing.Design/System.Drawing.Design-net_2_0.csproj
mcs/class/System.Drawing.Design/System.Drawing.Design-net_4_0.csproj
mcs/class/System.Drawing.Design/System.Drawing.Design-net_4_5.csproj
mcs/class/System.Drawing/System.Drawing-net_2_0.csproj
mcs/class/System.Drawing/System.Drawing-net_4_0.csproj
mcs/class/System.Drawing/System.Drawing-net_4_5.csproj
mcs/class/System.Drawing/System.Drawing-tests-net_2_0.csproj
mcs/class/System.Drawing/System.Drawing-tests-net_4_0.csproj
mcs/class/System.Drawing/System.Drawing-tests-net_4_5.csproj
mcs/class/System.Drawing/System.Drawing/Icon.cs
mcs/class/System.Drawing/Test/DrawingTest/DrawingTestHelper/DrawingTest.cs
mcs/class/System.Drawing/Test/DrawingTest/DrawingTestHelper/Makefile
mcs/class/System.Drawing/Test/DrawingTest/DrawingTestHelper/PDComparer.cs
mcs/class/System.Drawing/Test/DrawingTest/Test/Graphics.cs
mcs/class/System.Drawing/Test/DrawingTest/Test/Makefile
mcs/class/System.Dynamic/System.Dynamic-net_4_0.csproj
mcs/class/System.Dynamic/System.Dynamic-net_4_5.csproj
mcs/class/System.EnterpriseServices/System.EnterpriseServices-net_2_0.csproj
mcs/class/System.EnterpriseServices/System.EnterpriseServices-net_4_0.csproj
mcs/class/System.EnterpriseServices/System.EnterpriseServices-net_4_5.csproj
mcs/class/System.IdentityModel.Selectors/System.IdentityModel.Selectors-net_2_0.csproj
mcs/class/System.IdentityModel.Selectors/System.IdentityModel.Selectors-net_4_0.csproj
mcs/class/System.IdentityModel.Selectors/System.IdentityModel.Selectors-net_4_5.csproj
mcs/class/System.IdentityModel/System.IdentityModel-net_2_0.csproj
mcs/class/System.IdentityModel/System.IdentityModel-net_4_0.csproj
mcs/class/System.IdentityModel/System.IdentityModel-net_4_5.csproj
mcs/class/System.IdentityModel/System.IdentityModel-tests-net_2_0.csproj
mcs/class/System.IdentityModel/System.IdentityModel-tests-net_4_0.csproj
mcs/class/System.IdentityModel/System.IdentityModel-tests-net_4_5.csproj
mcs/class/System.Json/Assembly/AssemblyInfo.cs
mcs/class/System.Json/Makefile
mcs/class/System.Json/System.Json-net_4_0.csproj
mcs/class/System.Json/System.Json-net_4_5.csproj
mcs/class/System.Json/System.Json-tests-net_4_0.csproj
mcs/class/System.Json/System.Json-tests-net_4_5.csproj
mcs/class/System.Json/System.Json.dll.sources
mcs/class/System.Json/System.Json/ChangeLog [deleted file]
mcs/class/System.Json/System.Json/JsonArray.cs [deleted file]
mcs/class/System.Json/System.Json/JsonObject.cs [deleted file]
mcs/class/System.Json/System.Json/JsonPrimitive.cs [deleted file]
mcs/class/System.Json/System.Json/JsonType.cs [deleted file]
mcs/class/System.Json/System.Json/JsonValue.cs [deleted file]
mcs/class/System.Json/Test/System.Json/JsonValueTest.cs
mcs/class/System.Management/System.Management-net_2_0.csproj
mcs/class/System.Management/System.Management-net_4_0.csproj
mcs/class/System.Management/System.Management-net_4_5.csproj
mcs/class/System.Messaging/System.Messaging-net_2_0.csproj
mcs/class/System.Messaging/System.Messaging-net_4_0.csproj
mcs/class/System.Messaging/System.Messaging-net_4_5.csproj
mcs/class/System.Messaging/System.Messaging-tests-net_2_0.csproj
mcs/class/System.Messaging/System.Messaging-tests-net_4_0.csproj
mcs/class/System.Messaging/System.Messaging-tests-net_4_5.csproj
mcs/class/System.Net.Http.Formatting/Extensions.cs [new file with mode: 0644]
mcs/class/System.Net.Http.Formatting/Makefile [new file with mode: 0644]
mcs/class/System.Net.Http.Formatting/System.Net.Http.Formatting-net_4_5.csproj [new file with mode: 0644]
mcs/class/System.Net.Http.Formatting/System.Net.Http.Formatting.dll.sources [new file with mode: 0644]
mcs/class/System.Net.Http/Assembly/AssemblyInfo.cs
mcs/class/System.Net.Http/Makefile
mcs/class/System.Net.Http/System.Net.Http-net_4_5.csproj [new file with mode: 0644]
mcs/class/System.Net.Http/System.Net.Http-net_4_5.sln [new file with mode: 0644]
mcs/class/System.Net.Http/System.Net.Http-tests-net_4_5.csproj [new file with mode: 0644]
mcs/class/System.Net.Http/System.Net.Http.Headers/CollectionExtensions.cs
mcs/class/System.Net.Http/System.Net.Http.Headers/ContentDispositionHeaderValue.cs [new file with mode: 0644]
mcs/class/System.Net.Http/System.Net.Http.Headers/HttpContentHeaders.cs
mcs/class/System.Net.Http/System.Net.Http.Headers/HttpRequestHeaders.cs
mcs/class/System.Net.Http/System.Net.Http.Headers/HttpResponseHeaders.cs
mcs/class/System.Net.Http/System.Net.Http.Headers/Lexer.cs
mcs/class/System.Net.Http/System.Net.Http.Headers/MediaTypeHeaderValue.cs
mcs/class/System.Net.Http/System.Net.Http.Headers/Parser.cs
mcs/class/System.Net.Http/System.Net.Http.Headers/QualityValue.cs
mcs/class/System.Net.Http/System.Net.Http.dll.sources
mcs/class/System.Net.Http/System.Net.Http/ByteArrayContent.cs
mcs/class/System.Net.Http/System.Net.Http/DelegatingHandler.cs [new file with mode: 0644]
mcs/class/System.Net.Http/System.Net.Http/FormUrlEncodedContent.cs [new file with mode: 0644]
mcs/class/System.Net.Http/System.Net.Http/HttpClient.cs
mcs/class/System.Net.Http/System.Net.Http/HttpClientHandler.cs
mcs/class/System.Net.Http/System.Net.Http/HttpContent.cs
mcs/class/System.Net.Http/System.Net.Http/HttpRequestMessage.cs
mcs/class/System.Net.Http/System.Net.Http/HttpResponseMessage.cs
mcs/class/System.Net.Http/System.Net.Http/MessageProcessingHandler.cs [new file with mode: 0644]
mcs/class/System.Net.Http/System.Net.Http/MultipartContent.cs [new file with mode: 0644]
mcs/class/System.Net.Http/System.Net.Http/MultipartFormDataContent.cs [new file with mode: 0644]
mcs/class/System.Net.Http/System.Net.Http/StreamContent.cs
mcs/class/System.Net.Http/System.Net.Http_test.dll.sources
mcs/class/System.Net.Http/Test/System.Net.Http.Headers/ContentDispositionHeaderValueTest.cs [new file with mode: 0644]
mcs/class/System.Net.Http/Test/System.Net.Http.Headers/MediaTypeHeaderValueTest.cs
mcs/class/System.Net.Http/Test/System.Net.Http/ByteArrayContentTest.cs
mcs/class/System.Net.Http/Test/System.Net.Http/FormUrlEncodedContentTest.cs [new file with mode: 0644]
mcs/class/System.Net.Http/Test/System.Net.Http/HttpClientHandlerTest.cs
mcs/class/System.Net.Http/Test/System.Net.Http/HttpClientTest.cs
mcs/class/System.Net.Http/Test/System.Net.Http/HttpRequestMessageTest.cs
mcs/class/System.Net.Http/Test/System.Net.Http/HttpResponseMessageTest.cs
mcs/class/System.Net.Http/Test/System.Net.Http/MultipartContentTest.cs [new file with mode: 0644]
mcs/class/System.Net.Http/Test/System.Net.Http/MultipartFormDataContentTest.cs [new file with mode: 0644]
mcs/class/System.Net.Http/Test/System.Net.Http/StreamContentTest.cs
mcs/class/System.Net/System.Net-net_2_0.csproj
mcs/class/System.Net/System.Net-net_4_0.csproj
mcs/class/System.Net/System.Net-net_4_5.csproj
mcs/class/System.Numerics/System.Numerics-net_4_0.csproj
mcs/class/System.Numerics/System.Numerics-net_4_5.csproj
mcs/class/System.Numerics/System.Numerics-tests-net_4_0.csproj
mcs/class/System.Numerics/System.Numerics-tests-net_4_5.csproj
mcs/class/System.Runtime.Caching/System.Runtime.Caching-net_4_0.csproj
mcs/class/System.Runtime.Caching/System.Runtime.Caching-net_4_5.csproj
mcs/class/System.Runtime.Caching/System.Runtime.Caching-tests-net_4_0.csproj
mcs/class/System.Runtime.Caching/System.Runtime.Caching-tests-net_4_5.csproj
mcs/class/System.Runtime.DurableInstancing/System.Runtime.DurableInstancing-net_4_0.csproj
mcs/class/System.Runtime.DurableInstancing/System.Runtime.DurableInstancing-net_4_5.csproj
mcs/class/System.Runtime.DurableInstancing/System.Runtime.DurableInstancing-tests-net_4_0.csproj
mcs/class/System.Runtime.DurableInstancing/System.Runtime.DurableInstancing-tests-net_4_5.csproj
mcs/class/System.Runtime.Remoting/System.Runtime.Remoting-net_2_0.csproj
mcs/class/System.Runtime.Remoting/System.Runtime.Remoting-net_4_0.csproj
mcs/class/System.Runtime.Remoting/System.Runtime.Remoting-net_4_5.csproj
mcs/class/System.Runtime.Remoting/System.Runtime.Remoting-tests-net_2_0.csproj
mcs/class/System.Runtime.Remoting/System.Runtime.Remoting-tests-net_4_0.csproj
mcs/class/System.Runtime.Remoting/System.Runtime.Remoting-tests-net_4_5.csproj
mcs/class/System.Runtime.Serialization.Formatters.Soap/System.Runtime.Serialization.Formatters.Soap-net_2_0.csproj
mcs/class/System.Runtime.Serialization.Formatters.Soap/System.Runtime.Serialization.Formatters.Soap-net_4_0.csproj
mcs/class/System.Runtime.Serialization.Formatters.Soap/System.Runtime.Serialization.Formatters.Soap-net_4_5.csproj
mcs/class/System.Runtime.Serialization.Formatters.Soap/System.Runtime.Serialization.Formatters.Soap-tests-net_2_0.csproj
mcs/class/System.Runtime.Serialization.Formatters.Soap/System.Runtime.Serialization.Formatters.Soap-tests-net_4_0.csproj
mcs/class/System.Runtime.Serialization.Formatters.Soap/System.Runtime.Serialization.Formatters.Soap-tests-net_4_5.csproj
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization-net_2_0.csproj
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization-net_4_0.csproj
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization-net_4_5.csproj
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization-tests-net_2_0.csproj
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization-tests-net_4_0.csproj
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization-tests-net_4_5.csproj
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization/DataContractSerializer.cs
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization/KnownTypeCollection.cs
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization/XmlFormatterDeserializer.cs
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization/XmlFormatterSerializer.cs
mcs/class/System.Runtime.Serialization/System.Runtime.Serialization_test.dll.sources
mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/Bug2843Test.cs
mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/Bug3258Test.cs [new file with mode: 0644]
mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/DataContractSerializerTest_DuplicateQName.cs [new file with mode: 0644]
mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/DataContractSerializerTest_NullableWithDictionary.cs
mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/XmlObjectSerializerTest.cs
mcs/class/System.Security/System.Security-net_2_0.csproj
mcs/class/System.Security/System.Security-net_4_0.csproj
mcs/class/System.Security/System.Security-net_4_5.csproj
mcs/class/System.Security/System.Security-tests-net_2_0.csproj
mcs/class/System.Security/System.Security-tests-net_4_0.csproj
mcs/class/System.Security/System.Security-tests-net_4_5.csproj
mcs/class/System.ServiceModel.Discovery/System.ServiceModel.Discovery-net_4_0.csproj
mcs/class/System.ServiceModel.Discovery/System.ServiceModel.Discovery-net_4_5.csproj
mcs/class/System.ServiceModel.Discovery/System.ServiceModel.Discovery-tests-net_4_0.csproj
mcs/class/System.ServiceModel.Discovery/System.ServiceModel.Discovery-tests-net_4_5.csproj
mcs/class/System.ServiceModel.Routing/System.ServiceModel.Routing-net_4_0.csproj
mcs/class/System.ServiceModel.Routing/System.ServiceModel.Routing-net_4_5.csproj
mcs/class/System.ServiceModel.Web/System.Runtime.Serialization.Json/JavaScriptReader.cs
mcs/class/System.ServiceModel.Web/System.Runtime.Serialization.Json/JsonReaderWriterFactory.cs
mcs/class/System.ServiceModel.Web/System.ServiceModel.Web-net_2_0.csproj
mcs/class/System.ServiceModel.Web/System.ServiceModel.Web-net_4_0.csproj
mcs/class/System.ServiceModel.Web/System.ServiceModel.Web-net_4_5.csproj
mcs/class/System.ServiceModel.Web/System.ServiceModel.Web-tests-net_2_0.csproj
mcs/class/System.ServiceModel.Web/System.ServiceModel.Web-tests-net_4_0.csproj
mcs/class/System.ServiceModel.Web/System.ServiceModel.Web-tests-net_4_5.csproj
mcs/class/System.ServiceModel.Web/System/UriTemplate.cs
mcs/class/System.ServiceModel.Web/Test/System/UriTemplateTest.cs
mcs/class/System.ServiceModel/Makefile
mcs/class/System.ServiceModel/System.ServiceModel-net_2_0.csproj
mcs/class/System.ServiceModel/System.ServiceModel-net_4_0.csproj
mcs/class/System.ServiceModel/System.ServiceModel-net_4_5.csproj
mcs/class/System.ServiceModel/System.ServiceModel-tests-net_2_0.csproj
mcs/class/System.ServiceModel/System.ServiceModel-tests-net_4_0.csproj
mcs/class/System.ServiceModel/System.ServiceModel-tests-net_4_5.csproj
mcs/class/System.ServiceProcess/System.ServiceProcess-net_2_0.csproj
mcs/class/System.ServiceProcess/System.ServiceProcess-net_4_0.csproj
mcs/class/System.ServiceProcess/System.ServiceProcess-net_4_5.csproj
mcs/class/System.ServiceProcess/System.ServiceProcess-tests-net_2_0.csproj
mcs/class/System.ServiceProcess/System.ServiceProcess-tests-net_4_0.csproj
mcs/class/System.ServiceProcess/System.ServiceProcess-tests-net_4_5.csproj
mcs/class/System.Threading.Tasks.Dataflow/Makefile
mcs/class/System.Threading.Tasks.Dataflow/System.Threading.Tasks.Dataflow-net_4_5.csproj
mcs/class/System.Threading.Tasks.Dataflow/System.Threading.Tasks.Dataflow-tests-net_4_5.csproj
mcs/class/System.Transactions/System.Transactions-net_2_0.csproj
mcs/class/System.Transactions/System.Transactions-net_4_0.csproj
mcs/class/System.Transactions/System.Transactions-net_4_5.csproj
mcs/class/System.Transactions/System.Transactions-tests-net_2_0.csproj
mcs/class/System.Transactions/System.Transactions-tests-net_4_0.csproj
mcs/class/System.Transactions/System.Transactions-tests-net_4_5.csproj
mcs/class/System.Web.Abstractions/System.Web.Abstractions-net_2_0.csproj
mcs/class/System.Web.Abstractions/System.Web.Abstractions-net_4_0.csproj
mcs/class/System.Web.Abstractions/System.Web.Abstractions-net_4_5.csproj
mcs/class/System.Web.Abstractions/System.Web.Abstractions-tests-net_2_0.csproj
mcs/class/System.Web.Abstractions/System.Web.Abstractions-tests-net_4_0.csproj
mcs/class/System.Web.Abstractions/System.Web.Abstractions-tests-net_4_5.csproj
mcs/class/System.Web.ApplicationServices/System.Web.ApplicationServices-net_2_0.csproj
mcs/class/System.Web.ApplicationServices/System.Web.ApplicationServices-net_4_0.csproj
mcs/class/System.Web.ApplicationServices/System.Web.ApplicationServices-net_4_5.csproj
mcs/class/System.Web.DynamicData/Makefile
mcs/class/System.Web.DynamicData/System.Web.DynamicData-net_2_0.csproj
mcs/class/System.Web.DynamicData/System.Web.DynamicData-net_4_0.csproj
mcs/class/System.Web.DynamicData/System.Web.DynamicData-net_4_5.csproj
mcs/class/System.Web.DynamicData/System.Web.DynamicData-tests-net_2_0.csproj
mcs/class/System.Web.DynamicData/System.Web.DynamicData-tests-net_4_0.csproj
mcs/class/System.Web.DynamicData/System.Web.DynamicData-tests-net_4_5.csproj
mcs/class/System.Web.Extensions.Design/System.Web.Extensions.Design-net_2_0.csproj
mcs/class/System.Web.Extensions.Design/System.Web.Extensions.Design-net_4_0.csproj
mcs/class/System.Web.Extensions.Design/System.Web.Extensions.Design-net_4_5.csproj
mcs/class/System.Web.Extensions.Design_1.0/System.Web.Extensions.Design_1.0-net_2_0.csproj
mcs/class/System.Web.Extensions/System.Web.Extensions-net_2_0.csproj
mcs/class/System.Web.Extensions/System.Web.Extensions-net_4_0.csproj
mcs/class/System.Web.Extensions/System.Web.Extensions-net_4_5.csproj
mcs/class/System.Web.Extensions/System.Web.Handlers/ScriptResourceHandler.cs
mcs/class/System.Web.Extensions_1.0/System.Web.Extensions_1.0-net_2_0.csproj
mcs/class/System.Web.Http/Makefile [new file with mode: 0644]
mcs/class/System.Web.Http/System.Web.Http-net_4_5.csproj [new file with mode: 0644]
mcs/class/System.Web.Http/System.Web.Http.dll.sources [new file with mode: 0644]
mcs/class/System.Web.Mvc/System.Web.Mvc-net_2_0.csproj
mcs/class/System.Web.Mvc2/Makefile
mcs/class/System.Web.Mvc2/System.Web.Mvc2-net_2_0.csproj
mcs/class/System.Web.Mvc2/System.Web.Mvc2-net_4_0.csproj
mcs/class/System.Web.Mvc2/System.Web.Mvc2-net_4_5.csproj
mcs/class/System.Web.Mvc3/GlobalAssemblyInfo.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/GlobalSuppressions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Makefile [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AcceptVerbsAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionDescriptor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionExecutedContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionExecutingContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionFilterAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionMethodDispatcher.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionMethodDispatcherCache.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionMethodSelector.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionMethodSelectorAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionNameAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionNameSelectorAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ActionSelector.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AdditionalMetaDataAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Ajax/AjaxExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Ajax/AjaxOptions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Ajax/InsertionMode.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AjaxHelper.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AjaxHelper`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AjaxRequestExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AllowHtmlAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AreaHelpers.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AreaRegistration.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AreaRegistrationContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AssociatedMetadataProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AssociatedValidatorProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/ActionDescriptorCreator.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/AsyncActionDescriptor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/AsyncActionMethodSelector.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/AsyncControllerActionInvoker.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/AsyncManager.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/AsyncResultWrapper.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/AsyncUtil.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/AsyncVoid.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/BeginInvokeDelegate.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/EndInvokeDelegate.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/EndInvokeDelegate`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/IAsyncActionInvoker.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/IAsyncController.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/IAsyncManagerContainer.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/OperationCounter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/ReflectedAsyncActionDescriptor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/ReflectedAsyncControllerDescriptor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/SimpleAsyncResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/SingleEntryGate.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/SynchronizationContextUtil.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/SynchronousOperationException.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/Trigger.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Async/TriggerListener.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AsyncController.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AsyncTimeoutAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AuthorizationContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/AuthorizeAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/BindAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/BuildManagerCompiledView.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/BuildManagerViewEngine.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/BuildManagerWrapper.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ByteArrayModelBinder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ChildActionOnlyAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ChildActionValueProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ChildActionValueProviderFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ClientDataTypeModelValidatorProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/CompareAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ContentResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Controller.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ControllerActionInvoker.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ControllerBase.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ControllerBuilder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ControllerContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ControllerDescriptor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ControllerDescriptorCache.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ControllerInstanceFilterProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ControllerTypeCache.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/CustomModelBinderAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelMetadata.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelMetadataProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelValidator.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelValidatorProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelValidator`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DataErrorInfoModelValidatorProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DataTypeUtil.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DefaultControllerFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DefaultModelBinder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DefaultViewLocationCache.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DependencyResolver.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DependencyResolverExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DescriptorUtil.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DictionaryHelpers.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DictionaryValueProvider`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/DynamicViewDataDictionary.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/EmptyModelMetadataProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/EmptyModelValidatorProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/EmptyResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Error.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExceptionContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionHelper.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/BinaryExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/CachedExpressionCompiler.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ConditionalExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ConstantExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/DefaultExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ExpressionFingerprintChain.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/FingerprintingExpressionVisitor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/HashCodeCombiner.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/Hoisted`2.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/HoistingExpressionVisitor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/IndexExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/LambdaExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/MemberExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/MethodCallExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ParameterExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/TypeBinaryExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/UnaryExpressionFingerprint.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FieldValidationMetadata.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FileContentResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FilePathResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FileResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FileStreamResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Filter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FilterAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FilterAttributeFilterProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FilterInfo.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FilterProviderCollection.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FilterProviders.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FilterScope.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FormCollection.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FormContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FormMethod.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FormValueProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/FormValueProviderFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/GlobalFilterCollection.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/GlobalFilters.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HandleErrorAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HandleErrorInfo.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HiddenInputAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/ChildActionExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/DefaultDisplayTemplates.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/DefaultEditorTemplates.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/DisplayExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/DisplayTextExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/EditorExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/FormExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/InputExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/LabelExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/LinkExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/MvcForm.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/PartialExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/RenderPartialExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/SelectExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/TemplateHelpers.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/TextAreaExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Html/ValidationExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HtmlHelper.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HtmlHelper`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpDeleteAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpFileCollectionValueProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpFileCollectionValueProviderFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpGetAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpHandlerUtil.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpNotFoundResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpPostAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpPostedFileBaseModelBinder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpPutAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpRequestExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpStatusCodeResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpUnauthorizedResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/HttpVerbs.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IActionFilter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IActionInvoker.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IAuthorizationFilter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IBuildManager.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IClientValidatable.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IController.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IControllerActivator.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IControllerFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IDependencyResolver.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IExceptionFilter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IFilterProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IMetadataAware.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IModelBinder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IModelBinderProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IMvcControlBuilder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IMvcFilter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IResolver.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IResultFilter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IRouteWithArea.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ITempDataProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IUniquelyIdentifiable.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IUnvalidatedRequestValues.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IUnvalidatedValueProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IValueProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IView.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IViewDataContainer.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IViewEngine.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IViewLocationCache.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IViewPageActivator.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/IViewStartPageChild.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/InputType.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/JavaScriptResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/JsonRequestBehavior.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/JsonResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/JsonValueProviderFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/LinqBinaryModelBinder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelBinderAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelBinderDictionary.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelBinderProviderCollection.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelBinderProviders.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelBinders.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelBindingContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationEqualToRule.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRangeRule.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRegexRule.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRemoteRule.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRequiredRule.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRule.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationStringLengthRule.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelError.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelErrorCollection.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelMetadata.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelMetadataProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelMetadataProviders.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelState.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelStateDictionary.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelValidationResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelValidator.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelValidatorProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelValidatorProviderCollection.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ModelValidatorProviders.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/MultiSelectList.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/MultiServiceResolver.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/MvcFilter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/MvcHandler.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/MvcHtmlString.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/MvcHttpHandler.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/MvcRouteHandler.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/MvcWebRazorHostFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/NameValueCollectionExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/NameValueCollectionValueProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/NoAsyncTimeoutAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/NonActionAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/NullViewLocationCache.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/OutputCacheAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ParameterBindingInfo.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ParameterDescriptor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ParameterInfoUtil.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/PartialViewResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/PathHelpers.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/PreApplicationStartCode.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/QueryStringValueProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/QueryStringValueProviderFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RangeAttributeAdapter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Razor/ModelSpan.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Razor/MvcCSharpRazorCodeGenerator.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Razor/MvcCSharpRazorCodeParser.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Razor/MvcVBRazorCodeGenerator.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Razor/MvcVBRazorCodeParser.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Razor/MvcWebPageRazorHost.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Razor/SetModelTypeCodeGenerator.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Razor/StartPageLookupDelegate.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RazorView.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RazorViewEngine.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ReaderWriterCache`2.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RedirectResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RedirectToRouteResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ReflectedActionDescriptor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ReflectedAttributeCache.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ReflectedControllerDescriptor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ReflectedParameterBindingInfo.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ReflectedParameterDescriptor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RegularExpressionAttributeAdapter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RemoteAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RequireHttpsAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RequiredAttributeAdapter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Resources/MvcResources.Designer.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/Resources/MvcResources.resx [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ResultExecutedContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ResultExecutingContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RouteCollectionExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RouteDataValueProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RouteDataValueProviderFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/RouteValuesHelpers.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/SecurityUtil.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/SelectList.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/SelectListItem.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/SessionStateAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/SessionStateTempDataProvider.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/SingleServiceResolver.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/StringLengthAttributeAdapter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/TagBuilderExtensions.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/TempDataDictionary.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/TemplateInfo.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/TryGetValueDelegate.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/TypeCacheSerializer.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/TypeCacheUtil.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/TypeDescriptorHelper.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/TypeHelpers.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/UnvalidatedRequestValuesAccessor.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/UnvalidatedRequestValuesWrapper.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/UrlHelper.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/UrlParameter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/UrlRewriterHelper.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValidatableObjectAdapter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValidateAntiForgeryTokenAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValidateInputAttribute.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValueProviderCollection.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValueProviderDictionary.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValueProviderFactories.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValueProviderFactory.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValueProviderFactoryCollection.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValueProviderResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ValueProviderUtil.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewContext.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewDataDictionary.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewDataDictionary`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewDataInfo.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewEngineCollection.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewEngineResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewEngines.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewMasterPage.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewMasterPageControlBuilder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewMasterPage`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewPage.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewPageControlBuilder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewPage`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewResult.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewResultBase.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewStartPage.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewTemplateUserControl.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewTemplateUserControl`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewType.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewTypeControlBuilder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewTypeParserFilter.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewUserControl.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewUserControlControlBuilder.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/ViewUserControl`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/VirtualPathProviderViewEngine.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/WebFormView.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/WebFormViewEngine.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/WebViewPage.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Mvc/WebViewPage`1.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/Properties/AssemblyInfo.cs [new file with mode: 0644]
mcs/class/System.Web.Mvc3/System.Web.Mvc.csproj [new file with mode: 0644]
mcs/class/System.Web.Mvc3/System.Web.Mvc3-net_4_5.csproj [new file with mode: 0644]
mcs/class/System.Web.Mvc3/System.Web.Mvc3.dll.sources [new file with mode: 0644]
mcs/class/System.Web.Razor/Assembly/AssemblyInfo.cs [new file with mode: 0644]
mcs/class/System.Web.Razor/Makefile [new file with mode: 0644]
mcs/class/System.Web.Razor/System.Web.Razor-net_4_5.csproj [new file with mode: 0644]
mcs/class/System.Web.Razor/System.Web.Razor.dll.sources [new file with mode: 0644]
mcs/class/System.Web.Routing/System.Web.Routing-net_2_0.csproj
mcs/class/System.Web.Routing/System.Web.Routing-net_4_0.csproj
mcs/class/System.Web.Routing/System.Web.Routing-net_4_5.csproj
mcs/class/System.Web.Routing/System.Web.Routing-tests-net_2_0.csproj
mcs/class/System.Web.Routing/System.Web.Routing-tests-net_4_0.csproj
mcs/class/System.Web.Routing/System.Web.Routing-tests-net_4_5.csproj
mcs/class/System.Web.Services/System.Web.Services-net_2_0.csproj
mcs/class/System.Web.Services/System.Web.Services-net_4_0.csproj
mcs/class/System.Web.Services/System.Web.Services-net_4_5.csproj
mcs/class/System.Web.Services/System.Web.Services-tests-net_2_0.csproj
mcs/class/System.Web.Services/System.Web.Services-tests-net_4_0.csproj
mcs/class/System.Web.Services/System.Web.Services-tests-net_4_5.csproj
mcs/class/System.Web.WebPages.Deployment/Assembly/AssemblyInfo.cs [new file with mode: 0644]
mcs/class/System.Web.WebPages.Deployment/Makefile [new file with mode: 0644]
mcs/class/System.Web.WebPages.Deployment/System.Web.WebPages.Deployment-net_4_5.csproj [new file with mode: 0644]
mcs/class/System.Web.WebPages.Deployment/System.Web.WebPages.Deployment.dll.sources [new file with mode: 0644]
mcs/class/System.Web.WebPages.Razor/Assembly/AssemblyInfo.cs [new file with mode: 0644]
mcs/class/System.Web.WebPages.Razor/Makefile [new file with mode: 0644]
mcs/class/System.Web.WebPages.Razor/System.Web.WebPages.Razor-net_4_5.csproj [new file with mode: 0644]
mcs/class/System.Web.WebPages.Razor/System.Web.WebPages.Razor.dll.sources [new file with mode: 0644]
mcs/class/System.Web.WebPages/Assembly/AssemblyInfo.cs [new file with mode: 0644]
mcs/class/System.Web.WebPages/Makefile [new file with mode: 0644]
mcs/class/System.Web.WebPages/System.Web.WebPages-net_4_5.csproj [new file with mode: 0644]
mcs/class/System.Web.WebPages/System.Web.WebPages.dll.sources [new file with mode: 0644]
mcs/class/System.Web/Assembly/AssemblyInfo.cs
mcs/class/System.Web/Makefile
mcs/class/System.Web/System.Web-net_2_0.csproj
mcs/class/System.Web/System.Web-net_4_0.csproj
mcs/class/System.Web/System.Web-net_4_5.csproj
mcs/class/System.Web/System.Web.Handlers/AssemblyResourceLoader.cs
mcs/class/System.Web/System.Web/HttpRequest.cs
mcs/class/System.Web/Test/TestMonoWeb/Makefile
mcs/class/System.Windows.Forms.DataVisualization/System.Windows.Forms.DataVisualization-net_4_0.csproj
mcs/class/System.Windows.Forms.DataVisualization/System.Windows.Forms.DataVisualization-net_4_5.csproj
mcs/class/System.XML/Makefile
mcs/class/System.XML/System.Xml-build.csproj
mcs/class/System.XML/System.Xml-net_2_0.csproj
mcs/class/System.XML/System.Xml-net_4_0.csproj
mcs/class/System.XML/System.Xml-net_4_5.csproj
mcs/class/System.XML/System.Xml-tests-net_2_0.csproj
mcs/class/System.XML/System.Xml-tests-net_4_0.csproj
mcs/class/System.XML/System.Xml-tests-net_4_5.csproj
mcs/class/System.XML/System.Xml.Serialization/XmlAttributes.cs
mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs
mcs/class/System.XML/System.Xml/IXmlNamespaceResolver.cs
mcs/class/System.XML/System.Xml/XmlAttribute.cs
mcs/class/System.XML/System.Xml/XmlConvert.cs
mcs/class/System.XML/System.Xml/XmlDocument.cs
mcs/class/System.XML/System.Xml/XmlDocumentFragment.cs
mcs/class/System.XML/System.Xml/XmlImplementation.cs
mcs/class/System.XML/System.Xml/XmlNameTable.cs
mcs/class/System.XML/System.Xml/XmlNodeReader2.cs
mcs/class/System.XML/System.Xml/XmlReader.cs
mcs/class/System.XML/System.Xml/XmlReaderSettings.cs
mcs/class/System.XML/System.Xml/XmlResolver.cs
mcs/class/System.XML/System.Xml/XmlTextWriter2.cs
mcs/class/System.XML/System.Xml/XmlWriter.cs
mcs/class/System.XML/Test/System.Xml.Schema/XmlSchemaCollectionTests.cs
mcs/class/System.XML/Test/System.Xml.Serialization/ComplexDataStructure.cs
mcs/class/System.XML/Test/System.Xml.Serialization/DeserializeTests.cs
mcs/class/System.XML/Test/System.Xml.Serialization/XmlAttributesTests.cs
mcs/class/System.XML/Test/System.Xml/XmlWriterSettingsTests.cs
mcs/class/System.XML/mobile_System.Xml.dll.sources
mcs/class/System.Xaml/System.Xaml-net_4_0.csproj
mcs/class/System.Xaml/System.Xaml-net_4_5.csproj
mcs/class/System.Xaml/System.Xaml-tests-net_4_0.csproj
mcs/class/System.Xaml/System.Xaml-tests-net_4_5.csproj
mcs/class/System.Xml.Linq/System.Xml.Linq-net_2_0.csproj
mcs/class/System.Xml.Linq/System.Xml.Linq-net_4_0.csproj
mcs/class/System.Xml.Linq/System.Xml.Linq-net_4_5.csproj
mcs/class/System.Xml.Linq/System.Xml.Linq-tests-net_2_0.csproj
mcs/class/System.Xml.Linq/System.Xml.Linq-tests-net_4_0.csproj
mcs/class/System.Xml.Linq/System.Xml.Linq-tests-net_4_5.csproj
mcs/class/System.Xml.Linq/System.Xml.Linq/XDocument.cs
mcs/class/System.Xml.Linq/System.Xml.Linq/XElement.cs
mcs/class/System.Xml.Linq/System.Xml.Linq/XNodeNavigator.cs
mcs/class/System.Xml.Linq/Test/System.Xml.Linq/XDocumentTest.cs
mcs/class/System.Xml.Linq/Test/System.Xml.Linq/XElementTest.cs
mcs/class/System.Xml.Linq/Test/System.Xml.Linq/XNodeNavigatorTest.cs
mcs/class/System/Assembly/AssemblyInfo.cs
mcs/class/System/Makefile
mcs/class/System/Microsoft.CSharp/CSharpCodeCompiler.cs
mcs/class/System/Microsoft.CSharp/CSharpCodeGenerator.cs
mcs/class/System/System-build.csproj
mcs/class/System/System-net_2_0.csproj
mcs/class/System/System-net_4_0.csproj
mcs/class/System/System-net_4_5.csproj
mcs/class/System/System-tests-net_2_0.csproj
mcs/class/System/System-tests-net_4_0.csproj
mcs/class/System/System-tests-net_4_5.csproj
mcs/class/System/System.CodeDom.Compiler/CodeGenerator.cs
mcs/class/System/System.Diagnostics/Debug.cs
mcs/class/System/System.Diagnostics/DefaultTraceListener.cs
mcs/class/System/System.Diagnostics/Stopwatch.cs
mcs/class/System/System.Diagnostics/TraceImpl.cs
mcs/class/System/System.Diagnostics/TraceListener.cs
mcs/class/System/System.Diagnostics/TraceListenerCollection.cs
mcs/class/System/System.IO.Ports/WinSerialStream.cs
mcs/class/System/System.Net.Mime/ContentType.cs
mcs/class/System/System.Net.NetworkInformation/NetworkInterface.cs
mcs/class/System/System.Net.Sockets/Socket.cs
mcs/class/System/System.Net/ChunkStream.cs
mcs/class/System/System.Net/Cookie.cs
mcs/class/System/System.Net/CookieContainer.cs
mcs/class/System/System.Net/EndPointListener.cs
mcs/class/System/System.Net/HttpConnection.cs
mcs/class/System/System.Net/HttpListenerRequest.cs
mcs/class/System/System.Net/HttpWebRequest.cs
mcs/class/System/System.Net/MacProxy.cs [new file with mode: 0644]
mcs/class/System/System.Net/ServicePointManager.cs
mcs/class/System/System.Net/WebConnection.cs
mcs/class/System/System.Net/WebHeaderCollection.cs
mcs/class/System/System.Net/WebRequest.cs
mcs/class/System/System.Net/WebResponse.cs
mcs/class/System/System.Security.Cryptography.X509Certificates/OSX509Certificates.cs
mcs/class/System/System.Windows.Input/ICommand.cs [new file with mode: 0644]
mcs/class/System/System.dll.sources
mcs/class/System/System/Uri.cs
mcs/class/System/System_test.dll.sources
mcs/class/System/Test/Microsoft.CSharp/CodeGeneratorFromCompileUnitTest.cs
mcs/class/System/Test/System.CodeDom.Compiler/CodeGeneratorGenerateFromCompileUnitTest.cs [new file with mode: 0644]
mcs/class/System/Test/System.CodeDom.Compiler/CodeGeneratorTest.cs
mcs/class/System/Test/System.Collections.Specialized/BasicOperationsTest.cs
mcs/class/System/Test/System.Collections.Specialized/StringCollectionTest.cs
mcs/class/System/Test/System.ComponentModel/DateTimeOffsetConverterTests.cs
mcs/class/System/Test/System.ComponentModel/EventHandlerListTests.cs
mcs/class/System/Test/System.Diagnostics/DebugTest.cs [new file with mode: 0644]
mcs/class/System/Test/System.Net/CookieContainerTest.cs
mcs/class/System/Test/System.Net/SocketPermissionTest.cs
mcs/class/System/Test/System.Security.Cryptography.X509Certificates/X509Cert20Test.cs [new file with mode: 0644]
mcs/class/System/Test/System/UriTest.cs
mcs/class/System/mobile_System.dll.sources
mcs/class/SystemWebTestShim/SystemWebTestShim-net_2_0.csproj
mcs/class/SystemWebTestShim/SystemWebTestShim-net_4_0.csproj
mcs/class/SystemWebTestShim/SystemWebTestShim-net_4_5.csproj
mcs/class/WebMatrix.Data/Makefile
mcs/class/WebMatrix.Data/WebMatrix.Data-net_4_0.csproj
mcs/class/WebMatrix.Data/WebMatrix.Data-net_4_5.csproj
mcs/class/WebMatrix.Data/WebMatrix.Data-tests-net_4_0.csproj
mcs/class/WebMatrix.Data/WebMatrix.Data-tests-net_4_5.csproj
mcs/class/WindowsBase/Makefile
mcs/class/WindowsBase/WindowsBase-net_2_0.csproj
mcs/class/WindowsBase/WindowsBase-net_4_0.csproj
mcs/class/WindowsBase/WindowsBase-net_4_5.csproj
mcs/class/WindowsBase/WindowsBase-tests-net_2_0.csproj
mcs/class/WindowsBase/WindowsBase-tests-net_4_0.csproj
mcs/class/WindowsBase/WindowsBase-tests-net_4_5.csproj
mcs/class/corlib/Makefile
mcs/class/corlib/System.Collections.Concurrent/ConcurrentStack.cs
mcs/class/corlib/System.Globalization/CompareInfo.cs
mcs/class/corlib/System.Globalization/CultureInfo.cs
mcs/class/corlib/System.Globalization/DateTimeFormatInfo.cs
mcs/class/corlib/System.Globalization/RegionInfo.cs
mcs/class/corlib/System.Globalization/TextInfo.cs
mcs/class/corlib/System.IO.IsolatedStorage/IsolatedStorageFile.cs
mcs/class/corlib/System.IO/BinaryWriter.cs
mcs/class/corlib/System.IO/Directory.cs
mcs/class/corlib/System.IO/LogcatTextWriter.cs
mcs/class/corlib/System.IO/Path.cs
mcs/class/corlib/System.Reflection/MonoMethod.cs
mcs/class/corlib/System.Runtime.CompilerServices/AsyncTaskMethodBuilder.cs
mcs/class/corlib/System.Runtime.CompilerServices/AsyncTaskMethodBuilder_T.cs
mcs/class/corlib/System.Threading.Tasks/EventSlots.cs [deleted file]
mcs/class/corlib/System.Threading.Tasks/Task.cs
mcs/class/corlib/System.Threading.Tasks/TaskActionInvoker.cs
mcs/class/corlib/System.Threading.Tasks/TaskConstants.cs
mcs/class/corlib/System.Threading.Tasks/TaskContinuation.cs
mcs/class/corlib/System.Threading.Tasks/TaskFactory.cs
mcs/class/corlib/System.Threading.Tasks/TaskScheduler.cs
mcs/class/corlib/System.Threading.Tasks/Task_T.cs
mcs/class/corlib/System.Threading.Tasks/TpScheduler.cs
mcs/class/corlib/System.Threading/CancellationTokenRegistration.cs
mcs/class/corlib/System.Threading/CancellationTokenSource.cs
mcs/class/corlib/System.Threading/ManualResetEventSlim.cs
mcs/class/corlib/System.Threading/Thread.cs
mcs/class/corlib/System/DateTimeUtils.cs
mcs/class/corlib/System/Environment.cs
mcs/class/corlib/System/Guid.cs
mcs/class/corlib/System/Int32.cs
mcs/class/corlib/System/String.cs
mcs/class/corlib/System/TimeZone.cs
mcs/class/corlib/System/__ComObject.cs
mcs/class/corlib/Test/System.Collections.Concurrent/ConcurrentStackTests.cs
mcs/class/corlib/Test/System.Collections/NewArrayListTest.cs
mcs/class/corlib/Test/System.Diagnostics/DebugTest.cs [deleted file]
mcs/class/corlib/Test/System.Globalization/CultureInfoTest.cs
mcs/class/corlib/Test/System.Globalization/DateTimeFormatInfoTest.cs
mcs/class/corlib/Test/System.Globalization/RegionInfoTest.cs
mcs/class/corlib/Test/System.Globalization/TextInfoTest.cs
mcs/class/corlib/Test/System.IO.IsolatedStorage/IsolatedStorageFileTest.cs
mcs/class/corlib/Test/System.IO/DirectoryTest.cs
mcs/class/corlib/Test/System.Reflection/ParameterInfoTest.cs
mcs/class/corlib/Test/System.Runtime.Serialization.Formatters.Binary/VersionTolerantSerialization/BinarySerializationOverVersions.cs
mcs/class/corlib/Test/System.Security.Cryptography.X509Certificates/X509Cert20Test.cs [deleted file]
mcs/class/corlib/Test/System.Security.Cryptography/DESTest.cs
mcs/class/corlib/Test/System.Security.Cryptography/RIPEMD160Test.cs
mcs/class/corlib/Test/System.Security.Cryptography/RSACryptoServiceProviderTest.cs
mcs/class/corlib/Test/System.Security.Cryptography/SymmetricAlgorithmTest.cs
mcs/class/corlib/Test/System.Threading.Tasks/TaskCompletionSourceTests.cs
mcs/class/corlib/Test/System.Threading.Tasks/TaskFactoryTest.cs
mcs/class/corlib/Test/System.Threading.Tasks/TaskSchedulerTest.cs
mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs
mcs/class/corlib/Test/System.Threading.Tasks/Task_T_Test.cs
mcs/class/corlib/Test/System.Threading/CancellationTokenSourceTest.cs
mcs/class/corlib/Test/System.Threading/ManualResetEventSlimTests.cs
mcs/class/corlib/Test/System.Threading/ThreadTest.cs
mcs/class/corlib/Test/System/DateTimeTest.cs
mcs/class/corlib/Test/System/DecimalTest.cs
mcs/class/corlib/Test/System/DoubleTest.cs
mcs/class/corlib/Test/System/GuidTest.cs
mcs/class/corlib/Test/System/Int16Test.cs
mcs/class/corlib/Test/System/Int32Test.cs
mcs/class/corlib/Test/System/Int64Test.cs
mcs/class/corlib/Test/System/NumberFormatterTest.cs
mcs/class/corlib/Test/System/SingleTest.cs
mcs/class/corlib/Test/System/StringTest.cs
mcs/class/corlib/Test/System/TimeZoneTest.cs
mcs/class/corlib/Test/System/UInt16Test.cs
mcs/class/corlib/Test/System/UInt32Test.cs
mcs/class/corlib/Test/System/UInt64Test.cs
mcs/class/corlib/Test/ms_run_test.sh [deleted file]
mcs/class/corlib/Test/run_test.sh [deleted file]
mcs/class/corlib/corlib-build.csproj
mcs/class/corlib/corlib-net_2_0.csproj
mcs/class/corlib/corlib-net_4_0.csproj
mcs/class/corlib/corlib-net_4_5.csproj
mcs/class/corlib/corlib-tests-net_2_0.csproj
mcs/class/corlib/corlib-tests-net_4_0.csproj
mcs/class/corlib/corlib-tests-net_4_5.csproj
mcs/class/corlib/corlib.dll.sources
mcs/class/corlib/corlib_test.dll.sources
mcs/errors/CS0012-14-lib.il [new file with mode: 0644]
mcs/errors/CS0012-15-lib.il [new file with mode: 0644]
mcs/errors/CS0012-16-lib.il [new file with mode: 0644]
mcs/errors/CS0101-7-2.cs [new file with mode: 0644]
mcs/errors/Makefile
mcs/errors/cs0012-14.cs [new file with mode: 0644]
mcs/errors/cs0012-15.cs [new file with mode: 0644]
mcs/errors/cs0012-16.cs [new file with mode: 0644]
mcs/errors/cs0023-18.cs [new file with mode: 0644]
mcs/errors/cs0101-7.cs [new file with mode: 0644]
mcs/errors/cs0118-16.cs [new file with mode: 0644]
mcs/errors/cs0120-18.cs [new file with mode: 0644]
mcs/errors/cs0453-8.cs [new file with mode: 0644]
mcs/errors/cs0516-2.cs [new file with mode: 0644]
mcs/errors/cs0649-5.cs [new file with mode: 0644]
mcs/errors/cs0839.cs [deleted file]
mcs/errors/cs1525-43.cs [new file with mode: 0644]
mcs/errors/cs1525-44.cs [new file with mode: 0644]
mcs/errors/cs1525-45.cs [new file with mode: 0644]
mcs/errors/cs1525-46.cs [new file with mode: 0644]
mcs/errors/cs1525-47.cs [new file with mode: 0644]
mcs/errors/cs1526.cs [deleted file]
mcs/errors/cs1691-4.cs [new file with mode: 0644]
mcs/errors/cs2021-2.cs [new file with mode: 0644]
mcs/errors/cs2021.cs [new file with mode: 0644]
mcs/jay/Makefile
mcs/mcs/anonymous.cs
mcs/mcs/assign.cs
mcs/mcs/async.cs
mcs/mcs/cfold.cs
mcs/mcs/class.cs
mcs/mcs/codegen.cs
mcs/mcs/const.cs
mcs/mcs/constant.cs
mcs/mcs/convert.cs
mcs/mcs/cs-parser.jay
mcs/mcs/cs-tokenizer.cs
mcs/mcs/decl.cs
mcs/mcs/doc.cs
mcs/mcs/driver.cs
mcs/mcs/ecore.cs
mcs/mcs/enum.cs
mcs/mcs/expression.cs
mcs/mcs/generic.cs
mcs/mcs/import.cs
mcs/mcs/iterators.cs
mcs/mcs/literal.cs
mcs/mcs/method.cs
mcs/mcs/namespace.cs
mcs/mcs/nullable.cs
mcs/mcs/parameter.cs
mcs/mcs/property.cs
mcs/mcs/report.cs
mcs/mcs/settings.cs
mcs/mcs/statement.cs
mcs/mcs/typespec.cs
mcs/mcs/visit.cs
mcs/tests/gtest-409.cs
mcs/tests/gtest-437.cs [deleted file]
mcs/tests/gtest-567.cs [new file with mode: 0644]
mcs/tests/gtest-568.cs [new file with mode: 0644]
mcs/tests/gtest-etree-01.cs
mcs/tests/gtest-exmethod-43.cs [new file with mode: 0644]
mcs/tests/gtest-iter-23.cs [new file with mode: 0644]
mcs/tests/gtest-iter-24.cs [new file with mode: 0644]
mcs/tests/gtest-iter-25.cs [new file with mode: 0644]
mcs/tests/known-issues-net_4_5
mcs/tests/test-106.cs [deleted file]
mcs/tests/test-129.cs
mcs/tests/test-514.cs
mcs/tests/test-792-lib.il
mcs/tests/test-792.cs
mcs/tests/test-795.cs
mcs/tests/test-796.cs
mcs/tests/test-844.cs [new file with mode: 0644]
mcs/tests/test-845.cs [new file with mode: 0644]
mcs/tests/test-anon-170.cs [new file with mode: 0644]
mcs/tests/test-async-23.cs
mcs/tests/test-async-31.cs [new file with mode: 0644]
mcs/tests/test-async-32.cs [new file with mode: 0644]
mcs/tests/test-async-33.cs [new file with mode: 0644]
mcs/tests/test-async-34.cs [new file with mode: 0644]
mcs/tests/test-debug-19-ref.xml
mcs/tests/test-debug-21-ref.xml
mcs/tests/test-debug-22-ref.xml [new file with mode: 0644]
mcs/tests/test-debug-22.cs [new file with mode: 0644]
mcs/tests/test-xml-066-ref.xml [new file with mode: 0644]
mcs/tests/test-xml-066.cs [new file with mode: 0644]
mcs/tests/ver-il-net_4_5.xml
mcs/tools/corcompare/gen-infos.rb
mcs/tools/corcompare/mono-api-info.cs
mcs/tools/corcompare/upload.rb
mcs/tools/mono-shlib-cop/Makefile
mcs/tools/monodoc/Makefile
mcs/tools/monodoc/Mono.Documentation/XmlDocUtils.cs
mcs/tools/monodoc/Monodoc/ecma-provider.cs
mcs/tools/monodoc/Monodoc/editing.cs
mcs/tools/monodoc/Monodoc/provider.cs
mcs/tools/monodoc/Resources/mdoc-html-utils.xsl
mcs/tools/monodoc/Resources/mdoc-sections-css.xsl
mcs/tools/monodoc/Resources/mdoc-sections.xsl
mcs/tools/svcutil/Makefile
mcs/tools/xbuild/Makefile
mcs/tools/xbuild/xbuild/Microsoft.Portable.CSharp.targets [new file with mode: 0644]
mono-core.spec.in
mono/arch/arm/arm-dis.c
mono/arch/s390x/s390x-codegen.h
mono/dis/Makefile.am
mono/metadata/Makefile.am
mono/metadata/appdomain.c
mono/metadata/boehm-gc.c
mono/metadata/class-internals.h
mono/metadata/class.c
mono/metadata/cominterop.c
mono/metadata/culture-info-tables.h
mono/metadata/culture-info.h
mono/metadata/filewatcher.c
mono/metadata/gc-internal.h
mono/metadata/gc.c
mono/metadata/icall-def.h
mono/metadata/image.c
mono/metadata/loader.c
mono/metadata/locales.c
mono/metadata/locales.h
mono/metadata/marshal.c
mono/metadata/marshal.h
mono/metadata/metadata-internals.h
mono/metadata/metadata.c
mono/metadata/null-gc.c
mono/metadata/object-internals.h
mono/metadata/object.c
mono/metadata/process.c
mono/metadata/reflection.c
mono/metadata/sgen-alloc.c
mono/metadata/sgen-bridge.c
mono/metadata/sgen-bridge.h
mono/metadata/sgen-cardtable.c
mono/metadata/sgen-copy-object.h [new file with mode: 0644]
mono/metadata/sgen-debug.c
mono/metadata/sgen-descriptor.c
mono/metadata/sgen-descriptor.h
mono/metadata/sgen-fin-weak-hash.c
mono/metadata/sgen-gc.c
mono/metadata/sgen-gc.h
mono/metadata/sgen-gray.c
mono/metadata/sgen-gray.h
mono/metadata/sgen-hash-table.c
mono/metadata/sgen-internal.c
mono/metadata/sgen-los.c
mono/metadata/sgen-major-copy-object.h
mono/metadata/sgen-major-copying.c
mono/metadata/sgen-major-scan-object.h
mono/metadata/sgen-marksweep.c
mono/metadata/sgen-minor-copy-object.h [new file with mode: 0644]
mono/metadata/sgen-minor-scan-object.h [new file with mode: 0644]
mono/metadata/sgen-nursery-allocator.c
mono/metadata/sgen-os-mach.c
mono/metadata/sgen-os-posix.c
mono/metadata/sgen-os-win32.c
mono/metadata/sgen-pinned-allocator.c
mono/metadata/sgen-pinning-stats.c
mono/metadata/sgen-pinning.c
mono/metadata/sgen-pinning.h
mono/metadata/sgen-protocol.c
mono/metadata/sgen-simple-nursery.c [new file with mode: 0644]
mono/metadata/sgen-split-nursery.c [new file with mode: 0644]
mono/metadata/sgen-ssb.c
mono/metadata/sgen-ssb.h
mono/metadata/sgen-toggleref.c
mono/metadata/sgen-workers.c
mono/metadata/sgen-workers.h
mono/metadata/threadpool-internals.h
mono/metadata/threadpool.c
mono/metadata/threads-types.h
mono/metadata/threads.c
mono/metadata/verify.c
mono/mini/Makefile.am
mono/mini/aot-compiler.c
mono/mini/aot-runtime.c
mono/mini/cpu-s390x.md
mono/mini/debugger-agent.c
mono/mini/driver.c
mono/mini/image-writer.c
mono/mini/method-to-ir.c
mono/mini/mini-amd64.c
mono/mini/mini-arm.c
mono/mini/mini-codegen.c
mono/mini/mini-darwin.c
mono/mini/mini-exceptions.c
mono/mini/mini-llvm.c
mono/mini/mini-llvm.h
mono/mini/mini-s390x.c
mono/mini/mini-unwind.h
mono/mini/mini-x86.c
mono/mini/mini-x86.h
mono/mini/mini.c
mono/mini/unwind.c
mono/profiler/.gitignore
mono/profiler/proflog.c
mono/tests/Makefile.am
mono/tests/bug-3903.cs [new file with mode: 0644]
mono/tests/cominterop.cs
mono/tests/finalizer-exception.cs
mono/tests/finalizer-thread.cs [new file with mode: 0644]
mono/tests/gc-altstack.cs
mono/tests/libtest.c
mono/tests/mono-path.cs [new file with mode: 0644]
mono/tests/pinvoke2.cs
mono/tests/thread6.cs
mono/utils/mono-path.c
mono/utils/mono-threads-windows.c
mono/utils/strtod.c
msvc/scripts/genproj.cs
msvc/scripts/order.xml
msvc/test_eglib.vcxproj
scripts/Makefile.am
scripts/patch-quiet.sh
scripts/update_submodules [new file with mode: 0755]
tools/locale-builder/.gitignore
tools/locale-builder/CLDR/.gitignore [new file with mode: 0644]
tools/locale-builder/CLDR/README.txt [new file with mode: 0644]
tools/locale-builder/CalendarType.cs [new file with mode: 0644]
tools/locale-builder/Constants.cs [new file with mode: 0644]
tools/locale-builder/CultureInfoEntry.cs
tools/locale-builder/DateTimeFormatEntry.cs
tools/locale-builder/Driver.cs
tools/locale-builder/Entry.cs
tools/locale-builder/Makefile.am
tools/locale-builder/NumberFormatEntry.cs
tools/locale-builder/Patterns.cs [new file with mode: 0644]
tools/locale-builder/README
tools/locale-builder/RegionInfoEntry.cs
tools/locale-builder/TextInfoEntry.cs
tools/locale-builder/langs/.gitattributes [deleted file]
tools/locale-builder/langs/.gitignore [deleted file]
tools/locale-builder/langs/ka.xml [deleted file]
tools/locale-builder/langs/nb.xml [deleted file]
tools/locale-builder/langs/nn.xml [deleted file]
tools/locale-builder/lcids.xml [changed mode: 0755->0644]
tools/locale-builder/locale-builder.csproj [new file with mode: 0644]
tools/locale-builder/locales/.gitattributes [deleted file]
tools/locale-builder/locales/.gitignore [deleted file]
tools/locale-builder/locales/ka_GE.xml [deleted file]
tools/locale-builder/locales/nb_NO.xml [deleted file]
tools/locale-builder/locales/nn_NO.xml [deleted file]
tools/locale-builder/supp/ChangeLog [deleted file]
tools/locale-builder/supp/af_ZA.xml [deleted file]
tools/locale-builder/supp/ar.xml [deleted file]
tools/locale-builder/supp/ar_AE.xml [deleted file]
tools/locale-builder/supp/ar_BH.xml [deleted file]
tools/locale-builder/supp/ar_DZ.xml [deleted file]
tools/locale-builder/supp/ar_EG.xml [deleted file]
tools/locale-builder/supp/ar_IQ.xml [deleted file]
tools/locale-builder/supp/ar_JO.xml [deleted file]
tools/locale-builder/supp/ar_KW.xml [deleted file]
tools/locale-builder/supp/ar_LB.xml [deleted file]
tools/locale-builder/supp/ar_LY.xml [deleted file]
tools/locale-builder/supp/ar_MA.xml [deleted file]
tools/locale-builder/supp/ar_OM.xml [deleted file]
tools/locale-builder/supp/ar_QA.xml [deleted file]
tools/locale-builder/supp/ar_SA.xml [deleted file]
tools/locale-builder/supp/ar_SY.xml [deleted file]
tools/locale-builder/supp/ar_TN.xml [deleted file]
tools/locale-builder/supp/ar_YE.xml [deleted file]
tools/locale-builder/supp/be_BY.xml [deleted file]
tools/locale-builder/supp/bg.xml [deleted file]
tools/locale-builder/supp/ca_ES.xml [deleted file]
tools/locale-builder/supp/cs_CZ.xml [deleted file]
tools/locale-builder/supp/da.xml [deleted file]
tools/locale-builder/supp/de.xml [deleted file]
tools/locale-builder/supp/de_AT.xml [deleted file]
tools/locale-builder/supp/el.xml [deleted file]
tools/locale-builder/supp/en.xml [deleted file]
tools/locale-builder/supp/en_AU.xml [deleted file]
tools/locale-builder/supp/en_CA.xml [deleted file]
tools/locale-builder/supp/en_GB.xml [deleted file]
tools/locale-builder/supp/en_IE.xml [deleted file]
tools/locale-builder/supp/en_NZ.xml [deleted file]
tools/locale-builder/supp/en_PH.xml [deleted file]
tools/locale-builder/supp/en_TT.xml [deleted file]
tools/locale-builder/supp/en_US.xml [deleted file]
tools/locale-builder/supp/en_ZA.xml [deleted file]
tools/locale-builder/supp/en_ZW.xml [deleted file]
tools/locale-builder/supp/es.xml [deleted file]
tools/locale-builder/supp/es_AR.xml [deleted file]
tools/locale-builder/supp/es_BO.xml [deleted file]
tools/locale-builder/supp/es_CL.xml [deleted file]
tools/locale-builder/supp/es_CO.xml [deleted file]
tools/locale-builder/supp/es_CR.xml [deleted file]
tools/locale-builder/supp/es_DO.xml [deleted file]
tools/locale-builder/supp/es_EC.xml [deleted file]
tools/locale-builder/supp/es_ES.xml [deleted file]
tools/locale-builder/supp/es_GT.xml [deleted file]
tools/locale-builder/supp/es_HN.xml [deleted file]
tools/locale-builder/supp/es_MX.xml [deleted file]
tools/locale-builder/supp/es_NI.xml [deleted file]
tools/locale-builder/supp/es_PA.xml [deleted file]
tools/locale-builder/supp/es_PE.xml [deleted file]
tools/locale-builder/supp/es_PR.xml [deleted file]
tools/locale-builder/supp/es_PY.xml [deleted file]
tools/locale-builder/supp/es_SV.xml [deleted file]
tools/locale-builder/supp/es_UY.xml [deleted file]
tools/locale-builder/supp/es_VE.xml [deleted file]
tools/locale-builder/supp/et.xml [deleted file]
tools/locale-builder/supp/eu_ES.xml [deleted file]
tools/locale-builder/supp/fa.xml [deleted file]
tools/locale-builder/supp/fi.xml [deleted file]
tools/locale-builder/supp/fo_FO.xml [deleted file]
tools/locale-builder/supp/fr.xml [deleted file]
tools/locale-builder/supp/fr_BE.xml [deleted file]
tools/locale-builder/supp/fr_CA.xml [deleted file]
tools/locale-builder/supp/fr_CH.xml [deleted file]
tools/locale-builder/supp/fr_FR.xml [deleted file]
tools/locale-builder/supp/fr_LU.xml [deleted file]
tools/locale-builder/supp/he.xml [deleted file]
tools/locale-builder/supp/hi_IN.xml [deleted file]
tools/locale-builder/supp/hr.xml [deleted file]
tools/locale-builder/supp/hu.xml [deleted file]
tools/locale-builder/supp/hy.xml [deleted file]
tools/locale-builder/supp/id_ID.xml [deleted file]
tools/locale-builder/supp/is.xml [deleted file]
tools/locale-builder/supp/it_CH.xml [deleted file]
tools/locale-builder/supp/it_IT.xml [deleted file]
tools/locale-builder/supp/ja.xml [deleted file]
tools/locale-builder/supp/ka_GE.xml [deleted file]
tools/locale-builder/supp/ko_KR.xml [deleted file]
tools/locale-builder/supp/lt_LT.xml [deleted file]
tools/locale-builder/supp/lv.xml [deleted file]
tools/locale-builder/supp/mk.xml [deleted file]
tools/locale-builder/supp/nl_BE.xml [deleted file]
tools/locale-builder/supp/nl_NL.xml [deleted file]
tools/locale-builder/supp/pl.xml [deleted file]
tools/locale-builder/supp/pt.xml [deleted file]
tools/locale-builder/supp/pt_BR.xml [deleted file]
tools/locale-builder/supp/pt_PT.xml [deleted file]
tools/locale-builder/supp/ro.xml [deleted file]
tools/locale-builder/supp/root.xml [deleted file]
tools/locale-builder/supp/ru.xml [deleted file]
tools/locale-builder/supp/sk.xml [deleted file]
tools/locale-builder/supp/sl.xml [deleted file]
tools/locale-builder/supp/sq.xml [deleted file]
tools/locale-builder/supp/sv_FI.xml [deleted file]
tools/locale-builder/supp/sv_SE.xml [deleted file]
tools/locale-builder/supp/sw_KE.xml [deleted file]
tools/locale-builder/supp/th.xml [deleted file]
tools/locale-builder/supp/tr.xml [deleted file]
tools/locale-builder/supp/uk.xml [deleted file]
tools/locale-builder/supp/vi.xml [deleted file]
tools/locale-builder/supplementalData.xml [deleted file]
tools/locale-builder/tests/test-culture.cs [new file with mode: 0644]
tools/locale-builder/textinfo.xml [deleted file]

diff --git a/.gitmodules b/.gitmodules
new file mode 100644 (file)
index 0000000..aeab4b9
--- /dev/null
@@ -0,0 +1,9 @@
+[submodule "external/aspnetwebstack"]
+       path = external/aspnetwebstack
+       url = git://github.com/mono/aspnetwebstack.git
+[submodule "external/Newtonsoft.Json"]
+       path = external/Newtonsoft.Json
+       url = git://github.com/mono/Newtonsoft.Json.git
+[submodule "external/cecil"]
+       path = external/cecil
+       url = git://github.com/mono/cecil.git
diff --git a/LICENSE b/LICENSE
index f8b52eb4f7f3c13d6ec88940bc75fd5d83466de6..0c52cc7dc9580339505658e89441c8d48e7cdf82 100644 (file)
--- a/LICENSE
+++ b/LICENSE
@@ -8,8 +8,8 @@ For comments, corrections and updates, please contact mono@xamarin.com
 
        Parts of Mono are dual licensed, they are available to the
        public in GPL or LGPL forms, but we also offer those pieces
-       under commercial terms from Novell for when the GPL and the
-       LGPL are not suitable.
+       under commercial terms from Xamarin for the cases wher the GPL
+       and the LGPL are not suitable.
 
        We have tried to pick the licenses that will maximize adoption
        of Mono, so we tend to use the MIT X11 or LGPL liceses.
@@ -22,6 +22,9 @@ For comments, corrections and updates, please contact mono@xamarin.com
        Contributions for other modules should be under the same license
        terms as the rest of the module, or under MIT X11 terms. 
 
+       For the actual license links in the Mono distribution see the
+       bottom of this file.
+
        If you need further information, please contact mono@xamarin.com
 
 * The Modules
@@ -31,7 +34,7 @@ For comments, corrections and updates, please contact mono@xamarin.com
        This code is dual licensed under the LGPL or commercial licenses. 
 
        The LGPL ensures that Mono can be used in most scenarios, but
-       gives Novell the flexibility to relicense the code for
+       gives Xamarin the flexibility to relicense the code for
        embedded systems, static linking or commercial settings where
        the LGPL can not be used.
 
@@ -39,7 +42,7 @@ For comments, corrections and updates, please contact mono@xamarin.com
        embedded system where the end user is not able to upgrade the
        Mono VM or Moonlight installation or distribution that is part
        of your product (Section 6 and 7), you would have to obtain a
-       commercial license from Novell (consider software burned into
+       commercial license from Xamarin (consider software burned into
        a ROM, systems where end users would not be able to upgrade,
        an embedded console, a game console that imposes limitations
        on the distribution and access to the code, a phone platform
index a68090098d93a27963c56aeeac3d71ef4a96aa6c..eef2c3800e13d7ee5d8401d60ca5aa125c01f0fc 100644 (file)
@@ -18,6 +18,14 @@ DIST_SUBDIRS = m4 po libgc eglib mono ikvm-native support data runtime scripts m
 endif
 endif
 
+all: update_submodules
+
+SUBMODULE_ERROR='Could not recursively update all git submodules. You may experience compilation problems if some submodules are out of date'
+update_submodules:
+       @$(srcdir)/scripts/update_submodules
+
+.PHONY: update_submodules
+
 EXTRA_DIST= \
            LICENSE \
            autogen.sh \
@@ -25,7 +33,8 @@ EXTRA_DIST= \
            mkinstalldirs \
            mono-uninstalled.pc.in \
            winconfig.h \
-           mono-core.spec
+           mono-core.spec \
+           external
 
 DISTCHECK_CONFIGURE_FLAGS = EXTERNAL_MCS=false EXTERNAL_RUNTIME=false
 
diff --git a/README b/README
index d57aef26d8aa35567e313858ffbb0387adda2173..e39e5bceb5d2107d6f937957d4bdf9a9199e3015 100644 (file)
--- a/README
+++ b/README
@@ -4,6 +4,7 @@ This is Mono.
        1. Installation
        2. Using Mono
        3. Directory Roadmap
+       4. git submodules maintenance
 
 1. Compilation and Installation
 ===============================
@@ -586,3 +587,7 @@ This is Mono.
                same prefix than this module gets.
 
 
+4. Git submodules maintenance
+=============================
+
+Read documentation at http://mono-project.com/Git_Submodule_Maintenance
index c276e939df6c25df244e91150349c2d3a5a27aa9..2c47b2c1939a591400f64928a38bb68870a2bd73 100644 (file)
@@ -1,7 +1,7 @@
 # Process this file with autoconf to produce a configure script.
 #AC_PREREQ([2.62])
 
-AC_INIT(mono, [2.11],
+AC_INIT(mono, [2.11.2],
         [http://bugzilla.xamarin.com/enter_bug.cgi?classification=Mono])
 
 AC_CONFIG_SRCDIR([README])
@@ -419,7 +419,7 @@ AM_ICONV()
 AM_CONDITIONAL(NO_VERSION_SCRIPT, test x$no_version_script = xyes)
 
 AC_CHECK_HEADERS(sys/filio.h sys/sockio.h netdb.h utime.h sys/utime.h semaphore.h sys/un.h linux/rtc.h sys/syscall.h sys/mkdev.h sys/uio.h sys/param.h)
-AC_CHECK_HEADERS(sys/param.h sys/socket.h sys/ipc.h sys/sem.h sys/utsname.h alloca.h ucontext.h pwd.h sys/select.h netinet/tcp.h netinet/in.h unistd.h sys/types.h link.h asm/sigcontext.h)
+AC_CHECK_HEADERS(sys/param.h sys/socket.h sys/ipc.h sys/sem.h sys/utsname.h alloca.h ucontext.h pwd.h sys/select.h netinet/tcp.h netinet/in.h unistd.h sys/types.h link.h asm/sigcontext.h sys/inotify.h)
 AC_CHECK_HEADERS([linux/netlink.h linux/rtnetlink.h],
                   [], [], [#include <stddef.h>
                  #include <sys/socket.h>
@@ -859,6 +859,9 @@ if test "x$mono_feature_disable_shared_perfcounters" = "xyes"; then
        AC_MSG_NOTICE([Disabled Shared perfcounters.])
 fi
 
+AC_ARG_ENABLE(executables, [  --disable-executables disable the build of the runtime executables], enable_executables=$enableval, enable_executables=yes)
+AM_CONDITIONAL(DISABLE_EXECUTABLES, test x$enable_executables = xno)
+
 AC_MSG_CHECKING(for visibility __attribute__)
 AC_COMPILE_IFELSE([
        AC_LANG_SOURCE([[
@@ -1480,12 +1483,11 @@ if test x$target_win32 = xno; then
                                exit (0);
                        }
 
+                       volatile char*__ptr = NULL;
                        static void *
                        loop (void *ignored)
                        {
-                               char *ptr = NULL;
-
-                               *ptr = 0;
+                               *__ptr = 0;
                                return NULL;
                        }
 
@@ -2609,7 +2611,8 @@ case "$host" in
        done
        
        if test "x$X11" = "xlibX11.so"; then
-               AC_MSG_WARN([Could not find X development libs. Do you have the -devel package installed? WinForms may not work...]);
+               AC_MSG_WARN([Could not find X development libs. Do you have the -devel package installed? Assuming libX11.so.6...]);
+               X11=libX11.so.6
        fi
        ;;
 esac
@@ -3133,6 +3136,8 @@ data/system.web.extensions_1.0.pc
 data/system.web.extensions.design_1.0.pc
 data/system.web.mvc.pc
 data/system.web.mvc2.pc
+data/system.web.mvc3.pc
+data/aspnetwebstack.pc
 samples/Makefile
 support/Makefile
 data/config
@@ -3144,6 +3149,9 @@ msvc/Makefile
 po/Makefile
 ])
 
+# Update all submodules recursively to ensure everything is checked out
+$srcdir/scripts/update_submodules
+
 if test x$host_win32 = xyes; then
    # Get rid of 'cyg' prefixes in library names
    sed -e "s/\/cyg\//\/\//" libtool > libtool.new; mv libtool.new libtool; chmod 755 libtool
@@ -3259,7 +3267,6 @@ echo "
        oprofile:      $OPROFILE
        BigArrays:     $enable_big_arrays
        DTrace:        $enable_dtrace
-       Parallel Mark: $enable_parallel_mark
        LLVM Back End: $enable_llvm (dynamically loaded: $enable_loadedllvm)
 
     Libraries:
index 1e256446b0d89cb5225cc763fbb17bd56cc3c487..3688d2692d78dc01485640bf785778fad88e73ff 100644 (file)
@@ -12,7 +12,7 @@ EXTRA_DIST =          \
        mono.pc.in mono-2.pc.in monosgen-2.pc.in mint.pc.in dotnet.pc.in dotnet35.pc.in wcf.pc.in monodoc.pc.in \
        mono-nunit.pc.in mono-cairo.pc.in mono-options.pc.in cecil.pc.in \
        mono-lineeditor.pc.in system.web.extensions_1.0.pc.in system.web.extensions.design_1.0.pc.in\
-       dtrace-prelink.sh mono.web.pc.in system.web.mvc.pc.in system.web.mvc2.pc.in \
+       dtrace-prelink.sh mono.web.pc.in system.web.mvc.pc.in system.web.mvc2.pc.in system.web.mvc3.pc.in aspnetwebstack.pc.in \
        net_1_1/machine.config \
        gdb/mono-gdb.py \
        gdb/gdb-python.diff
@@ -28,17 +28,17 @@ endif
 if JIT_SUPPORTED
 if INTERP_SUPPORTED
 pkgconfig_DATA= mono.pc mono-2.pc mint.pc dotnet.pc dotnet35.pc wcf.pc mono-nunit.pc mono-cairo.pc mono-options.pc cecil.pc monodoc.pc mono-lineeditor.pc system.web.extensions_1.0.pc \
-               system.web.extensions.design_1.0.pc mono.web.pc system.web.mvc.pc system.web.mvc2.pc $(SGENPCFILE)
+               system.web.extensions.design_1.0.pc mono.web.pc system.web.mvc.pc system.web.mvc2.pc system.web.mvc3.pc aspnetwebstack.pc $(SGENPCFILE)
 else
 pkgconfig_DATA= mono.pc mono-2.pc dotnet.pc dotnet35.pc wcf.pc mono-nunit.pc mono-cairo.pc mono-options.pc cecil.pc monodoc.pc mono-lineeditor.pc system.web.extensions_1.0.pc \
-               system.web.extensions.design_1.0.pc mono.web.pc system.web.mvc.pc system.web.mvc2.pc $(SGENPCFILE)
+               system.web.extensions.design_1.0.pc mono.web.pc system.web.mvc.pc system.web.mvc2.pc system.web.mvc3.pc aspnetwebstack.pc $(SGENPCFILE)
 endif
 else
 pkgconfig_DATA= mint.pc mono-nunit.pc mono-cairo.pc mono-options.pc cecil.pc monodoc.pc mono-lineeditor.pc
 endif
 
 DISTCLEANFILES= mono-2.pc mono.pc mint.pc dotnet.pc dotnet35.pc wcf.pc mono-nunit.pc mono-cairo.pc mono-options.pc cecil.pc monodoc.pc mono-lineeditor.pc system.web.extensions_1.0.pc \
-               system.web.extensions.design_1.0.pc mono.web.pc system.web.mvc.pc system.web.mvc2.pc $(SGENPCFILE) mono-sgen-gdb.py
+               system.web.extensions.design_1.0.pc mono.web.pc system.web.mvc.pc system.web.mvc2.pc system.web.mvc3.pc aspnetwebstack.pc $(SGENPCFILE) mono-sgen-gdb.py
 
 mono_DATA =  config \
             browscap.ini
diff --git a/data/aspnetwebstack.pc.in b/data/aspnetwebstack.pc.in
new file mode 100644 (file)
index 0000000..250fdb6
--- /dev/null
@@ -0,0 +1,4 @@
+Name: AspNetWebStack
+Description: References Microsoft ASP.NET Web Stack
+Version: @VERSION@
+Libs: -r:System.Web.Razor.dll -r:System.Web.Http.dll -r:System.Web.WebPages -r:System.Web.WebPages.Razor -r:System.Web.WebPages.Deployment
diff --git a/data/system.web.mvc3.pc.in b/data/system.web.mvc3.pc.in
new file mode 100644 (file)
index 0000000..be94fbe
--- /dev/null
@@ -0,0 +1,4 @@
+Name: System.Web.Mvc3
+Description: System.Web.Mvc - ASP.NET MVC v3
+Version: 3.0.0.0
+Libs: -r:@prefix@/lib/mono/gac/System.Web.Mvc/3.0.0.0__31bf3856ad364e35/System.Web.Mvc.dll
index 4ae2f8f5e9e8863f5e7fe704e3275dd8dd084be8..14343494d80eb5660d5aadd08fcea92814c5b7ac 100644 (file)
@@ -88,6 +88,24 @@ g_build_path (const gchar *separator, const gchar *first_element, ...)
        return g_string_free (path, FALSE);
 }
 
+static gchar*
+strrchr_seperator (const gchar* filename)
+{
+#ifdef G_OS_WIN32
+       char *p2;
+#endif
+       char *p;
+
+       p = strrchr (filename, G_DIR_SEPARATOR);
+#ifdef G_OS_WIN32
+       p2 = strrchr (filename, '/');
+       if (p2 > p)
+               p = p2;
+#endif
+
+       return p;
+}
+
 gchar *
 g_path_get_dirname (const gchar *filename)
 {
@@ -95,7 +113,7 @@ g_path_get_dirname (const gchar *filename)
        size_t count;
        g_return_val_if_fail (filename != NULL, NULL);
 
-       p = strrchr (filename, G_DIR_SEPARATOR);
+       p = strrchr_seperator (filename);
        if (p == NULL)
                return g_strdup (".");
        if (p == filename)
@@ -119,7 +137,7 @@ g_path_get_basename (const char *filename)
                return g_strdup (".");
 
        /* No separator -> filename */
-       r = strrchr (filename, G_DIR_SEPARATOR);
+       r = strrchr_seperator (filename);
        if (r == NULL)
                return g_strdup (filename);
 
@@ -127,7 +145,7 @@ g_path_get_basename (const char *filename)
        if (r [1] == 0){
                char *copy = g_strdup (filename);
                copy [r-filename] = 0;
-               r = strrchr (copy, G_DIR_SEPARATOR);
+               r = strrchr_seperator (copy);
 
                if (r == NULL){
                        g_free (copy);                  
index fccf2651db26b05678dea8a5e4b1472f6d5a0753..0f66a43372e96e0f2ad6db4ac0ec3ef76290ecd6 100644 (file)
@@ -357,6 +357,9 @@ g_strreverse (gchar *str)
        if (str == NULL)
                return NULL;
 
+       if (*str == 0)
+               return str;
+
        for (i = 0, j = strlen (str) - 1; i < j; i++, j--) {
                c = str [i];
                str [i] = str [j];
index dd639ebcadd42721498f49350ac6d6f78ece9bc7..c3a9000f8d225839522e6dfad8a9d8d4e08f82a1 100644 (file)
@@ -52,7 +52,7 @@
 #    endif
 #endif
 
-static char *my_charset;
+static const char *my_charset;
 static gboolean is_utf8;
 
 /*
index aa13ece6f7799c764fd99594d6ba1c58b61e77fa..e3832a04be493815e423203c66616f86418e33db 100644 (file)
@@ -129,15 +129,16 @@ test_buildfname ()
                return FAILED ("1 Got wrong result, got: %s", s);
        g_free (s);
 
-       s = g_build_filename ("/", "a", NULL);
 #ifdef G_OS_WIN32
-       if (strcmp (s, "\\a") != 0)
+       s = g_build_filename ("C:\\", "a", NULL);
+       if (strcmp (s, "C:\\a") != 0)
 #else
+       s = g_build_filename ("/", "a", NULL);
        if (strcmp (s, "/a") != 0)
 #endif
                return FAILED ("1 Got wrong result, got: %s", s);
 
-#ifndef OS_WIN32
+#ifndef G_OS_WIN32
        s = g_build_filename ("/", "foo", "/bar", "tolo/", "/meo/", NULL);
        if (strcmp (s, "/foo/bar/tolo/meo/") != 0)
                return FAILED ("1 Got wrong result, got: %s", s);
@@ -157,6 +158,11 @@ test_dirname ()
                return FAILED ("Expected c:\\home, got %s", s);
        g_free (s);
 
+       s = g_path_get_dirname ("c:/home/miguel");
+       if (strcmp (s, "c:/home") != 0)
+               return FAILED ("Expected c:/home, got %s", s);
+       g_free (s);
+
        s = g_path_get_dirname ("c:\\home\\dingus\\");
        if (strcmp (s, "c:\\home\\dingus") != 0)
                return FAILED ("Expected c:\\home\\dingus, got %s", s);
@@ -209,10 +215,20 @@ test_basename ()
                return FAILED ("1 Expected dingus, got %s", s);
        g_free (s);
 
+       s = g_path_get_basename ("c:/home/dingus/");
+       if (strcmp (s, "dingus") != 0)
+               return FAILED ("1 Expected dingus, got %s", s);
+       g_free (s);
+
        s = g_path_get_basename ("c:\\home\\dingus");
        if (strcmp (s, "dingus") != 0)
                return FAILED ("2 Expected dingus, got %s", s);
        g_free (s);
+
+       s = g_path_get_basename ("c:/home/dingus");
+       if (strcmp (s, "dingus") != 0)
+               return FAILED ("2 Expected dingus, got %s", s);
+       g_free (s);
 #else
        s = g_path_get_basename ("");
        if (strcmp (s, ".") != 0)
index 14d24d6ac772f2933455747c1247f7adb2589eff..6c8b8892e94709c7fb502b03c257e3ce48fb680a 100644 (file)
@@ -296,27 +296,37 @@ test_split_set ()
 RESULT
 test_strreverse ()
 {
+       RESULT res = OK;
        gchar *a = g_strdup ("onetwothree");
        gchar *a_target = "eerhtowteno";
        gchar *b = g_strdup ("onetwothre");
        gchar *b_target = "erhtowteno";
+       gchar *c = g_strdup ("");
+       gchar *c_target = "";
 
        g_strreverse (a);
        if (strcmp (a, a_target)) {
-               g_free (b);
-               g_free (a);
-               return FAILED("strreverse failed. Expecting: '%s' and got '%s'\n", a, a_target);
+               res = FAILED("strreverse failed. Expecting: '%s' and got '%s'\n", a, a_target);
+               goto cleanup;
        }
 
        g_strreverse (b);
        if (strcmp (b, b_target)) {
-               g_free (b);
-               g_free (a);
-               return FAILED("strreverse failed. Expecting: '%s' and got '%s'\n", b, b_target);
+               res = FAILED("strreverse failed. Expecting: '%s' and got '%s'\n", b, b_target);
+               goto cleanup;
        }
+
+       g_strreverse (c);
+       if (strcmp (c, c_target)) {
+               res = FAILED("strreverse failed. Expecting: '%s' and got '%s'\n", b, b_target);
+               goto cleanup;
+       }
+
+cleanup:
+       g_free (c);
        g_free (b);
        g_free (a);
-       return OK;
+       return res;
 }
 
 RESULT
@@ -404,6 +414,8 @@ test_strstrip ()
 RESULT
 test_filename_to_uri ()
 {
+#ifdef G_OS_WIN32
+#else
        char *s;
 
        urit ("/a", "file:///a");
@@ -422,6 +434,7 @@ test_filename_to_uri ()
        urit ("/@ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", "file:///@ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz");
        errit ("a");
        errit ("./hola");
+#endif
        
        return OK;
 }
@@ -433,6 +446,8 @@ test_filename_to_uri ()
 RESULT
 test_filename_from_uri ()
 {
+#ifdef G_OS_WIN32
+#else
        char *s;
 
        fileit ("file:///a", "/a");
@@ -446,6 +461,7 @@ test_filename_from_uri ()
        ferrit ("file:///%");
        ferrit ("file:///%0");
        ferrit ("file:///%jj");
+#endif
        
        return OK;
 }
diff --git a/external/Newtonsoft.Json b/external/Newtonsoft.Json
new file mode 160000 (submodule)
index 0000000..471c3e0
--- /dev/null
@@ -0,0 +1 @@
+Subproject commit 471c3e0803a9f40a0acc8aeceb31de6ff93a52c4
diff --git a/external/aspnetwebstack b/external/aspnetwebstack
new file mode 160000 (submodule)
index 0000000..1836def
--- /dev/null
@@ -0,0 +1 @@
+Subproject commit 1836deff6a2683b8a5b7dd78f2b591a10b47573e
diff --git a/external/cecil b/external/cecil
new file mode 160000 (submodule)
index 0000000..54e0a50
--- /dev/null
@@ -0,0 +1 @@
+Subproject commit 54e0a50464edbc254b39ea3c885ee91ada730705
index 516b12c94c0de5ecb516c5e8d83f67a8470f8504..a1051f5ac4e0e80b1af6af6198d78fa799907766 100644 (file)
@@ -79,7 +79,7 @@ void GC_push_all_stacks() {
   kern_return_t r;
   GC_thread p;
   pthread_t me;
-  ptr_t lo, hi;
+  ptr_t lo, hi, altstack_lo, altstack_hi;
 #if defined(POWERPC)
   ppc_thread_state_t state;
   mach_msg_type_number_t thread_state_count = PPC_THREAD_STATE_COUNT;
@@ -252,6 +252,16 @@ void GC_push_all_stacks() {
        hi = GC_stackbottom;
       else
        hi = p->stack_end;
+
+         if (p->altstack && lo >= p->altstack && lo <= p->altstack + p->altstack_size) {
+                 altstack_lo = lo;
+                 altstack_hi = p->altstack + p->altstack_size;
+                 lo = (char*)p->stack;
+                 hi = (char*)p->stack + p->stack_size;
+         }     else {
+                 altstack_lo = NULL;
+         }
+
 #if DEBUG_THREADS
       GC_printf3("Darwin: Stack for thread 0x%lx = [%lx,%lx)\n",
                 (unsigned long) p -> id,
@@ -259,7 +269,10 @@ void GC_push_all_stacks() {
                 (unsigned long) hi
                 );
 #endif
-      GC_push_all_stack(lo,hi);
+         if (lo)
+                 GC_push_all_stack(lo,hi);
+         if (altstack_lo)
+                 GC_push_all_stack(altstack_lo,altstack_hi);
     } /* for(p=GC_threads[i]...) */
   } /* for(i=0;i<THREAD_TABLE_SZ...) */
 }
index d77de303e0d5e69193214b20d8dabcba1ad847d1..7e5fd2ed84074e0b8ed9badb29d62a8a65cea821 100644 (file)
@@ -841,6 +841,12 @@ GC_API GC_PTR GC_is_valid_displacement GC_PROTO((GC_PTR    p));
 /* Returns 1 if the calling thread is registered with the GC, 0 otherwise */
 GC_API int GC_thread_is_registered GC_PROTO((void));
 
+/* Notify the collector about the stack and the altstack of the current thread */
+/* STACK/STACK_SIZE is used to determine the stack dimensions when a thread is
+ * suspended while it is on an altstack.
+ */
+GC_API void GC_register_altstack GC_PROTO((void *stack, int stack_size, void *altstack, int altstack_size));
+
 /* Safer, but slow, pointer addition.  Probably useful mainly with     */
 /* a preprocessor.  Useful only for heap pointers.                     */
 #ifdef GC_DEBUG
index 076a6d26ff93a912c4d7be62d0210e17f11f1b9d..4046a2666b846d404ddf5edc4aada8945f5a00fd 100644 (file)
@@ -47,6 +47,10 @@ typedef struct GC_Thread_Rep {
                                /* not need to be sent a signal to stop */
                                /* it.                                  */
     ptr_t stack_end;           /* Cold end of the stack.               */
+       ptr_t altstack; /* The start of the altstack if there is one, NULL otherwise */
+       int altstack_size; /* The size of the altstack if there is one */
+       ptr_t stack; /* The start of the normal stack */
+       int stack_size; /* The size of the normal stack */
 #   ifdef IA64
        ptr_t backing_store_end;
        ptr_t backing_store_ptr;
index 3ecc5e9047d994804e0dd3dea4f985942a01e71c..e6ac64b62a8ee24f5a94a1e3040f9e6ae4d6197b 100644 (file)
@@ -290,6 +290,10 @@ static void pthread_push_all_stacks()
                (unsigned long) lo, (unsigned long) hi);
         #endif
        if (0 == lo) ABORT("GC_push_all_stacks: sp not set!\n");
+       if (p->altstack && lo >= p->altstack && lo <= p->altstack + p->altstack_size)
+               hi = p->altstack + p->altstack_size;
+       /* FIXME: Need to scan the normal stack too, but how ? */
+
 #       ifdef STACK_GROWS_UP
          /* We got them backwards! */
           GC_push_all_stack(hi, lo);
index 4b3d825fbc7b4e4f9d4a1f0a37d995385a0199bf..d1f3b129ea8b8540bd64717304340e5a668a308f 100644 (file)
@@ -215,6 +215,10 @@ static int GC_setspecific (GC_key_t key, void *value) {
 
 static GC_bool keys_initialized;
 
+static pthread_t main_pthread_self;
+static void *main_stack, *main_altstack;
+static int main_stack_size, main_altstack_size;
+
 #ifdef MONO_DEBUGGER_SUPPORTED
 #include "include/libgc-mono-debugger.h"
 #endif
@@ -848,6 +852,30 @@ int GC_thread_is_registered (void)
        return ptr ? 1 : 0;
 }
 
+void GC_register_altstack (void *stack, int stack_size, void *altstack, int altstack_size)
+{
+       GC_thread thread;
+
+       LOCK();
+       thread = (void *)GC_lookup_thread(pthread_self());
+       if (thread) {
+               thread->stack = stack;
+               thread->stack_size = stack_size;
+               thread->altstack = altstack;
+               thread->altstack_size = altstack_size;
+       } else {
+               /*
+                * This happens if we are called before GC_thr_init ().
+                */
+               main_pthread_self = pthread_self ();
+               main_stack = stack;
+               main_stack_size = stack_size;
+               main_altstack = altstack;
+               main_altstack_size = altstack_size;
+       }
+       UNLOCK();
+}
+
 #ifdef HANDLE_FORK
 /* Remove all entries from the GC_threads table, except the    */
 /* one for the current thread.  We need to do this in the child        */
@@ -1083,6 +1111,12 @@ void GC_thr_init()
          gc_thread_vtable->thread_created (pthread_self (), &t->stop_info.stack_ptr);
 #     endif
 #endif
+                if (pthread_self () == main_pthread_self) {
+                        t->stack = main_stack;
+                        t->stack_size = main_stack_size;
+                        t->altstack = main_altstack;
+                        t->altstack_size = main_altstack_size;
+                }
 
     GC_stop_init();
 
index a0321b157e4c440ea9eec2395a3c55da86393980..8ca8fa3b3a21323a6480fe54843a5109624c97db 100644 (file)
@@ -648,6 +648,10 @@ int GC_thread_register_foreign (void *base_addr)
        return 0;
 }
 
+void GC_register_altstack (void *stack, int stack_size, void *altstack, int altstack_size)
+{
+}
+
 /* Solaris 2/Intel uses an initial stack size limit slightly bigger than the
    SPARC default of 8 MB.  Account for this to warn only if the user has
    raised the limit beyond the default.
index 9662eb186ceb1f5f69184d47070e08670f309a72..a60363b4d6f7a89833cfc96a5897b6018d2e63c0 100644 (file)
@@ -85,6 +85,10 @@ int GC_thread_is_registered (void)
 #endif
 }
 
+void GC_register_altstack (void *stack, int stack_size, void *altstack, int altstack_size)
+{
+}
+
 /*
  * This may be called from DllMain, and hence operates under unusual
  * constraints.
index 3904feb285e3696ffd98e9e6a2bc212f347c8dbe..fa55e69719e3a75159b445b9c8dcad536849e686 100644 (file)
@@ -1089,6 +1089,22 @@ and leave them untouched. Precise marking reduces floating garbage
 and can speed up nursery collection and allocation rate, it has
 the downside of requiring a significant extra memory per compiled
 method. The right option, unfortunately, requires experimentation.
+.TP
+\fBminor=\fIminor-collector\fR
+Specifies which minor collector to use. Options are 'simple' which
+promotes all objects from the nursery directly to the old generation
+and 'split' which lets object stay longer on the nursery before promoting.
+.TP
+\fBalloc-ratio=\fIratio\fR
+Specifies the ratio of memory from the nursery to be use by the alloc space.
+This only can only be used with the split minor collector.
+Valid values are integers between 1 and 100. Default is 60.
+.TP
+\fBpromotion-age=\fIage\fR
+Specifies the required age of an object must reach inside the nursery before
+been promoted to the old generation. This only can only be used with the
+split minor collector.
+Valid values are integers between 1 and 14. Default is 2.
 .ne
 .RE
 .TP
index 76cdc5efbad87eafc5cf6c0261f812b6e8e64b40..404aa14ef19436d698ad8a398d3beafdcd632ea6 100644 (file)
@@ -6,6 +6,7 @@
 *_test_*.dll.config
 *_test_*.xml
 *.o
+*.resources
 TestResult-*.log
 TestResult-*.xml
 TestResult*.xml
index b9935a42927135136f670b6acddb75052484c100..47af19762128333d947a1198f1a3689b43849a8d 100644 (file)
@@ -11,8 +11,6 @@ ifndef base_prog_config
 base_prog_config := $(wildcard $(base_prog).config)
 endif
 
-executable_CLEAN_FILES = *.exe $(PROGRAM) $(PROGRAM).mdb $(BUILT_SOURCES)
-
 ifeq (cat,$(PLATFORM_CHANGE_SEPARATOR_CMD))
 response = $(sourcefile)
 else
@@ -36,10 +34,10 @@ endif
 the_lib = $(the_libdir)$(base_prog)
 build_lib = $(build_libdir)$(base_prog)
 
+executable_CLEAN_FILES += $(the_lib)   $(the_lib).so   $(the_lib).mdb   $(the_lib:.exe=.pdb)
+executable_CLEAN_FILES += $(build_lib) $(build_lib).so $(build_lib).mdb $(build_lib:.exe=.pdb)
+
 makefrag = $(depsdir)/$(PROFILE)_$(base_prog).makefrag
-pdb = $(patsubst %.exe,%.pdb,$(PROGRAM))
-mdb = $(patsubst %.exe,%.mdb,$(PROGRAM))
-executable_CLEAN_FILES += $(makefrag) $(pdb) $(mdb)
 
 all-local: $(the_lib) $(PROGRAM_config)
 
index ed75e91b9ccfbd321c2dab49ad8f31d43a7de3d7..b96a8ca24cce70188ff9f8bac4b03225b4d63a2c 100644 (file)
@@ -30,7 +30,7 @@ endif
 
 USE_MCS_FLAGS = /codepage:$(CODEPAGE) $(LOCAL_MCS_FLAGS) $(PLATFORM_MCS_FLAGS) $(PROFILE_MCS_FLAGS) $(MCS_FLAGS)
 USE_MBAS_FLAGS = /codepage:$(CODEPAGE) $(LOCAL_MBAS_FLAGS) $(PLATFORM_MBAS_FLAGS) $(PROFILE_MBAS_FLAGS) $(MBAS_FLAGS)
-USE_CFLAGS = $(LOCAL_CFLAGS) $(CFLAGS)
+USE_CFLAGS = $(LOCAL_CFLAGS) $(CFLAGS) $(CPPFLAGS)
 CSCOMPILE = $(Q_MCS) $(MCS) $(USE_MCS_FLAGS)
 BASCOMPILE = $(MBAS) $(USE_MBAS_FLAGS)
 CCOMPILE = $(CC) $(USE_CFLAGS)
index 2b273818ac7d87205cba5b27781f0adda1ecdcbc..1d2a512447d401388f5a48aa7585e86384bb7f36 100644 (file)
@@ -93,7 +93,7 @@ run-test-ondotnet-lib: test-local
        ok=:; \
        $(TEST_HARNESS) $(test_assemblies) -noshadow $(TEST_HARNESS_FLAGS) $(LOCAL_TEST_HARNESS_ONDOTNET_FLAGS) $(TEST_HARNESS_EXCLUDES_ONDOTNET) $(TEST_HARNESS_OUTPUT_ONDOTNET) -xml=TestResult-ondotnet-$(PROFILE).xml $(FIXTURE_ARG) $(TESTNAME_ARG) || ok=false; \
        $(TEST_HARNESS_POSTPROC_ONDOTNET) ; $$ok
-       
+
 
 endif # test_assemblies
 
@@ -106,7 +106,7 @@ endif
 ifdef HAVE_CS_TESTS
 
 $(test_lib): $(the_assembly) $(test_response) $(test_nunit_dep)
-       $(TEST_COMPILE) -target:library -out:$@ $(test_flags) $(LOCAL_TEST_COMPILER_ONDOTNET_FLAGS) @$(test_response)
+       $(TEST_COMPILE) $(LIBRARY_FLAGS) -target:library -out:$@ $(test_flags) $(LOCAL_TEST_COMPILER_ONDOTNET_FLAGS) @$(test_response)
 
 $(test_response): $(test_sourcefile)
 #      @echo Creating $@ ...
index 2b7767cfd38aefaf7d4f9784b48c0a9d4ea13e56..c153e5f592721d7f7b186728892ab2bae3345804 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2daa9a8885abac6f34c5b19ea296f46e6419902e..bf3f1656fa48cc9ab32826d8901d2f1ceae1973e 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a4fa3073bf6e5be0ef3e9dd4ead67075caf43ae1..217d37e67f2cf09790fa5b77eeb2551ecc4d914a 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f156c679d75a22fecd6e83582f3705d2ecec3076..a1f5aee0071a3c3287f37e4298e6f69dd0f2c61b 100644 (file)
@@ -91,7 +91,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e30cf11fdfa2c4ca707e729d9b885e0404bafa6e..88f9073cd8ecfc20361dcb08b9dd0c6352f88121 100644 (file)
@@ -91,7 +91,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d996250be6e08e399766bac099e19bf683e9fe97..c191fd8b39564ae5d770a2718c73887c6950d63e 100644 (file)
@@ -91,7 +91,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 85320cdeacb33b06270c9f0cc02d5ee2db62018f..1fc978eb0f83011483163f71278cbb864638985e 100644 (file)
@@ -59,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e7fff30824928c548d2909adb67e09efd96ab5f4..73ca4a36256fd52c7d549aaab83bfc8f41d3794e 100644 (file)
@@ -59,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a92400b2591d242f0b8454132a21521ccdea91f1..976484b5ebc2c76f93b5e093fd2d57d6f553b029 100644 (file)
@@ -59,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 856fb3b50ee9d63331b4c5ff49df6517652cee4f..c31c0be9325a33774ff6e912db76873293ac5dda 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0d4aa0fe45de1c6a000e08e5b0d01f31f25975e9..7d9f54ace1161271dc7725e5bbb8ebeb97b67cd7 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4e2de7e399d8ec012b784a0bb5070e4bace56aa2..a537276cc45af62c0aa37376229c0ac5e9bb2073 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4843558e55a5170ed49ba20c565f9ed54c0bddfe..f5b301a07191591398fa31d1a232a29356c33b82 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 09e7d2dc00679c91ee7bdcf1075d68c6f641aebb..904e9336fc4b724ee69c932f2114cfb8d882b091 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index dba9c146e6baa46fbe5b1aff73806d4dcb40c6f9..c713a2e461880e68c245041f7538d792be9bbe8c 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f8fc637a365435bc9e9f227b206f1d172b48c00e..a7dd708c2d2e0c10cc3f6db9533c7efe894463d2 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 62f6e318d5ced2e66d9f3b954944e7f5ed899699..c7194ce303e3116949cf5e6a1bd2bce16639f316 100644 (file)
@@ -59,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index dc73214d0ab3ec21f080dabfbea73f6a592c56fe..610c807f3e0c2b13b32962415086e389798e1043 100644 (file)
@@ -59,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 691519316c4d9ed7b5fe95b9ad0d0421302dd8ce..f3060cf4f83b9639186d74390190b3deb72f780c 100644 (file)
@@ -59,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e8e8d1d85eb26ffa36158b5f084557560439cbe7..608fe018f2844a10ba2a3207ea2d03fec0e3aaae 100644 (file)
@@ -65,7 +65,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d1de303c87808e9d31fdaf20a2c8b02b2eccc418..aa325739f7122044466f4c354223740e148f9a1e 100644 (file)
@@ -65,7 +65,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3afba33419fa1ced20617ea3035176ad27024427..48ea4bacb69b79421cf55f81ac20f403e244be76 100644 (file)
@@ -65,7 +65,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index aefcff129d965402def14e5bdf4bb7df182abfac..b56d091c9f5cc9b6b673d1a2764203c1a8616025 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2eadb406dd3918e355c0e1b6d8ac0d92d308f430..f0bf018add4544bf83cd7d998df4e2826813af17 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9e0fc06b913a743922a23029c3d2070328994601..c1c89e5d6311f9d6adc7feb0c6825f81335bdc62 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b49412622f9a6ed9800202b916da084edab677e3..a25e07b21a6f54b4a4ea04ffdbc1af0dbf4dedb6 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a6778a938b90bfcbb6e52fd7a127f5d6148555ac..e236af402bcdd98e2bd29bd376389409a1a26a22 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 41bfe0c9dc62fdb6ad07fefbbb545ded0524b9a1..2ae7ae2e32d718e2963478bf0bb40ddf9c37ba82 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4c87a143a116c1c15aafa95dc879e401004d2919..abc254af27d9238215a9f76605a45860de5d7e07 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 72324d15e7b012c8980f4b229201662e5b6e345c..5e4bc107943d71de18189ce6b98a639e5825d855 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9e65a4e6f1b6979679d13a4a1ebfcd161e1b5bbc..5bcb5c99e6edcc9ba11631e04fdd54ccc10d40c3 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4e9768222d63a76729dc5f39a48aa993e7d89678..27994c37e0c08fc07b1f82f8e199bd44481092da 100644 (file)
@@ -62,7 +62,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ed4defd5da395ab3899a20e8c711bdda73d0a479..857e12193ac60e3849dce86df200c8fb950a3c16 100644 (file)
@@ -62,7 +62,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e68f7501e74c585f59cd0f61af6d67f2b7ed3f77..626baa3d0f391136027625ed4574e70ac7af8c00 100644 (file)
@@ -62,7 +62,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 878bff121d2ada9f5a986d422fba4af0289ac231..9d23b6edf08d228e691753797ef5caf42c1c5f4e 100644 (file)
@@ -90,7 +90,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 6911cd82e6070bbf82b67e9896be9b1a71868b26..1aa95ada5ca8492e2ac43108cac5ac13fcb854f7 100644 (file)
@@ -90,7 +90,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9b1baeccc38d2c27b4ea8073bc2186f9b0657735..2104d5dfda85c6991c8295777b76f1829e5de5b7 100644 (file)
@@ -90,7 +90,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9d29c0e43b7fbf8a7814e9d6b7474c3c18d99d4b..77c6fc0a002d4e32b50ed2732ffc3c4b77f038a0 100644 (file)
@@ -68,7 +68,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4896ae45d497ed618b2e4b6429eaeafc97ae4f24..96f50a0ef667d47c3de2928be7459a38d4ded40a 100644 (file)
@@ -68,7 +68,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index deb98b18b579b00fa328c24eacb36925e3ff2f98..774f9a311dca499596df573b177af7c36c98ed6f 100644 (file)
@@ -68,7 +68,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b7cb1d360323bea9ca8b67623bbf4de257fcd612..563092bd093f1b9881ce18bb2d0b542b727e3103 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e36ea9dfdc95727ee16436ae20442c56aea4a5b7..3fd8ba968ac2bc018e2420d2400aa0f914fa6c6d 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 895f241a5f3e2a27042398635a6faa6eba2f693e..2244d0511c3c457e61db6ff3b74b090203b7ba4e 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2f6a8f02874ec377b892fdda51b4492c2c0f9391..6a3de8eabb1fcbb323c9f80a8bc55dedc196192e 100644 (file)
@@ -76,7 +76,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 55d20367c8010b8b7e76d219d4507a114f8c3439..81d70f029bff643c26bd076fc7b40151b8c51fb2 100644 (file)
@@ -76,7 +76,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e37a5759a0557148978a9d1ec0ac8c674783002d..308e6738012cb3bb7072df2fa09d52cd3806df9a 100644 (file)
@@ -76,7 +76,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 82ee9b2945aad67f1fb314900d90d0c0fa9bcff0..1073c8b41be3f4d297effed8afbf398825029879 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index bf99a2395b142a182a2d00c0e0116a8b0871ef34..4f4cfd40ccac4a190a3f5ef52804bfcd0c918cab 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2129c8e720bc8f44617861f79a7d675a4da798fb..d271c046339a2d86bed4950954e0f70de62d0303 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2020410b67207a03fd1b6c569b851a873a772488..6a56f3941784ac1629ed4b0fb4ddc85d4b648a0c 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -48,19 +48,10 @@ namespace IKVM.Reflection
                public abstract Module GetModule(string name);
                public abstract string[] GetManifestResourceNames();
                public abstract ManifestResourceInfo GetManifestResourceInfo(string resourceName);
-               public abstract System.IO.Stream GetManifestResourceStream(string resourceName);
-
-               internal Type GetTypeImpl(string typeName)
-               {
-                       Type type = FindType(TypeName.Split(TypeNameParser.Unescape(typeName)));
-                       if (type == null && __IsMissing)
-                       {
-                               throw new MissingAssemblyException((MissingAssembly)this);
-                       }
-                       return type;
-               }
+               public abstract System.IO.Stream GetManifestResourceStream(string name);
 
                internal abstract Type FindType(TypeName name);
+               internal abstract Type FindTypeIgnoreCase(TypeName lowerCaseName);
 
                // The differences between ResolveType and FindType are:
                // - ResolveType is only used when a type is assumed to exist (because another module's metadata claims it)
@@ -108,14 +99,19 @@ namespace IKVM.Reflection
                        return list.ToArray();
                }
 
-               public Type GetType(string typeName)
+               public Type GetType(string name)
                {
-                       return GetType(typeName, false);
+                       return GetType(name, false);
                }
 
-               public Type GetType(string typeName, bool throwOnError)
+               public Type GetType(string name, bool throwOnError)
                {
-                       TypeNameParser parser = TypeNameParser.Parse(typeName, throwOnError);
+                       return GetType(name, throwOnError, false);
+               }
+
+               public Type GetType(string name, bool throwOnError, bool ignoreCase)
+               {
+                       TypeNameParser parser = TypeNameParser.Parse(name, throwOnError);
                        if (parser.Error)
                        {
                                return null;
@@ -131,7 +127,15 @@ namespace IKVM.Reflection
                                        return null;
                                }
                        }
-                       return parser.Expand(GetTypeImpl(parser.FirstNamePart), this, throwOnError, typeName, false);
+                       TypeName typeName = TypeName.Split(TypeNameParser.Unescape(parser.FirstNamePart));
+                       Type type = ignoreCase
+                               ? FindTypeIgnoreCase(typeName.ToLowerInvariant())
+                               : FindType(typeName);
+                       if (type == null && __IsMissing)
+                       {
+                               throw new MissingAssemblyException((MissingAssembly)this);
+                       }
+                       return parser.Expand(type, this, throwOnError, name, false, ignoreCase);
                }
 
                public virtual Module LoadModule(string moduleName, byte[] rawModule)
index 1307f00de18726d0099072b6cc9ec05e22d1e225..a0794512e1457f1ef15c1a413fc60b33450fd8a0 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2010 Jeroen Frijters
+  Copyright (C) 2010-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -30,14 +30,376 @@ namespace IKVM.Reflection
        {
                protected Binder()
                {
-                       throw new NotSupportedException();
                }
 
-               public abstract MethodBase BindToMethod(BindingFlags bindingAttr, MethodBase[] match, ref object[] args, ParameterModifier[] modifiers, CultureInfo culture, string[] names, out object state);
-               public abstract FieldInfo BindToField(BindingFlags bindingAttr, FieldInfo[] match, object value, CultureInfo culture);
-               public abstract object ChangeType(object value, Type type, CultureInfo culture);
-               public abstract void ReorderArgumentArray(ref object[] args, object state);
+               public virtual MethodBase BindToMethod(BindingFlags bindingAttr, MethodBase[] match, ref object[] args, ParameterModifier[] modifiers, CultureInfo culture, string[] names, out object state)
+               {
+                       throw new InvalidOperationException();
+               }
+
+               public virtual FieldInfo BindToField(BindingFlags bindingAttr, FieldInfo[] match, object value, CultureInfo culture)
+               {
+                       throw new InvalidOperationException();
+               }
+
+               public virtual object ChangeType(object value, Type type, CultureInfo culture)
+               {
+                       throw new InvalidOperationException();
+               }
+
+               public virtual void ReorderArgumentArray(ref object[] args, object state)
+               {
+                       throw new InvalidOperationException();
+               }
+
                public abstract MethodBase SelectMethod(BindingFlags bindingAttr, MethodBase[] match, Type[] types, ParameterModifier[] modifiers);
                public abstract PropertyInfo SelectProperty(BindingFlags bindingAttr, PropertyInfo[] match, Type returnType, Type[] indexes, ParameterModifier[] modifiers);
        }
+
+       sealed class DefaultBinder : Binder
+       {
+               public override MethodBase SelectMethod(BindingFlags bindingAttr, MethodBase[] match, Type[] types, ParameterModifier[] modifiers)
+               {
+                       int matchCount = 0;
+                       foreach (MethodBase method in match)
+                       {
+                               if (MatchParameterTypes(method.GetParameters(), types))
+                               {
+                                       match[matchCount++] = method;
+                               }
+                       }
+
+                       if (matchCount == 0)
+                       {
+                               return null;
+                       }
+
+                       if (matchCount == 1)
+                       {
+                               return match[0];
+                       }
+
+                       MethodBase bestMatch = match[0];
+                       bool ambiguous = false;
+                       for (int i = 1; i < matchCount; i++)
+                       {
+                               bestMatch = SelectBestMatch(bestMatch, match[i], types, ref ambiguous);
+                       }
+                       if (ambiguous)
+                       {
+                               throw new AmbiguousMatchException();
+                       }
+                       return bestMatch;
+               }
+
+               private static bool MatchParameterTypes(ParameterInfo[] parameters, Type[] types)
+               {
+                       if (parameters.Length != types.Length)
+                       {
+                               return false;
+                       }
+                       for (int i = 0; i < parameters.Length; i++)
+                       {
+                               Type sourceType = types[i];
+                               Type targetType = parameters[i].ParameterType;
+                               if (sourceType != targetType
+                                       && !targetType.IsAssignableFrom(sourceType)
+                                       && !IsAllowedPrimitiveConversion(sourceType, targetType))
+                               {
+                                       return false;
+                               }
+                       }
+                       return true;
+               }
+
+               private static MethodBase SelectBestMatch(MethodBase mb1, MethodBase mb2, Type[] types, ref bool ambiguous)
+               {
+                       switch (MatchSignatures(mb1.MethodSignature, mb2.MethodSignature, types))
+                       {
+                               case 1:
+                                       return mb1;
+                               case 2:
+                                       return mb2;
+                       }
+
+                       if (mb1.MethodSignature.MatchParameterTypes(mb2.MethodSignature))
+                       {
+                               int depth1 = GetInheritanceDepth(mb1.DeclaringType);
+                               int depth2 = GetInheritanceDepth(mb2.DeclaringType);
+                               if (depth1 > depth2)
+                               {
+                                       return mb1;
+                               }
+                               else if (depth1 < depth2)
+                               {
+                                       return mb2;
+                               }
+                       }
+
+                       ambiguous = true;
+                       return mb1;
+               }
+
+               private static int GetInheritanceDepth(Type type)
+               {
+                       int depth = 0;
+                       while (type != null)
+                       {
+                               depth++;
+                               type = type.BaseType;
+                       }
+                       return depth;
+               }
+
+               private static int MatchSignatures(MethodSignature sig1, MethodSignature sig2, Type[] types)
+               {
+                       for (int i = 0; i < sig1.GetParameterCount(); i++)
+                       {
+                               Type type1 = sig1.GetParameterType(i);
+                               Type type2 = sig2.GetParameterType(i);
+                               if (type1 != type2)
+                               {
+                                       return MatchTypes(type1, type2, types[i]);
+                               }
+                       }
+                       return 0;
+               }
+
+               private static int MatchSignatures(PropertySignature sig1, PropertySignature sig2, Type[] types)
+               {
+                       for (int i = 0; i < sig1.ParameterCount; i++)
+                       {
+                               Type type1 = sig1.GetParameter(i);
+                               Type type2 = sig2.GetParameter(i);
+                               if (type1 != type2)
+                               {
+                                       return MatchTypes(type1, type2, types[i]);
+                               }
+                       }
+                       return 0;
+               }
+
+               private static int MatchTypes(Type type1, Type type2, Type type)
+               {
+                       if (type1 == type)
+                       {
+                               return 1;
+                       }
+                       if (type2 == type)
+                       {
+                               return 2;
+                       }
+                       bool conv = type1.IsAssignableFrom(type2);
+                       return conv == type2.IsAssignableFrom(type1) ? 0 : conv ? 2 : 1;
+               }
+
+               private static bool IsAllowedPrimitiveConversion(Type source, Type target)
+               {
+                       // we need to check for primitives, because GetTypeCode will return the underlying type for enums
+                       if (!source.IsPrimitive || !target.IsPrimitive)
+                       {
+                               return false;
+                       }
+                       TypeCode sourceType = Type.GetTypeCode(source);
+                       TypeCode targetType = Type.GetTypeCode(target);
+                       switch (sourceType)
+                       {
+                               case TypeCode.Char:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.UInt16:
+                                               case TypeCode.UInt32:
+                                               case TypeCode.Int32:
+                                               case TypeCode.UInt64:
+                                               case TypeCode.Int64:
+                                               case TypeCode.Single:
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               case TypeCode.Byte:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.Char:
+                                               case TypeCode.UInt16:
+                                               case TypeCode.Int16:
+                                               case TypeCode.UInt32:
+                                               case TypeCode.Int32:
+                                               case TypeCode.UInt64:
+                                               case TypeCode.Int64:
+                                               case TypeCode.Single:
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               case TypeCode.SByte:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.Int16:
+                                               case TypeCode.Int32:
+                                               case TypeCode.Int64:
+                                               case TypeCode.Single:
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               case TypeCode.UInt16:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.UInt32:
+                                               case TypeCode.Int32:
+                                               case TypeCode.UInt64:
+                                               case TypeCode.Int64:
+                                               case TypeCode.Single:
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               case TypeCode.Int16:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.Int32:
+                                               case TypeCode.Int64:
+                                               case TypeCode.Single:
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               case TypeCode.UInt32:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.UInt64:
+                                               case TypeCode.Int64:
+                                               case TypeCode.Single:
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               case TypeCode.Int32:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.Int64:
+                                               case TypeCode.Single:
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               case TypeCode.UInt64:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.Single:
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               case TypeCode.Int64:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.Single:
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               case TypeCode.Single:
+                                       switch (targetType)
+                                       {
+                                               case TypeCode.Double:
+                                                       return true;
+                                               default:
+                                                       return false;
+                                       }
+                               default:
+                                       return false;
+                       }
+               }
+
+               public override PropertyInfo SelectProperty(BindingFlags bindingAttr, PropertyInfo[] match, Type returnType, Type[] indexes, ParameterModifier[] modifiers)
+               {
+                       int matchCount = 0;
+                       foreach (PropertyInfo property in match)
+                       {
+                               if (indexes == null || MatchParameterTypes(property.GetIndexParameters(), indexes))
+                               {
+                                       if (returnType != null)
+                                       {
+                                               if (property.PropertyType.IsPrimitive)
+                                               {
+                                                       if (!IsAllowedPrimitiveConversion(returnType, property.PropertyType))
+                                                       {
+                                                               continue;
+                                                       }
+                                               }
+                                               else
+                                               {
+                                                       if (!property.PropertyType.IsAssignableFrom(returnType))
+                                                       {
+                                                               continue;
+                                                       }
+                                               }
+                                       }
+                                       match[matchCount++] = property;
+                               }
+                       }
+
+                       if (matchCount == 0)
+                       {
+                               return null;
+                       }
+
+                       if (matchCount == 1)
+                       {
+                               return match[0];
+                       }
+
+                       PropertyInfo bestMatch = match[0];
+                       bool ambiguous = false;
+                       for (int i = 1; i < matchCount; i++)
+                       {
+                               int best = MatchTypes(bestMatch.PropertyType, match[i].PropertyType, returnType);
+                               if (best == 0 && indexes != null)
+                               {
+                                       best = MatchSignatures(bestMatch.PropertySignature, match[i].PropertySignature, indexes);
+                               }
+                               if (best == 0)
+                               {
+                                       int depth1 = GetInheritanceDepth(bestMatch.DeclaringType);
+                                       int depth2 = GetInheritanceDepth(match[i].DeclaringType);
+                                       if (bestMatch.Name == match[i].Name && depth1 != depth2)
+                                       {
+                                               if (depth1 > depth2)
+                                               {
+                                                       best = 1;
+                                               }
+                                               else
+                                               {
+                                                       best = 2;
+                                               }
+                                       }
+                                       else
+                                       {
+                                               ambiguous = true;
+                                       }
+                               }
+                               if (best == 2)
+                               {
+                                       ambiguous = false;
+                                       bestMatch = match[i];
+                               }
+                       }
+                       if (ambiguous)
+                       {
+                               throw new AmbiguousMatchException();
+                       }
+                       return bestMatch;
+               }
+       }
 }
index 72524e0098a88cd76e25b88854e40697aa0071b0..35a6549a26b438f661ea90b4c2986f825b14e448 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -23,6 +23,7 @@
 */
 using System;
 using System.Collections.Generic;
+using System.Diagnostics;
 
 namespace IKVM.Reflection
 {
@@ -58,7 +59,7 @@ namespace IKVM.Reflection
                        get { return GetMethodInfo().__MethodRVA; }
                }
 
-               public override bool ContainsGenericParameters
+               public sealed override bool ContainsGenericParameters
                {
                        get { return GetMethodInfo().ContainsGenericParameters; }
                }
@@ -78,66 +79,9 @@ namespace IKVM.Reflection
                        return parameters;
                }
 
-               private sealed class ParameterInfoWrapper : ParameterInfo
+               internal sealed override MemberInfo SetReflectedType(Type type)
                {
-                       private readonly ConstructorInfo ctor;
-                       private readonly ParameterInfo forward;
-
-                       internal ParameterInfoWrapper(ConstructorInfo ctor, ParameterInfo forward)
-                       {
-                               this.ctor = ctor;
-                               this.forward = forward;
-                       }
-
-                       public override string Name
-                       {
-                               get { return forward.Name; }
-                       }
-
-                       public override Type ParameterType
-                       {
-                               get { return forward.ParameterType; }
-                       }
-
-                       public override ParameterAttributes Attributes
-                       {
-                               get { return forward.Attributes; }
-                       }
-
-                       public override int Position
-                       {
-                               get { return forward.Position; }
-                       }
-
-                       public override object RawDefaultValue
-                       {
-                               get { return forward.RawDefaultValue; }
-                       }
-
-                       public override CustomModifiers __GetCustomModifiers()
-                       {
-                               return forward.__GetCustomModifiers();
-                       }
-
-                       public override MemberInfo Member
-                       {
-                               get { return ctor; }
-                       }
-
-                       public override int MetadataToken
-                       {
-                               get { return forward.MetadataToken; }
-                       }
-
-                       internal override Module Module
-                       {
-                               get { return ctor.Module; }
-                       }
-
-                       internal override IList<CustomAttributeData> GetCustomAttributesData(Type attributeType)
-                       {
-                               return forward.GetCustomAttributesData(attributeType);
-                       }
+                       return new ConstructorInfoWithReflectedType(type, this);
                }
        }
 
@@ -241,4 +185,115 @@ namespace IKVM.Reflection
                        return method.ImportTo(module);
                }
        }
+
+       sealed class ConstructorInfoWithReflectedType : ConstructorInfo
+       {
+               private readonly Type reflectedType;
+               private readonly ConstructorInfo ctor;
+
+               internal ConstructorInfoWithReflectedType(Type reflectedType, ConstructorInfo ctor)
+               {
+                       Debug.Assert(reflectedType != ctor.DeclaringType);
+                       this.reflectedType = reflectedType;
+                       this.ctor = ctor;
+               }
+
+               public override bool Equals(object obj)
+               {
+                       ConstructorInfoWithReflectedType other = obj as ConstructorInfoWithReflectedType;
+                       return other != null
+                               && other.reflectedType == reflectedType
+                               && other.ctor == ctor;
+               }
+
+               public override int GetHashCode()
+               {
+                       return reflectedType.GetHashCode() ^ ctor.GetHashCode();
+               }
+
+               public override MethodBody GetMethodBody()
+               {
+                       return ctor.GetMethodBody();
+               }
+
+               public override CallingConventions CallingConvention
+               {
+                       get { return ctor.CallingConvention; }
+               }
+
+               public override MethodAttributes Attributes
+               {
+                       get { return ctor.Attributes; }
+               }
+
+               public override MethodImplAttributes GetMethodImplementationFlags()
+               {
+                       return ctor.GetMethodImplementationFlags();
+               }
+
+               internal override int ParameterCount
+               {
+                       get { return ctor.ParameterCount; }
+               }
+
+               public override Type DeclaringType
+               {
+                       get { return ctor.DeclaringType; }
+               }
+
+               public override Type ReflectedType
+               {
+                       get { return reflectedType; }
+               }
+
+               public override string Name
+               {
+                       get { return ctor.Name; }
+               }
+
+               public override string ToString()
+               {
+                       return ctor.ToString();
+               }
+
+               public override Module Module
+               {
+                       get { return ctor.Module; }
+               }
+
+               public override int MetadataToken
+               {
+                       get { return ctor.MetadataToken; }
+               }
+
+               public override bool __IsMissing
+               {
+                       get { return ctor.__IsMissing; }
+               }
+
+               internal override MethodInfo GetMethodInfo()
+               {
+                       return ctor.GetMethodInfo();
+               }
+
+               internal override IList<CustomAttributeData> GetCustomAttributesData(Type attributeType)
+               {
+                       return ctor.GetCustomAttributesData(attributeType);
+               }
+
+               internal override MethodInfo GetMethodOnTypeDefinition()
+               {
+                       return ctor.GetMethodOnTypeDefinition();
+               }
+
+               internal override MethodSignature MethodSignature
+               {
+                       get { return ctor.MethodSignature; }
+               }
+
+               internal override int ImportTo(Emit.ModuleBuilder module)
+               {
+                       return ctor.ImportTo(module);
+               }
+       }
 }
index ff6e04f0196011b01c0df225b6c547ec7c77f2e2..be25fc6e132c029601ba32c9e844eabe4d5a7e3f 100644 (file)
@@ -428,7 +428,7 @@ namespace IKVM.Reflection
                                // there are broken compilers that emit an extra NUL character after the type name
                                typeName = typeName.Substring(0, typeName.Length - 1);
                        }
-                       return TypeNameParser.Parse(typeName, true).GetType(asm.universe, asm, true, typeName, true);
+                       return TypeNameParser.Parse(typeName, true).GetType(asm.universe, asm, true, typeName, true, false);
                }
 
                private static IList<CustomAttributeTypedArgument> ReadConstructorArguments(Assembly asm, ByteReader br, ConstructorInfo constructor)
index a573f5f8a1a6b26f19f773957459a237c495de07..038fdf06ddbfd52eb8770fcfbbf5a15050e0aed3 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2008-2011 Jeroen Frijters
+  Copyright (C) 2008-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -54,7 +54,9 @@ namespace IKVM.Reflection.Emit
                private PEFileKinds fileKind = PEFileKinds.Dll;
                private MethodInfo entryPoint;
                private VersionInfo versionInfo;
-               private ResourceSection unmanagedResources;
+               private byte[] win32icon;
+               private byte[] win32manifest;
+               private byte[] win32resources;
                private string imageRuntimeVersion;
                internal int mdStreamVersion = 0x20000;
                private Module pseudoManifestModule;
@@ -350,6 +352,10 @@ namespace IKVM.Reflection.Emit
                                manifestModule.AddDeclarativeSecurity(token, requestRefuse, refusedPermissions);
                        }
 
+                       ResourceSection unmanagedResources = versionInfo != null || win32icon != null || win32manifest != null || win32resources != null
+                               ? new ResourceSection()
+                               : null;
+
                        if (versionInfo != null)
                        {
                                versionInfo.SetName(GetName());
@@ -364,13 +370,24 @@ namespace IKVM.Reflection.Emit
                                }
                                ByteBuffer versionInfoData = new ByteBuffer(512);
                                versionInfo.Write(versionInfoData);
-                               if (unmanagedResources == null)
-                               {
-                                       unmanagedResources = new ResourceSection();
-                               }
                                unmanagedResources.AddVersionInfo(versionInfoData);
                        }
 
+                       if (win32icon != null)
+                       {
+                               unmanagedResources.AddIcon(win32icon);
+                       }
+
+                       if (win32manifest != null)
+                       {
+                               unmanagedResources.AddManifest(win32manifest, fileKind == PEFileKinds.Dll ? (ushort)2 : (ushort)1);
+                       }
+
+                       if (win32resources != null)
+                       {
+                               unmanagedResources.ExtractResources(win32resources);
+                       }
+
                        foreach (CustomAttributeBuilder cab in customAttributes)
                        {
                                // we intentionally don't filter out the version info (pseudo) custom attributes (to be compatible with .NET)
@@ -467,11 +484,19 @@ namespace IKVM.Reflection.Emit
 
                public void DefineVersionInfoResource()
                {
+                       if (versionInfo != null || win32resources != null)
+                       {
+                               throw new ArgumentException("Native resource has already been defined.");
+                       }
                        versionInfo = new VersionInfo();
                }
 
                public void DefineVersionInfoResource(string product, string productVersion, string company, string copyright, string trademark)
                {
+                       if (versionInfo != null || win32resources != null)
+                       {
+                               throw new ArgumentException("Native resource has already been defined.");
+                       }
                        versionInfo = new VersionInfo();
                        versionInfo.product = product;
                        versionInfo.informationalVersion = productVersion;
@@ -482,17 +507,32 @@ namespace IKVM.Reflection.Emit
 
                public void __DefineIconResource(byte[] iconFile)
                {
-                       unmanagedResources = new ResourceSection();
-                       unmanagedResources.AddIcon(iconFile);
+                       if (win32icon != null || win32resources != null)
+                       {
+                               throw new ArgumentException("Native resource has already been defined.");
+                       }
+                       win32icon = (byte[])iconFile.Clone();
+               }
+
+               public void __DefineManifestResource(byte[] manifest)
+               {
+                       if (win32manifest != null || win32resources != null)
+                       {
+                               throw new ArgumentException("Native resource has already been defined.");
+                       }
+                       win32manifest = (byte[])manifest.Clone();
                }
 
                public void __DefineUnmanagedResource(byte[] resource)
                {
+                       if (versionInfo != null || win32icon != null || win32manifest != null || win32resources != null)
+                       {
+                               throw new ArgumentException("Native resource has already been defined.");
+                       }
                        // The standard .NET DefineUnmanagedResource(byte[]) is useless, because it embeds "resource" (as-is) as the .rsrc section,
                        // but it doesn't set the PE file Resource Directory entry to point to it. That's why we have a renamed version, which behaves
                        // like DefineUnmanagedResource(string).
-                       unmanagedResources = new ResourceSection();
-                       unmanagedResources.ExtractResources(resource);
+                       win32resources = (byte[])resource.Clone();
                }
 
                public void DefineUnmanagedResource(string resourceFileName)
@@ -537,6 +577,27 @@ namespace IKVM.Reflection.Emit
                        return null;
                }
 
+               internal override Type FindTypeIgnoreCase(TypeName lowerCaseName)
+               {
+                       foreach (ModuleBuilder mb in modules)
+                       {
+                               Type type = mb.FindTypeIgnoreCase(lowerCaseName);
+                               if (type != null)
+                               {
+                                       return type;
+                               }
+                       }
+                       foreach (Module module in addedModules)
+                       {
+                               Type type = module.FindTypeIgnoreCase(lowerCaseName);
+                               if (type != null)
+                               {
+                                       return type;
+                               }
+                       }
+                       return null;
+               }
+
                public override string ImageRuntimeVersion
                {
                        get { return imageRuntimeVersion; }
@@ -676,6 +737,11 @@ namespace IKVM.Reflection.Emit
                        return null;
                }
 
+               internal override Type FindTypeIgnoreCase(TypeName lowerCaseName)
+               {
+                       return null;
+               }
+
                internal override void  GetTypesImpl(List<Type> list)
                {
                }
index c0e28424fe4b402e21d87de059b00254a2e9d610..ad6165f4ef9dce88a05c897888f32be5f0a8b942 100644 (file)
@@ -227,6 +227,21 @@ namespace IKVM.Reflection.Emit
                        }
                }
 
+               internal override bool IsNonPrivate
+               {
+                       get
+                       {
+                               foreach (Accessor acc in accessors)
+                               {
+                                       if ((acc.Method.Attributes & MethodAttributes.MemberAccessMask) > MethodAttributes.Private)
+                                       {
+                                               return true;
+                                       }
+                               }
+                               return false;
+                       }
+               }
+
                internal override bool IsStatic
                {
                        get
index ce3791d4c47ba4552de625c5b0efb35f6654345a..349fce6d00a0b4d495651bd34dfb6f11866c127b 100644 (file)
@@ -301,14 +301,12 @@ namespace IKVM.Reflection.Emit
 
                public ParameterBuilder DefineParameter(int position, ParameterAttributes attributes, string strParamName)
                {
-                       // the parameter is named "position", but it is actually a sequence number (i.e. 0 = return parameter, 1 = first parameter)
-                       int sequence = position--;
                        if (parameters == null)
                        {
                                parameters = new List<ParameterBuilder>();
                        }
                        this.ModuleBuilder.Param.AddVirtualRecord();
-                       ParameterBuilder pb = new ParameterBuilder(this.ModuleBuilder, sequence, attributes, strParamName);
+                       ParameterBuilder pb = new ParameterBuilder(this.ModuleBuilder, position, attributes, strParamName);
                        if (parameters.Count == 0 || position > parameters[parameters.Count - 1].Position)
                        {
                                parameters.Add(pb);
@@ -443,7 +441,8 @@ namespace IKVM.Reflection.Emit
                                        {
                                                foreach (ParameterBuilder pb in method.parameters)
                                                {
-                                                       if (pb.Position == parameter)
+                                                       // ParameterBuilder.Position is 1-based
+                                                       if (pb.Position - 1 == parameter)
                                                        {
                                                                return pb;
                                                        }
index db0e58b6a23d9072cf1e74294685f2b4fd9e9f14..41ebeffcddbd3f23ab00b48008676599738888bf 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2008-2011 Jeroen Frijters
+  Copyright (C) 2008-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -41,6 +41,8 @@ namespace IKVM.Reflection.Emit
                private Guid mvid = Guid.NewGuid();
                private long imageBaseAddress = 0x00400000;
                private long stackReserve = -1;
+               private int fileAlignment = 0x200;
+               private DllCharacteristics dllCharacteristics = DllCharacteristics.DynamicBase | DllCharacteristics.NoSEH | DllCharacteristics.NXCompat | DllCharacteristics.TerminalServerAware;
                private readonly AssemblyBuilder asm;
                internal readonly string moduleName;
                internal readonly string fileName;
@@ -334,17 +336,16 @@ namespace IKVM.Reflection.Emit
                        ExportedTypeTable.Record rec = new ExportedTypeTable.Record();
                        rec.TypeDefId = type.MetadataToken;
                        rec.TypeName = this.Strings.Add(type.__Name);
+                       string ns = type.__Namespace;
+                       rec.TypeNamespace = ns == null ? 0 : this.Strings.Add(ns);
                        if (type.IsNested)
                        {
                                rec.Flags = 0;
-                               rec.TypeNamespace = 0;
                                rec.Implementation = ExportType(type.DeclaringType);
                        }
                        else
                        {
                                rec.Flags = 0x00200000; // CorTypeAttr.tdForwarder
-                               string ns = type.__Namespace;
-                               rec.TypeNamespace = ns == null ? 0 : this.Strings.Add(ns);
                                rec.Implementation = ImportAssemblyRef(type.Assembly);
                        }
                        return 0x27000000 | this.ExportedType.FindOrAddRecord(rec);
@@ -470,6 +471,18 @@ namespace IKVM.Reflection.Emit
                        return null;
                }
 
+               internal override Type FindTypeIgnoreCase(TypeName lowerCaseName)
+               {
+                       foreach (Type type in types)
+                       {
+                               if (new TypeName(type.__Namespace, type.__Name).ToLowerInvariant() == lowerCaseName)
+                               {
+                                       return type;
+                               }
+                       }
+                       return null;
+               }
+
                internal override void GetTypesImpl(List<Type> list)
                {
                        foreach (Type type in types)
@@ -640,7 +653,7 @@ namespace IKVM.Reflection.Emit
                        int token;
                        if (!typeTokens.TryGetValue(type, out token))
                        {
-                               if (type.HasElementType || type.IsGenericTypeInstance)
+                               if (type.HasElementType || type.IsGenericTypeInstance || type.__IsFunctionPointer)
                                {
                                        ByteBuffer spec = new ByteBuffer(5);
                                        Signature.WriteTypeSpec(this, spec, type);
@@ -979,7 +992,8 @@ namespace IKVM.Reflection.Emit
                                {
                                        ExportedTypeTable.Record rec = new ExportedTypeTable.Record();
                                        rec.Flags = (int)type.Attributes;
-                                       rec.TypeDefId = type.MetadataToken & 0xFFFFFF;
+                                       // LAMESPEC ECMA says that TypeDefId is a row index, but it should be a token
+                                       rec.TypeDefId = type.MetadataToken;
                                        rec.TypeName = this.Strings.Add(type.__Name);
                                        string ns = type.__Namespace;
                                        rec.TypeNamespace = ns == null ? 0 : this.Strings.Add(ns);
@@ -1271,14 +1285,21 @@ namespace IKVM.Reflection.Emit
                        return imageBaseAddress;
                }
 
-               public override long __StackReserve
+               public new long __StackReserve
                {
                        get { return stackReserve; }
+                       set { stackReserve = value; }
+               }
+
+               protected override long GetStackReserveImpl()
+               {
+                       return stackReserve;
                }
 
+               [Obsolete("Use __StackReserve property.")]
                public void __SetStackReserve(long stackReserve)
                {
-                       this.stackReserve = stackReserve;
+                       __StackReserve = stackReserve;
                }
 
                internal ulong GetStackReserve(ulong defaultValue)
@@ -1286,6 +1307,28 @@ namespace IKVM.Reflection.Emit
                        return stackReserve == -1 ? defaultValue : (ulong)stackReserve;
                }
 
+               public new int __FileAlignment
+               {
+                       get { return fileAlignment; }
+                       set { fileAlignment = value; }
+               }
+
+               protected override int GetFileAlignmentImpl()
+               {
+                       return fileAlignment;
+               }
+
+               public new DllCharacteristics __DllCharacteristics
+               {
+                       get { return dllCharacteristics; }
+                       set { dllCharacteristics = value; }
+               }
+
+               protected override DllCharacteristics GetDllCharacteristicsImpl()
+               {
+                       return dllCharacteristics;
+               }
+
                public override int MDStreamVersion
                {
                        get { return asm.mdStreamVersion; }
index a74e35091687eefcc5f11a530c1d90ecfca9bf1d..74731fd944cd7c9a9354056c6ea4714817a005fb 100644 (file)
@@ -65,7 +65,8 @@ namespace IKVM.Reflection.Emit
 
                public int Position
                {
-                       get { return sequence - 1; }
+                       // note that this differs from ParameterInfo.Position, which is zero based
+                       get { return sequence; }
                }
 
                public int Attributes
index f1778578a5b27a8e6bda0d4797f5c0a065086436..d48e9d92641b48e7eebab8740ca5f4198110537c 100644 (file)
@@ -234,6 +234,21 @@ namespace IKVM.Reflection.Emit
                        }
                }
 
+               internal override bool IsNonPrivate
+               {
+                       get
+                       {
+                               foreach (Accessor acc in accessors)
+                               {
+                                       if ((acc.Method.Attributes & MethodAttributes.MemberAccessMask) > MethodAttributes.Private)
+                                       {
+                                               return true;
+                                       }
+                               }
+                               return false;
+                       }
+               }
+
                internal override bool IsStatic
                {
                        get
index de429c8235f6fc21c4e277f568d990fbdbc4dabf..79333401cf3e3689241d1f9de51eace5ae0c9302 100644 (file)
@@ -39,6 +39,7 @@ namespace IKVM.Reflection
        public enum BindingFlags
        {
                Default = 0,
+               IgnoreCase = 1,
                DeclaredOnly = 2,
                Instance = 4,
                Static = 8,
@@ -277,4 +278,16 @@ namespace IKVM.Reflection
                BeforeFieldInit = 1048576,
                CustomFormatMask = 12582912,
        }
+
+       // IKVM.Reflection specific type
+       [Flags]
+       public enum DllCharacteristics
+       {
+               HighEntropyVA = 0x0020,                 // IMAGE_DLLCHARACTERISTICS_HIGH_ENTROPY_VA
+               DynamicBase = 0x0040,                   // IMAGE_DLLCHARACTERISTICS_DYNAMIC_BASE
+               NoSEH = 0x0400,                                 // IMAGE_DLLCHARACTERISTICS_NO_SEH
+               NXCompat = 0x0100,                              // IMAGE_DLLCHARACTERISTICS_NX_COMPAT
+               AppContainer = 0x1000,                  // IMAGE_DLLCHARACTERISTICS_APPCONTAINER
+               TerminalServerAware = 0x8000,   // IMAGE_DLLCHARACTERISTICS_TERMINAL_SERVER_AWARE
+       }
 }
index 658f95412e69cdd4fe9e43577c46e10fd042d182..4da79952e2694a55609984a6f988f8865b1f4061 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -21,6 +21,8 @@
   jeroen@frijters.net
   
 */
+using System.Collections.Generic;
+using System.Diagnostics;
 
 namespace IKVM.Reflection
 {
@@ -44,6 +46,7 @@ namespace IKVM.Reflection
                public abstract MethodInfo[] __GetMethods();
                public abstract Type EventHandlerType { get; }
                internal abstract bool IsPublic { get; }
+               internal abstract bool IsNonPrivate { get; }
                internal abstract bool IsStatic { get; }
 
                public bool IsSpecialName
@@ -80,5 +83,144 @@ namespace IKVM.Reflection
                {
                        return this.DeclaringType.ToString() + " " + Name;
                }
+
+               internal sealed override bool BindingFlagsMatch(BindingFlags flags)
+               {
+                       return BindingFlagsMatch(IsPublic, flags, BindingFlags.Public, BindingFlags.NonPublic)
+                               && BindingFlagsMatch(IsStatic, flags, BindingFlags.Static, BindingFlags.Instance);
+               }
+
+               internal sealed override bool BindingFlagsMatchInherited(BindingFlags flags)
+               {
+                       return IsNonPrivate
+                               && BindingFlagsMatch(IsPublic, flags, BindingFlags.Public, BindingFlags.NonPublic)
+                               && BindingFlagsMatch(IsStatic, flags, BindingFlags.Static | BindingFlags.FlattenHierarchy, BindingFlags.Instance);
+               }
+
+               internal sealed override MemberInfo SetReflectedType(Type type)
+               {
+                       return new EventInfoWithReflectedType(type, this);
+               }
+       }
+
+       sealed class EventInfoWithReflectedType : EventInfo
+       {
+               private readonly Type reflectedType;
+               private readonly EventInfo eventInfo;
+
+               internal EventInfoWithReflectedType(Type reflectedType, EventInfo eventInfo)
+               {
+                       Debug.Assert(reflectedType != eventInfo.DeclaringType);
+                       this.reflectedType = reflectedType;
+                       this.eventInfo = eventInfo;
+               }
+
+               public override EventAttributes Attributes
+               {
+                       get { return eventInfo.Attributes; }
+               }
+
+               public override MethodInfo GetAddMethod(bool nonPublic)
+               {
+                       return SetReflectedType(eventInfo.GetAddMethod(nonPublic), reflectedType);
+               }
+
+               public override MethodInfo GetRaiseMethod(bool nonPublic)
+               {
+                       return SetReflectedType(eventInfo.GetRaiseMethod(nonPublic), reflectedType);
+               }
+
+               public override MethodInfo GetRemoveMethod(bool nonPublic)
+               {
+                       return SetReflectedType(eventInfo.GetRemoveMethod(nonPublic), reflectedType);
+               }
+
+               public override MethodInfo[] GetOtherMethods(bool nonPublic)
+               {
+                       return SetReflectedType(eventInfo.GetOtherMethods(nonPublic), reflectedType);
+               }
+
+               public override MethodInfo[] __GetMethods()
+               {
+                       return SetReflectedType(eventInfo.__GetMethods(), reflectedType);
+               }
+
+               public override Type EventHandlerType
+               {
+                       get { return eventInfo.EventHandlerType; }
+               }
+
+               internal override bool IsPublic
+               {
+                       get { return eventInfo.IsPublic; }
+               }
+
+               internal override bool IsNonPrivate
+               {
+                       get { return eventInfo.IsNonPrivate; }
+               }
+
+               internal override bool IsStatic
+               {
+                       get { return eventInfo.IsStatic; }
+               }
+
+               internal override EventInfo BindTypeParameters(Type type)
+               {
+                       return eventInfo.BindTypeParameters(type);
+               }
+
+               public override string ToString()
+               {
+                       return eventInfo.ToString();
+               }
+
+               public override bool __IsMissing
+               {
+                       get { return eventInfo.__IsMissing; }
+               }
+
+               public override Type DeclaringType
+               {
+                       get { return eventInfo.DeclaringType; }
+               }
+
+               public override Type ReflectedType
+               {
+                       get { return reflectedType; }
+               }
+
+               public override bool Equals(object obj)
+               {
+                       EventInfoWithReflectedType other = obj as EventInfoWithReflectedType;
+                       return other != null
+                               && other.reflectedType == reflectedType
+                               && other.eventInfo == eventInfo;
+               }
+
+               public override int GetHashCode()
+               {
+                       return reflectedType.GetHashCode() ^ eventInfo.GetHashCode();
+               }
+
+               internal override IList<CustomAttributeData> GetCustomAttributesData(Type attributeType)
+               {
+                       return eventInfo.GetCustomAttributesData(attributeType);
+               }
+
+               public override int MetadataToken
+               {
+                       get { return eventInfo.MetadataToken; }
+               }
+
+               public override Module Module
+               {
+                       get { return eventInfo.Module; }
+               }
+
+               public override string Name
+               {
+                       get { return eventInfo.Name; }
+               }
        }
 }
index dea054d79c431c972179acc2ca537e2f93864702..62d95eb4656b599aae856874d834dc82fb809596 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -22,6 +22,8 @@
   
 */
 using System;
+using System.Collections.Generic;
+using System.Diagnostics;
 
 namespace IKVM.Reflection
 {
@@ -134,5 +136,129 @@ namespace IKVM.Reflection
                {
                        return new GenericFieldInstance(this.DeclaringType.BindTypeParameters(type), this);
                }
+
+               internal sealed override bool BindingFlagsMatch(BindingFlags flags)
+               {
+                       return BindingFlagsMatch(IsPublic, flags, BindingFlags.Public, BindingFlags.NonPublic)
+                               && BindingFlagsMatch(IsStatic, flags, BindingFlags.Static, BindingFlags.Instance);
+               }
+
+               internal sealed override bool BindingFlagsMatchInherited(BindingFlags flags)
+               {
+                       return (Attributes & FieldAttributes.FieldAccessMask) > FieldAttributes.Private
+                               && BindingFlagsMatch(IsPublic, flags, BindingFlags.Public, BindingFlags.NonPublic)
+                               && BindingFlagsMatch(IsStatic, flags, BindingFlags.Static | BindingFlags.FlattenHierarchy, BindingFlags.Instance);
+               }
+
+               internal sealed override MemberInfo SetReflectedType(Type type)
+               {
+                       return new FieldInfoWithReflectedType(type, this);
+               }
+       }
+
+       sealed class FieldInfoWithReflectedType : FieldInfo
+       {
+               private readonly Type reflectedType;
+               private readonly FieldInfo field;
+
+               internal FieldInfoWithReflectedType(Type reflectedType, FieldInfo field)
+               {
+                       Debug.Assert(reflectedType != field.DeclaringType);
+                       this.reflectedType = reflectedType;
+                       this.field = field;
+               }
+
+               public override FieldAttributes Attributes
+               {
+                       get { return field.Attributes; }
+               }
+
+               public override void __GetDataFromRVA(byte[] data, int offset, int length)
+               {
+                       field.__GetDataFromRVA(data, offset, length);
+               }
+
+               public override int __FieldRVA
+               {
+                       get { return field.__FieldRVA; }
+               }
+
+               public override Object GetRawConstantValue()
+               {
+                       return field.GetRawConstantValue();
+               }
+
+               internal override FieldSignature FieldSignature
+               {
+                       get { return field.FieldSignature; }
+               }
+
+               public override FieldInfo __GetFieldOnTypeDefinition()
+               {
+                       return field.__GetFieldOnTypeDefinition();
+               }
+
+               internal override int ImportTo(Emit.ModuleBuilder module)
+               {
+                       return field.ImportTo(module);
+               }
+
+               internal override FieldInfo BindTypeParameters(Type type)
+               {
+                       return field.BindTypeParameters(type);
+               }
+
+               public override bool __IsMissing
+               {
+                       get { return field.__IsMissing; }
+               }
+
+               public override Type DeclaringType
+               {
+                       get { return field.DeclaringType; }
+               }
+
+               public override Type ReflectedType
+               {
+                       get { return reflectedType; }
+               }
+
+               public override bool Equals(object obj)
+               {
+                       FieldInfoWithReflectedType other = obj as FieldInfoWithReflectedType;
+                       return other != null
+                               && other.reflectedType == reflectedType
+                               && other.field == field;
+               }
+
+               public override int GetHashCode()
+               {
+                       return reflectedType.GetHashCode() ^ field.GetHashCode();
+               }
+
+               internal override IList<CustomAttributeData> GetCustomAttributesData(Type attributeType)
+               {
+                       return field.GetCustomAttributesData(attributeType);
+               }
+
+               public override int MetadataToken
+               {
+                       get { return field.MetadataToken; }
+               }
+
+               public override Module Module
+               {
+                       get { return field.Module; }
+               }
+
+               public override string Name
+               {
+                       get { return field.Name; }
+               }
+
+               public override string ToString()
+               {
+                       return field.ToString();
+               }
        }
 }
index 4d5041e3ecf68e903eeea335bb81c619f6d50132..5245147288a1799389a5d86387a3803ff00987a9 100644 (file)
@@ -507,6 +507,11 @@ namespace IKVM.Reflection
                        get { return property.IsPublic; }
                }
 
+               internal override bool IsNonPrivate
+               {
+                       get { return property.IsNonPrivate; }
+               }
+
                internal override bool IsStatic
                {
                        get { return property.IsStatic; }
@@ -659,6 +664,11 @@ namespace IKVM.Reflection
                        get { return eventInfo.IsPublic; }
                }
 
+               internal override bool IsNonPrivate
+               {
+                       get { return eventInfo.IsNonPrivate; }
+               }
+
                internal override bool IsStatic
                {
                        get { return eventInfo.IsStatic; }
index 596830eec224aa998ed47874a4e1e03a037e1125..37a4a210fb77818e1cc66b5d8bd685026e024b5b 100644 (file)
@@ -113,7 +113,7 @@ namespace IKVM.Reflection
                                        TypeNameParser parser = TypeNameParser.Parse(marshalType, false);
                                        if (!parser.Error)
                                        {
-                                               marshalTypeRef = parser.GetType(module.universe, module.Assembly, false, marshalType, false);
+                                               marshalTypeRef = parser.GetType(module.universe, module.Assembly, false, marshalType, false, false);
                                        }
                                }
 
index afa91c57cfe03c0d8d1694c30e824780e9599f17..81aae92ecbdc61a8d7a30018bdd026f8f0190235 100644 (file)
@@ -42,6 +42,13 @@ namespace IKVM.Reflection
                public abstract Type DeclaringType { get; }
                public abstract MemberTypes MemberType { get; }
 
+               public virtual Type ReflectedType
+               {
+                       get { return DeclaringType; }
+               }
+
+               internal abstract MemberInfo SetReflectedType(Type type);
+
                public virtual int MetadataToken
                {
                        get { throw new NotSupportedException(); }
@@ -82,10 +89,36 @@ namespace IKVM.Reflection
                        return this.Module.GetCustomAttributes(this.MetadataToken, attributeType);
                }
 
-               internal static bool BindingFlagsMatch(bool state, BindingFlags flags, BindingFlags trueFlag, BindingFlags falseFlag)
+               internal virtual bool BindingFlagsMatch(BindingFlags flags)
+               {
+                       throw new InvalidOperationException();
+               }
+
+               internal virtual bool BindingFlagsMatchInherited(BindingFlags flags)
+               {
+                       throw new InvalidOperationException();
+               }
+
+               protected static bool BindingFlagsMatch(bool state, BindingFlags flags, BindingFlags trueFlag, BindingFlags falseFlag)
                {
                        return (state && (flags & trueFlag) == trueFlag)
                                || (!state && (flags & falseFlag) == falseFlag);
                }
+
+               protected static T SetReflectedType<T>(T member, Type type)
+                       where T : MemberInfo
+               {
+                       return member == null ? null : (T)member.SetReflectedType(type);
+               }
+
+               protected static T[] SetReflectedType<T>(T[] members, Type type)
+                       where T : MemberInfo
+               {
+                       for (int i = 0; i < members.Length; i++)
+                       {
+                               members[i] = SetReflectedType(members[i], type);
+                       }
+                       return members;
+               }
        }
 }
index 3bce69a961577647facf5e11d5a5dcc0d89e3b61..d39e9f65ba0b9a1470e5bf1a3fce8bdc564baa6b 100644 (file)
@@ -1898,14 +1898,16 @@ namespace IKVM.Reflection.Metadata
                        return methods.ToArray();
                }
 
-               internal void ComputeFlags(Module module, int token, out bool isPublic, out bool isStatic)
+               internal void ComputeFlags(Module module, int token, out bool isPublic, out bool isNonPrivate, out bool isStatic)
                {
                        isPublic = false;
+                       isNonPrivate = false;
                        isStatic = false;
                        foreach (int i in Filter(token))
                        {
                                MethodBase method = module.ResolveMethod((MethodDefTable.Index << 24) + records[i].Method);
                                isPublic |= method.IsPublic;
+                               isNonPrivate |= (method.Attributes & MethodAttributes.MemberAccessMask) > MethodAttributes.Private;
                                isStatic |= method.IsStatic;
                        }
                }
index 916cd8d147ea72cee6c57e051692125c6b0595ba..1bf10e2c420406af587cc1b666a19167d90b9cf5 100644 (file)
@@ -146,5 +146,18 @@ namespace IKVM.Reflection
                internal abstract int ImportTo(Emit.ModuleBuilder module);
 
                internal abstract MethodBase BindTypeParameters(Type type);
+
+               internal sealed override bool BindingFlagsMatch(BindingFlags flags)
+               {
+                       return BindingFlagsMatch(IsPublic, flags, BindingFlags.Public, BindingFlags.NonPublic)
+                               && BindingFlagsMatch(IsStatic, flags, BindingFlags.Static, BindingFlags.Instance);
+               }
+
+               internal sealed override bool BindingFlagsMatchInherited(BindingFlags flags)
+               {
+                       return (Attributes & MethodAttributes.MemberAccessMask) > MethodAttributes.Private
+                               && BindingFlagsMatch(IsPublic, flags, BindingFlags.Public, BindingFlags.NonPublic)
+                               && BindingFlagsMatch(IsStatic, flags, BindingFlags.Static | BindingFlags.FlattenHierarchy, BindingFlags.Instance);
+               }
        }
 }
index ee4e4fb47c5baf43beca6f4ca1901e36df711758..87cbbc9a48bdb1a030d2127358d386beaa931bbf 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -22,6 +22,8 @@
   
 */
 using System;
+using System.Collections.Generic;
+using System.Diagnostics;
 using System.Text;
 
 namespace IKVM.Reflection
@@ -152,5 +154,201 @@ namespace IKVM.Reflection
                {
                        get { return !IsStatic; }
                }
+
+               internal sealed override MemberInfo SetReflectedType(Type type)
+               {
+                       return new MethodInfoWithReflectedType(type, this);
+               }
+       }
+
+       sealed class MethodInfoWithReflectedType : MethodInfo
+       {
+               private readonly Type reflectedType;
+               private readonly MethodInfo method;
+
+               internal MethodInfoWithReflectedType(Type reflectedType, MethodInfo method)
+               {
+                       Debug.Assert(reflectedType != method.DeclaringType);
+                       this.reflectedType = reflectedType;
+                       this.method = method;
+               }
+
+               public override bool Equals(object obj)
+               {
+                       MethodInfoWithReflectedType other = obj as MethodInfoWithReflectedType;
+                       return other != null
+                               && other.reflectedType == reflectedType
+                               && other.method == method;
+               }
+
+               public override int GetHashCode()
+               {
+                       return reflectedType.GetHashCode() ^ method.GetHashCode();
+               }
+
+               internal override MethodSignature MethodSignature
+               {
+                       get { return method.MethodSignature; }
+               }
+
+               internal override int ParameterCount
+               {
+                       get { return method.ParameterCount; }
+               }
+
+               public override ParameterInfo[] GetParameters()
+               {
+                       ParameterInfo[] parameters = method.GetParameters();
+                       for (int i = 0; i < parameters.Length; i++)
+                       {
+                               parameters[i] = new ParameterInfoWrapper(this, parameters[i]);
+                       }
+                       return parameters;
+               }
+
+               public override MethodAttributes Attributes
+               {
+                       get { return method.Attributes; }
+               }
+
+               public override MethodImplAttributes GetMethodImplementationFlags()
+               {
+                       return method.GetMethodImplementationFlags();
+               }
+
+               public override MethodBody GetMethodBody()
+               {
+                       return method.GetMethodBody();
+               }
+
+               public override CallingConventions CallingConvention
+               {
+                       get { return method.CallingConvention; }
+               }
+
+               public override int __MethodRVA
+               {
+                       get { return method.__MethodRVA; }
+               }
+
+               public override Type ReturnType
+               {
+                       get { return method.ReturnType; }
+               }
+
+               public override ParameterInfo ReturnParameter
+               {
+                       get { return new ParameterInfoWrapper(this, method.ReturnParameter); }
+               }
+
+               public override MethodInfo MakeGenericMethod(params Type[] typeArguments)
+               {
+                       return (MethodInfo)method.MakeGenericMethod(typeArguments).SetReflectedType(reflectedType);
+               }
+
+               public override MethodInfo GetGenericMethodDefinition()
+               {
+                       return (MethodInfo)method.GetGenericMethodDefinition().SetReflectedType(reflectedType);
+               }
+
+               public override string ToString()
+               {
+                       return method.ToString();
+               }
+
+               public override MethodInfo[] __GetMethodImpls()
+               {
+                       return method.__GetMethodImpls();
+               }
+
+               internal override Type GetGenericMethodArgument(int index)
+               {
+                       return method.GetGenericMethodArgument(index);
+               }
+
+               internal override int GetGenericMethodArgumentCount()
+               {
+                       return method.GetGenericMethodArgumentCount();
+               }
+
+               internal override MethodInfo GetMethodOnTypeDefinition()
+               {
+                       return method.GetMethodOnTypeDefinition();
+               }
+
+               internal override bool HasThis
+               {
+                       get { return method.HasThis; }
+               }
+
+               public override Module Module
+               {
+                       get { return method.Module; }
+               }
+
+               public override Type DeclaringType
+               {
+                       get { return method.DeclaringType; }
+               }
+
+               public override Type ReflectedType
+               {
+                       get { return reflectedType; }
+               }
+
+               public override string Name
+               {
+                       get { return method.Name; }
+               }
+
+               internal override int ImportTo(IKVM.Reflection.Emit.ModuleBuilder module)
+               {
+                       return method.ImportTo(module);
+               }
+
+               public override MethodBase __GetMethodOnTypeDefinition()
+               {
+                       return method.__GetMethodOnTypeDefinition();
+               }
+
+               public override bool __IsMissing
+               {
+                       get { return method.__IsMissing; }
+               }
+
+               internal override MethodBase BindTypeParameters(Type type)
+               {
+                       return method.BindTypeParameters(type);
+               }
+
+               public override bool ContainsGenericParameters
+               {
+                       get { return method.ContainsGenericParameters; }
+               }
+
+               internal override IList<CustomAttributeData> GetCustomAttributesData(Type attributeType)
+               {
+                       return method.GetCustomAttributesData(attributeType);
+               }
+
+               public override Type[] GetGenericArguments()
+               {
+                       return method.GetGenericArguments();
+               }
+
+               public override bool IsGenericMethod
+               {
+                       get { return method.IsGenericMethod; }
+               }
+
+               public override bool IsGenericMethodDefinition
+               {
+                       get { return method.IsGenericMethodDefinition; }
+               }
+
+               public override int MetadataToken
+               {
+                       get { return method.MetadataToken; }
+               }
        }
 }
index a45c2386cee929870aa93c337371c9fe3d90ad9b..76c9cb505b044a04f65d6b019c99a3e0eafdb821 100644 (file)
@@ -312,32 +312,14 @@ namespace IKVM.Reflection
                        return new MethodSignature(returnType, parameterTypes, modifiers, callingConvention, genericParamCount);
                }
 
+               internal bool MatchParameterTypes(MethodSignature other)
+               {
+                       return Util.ArrayEquals(other.parameterTypes, parameterTypes);
+               }
+
                internal bool MatchParameterTypes(Type[] types)
                {
-                       if (types == parameterTypes)
-                       {
-                               return true;
-                       }
-                       if (types == null)
-                       {
-                               return parameterTypes.Length == 0;
-                       }
-                       if (parameterTypes == null)
-                       {
-                               return types.Length == 0;
-                       }
-                       if (types.Length == parameterTypes.Length)
-                       {
-                               for (int i = 0; i < types.Length; i++)
-                               {
-                                       if (!Util.TypeEquals(types[i], parameterTypes[i]))
-                                       {
-                                               return false;
-                                       }
-                               }
-                               return true;
-                       }
-                       return false;
+                       return Util.ArrayEquals(types, parameterTypes);
                }
 
                internal override void WriteSig(ModuleBuilder module, ByteBuffer bb)
index 7c3305eef0468f81b4a41a8608c2014abeb6c841..dfc7791b1404b376beca0471f1bb3364191103d0 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2011 Jeroen Frijters
+  Copyright (C) 2011-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -223,6 +223,11 @@ namespace IKVM.Reflection
                        return null;
                }
 
+               internal override Type FindTypeIgnoreCase(TypeName lowerCaseName)
+               {
+                       return null;
+               }
+
                internal override IList<CustomAttributeData> GetCustomAttributesData(Type attributeType)
                {
                        throw new MissingAssemblyException(this);
@@ -274,6 +279,11 @@ namespace IKVM.Reflection
                        return null;
                }
 
+               internal override Type FindTypeIgnoreCase(TypeName lowerCaseName)
+               {
+                       return null;
+               }
+
                internal override void GetTypesImpl(System.Collections.Generic.List<Type> list)
                {
                        throw new MissingModuleException(this);
@@ -378,6 +388,11 @@ namespace IKVM.Reflection
                        return null;
                }
 
+               internal override Type FindNestedTypeIgnoreCase(TypeName lowerCaseName)
+               {
+                       return null;
+               }
+
                public override bool __IsMissing
                {
                        get { return true; }
@@ -429,7 +444,15 @@ namespace IKVM.Reflection
                                        case TypeFlags.NotValueType:
                                                return false;
                                        default:
-                                               throw new MissingMemberException(this);
+                                               if (module.universe.ResolveMissingTypeIsValueType(this))
+                                               {
+                                                       typeFlags |= TypeFlags.ValueType;
+                                               }
+                                               else
+                                               {
+                                                       typeFlags |= TypeFlags.NotValueType;
+                                               }
+                                               return (typeFlags & TypeFlags.ValueType) != 0;
                                }
                        }
                }
@@ -1081,6 +1104,11 @@ namespace IKVM.Reflection
                        get { throw new MissingMemberException(this); }
                }
 
+               internal override bool IsNonPrivate
+               {
+                       get { throw new MissingMemberException(this); }
+               }
+
                internal override bool IsStatic
                {
                        get { throw new MissingMemberException(this); }
index 9c5009135a1819eda9437cea7bf14317297c425d..fa95cfff23ca931ca9c0f99d6de2bea143097a8b 100644 (file)
@@ -309,6 +309,7 @@ namespace IKVM.Reflection
                internal abstract void GetTypesImpl(List<Type> list);
 
                internal abstract Type FindType(TypeName name);
+               internal abstract Type FindTypeIgnoreCase(TypeName lowerCaseName);
 
                [Obsolete("Please use __ResolveOptionalParameterTypes(int, Type[], Type[], out CustomModifiers[]) instead.")]
                public Type[] __ResolveOptionalParameterTypes(int metadataToken)
@@ -329,10 +330,6 @@ namespace IKVM.Reflection
 
                public Type GetType(string className, bool throwOnError, bool ignoreCase)
                {
-                       if (ignoreCase)
-                       {
-                               throw new NotImplementedException();
-                       }
                        TypeNameParser parser = TypeNameParser.Parse(className, throwOnError);
                        if (parser.Error)
                        {
@@ -349,12 +346,15 @@ namespace IKVM.Reflection
                                        return null;
                                }
                        }
-                       Type type = FindType(TypeName.Split(TypeNameParser.Unescape(parser.FirstNamePart)));
+                       TypeName typeName = TypeName.Split(TypeNameParser.Unescape(parser.FirstNamePart));
+                       Type type = ignoreCase
+                               ? FindTypeIgnoreCase(typeName.ToLowerInvariant())
+                               : FindType(typeName);
                        if (type == null && __IsMissing)
                        {
                                throw new MissingModuleException((MissingModule)this);
                        }
-                       return parser.Expand(type, this.Assembly, throwOnError, className, false);
+                       return parser.Expand(type, this.Assembly, throwOnError, className, false, ignoreCase);
                }
 
                public Type[] GetTypes()
@@ -442,16 +442,27 @@ namespace IKVM.Reflection
 
                protected abstract long GetImageBaseImpl();
 
-               public virtual long __StackReserve
+               public long __StackReserve
                {
-                       get { throw new NotSupportedException(); }
+                       get { return GetStackReserveImpl(); }
                }
 
-               public virtual int __FileAlignment
+               protected abstract long GetStackReserveImpl();
+
+               public int __FileAlignment
                {
-                       get { throw new NotSupportedException(); }
+                       get { return GetFileAlignmentImpl(); }
                }
 
+               protected abstract int GetFileAlignmentImpl();
+
+               public DllCharacteristics __DllCharacteristics
+               {
+                       get { return GetDllCharacteristicsImpl(); }
+               }
+
+               protected abstract DllCharacteristics GetDllCharacteristicsImpl();
+
                public virtual byte[] __ModuleHash
                {
                        get { throw new NotSupportedException(); }
@@ -594,6 +605,21 @@ namespace IKVM.Reflection
                        throw NotSupportedException();
                }
 
+               protected sealed override long GetStackReserveImpl()
+               {
+                       throw NotSupportedException();
+               }
+
+               protected sealed override int GetFileAlignmentImpl()
+               {
+                       throw NotSupportedException();
+               }
+
+               protected override DllCharacteristics GetDllCharacteristicsImpl()
+               {
+                       throw NotSupportedException();
+               }
+
                public sealed override Type ResolveType(int metadataToken, Type[] genericTypeArguments, Type[] genericMethodArguments)
                {
                        throw ArgumentOutOfRangeException();
index 693c5cab8199b326a131653a815a309bfaca47e5..b8627e6dcfa56bf2615f5868e0a0de320c45f1df 100644 (file)
@@ -113,4 +113,66 @@ namespace IKVM.Reflection
                        return this.Module.GetCustomAttributes(this.MetadataToken, attributeType);
                }
        }
+
+       sealed class ParameterInfoWrapper : ParameterInfo
+       {
+               private readonly MemberInfo member;
+               private readonly ParameterInfo forward;
+
+               internal ParameterInfoWrapper(MemberInfo member, ParameterInfo forward)
+               {
+                       this.member = member;
+                       this.forward = forward;
+               }
+
+               public override string Name
+               {
+                       get { return forward.Name; }
+               }
+
+               public override Type ParameterType
+               {
+                       get { return forward.ParameterType; }
+               }
+
+               public override ParameterAttributes Attributes
+               {
+                       get { return forward.Attributes; }
+               }
+
+               public override int Position
+               {
+                       get { return forward.Position; }
+               }
+
+               public override object RawDefaultValue
+               {
+                       get { return forward.RawDefaultValue; }
+               }
+
+               public override CustomModifiers __GetCustomModifiers()
+               {
+                       return forward.__GetCustomModifiers();
+               }
+
+               public override MemberInfo Member
+               {
+                       get { return member; }
+               }
+
+               public override int MetadataToken
+               {
+                       get { return forward.MetadataToken; }
+               }
+
+               internal override Module Module
+               {
+                       get { return member.Module; }
+               }
+
+               internal override IList<CustomAttributeData> GetCustomAttributesData(Type attributeType)
+               {
+                       return forward.GetCustomAttributesData(attributeType);
+               }
+       }
 }
index 1644aaaa4fef877188609875e12de57c3b338d59..771edcb48bafe1f07e8a3b342a2b9eda0be2ce9d 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -22,6 +22,7 @@
   
 */
 using System;
+using System.Collections.Generic;
 
 namespace IKVM.Reflection
 {
@@ -45,6 +46,7 @@ namespace IKVM.Reflection
                public abstract MethodInfo[] GetAccessors(bool nonPublic);
                public abstract object GetRawConstantValue();
                internal abstract bool IsPublic { get; }
+               internal abstract bool IsNonPrivate { get; }
                internal abstract bool IsStatic { get; }
                internal abstract PropertySignature PropertySignature { get; }
 
@@ -105,7 +107,7 @@ namespace IKVM.Reflection
                        }
                }
 
-               public ParameterInfo[] GetIndexParameters()
+               public virtual ParameterInfo[] GetIndexParameters()
                {
                        ParameterInfo[] parameters = new ParameterInfo[this.PropertySignature.ParameterCount];
                        for (int i = 0; i < parameters.Length; i++)
@@ -169,5 +171,158 @@ namespace IKVM.Reflection
                {
                        return this.DeclaringType.ToString() + " " + Name;
                }
+
+               internal sealed override bool BindingFlagsMatch(BindingFlags flags)
+               {
+                       return BindingFlagsMatch(IsPublic, flags, BindingFlags.Public, BindingFlags.NonPublic)
+                               && BindingFlagsMatch(IsStatic, flags, BindingFlags.Static, BindingFlags.Instance);
+               }
+
+               internal sealed override bool BindingFlagsMatchInherited(BindingFlags flags)
+               {
+                       return IsNonPrivate
+                               && BindingFlagsMatch(IsPublic, flags, BindingFlags.Public, BindingFlags.NonPublic)
+                               && BindingFlagsMatch(IsStatic, flags, BindingFlags.Static | BindingFlags.FlattenHierarchy, BindingFlags.Instance);
+               }
+
+               internal sealed override MemberInfo SetReflectedType(Type type)
+               {
+                       return new PropertyInfoWithReflectedType(type, this);
+               }
+       }
+
+       sealed class PropertyInfoWithReflectedType : PropertyInfo
+       {
+               private readonly Type reflectedType;
+               private readonly PropertyInfo property;
+
+               internal PropertyInfoWithReflectedType(Type reflectedType, PropertyInfo property)
+               {
+                       this.reflectedType = reflectedType;
+                       this.property = property;
+               }
+
+               public override PropertyAttributes Attributes
+               {
+                       get { return property.Attributes; }
+               }
+
+               public override bool CanRead
+               {
+                       get { return property.CanRead; }
+               }
+
+               public override bool CanWrite
+               {
+                       get { return property.CanWrite; }
+               }
+
+               public override MethodInfo GetGetMethod(bool nonPublic)
+               {
+                       return SetReflectedType(property.GetGetMethod(nonPublic), reflectedType);
+               }
+
+               public override MethodInfo GetSetMethod(bool nonPublic)
+               {
+                       return SetReflectedType(property.GetSetMethod(nonPublic), reflectedType);
+               }
+
+               public override MethodInfo[] GetAccessors(bool nonPublic)
+               {
+                       return SetReflectedType(property.GetAccessors(nonPublic), reflectedType);
+               }
+
+               public override object GetRawConstantValue()
+               {
+                       return property.GetRawConstantValue();
+               }
+
+               internal override bool IsPublic
+               {
+                       get { return property.IsPublic; }
+               }
+
+               internal override bool IsNonPrivate
+               {
+                       get { return property.IsNonPrivate; }
+               }
+
+               internal override bool IsStatic
+               {
+                       get { return property.IsStatic; }
+               }
+
+               internal override PropertySignature PropertySignature
+               {
+                       get { return property.PropertySignature; }
+               }
+
+               public override ParameterInfo[] GetIndexParameters()
+               {
+                       ParameterInfo[] parameters = property.GetIndexParameters();
+                       for (int i = 0; i < parameters.Length; i++)
+                       {
+                               parameters[i] = new ParameterInfoWrapper(this, parameters[i]);
+                       }
+                       return parameters;
+               }
+
+               internal override PropertyInfo BindTypeParameters(Type type)
+               {
+                       return property.BindTypeParameters(type);
+               }
+
+               public override string ToString()
+               {
+                       return property.ToString();
+               }
+
+               public override bool __IsMissing
+               {
+                       get { return property.__IsMissing; }
+               }
+
+               public override Type DeclaringType
+               {
+                       get { return property.DeclaringType; }
+               }
+
+               public override Type ReflectedType
+               {
+                       get { return reflectedType; }
+               }
+
+               public override bool Equals(object obj)
+               {
+                       PropertyInfoWithReflectedType other = obj as PropertyInfoWithReflectedType;
+                       return other != null
+                               && other.reflectedType == reflectedType
+                               && other.property == property;
+               }
+
+               public override int GetHashCode()
+               {
+                       return reflectedType.GetHashCode() ^ property.GetHashCode();
+               }
+
+               internal override IList<CustomAttributeData> GetCustomAttributesData(Type attributeType)
+               {
+                       return property.GetCustomAttributesData(attributeType);
+               }
+
+               public override int MetadataToken
+               {
+                       get { return property.MetadataToken; }
+               }
+
+               public override Module Module
+               {
+                       get { return property.Module; }
+               }
+
+               public override string Name
+               {
+                       get { return property.Name; }
+               }
        }
 }
index e9628561c5ac5cf20498d04895c4b6f968f98f29..9a4a5534d129d6cf569ca94a1941385c299e49b3 100644 (file)
@@ -147,6 +147,11 @@ namespace IKVM.Reflection
                        get { return callingConvention; }
                }
 
+               internal bool MatchParameterTypes(Type[] types)
+               {
+                       return Util.ArrayEquals(types, parameterTypes);
+               }
+
                internal static PropertySignature ReadSig(ModuleReader module, ByteReader br, IGenericContext context)
                {
                        byte flags = br.ReadByte();
index 2764e2d676cc916ceca391102464e08bd4326568..5850d7b8af5af94760a42d44f7342bdff369b861 100644 (file)
@@ -109,6 +109,19 @@ namespace IKVM.Reflection.Reader
                        return type;
                }
 
+               internal override Type FindTypeIgnoreCase(TypeName lowerCaseName)
+               {
+                       Type type = manifestModule.FindTypeIgnoreCase(lowerCaseName);
+                       for (int i = 0; type == null && i < externalModules.Length; i++)
+                       {
+                               if ((manifestModule.File.records[i].Flags & ContainsNoMetaData) == 0)
+                               {
+                                       type = GetModule(i).FindTypeIgnoreCase(lowerCaseName);
+                               }
+                       }
+                       return type;
+               }
+
                public override string ImageRuntimeVersion
                {
                        get { return manifestModule.__ImageRuntimeVersion; }
index a40baf5820d33272d9ce133ea3cadda071ec25e7..5d9e1a683ae56f65fb1bd12a80804ee4f42d1a3f 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -34,6 +34,7 @@ namespace IKVM.Reflection.Reader
                private readonly Type declaringType;
                private readonly int index;
                private bool isPublic;
+               private bool isNonPrivate;
                private bool isStatic;
                private bool flagsCached;
 
@@ -122,6 +123,18 @@ namespace IKVM.Reflection.Reader
                        }
                }
 
+               internal override bool IsNonPrivate
+               {
+                       get
+                       {
+                               if (!flagsCached)
+                               {
+                                       ComputeFlags();
+                               }
+                               return isNonPrivate;
+                       }
+               }
+
                internal override bool IsStatic
                {
                        get
@@ -136,7 +149,7 @@ namespace IKVM.Reflection.Reader
 
                private void ComputeFlags()
                {
-                       module.MethodSemantics.ComputeFlags(module, this.MetadataToken, out isPublic, out isStatic);
+                       module.MethodSemantics.ComputeFlags(module, this.MetadataToken, out isPublic, out isNonPrivate, out isStatic);
                        flagsCached = true;
                }
        }
index 4c1ea24033e50f8e0d449370289ba80d677dfcc1..f0999a84d7acf9ee0ad668a11b88bd1477a4ec63 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -87,6 +87,59 @@ namespace IKVM.Reflection.Reader
                {
                        get { return true; }
                }
+
+               public sealed override bool __ContainsMissingType
+               {
+                       get
+                       {
+                               bool freeList = false;
+                               try
+                               {
+                                       foreach (Type type in GetGenericParameterConstraints())
+                                       {
+                                               if (type.__IsMissing)
+                                               {
+                                                       return true;
+                                               }
+                                               else if (type.IsGenericTypeInstance || type.HasElementType || type.__IsFunctionPointer)
+                                               {
+                                                       // if a constructed type contains generic parameters,
+                                                       // it might contain this type parameter again and
+                                                       // to prevent infinite recurssion, we keep a thread local
+                                                       // list of type parameters we've already processed
+                                                       if (type.ContainsGenericParameters)
+                                                       {
+                                                               if (containsMissingTypeHack == null)
+                                                               {
+                                                                       freeList = true;
+                                                                       containsMissingTypeHack = new List<Type>();
+                                                               }
+                                                               else if (containsMissingTypeHack.Contains(this))
+                                                               {
+                                                                       return false;
+                                                               }
+                                                               containsMissingTypeHack.Add(this);
+                                                       }
+                                                       if (type.__ContainsMissingType)
+                                                       {
+                                                               return true;
+                                                       }
+                                               }
+                                       }
+                                       return false;
+                               }
+                               finally
+                               {
+                                       if (freeList)
+                                       {
+                                               containsMissingTypeHack = null;
+                                       }
+                               }
+                       }
+               }
+
+               [ThreadStatic]
+               private static List<Type> containsMissingTypeHack;
        }
 
        sealed class UnboundGenericMethodParameter : TypeParameterType
@@ -141,6 +194,11 @@ namespace IKVM.Reflection.Reader
                                throw new InvalidOperationException();
                        }
 
+                       internal override Type FindTypeIgnoreCase(TypeName lowerCaseName)
+                       {
+                               throw new InvalidOperationException();
+                       }
+
                        internal override void GetTypesImpl(List<Type> list)
                        {
                                throw new InvalidOperationException();
index 249f39e23ade039fd1366f570b0c264ed6dcfab5..da3e24e84cec0ba263c25485b61e94fb617051c1 100644 (file)
@@ -589,6 +589,26 @@ namespace IKVM.Reflection.Reader
                        return type;
                }
 
+               internal override Type FindTypeIgnoreCase(TypeName lowerCaseName)
+               {
+                       PopulateTypeDef();
+                       foreach (Type type in types.Values)
+                       {
+                               if (new TypeName(type.__Namespace, type.__Name).ToLowerInvariant() == lowerCaseName)
+                               {
+                                       return type;
+                               }
+                       }
+                       foreach (TypeName name in forwardedTypes.Keys)
+                       {
+                               if (name.ToLowerInvariant() == lowerCaseName)
+                               {
+                                       return forwardedTypes[name].GetType(this, name);
+                               }
+                       }
+                       return null;
+               }
+
                private Exception TokenOutOfRangeException(int metadataToken)
                {
                        return new ArgumentOutOfRangeException("metadataToken", String.Format("Token 0x{0:x8} is not valid in the scope of module {1}.", metadataToken, this.Name));
@@ -1220,14 +1240,19 @@ namespace IKVM.Reflection.Reader
                        return (long)peFile.OptionalHeader.ImageBase;
                }
 
-               public override long __StackReserve
+               protected override long GetStackReserveImpl()
+               {
+                       return (long)peFile.OptionalHeader.SizeOfStackReserve;
+               }
+
+               protected override int GetFileAlignmentImpl()
                {
-                       get { return (long)peFile.OptionalHeader.SizeOfStackReserve; }
+                       return (int)peFile.OptionalHeader.FileAlignment;
                }
 
-               public override int __FileAlignment
+               protected override DllCharacteristics GetDllCharacteristicsImpl()
                {
-                       get { return (int)peFile.OptionalHeader.FileAlignment; }
+                       return (DllCharacteristics)peFile.OptionalHeader.DllCharacteristics;
                }
 
                public override int __EntryPointRVA
index cd1fb20b3825296a50e7c4a684a29659f7cd7d34..50928c88e03a85b2675bd129524ea71a2064620d 100644 (file)
@@ -98,11 +98,6 @@ namespace IKVM.Reflection.Reader
                public const WORD IMAGE_SUBSYSTEM_WINDOWS_GUI = 2;
                public const WORD IMAGE_SUBSYSTEM_WINDOWS_CUI = 3;
 
-               public const WORD IMAGE_DLLCHARACTERISTICS_DYNAMIC_BASE = 0x0040;
-               public const WORD IMAGE_DLLCHARACTERISTICS_NX_COMPAT = 0x0100;
-               public const WORD IMAGE_DLLCHARACTERISTICS_NO_SEH = 0x0400;
-               public const WORD IMAGE_DLLCHARACTERISTICS_TERMINAL_SERVER_AWARE = 0x8000;
-
                public WORD Magic;
                public BYTE MajorLinkerVersion;
                public BYTE MinorLinkerVersion;
index ea95393f897b3ff1f2b69a2dd00b7d9063289ccd..fd74448f74ace0ac69a62b25c84b8b5523e5e91f 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -35,6 +35,7 @@ namespace IKVM.Reflection.Reader
                private readonly int index;
                private PropertySignature sig;
                private bool isPublic;
+               private bool isNonPrivate;
                private bool isStatic;
                private bool flagsCached;
 
@@ -135,6 +136,18 @@ namespace IKVM.Reflection.Reader
                        }
                }
 
+               internal override bool IsNonPrivate
+               {
+                       get
+                       {
+                               if (!flagsCached)
+                               {
+                                       ComputeFlags();
+                               }
+                               return isNonPrivate;
+                       }
+               }
+
                internal override bool IsStatic
                {
                        get
@@ -149,7 +162,7 @@ namespace IKVM.Reflection.Reader
 
                private void ComputeFlags()
                {
-                       module.MethodSemantics.ComputeFlags(module, this.MetadataToken, out isPublic, out isStatic);
+                       module.MethodSemantics.ComputeFlags(module, this.MetadataToken, out isPublic, out isNonPrivate, out isStatic);
                        flagsCached = true;
                }
        }
index 6e3e3925e18b592bc746a82cf1f654a88c051006..0113e4706425426400da8f5327206d67d5a6f35c 100644 (file)
@@ -90,6 +90,11 @@ namespace IKVM.Reflection.Reader
                        return null;
                }
 
+               internal override Type FindTypeIgnoreCase(TypeName lowerCaseName)
+               {
+                       return null;
+               }
+
                internal override void GetTypesImpl(List<Type> list)
                {
                }
index 64ef33a7431e0b687729cae108c6432d71d5a6eb..841cacf97abfc9ccec7d571c2976c8e2a027c502 100644 (file)
@@ -79,7 +79,7 @@ namespace IKVM.Reflection
 
                public static Binder DefaultBinder
                {
-                       get { return null; }
+                       get { return new DefaultBinder(); }
                }
 
                public sealed override MemberTypes MemberType
@@ -521,7 +521,16 @@ namespace IKVM.Reflection
 
                public MemberInfo[] GetMember(string name, MemberTypes type, BindingFlags bindingAttr)
                {
-                       MemberFilter filter = delegate(MemberInfo member, object filterCriteria) { return member.Name.Equals(filterCriteria); };
+                       MemberFilter filter;
+                       if ((bindingAttr & BindingFlags.IgnoreCase) != 0)
+                       {
+                               name = name.ToLowerInvariant();
+                               filter = delegate(MemberInfo member, object filterCriteria) { return member.Name.ToLowerInvariant().Equals(filterCriteria); };
+                       }
+                       else
+                       {
+                               filter = delegate(MemberInfo member, object filterCriteria) { return member.Name.Equals(filterCriteria); };
+                       }
                        return FindMembers(type, bindingAttr, filter, name);
                }
 
@@ -566,57 +575,151 @@ namespace IKVM.Reflection
                        return members.ToArray();
                }
 
-               public EventInfo GetEvent(string name)
+               private MemberInfo[] GetMembers<T>()
                {
-                       return GetEvent(name, BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static);
+                       if (typeof(T) == typeof(ConstructorInfo) || typeof(T) == typeof(MethodInfo))
+                       {
+                               return __GetDeclaredMethods();
+                       }
+                       else if (typeof(T) == typeof(FieldInfo))
+                       {
+                               return __GetDeclaredFields();
+                       }
+                       else if (typeof(T) == typeof(PropertyInfo))
+                       {
+                               return __GetDeclaredProperties();
+                       }
+                       else if (typeof(T) == typeof(EventInfo))
+                       {
+                               return __GetDeclaredEvents();
+                       }
+                       else if (typeof(T) == typeof(Type))
+                       {
+                               return __GetDeclaredTypes();
+                       }
+                       else
+                       {
+                               throw new InvalidOperationException();
+                       }
                }
 
-               public EventInfo GetEvent(string name, BindingFlags bindingAttr)
+               private T[] GetMembers<T>(BindingFlags flags)
+                       where T : MemberInfo
                {
-                       foreach (EventInfo evt in GetEvents(bindingAttr))
+                       CheckBaked();
+                       List<T> list = new List<T>();
+                       foreach (MemberInfo member in GetMembers<T>())
                        {
-                               if (evt.Name == name)
+                               if (member is T && member.BindingFlagsMatch(flags))
                                {
-                                       return evt;
+                                       list.Add((T)member);
                                }
                        }
-                       return null;
-               }
-
-               public EventInfo[] GetEvents()
-               {
-                       return GetEvents(BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static);
+                       if ((flags & BindingFlags.DeclaredOnly) == 0)
+                       {
+                               for (Type type = this.BaseType; type != null; type = type.BaseType)
+                               {
+                                       type.CheckBaked();
+                                       foreach (MemberInfo member in type.GetMembers<T>())
+                                       {
+                                               if (member is T && member.BindingFlagsMatchInherited(flags))
+                                               {
+                                                       list.Add((T)member.SetReflectedType(this));
+                                               }
+                                       }
+                               }
+                       }
+                       return list.ToArray();
                }
 
-               public EventInfo[] GetEvents(BindingFlags bindingAttr)
+               private T GetMemberByName<T>(string name, BindingFlags flags, Predicate<T> filter)
+                       where T : MemberInfo
                {
-                       List<EventInfo> list = new List<EventInfo>();
-                       Type type = this;
-                       while (type != null)
+                       CheckBaked();
+                       if ((flags & BindingFlags.IgnoreCase) != 0)
+                       {
+                               name = name.ToLowerInvariant();
+                       }
+                       T found = null;
+                       foreach (MemberInfo member in GetMembers<T>())
                        {
-                               type.CheckBaked();
-                               foreach (EventInfo evt in type.__GetDeclaredEvents())
+                               if (member is T && member.BindingFlagsMatch(flags))
                                {
-                                       if (BindingFlagsMatch(evt.IsPublic, bindingAttr, BindingFlags.Public, BindingFlags.NonPublic)
-                                               && BindingFlagsMatch(evt.IsStatic, bindingAttr, BindingFlags.Static, BindingFlags.Instance))
+                                       string memberName = member.Name;
+                                       if ((flags & BindingFlags.IgnoreCase) != 0)
                                        {
-                                               list.Add(evt);
+                                               memberName = memberName.ToLowerInvariant();
                                        }
-                               }
-                               if ((bindingAttr & BindingFlags.DeclaredOnly) == 0)
-                               {
-                                       if ((bindingAttr & BindingFlags.FlattenHierarchy) == 0)
+                                       if (memberName == name && (filter == null || filter((T)member)))
                                        {
-                                               bindingAttr &= ~BindingFlags.Static;
+                                               if (found != null)
+                                               {
+                                                       throw new AmbiguousMatchException();
+                                               }
+                                               found = (T)member;
                                        }
-                                       type = type.BaseType;
                                }
-                               else
+                       }
+                       if ((flags & BindingFlags.DeclaredOnly) == 0)
+                       {
+                               for (Type type = this.BaseType; (found == null || typeof(T) == typeof(MethodInfo)) && type != null; type = type.BaseType)
                                {
-                                       break;
+                                       type.CheckBaked();
+                                       foreach (MemberInfo member in type.GetMembers<T>())
+                                       {
+                                               if (member is T && member.BindingFlagsMatchInherited(flags))
+                                               {
+                                                       string memberName = member.Name;
+                                                       if ((flags & BindingFlags.IgnoreCase) != 0)
+                                                       {
+                                                               memberName = memberName.ToLowerInvariant();
+                                                       }
+                                                       if (memberName == name && (filter == null || filter((T)member)))
+                                                       {
+                                                               if (found != null)
+                                                               {
+                                                                       MethodInfo mi;
+                                                                       // TODO does this depend on HideBySig vs HideByName?
+                                                                       if ((mi = found as MethodInfo) != null
+                                                                               && mi.MethodSignature.MatchParameterTypes(((MethodBase)member).MethodSignature))
+                                                                       {
+                                                                               continue;
+                                                                       }
+                                                                       throw new AmbiguousMatchException();
+                                                               }
+                                                               found = (T)member.SetReflectedType(this);
+                                                       }
+                                               }
+                                       }
                                }
                        }
-                       return list.ToArray();
+                       return found;
+               }
+
+               private T GetMemberByName<T>(string name, BindingFlags flags)
+                       where T : MemberInfo
+               {
+                       return GetMemberByName<T>(name, flags, null);
+               }
+
+               public EventInfo GetEvent(string name)
+               {
+                       return GetEvent(name, BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static);
+               }
+
+               public EventInfo GetEvent(string name, BindingFlags bindingAttr)
+               {
+                       return GetMemberByName<EventInfo>(name, bindingAttr);
+               }
+
+               public EventInfo[] GetEvents()
+               {
+                       return GetEvents(BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static);
+               }
+
+               public EventInfo[] GetEvents(BindingFlags bindingAttr)
+               {
+                       return GetMembers<EventInfo>(bindingAttr);
                }
 
                public FieldInfo GetField(string name)
@@ -626,14 +729,7 @@ namespace IKVM.Reflection
 
                public FieldInfo GetField(string name, BindingFlags bindingAttr)
                {
-                       foreach (FieldInfo field in GetFields(bindingAttr))
-                       {
-                               if (field.Name == name)
-                               {
-                                       return field;
-                               }
-                       }
-                       return null;
+                       return GetMemberByName<FieldInfo>(name, bindingAttr);
                }
 
                public FieldInfo[] GetFields()
@@ -643,32 +739,7 @@ namespace IKVM.Reflection
 
                public FieldInfo[] GetFields(BindingFlags bindingAttr)
                {
-                       List<FieldInfo> list = new List<FieldInfo>();
-                       CheckBaked();
-                       foreach (FieldInfo field in __GetDeclaredFields())
-                       {
-                               if (BindingFlagsMatch(field.IsPublic, bindingAttr, BindingFlags.Public, BindingFlags.NonPublic)
-                                       && BindingFlagsMatch(field.IsStatic, bindingAttr, BindingFlags.Static, BindingFlags.Instance))
-                               {
-                                       list.Add(field);
-                               }
-                       }
-                       if ((bindingAttr & BindingFlags.DeclaredOnly) == 0)
-                       {
-                               for (Type type = this.BaseType; type != null; type = type.BaseType)
-                               {
-                                       type.CheckBaked();
-                                       foreach (FieldInfo field in type.__GetDeclaredFields())
-                                       {
-                                               if ((field.Attributes & FieldAttributes.FieldAccessMask) > FieldAttributes.Private
-                                                       && BindingFlagsMatch(field.IsStatic, bindingAttr, BindingFlags.Static | BindingFlags.FlattenHierarchy, BindingFlags.Instance))
-                                               {
-                                                       list.Add(field);
-                                               }
-                                       }
-                               }
-                       }
-                       return list.ToArray();
+                       return GetMembers<FieldInfo>(bindingAttr);
                }
 
                public Type[] GetInterfaces()
@@ -701,28 +772,42 @@ namespace IKVM.Reflection
                        foreach (MethodBase mb in __GetDeclaredMethods())
                        {
                                MethodInfo mi = mb as MethodInfo;
-                               if (mi != null
-                                       && BindingFlagsMatch(mi.IsPublic, bindingAttr, BindingFlags.Public, BindingFlags.NonPublic)
-                                       && BindingFlagsMatch(mi.IsStatic, bindingAttr, BindingFlags.Static, BindingFlags.Instance))
+                               if (mi != null && mi.BindingFlagsMatch(bindingAttr))
                                {
                                        list.Add(mi);
                                }
                        }
                        if ((bindingAttr & BindingFlags.DeclaredOnly) == 0)
                        {
+                               List<MethodInfo> baseMethods = new List<MethodInfo>();
+                               foreach (MethodInfo mi in list)
+                               {
+                                       if (mi.IsVirtual)
+                                       {
+                                               baseMethods.Add(mi.GetBaseDefinition());
+                                       }
+                               }
                                for (Type type = this.BaseType; type != null; type = type.BaseType)
                                {
                                        type.CheckBaked();
                                        foreach (MethodBase mb in type.__GetDeclaredMethods())
                                        {
                                                MethodInfo mi = mb as MethodInfo;
-                                               if (mi != null
-                                                       && (mi.Attributes & MethodAttributes.MemberAccessMask) > MethodAttributes.Private
-                                                       && BindingFlagsMatch(mi.IsPublic, bindingAttr, BindingFlags.Public, BindingFlags.NonPublic)
-                                                       && BindingFlagsMatch(mi.IsStatic, bindingAttr, BindingFlags.Static | BindingFlags.FlattenHierarchy, BindingFlags.Instance)
-                                                       && !FindMethod(list, mi))
+                                               if (mi != null && mi.BindingFlagsMatchInherited(bindingAttr))
                                                {
-                                                       list.Add(mi);
+                                                       if (mi.IsVirtual)
+                                                       {
+                                                               if (baseMethods == null)
+                                                               {
+                                                                       baseMethods = new List<MethodInfo>();
+                                                               }
+                                                               else if (FindMethod(baseMethods, mi.GetBaseDefinition()))
+                                                               {
+                                                                       continue;
+                                                               }
+                                                               baseMethods.Add(mi.GetBaseDefinition());
+                                                       }
+                                                       list.Add((MethodInfo)mi.SetReflectedType(this));
                                                }
                                        }
                                }
@@ -754,19 +839,7 @@ namespace IKVM.Reflection
 
                public MethodInfo GetMethod(string name, BindingFlags bindingAttr)
                {
-                       MethodInfo found = null;
-                       foreach (MethodInfo method in GetMethods(bindingAttr))
-                       {
-                               if (method.Name == name)
-                               {
-                                       if (found != null)
-                                       {
-                                               throw new AmbiguousMatchException();
-                                       }
-                                       found = method;
-                               }
-                       }
-                       return found;
+                       return GetMemberByName<MethodInfo>(name, bindingAttr);
                }
 
                public MethodInfo GetMethod(string name, Type[] types)
@@ -781,19 +854,21 @@ namespace IKVM.Reflection
 
                public MethodInfo GetMethod(string name, BindingFlags bindingAttr, Binder binder, Type[] types, ParameterModifier[] modifiers)
                {
-                       MethodInfo found = null;
-                       foreach (MethodInfo method in GetMethods(bindingAttr))
-                       {
-                               if (method.Name == name && method.MethodSignature.MatchParameterTypes(types))
-                               {
-                                       if (found != null)
-                                       {
-                                               throw new AmbiguousMatchException();
-                                       }
-                                       found = method;
-                               }
-                       }
-                       return found;
+                       // first we try an exact match and only if that fails we fall back to using the binder
+                       return GetMemberByName<MethodInfo>(name, bindingAttr,
+                               delegate(MethodInfo method) { return method.MethodSignature.MatchParameterTypes(types); })
+                               ?? GetMethodWithBinder<MethodInfo>(name, bindingAttr, binder ?? DefaultBinder, types, modifiers);
+               }
+
+               private T GetMethodWithBinder<T>(string name, BindingFlags bindingAttr, Binder binder, Type[] types, ParameterModifier[] modifiers)
+                       where T : MethodBase
+               {
+                       List<MethodBase> list = new List<MethodBase>();
+                       GetMemberByName<T>(name, bindingAttr, delegate(T method) {
+                               list.Add(method);
+                               return false;
+                       });
+                       return (T)binder.SelectMethod(bindingAttr, list.ToArray(), types, modifiers);
                }
 
                public MethodInfo GetMethod(string name, BindingFlags bindingAttr, Binder binder, CallingConventions callConvention, Type[] types, ParameterModifier[] modifiers)
@@ -809,19 +884,7 @@ namespace IKVM.Reflection
 
                public ConstructorInfo[] GetConstructors(BindingFlags bindingAttr)
                {
-                       CheckBaked();
-                       List<ConstructorInfo> list = new List<ConstructorInfo>();
-                       foreach (MethodBase mb in __GetDeclaredMethods())
-                       {
-                               ConstructorInfo constructor = mb as ConstructorInfo;
-                               if (constructor != null
-                                       && BindingFlagsMatch(constructor.IsPublic, bindingAttr, BindingFlags.Public, BindingFlags.NonPublic)
-                                       && BindingFlagsMatch(constructor.IsStatic, bindingAttr, BindingFlags.Static, BindingFlags.Instance))
-                               {
-                                       list.Add(constructor);
-                               }
-                       }
-                       return list.ToArray();
+                       return GetMembers<ConstructorInfo>(bindingAttr | BindingFlags.DeclaredOnly);
                }
 
                public ConstructorInfo GetConstructor(Type[] types)
@@ -831,14 +894,10 @@ namespace IKVM.Reflection
 
                public ConstructorInfo GetConstructor(BindingFlags bindingAttr, Binder binder, Type[] types, ParameterModifier[] modifiers)
                {
-                       foreach (ConstructorInfo constructor in GetConstructors(bindingAttr))
-                       {
-                               if (constructor.MethodSignature.MatchParameterTypes(types))
-                               {
-                                       return constructor;
-                               }
-                       }
-                       return null;
+                       // first we try an exact match and only if that fails we fall back to using the binder
+                       return GetMemberByName<ConstructorInfo>(ConstructorInfo.ConstructorName, bindingAttr | BindingFlags.DeclaredOnly,
+                               delegate(ConstructorInfo ctor) { return ctor.MethodSignature.MatchParameterTypes(types); })
+                               ?? GetMethodWithBinder<ConstructorInfo>(ConstructorInfo.ConstructorName, bindingAttr, binder ?? DefaultBinder, types, modifiers);
                }
 
                public ConstructorInfo GetConstructor(BindingFlags bindingAttr, Binder binder, CallingConventions callingConvention, Type[] types, ParameterModifier[] modifiers)
@@ -865,17 +924,11 @@ namespace IKVM.Reflection
                        return null;
                }
 
-               public Type GetNestedType(string name)
-               {
-                       return GetNestedType(name, BindingFlags.Public);
-               }
-
-               public Type GetNestedType(string name, BindingFlags bindingAttr)
+               internal virtual Type FindNestedTypeIgnoreCase(TypeName lowerCaseName)
                {
-                       foreach (Type type in GetNestedTypes(bindingAttr))
+                       foreach (Type type in __GetDeclaredTypes())
                        {
-                               // FXBUG the namespace is ignored
-                               if (type.__Name == name)
+                               if (new TypeName(type.__Namespace, type.__Name).ToLowerInvariant() == lowerCaseName)
                                {
                                        return type;
                                }
@@ -883,6 +936,17 @@ namespace IKVM.Reflection
                        return null;
                }
 
+               public Type GetNestedType(string name)
+               {
+                       return GetNestedType(name, BindingFlags.Public);
+               }
+
+               public Type GetNestedType(string name, BindingFlags bindingAttr)
+               {
+                       // FXBUG the namespace is ignored, so we can use GetMemberByName
+                       return GetMemberByName<Type>(name, bindingAttr | BindingFlags.DeclaredOnly);
+               }
+
                public Type[] GetNestedTypes()
                {
                        return GetNestedTypes(BindingFlags.Public);
@@ -890,16 +954,8 @@ namespace IKVM.Reflection
 
                public Type[] GetNestedTypes(BindingFlags bindingAttr)
                {
-                       CheckBaked();
-                       List<Type> list = new List<Type>();
-                       foreach (Type type in __GetDeclaredTypes())
-                       {
-                               if (BindingFlagsMatch(type.IsNestedPublic, bindingAttr, BindingFlags.Public, BindingFlags.NonPublic))
-                               {
-                                       list.Add(type);
-                               }
-                       }
-                       return list.ToArray();
+                       // FXBUG the namespace is ignored, so we can use GetMember
+                       return GetMembers<Type>(bindingAttr | BindingFlags.DeclaredOnly);
                }
 
                public PropertyInfo[] GetProperties()
@@ -909,33 +965,7 @@ namespace IKVM.Reflection
 
                public PropertyInfo[] GetProperties(BindingFlags bindingAttr)
                {
-                       List<PropertyInfo> list = new List<PropertyInfo>();
-                       Type type = this;
-                       while (type != null)
-                       {
-                               type.CheckBaked();
-                               foreach (PropertyInfo property in type.__GetDeclaredProperties())
-                               {
-                                       if (BindingFlagsMatch(property.IsPublic, bindingAttr, BindingFlags.Public, BindingFlags.NonPublic)
-                                               && BindingFlagsMatch(property.IsStatic, bindingAttr, BindingFlags.Static, BindingFlags.Instance))
-                                       {
-                                               list.Add(property);
-                                       }
-                               }
-                               if ((bindingAttr & BindingFlags.DeclaredOnly) == 0)
-                               {
-                                       if ((bindingAttr & BindingFlags.FlattenHierarchy) == 0)
-                                       {
-                                               bindingAttr &= ~BindingFlags.Static;
-                                       }
-                                       type = type.BaseType;
-                               }
-                               else
-                               {
-                                       break;
-                               }
-                       }
-                       return list.ToArray();
+                       return GetMembers<PropertyInfo>(bindingAttr);
                }
 
                public PropertyInfo GetProperty(string name)
@@ -945,64 +975,21 @@ namespace IKVM.Reflection
 
                public PropertyInfo GetProperty(string name, BindingFlags bindingAttr)
                {
-                       foreach (PropertyInfo prop in GetProperties(bindingAttr))
-                       {
-                               if (prop.Name == name)
-                               {
-                                       return prop;
-                               }
-                       }
-                       return null;
+                       return GetMemberByName<PropertyInfo>(name, bindingAttr);
                }
 
                public PropertyInfo GetProperty(string name, Type returnType)
                {
-                       PropertyInfo found = null;
-                       foreach (PropertyInfo prop in GetProperties())
-                       {
-                               if (prop.Name == name && prop.PropertyType.Equals(returnType))
-                               {
-                                       if (found != null)
-                                       {
-                                               throw new AmbiguousMatchException();
-                                       }
-                                       found = prop;
-                               }
-                       }
-                       return found;
+                       const BindingFlags flags = BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static;
+                       return GetMemberByName<PropertyInfo>(name, flags, delegate(PropertyInfo prop) { return prop.PropertyType.Equals(returnType); })
+                               ?? GetPropertyWithBinder(name, flags, DefaultBinder, returnType, null, null);
                }
 
                public PropertyInfo GetProperty(string name, Type[] types)
                {
-                       PropertyInfo found = null;
-                       foreach (PropertyInfo prop in GetProperties())
-                       {
-                               if (prop.Name == name && MatchParameterTypes(prop.GetIndexParameters(), types))
-                               {
-                                       if (found != null)
-                                       {
-                                               throw new AmbiguousMatchException();
-                                       }
-                                       found = prop;
-                               }
-                       }
-                       return found;
-               }
-
-               private static bool MatchParameterTypes(ParameterInfo[] parameters, Type[] types)
-               {
-                       if (parameters.Length == types.Length)
-                       {
-                               for (int i = 0; i < parameters.Length; i++)
-                               {
-                                       if (!parameters[i].ParameterType.Equals(types[i]))
-                                       {
-                                               return false;
-                                       }
-                               }
-                               return true;
-                       }
-                       return false;
+                       const BindingFlags flags = BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static;
+                       return GetMemberByName<PropertyInfo>(name, flags, delegate(PropertyInfo prop) { return prop.PropertySignature.MatchParameterTypes(types); })
+                               ?? GetPropertyWithBinder(name, flags, DefaultBinder, null, types, null);
                }
 
                public PropertyInfo GetProperty(string name, Type returnType, Type[] types)
@@ -1017,19 +1004,21 @@ namespace IKVM.Reflection
 
                public PropertyInfo GetProperty(string name, BindingFlags bindingAttr, Binder binder, Type returnType, Type[] types, ParameterModifier[] modifiers)
                {
-                       PropertyInfo found = null;
-                       foreach (PropertyInfo prop in GetProperties(bindingAttr))
-                       {
-                               if (prop.Name == name && prop.PropertyType.Equals(returnType) && MatchParameterTypes(prop.GetIndexParameters(), types))
-                               {
-                                       if (found != null)
-                                       {
-                                               throw new AmbiguousMatchException();
-                                       }
-                                       found = prop;
-                               }
-                       }
-                       return found;
+                       return GetMemberByName<PropertyInfo>(name, bindingAttr,
+                               delegate(PropertyInfo prop) {
+                                       return prop.PropertyType.Equals(returnType) && prop.PropertySignature.MatchParameterTypes(types);
+                               })
+                               ?? GetPropertyWithBinder(name, bindingAttr, binder ?? DefaultBinder, returnType, types, modifiers);
+               }
+
+               private PropertyInfo GetPropertyWithBinder(string name, BindingFlags bindingAttr, Binder binder, Type returnType, Type[] types, ParameterModifier[] modifiers)
+               {
+                       List<PropertyInfo> list = new List<PropertyInfo>();
+                       GetMemberByName<PropertyInfo>(name, bindingAttr, delegate(PropertyInfo property) {
+                               list.Add(property);
+                               return false;
+                       });
+                       return binder.SelectProperty(bindingAttr, list.ToArray(), returnType, types, modifiers);
                }
 
                public Type GetInterface(string name)
@@ -1041,16 +1030,26 @@ namespace IKVM.Reflection
                {
                        if (ignoreCase)
                        {
-                               throw new NotImplementedException();
+                               name = name.ToLowerInvariant();
                        }
+                       Type found = null;
                        foreach (Type type in GetInterfaces())
                        {
-                               if (type.FullName == name)
+                               string typeName = type.FullName;
+                               if (ignoreCase)
                                {
-                                       return type;
+                                       typeName = typeName.ToLowerInvariant();
+                               }
+                               if (typeName == name)
+                               {
+                                       if (found != null)
+                                       {
+                                               throw new AmbiguousMatchException();
+                                       }
+                                       found = type;
                                }
                        }
-                       return null;
+                       return found;
                }
 
                public Type[] FindInterfaces(TypeFilter filter, object filterCriteria)
@@ -1809,6 +1808,15 @@ namespace IKVM.Reflection
                        return __CreateMissingField(name, fieldType, CustomModifiers.FromReqOpt(requiredCustomModifiers, optionalCustomModifiers));
                }
 
+               public PropertyInfo __CreateMissingProperty(string name, CallingConventions callingConvention, Type propertyType, CustomModifiers propertyTypeCustomModifiers, Type[] parameterTypes, CustomModifiers[] parameterTypeCustomModifiers)
+               {
+                       PropertySignature sig = PropertySignature.Create(callingConvention,
+                               propertyType,
+                               parameterTypes,
+                               PackedCustomModifiers.CreateFromExternal(propertyTypeCustomModifiers, parameterTypeCustomModifiers, Util.NullSafeLength(parameterTypes)));
+                       return new MissingProperty(this, name, sig);
+               }
+
                internal virtual Type SetMetadataTokenForMissing(int token)
                {
                        return this;
@@ -1857,6 +1865,16 @@ namespace IKVM.Reflection
                {
                        get { return Module.universe; }
                }
+
+               internal sealed override bool BindingFlagsMatch(BindingFlags flags)
+               {
+                       return BindingFlagsMatch(IsNestedPublic, flags, BindingFlags.Public, BindingFlags.NonPublic);
+               }
+
+               internal sealed override MemberInfo SetReflectedType(Type type)
+               {
+                       throw new InvalidOperationException();
+               }
        }
 
        abstract class ElementHolderType : Type
index 22ff76c049cad1701fed064f7ad1f73b66f1a429..781fe1b358873c08a71a13381e7b52ec6f6b8596 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2009-2011 Jeroen Frijters
+  Copyright (C) 2009-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -23,6 +23,7 @@
 */
 using System;
 using System.Collections.Generic;
+using System.Diagnostics;
 using System.Text;
 
 namespace IKVM.Reflection
@@ -86,6 +87,11 @@ namespace IKVM.Reflection
                        return this == other;
                }
 
+               internal TypeName ToLowerInvariant()
+               {
+                       return new TypeName(ns == null ? null : ns.ToLowerInvariant(), name.ToLowerInvariant());
+               }
+
                internal static TypeName Split(string name)
                {
                        int dot = name.LastIndexOf('.');
@@ -449,8 +455,9 @@ namespace IKVM.Reflection
                        }
                }
 
-               internal Type GetType(Universe universe, Assembly context, bool throwOnError, string originalName, bool resolve)
+               internal Type GetType(Universe universe, Assembly context, bool throwOnError, string originalName, bool resolve, bool ignoreCase)
                {
+                       Debug.Assert(!resolve || !ignoreCase);
                        TypeName name = TypeName.Split(this.name);
                        Type type;
                        if (assemblyName != null)
@@ -464,6 +471,10 @@ namespace IKVM.Reflection
                                {
                                        type = asm.ResolveType(name);
                                }
+                               else if (ignoreCase)
+                               {
+                                       type = asm.FindTypeIgnoreCase(name.ToLowerInvariant());
+                               }
                                else
                                {
                                        type = asm.FindType(name);
@@ -475,6 +486,10 @@ namespace IKVM.Reflection
                                {
                                        type = universe.Mscorlib.ResolveType(name);
                                }
+                               else if (ignoreCase)
+                               {
+                                       type = universe.Mscorlib.FindTypeIgnoreCase(name.ToLowerInvariant());
+                               }
                                else
                                {
                                        type = universe.Mscorlib.FindType(name);
@@ -482,10 +497,25 @@ namespace IKVM.Reflection
                        }
                        else
                        {
-                               type = context.FindType(name);
+                               if (ignoreCase)
+                               {
+                                       name = name.ToLowerInvariant();
+                                       type = context.FindTypeIgnoreCase(name);
+                               }
+                               else
+                               {
+                                       type = context.FindType(name);
+                               }
                                if (type == null && context != universe.Mscorlib)
                                {
-                                       type = universe.Mscorlib.FindType(name);
+                                       if (ignoreCase)
+                                       {
+                                               type = universe.Mscorlib.FindTypeIgnoreCase(name);
+                                       }
+                                       else
+                                       {
+                                               type = universe.Mscorlib.FindType(name);
+                                       }
                                }
                                if (type == null && resolve)
                                {
@@ -499,11 +529,12 @@ namespace IKVM.Reflection
                                        }
                                }
                        }
-                       return Expand(type, context, throwOnError, originalName, resolve);
+                       return Expand(type, context, throwOnError, originalName, resolve, ignoreCase);
                }
 
-               internal Type Expand(Type type, Assembly context, bool throwOnError, string originalName, bool resolve)
+               internal Type Expand(Type type, Assembly context, bool throwOnError, string originalName, bool resolve, bool ignoreCase)
                {
+                       Debug.Assert(!resolve || !ignoreCase);
                        if (type == null)
                        {
                                if (throwOnError)
@@ -519,7 +550,9 @@ namespace IKVM.Reflection
                                {
                                        outer = type;
                                        TypeName name = TypeName.Split(TypeNameParser.Unescape(nest));
-                                       type = outer.FindNestedType(name);
+                                       type = ignoreCase
+                                               ? outer.FindNestedTypeIgnoreCase(name.ToLowerInvariant())
+                                               : outer.FindNestedType(name);
                                        if (type == null)
                                        {
                                                if (resolve)
@@ -542,7 +575,7 @@ namespace IKVM.Reflection
                                Type[] typeArgs = new Type[genericParameters.Length];
                                for (int i = 0; i < typeArgs.Length; i++)
                                {
-                                       typeArgs[i] = genericParameters[i].GetType(type.Assembly.universe, context, throwOnError, originalName, resolve);
+                                       typeArgs[i] = genericParameters[i].GetType(type.Assembly.universe, context, throwOnError, originalName, resolve, ignoreCase);
                                        if (typeArgs[i] == null)
                                        {
                                                return null;
index a59da44b8d2371cd4a0f7d4cb4cb11a4b6cc5947..2ae8c62bd9e00fab04837658f66332104d51217e 100644 (file)
@@ -153,6 +153,7 @@ namespace IKVM.Reflection
                private Type typeof_System_Security_Permissions_PermissionSetAttribute;
                private Type typeof_System_Security_Permissions_SecurityAction;
                private List<ResolveEventHandler> resolvers = new List<ResolveEventHandler>();
+               private Predicate<Type> missingTypeIsValueType;
 
                public Universe()
                        : this(UniverseOptions.None)
@@ -776,26 +777,40 @@ namespace IKVM.Reflection
                {
                        // to be more compatible with Type.GetType(), we could call Assembly.GetCallingAssembly(),
                        // import that assembly and pass it as the context, but implicitly importing is considered evil
-                       return GetType(null, assemblyQualifiedTypeName, false);
+                       return GetType(null, assemblyQualifiedTypeName, false, false);
                }
 
                public Type GetType(string assemblyQualifiedTypeName, bool throwOnError)
                {
                        // to be more compatible with Type.GetType(), we could call Assembly.GetCallingAssembly(),
                        // import that assembly and pass it as the context, but implicitly importing is considered evil
-                       return GetType(null, assemblyQualifiedTypeName, throwOnError);
+                       return GetType(null, assemblyQualifiedTypeName, throwOnError, false);
+               }
+
+               public Type GetType(string assemblyQualifiedTypeName, bool throwOnError, bool ignoreCase)
+               {
+                       // to be more compatible with Type.GetType(), we could call Assembly.GetCallingAssembly(),
+                       // import that assembly and pass it as the context, but implicitly importing is considered evil
+                       return GetType(null, assemblyQualifiedTypeName, throwOnError, ignoreCase);
                }
 
                // note that context is slightly different from the calling assembly (System.Type.GetType),
                // because context is passed to the AssemblyResolve event as the RequestingAssembly
                public Type GetType(Assembly context, string assemblyQualifiedTypeName, bool throwOnError)
+               {
+                       return GetType(context, assemblyQualifiedTypeName, throwOnError, false);
+               }
+
+               // note that context is slightly different from the calling assembly (System.Type.GetType),
+               // because context is passed to the AssemblyResolve event as the RequestingAssembly
+               public Type GetType(Assembly context, string assemblyQualifiedTypeName, bool throwOnError, bool ignoreCase)
                {
                        TypeNameParser parser = TypeNameParser.Parse(assemblyQualifiedTypeName, throwOnError);
                        if (parser.Error)
                        {
                                return null;
                        }
-                       return parser.GetType(this, context, throwOnError, assemblyQualifiedTypeName, false);
+                       return parser.GetType(this, context, throwOnError, assemblyQualifiedTypeName, false, ignoreCase);
                }
 
                // this is similar to GetType(Assembly context, string assemblyQualifiedTypeName, bool throwOnError),
@@ -808,7 +823,7 @@ namespace IKVM.Reflection
                        {
                                return null;
                        }
-                       return parser.GetType(this, context, false, assemblyQualifiedTypeName, true);
+                       return parser.GetType(this, context, false, assemblyQualifiedTypeName, true, false);
                }
 
                public Assembly[] GetAssemblies()
@@ -1032,5 +1047,33 @@ namespace IKVM.Reflection
                        return new __StandAloneMethodSig(false, 0, callingConvention, returnType ?? this.System_Void, Util.Copy(parameterTypes), Util.Copy(optionalParameterTypes),
                                PackedCustomModifiers.CreateFromExternal(returnTypeCustomModifiers, parameterTypeCustomModifiers, Util.NullSafeLength(parameterTypes) + Util.NullSafeLength(optionalParameterTypes)));
                }
+
+               public event Predicate<Type> MissingTypeIsValueType
+               {
+                       add
+                       {
+                               if (missingTypeIsValueType != null)
+                               {
+                                       throw new InvalidOperationException("Only a single MissingTypeIsValueType handler can be registered.");
+                               }
+                               missingTypeIsValueType = value;
+                       }
+                       remove
+                       {
+                               if (value.Equals(missingTypeIsValueType))
+                               {
+                                       missingTypeIsValueType = null;
+                               }
+                       }
+               }
+
+               internal bool ResolveMissingTypeIsValueType(MissingType missingType)
+               {
+                       if (missingTypeIsValueType != null)
+                       {
+                               return missingTypeIsValueType(missingType);
+                       }
+                       throw new MissingMemberException(missingType);
+               }
        }
 }
index ff82c9d24562e7f36ccbf506258226c06c35a7d5..64cf009836bf9c78a53e44799caeae57d80dc3cc 100644 (file)
@@ -95,6 +95,7 @@ namespace IKVM.Reflection.Writer
                        }
 
                        PEWriter writer = new PEWriter(stream);
+                       writer.Headers.OptionalHeader.FileAlignment = (uint)moduleBuilder.__FileAlignment;
                        switch (imageFileMachine)
                        {
                                case ImageFileMachine.I386:
@@ -142,11 +143,7 @@ namespace IKVM.Reflection.Writer
                                        writer.Headers.OptionalHeader.Subsystem = IMAGE_OPTIONAL_HEADER.IMAGE_SUBSYSTEM_WINDOWS_CUI;
                                        break;
                        }
-                       writer.Headers.OptionalHeader.DllCharacteristics =
-                               IMAGE_OPTIONAL_HEADER.IMAGE_DLLCHARACTERISTICS_DYNAMIC_BASE |
-                               IMAGE_OPTIONAL_HEADER.IMAGE_DLLCHARACTERISTICS_NO_SEH |
-                               IMAGE_OPTIONAL_HEADER.IMAGE_DLLCHARACTERISTICS_NX_COMPAT |
-                               IMAGE_OPTIONAL_HEADER.IMAGE_DLLCHARACTERISTICS_TERMINAL_SERVER_AWARE;
+                       writer.Headers.OptionalHeader.DllCharacteristics = (ushort)moduleBuilder.__DllCharacteristics;
 
                        CliHeader cliHeader = new CliHeader();
                        cliHeader.Cb = 0x48;
index 66b7f7ced8534b3c56c5e37e5400bce855c76d4e..665296e6bd8e67834225f1d6b98b20f877851515 100644 (file)
@@ -162,13 +162,6 @@ namespace IKVM.Reflection.Writer
                public const WORD IMAGE_SUBSYSTEM_WINDOWS_GUI = 2;
                public const WORD IMAGE_SUBSYSTEM_WINDOWS_CUI = 3;
 
-               public const WORD IMAGE_DLLCHARACTERISTICS_HIGH_ENTROPY_VA = 0x0020;
-               public const WORD IMAGE_DLLCHARACTERISTICS_DYNAMIC_BASE = 0x0040;
-               public const WORD IMAGE_DLLCHARACTERISTICS_NX_COMPAT = 0x0100;
-               public const WORD IMAGE_DLLCHARACTERISTICS_NO_SEH = 0x0400;
-               public const WORD IMAGE_DLLCHARACTERISTICS_APPCONTAINER = 0x1000;
-               public const WORD IMAGE_DLLCHARACTERISTICS_TERMINAL_SERVER_AWARE = 0x8000;
-
                public WORD Magic = IMAGE_NT_OPTIONAL_HDR32_MAGIC;
                public BYTE MajorLinkerVersion = 8;
                public BYTE MinorLinkerVersion = 0;
@@ -180,7 +173,7 @@ namespace IKVM.Reflection.Writer
                public DWORD BaseOfData;
                public ULONGLONG ImageBase;
                public DWORD SectionAlignment = 0x2000;
-               public DWORD FileAlignment = 0x200;
+               public DWORD FileAlignment;
                public WORD MajorOperatingSystemVersion = 4;
                public WORD MinorOperatingSystemVersion = 0;
                public WORD MajorImageVersion = 0;
index 81941e246bc9913a5720c48e48458e1b7f2c0ba6..3789ca2c99d78a417046a283b1566cf80cb32fb5 100644 (file)
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2010 Jeroen Frijters
+  Copyright (C) 2010-2012 Jeroen Frijters
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -34,6 +34,7 @@ namespace IKVM.Reflection.Writer
                private const int RT_ICON = 3;
                private const int RT_GROUP_ICON = 14;
                private const int RT_VERSION = 16;
+               private const int RT_MANIFEST = 24;
                private ResourceDirectoryEntry root = new ResourceDirectoryEntry(new OrdinalOrName("root"));
                private ByteBuffer bb;
                private List<int> linkOffsets;
@@ -87,6 +88,11 @@ namespace IKVM.Reflection.Writer
                        root[new OrdinalOrName(RT_GROUP_ICON)][new OrdinalOrName(32512)][new OrdinalOrName(0)].Data = group;
                }
 
+               internal void AddManifest(byte[] manifest, ushort resourceID)
+               {
+                       root[new OrdinalOrName(RT_MANIFEST)][new OrdinalOrName(resourceID)][new OrdinalOrName(0)].Data = ByteBuffer.Wrap(manifest);
+               }
+
                internal void ExtractResources(byte[] buf)
                {
                        ByteReader br = new ByteReader(buf, 0, buf.Length);
@@ -147,21 +153,40 @@ namespace IKVM.Reflection.Writer
                        {
                                foreach (ResourceDirectoryEntry entry in entries)
                                {
-                                       if (entry.OrdinalOrName.Ordinal == id.Ordinal && entry.OrdinalOrName.Name == id.Name)
+                                       if (entry.OrdinalOrName.IsEqual(id))
                                        {
                                                return entry;
                                        }
                                }
+                               // the entries must be sorted
                                ResourceDirectoryEntry newEntry = new ResourceDirectoryEntry(id);
                                if (id.Name == null)
                                {
+                                       for (int i = namedEntries; i < entries.Count; i++)
+                                       {
+                                               if (entries[i].OrdinalOrName.IsGreaterThan(id))
+                                               {
+                                                       entries.Insert(i, newEntry);
+                                                       return newEntry;
+                                               }
+                                       }
                                        entries.Add(newEntry);
+                                       return newEntry;
                                }
                                else
                                {
+                                       for (int i = 0; i < namedEntries; i++)
+                                       {
+                                               if (entries[i].OrdinalOrName.IsGreaterThan(id))
+                                               {
+                                                       entries.Insert(i, newEntry);
+                                                       namedEntries++;
+                                                       return newEntry;
+                                               }
+                                       }
                                        entries.Insert(namedEntries++, newEntry);
+                                       return newEntry;
                                }
-                               return newEntry;
                        }
                }
 
@@ -322,6 +347,20 @@ namespace IKVM.Reflection.Writer
                        Ordinal = 0xFFFF;
                        Name = value;
                }
+
+               internal bool IsGreaterThan(OrdinalOrName other)
+               {
+                       return this.Name == null
+                               ? this.Ordinal > other.Ordinal
+                               : String.Compare(this.Name, other.Name, StringComparison.OrdinalIgnoreCase) > 0;
+               }
+
+               internal bool IsEqual(OrdinalOrName other)
+               {
+                       return this.Name == null
+                               ? this.Ordinal == other.Ordinal
+                               : String.Compare(this.Name, other.Name, StringComparison.OrdinalIgnoreCase) == 0;
+               }
        }
 
        struct RESOURCEHEADER
index 0f2b9f949faac93b2a2a89747d57ef239e8dd566..186ec2417f8660c0601716f1425ad7e64db3bda0 100644 (file)
@@ -179,7 +179,6 @@ net_4_0_dirs := \
        System.ServiceModel.Discovery \
        System.Runtime.Caching \
        System.Runtime.DurableInstancing \
-       Mono.CodeContracts \
        Mono.Parallel \
        Microsoft.Web.Infrastructure \
        WebMatrix.Data \
@@ -193,7 +192,15 @@ net_4_0_only_dirs := \
 net_4_5_dirs := \
        System.Threading.Tasks.Dataflow \
        System.ComponentModel.Composition.4.5 \
-       System.Net.Http
+       System.Net.Http \
+       System.Web.Razor \
+       System.Web.WebPages.Deployment \
+       System.Web.WebPages \
+       System.Web.WebPages.Razor \
+       System.Web.Mvc3 \
+       System.Net.Http.Formatting \
+       System.Web.Http \
+       Mono.CodeContracts
 
 net_2_0_SUBDIRS := $(common_dirs) $(net_2_0_dirs) $(net_2_0_only_dirs) aot-compiler
 moonlight_raw_SUBDIRS := $(moonlight_raw_dirs)
index 2e09acd069295b8cd0c4f8c6bc6846c438896907..4f96023a6c81750740b96816e1ad30f199d91360 100644 (file)
@@ -8,13 +8,10 @@ LIB_MCS_FLAGS = /unsafe \
        /r:System.Drawing.dll /r:Accessibility.dll \
        /r:System.Data.dll /r:Mono.Posix.dll \
        /r:Mono.WebBrowser \
+       /r:System.Configuration.dll \
        @System.Windows.Forms.dll.resources \
        -nowarn:618,612,809
 
-ifneq (1, $(FRAMEWORK_VERSION_MAJOR))
-LIB_MCS_FLAGS += /r:System.Configuration.dll
-endif
-
 ifeq (true, $(GENERATE_RESOURCES))
 LIB_MCS_FLAGS += /define:GENERATING_RESOURCES
 endif
@@ -103,7 +100,7 @@ EXTRA_DISTFILES = \
        $(IMAGES_RESOURCES) \
        $(TEST_DISTFILES)
 
-TEST_MCS_FLAGS = /r:System.Data.dll /r:System.Drawing.dll /r:Accessibility.dll \
+TEST_MCS_FLAGS = /r:System.Data.dll /r:System.Drawing.dll /r:Accessibility.dll -r:System.dll -r:System.Xml.dll \
        -resource:Test/resources/a.cur,a.cur \
        -resource:Test/resources/32x32.ico,32x32.ico \
        -nowarn:618,612
index 21e4c323b50f765204e7253549606b517a258a12..5ae732ad083387474ea996854477bcbc5e205a69 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 72e0d08d7615ae75c34dfab3284332e68e00eaca..3d0422da9681bb559738c91ffcb3d08b4f9339f4 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2e75c5c5417772da2c2c1637de6ef1b532461454..8a4329b39ec10b3ce8f8c3df1a692531c59e081f 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 59106f78c330ad19825e71d8f6446344ee68fd7e..3fbb9a960804816f00d5845d469ecabd44efd02b 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Accessibility.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index de432e9c0dcded1f2ae01e5818324511081f0518..73c499f9afec05db31b465106ac677f3708799dc 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Accessibility.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 6a81b1a241d5985b4e380be9b8610a75e4aecb60..e416e19859aef88361176a72e37fec082dde47fc 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Accessibility.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 674da0583bf42bf24724b4a2f550f7e4ed9daeb1..59d0086aafb3291c8ea38c56700cbeb13c89fe4d 100644 (file)
@@ -66,7 +66,7 @@ namespace System.Windows.Forms {
                        IntPtr clipboard_handle;
 
                        clipboard_handle = XplatUI.ClipboardOpen (false);
-                       XplatUI.ClipboardStore (clipboard_handle, null, 0, null);
+                       XplatUI.ClipboardStore (clipboard_handle, null, 0, null, false);
                }
 
                public static bool ContainsAudio ()
@@ -240,7 +240,7 @@ namespace System.Windows.Forms {
                        converter = new XplatUI.ObjectToClipboard(ConvertToClipboardData);
 
                        clipboard_handle = XplatUI.ClipboardOpen(false);
-                       XplatUI.ClipboardStore(clipboard_handle, null, 0, null);        // Empty clipboard
+                       XplatUI.ClipboardStore(clipboard_handle, null, 0, null, copy);  // Empty clipboard
 
                        native_format = -1;
 
@@ -261,7 +261,7 @@ namespace System.Windows.Forms {
                                        if (IsDataSerializable (obj))
                                                item_format.is_serializable = true;
 
-                                       XplatUI.ClipboardStore(clipboard_handle, obj, native_format, converter);
+                                       XplatUI.ClipboardStore(clipboard_handle, obj, native_format, converter, copy);
                                }
                        } else {
                                item_format = DataFormats.Format.Find(data.GetType().FullName);
@@ -269,7 +269,7 @@ namespace System.Windows.Forms {
                                        native_format = item_format.Id;
                                }
 
-                               XplatUI.ClipboardStore(clipboard_handle, data, native_format, converter);
+                               XplatUI.ClipboardStore(clipboard_handle, data, native_format, converter, copy);
                        }
                        XplatUI.ClipboardClose(clipboard_handle);
                }
index ad14ddaefbe7e0fa32999b41ac611b647992399d..e91853f0fd77d9e7f639e42b9d00ec12a2e7c3a9 100644 (file)
@@ -2531,13 +2531,26 @@ namespace System.Windows.Forms
                        public int Add (object item)
                        {
                                int idx;
+                               object[] selectedItems = null;
+
+                               // we need to remember the original selected items so that we can update the indices
+                               if (owner.sorted) {
+                                       selectedItems = new object[owner.SelectedItems.Count];
+                                       owner.SelectedItems.CopyTo (selectedItems, 0);
+                               }
 
                                idx = AddItem (item);
                                owner.CollectionChanged ();
                                
                                // If we are sorted, the item probably moved indexes, get the real one
-                               if (owner.sorted)
+                               if (owner.sorted) {
+                                       // update indices of selected items
+                                       owner.SelectedIndices.Clear ();
+                                       for (int i = 0; i < selectedItems.Length; i++) {
+                                               owner.SelectedIndex = this.IndexOf (selectedItems [i]);
+                                       }
                                        return this.IndexOf (item);
+                               }
                                        
                                return idx;
                        }
index 380d11e8e0d810dc638c1ccb7890023d8abe4a4a..18ee3dd8117ad2359379172886bca6eef8afec92 100644 (file)
@@ -187,8 +187,7 @@ namespace System.Windows.Forms
        internal abstract class Theme
        {
                protected Array syscolors;
-               private readonly Font default_font;
-               protected Font window_border_font;
+               Font default_font;
                protected Color defaultWindowBackColor;
                protected Color defaultWindowForeColor;
                internal SystemResPool ResPool = new SystemResPool ();
@@ -196,8 +195,6 @@ namespace System.Windows.Forms
 
                protected Theme ()
                {
-                       default_font = SystemFonts.DefaultFont;
-                       syscolors = null;
                }
 
                private void SetSystemColors (KnownColor kc, Color value)
@@ -358,7 +355,7 @@ namespace System.Windows.Forms
                }
 
                public virtual Font DefaultFont {
-                       get { return default_font; }
+                       get { return default_font ?? (default_font = SystemFonts.DefaultFont); }
                }
 
                public virtual Color DefaultWindowBackColor {
@@ -504,7 +501,7 @@ namespace System.Windows.Forms
 
                public virtual Font MenuFont {
                        get {
-                               return default_font;
+                               return default_font ?? (default_font = SystemFonts.DefaultFont);
                        }
                }
 
@@ -558,10 +555,8 @@ namespace System.Windows.Forms
                        }
                }
 
-               public virtual Font WindowBorderFont {
-                       get {
-                               return window_border_font;
-                       }
+               public abstract Font WindowBorderFont {
+                       get;
                }
 
                public int Clamp (int value, int lower, int upper)
index 1ce07bf75e2ac1579b1c3938acaad03792c926fa..c9603aad23dae6d8c94b87feb8baac100b0df008 100644 (file)
@@ -54,7 +54,8 @@ namespace System.Windows.Forms
                protected static StringFormat string_format_menu_text;
                protected static StringFormat string_format_menu_shortcut;
                protected static StringFormat string_format_menu_menubar_text;
-               static ImageAttributes imagedisabled_attributes = null;
+               static ImageAttributes imagedisabled_attributes;
+               Font window_border_font;
                const int SEPARATOR_HEIGHT = 6;
                const int SEPARATOR_MIN_WIDTH = 20;
                const int SM_CXBORDER = 1;
@@ -71,7 +72,7 @@ namespace System.Windows.Forms
                public override void ResetDefaults() {
                        defaultWindowBackColor = this.ColorWindow;
                        defaultWindowForeColor = this.ColorControlText;
-                       window_border_font = new Font(FontFamily.GenericSansSerif, 8.25f, FontStyle.Bold);
+                       window_border_font = null;
                        
                        /* Menu string formats */
                        string_format_menu_text = new StringFormat ();
@@ -106,6 +107,12 @@ namespace System.Windows.Forms
                                return XplatUI.VerticalScrollBarWidth;
                        }
                }
+               
+               public override Font WindowBorderFont {
+                       get {
+                               return window_border_font ?? (window_border_font = new Font(FontFamily.GenericSansSerif, 8.25f, FontStyle.Bold));
+                       }
+               }
 
                #endregion      // Principal Theme Methods
 
index bb1169338146656753e9ef9e667f729472c0f35b..bd5557091eca48370bd369f54e76a546061ce283 100644 (file)
@@ -353,6 +353,8 @@ namespace System.Windows.Forms {
                                tree_view.RecalculateVisibleOrder (prev);
 
                                if (removed == tree_view.SelectedNode) {
+                                       if (removed.IsExpanded)
+                                               removed.Collapse();     // Fix Xamarin Bugzilla 5010.
                                        re_set_selected = true;
                                        OpenTreeNodeEnumerator oe = new OpenTreeNodeEnumerator (removed);
                                        if (oe.MoveNext () && oe.MoveNext ()) {
index dcebf2fe4792bec2cdbace1b2359e540d906e854..89f91da939c0baf542260b71880a5ca72601da80 100644 (file)
@@ -549,10 +549,10 @@ namespace System.Windows.Forms {
                        return driver.ClipboardOpen (primary_selection);
                }
 
-               internal static void ClipboardStore (IntPtr handle, object obj, int type, XplatUI.ObjectToClipboard converter)
+               internal static void ClipboardStore (IntPtr handle, object obj, int type, XplatUI.ObjectToClipboard converter, bool copy)
                {
-                       DriverDebug ("ClipboardStore ({0:X}, {1}, {2}): Called", handle.ToInt32 (), obj, type, converter);
-                       driver.ClipboardStore (handle, obj, type, converter);
+                       DriverDebug ("ClipboardStore ({0:X}, {1}, {2}, {3}, {4}): Called", handle.ToInt32 (), obj, type, converter, copy);
+                       driver.ClipboardStore (handle, obj, type, converter, copy);
                }
 
                internal static object ClipboardRetrieve (IntPtr handle, int type, XplatUI.ClipboardToObject converter)
index 47e0c9f845acdd780b83769effbff36d196d8aec..18afe41221fbf888cac28d6393c84225ae3788ad 100644 (file)
@@ -874,7 +874,7 @@ namespace System.Windows.Forms {
                        return Carbon.Pasteboard.Retrieve (handle, type);
                }
 
-               internal override void ClipboardStore(IntPtr handle, object obj, int type, XplatUI.ObjectToClipboard converter) {
+               internal override void ClipboardStore(IntPtr handle, object obj, int type, XplatUI.ObjectToClipboard converter, bool copy) {
                        Carbon.Pasteboard.Store (handle, obj, type);
                }
                
index 3adc21522ff9deac227d0eb0abdb235168adce94..b79b967566cf9eb257748c133b24bd562142b7e7 100644 (file)
@@ -399,7 +399,7 @@ namespace System.Windows.Forms {
                internal abstract void ClipboardClose(IntPtr handle);
                internal abstract IntPtr ClipboardOpen (bool primary_selection);
                internal abstract int ClipboardGetID(IntPtr handle, string format);
-               internal abstract void ClipboardStore(IntPtr handle, object obj, int id, XplatUI.ObjectToClipboard converter);
+               internal abstract void ClipboardStore(IntPtr handle, object obj, int id, XplatUI.ObjectToClipboard converter, bool copy);
                internal abstract int[] ClipboardAvailableFormats(IntPtr handle);
                internal abstract object ClipboardRetrieve(IntPtr handle, int id, XplatUI.ClipboardToObject converter);
 
index 4f27cd713520340ad449c7fca9de13d9944da09c..efc464d5d124bb11c44f58f23b742727b2c59bac 100644 (file)
@@ -2908,7 +2908,8 @@ namespace System.Windows.Forms {
 
                }
 
-               internal override void ClipboardStore(IntPtr handle, object obj, int type, XplatUI.ObjectToClipboard converter) {
+               internal override void ClipboardStore(IntPtr handle, object obj, int type, XplatUI.ObjectToClipboard converter, bool copy)
+               {
                        byte[]  data = null;
 
                        if (handle != clip_magic) {
index d00c40d13be29a7a7673c5411911aa221f8b4faf..9b6c13014ae6d2159435b29307feacd854fc902c 100644 (file)
@@ -1270,9 +1270,20 @@ namespace System.Windows.Forms {
 
                        if ((long)nitems > 0) {
                                if (property == (IntPtr)Atom.XA_STRING) {
+                                       // Xamarin-5116: PtrToStringAnsi expects to get UTF-8, but we might have
+                                       // Latin-1 instead.
+                                       var s = Marshal.PtrToStringAnsi (prop);
+                                       if (string.IsNullOrEmpty (s)) {
+                                               var sb = new StringBuilder ();
+                                               for (int i = 0; i < (int)nitems; i++) {
+                                                       var b = Marshal.ReadByte (prop, i);
+                                                       sb.Append ((char)b);
+                                               }
+                                               s = sb.ToString ();
+                                       }
                                        // Some X managers/apps pass unicode chars as escaped strings, so
                                        // we may need to unescape them.
-                                       Clipboard.Item = UnescapeUnicodeFromAnsi (Marshal.PtrToStringAnsi(prop));
+                                       Clipboard.Item = UnescapeUnicodeFromAnsi (s);
                                } else if (property == (IntPtr)Atom.XA_BITMAP) {
                                        // FIXME - convert bitmap to image
                                } else if (property == (IntPtr)Atom.XA_PIXMAP) {
@@ -1325,7 +1336,7 @@ namespace System.Windows.Forms {
 
                                int length = 0;
                                while (pos < value.Length) {
-                                       if (!Char.IsLetterOrDigit (value [pos]))
+                                       if (!ValidHexDigit (value [pos]))
                                                break;
                                        length++;
                                        pos++;
@@ -1347,6 +1358,11 @@ namespace System.Windows.Forms {
                        return sb.ToString ();
                }
 
+               private static bool ValidHexDigit (char e)
+               {
+                       return Char.IsDigit (e) || (e >= 'A' && e <= 'F') || (e >= 'a' && e <= 'f');
+               }
+
                void AddExpose (Hwnd hwnd, bool client, int x, int y, int width, int height) {
                        // Don't waste time
                        if ((hwnd == null) || (x > hwnd.Width) || (y > hwnd.Height) || ((x + width) < 0) || ((y + height) < 0)) {
@@ -2772,17 +2788,36 @@ namespace System.Windows.Forms {
                        return Clipboard.Item;
                }
 
-               internal override void ClipboardStore(IntPtr handle, object obj, int type, XplatUI.ObjectToClipboard converter)
+               internal override void ClipboardStore (IntPtr handle, object obj, int type, XplatUI.ObjectToClipboard converter, bool copy)
                {
                        Clipboard.Converter = converter;
 
                        if (obj != null) {
                                Clipboard.AddSource (type, obj);
-                               XSetSelectionOwner(DisplayHandle, CLIPBOARD, FosterParent, IntPtr.Zero);
+                               XSetSelectionOwner (DisplayHandle, CLIPBOARD, FosterParent, IntPtr.Zero);
+
+                               if (copy) {
+                                       try {
+                                               var clipboardAtom = gdk_atom_intern ("CLIPBOARD", true);
+                                               var clipboard = gtk_clipboard_get (clipboardAtom);
+                                               if (clipboard != null) {
+                                                       // for now we only store text
+                                                       var text = Clipboard.GetRtfText ();
+                                                       if (string.IsNullOrEmpty (text))
+                                                               text = Clipboard.GetPlainText ();
+                                                       if (!string.IsNullOrEmpty (text)) {
+                                                               gtk_clipboard_set_text (clipboard, text, text.Length);
+                                                               gtk_clipboard_store (clipboard);
+                                                       }
+                                               }
+                                       } catch {
+                                               // ignore any errors - most likely because gtk isn't installed?
+                                       }
+                               }
                        } else {
                                // Clearing the selection
                                Clipboard.ClearSources ();
-                               XSetSelectionOwner(DisplayHandle, CLIPBOARD, IntPtr.Zero, IntPtr.Zero);
+                               XSetSelectionOwner (DisplayHandle, CLIPBOARD, IntPtr.Zero, IntPtr.Zero);
                        }
                }
 
@@ -3768,6 +3803,10 @@ namespace System.Windows.Forms {
                        if (((long)nitems > 0) && (prop != IntPtr.Zero)) {
                                active = (IntPtr)Marshal.ReadInt32(prop);
                                XFree(prop);
+                       } else {
+                               // The window manager does not support _NET_ACTIVE_WINDOW.  Fall back to XGetInputFocus.
+                               IntPtr  revert_to = IntPtr.Zero;
+                               XGetInputFocus(DisplayHandle, out active, out revert_to);
                        }
 
                        if (active != IntPtr.Zero) {
@@ -7526,7 +7565,24 @@ namespace System.Windows.Forms {
 
                [DllImport ("libX11", EntryPoint="XIfEvent")]
                internal extern static void XIfEvent (IntPtr display, ref XEvent xevent, Delegate event_predicate, IntPtr arg);
+
+               [DllImport ("libX11", EntryPoint="XGetInputFocus")]
+               internal extern static void XGetInputFocus (IntPtr display, out IntPtr focus, out IntPtr revert_to);
                #endregion
+#region Gtk/Gdk imports
+               [DllImport("libgdk-x11-2.0")]
+               internal extern static IntPtr gdk_atom_intern (string atomName, bool onlyIfExists);
+
+               [DllImport("libgtk-x11-2.0")]
+               internal extern static IntPtr gtk_clipboard_get (IntPtr atom);
+
+               [DllImport("libgtk-x11-2.0")]
+               internal extern static void gtk_clipboard_store (IntPtr clipboard);
+
+               [DllImport("libgtk-x11-2.0")]
+               internal extern static void gtk_clipboard_set_text (IntPtr clipboard, string text, int len);
+#endregion
+
 #endif
        }
 }
index 66832bc9131f25a8912e3bbe6d9f86cac102fd47..f90a1b98c1274b9676dba4f8550b28333a30fc36 100644 (file)
@@ -24,6 +24,9 @@
 //
 
 using System;
+using System.CodeDom.Compiler;
+using System.Diagnostics;
+using System.IO;
 using System.Text;
 using System.Windows.Forms;
 using NUnit.Framework;
@@ -99,6 +102,82 @@ namespace MonoTests.System.Windows.Forms
                        public string Name;
                        public int Id;
                }
+
+               [Test]
+               public void DataRemainsOnClipboard_Xamarin4959 ()
+               {
+                       // Compile an app that puts something on the clipboard
+                       var source = @"
+using System;
+using System.Windows.Forms;
+public static class MainClass
+{
+       public static void Main ()
+       {
+               Clipboard.SetDataObject (""testing bug 4959"", true, 10, 100);
+       }
+}
+";
+                       var exeName = Path.GetTempFileName ();
+                       try {
+                               var parameters = new CompilerParameters ();
+                               parameters.GenerateExecutable = true;
+                               parameters.ReferencedAssemblies.Add ("System.Windows.Forms.dll");
+                               parameters.OutputAssembly = exeName;
+                               var compiler = CodeDomProvider.CreateProvider ("CSharp");
+                               var compilerResults = compiler.CompileAssemblyFromSource (parameters, source);
+                               Assert.AreEqual (0, compilerResults.Errors.Count);
+
+                               // Execute the app
+                               using (var app = Process.Start (exeName)) {
+                                       app.WaitForExit ();
+                               }
+
+                               // Text should still be on the clipboard
+                               Assert.AreEqual ("testing bug 4959", Clipboard.GetText ());
+                       } finally {
+                               File.Delete (exeName);
+                       }
+               }
+
+               [Test]
+               public void DataGetsCleared_Xamarin4959 ()
+               {
+                       // This is the reverse of the previous test
+
+                       // Compile an app that puts something on the clipboard
+                       var source = @"
+using System;
+using System.Windows.Forms;
+public static class MainClass
+{
+       public static void Main ()
+       {
+               Clipboard.SetDataObject (""testing bug 4959"", false, 10, 100);
+       }
+}
+";
+                       var exeName = Path.GetTempFileName ();
+                       try {
+                               var parameters = new CompilerParameters ();
+                               parameters.GenerateExecutable = true;
+                               parameters.ReferencedAssemblies.Add ("System.Windows.Forms.dll");
+                               parameters.OutputAssembly = exeName;
+                               var compiler = CodeDomProvider.CreateProvider ("CSharp");
+                               var compilerResults = compiler.CompileAssemblyFromSource (parameters, source);
+                               Assert.AreEqual (0, compilerResults.Errors.Count);
+
+                               // Execute the app
+                               using (var app = Process.Start (exeName)) {
+                                       app.WaitForExit ();
+                               }
+
+                               // Text should no longer be on the clipboard
+                               Assert.IsTrue (string.IsNullOrEmpty (Clipboard.GetText ()));
+                       } finally {
+                               File.Delete (exeName);
+                       }
+               }
 #endif
        }
 }
index 3b2a6b950b4f2addff882bc0f2f52930e5973c0a..c72999b8ac9c85b28f89d97a87d95e447b1669a8 100644 (file)
@@ -854,6 +854,59 @@ namespace MonoTests.System.Windows.Forms
                        }
                        Assert.AreEqual ((Array)expectedAddPositions, (Array)addedAtList.ToArray (typeof (int)), "addedAtList");
                }
+
+               [Test]
+               public void SelectedIndexUpdated () // Xamarin bug 4921
+               {
+                       using (Form f = new Form ()) {
+                               f.ShowInTaskbar = false;
+
+                               ListBox l = new ListBox ();
+                               l.Sorted = true;
+                               f.Controls.Add (l);
+
+                               l.Items.Add ("B");
+                               l.SelectedIndex = 0;
+
+                               Assert.AreEqual (0, l.SelectedIndex);
+
+                               l.Items.Add ("A");
+                               Assert.AreEqual (1, l.SelectedIndex);
+                       }
+               }
+
+               [Test]
+               public void SelectedIndexUpdated_MultiSelect () // Xamarin bug 4921
+               {
+                       using (Form f = new Form ()) {
+                               f.ShowInTaskbar = false;
+
+                               ListBox l = new ListBox ();
+                               l.Sorted = true;
+                               l.SelectionMode = SelectionMode.MultiSimple;
+                               f.Controls.Add (l);
+
+                               l.Items.Add ("B");
+                               l.Items.Add ("C");
+                               l.SelectedIndex = 0;
+                               l.SelectedIndex = 1;
+
+                               Assert.AreEqual (2, l.SelectedIndices.Count);
+                               Assert.AreEqual (0, l.SelectedIndices [0]);
+                               Assert.AreEqual (1, l.SelectedIndices [1]);
+                               Assert.AreEqual (2, l.SelectedItems.Count);
+                               Assert.AreEqual ("B", l.SelectedItems [0]);
+                               Assert.AreEqual ("C", l.SelectedItems [1]);
+
+                               l.Items.Add ("A");
+                               Assert.AreEqual (2, l.SelectedIndices.Count);
+                               Assert.AreEqual (1, l.SelectedIndices[0]);
+                               Assert.AreEqual (2, l.SelectedIndices[1]);
+                               Assert.AreEqual (2, l.SelectedItems.Count);
+                               Assert.AreEqual ("B", l.SelectedItems [0]);
+                               Assert.AreEqual ("C", l.SelectedItems [1]);
+                       }
+               }
        }
 
        [TestFixture]
index b5ec1ac67c4fe342df7620eaa9301dc22230a3dd..cc71dbdf242e8ad21dbfa8d164d54a14bc067c4d 100644 (file)
@@ -25,7 +25,8 @@ LIB_MCS_FLAGS = \
 
 TEST_MCS_FLAGS = \
        /r:$(BUILD_FRAMEWORK)   \
-       /r:Microsoft.Build.Utilities$(NAME_SUFFIX).dll
+       /r:Microsoft.Build.Utilities$(NAME_SUFFIX).dll \
+       /r:System.Xml.dll
 
 EXTRA_DISTFILES = \
        Test/resources/TestTasks.cs             \
index 332ee68fc4a7a9bdb13c2e542c8009f3f692a65d..79893411b886712def98d59f1a531aeb4cf5ae6e 100644 (file)
@@ -79,6 +79,22 @@ namespace Microsoft.Build.BuildEngine {
                        }
                }
 
+               internal bool CheckEvaluatedProjectPathExists ()
+               {
+                       string path = EvaluatedProjectPath;
+
+                       if (File.Exists (path))
+                               return true;
+
+                       if (Path.GetFileName (path) == "Microsoft.CSharp.Targets") {
+                               path = Path.ChangeExtension (path, ".targets");
+                               if (File.Exists (path))
+                                       return true;
+                       }
+
+                       return false;
+               }
+
                // FIXME: condition
                internal void Evaluate (bool ignoreMissingImports)
                {
@@ -146,6 +162,8 @@ namespace Microsoft.Build.BuildEngine {
                                base_dir_info = new DirectoryInfo (Directory.GetCurrentDirectory ());
 
                        IEnumerable<string> extn_paths = has_extn_ref ? GetExtensionPaths (project) : new string [] {null};
+                       bool import_needed = false;
+                       
                        try {
                                foreach (string path in extn_paths) {
                                        string extn_msg = null;
@@ -159,6 +177,8 @@ namespace Microsoft.Build.BuildEngine {
                                        if (!ConditionParser.ParseAndEvaluate (condition_attribute, project))
                                                continue;
 
+                                       import_needed = true;
+
                                        // We stop if atleast one file got imported.
                                        // Remaining extension paths are *not* tried
                                        bool atleast_one = false;
@@ -180,6 +200,9 @@ namespace Microsoft.Build.BuildEngine {
                                if (has_extn_ref)
                                        project.SetExtensionsPathProperties (Project.DefaultExtensionsPath);
                        }
+
+                       if (import_needed)
+                               throw new InvalidProjectFileException (String.Format ("{0} could not import \"{1}\"", importingFile, project_attribute));
                }
 
                // Parses the Project attribute from an Import,
index 3a8d2feda0b8d7afd7dffdf8c31c9ce07091f4c1..04a5034a6b9d195d45073441ca8d6066effc0802 100644 (file)
@@ -1156,6 +1156,9 @@ namespace Microsoft.Build.BuildEngine {
                                return false;
                        }
 
+                       if (!import.CheckEvaluatedProjectPathExists ())
+                               return false;
+
                        Imports.Add (import);
                        string importingFile = importingProject != null ? importingProject.FullFileName : FullFileName;
                        ParentEngine.LogMessage (MessageImportance.Low,
index 97efd3c3b61b356fd65b20ff211ea8c680394fb3..b1d417115e16c8b9cafab3f6701417bd459a5152 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 789100dbaac78e9d4cb72e61697128d7fcfa3708..6a94b540ceb033d5f307df117731a8dfcddb064c 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c716b292c34290e93871196054065740aa393e03..1ca758cb72a9bd192ac74980d7931c4484464a65 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1a7512f177b98d78584ed2f831f80753b0429c71..b3b71ac3923049653df7540c4d977c58620a20c0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 15c0ff412a4865685aba86e96e39ee9563666753..99d48fb30923fc21f5ed2c22e2883ff112b1c08f 100644 (file)
@@ -81,7 +81,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Utilities.dll</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 8c5235366a54da902ecae9134427835fe89411ae..debc4d4455be866f2958b668ab78aedb9a1501c7 100644 (file)
@@ -81,7 +81,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Utilities.v3.5.dll</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index f62c39cd57d6a0ac8e442a8b49f608bb32b3999c..2770fae4f6f681ce95c24a99332c3b84ce343800 100644 (file)
@@ -81,7 +81,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Utilities.v4.0.dll</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index ec0110e2ce91b61ede98165bd8d53e24e7f1f972..9a9b8f6ac8db96720809f65d7714e63ad1e5aaa7 100644 (file)
@@ -81,7 +81,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Utilities.v4.0.dll</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 685d5059d861281e652d0dca822faaaa96a899a8..53b46350bea8f748907c1d9fbc1ece5fbd33264f 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index fed5eabbca9cd590cc4fae1b9aa29fb296f8b0aa..a6cc343650c182e0cdbdc9ba90469f8a07e8f51f 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a99ba45036ed40aecbcb263b57d440d6579375ee..148619aa57f634719e37054ed5db7636658fa552 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1af40b8e98f9ab82880c5d9b055fb39d84ecec10..f1c54fdd3fd170069f23ae8c22f1872572456463 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index cb062e691bd0b2b9f3055684473fa0150c97f247..8a8f469666e1b60fbe1c87dc61888f59e4aca414 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index de19487cde63de84f6d9254789545e6e8a97a803..1c7e726cbd016bc4ab6309c51346ee92f529438f 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2dff961961af6a0eeef5ecc0dce0a58608a64175..ecc81fef6cca6e4f56212e09605e3d5947009222 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f5fdc0776a018be814b32915a97ea1ba3911d0c1..53441c93a5d532632508768486ddbb17ada5b772 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b5be1ee0785bbb23a2a93e61051465cba0d81c4b..07a42e36a9cd3171c56bcdbc3f8ba7cb2c68d775 100644 (file)
@@ -31,7 +31,8 @@ LIB_MCS_FLAGS = \
 TEST_MCS_FLAGS = \
        /r:$(BUILD_ENGINE)      \
        /r:$(BUILD_FRAMEWORK)   \
-       /r:Microsoft.Build.Utilities$(NAME_SUFFIX).dll
+       /r:Microsoft.Build.Utilities$(NAME_SUFFIX).dll \
+       /r:System.Core.dll
 
 EXTRA_DISTFILES = \
        Test/resources/test.cs \
index e6f96ea950e8f21144d6e748d0fa2df19b2b491c..2edf651cc0cd9410a9034f5207d189693d3a3bc0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 84e55f66acc3f48225f5a5594107a07838d023c6..f074ebbca88d12c8d40a596991462577c5a2983c 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0e7de9824263a9212c36e12b4d43cfe8c4d3719e..22248597bfcebd2b1378585c751df96af3ff2445 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8b25f4c93e3a0f13393476055ed108b631f3fcbd..7557e7d7a82f65f30464fb738969a71fce2b71a3 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d6b22f78e6c8085b60d4d837991e07e0d1d9b30a..d71294bcdab37fea24c5ca84c93810ca4bb3dc76 100644 (file)
@@ -80,7 +80,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Utilities.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 974e2539aca179ba970129d5970e17a4e94dd825..fc0185fbfe1c0c0f3df9162d3d3635e01f673669 100644 (file)
@@ -80,7 +80,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Utilities.v3.5.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 3bf27b2c83241bcb146a99695df45a382e609f31..b7a240bb6c712fd7030d67fbde5a2a87aa7e1f20 100644 (file)
@@ -80,7 +80,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Utilities.v4.0.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 229c0648b397cea287925bfdfa82dd7825d9228c..93ed5ba3a3825a3fa86bd5cdc8beda07930df966 100644 (file)
@@ -80,7 +80,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Utilities.v4.0.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index a357955858f09dff14923b1ff257e112047cdf18..32f34e3f401d90b638cb82e3ee384890da74329f 100644 (file)
@@ -19,7 +19,7 @@ LIB_MCS_FLAGS = \
        /r:System.dll                           \
        /r:$(BUILD_FRAMEWORK)
 
-TEST_MCS_FLAGS = /r:$(BUILD_FRAMEWORK)
+TEST_MCS_FLAGS = /r:$(BUILD_FRAMEWORK) -r:System.dll
 
 export TESTING_MONO=a
 XBUILD_DIR=../../tools/xbuild
index 9a7afc69632b1488f4e57793d991b36ff0519f8f..18408f709739e62298688fa0cb2f1311ef1d6f95 100644 (file)
@@ -72,7 +72,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b586c54d844db83d8d4b2ef5490f8b51bcc5cdb8..2d16d4868f5c204179ed8e13f271a37037d921b4 100644 (file)
@@ -72,7 +72,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3be84180f356140bfae08d06ae94d15292e76cc7..19bafe074c4b09890ca355da0a84b3bbfd3c75c4 100644 (file)
@@ -72,7 +72,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4f35dc6ac64b410baec75760e17caf516bc66542..f5a6246551246a13fe71a038b099d68bc995085a 100644 (file)
@@ -72,7 +72,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f091fc7d42fc4b26ed212ac584ace4289aa72619..e26706b50bbffd567cbcdb5fda4c7dddcf3bc143 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Framework.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index c0abe3bb9eaeed396427b91b0e6b4db4773255e7..8190e71b8b43b4bbb1640beaf090899edf01e258 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_3_5/Microsoft.Build.Framework.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index af07fc1566bf2099dac2a179696184c42034f03c..2916535d0f57b50cb3616cd4234643dee637cf17 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Framework.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index e55f29e82b3536bea07a5606ae7575076efaa058..a73bfea1d302b5c6c90117ff7335cff3cde617fb 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Microsoft.Build.Framework.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 74e14491def3917c45d77a273e218a6e999f9a02..17c16f6c6c03074e7463e3ede4f1898a5e4c6d4b 100644 (file)
@@ -18,6 +18,13 @@ LIB_MCS_FLAGS = \
        /r:System.Xml.dll                       \
        /r:Microsoft.Build.Engine.dll           \
        /r:Microsoft.Build.Framework.dll
+       
+TEST_MCS_FLAGS = /r:System.Core.dll
+
+EXTRA_DISTFILES = \
+       Test/FunctionalTestReferenceProject.csproj      \
+       Test/FunctionalTestReferenceProject3.csproj     \
+       Test/Microsoft.Build.Test.csproj
 
 include ../../build/library.make
 
index 1f2c7dbb3c43731f1c8b475e3caa3faa7ef5751c..19b70b76d695dfda45dd307f33d7f2e0e3c4632d 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3487157bf75c4f23b10feb6e80d2315d5a4a2d89..a0a069d5c9079e1422547202dcde961cbc91c1b2 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c25bc0526c926867ee2f8f96d39e039a187c4c83..fde980554b2a1c3f1e1b13841de722d3bc7c8b96 100644 (file)
@@ -53,7 +53,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 68c408c915eff76063011a7a46ad30c5a0de8805..113b8b39bce08a5b23ce9152cb2bb7ed8a0e3995 100644 (file)
@@ -53,7 +53,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index bdb2d94dd15819554048db0f3efe43361cca1da1..d90e44ed486b794459825543827d1dcb99186c46 100644 (file)
@@ -77,7 +77,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2ec821fa4a12956b560eefee3ea85b9f1444d1ec..270a8aa4d3cefddaf91b76c4129c114c12a4a49e 100644 (file)
@@ -77,7 +77,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d77c9ff6d22196eb29397421583065824e115913..9c466c5ed9c9875b31f69f0f0ec9654075f3ac37 100644 (file)
@@ -78,12 +78,6 @@ namespace Microsoft.CSharp.RuntimeBinder
                                        IsRuntimeBinder = true
                                };
 
-                               //IList<Compiler.PredefinedTypeSpec> core_types = null;
-                               //// HACK: To avoid re-initializing static TypeManager types, like string_type
-                               //if (!Compiler.RootContext.EvalMode) {
-                               //    core_types = Compiler.TypeManager.InitCoreTypes ();
-                               //}
-
                                //
                                // Any later loaded assemblies are handled internally by GetAssemblyDefinition
                                // domain.AssemblyLoad cannot be used as that would be too destructive as we
@@ -93,17 +87,19 @@ namespace Microsoft.CSharp.RuntimeBinder
                                //
                                var module = new Compiler.ModuleContainer (cc);
                                module.HasTypesFullyDefined = true;
+                               
+                               // Setup fake assembly, it's used mostly to simplify checks like friend-access
                                var temp = new Compiler.AssemblyDefinitionDynamic (module, "dynamic");
                                module.SetDeclaringAssembly (temp);
 
-                               // Import all currently loaded assemblies
-                               var domain = AppDomain.CurrentDomain;
-
-                               temp.Create (domain, System.Reflection.Emit.AssemblyBuilderAccess.Run);
                                var importer = new Compiler.ReflectionImporter (module, cc.BuiltinTypes) {
                                        IgnorePrivateMembers = false
                                };
 
+                               // Import all currently loaded assemblies
+                               // TODO: Rewrite this to populate type cache on-demand, that should greatly
+                               // reduce our start-up cost
+                               var domain = AppDomain.CurrentDomain;
                                foreach (var a in AppDomain.CurrentDomain.GetAssemblies ()) {
                                        importer.ImportAssembly (a, module.GlobalRootNamespace);
                                }
index 30e8658f66c027d7a4b30440e93f0a86fcdd5e40..1b8655df561546fa2effddb6b803b3d40d4c9c69 100644 (file)
@@ -64,7 +64,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 541307eaffa422832649aca62655474269855247..f6c36c048a3fe71ade01c66e45ec1bebd5166d5a 100644 (file)
@@ -64,7 +64,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 211fadca527fa252c0f8864acceb275d5bf8e009..620a81703940d6591fe29591442b0c62c419bcb1 100644 (file)
@@ -64,7 +64,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8e806e05c365817cb2bd81f2c5ea20e1ad4d412d..9234267f2f043df62135fe30044a6b88efb4655d 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 10189f29af1456e30d2de4881207b2460f26b16f..400351771560b414c07cfe2af41ed7e9e3271017 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 797f82eadc9a122fbbd469be25fe67067022fa58..8de5856e6144319944e63f3ee4a253ebd66f2035 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006</NoWarn>\r
     <OutputPath>./../../class/lib/net_2_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -84,7 +84,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index aa920e6ff8b895a938111c9f067a1b2f46b21134..a65371bc894a5d3e58433580a4cffab76e072f81 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -84,7 +84,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index daf82e1567dfa32a90c2a51533d8ba51df835e1b..7980e0f68556e4c143898f914d975228bf930145 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -84,7 +84,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4b93df4f9448e60fe729016544a287a3d43b35b8..d035f72cf5fd59cde9eb79392a73bbbeb2c86be7 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,169,618,219,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006,618,219,169</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,169,618,219,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006,618,219,169</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,169,618,219,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006,618,219,169</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -75,7 +75,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ceaa566af8cde40d8f66d279caa395aa657638f0..7651216bfc6a2e0e3e7629ab2d7e051fde956b8f 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,169,618,219,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006,618,219,169</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,169,618,219,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006,618,219,169</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,169,618,219,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006,618,219,169</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -75,7 +75,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 253712f3749126e32b3959ee95e228fed9ee5c51..a1bd0354e1a0ee74a540edb6890865eff1b5f594 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,169,618,219,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006,618,219,169</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,169,618,219,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006,618,219,169</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,169,618,219,169</NoWarn>\r
+    <NoWarn>1699,169,219,414,1030,3001,3005,3006,618,219,169</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -75,7 +75,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5075de608533807eb89e76aa8b74f6a935408284..2e67f5993926e04edda39a0b1f555dc5eed9439d 100644 (file)
@@ -4,7 +4,9 @@ include ../../build/rules.make
 
 LIBRARY = Mono.CSharp.dll
 
-LIB_MCS_FLAGS = -r:System.Core.dll -r:System.Xml -r:System
+LIB_MCS_FLAGS = -r:System.Core.dll -r:System.Xml.dll -r:System.dll
+
+TEST_MCS_FLAGS = -r:System.Core.dll
 
 include ../../build/library.make
 
index 120af1590108b818561fc617eff4735b65a764d7..5e5e1d17145113c84274c1ee282577c22679efce 100644 (file)
@@ -90,7 +90,7 @@
    <Compile Include="..\..\mcs\visit.cs" />
    <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolFile.cs" />
    <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolTable.cs" />
-   <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolWriter.cs" />
+   <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\SourceMethodBuilder.cs" />
    <Compile Include="..\..\class\corlib\Mono.Security.Cryptography\CryptoConvert.cs" />
    <Compile Include="..\..\build\common\Consts.cs" />
    <Compile Include="..\..\tools\monop\outline.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Core.dll</HintPath>
     </Reference>
-    <Reference Include="System.Xml">
+    <Reference Include="System.Xml.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Xml</HintPath>
+      <HintPath>System.Xml.dll</HintPath>
     </Reference>
-    <Reference Include="System">
+    <Reference Include="System.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System</HintPath>
+      <HintPath>System.dll</HintPath>
     </Reference>
 \r
   </ItemGroup>\r
index 03d8a279ac43a3e0645604feb8cea569a24e8482..eab5eada81eafed48cf8e9b04a9035fb4835b573 100644 (file)
@@ -90,7 +90,7 @@
    <Compile Include="..\..\mcs\visit.cs" />
    <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolFile.cs" />
    <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolTable.cs" />
-   <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolWriter.cs" />
+   <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\SourceMethodBuilder.cs" />
    <Compile Include="..\..\class\corlib\Mono.Security.Cryptography\CryptoConvert.cs" />
    <Compile Include="..\..\build\common\Consts.cs" />
    <Compile Include="..\..\tools\monop\outline.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Core.dll</HintPath>
     </Reference>
-    <Reference Include="System.Xml">
+    <Reference Include="System.Xml.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Xml</HintPath>
+      <HintPath>System.Xml.dll</HintPath>
     </Reference>
-    <Reference Include="System">
+    <Reference Include="System.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System</HintPath>
+      <HintPath>System.dll</HintPath>
     </Reference>
 \r
   </ItemGroup>\r
index eb650f9d6dee6505bb7544534212d38530002dd0..b83b056bb0d7ba03fd7f83462074701d215a37a0 100644 (file)
@@ -90,7 +90,7 @@
    <Compile Include="..\..\mcs\visit.cs" />
    <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolFile.cs" />
    <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolTable.cs" />
-   <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolWriter.cs" />
+   <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\SourceMethodBuilder.cs" />
    <Compile Include="..\..\class\corlib\Mono.Security.Cryptography\CryptoConvert.cs" />
    <Compile Include="..\..\build\common\Consts.cs" />
    <Compile Include="..\..\tools\monop\outline.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Core.dll</HintPath>
     </Reference>
-    <Reference Include="System.Xml">
+    <Reference Include="System.Xml.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Xml</HintPath>
+      <HintPath>System.Xml.dll</HintPath>
     </Reference>
-    <Reference Include="System">
+    <Reference Include="System.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System</HintPath>
+      <HintPath>System.dll</HintPath>
     </Reference>
 \r
   </ItemGroup>\r
index bdb007ce2b82cc13717e5af0d5111e265c8ad093..9b7cfd5de7e38ea4805d1fee50da929f16d96305 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_2_0/Mono.CSharp.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 4cc73cccfbf1c275077e2432e6665d816562b98b..06d43417e70f225f791eabee51e085870f8de65c 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_0/Mono.CSharp.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index d7ee4c6f0b35f859760df3bc6578d81d15b79e55..59733e46b950f5a3511ba180be59987b040cb6c1 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_5/Mono.CSharp.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 4275fe1a25813e7bb68bc9a9380fa5ca1c854baf..86347c3c75b7dbb636b5d2b25c3580424be0c326 100755 (executable)
@@ -72,6 +72,9 @@
     <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\MonoSymbolWriter.cs">\r
       <Link>MonoSymbolWriter.cs</Link>\r
     </Compile>\r
+    <Compile Include="..\..\class\Mono.CompilerServices.SymbolWriter\SourceMethodBuilder.cs">\r
+      <Link>SourceMethodBuilder.cs</Link>\r
+    </Compile>\r
     <Compile Include="..\..\mcs\anonymous.cs">\r
       <Link>anonymous.cs</Link>\r
     </Compile>\r
index e98067dc0a5708822594d298f898b78bcc1afcc6..3dd07b9c515af740eecdfc51cb9e46f7a4fbdaf0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1f9548f8f1fa34f2d7b1c4a11449c99c1e5a4382..29074ee6821d45ff54b050eac508db68088cf122 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3245f5e1ff1656a5396a85c25b18b4fc567b8c90..39c23cf6b4c67d8b83c1b5cab3d21f88703b521a 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ecb9bb41d834bde05644a3375205f0997ba535e4..58d527dfed4e1151e0965d9b797b57d33266d3ce 100644 (file)
@@ -5,9 +5,7 @@ LIBRARY = Mono.Cecil.Mdb.dll
 LIBRARY_SNK = ../mono.snk
 LIBRARY_PACKAGE = none
 
-CECIL = $(topdir)/class/lib/$(PROFILE)/Mono.Cecil.dll
-
-LIB_MCS_FLAGS = /r:$(corlib) /r:System.dll /r:$(CECIL) /d:CECIL -keyfile:$(LIBRARY_SNK)
+LIB_MCS_FLAGS = /r:$(corlib) /r:System.dll /r:Mono.Cecil.dll /d:CECIL -keyfile:$(LIBRARY_SNK)
 
 NO_TEST = yes
 
index 0843680d43d30e934425250582df2bb1b07b4998..5ea62e79adc764a2366bf196056b3e3209495ebe 100644 (file)
@@ -44,6 +44,7 @@
    <Compile Include="..\Mono.CompilerServices.SymbolWriter\MonoSymbolFile.cs" />
    <Compile Include="..\Mono.CompilerServices.SymbolWriter\MonoSymbolTable.cs" />
    <Compile Include="..\Mono.CompilerServices.SymbolWriter\MonoSymbolWriter.cs" />
+   <Compile Include="..\Mono.CompilerServices.SymbolWriter\SourceMethodBuilder.cs" />
 \r
   </ItemGroup>\r
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
@@ -57,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a0e68391a2611b453b26c9ea0ce14f22e15e4bd2..a124c20394a83b7c77d36269facd043900dc7688 100644 (file)
@@ -44,6 +44,7 @@
    <Compile Include="..\Mono.CompilerServices.SymbolWriter\MonoSymbolFile.cs" />
    <Compile Include="..\Mono.CompilerServices.SymbolWriter\MonoSymbolTable.cs" />
    <Compile Include="..\Mono.CompilerServices.SymbolWriter\MonoSymbolWriter.cs" />
+   <Compile Include="..\Mono.CompilerServices.SymbolWriter\SourceMethodBuilder.cs" />
 \r
   </ItemGroup>\r
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
@@ -57,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b4932e28c764eade29c9084dab4fe1d2e25b186d..6438eb796a2690df6fc51e9932ae53068273c65d 100644 (file)
@@ -44,6 +44,7 @@
    <Compile Include="..\Mono.CompilerServices.SymbolWriter\MonoSymbolFile.cs" />
    <Compile Include="..\Mono.CompilerServices.SymbolWriter\MonoSymbolTable.cs" />
    <Compile Include="..\Mono.CompilerServices.SymbolWriter\MonoSymbolWriter.cs" />
+   <Compile Include="..\Mono.CompilerServices.SymbolWriter\SourceMethodBuilder.cs" />
 \r
   </ItemGroup>\r
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
@@ -57,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0cd3f087cca4e88ead797d984c72fa198d4615ce..eedadff94e7ef99003dc1ed7553ae1b75a0fd1aa 100644 (file)
@@ -1,7 +1,7 @@
-./Mono.Cecil.Mdb/AssemblyInfo.cs
-./Mono.Cecil.Mdb/MdbReader.cs
-./Mono.Cecil.Mdb/MdbWriter.cs
-../Mono.CompilerServices.SymbolWriter/MonoSymbolFile.cs
-../Mono.CompilerServices.SymbolWriter/MonoSymbolTable.cs
-../Mono.CompilerServices.SymbolWriter/MonoSymbolWriter.cs
-../Mono.CompilerServices.SymbolWriter/SourceMethodBuilder.cs
+../../../external/cecil/symbols/mdb/Mono.Cecil.Mdb/AssemblyInfo.cs
+../../../external/cecil/symbols/mdb/Mono.Cecil.Mdb/MdbReader.cs
+../../../external/cecil/symbols/mdb/Mono.Cecil.Mdb/MdbWriter.cs
+../../../external/cecil/symbols/mdb/Mono.CompilerServices.SymbolWriter/MonoSymbolFile.cs
+../../../external/cecil/symbols/mdb/Mono.CompilerServices.SymbolWriter/MonoSymbolTable.cs
+../../../external/cecil/symbols/mdb/Mono.CompilerServices.SymbolWriter/MonoSymbolWriter.cs
+../../../external/cecil/symbols/mdb/Mono.CompilerServices.SymbolWriter/SymbolWriterImpl.cs
diff --git a/mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb/AssemblyInfo.cs b/mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb/AssemblyInfo.cs
deleted file mode 100644 (file)
index 8186b50..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-//
-// AssemblyInfo.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Reflection;
-using System.Runtime.InteropServices;
-
-[assembly: AssemblyTitle ("Mono.Cecil.Mdb")]
-[assembly: AssemblyProduct ("Mono.Cecil")]
-[assembly: AssemblyCopyright ("Copyright © 2008 - 2011 Jb Evain")]
-
-[assembly: CLSCompliant (false)]
-[assembly: ComVisible (false)]
-
-[assembly: AssemblyVersion ("0.9.5.0")]
-[assembly: AssemblyFileVersion ("0.9.5.0")]
diff --git a/mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb/MdbReader.cs b/mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb/MdbReader.cs
deleted file mode 100644 (file)
index 7f5d640..0000000
+++ /dev/null
@@ -1,213 +0,0 @@
-//
-// MdbReader.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-using System.IO;
-
-using Mono.Cecil.Cil;
-using Mono.Collections.Generic;
-using Mono.CompilerServices.SymbolWriter;
-
-namespace Mono.Cecil.Mdb {
-
-       public class MdbReaderProvider : ISymbolReaderProvider {
-
-               public ISymbolReader GetSymbolReader (ModuleDefinition module, string fileName)
-               {
-                       return new MdbReader (MonoSymbolFile.ReadSymbolFile (fileName + ".mdb", module.Mvid));
-               }
-
-               public ISymbolReader GetSymbolReader (ModuleDefinition module, Stream symbolStream)
-               {
-                       throw new NotImplementedException ();
-               }
-       }
-
-       public class MdbReader : ISymbolReader {
-
-               readonly MonoSymbolFile symbol_file;
-               readonly Dictionary<string, Document> documents;
-
-               public MdbReader (MonoSymbolFile symFile)
-               {
-                       symbol_file = symFile;
-                       documents = new Dictionary<string, Document> ();
-               }
-
-               public bool ProcessDebugHeader (ImageDebugDirectory directory, byte [] header)
-               {
-                       return true;
-               }
-
-               public void Read (MethodBody body, InstructionMapper mapper)
-               {
-                       var method_token = body.Method.MetadataToken;
-                       var entry = symbol_file.GetMethodByToken (method_token.ToInt32  ());
-                       if (entry == null)
-                               return;
-
-                       var scopes = ReadScopes (entry, body, mapper);
-                       ReadLineNumbers (entry, mapper);
-                       ReadLocalVariables (entry, body, scopes);
-               }
-
-               static void ReadLocalVariables (MethodEntry entry, MethodBody body, Scope [] scopes)
-               {
-                       var locals = entry.GetLocals ();
-                       foreach (var local in locals) {
-                               var variable = body.Variables [local.Index];
-                               variable.Name = local.Name;
-
-                               var index = local.BlockIndex;
-                               if (index < 0 || index >= scopes.Length)
-                                       continue;
-
-                               var scope = scopes [index];
-                               if (scope == null)
-                                       continue;
-
-                               scope.Variables.Add (variable);
-                       }
-               }
-
-               void ReadLineNumbers (MethodEntry entry, InstructionMapper mapper)
-               {
-                       Document document = null;
-                       var table = entry.GetLineNumberTable ();
-
-                       foreach (var line in table.LineNumbers) {
-                               var instruction = mapper (line.Offset);
-                               if (instruction == null)
-                                       continue;
-
-                               if (document == null)
-                                       document = GetDocument (entry.CompileUnit.SourceFile);
-
-                               instruction.SequencePoint = new SequencePoint (document) {
-                                       StartLine = line.Row,
-                                       EndLine = line.Row,
-                               };
-                       }
-               }
-
-               Document GetDocument (SourceFileEntry file)
-               {
-                       var file_name = file.FileName;
-
-                       Document document;
-                       if (documents.TryGetValue (file_name, out document))
-                               return document;
-
-                       document = new Document (file_name);
-                       documents.Add (file_name, document);
-
-                       return document;
-               }
-
-               static Scope [] ReadScopes (MethodEntry entry, MethodBody body, InstructionMapper mapper)
-               {
-                       var blocks = entry.GetCodeBlocks ();
-                       var scopes = new Scope [blocks.Length];
-
-                       foreach (var block in blocks) {
-                               if (block.BlockType != CodeBlockEntry.Type.Lexical)
-                                       continue;
-
-                               var scope = new Scope ();
-                               scope.Start = mapper (block.StartOffset);
-                               scope.End = mapper (block.EndOffset);
-
-                               scopes [block.Index] = scope;
-
-                               if (body.Scope == null)
-                                       body.Scope = scope;
-
-                               if (!AddScope (body.Scope, scope))
-                                       body.Scope = scope;
-                       }
-
-                       return scopes;
-               }
-
-               static bool AddScope (Scope provider, Scope scope)
-               {
-                       foreach (var sub_scope in provider.Scopes) {
-                               if (AddScope (sub_scope, scope))
-                                       return true;
-
-                               if (scope.Start.Offset >= sub_scope.Start.Offset && scope.End.Offset <= sub_scope.End.Offset) {
-                                       sub_scope.Scopes.Add (scope);
-                                       return true;
-                               }
-                       }
-
-                       return false;
-               }
-
-               public void Read (MethodSymbols symbols)
-               {
-                       var entry = symbol_file.GetMethodByToken (symbols.MethodToken.ToInt32 ());
-                       if (entry == null)
-                               return;
-
-                       ReadLineNumbers (entry, symbols);
-                       ReadLocalVariables (entry, symbols);
-               }
-
-               void ReadLineNumbers (MethodEntry entry, MethodSymbols symbols)
-               {
-                       var table = entry.GetLineNumberTable ();
-                       var lines = table.LineNumbers;
-
-                       var instructions = symbols.instructions = new Collection<InstructionSymbol> (lines.Length);
-
-                       for (int i = 0; i < lines.Length; i++) {
-                               var line = lines [i];
-
-                               instructions.Add (new InstructionSymbol (line.Offset, new SequencePoint (GetDocument (entry.CompileUnit.SourceFile)) {
-                                       StartLine = line.Row,
-                                       EndLine = line.Row,
-                               }));
-                       }
-               }
-
-               static void ReadLocalVariables (MethodEntry entry, MethodSymbols symbols)
-               {
-                       foreach (var local in entry.GetLocals ()) {
-                               var variable = symbols.Variables [local.Index];
-                               variable.Name = local.Name;
-                       }
-               }
-
-               public void Dispose ()
-               {
-                       symbol_file.Dispose ();
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb/MdbWriter.cs b/mcs/class/Mono.Cecil.Mdb/Mono.Cecil.Mdb/MdbWriter.cs
deleted file mode 100644 (file)
index 6f4aa20..0000000
+++ /dev/null
@@ -1,251 +0,0 @@
-//
-// MdbWriter.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-using System.IO;
-
-using Mono.Cecil.Cil;
-using Mono.Collections.Generic;
-using Mono.CompilerServices.SymbolWriter;
-
-namespace Mono.Cecil.Mdb {
-
-#if !READ_ONLY
-       public class MdbWriterProvider : ISymbolWriterProvider {
-
-               public ISymbolWriter GetSymbolWriter (ModuleDefinition module, string fileName)
-               {
-                       return new MdbWriter (module.Mvid, fileName);
-               }
-
-               public ISymbolWriter GetSymbolWriter (ModuleDefinition module, Stream symbolStream)
-               {
-                       throw new NotImplementedException ();
-               }
-       }
-
-       public class MdbWriter : ISymbolWriter {
-
-               readonly Guid mvid;
-               readonly MonoSymbolWriter writer;
-               readonly Dictionary<string, SourceFile> source_files;
-
-               public MdbWriter (Guid mvid, string assembly)
-               {
-                       this.mvid = mvid;
-                       this.writer = new MonoSymbolWriter (assembly);
-                       this.source_files = new Dictionary<string, SourceFile> ();
-               }
-
-               static Collection<Instruction> GetInstructions (MethodBody body)
-               {
-                       var instructions = new Collection<Instruction> ();
-                       foreach (var instruction in body.Instructions)
-                               if (instruction.SequencePoint != null)
-                                       instructions.Add (instruction);
-
-                       return instructions;
-               }
-
-               SourceFile GetSourceFile (Document document)
-               {
-                       var url = document.Url;
-
-                       SourceFile source_file;
-                       if (source_files.TryGetValue (url, out source_file))
-                               return source_file;
-
-                       var entry = writer.DefineDocument (url);
-                       var compile_unit = writer.DefineCompilationUnit (entry);
-
-                       source_file = new SourceFile (compile_unit, entry);
-                       source_files.Add (url, source_file);
-                       return source_file;
-               }
-
-               void Populate (Collection<Instruction> instructions, int [] offsets,
-                       int [] startRows, int [] startCols, out SourceFile file)
-               {
-                       SourceFile source_file = null;
-
-                       for (int i = 0; i < instructions.Count; i++) {
-                               var instruction = instructions [i];
-                               offsets [i] = instruction.Offset;
-
-                               var sequence_point = instruction.SequencePoint;
-                               if (source_file == null)
-                                       source_file = GetSourceFile (sequence_point.Document);
-
-                               startRows [i] = sequence_point.StartLine;
-                               startCols [i] = sequence_point.StartColumn;
-                       }
-
-                       file = source_file;
-               }
-
-               public void Write (MethodBody body)
-               {
-                       var method = new SourceMethod (body.Method);
-
-                       var instructions = GetInstructions (body);
-                       int count = instructions.Count;
-                       if (count == 0)
-                               return;
-
-                       var offsets = new int [count];
-                       var start_rows = new int [count];
-                       var start_cols = new int [count];
-
-                       SourceFile file;
-                       Populate (instructions, offsets, start_rows, start_cols, out file);
-
-                       var builder = writer.OpenMethod (file.CompilationUnit, 0, method);
-
-                       for (int i = 0; i < count; i++)
-                               builder.MarkSequencePoint (
-                                       offsets [i],
-                                       file.CompilationUnit.SourceFile,
-                                       start_rows [i],
-                                       start_cols [i],
-                                       false);
-
-                       if (body.HasVariables)
-                               AddVariables (body.Variables);
-
-                       writer.CloseMethod ();
-               }
-
-               readonly static byte [] empty_header = new byte [0];
-
-               public bool GetDebugHeader (out ImageDebugDirectory directory, out byte [] header)
-               {
-                       directory = new ImageDebugDirectory ();
-                       header = empty_header;
-                       return false;
-               }
-
-               void AddVariables (IList<VariableDefinition> variables)
-               {
-                       for (int i = 0; i < variables.Count; i++) {
-                               var variable = variables [i];
-                               writer.DefineLocalVariable (i, variable.Name);
-                       }
-               }
-
-               public void Write (MethodSymbols symbols)
-               {
-                       var method = new SourceMethodSymbol (symbols);
-
-                       var file = GetSourceFile (symbols.Instructions [0].SequencePoint.Document);
-                       var builder = writer.OpenMethod (file.CompilationUnit, 0, method);
-                       var count = symbols.Instructions.Count;
-
-                       for (int i = 0; i < count; i++) {
-                               var instruction = symbols.Instructions [i];
-                               var sequence_point = instruction.SequencePoint;
-
-                               builder.MarkSequencePoint (
-                                       instruction.Offset,
-                                       GetSourceFile (sequence_point.Document).CompilationUnit.SourceFile,
-                                       sequence_point.StartLine,
-                                       sequence_point.EndLine,
-                                       false);
-                       }
-
-                       if (symbols.HasVariables)
-                               AddVariables (symbols.Variables);
-
-                       writer.CloseMethod ();
-               }
-
-               public void Dispose ()
-               {
-                       writer.WriteSymbolFile (mvid);
-               }
-
-               class SourceFile : ISourceFile {
-
-                       readonly CompileUnitEntry compilation_unit;
-                       readonly SourceFileEntry entry;
-
-                       public SourceFileEntry Entry {
-                               get { return entry; }
-                       }
-
-                       public CompileUnitEntry CompilationUnit {
-                               get { return compilation_unit; }
-                       }
-
-                       public SourceFile (CompileUnitEntry comp_unit, SourceFileEntry entry)
-                       {
-                               this.compilation_unit = comp_unit;
-                               this.entry = entry;
-                       }
-               }
-
-               class SourceMethodSymbol : IMethodDef {
-
-                       readonly string name;
-                       readonly int token;
-
-                       public string Name {
-                               get { return name;}
-                       }
-
-                       public int Token {
-                               get { return token; }
-                       }
-
-                       public SourceMethodSymbol (MethodSymbols symbols)
-                       {
-                               name = symbols.MethodName;
-                               token = symbols.MethodToken.ToInt32 ();
-                       }
-               }
-
-               class SourceMethod : IMethodDef {
-
-                       readonly MethodDefinition method;
-
-                       public string Name {
-                               get { return method.Name; }
-                       }
-
-                       public int Token {
-                               get { return method.MetadataToken.ToInt32 (); }
-                       }
-
-                       public SourceMethod (MethodDefinition method)
-                       {
-                               this.method = method;
-                       }
-               }
-       }
-#endif
-}
diff --git a/mcs/class/Mono.Cecil/.gitignore b/mcs/class/Mono.Cecil/.gitignore
deleted file mode 100644 (file)
index 3629e37..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-bin
-obj
-*.suo
-*.user
-*.pidb
-*.userprefs
-*.xml
index cc6bab4f2f61becca05a37e74fda0c9d5a6568d5..970aa930eb263f9af5584622ffdb7209e50a8e95 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5b92337da1207e13e6aacbb97fa67c4e2f89a11c..4a2199ff5952ac89e05171b3fdd182c8c9196e41 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0f8e73482895c3dba936dff54ac291df7cbc1d2e..d14b9363152fe7bd607d73f27eacc01ff69d6792 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/Code.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/Code.cs
deleted file mode 100644 (file)
index fa88b63..0000000
+++ /dev/null
@@ -1,252 +0,0 @@
-//
-// Code.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil.Cil {
-
-       public enum Code {
-               Nop,
-               Break,
-               Ldarg_0,
-               Ldarg_1,
-               Ldarg_2,
-               Ldarg_3,
-               Ldloc_0,
-               Ldloc_1,
-               Ldloc_2,
-               Ldloc_3,
-               Stloc_0,
-               Stloc_1,
-               Stloc_2,
-               Stloc_3,
-               Ldarg_S,
-               Ldarga_S,
-               Starg_S,
-               Ldloc_S,
-               Ldloca_S,
-               Stloc_S,
-               Ldnull,
-               Ldc_I4_M1,
-               Ldc_I4_0,
-               Ldc_I4_1,
-               Ldc_I4_2,
-               Ldc_I4_3,
-               Ldc_I4_4,
-               Ldc_I4_5,
-               Ldc_I4_6,
-               Ldc_I4_7,
-               Ldc_I4_8,
-               Ldc_I4_S,
-               Ldc_I4,
-               Ldc_I8,
-               Ldc_R4,
-               Ldc_R8,
-               Dup,
-               Pop,
-               Jmp,
-               Call,
-               Calli,
-               Ret,
-               Br_S,
-               Brfalse_S,
-               Brtrue_S,
-               Beq_S,
-               Bge_S,
-               Bgt_S,
-               Ble_S,
-               Blt_S,
-               Bne_Un_S,
-               Bge_Un_S,
-               Bgt_Un_S,
-               Ble_Un_S,
-               Blt_Un_S,
-               Br,
-               Brfalse,
-               Brtrue,
-               Beq,
-               Bge,
-               Bgt,
-               Ble,
-               Blt,
-               Bne_Un,
-               Bge_Un,
-               Bgt_Un,
-               Ble_Un,
-               Blt_Un,
-               Switch,
-               Ldind_I1,
-               Ldind_U1,
-               Ldind_I2,
-               Ldind_U2,
-               Ldind_I4,
-               Ldind_U4,
-               Ldind_I8,
-               Ldind_I,
-               Ldind_R4,
-               Ldind_R8,
-               Ldind_Ref,
-               Stind_Ref,
-               Stind_I1,
-               Stind_I2,
-               Stind_I4,
-               Stind_I8,
-               Stind_R4,
-               Stind_R8,
-               Add,
-               Sub,
-               Mul,
-               Div,
-               Div_Un,
-               Rem,
-               Rem_Un,
-               And,
-               Or,
-               Xor,
-               Shl,
-               Shr,
-               Shr_Un,
-               Neg,
-               Not,
-               Conv_I1,
-               Conv_I2,
-               Conv_I4,
-               Conv_I8,
-               Conv_R4,
-               Conv_R8,
-               Conv_U4,
-               Conv_U8,
-               Callvirt,
-               Cpobj,
-               Ldobj,
-               Ldstr,
-               Newobj,
-               Castclass,
-               Isinst,
-               Conv_R_Un,
-               Unbox,
-               Throw,
-               Ldfld,
-               Ldflda,
-               Stfld,
-               Ldsfld,
-               Ldsflda,
-               Stsfld,
-               Stobj,
-               Conv_Ovf_I1_Un,
-               Conv_Ovf_I2_Un,
-               Conv_Ovf_I4_Un,
-               Conv_Ovf_I8_Un,
-               Conv_Ovf_U1_Un,
-               Conv_Ovf_U2_Un,
-               Conv_Ovf_U4_Un,
-               Conv_Ovf_U8_Un,
-               Conv_Ovf_I_Un,
-               Conv_Ovf_U_Un,
-               Box,
-               Newarr,
-               Ldlen,
-               Ldelema,
-               Ldelem_I1,
-               Ldelem_U1,
-               Ldelem_I2,
-               Ldelem_U2,
-               Ldelem_I4,
-               Ldelem_U4,
-               Ldelem_I8,
-               Ldelem_I,
-               Ldelem_R4,
-               Ldelem_R8,
-               Ldelem_Ref,
-               Stelem_I,
-               Stelem_I1,
-               Stelem_I2,
-               Stelem_I4,
-               Stelem_I8,
-               Stelem_R4,
-               Stelem_R8,
-               Stelem_Ref,
-               Ldelem_Any,
-               Stelem_Any,
-               Unbox_Any,
-               Conv_Ovf_I1,
-               Conv_Ovf_U1,
-               Conv_Ovf_I2,
-               Conv_Ovf_U2,
-               Conv_Ovf_I4,
-               Conv_Ovf_U4,
-               Conv_Ovf_I8,
-               Conv_Ovf_U8,
-               Refanyval,
-               Ckfinite,
-               Mkrefany,
-               Ldtoken,
-               Conv_U2,
-               Conv_U1,
-               Conv_I,
-               Conv_Ovf_I,
-               Conv_Ovf_U,
-               Add_Ovf,
-               Add_Ovf_Un,
-               Mul_Ovf,
-               Mul_Ovf_Un,
-               Sub_Ovf,
-               Sub_Ovf_Un,
-               Endfinally,
-               Leave,
-               Leave_S,
-               Stind_I,
-               Conv_U,
-               Arglist,
-               Ceq,
-               Cgt,
-               Cgt_Un,
-               Clt,
-               Clt_Un,
-               Ldftn,
-               Ldvirtftn,
-               Ldarg,
-               Ldarga,
-               Starg,
-               Ldloc,
-               Ldloca,
-               Stloc,
-               Localloc,
-               Endfilter,
-               Unaligned,
-               Volatile,
-               Tail,
-               Initobj,
-               Constrained,
-               Cpblk,
-               Initblk,
-               No,
-               Rethrow,
-               Sizeof,
-               Refanytype,
-               Readonly,
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/CodeReader.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/CodeReader.cs
deleted file mode 100644 (file)
index 61d04d9..0000000
+++ /dev/null
@@ -1,598 +0,0 @@
-//
-// CodeReader.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Cecil.PE;
-using Mono.Collections.Generic;
-
-using RVA = System.UInt32;
-
-namespace Mono.Cecil.Cil {
-
-       sealed class CodeReader : ByteBuffer {
-
-               readonly internal MetadataReader reader;
-
-               int start;
-               Section code_section;
-
-               MethodDefinition method;
-               MethodBody body;
-
-               int Offset {
-                       get { return base.position - start; }
-               }
-
-               public CodeReader (Section section, MetadataReader reader)
-                       : base (section.Data)
-               {
-                       this.code_section = section;
-                       this.reader = reader;
-               }
-
-               public MethodBody ReadMethodBody (MethodDefinition method)
-               {
-                       this.method = method;
-                       this.body = new MethodBody (method);
-
-                       reader.context = method;
-
-                       ReadMethodBody ();
-
-                       return this.body;
-               }
-
-               public void MoveTo (int rva)
-               {
-                       if (!IsInSection (rva)) {
-                               code_section = reader.image.GetSectionAtVirtualAddress ((uint) rva);
-                               Reset (code_section.Data);
-                       }
-
-                       base.position = rva - (int) code_section.VirtualAddress;
-               }
-
-               bool IsInSection (int rva)
-               {
-                       return code_section.VirtualAddress <= rva && rva < code_section.VirtualAddress + code_section.SizeOfRawData;
-               }
-
-               void ReadMethodBody ()
-               {
-                       MoveTo (method.RVA);
-
-                       var flags = ReadByte ();
-                       switch (flags & 0x3) {
-                       case 0x2: // tiny
-                               body.code_size = flags >> 2;
-                               body.MaxStackSize = 8;
-                               ReadCode ();
-                               break;
-                       case 0x3: // fat
-                               base.position--;
-                               ReadFatMethod ();
-                               break;
-                       default:
-                               throw new InvalidOperationException ();
-                       }
-
-                       var symbol_reader = reader.module.SymbolReader;
-
-                       if (symbol_reader != null) {
-                               var instructions = body.Instructions;
-                               symbol_reader.Read (body, offset => GetInstruction (instructions, offset));
-                       }
-               }
-
-               void ReadFatMethod ()
-               {
-                       var flags = ReadUInt16 ();
-                       body.max_stack_size = ReadUInt16 ();
-                       body.code_size = (int) ReadUInt32 ();
-                       body.local_var_token = new MetadataToken (ReadUInt32 ());
-                       body.init_locals = (flags & 0x10) != 0;
-
-                       if (body.local_var_token.RID != 0)
-                               body.variables = ReadVariables (body.local_var_token);
-
-                       ReadCode ();
-
-                       if ((flags & 0x8) != 0)
-                               ReadSection ();
-               }
-
-               public VariableDefinitionCollection ReadVariables (MetadataToken local_var_token)
-               {
-                       var position = reader.position;
-                       var variables = reader.ReadVariables (local_var_token);
-                       reader.position = position;
-
-                       return variables;
-               }
-
-               void ReadCode ()
-               {
-                       start = position;
-                       var code_size = body.code_size;
-
-                       if (code_size < 0 || buffer.Length <= (uint) (code_size + position))
-                               code_size = 0;
-
-                       var end = start + code_size;
-                       var instructions = body.instructions = new InstructionCollection (code_size / 3);
-
-                       while (position < end) {
-                               var offset = base.position - start;
-                               var opcode = ReadOpCode ();
-                               var current = new Instruction (offset, opcode);
-
-                               if (opcode.OperandType != OperandType.InlineNone)
-                                       current.operand = ReadOperand (current);
-
-                               instructions.Add (current);
-                       }
-
-                       ResolveBranches (instructions);
-               }
-
-               OpCode ReadOpCode ()
-               {
-                       var il_opcode = ReadByte ();
-                       return il_opcode != 0xfe
-                               ? OpCodes.OneByteOpCode [il_opcode]
-                               : OpCodes.TwoBytesOpCode [ReadByte ()];
-               }
-
-               object ReadOperand (Instruction instruction)
-               {
-                       switch (instruction.opcode.OperandType) {
-                       case OperandType.InlineSwitch:
-                               var length = ReadInt32 ();
-                               var base_offset = Offset + (4 * length);
-                               var branches = new int [length];
-                               for (int i = 0; i < length; i++)
-                                       branches [i] = base_offset + ReadInt32 ();
-                               return branches;
-                       case OperandType.ShortInlineBrTarget:
-                               return ReadSByte () + Offset;
-                       case OperandType.InlineBrTarget:
-                               return ReadInt32 () + Offset;
-                       case OperandType.ShortInlineI:
-                               if (instruction.opcode == OpCodes.Ldc_I4_S)
-                                       return ReadSByte ();
-
-                               return ReadByte ();
-                       case OperandType.InlineI:
-                               return ReadInt32 ();
-                       case OperandType.ShortInlineR:
-                               return ReadSingle ();
-                       case OperandType.InlineR:
-                               return ReadDouble ();
-                       case OperandType.InlineI8:
-                               return ReadInt64 ();
-                       case OperandType.ShortInlineVar:
-                               return GetVariable (ReadByte ());
-                       case OperandType.InlineVar:
-                               return GetVariable (ReadUInt16 ());
-                       case OperandType.ShortInlineArg:
-                               return GetParameter (ReadByte ());
-                       case OperandType.InlineArg:
-                               return GetParameter (ReadUInt16 ());
-                       case OperandType.InlineSig:
-                               return GetCallSite (ReadToken ());
-                       case OperandType.InlineString:
-                               return GetString (ReadToken ());
-                       case OperandType.InlineTok:
-                       case OperandType.InlineType:
-                       case OperandType.InlineMethod:
-                       case OperandType.InlineField:
-                               return reader.LookupToken (ReadToken ());
-                       default:
-                               throw new NotSupportedException ();
-                       }
-               }
-
-               public string GetString (MetadataToken token)
-               {
-                       return reader.image.UserStringHeap.Read (token.RID);
-               }
-
-               public ParameterDefinition GetParameter (int index)
-               {
-                       return body.GetParameter (index);
-               }
-
-               public VariableDefinition GetVariable (int index)
-               {
-                       return body.GetVariable (index);
-               }
-
-               public CallSite GetCallSite (MetadataToken token)
-               {
-                       return reader.ReadCallSite (token);
-               }
-
-               void ResolveBranches (Collection<Instruction> instructions)
-               {
-                       var items = instructions.items;
-                       var size = instructions.size;
-
-                       for (int i = 0; i < size; i++) {
-                               var instruction = items [i];
-                               switch (instruction.opcode.OperandType) {
-                               case OperandType.ShortInlineBrTarget:
-                               case OperandType.InlineBrTarget:
-                                       instruction.operand = GetInstruction ((int) instruction.operand);
-                                       break;
-                               case OperandType.InlineSwitch:
-                                       var offsets = (int []) instruction.operand;
-                                       var branches = new Instruction [offsets.Length];
-                                       for (int j = 0; j < offsets.Length; j++)
-                                               branches [j] = GetInstruction (offsets [j]);
-
-                                       instruction.operand = branches;
-                                       break;
-                               }
-                       }
-               }
-
-               Instruction GetInstruction (int offset)
-               {
-                       return GetInstruction (body.Instructions, offset);
-               }
-
-               static Instruction GetInstruction (Collection<Instruction> instructions, int offset)
-               {
-                       var size = instructions.size;
-                       var items = instructions.items;
-                       if (offset < 0 || offset > items [size - 1].offset)
-                               return null;
-
-                       int min = 0;
-                       int max = size - 1;
-                       while (min <= max) {
-                               int mid = min + ((max - min) / 2);
-                               var instruction = items [mid];
-                               var instruction_offset = instruction.offset;
-
-                               if (offset == instruction_offset)
-                                       return instruction;
-
-                               if (offset < instruction_offset)
-                                       max = mid - 1;
-                               else
-                                       min = mid + 1;
-                       }
-
-                       return null;
-               }
-
-               void ReadSection ()
-               {
-                       Align (4);
-
-                       const byte fat_format = 0x40;
-                       const byte more_sects = 0x80;
-
-                       var flags = ReadByte ();
-                       if ((flags & fat_format) == 0)
-                               ReadSmallSection ();
-                       else
-                               ReadFatSection ();
-
-                       if ((flags & more_sects) != 0)
-                               ReadSection ();
-               }
-
-               void ReadSmallSection ()
-               {
-                       var count = ReadByte () / 12;
-                       Advance (2);
-
-                       ReadExceptionHandlers (
-                               count,
-                               () => (int) ReadUInt16 (),
-                               () => (int) ReadByte ());
-               }
-
-               void ReadFatSection ()
-               {
-                       position--;
-                       var count = (ReadInt32 () >> 8) / 24;
-
-                       ReadExceptionHandlers (
-                               count,
-                               ReadInt32,
-                               ReadInt32);
-               }
-
-               // inline ?
-               void ReadExceptionHandlers (int count, Func<int> read_entry, Func<int> read_length)
-               {
-                       for (int i = 0; i < count; i++) {
-                               var handler = new ExceptionHandler (
-                                       (ExceptionHandlerType) (read_entry () & 0x7));
-
-                               handler.TryStart = GetInstruction (read_entry ());
-                               handler.TryEnd = GetInstruction (handler.TryStart.Offset + read_length ());
-
-                               handler.HandlerStart = GetInstruction (read_entry ());
-                               handler.HandlerEnd = GetInstruction (handler.HandlerStart.Offset + read_length ());
-
-                               ReadExceptionHandlerSpecific (handler);
-
-                               this.body.ExceptionHandlers.Add (handler);
-                       }
-               }
-
-               void ReadExceptionHandlerSpecific (ExceptionHandler handler)
-               {
-                       switch (handler.HandlerType) {
-                       case ExceptionHandlerType.Catch:
-                               handler.CatchType = (TypeReference) reader.LookupToken (ReadToken ());
-                               break;
-                       case ExceptionHandlerType.Filter:
-                               handler.FilterStart = GetInstruction (ReadInt32 ());
-                               break;
-                       default:
-                               Advance (4);
-                               break;
-                       }
-               }
-
-               void Align (int align)
-               {
-                       align--;
-                       Advance (((position + align) & ~align) - position);
-               }
-
-               public MetadataToken ReadToken ()
-               {
-                       return new MetadataToken (ReadUInt32 ());
-               }
-
-#if !READ_ONLY
-
-               public ByteBuffer PatchRawMethodBody (MethodDefinition method, CodeWriter writer, out MethodSymbols symbols)
-               {
-                       var buffer = new ByteBuffer ();
-                       symbols = new MethodSymbols (method.Name);
-
-                       this.method = method;
-                       reader.context = method;
-
-                       MoveTo (method.RVA);
-
-                       var flags = ReadByte ();
-
-                       MetadataToken local_var_token;
-
-                       switch (flags & 0x3) {
-                       case 0x2: // tiny
-                               buffer.WriteByte (flags);
-                               local_var_token = MetadataToken.Zero;
-                               symbols.code_size = flags >> 2;
-                               PatchRawCode (buffer, symbols.code_size, writer);
-                               break;
-                       case 0x3: // fat
-                               base.position--;
-
-                               PatchRawFatMethod (buffer, symbols, writer, out local_var_token);
-                               break;
-                       default:
-                               throw new NotSupportedException ();
-                       }
-
-                       var symbol_reader = reader.module.SymbolReader;
-                       if (symbol_reader != null && writer.metadata.write_symbols) {
-                               symbols.method_token = GetOriginalToken (writer.metadata, method);
-                               symbols.local_var_token = local_var_token;
-                               symbol_reader.Read (symbols);
-                       }
-
-                       return buffer;
-               }
-
-               void PatchRawFatMethod (ByteBuffer buffer, MethodSymbols symbols, CodeWriter writer, out MetadataToken local_var_token)
-               {
-                       var flags = ReadUInt16 ();
-                       buffer.WriteUInt16 (flags);
-                       buffer.WriteUInt16 (ReadUInt16 ());
-                       symbols.code_size = ReadInt32 ();
-                       buffer.WriteInt32 (symbols.code_size);
-                       local_var_token = ReadToken ();
-
-                       if (local_var_token.RID > 0) {
-                               var variables = symbols.variables = ReadVariables (local_var_token);
-                               buffer.WriteUInt32 (variables != null
-                                       ? writer.GetStandAloneSignature (symbols.variables).ToUInt32 ()
-                                       : 0);
-                       } else
-                               buffer.WriteUInt32 (0);
-
-                       PatchRawCode (buffer, symbols.code_size, writer);
-
-                       if ((flags & 0x8) != 0)
-                               PatchRawSection (buffer, writer.metadata);
-               }
-
-               static MetadataToken GetOriginalToken (MetadataBuilder metadata, MethodDefinition method)
-               {
-                       MetadataToken original;
-                       if (metadata.TryGetOriginalMethodToken (method.token, out original))
-                               return original;
-
-                       return MetadataToken.Zero;
-               }
-
-               void PatchRawCode (ByteBuffer buffer, int code_size, CodeWriter writer)
-               {
-                       var metadata = writer.metadata;
-                       buffer.WriteBytes (ReadBytes (code_size));
-                       var end = buffer.position;
-                       buffer.position -= code_size;
-
-                       while (buffer.position < end) {
-                               OpCode opcode;
-                               var il_opcode = buffer.ReadByte ();
-                               if (il_opcode != 0xfe) {
-                                       opcode = OpCodes.OneByteOpCode [il_opcode];
-                               } else {
-                                       var il_opcode2 = buffer.ReadByte ();
-                                       opcode = OpCodes.TwoBytesOpCode [il_opcode2];
-                               }
-
-                               switch (opcode.OperandType) {
-                               case OperandType.ShortInlineI:
-                               case OperandType.ShortInlineBrTarget:
-                               case OperandType.ShortInlineVar:
-                               case OperandType.ShortInlineArg:
-                                       buffer.position += 1;
-                                       break;
-                               case OperandType.InlineVar:
-                               case OperandType.InlineArg:
-                                       buffer.position += 2;
-                                       break;
-                               case OperandType.InlineBrTarget:
-                               case OperandType.ShortInlineR:
-                               case OperandType.InlineI:
-                                       buffer.position += 4;
-                                       break;
-                               case OperandType.InlineI8:
-                               case OperandType.InlineR:
-                                       buffer.position += 8;
-                                       break;
-                               case OperandType.InlineSwitch:
-                                       var length = buffer.ReadInt32 ();
-                                       buffer.position += length * 4;
-                                       break;
-                               case OperandType.InlineString:
-                                       var @string = GetString (new MetadataToken (buffer.ReadUInt32 ()));
-                                       buffer.position -= 4;
-                                       buffer.WriteUInt32 (
-                                               new MetadataToken (
-                                                       TokenType.String,
-                                                       metadata.user_string_heap.GetStringIndex (@string)).ToUInt32 ());
-                                       break;
-                               case OperandType.InlineSig:
-                                       var call_site = GetCallSite (new MetadataToken (buffer.ReadUInt32 ()));
-                                       buffer.position -= 4;
-                                       buffer.WriteUInt32 (writer.GetStandAloneSignature (call_site).ToUInt32 ());
-                                       break;
-                               case OperandType.InlineTok:
-                               case OperandType.InlineType:
-                               case OperandType.InlineMethod:
-                               case OperandType.InlineField:
-                                       var provider = reader.LookupToken (new MetadataToken (buffer.ReadUInt32 ()));
-                                       buffer.position -= 4;
-                                       buffer.WriteUInt32 (metadata.LookupToken (provider).ToUInt32 ());
-                                       break;
-                               }
-                       }
-               }
-
-               void PatchRawSection (ByteBuffer buffer, MetadataBuilder metadata)
-               {
-                       var position = base.position;
-                       Align (4);
-                       buffer.WriteBytes (base.position - position);
-
-                       const byte fat_format = 0x40;
-                       const byte more_sects = 0x80;
-
-                       var flags = ReadByte ();
-                       if ((flags & fat_format) == 0) {
-                               buffer.WriteByte (flags);
-                               PatchRawSmallSection (buffer, metadata);
-                       } else
-                               PatchRawFatSection (buffer, metadata);
-
-                       if ((flags & more_sects) != 0)
-                               PatchRawSection (buffer, metadata);
-               }
-
-               void PatchRawSmallSection (ByteBuffer buffer, MetadataBuilder metadata)
-               {
-                       var length = ReadByte ();
-                       buffer.WriteByte (length);
-                       Advance (2);
-
-                       buffer.WriteUInt16 (0);
-
-                       var count = length / 12;
-
-                       PatchRawExceptionHandlers (buffer, metadata, count, false);
-               }
-
-               void PatchRawFatSection (ByteBuffer buffer, MetadataBuilder metadata)
-               {
-                       position--;
-                       var length = ReadInt32 ();
-                       buffer.WriteInt32 (length);
-
-                       var count = (length >> 8) / 24;
-
-                       PatchRawExceptionHandlers (buffer, metadata, count, true);
-               }
-
-               void PatchRawExceptionHandlers (ByteBuffer buffer, MetadataBuilder metadata, int count, bool fat_entry)
-               {
-                       const int fat_entry_size = 16;
-                       const int small_entry_size = 6;
-
-                       for (int i = 0; i < count; i++) {
-                               ExceptionHandlerType handler_type;
-                               if (fat_entry) {
-                                       var type = ReadUInt32 ();
-                                       handler_type = (ExceptionHandlerType) (type & 0x7);
-                                       buffer.WriteUInt32 (type);
-                               } else {
-                                       var type = ReadUInt16 ();
-                                       handler_type = (ExceptionHandlerType) (type & 0x7);
-                                       buffer.WriteUInt16 (type);
-                               }
-
-                               buffer.WriteBytes (ReadBytes (fat_entry ? fat_entry_size : small_entry_size));
-
-                               switch (handler_type) {
-                               case ExceptionHandlerType.Catch:
-                                       var exception = reader.LookupToken (ReadToken ());
-                                       buffer.WriteUInt32 (metadata.LookupToken (exception).ToUInt32 ());
-                                       break;
-                               default:
-                                       buffer.WriteUInt32 (ReadUInt32 ());
-                                       break;
-                               }
-                       }
-               }
-
-#endif
-
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/CodeWriter.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/CodeWriter.cs
deleted file mode 100644 (file)
index 02876aa..0000000
+++ /dev/null
@@ -1,641 +0,0 @@
-//
-// CodeWriter.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-
-using Mono.Collections.Generic;
-
-using Mono.Cecil.Metadata;
-using Mono.Cecil.PE;
-
-using RVA = System.UInt32;
-
-#if !READ_ONLY
-
-namespace Mono.Cecil.Cil {
-
-       sealed class CodeWriter : ByteBuffer {
-
-               readonly RVA code_base;
-               internal readonly MetadataBuilder metadata;
-               readonly Dictionary<uint, MetadataToken> standalone_signatures;
-
-               RVA current;
-               MethodBody body;
-
-               public CodeWriter (MetadataBuilder metadata)
-                       : base (0)
-               {
-                       this.code_base = metadata.text_map.GetNextRVA (TextSegment.CLIHeader);
-                       this.current = code_base;
-                       this.metadata = metadata;
-                       this.standalone_signatures = new Dictionary<uint, MetadataToken> ();
-               }
-
-               public RVA WriteMethodBody (MethodDefinition method)
-               {
-                       var rva = BeginMethod ();
-
-                       if (IsUnresolved (method)) {
-                               if (method.rva == 0)
-                                       return 0;
-
-                               WriteUnresolvedMethodBody (method);
-                       } else {
-                               if (IsEmptyMethodBody (method.Body))
-                                       return 0;
-
-                               WriteResolvedMethodBody (method);
-                       }
-
-                       Align (4);
-
-                       EndMethod ();
-                       return rva;
-               }
-
-               static bool IsEmptyMethodBody (MethodBody body)
-               {
-                       return body.instructions.IsNullOrEmpty ()
-                               && body.variables.IsNullOrEmpty ();
-               }
-
-               static bool IsUnresolved (MethodDefinition method)
-               {
-                       return method.HasBody && method.HasImage && method.body == null;
-               }
-
-               void WriteUnresolvedMethodBody (MethodDefinition method)
-               {
-                       var code_reader = metadata.module.Read (method, (_, reader) => reader.code);
-
-                       MethodSymbols symbols;
-                       var buffer = code_reader.PatchRawMethodBody (method, this, out symbols);
-
-                       WriteBytes (buffer);
-
-                       if (symbols.instructions.IsNullOrEmpty ())
-                               return;
-
-                       symbols.method_token = method.token;
-                       symbols.local_var_token = GetLocalVarToken (buffer, symbols);
-
-                       var symbol_writer = metadata.symbol_writer;
-                       if (symbol_writer != null)
-                               symbol_writer.Write (symbols);
-               }
-
-               static MetadataToken GetLocalVarToken (ByteBuffer buffer, MethodSymbols symbols)
-               {
-                       if (symbols.variables.IsNullOrEmpty ())
-                               return MetadataToken.Zero;
-
-                       buffer.position = 8;
-                       return new MetadataToken (buffer.ReadUInt32 ());
-               }
-
-               void WriteResolvedMethodBody (MethodDefinition method)
-               {
-                       body = method.Body;
-                       ComputeHeader ();
-                       if (RequiresFatHeader ())
-                               WriteFatHeader ();
-                       else
-                               WriteByte ((byte) (0x2 | (body.CodeSize << 2))); // tiny
-
-                       WriteInstructions ();
-
-                       if (body.HasExceptionHandlers)
-                               WriteExceptionHandlers ();
-
-                       var symbol_writer = metadata.symbol_writer;
-                       if (symbol_writer != null)
-                               symbol_writer.Write (body);
-               }
-
-               void WriteFatHeader ()
-               {
-                       var body = this.body;
-                       byte flags = 0x3;       // fat
-                       if (body.InitLocals)
-                               flags |= 0x10;  // init locals
-                       if (body.HasExceptionHandlers)
-                               flags |= 0x8;   // more sections
-
-                       WriteByte (flags);
-                       WriteByte (0x30);
-                       WriteInt16 ((short) body.max_stack_size);
-                       WriteInt32 (body.code_size);
-                       body.local_var_token = body.HasVariables
-                               ? GetStandAloneSignature (body.Variables)
-                               : MetadataToken.Zero;
-                       WriteMetadataToken (body.local_var_token);
-               }
-
-               void WriteInstructions ()
-               {
-                       var instructions = body.Instructions;
-                       var items = instructions.items;
-                       var size = instructions.size;
-
-                       for (int i = 0; i < size; i++) {
-                               var instruction = items [i];
-                               WriteOpCode (instruction.opcode);
-                               WriteOperand (instruction);
-                       }
-               }
-
-               void WriteOpCode (OpCode opcode)
-               {
-                       if (opcode.Size == 1) {
-                               WriteByte (opcode.Op2);
-                       } else {
-                               WriteByte (opcode.Op1);
-                               WriteByte (opcode.Op2);
-                       }
-               }
-
-               void WriteOperand (Instruction instruction)
-               {
-                       var opcode = instruction.opcode;
-                       var operand_type = opcode.OperandType;
-                       if (operand_type == OperandType.InlineNone)
-                               return;
-
-                       var operand = instruction.operand;
-                       if (operand == null)
-                               throw new ArgumentException ();
-
-                       switch (operand_type) {
-                       case OperandType.InlineSwitch: {
-                               var targets = (Instruction []) operand;
-                               WriteInt32 (targets.Length);
-                               var diff = instruction.Offset + opcode.Size + (4 * (targets.Length + 1));
-                               for (int i = 0; i < targets.Length; i++)
-                                       WriteInt32 (GetTargetOffset (targets [i]) - diff);
-                               break;
-                       }
-                       case OperandType.ShortInlineBrTarget: {
-                               var target = (Instruction) operand;
-                               WriteSByte ((sbyte) (GetTargetOffset (target) - (instruction.Offset + opcode.Size + 1)));
-                               break;
-                       }
-                       case OperandType.InlineBrTarget: {
-                               var target = (Instruction) operand;
-                               WriteInt32 (GetTargetOffset (target) - (instruction.Offset + opcode.Size + 4));
-                               break;
-                       }
-                       case OperandType.ShortInlineVar:
-                               WriteByte ((byte) GetVariableIndex ((VariableDefinition) operand));
-                               break;
-                       case OperandType.ShortInlineArg:
-                               WriteByte ((byte) GetParameterIndex ((ParameterDefinition) operand));
-                               break;
-                       case OperandType.InlineVar:
-                               WriteInt16 ((short) GetVariableIndex ((VariableDefinition) operand));
-                               break;
-                       case OperandType.InlineArg:
-                               WriteInt16 ((short) GetParameterIndex ((ParameterDefinition) operand));
-                               break;
-                       case OperandType.InlineSig:
-                               WriteMetadataToken (GetStandAloneSignature ((CallSite) operand));
-                               break;
-                       case OperandType.ShortInlineI:
-                               if (opcode == OpCodes.Ldc_I4_S)
-                                       WriteSByte ((sbyte) operand);
-                               else
-                                       WriteByte ((byte) operand);
-                               break;
-                       case OperandType.InlineI:
-                               WriteInt32 ((int) operand);
-                               break;
-                       case OperandType.InlineI8:
-                               WriteInt64 ((long) operand);
-                               break;
-                       case OperandType.ShortInlineR:
-                               WriteSingle ((float) operand);
-                               break;
-                       case OperandType.InlineR:
-                               WriteDouble ((double) operand);
-                               break;
-                       case OperandType.InlineString:
-                               WriteMetadataToken (
-                                       new MetadataToken (
-                                               TokenType.String,
-                                               GetUserStringIndex ((string) operand)));
-                               break;
-                       case OperandType.InlineType:
-                       case OperandType.InlineField:
-                       case OperandType.InlineMethod:
-                       case OperandType.InlineTok:
-                               WriteMetadataToken (metadata.LookupToken ((IMetadataTokenProvider) operand));
-                               break;
-                       default:
-                               throw new ArgumentException ();
-                       }
-               }
-
-               int GetTargetOffset (Instruction instruction)
-               {
-                       if (instruction == null) {
-                               var last = body.instructions [body.instructions.size - 1];
-                               return last.offset + last.GetSize ();
-                       }
-
-                       return instruction.offset;
-               }
-
-               uint GetUserStringIndex (string @string)
-               {
-                       if (@string == null)
-                               return 0;
-
-                       return metadata.user_string_heap.GetStringIndex (@string);
-               }
-
-               static int GetVariableIndex (VariableDefinition variable)
-               {
-                       return variable.Index;
-               }
-
-               int GetParameterIndex (ParameterDefinition parameter)
-               {
-                       if (body.method.HasThis) {
-                               if (parameter == body.this_parameter)
-                                       return 0;
-
-                               return parameter.Index + 1;
-                       }
-
-                       return parameter.Index;
-               }
-
-               bool RequiresFatHeader ()
-               {
-                       var body = this.body;
-                       return body.CodeSize >= 64
-                               || body.InitLocals
-                               || body.HasVariables
-                               || body.HasExceptionHandlers
-                               || body.MaxStackSize > 8;
-               }
-
-               void ComputeHeader ()
-               {
-                       int offset = 0;
-                       var instructions = body.instructions;
-                       var items = instructions.items;
-                       var count = instructions.size;
-                       var stack_size = 0;
-                       var max_stack = 0;
-                       Dictionary<Instruction, int> stack_sizes = null;
-
-                       if (body.HasExceptionHandlers)
-                               ComputeExceptionHandlerStackSize (ref stack_sizes);
-
-                       for (int i = 0; i < count; i++) {
-                               var instruction = items [i];
-                               instruction.offset = offset;
-                               offset += instruction.GetSize ();
-
-                               ComputeStackSize (instruction, ref stack_sizes, ref stack_size, ref max_stack);
-                       }
-
-                       body.code_size = offset;
-                       body.max_stack_size = max_stack;
-               }
-
-               void ComputeExceptionHandlerStackSize (ref Dictionary<Instruction, int> stack_sizes)
-               {
-                       var exception_handlers = body.ExceptionHandlers;
-
-                       for (int i = 0; i < exception_handlers.Count; i++) {
-                               var exception_handler = exception_handlers [i];
-
-                               switch (exception_handler.HandlerType) {
-                               case ExceptionHandlerType.Catch:
-                                       AddExceptionStackSize (exception_handler.HandlerStart, ref stack_sizes);
-                                       break;
-                               case ExceptionHandlerType.Filter:
-                                       AddExceptionStackSize (exception_handler.FilterStart, ref stack_sizes);
-                                       AddExceptionStackSize (exception_handler.HandlerStart, ref stack_sizes);
-                                       break;
-                               }
-                       }
-               }
-
-               static void AddExceptionStackSize (Instruction handler_start, ref Dictionary<Instruction, int> stack_sizes)
-               {
-                       if (handler_start == null)
-                               return;
-
-                       if (stack_sizes == null)
-                               stack_sizes = new Dictionary<Instruction, int> ();
-
-                       stack_sizes [handler_start] = 1;
-               }
-
-               static void ComputeStackSize (Instruction instruction, ref Dictionary<Instruction, int> stack_sizes, ref int stack_size, ref int max_stack)
-               {
-                       int computed_size;
-                       if (stack_sizes != null && stack_sizes.TryGetValue (instruction, out computed_size))
-                               stack_size = computed_size;
-
-                       max_stack = System.Math.Max (max_stack, stack_size);
-                       ComputeStackDelta (instruction, ref stack_size);
-                       max_stack = System.Math.Max (max_stack, stack_size);
-
-                       CopyBranchStackSize (instruction, ref stack_sizes, stack_size);
-                       ComputeStackSize (instruction, ref stack_size);
-               }
-
-               static void CopyBranchStackSize (Instruction instruction, ref Dictionary<Instruction, int> stack_sizes, int stack_size)
-               {
-                       if (stack_size == 0)
-                               return;
-
-                       switch (instruction.opcode.OperandType) {
-                       case OperandType.ShortInlineBrTarget:
-                       case OperandType.InlineBrTarget:
-                               CopyBranchStackSize (ref stack_sizes, (Instruction) instruction.operand, stack_size);
-                               break;
-                       case OperandType.InlineSwitch:
-                               var targets = (Instruction[]) instruction.operand;
-                               for (int i = 0; i < targets.Length; i++)
-                                       CopyBranchStackSize (ref stack_sizes, targets [i], stack_size);
-                               break;
-                       }
-               }
-
-               static void CopyBranchStackSize (ref Dictionary<Instruction, int> stack_sizes, Instruction target, int stack_size)
-               {
-                       if (stack_sizes == null)
-                               stack_sizes = new Dictionary<Instruction, int> ();
-
-                       int branch_stack_size = stack_size;
-
-                       int computed_size;
-                       if (stack_sizes.TryGetValue (target, out computed_size))
-                               branch_stack_size = System.Math.Max (branch_stack_size, computed_size);
-
-                       stack_sizes [target] = branch_stack_size;
-               }
-
-               static void ComputeStackSize (Instruction instruction, ref int stack_size)
-               {
-                       switch (instruction.opcode.FlowControl) {
-                       case FlowControl.Branch:
-                       case FlowControl.Break:
-                       case FlowControl.Throw:
-                       case FlowControl.Return:
-                               stack_size = 0;
-                               break;
-                       }
-               }
-
-               static void ComputeStackDelta (Instruction instruction, ref int stack_size)
-               {
-                       switch (instruction.opcode.FlowControl) {
-                       case FlowControl.Call: {
-                               var method = (IMethodSignature) instruction.operand;
-                               stack_size -= (method.HasParameters ? method.Parameters.Count : 0)
-                                       + (method.HasThis && instruction.opcode.Code != Code.Newobj ? 1 : 0);
-                               stack_size += (method.ReturnType.etype == ElementType.Void ? 0 : 1)
-                                       + (method.HasThis && instruction.opcode.Code == Code.Newobj ? 1 : 0);
-                               break;
-                       }
-                       default:
-                               ComputePopDelta (instruction.opcode.StackBehaviourPop, ref stack_size);
-                               ComputePushDelta (instruction.opcode.StackBehaviourPush, ref stack_size);
-                               break;
-                       }
-               }
-
-               static void ComputePopDelta (StackBehaviour pop_behavior, ref int stack_size)
-               {
-                       switch (pop_behavior) {
-                       case StackBehaviour.Popi:
-                       case StackBehaviour.Popref:
-                       case StackBehaviour.Pop1:
-                               stack_size--;
-                               break;
-                       case StackBehaviour.Pop1_pop1:
-                       case StackBehaviour.Popi_pop1:
-                       case StackBehaviour.Popi_popi:
-                       case StackBehaviour.Popi_popi8:
-                       case StackBehaviour.Popi_popr4:
-                       case StackBehaviour.Popi_popr8:
-                       case StackBehaviour.Popref_pop1:
-                       case StackBehaviour.Popref_popi:
-                               stack_size -= 2;
-                               break;
-                       case StackBehaviour.Popi_popi_popi:
-                       case StackBehaviour.Popref_popi_popi:
-                       case StackBehaviour.Popref_popi_popi8:
-                       case StackBehaviour.Popref_popi_popr4:
-                       case StackBehaviour.Popref_popi_popr8:
-                       case StackBehaviour.Popref_popi_popref:
-                               stack_size -= 3;
-                               break;
-                       case StackBehaviour.PopAll:
-                               stack_size = 0;
-                               break;
-                       }
-               }
-
-               static void ComputePushDelta (StackBehaviour push_behaviour, ref int stack_size)
-               {
-                       switch (push_behaviour) {
-                       case StackBehaviour.Push1:
-                       case StackBehaviour.Pushi:
-                       case StackBehaviour.Pushi8:
-                       case StackBehaviour.Pushr4:
-                       case StackBehaviour.Pushr8:
-                       case StackBehaviour.Pushref:
-                               stack_size++;
-                               break;
-                       case StackBehaviour.Push1_push1:
-                               stack_size += 2;
-                               break;
-                       }
-               }
-
-               void WriteExceptionHandlers ()
-               {
-                       Align (4);
-
-                       var handlers = body.ExceptionHandlers;
-
-                       if (handlers.Count < 0x15 && !RequiresFatSection (handlers))
-                               WriteSmallSection (handlers);
-                       else
-                               WriteFatSection (handlers);
-               }
-
-               static bool RequiresFatSection (Collection<ExceptionHandler> handlers)
-               {
-                       for (int i = 0; i < handlers.Count; i++) {
-                               var handler = handlers [i];
-
-                               if (IsFatRange (handler.TryStart, handler.TryEnd))
-                                       return true;
-
-                               if (IsFatRange (handler.HandlerStart, handler.HandlerEnd))
-                                       return true;
-
-                               if (handler.HandlerType == ExceptionHandlerType.Filter
-                                       && IsFatRange (handler.FilterStart, handler.HandlerStart))
-                                       return true;
-                       }
-
-                       return false;
-               }
-
-               static bool IsFatRange (Instruction start, Instruction end)
-               {
-                       if (start == null)
-                               throw new ArgumentException ();
-
-                       if (end == null)
-                               return true;
-
-                       return end.Offset - start.Offset > 255 || start.Offset > 65535;
-               }
-
-               void WriteSmallSection (Collection<ExceptionHandler> handlers)
-               {
-                       const byte eh_table = 0x1;
-
-                       WriteByte (eh_table);
-                       WriteByte ((byte) (handlers.Count * 12 + 4));
-                       WriteBytes (2);
-
-                       WriteExceptionHandlers (
-                               handlers,
-                               i => WriteUInt16 ((ushort) i),
-                               i => WriteByte ((byte) i));
-               }
-
-               void WriteFatSection (Collection<ExceptionHandler> handlers)
-               {
-                       const byte eh_table = 0x1;
-                       const byte fat_format = 0x40;
-
-                       WriteByte (eh_table | fat_format);
-
-                       int size = handlers.Count * 24 + 4;
-                       WriteByte ((byte) (size & 0xff));
-                       WriteByte ((byte) ((size >> 8) & 0xff));
-                       WriteByte ((byte) ((size >> 16) & 0xff));
-
-                       WriteExceptionHandlers (handlers, WriteInt32, WriteInt32);
-               }
-
-               void WriteExceptionHandlers (Collection<ExceptionHandler> handlers, Action<int> write_entry, Action<int> write_length)
-               {
-                       for (int i = 0; i < handlers.Count; i++) {
-                               var handler = handlers [i];
-
-                               write_entry ((int) handler.HandlerType);
-
-                               write_entry (handler.TryStart.Offset);
-                               write_length (GetTargetOffset (handler.TryEnd) - handler.TryStart.Offset);
-
-                               write_entry (handler.HandlerStart.Offset);
-                               write_length (GetTargetOffset (handler.HandlerEnd) - handler.HandlerStart.Offset);
-
-                               WriteExceptionHandlerSpecific (handler);
-                       }
-               }
-
-               void WriteExceptionHandlerSpecific (ExceptionHandler handler)
-               {
-                       switch (handler.HandlerType) {
-                       case ExceptionHandlerType.Catch:
-                               WriteMetadataToken (metadata.LookupToken (handler.CatchType));
-                               break;
-                       case ExceptionHandlerType.Filter:
-                               WriteInt32 (handler.FilterStart.Offset);
-                               break;
-                       default:
-                               WriteInt32 (0);
-                               break;
-                       }
-               }
-
-               public MetadataToken GetStandAloneSignature (Collection<VariableDefinition> variables)
-               {
-                       var signature = metadata.GetLocalVariableBlobIndex (variables);
-
-                       return GetStandAloneSignatureToken (signature);
-               }
-
-               public MetadataToken GetStandAloneSignature (CallSite call_site)
-               {
-                       var signature = metadata.GetCallSiteBlobIndex (call_site);
-                       var token = GetStandAloneSignatureToken (signature);
-                       call_site.MetadataToken = token;
-                       return token;
-               }
-
-               MetadataToken GetStandAloneSignatureToken (uint signature)
-               {
-                       MetadataToken token;
-                       if (standalone_signatures.TryGetValue (signature, out token))
-                               return token;
-
-                       token = new MetadataToken (TokenType.Signature, metadata.AddStandAloneSignature (signature));
-                       standalone_signatures.Add (signature, token);
-                       return token;
-               }
-
-               RVA BeginMethod ()
-               {
-                       return current;
-               }
-
-               void WriteMetadataToken (MetadataToken token)
-               {
-                       WriteUInt32 (token.ToUInt32 ());
-               }
-
-               void Align (int align)
-               {
-                       align--;
-                       WriteBytes (((position + align) & ~align) - position);
-               }
-
-               void EndMethod ()
-               {
-                       current = (RVA) (code_base + position);
-               }
-       }
-}
-
-#endif
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/Document.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/Document.cs
deleted file mode 100644 (file)
index 6648b7a..0000000
+++ /dev/null
@@ -1,111 +0,0 @@
-//
-// Document.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil.Cil {
-
-       public enum DocumentType {
-               Other,
-               Text,
-       }
-
-       public enum DocumentHashAlgorithm {
-               None,
-               MD5,
-               SHA1,
-       }
-
-       public enum DocumentLanguage {
-               Other,
-               C,
-               Cpp,
-               CSharp,
-               Basic,
-               Java,
-               Cobol,
-               Pascal,
-               Cil,
-               JScript,
-               Smc,
-               MCpp,
-       }
-
-       public enum DocumentLanguageVendor {
-               Other,
-               Microsoft,
-       }
-
-       public sealed class Document {
-
-               string url;
-
-               byte type;
-               byte hash_algorithm;
-               byte language;
-               byte language_vendor;
-
-               byte [] hash;
-
-               public string Url {
-                       get { return url; }
-                       set { url = value; }
-               }
-
-               public DocumentType Type {
-                       get { return (DocumentType) type; }
-                       set { type = (byte) value; }
-               }
-
-               public DocumentHashAlgorithm HashAlgorithm {
-                       get { return (DocumentHashAlgorithm) hash_algorithm; }
-                       set { hash_algorithm = (byte) value; }
-               }
-
-               public DocumentLanguage Language {
-                       get { return (DocumentLanguage) language; }
-                       set { language = (byte) value; }
-               }
-
-               public DocumentLanguageVendor LanguageVendor {
-                       get { return (DocumentLanguageVendor) language_vendor; }
-                       set { language_vendor = (byte) value; }
-               }
-
-               public byte [] Hash {
-                       get { return hash; }
-                       set { hash = value; }
-               }
-
-               public Document (string url)
-               {
-                       this.url = url;
-                       this.hash = Empty<byte>.Array;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/ExceptionHandler.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/ExceptionHandler.cs
deleted file mode 100644 (file)
index c61ff23..0000000
+++ /dev/null
@@ -1,89 +0,0 @@
-//
-// ExceptionHandler.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil.Cil {
-
-       public enum ExceptionHandlerType {
-               Catch = 0,
-               Filter = 1,
-               Finally = 2,
-               Fault = 4,
-       }
-
-       public sealed class ExceptionHandler {
-
-               Instruction try_start;
-               Instruction try_end;
-               Instruction filter_start;
-               Instruction handler_start;
-               Instruction handler_end;
-
-               TypeReference catch_type;
-               ExceptionHandlerType handler_type;
-
-               public Instruction TryStart {
-                       get { return try_start; }
-                       set { try_start = value; }
-               }
-
-               public Instruction TryEnd {
-                       get { return try_end; }
-                       set { try_end = value; }
-               }
-
-               public Instruction FilterStart {
-                       get { return filter_start; }
-                       set { filter_start = value; }
-               }
-
-               public Instruction HandlerStart {
-                       get { return handler_start; }
-                       set { handler_start = value; }
-               }
-
-               public Instruction HandlerEnd {
-                       get { return handler_end; }
-                       set { handler_end = value; }
-               }
-
-               public TypeReference CatchType {
-                       get { return catch_type; }
-                       set { catch_type = value; }
-               }
-
-               public ExceptionHandlerType HandlerType {
-                       get { return handler_type; }
-                       set { handler_type = value; }
-               }
-
-               public ExceptionHandler (ExceptionHandlerType handlerType)
-               {
-                       this.handler_type = handlerType;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/ILProcessor.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/ILProcessor.cs
deleted file mode 100644 (file)
index cd5dbb4..0000000
+++ /dev/null
@@ -1,278 +0,0 @@
-//
-// ILProcessor.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil.Cil {
-
-       public sealed class ILProcessor {
-
-               readonly MethodBody body;
-               readonly Collection<Instruction> instructions;
-
-               public MethodBody Body {
-                       get { return body; }
-               }
-
-               internal ILProcessor (MethodBody body)
-               {
-                       this.body = body;
-                       this.instructions = body.Instructions;
-               }
-
-               public Instruction Create (OpCode opcode)
-               {
-                       return Instruction.Create (opcode);
-               }
-
-               public Instruction Create (OpCode opcode, TypeReference type)
-               {
-                       return Instruction.Create (opcode, type);
-               }
-
-               public Instruction Create (OpCode opcode, CallSite site)
-               {
-                       return Instruction.Create (opcode, site);
-               }
-
-               public Instruction Create (OpCode opcode, MethodReference method)
-               {
-                       return Instruction.Create (opcode, method);
-               }
-
-               public Instruction Create (OpCode opcode, FieldReference field)
-               {
-                       return Instruction.Create (opcode, field);
-               }
-
-               public Instruction Create (OpCode opcode, string value)
-               {
-                       return Instruction.Create (opcode, value);
-               }
-
-               public Instruction Create (OpCode opcode, sbyte value)
-               {
-                       return Instruction.Create (opcode, value);
-               }
-
-               public Instruction Create (OpCode opcode, byte value)
-               {
-                       if (opcode.OperandType == OperandType.ShortInlineVar)
-                               return Instruction.Create (opcode, body.Variables [value]);
-
-                       if (opcode.OperandType == OperandType.ShortInlineArg)
-                               return Instruction.Create (opcode, body.GetParameter (value));
-
-                       return Instruction.Create (opcode, value);
-               }
-
-               public Instruction Create (OpCode opcode, int value)
-               {
-                       if (opcode.OperandType == OperandType.InlineVar)
-                               return Instruction.Create (opcode, body.Variables [value]);
-
-                       if (opcode.OperandType == OperandType.InlineArg)
-                               return Instruction.Create (opcode, body.GetParameter (value));
-
-                       return Instruction.Create (opcode, value);
-               }
-
-               public Instruction Create (OpCode opcode, long value)
-               {
-                       return Instruction.Create (opcode, value);
-               }
-
-               public Instruction Create (OpCode opcode, float value)
-               {
-                       return Instruction.Create (opcode, value);
-               }
-
-               public Instruction Create (OpCode opcode, double value)
-               {
-                       return Instruction.Create (opcode, value);
-               }
-
-               public Instruction Create (OpCode opcode, Instruction target)
-               {
-                       return Instruction.Create (opcode, target);
-               }
-
-               public Instruction Create (OpCode opcode, Instruction [] targets)
-               {
-                       return Instruction.Create (opcode, targets);
-               }
-
-               public Instruction Create (OpCode opcode, VariableDefinition variable)
-               {
-                       return Instruction.Create (opcode, variable);
-               }
-
-               public Instruction Create (OpCode opcode, ParameterDefinition parameter)
-               {
-                       return Instruction.Create (opcode, parameter);
-               }
-
-               public void Emit (OpCode opcode)
-               {
-                       Append (Create (opcode));
-               }
-
-               public void Emit (OpCode opcode, TypeReference type)
-               {
-                       Append (Create (opcode, type));
-               }
-
-               public void Emit (OpCode opcode, MethodReference method)
-               {
-                       Append (Create (opcode, method));
-               }
-
-               public void Emit (OpCode opcode, CallSite site)
-               {
-                       Append (Create (opcode, site));
-               }
-
-               public void Emit (OpCode opcode, FieldReference field)
-               {
-                       Append (Create (opcode, field));
-               }
-
-               public void Emit (OpCode opcode, string value)
-               {
-                       Append (Create (opcode, value));
-               }
-
-               public void Emit (OpCode opcode, byte value)
-               {
-                       Append (Create (opcode, value));
-               }
-
-               public void Emit (OpCode opcode, sbyte value)
-               {
-                       Append (Create (opcode, value));
-               }
-
-               public void Emit (OpCode opcode, int value)
-               {
-                       Append (Create (opcode, value));
-               }
-
-               public void Emit (OpCode opcode, long value)
-               {
-                       Append (Create (opcode, value));
-               }
-
-               public void Emit (OpCode opcode, float value)
-               {
-                       Append (Create (opcode, value));
-               }
-
-               public void Emit (OpCode opcode, double value)
-               {
-                       Append (Create (opcode, value));
-               }
-
-               public void Emit (OpCode opcode, Instruction target)
-               {
-                       Append (Create (opcode, target));
-               }
-
-               public void Emit (OpCode opcode, Instruction [] targets)
-               {
-                       Append (Create (opcode, targets));
-               }
-
-               public void Emit (OpCode opcode, VariableDefinition variable)
-               {
-                       Append (Create (opcode, variable));
-               }
-
-               public void Emit (OpCode opcode, ParameterDefinition parameter)
-               {
-                       Append (Create (opcode, parameter));
-               }
-
-               public void InsertBefore (Instruction target, Instruction instruction)
-               {
-                       if (target == null)
-                               throw new ArgumentNullException ("target");
-                       if (instruction == null)
-                               throw new ArgumentNullException ("instruction");
-
-                       var index = instructions.IndexOf (target);
-                       if (index == -1)
-                               throw new ArgumentOutOfRangeException ("target");
-
-                       instructions.Insert (index, instruction);
-               }
-
-               public void InsertAfter (Instruction target, Instruction instruction)
-               {
-                       if (target == null)
-                               throw new ArgumentNullException ("target");
-                       if (instruction == null)
-                               throw new ArgumentNullException ("instruction");
-
-                       var index = instructions.IndexOf (target);
-                       if (index == -1)
-                               throw new ArgumentOutOfRangeException ("target");
-
-                       instructions.Insert (index + 1, instruction);
-               }
-
-               public void Append (Instruction instruction)
-               {
-                       if (instruction == null)
-                               throw new ArgumentNullException ("instruction");
-
-                       instructions.Add (instruction);
-               }
-
-               public void Replace (Instruction target, Instruction instruction)
-               {
-                       if (target == null)
-                               throw new ArgumentNullException ("target");
-                       if (instruction == null)
-                               throw new ArgumentNullException ("instruction");
-
-                       InsertAfter (target, instruction);
-                       Remove (target);
-               }
-
-               public void Remove (Instruction instruction)
-               {
-                       if (instruction == null)
-                               throw new ArgumentNullException ("instruction");
-
-                       if (!instructions.Remove (instruction))
-                               throw new ArgumentOutOfRangeException ("instruction");
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/Instruction.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/Instruction.cs
deleted file mode 100644 (file)
index c28d4c9..0000000
+++ /dev/null
@@ -1,321 +0,0 @@
-//
-// Instruction.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Text;
-
-namespace Mono.Cecil.Cil {
-
-       public sealed class Instruction {
-
-               internal int offset;
-               internal OpCode opcode;
-               internal object operand;
-
-               internal Instruction previous;
-               internal Instruction next;
-
-               SequencePoint sequence_point;
-
-               public int Offset {
-                       get { return offset; }
-                       set { offset = value; }
-               }
-
-               public OpCode OpCode {
-                       get { return opcode; }
-                       set { opcode = value; }
-               }
-
-               public object Operand {
-                       get { return operand; }
-                       set { operand = value; }
-               }
-
-               public Instruction Previous {
-                       get { return previous; }
-                       set { previous = value; }
-               }
-
-               public Instruction Next {
-                       get { return next; }
-                       set { next = value; }
-               }
-
-               public SequencePoint SequencePoint {
-                       get { return sequence_point; }
-                       set { sequence_point = value; }
-               }
-
-               internal Instruction (int offset, OpCode opCode)
-               {
-                       this.offset = offset;
-                       this.opcode = opCode;
-               }
-
-               internal Instruction (OpCode opcode, object operand)
-               {
-                       this.opcode = opcode;
-                       this.operand = operand;
-               }
-
-               public int GetSize ()
-               {
-                       int size = opcode.Size;
-
-                       switch (opcode.OperandType) {
-                       case OperandType.InlineSwitch:
-                               return size + (1 + ((Instruction []) operand).Length) * 4;
-                       case OperandType.InlineI8:
-                       case OperandType.InlineR:
-                               return size + 8;
-                       case OperandType.InlineBrTarget:
-                       case OperandType.InlineField:
-                       case OperandType.InlineI:
-                       case OperandType.InlineMethod:
-                       case OperandType.InlineString:
-                       case OperandType.InlineTok:
-                       case OperandType.InlineType:
-                       case OperandType.ShortInlineR:
-                       case OperandType.InlineSig:
-                               return size + 4;
-                       case OperandType.InlineArg:
-                       case OperandType.InlineVar:
-                               return size + 2;
-                       case OperandType.ShortInlineBrTarget:
-                       case OperandType.ShortInlineI:
-                       case OperandType.ShortInlineArg:
-                       case OperandType.ShortInlineVar:
-                               return size + 1;
-                       default:
-                               return size;
-                       }
-               }
-
-               public override string ToString ()
-               {
-                       var instruction = new StringBuilder ();
-
-                       AppendLabel (instruction, this);
-                       instruction.Append (':');
-                       instruction.Append (' ');
-                       instruction.Append (opcode.Name);
-
-                       if (operand == null)
-                               return instruction.ToString ();
-
-                       instruction.Append (' ');
-
-                       switch (opcode.OperandType) {
-                       case OperandType.ShortInlineBrTarget:
-                       case OperandType.InlineBrTarget:
-                               AppendLabel (instruction, (Instruction) operand);
-                               break;
-                       case OperandType.InlineSwitch:
-                               var labels = (Instruction []) operand;
-                               for (int i = 0; i < labels.Length; i++) {
-                                       if (i > 0)
-                                               instruction.Append (',');
-
-                                       AppendLabel (instruction, labels [i]);
-                               }
-                               break;
-                       case OperandType.InlineString:
-                               instruction.Append ('\"');
-                               instruction.Append (operand);
-                               instruction.Append ('\"');
-                               break;
-                       default:
-                               instruction.Append (operand);
-                               break;
-                       }
-
-                       return instruction.ToString ();
-               }
-
-               static void AppendLabel (StringBuilder builder, Instruction instruction)
-               {
-                       builder.Append ("IL_");
-                       builder.Append (instruction.offset.ToString ("x4"));
-               }
-
-               public static Instruction Create (OpCode opcode)
-               {
-                       if (opcode.OperandType != OperandType.InlineNone)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, null);
-               }
-
-               public static Instruction Create (OpCode opcode, TypeReference type)
-               {
-                       if (type == null)
-                               throw new ArgumentNullException ("type");
-                       if (opcode.OperandType != OperandType.InlineType &&
-                               opcode.OperandType != OperandType.InlineTok)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, type);
-               }
-
-               public static Instruction Create (OpCode opcode, CallSite site)
-               {
-                       if (site == null)
-                               throw new ArgumentNullException ("site");
-                       if (opcode.Code != Code.Calli)
-                               throw new ArgumentException ("code");
-
-                       return new Instruction (opcode, site);
-               }
-
-               public static Instruction Create (OpCode opcode, MethodReference method)
-               {
-                       if (method == null)
-                               throw new ArgumentNullException ("method");
-                       if (opcode.OperandType != OperandType.InlineMethod &&
-                               opcode.OperandType != OperandType.InlineTok)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, method);
-               }
-
-               public static Instruction Create (OpCode opcode, FieldReference field)
-               {
-                       if (field == null)
-                               throw new ArgumentNullException ("field");
-                       if (opcode.OperandType != OperandType.InlineField &&
-                               opcode.OperandType != OperandType.InlineTok)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, field);
-               }
-
-               public static Instruction Create (OpCode opcode, string value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       if (opcode.OperandType != OperandType.InlineString)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, value);
-               }
-
-               public static Instruction Create (OpCode opcode, sbyte value)
-               {
-                       if (opcode.OperandType != OperandType.ShortInlineI &&
-                               opcode != OpCodes.Ldc_I4_S)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, value);
-               }
-
-               public static Instruction Create (OpCode opcode, byte value)
-               {
-                       if (opcode.OperandType != OperandType.ShortInlineI ||
-                               opcode == OpCodes.Ldc_I4_S)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, value);
-               }
-
-               public static Instruction Create (OpCode opcode, int value)
-               {
-                       if (opcode.OperandType != OperandType.InlineI)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, value);
-               }
-
-               public static Instruction Create (OpCode opcode, long value)
-               {
-                       if (opcode.OperandType != OperandType.InlineI8)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, value);
-               }
-
-               public static Instruction Create (OpCode opcode, float value)
-               {
-                       if (opcode.OperandType != OperandType.ShortInlineR)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, value);
-               }
-
-               public static Instruction Create (OpCode opcode, double value)
-               {
-                       if (opcode.OperandType != OperandType.InlineR)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, value);
-               }
-
-               public static Instruction Create (OpCode opcode, Instruction target)
-               {
-                       if (target == null)
-                               throw new ArgumentNullException ("target");
-                       if (opcode.OperandType != OperandType.InlineBrTarget &&
-                               opcode.OperandType != OperandType.ShortInlineBrTarget)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, target);
-               }
-
-               public static Instruction Create (OpCode opcode, Instruction [] targets)
-               {
-                       if (targets == null)
-                               throw new ArgumentNullException ("targets");
-                       if (opcode.OperandType != OperandType.InlineSwitch)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, targets);
-               }
-
-               public static Instruction Create (OpCode opcode, VariableDefinition variable)
-               {
-                       if (variable == null)
-                               throw new ArgumentNullException ("variable");
-                       if (opcode.OperandType != OperandType.ShortInlineVar &&
-                               opcode.OperandType != OperandType.InlineVar)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, variable);
-               }
-
-               public static Instruction Create (OpCode opcode, ParameterDefinition parameter)
-               {
-                       if (parameter == null)
-                               throw new ArgumentNullException ("parameter");
-                       if (opcode.OperandType != OperandType.ShortInlineArg &&
-                               opcode.OperandType != OperandType.InlineArg)
-                               throw new ArgumentException ("opcode");
-
-                       return new Instruction (opcode, parameter);
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/MethodBody.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/MethodBody.cs
deleted file mode 100644 (file)
index 4ae749b..0000000
+++ /dev/null
@@ -1,230 +0,0 @@
-//
-// MethodBody.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil.Cil {
-
-       public sealed class MethodBody : IVariableDefinitionProvider {
-
-               readonly internal MethodDefinition method;
-
-               internal ParameterDefinition this_parameter;
-               internal int max_stack_size;
-               internal int code_size;
-               internal bool init_locals;
-               internal MetadataToken local_var_token;
-
-               internal Collection<Instruction> instructions;
-               internal Collection<ExceptionHandler> exceptions;
-               internal Collection<VariableDefinition> variables;
-               Scope scope;
-
-               public MethodDefinition Method {
-                       get { return method; }
-               }
-
-               public int MaxStackSize {
-                       get { return max_stack_size; }
-                       set { max_stack_size = value; }
-               }
-
-               public int CodeSize {
-                       get { return code_size; }
-               }
-
-               public bool InitLocals {
-                       get { return init_locals; }
-                       set { init_locals = value; }
-               }
-
-               public MetadataToken LocalVarToken {
-                       get { return local_var_token; }
-                       set { local_var_token = value; }
-               }
-
-               public Collection<Instruction> Instructions {
-                       get { return instructions ?? (instructions = new InstructionCollection ()); }
-               }
-
-               public bool HasExceptionHandlers {
-                       get { return !exceptions.IsNullOrEmpty (); }
-               }
-
-               public Collection<ExceptionHandler> ExceptionHandlers {
-                       get { return exceptions ?? (exceptions = new Collection<ExceptionHandler> ()); }
-               }
-
-               public bool HasVariables {
-                       get { return !variables.IsNullOrEmpty (); }
-               }
-
-               public Collection<VariableDefinition> Variables {
-                       get { return variables ?? (variables = new VariableDefinitionCollection ()); }
-               }
-
-               public Scope Scope {
-                       get { return scope; }
-                       set { scope = value; }
-               }
-
-               public ParameterDefinition ThisParameter {
-                       get {
-                               if (method == null || method.DeclaringType == null)
-                                       throw new NotSupportedException ();
-
-                               return this_parameter ?? (this_parameter = new ParameterDefinition ("0", ParameterAttributes.None, method.DeclaringType));
-                       }
-               }
-
-               public MethodBody (MethodDefinition method)
-               {
-                       this.method = method;
-               }
-
-               public ILProcessor GetILProcessor ()
-               {
-                       return new ILProcessor (this);
-               }
-       }
-
-       public interface IVariableDefinitionProvider {
-               bool HasVariables { get; }
-               Collection<VariableDefinition> Variables { get; }
-       }
-
-       class VariableDefinitionCollection : Collection<VariableDefinition> {
-
-               internal VariableDefinitionCollection ()
-               {
-               }
-
-               internal VariableDefinitionCollection (int capacity)
-                       : base (capacity)
-               {
-               }
-
-               protected override void OnAdd (VariableDefinition item, int index)
-               {
-                       item.index = index;
-               }
-
-               protected override void OnInsert (VariableDefinition item, int index)
-               {
-                       item.index = index;
-
-                       for (int i = index; i < size; i++)
-                               items [i].index = i + 1;
-               }
-
-               protected override void OnSet (VariableDefinition item, int index)
-               {
-                       item.index = index;
-               }
-
-               protected override void OnRemove (VariableDefinition item, int index)
-               {
-                       item.index = -1;
-
-                       for (int i = index + 1; i < size; i++)
-                               items [i].index = i - 1;
-               }
-       }
-
-       class InstructionCollection : Collection<Instruction> {
-
-               internal InstructionCollection ()
-               {
-               }
-
-               internal InstructionCollection (int capacity)
-                       : base (capacity)
-               {
-               }
-
-               protected override void OnAdd (Instruction item, int index)
-               {
-                       if (index == 0)
-                               return;
-
-                       var previous = items [index - 1];
-                       previous.next = item;
-                       item.previous = previous;
-               }
-
-               protected override void OnInsert (Instruction item, int index)
-               {
-                       if (size == 0)
-                               return;
-
-                       var current = items [index];
-                       if (current == null) {
-                               var last = items [index - 1];
-                               last.next = item;
-                               item.previous = last;
-                               return;
-                       }
-
-                       var previous = current.previous;
-                       if (previous != null) {
-                               previous.next = item;
-                               item.previous = previous;
-                       }
-
-                       current.previous = item;
-                       item.next = current;
-               }
-
-               protected override void OnSet (Instruction item, int index)
-               {
-                       var current = items [index];
-
-                       item.previous = current.previous;
-                       item.next = current.next;
-
-                       current.previous = null;
-                       current.next = null;
-               }
-
-               protected override void OnRemove (Instruction item, int index)
-               {
-                       var previous = item.previous;
-                       if (previous != null)
-                               previous.next = item.next;
-
-                       var next = item.next;
-                       if (next != null)
-                               next.previous = item.previous;
-
-                       item.previous = null;
-                       item.next = null;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/OpCode.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/OpCode.cs
deleted file mode 100644 (file)
index 1a14421..0000000
+++ /dev/null
@@ -1,455 +0,0 @@
-//
-// OpCode.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil.Cil {
-
-       public enum FlowControl {
-               Branch,
-               Break,
-               Call,
-               Cond_Branch,
-               Meta,
-               Next,
-               Phi,
-               Return,
-               Throw,
-       }
-
-       public enum OpCodeType {
-               Annotation,
-               Macro,
-               Nternal,
-               Objmodel,
-               Prefix,
-               Primitive,
-       }
-
-       public enum OperandType {
-               InlineBrTarget,
-               InlineField,
-               InlineI,
-               InlineI8,
-               InlineMethod,
-               InlineNone,
-               InlinePhi,
-               InlineR,
-               InlineSig,
-               InlineString,
-               InlineSwitch,
-               InlineTok,
-               InlineType,
-               InlineVar,
-               InlineArg,
-               ShortInlineBrTarget,
-               ShortInlineI,
-               ShortInlineR,
-               ShortInlineVar,
-               ShortInlineArg,
-       }
-
-       public enum StackBehaviour {
-               Pop0,
-               Pop1,
-               Pop1_pop1,
-               Popi,
-               Popi_pop1,
-               Popi_popi,
-               Popi_popi8,
-               Popi_popi_popi,
-               Popi_popr4,
-               Popi_popr8,
-               Popref,
-               Popref_pop1,
-               Popref_popi,
-               Popref_popi_popi,
-               Popref_popi_popi8,
-               Popref_popi_popr4,
-               Popref_popi_popr8,
-               Popref_popi_popref,
-               PopAll,
-               Push0,
-               Push1,
-               Push1_push1,
-               Pushi,
-               Pushi8,
-               Pushr4,
-               Pushr8,
-               Pushref,
-               Varpop,
-               Varpush,
-       }
-
-       public struct OpCode {
-
-               readonly byte op1;
-               readonly byte op2;
-               readonly byte code;
-               readonly byte flow_control;
-               readonly byte opcode_type;
-               readonly byte operand_type;
-               readonly byte stack_behavior_pop;
-               readonly byte stack_behavior_push;
-
-               public string Name {
-                       get { return OpCodeNames.names [(int) Code]; }
-               }
-
-               public int Size {
-                       get { return op1 == 0xff ? 1 : 2; }
-               }
-
-               public byte Op1 {
-                       get { return op1; }
-               }
-
-               public byte Op2 {
-                       get { return op2; }
-               }
-
-               public short Value {
-                       get { return op1 == 0xff ? op2 : (short) ((op1 << 8) | op2); }
-               }
-
-               public Code Code {
-                       get { return (Code) code; }
-               }
-
-               public FlowControl FlowControl {
-                       get { return (FlowControl) flow_control; }
-               }
-
-               public OpCodeType OpCodeType {
-                       get { return (OpCodeType) opcode_type; }
-               }
-
-               public OperandType OperandType {
-                       get { return (OperandType) operand_type; }
-               }
-
-               public StackBehaviour StackBehaviourPop {
-                       get { return (StackBehaviour) stack_behavior_pop; }
-               }
-
-               public StackBehaviour StackBehaviourPush {
-                       get { return (StackBehaviour) stack_behavior_push; }
-               }
-
-               internal OpCode (int x, int y)
-               {
-                       this.op1 = (byte) ((x >> 0) & 0xff);
-                       this.op2 = (byte) ((x >> 8) & 0xff);
-                       this.code = (byte) ((x >> 16) & 0xff);
-                       this.flow_control = (byte) ((x >> 24) & 0xff);
-
-                       this.opcode_type = (byte) ((y >> 0) & 0xff);
-                       this.operand_type = (byte) ((y >> 8) & 0xff);
-                       this.stack_behavior_pop = (byte) ((y >> 16) & 0xff);
-                       this.stack_behavior_push = (byte) ((y >> 24) & 0xff);
-
-                       if (op1 == 0xff)
-                               OpCodes.OneByteOpCode [op2] = this;
-                       else
-                               OpCodes.TwoBytesOpCode [op2] = this;
-               }
-
-               public override int GetHashCode ()
-               {
-                       return Value;
-               }
-
-               public override bool Equals (object obj)
-               {
-                       if (!(obj is OpCode))
-                               return false;
-
-                       var opcode = (OpCode) obj;
-                       return op1 == opcode.op1 && op2 == opcode.op2;
-               }
-
-               public bool Equals (OpCode opcode)
-               {
-                       return op1 == opcode.op1 && op2 == opcode.op2;
-               }
-
-               public static bool operator == (OpCode one, OpCode other)
-               {
-                       return one.op1 == other.op1 && one.op2 == other.op2;
-               }
-
-               public static bool operator != (OpCode one, OpCode other)
-               {
-                       return one.op1 != other.op1 || one.op2 != other.op2;
-               }
-
-               public override string ToString ()
-               {
-                       return Name;
-               }
-       }
-
-       static class OpCodeNames {
-
-               internal static readonly string [] names;
-
-               static OpCodeNames ()
-               {
-                       var table = new byte [] {
-                               3, 110, 111, 112,
-                               5, 98, 114, 101, 97, 107,
-                               7, 108, 100, 97, 114, 103, 46, 48,
-                               7, 108, 100, 97, 114, 103, 46, 49,
-                               7, 108, 100, 97, 114, 103, 46, 50,
-                               7, 108, 100, 97, 114, 103, 46, 51,
-                               7, 108, 100, 108, 111, 99, 46, 48,
-                               7, 108, 100, 108, 111, 99, 46, 49,
-                               7, 108, 100, 108, 111, 99, 46, 50,
-                               7, 108, 100, 108, 111, 99, 46, 51,
-                               7, 115, 116, 108, 111, 99, 46, 48,
-                               7, 115, 116, 108, 111, 99, 46, 49,
-                               7, 115, 116, 108, 111, 99, 46, 50,
-                               7, 115, 116, 108, 111, 99, 46, 51,
-                               7, 108, 100, 97, 114, 103, 46, 115,
-                               8, 108, 100, 97, 114, 103, 97, 46, 115,
-                               7, 115, 116, 97, 114, 103, 46, 115,
-                               7, 108, 100, 108, 111, 99, 46, 115,
-                               8, 108, 100, 108, 111, 99, 97, 46, 115,
-                               7, 115, 116, 108, 111, 99, 46, 115,
-                               6, 108, 100, 110, 117, 108, 108,
-                               9, 108, 100, 99, 46, 105, 52, 46, 109, 49,
-                               8, 108, 100, 99, 46, 105, 52, 46, 48,
-                               8, 108, 100, 99, 46, 105, 52, 46, 49,
-                               8, 108, 100, 99, 46, 105, 52, 46, 50,
-                               8, 108, 100, 99, 46, 105, 52, 46, 51,
-                               8, 108, 100, 99, 46, 105, 52, 46, 52,
-                               8, 108, 100, 99, 46, 105, 52, 46, 53,
-                               8, 108, 100, 99, 46, 105, 52, 46, 54,
-                               8, 108, 100, 99, 46, 105, 52, 46, 55,
-                               8, 108, 100, 99, 46, 105, 52, 46, 56,
-                               8, 108, 100, 99, 46, 105, 52, 46, 115,
-                               6, 108, 100, 99, 46, 105, 52,
-                               6, 108, 100, 99, 46, 105, 56,
-                               6, 108, 100, 99, 46, 114, 52,
-                               6, 108, 100, 99, 46, 114, 56,
-                               3, 100, 117, 112,
-                               3, 112, 111, 112,
-                               3, 106, 109, 112,
-                               4, 99, 97, 108, 108,
-                               5, 99, 97, 108, 108, 105,
-                               3, 114, 101, 116,
-                               4, 98, 114, 46, 115,
-                               9, 98, 114, 102, 97, 108, 115, 101, 46, 115,
-                               8, 98, 114, 116, 114, 117, 101, 46, 115,
-                               5, 98, 101, 113, 46, 115,
-                               5, 98, 103, 101, 46, 115,
-                               5, 98, 103, 116, 46, 115,
-                               5, 98, 108, 101, 46, 115,
-                               5, 98, 108, 116, 46, 115,
-                               8, 98, 110, 101, 46, 117, 110, 46, 115,
-                               8, 98, 103, 101, 46, 117, 110, 46, 115,
-                               8, 98, 103, 116, 46, 117, 110, 46, 115,
-                               8, 98, 108, 101, 46, 117, 110, 46, 115,
-                               8, 98, 108, 116, 46, 117, 110, 46, 115,
-                               2, 98, 114,
-                               7, 98, 114, 102, 97, 108, 115, 101,
-                               6, 98, 114, 116, 114, 117, 101,
-                               3, 98, 101, 113,
-                               3, 98, 103, 101,
-                               3, 98, 103, 116,
-                               3, 98, 108, 101,
-                               3, 98, 108, 116,
-                               6, 98, 110, 101, 46, 117, 110,
-                               6, 98, 103, 101, 46, 117, 110,
-                               6, 98, 103, 116, 46, 117, 110,
-                               6, 98, 108, 101, 46, 117, 110,
-                               6, 98, 108, 116, 46, 117, 110,
-                               6, 115, 119, 105, 116, 99, 104,
-                               8, 108, 100, 105, 110, 100, 46, 105, 49,
-                               8, 108, 100, 105, 110, 100, 46, 117, 49,
-                               8, 108, 100, 105, 110, 100, 46, 105, 50,
-                               8, 108, 100, 105, 110, 100, 46, 117, 50,
-                               8, 108, 100, 105, 110, 100, 46, 105, 52,
-                               8, 108, 100, 105, 110, 100, 46, 117, 52,
-                               8, 108, 100, 105, 110, 100, 46, 105, 56,
-                               7, 108, 100, 105, 110, 100, 46, 105,
-                               8, 108, 100, 105, 110, 100, 46, 114, 52,
-                               8, 108, 100, 105, 110, 100, 46, 114, 56,
-                               9, 108, 100, 105, 110, 100, 46, 114, 101, 102,
-                               9, 115, 116, 105, 110, 100, 46, 114, 101, 102,
-                               8, 115, 116, 105, 110, 100, 46, 105, 49,
-                               8, 115, 116, 105, 110, 100, 46, 105, 50,
-                               8, 115, 116, 105, 110, 100, 46, 105, 52,
-                               8, 115, 116, 105, 110, 100, 46, 105, 56,
-                               8, 115, 116, 105, 110, 100, 46, 114, 52,
-                               8, 115, 116, 105, 110, 100, 46, 114, 56,
-                               3, 97, 100, 100,
-                               3, 115, 117, 98,
-                               3, 109, 117, 108,
-                               3, 100, 105, 118,
-                               6, 100, 105, 118, 46, 117, 110,
-                               3, 114, 101, 109,
-                               6, 114, 101, 109, 46, 117, 110,
-                               3, 97, 110, 100,
-                               2, 111, 114,
-                               3, 120, 111, 114,
-                               3, 115, 104, 108,
-                               3, 115, 104, 114,
-                               6, 115, 104, 114, 46, 117, 110,
-                               3, 110, 101, 103,
-                               3, 110, 111, 116,
-                               7, 99, 111, 110, 118, 46, 105, 49,
-                               7, 99, 111, 110, 118, 46, 105, 50,
-                               7, 99, 111, 110, 118, 46, 105, 52,
-                               7, 99, 111, 110, 118, 46, 105, 56,
-                               7, 99, 111, 110, 118, 46, 114, 52,
-                               7, 99, 111, 110, 118, 46, 114, 56,
-                               7, 99, 111, 110, 118, 46, 117, 52,
-                               7, 99, 111, 110, 118, 46, 117, 56,
-                               8, 99, 97, 108, 108, 118, 105, 114, 116,
-                               5, 99, 112, 111, 98, 106,
-                               5, 108, 100, 111, 98, 106,
-                               5, 108, 100, 115, 116, 114,
-                               6, 110, 101, 119, 111, 98, 106,
-                               9, 99, 97, 115, 116, 99, 108, 97, 115, 115,
-                               6, 105, 115, 105, 110, 115, 116,
-                               9, 99, 111, 110, 118, 46, 114, 46, 117, 110,
-                               5, 117, 110, 98, 111, 120,
-                               5, 116, 104, 114, 111, 119,
-                               5, 108, 100, 102, 108, 100,
-                               6, 108, 100, 102, 108, 100, 97,
-                               5, 115, 116, 102, 108, 100,
-                               6, 108, 100, 115, 102, 108, 100,
-                               7, 108, 100, 115, 102, 108, 100, 97,
-                               6, 115, 116, 115, 102, 108, 100,
-                               5, 115, 116, 111, 98, 106,
-                               14, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105, 49, 46, 117, 110,
-                               14, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105, 50, 46, 117, 110,
-                               14, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105, 52, 46, 117, 110,
-                               14, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105, 56, 46, 117, 110,
-                               14, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117, 49, 46, 117, 110,
-                               14, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117, 50, 46, 117, 110,
-                               14, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117, 52, 46, 117, 110,
-                               14, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117, 56, 46, 117, 110,
-                               13, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105, 46, 117, 110,
-                               13, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117, 46, 117, 110,
-                               3, 98, 111, 120,
-                               6, 110, 101, 119, 97, 114, 114,
-                               5, 108, 100, 108, 101, 110,
-                               7, 108, 100, 101, 108, 101, 109, 97,
-                               9, 108, 100, 101, 108, 101, 109, 46, 105, 49,
-                               9, 108, 100, 101, 108, 101, 109, 46, 117, 49,
-                               9, 108, 100, 101, 108, 101, 109, 46, 105, 50,
-                               9, 108, 100, 101, 108, 101, 109, 46, 117, 50,
-                               9, 108, 100, 101, 108, 101, 109, 46, 105, 52,
-                               9, 108, 100, 101, 108, 101, 109, 46, 117, 52,
-                               9, 108, 100, 101, 108, 101, 109, 46, 105, 56,
-                               8, 108, 100, 101, 108, 101, 109, 46, 105,
-                               9, 108, 100, 101, 108, 101, 109, 46, 114, 52,
-                               9, 108, 100, 101, 108, 101, 109, 46, 114, 56,
-                               10, 108, 100, 101, 108, 101, 109, 46, 114, 101, 102,
-                               8, 115, 116, 101, 108, 101, 109, 46, 105,
-                               9, 115, 116, 101, 108, 101, 109, 46, 105, 49,
-                               9, 115, 116, 101, 108, 101, 109, 46, 105, 50,
-                               9, 115, 116, 101, 108, 101, 109, 46, 105, 52,
-                               9, 115, 116, 101, 108, 101, 109, 46, 105, 56,
-                               9, 115, 116, 101, 108, 101, 109, 46, 114, 52,
-                               9, 115, 116, 101, 108, 101, 109, 46, 114, 56,
-                               10, 115, 116, 101, 108, 101, 109, 46, 114, 101, 102,
-                               10, 108, 100, 101, 108, 101, 109, 46, 97, 110, 121,
-                               10, 115, 116, 101, 108, 101, 109, 46, 97, 110, 121,
-                               9, 117, 110, 98, 111, 120, 46, 97, 110, 121,
-                               11, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105, 49,
-                               11, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117, 49,
-                               11, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105, 50,
-                               11, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117, 50,
-                               11, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105, 52,
-                               11, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117, 52,
-                               11, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105, 56,
-                               11, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117, 56,
-                               9, 114, 101, 102, 97, 110, 121, 118, 97, 108,
-                               8, 99, 107, 102, 105, 110, 105, 116, 101,
-                               8, 109, 107, 114, 101, 102, 97, 110, 121,
-                               7, 108, 100, 116, 111, 107, 101, 110,
-                               7, 99, 111, 110, 118, 46, 117, 50,
-                               7, 99, 111, 110, 118, 46, 117, 49,
-                               6, 99, 111, 110, 118, 46, 105,
-                               10, 99, 111, 110, 118, 46, 111, 118, 102, 46, 105,
-                               10, 99, 111, 110, 118, 46, 111, 118, 102, 46, 117,
-                               7, 97, 100, 100, 46, 111, 118, 102,
-                               10, 97, 100, 100, 46, 111, 118, 102, 46, 117, 110,
-                               7, 109, 117, 108, 46, 111, 118, 102,
-                               10, 109, 117, 108, 46, 111, 118, 102, 46, 117, 110,
-                               7, 115, 117, 98, 46, 111, 118, 102,
-                               10, 115, 117, 98, 46, 111, 118, 102, 46, 117, 110,
-                               10, 101, 110, 100, 102, 105, 110, 97, 108, 108, 121,
-                               5, 108, 101, 97, 118, 101,
-                               7, 108, 101, 97, 118, 101, 46, 115,
-                               7, 115, 116, 105, 110, 100, 46, 105,
-                               6, 99, 111, 110, 118, 46, 117,
-                               7, 97, 114, 103, 108, 105, 115, 116,
-                               3, 99, 101, 113,
-                               3, 99, 103, 116,
-                               6, 99, 103, 116, 46, 117, 110,
-                               3, 99, 108, 116,
-                               6, 99, 108, 116, 46, 117, 110,
-                               5, 108, 100, 102, 116, 110,
-                               9, 108, 100, 118, 105, 114, 116, 102, 116, 110,
-                               5, 108, 100, 97, 114, 103,
-                               6, 108, 100, 97, 114, 103, 97,
-                               5, 115, 116, 97, 114, 103,
-                               5, 108, 100, 108, 111, 99,
-                               6, 108, 100, 108, 111, 99, 97,
-                               5, 115, 116, 108, 111, 99,
-                               8, 108, 111, 99, 97, 108, 108, 111, 99,
-                               9, 101, 110, 100, 102, 105, 108, 116, 101, 114,
-                               10, 117, 110, 97, 108, 105, 103, 110, 101, 100, 46,
-                               9, 118, 111, 108, 97, 116, 105, 108, 101, 46,
-                               5, 116, 97, 105, 108, 46,
-                               7, 105, 110, 105, 116, 111, 98, 106,
-                               12, 99, 111, 110, 115, 116, 114, 97, 105, 110, 101, 100, 46,
-                               5, 99, 112, 98, 108, 107,
-                               7, 105, 110, 105, 116, 98, 108, 107,
-                               3, 110, 111, 46,
-                               7, 114, 101, 116, 104, 114, 111, 119,
-                               6, 115, 105, 122, 101, 111, 102,
-                               10, 114, 101, 102, 97, 110, 121, 116, 121, 112, 101,
-                               9, 114, 101, 97, 100, 111, 110, 108, 121, 46,
-                       };
-
-                       names = new string [219];
-
-                       for (int i = 0, p = 0; i < names.Length; i++) {
-                               var buffer = new char [table [p++]];
-
-                               for (int j = 0; j < buffer.Length; j++)
-                                       buffer [j] = (char) table [p++];
-
-                               names [i] = new string (buffer);
-                       }
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/OpCodes.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/OpCodes.cs
deleted file mode 100644 (file)
index 85712ec..0000000
+++ /dev/null
@@ -1,912 +0,0 @@
-//
-// OpCodes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil.Cil {
-
-       public static class OpCodes {
-
-               internal static readonly OpCode [] OneByteOpCode = new OpCode [0xe0 + 1];
-               internal static readonly OpCode [] TwoBytesOpCode = new OpCode [0x1e + 1];
-
-               public static readonly OpCode Nop = new OpCode (
-                       0xff << 0 | 0x00 << 8 | (byte) Code.Nop << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Break = new OpCode (
-                       0xff << 0 | 0x01 << 8 | (byte) Code.Break << 16 | (byte) FlowControl.Break << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldarg_0 = new OpCode (
-                       0xff << 0 | 0x02 << 8 | (byte) Code.Ldarg_0 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldarg_1 = new OpCode (
-                       0xff << 0 | 0x03 << 8 | (byte) Code.Ldarg_1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldarg_2 = new OpCode (
-                       0xff << 0 | 0x04 << 8 | (byte) Code.Ldarg_2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldarg_3 = new OpCode (
-                       0xff << 0 | 0x05 << 8 | (byte) Code.Ldarg_3 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldloc_0 = new OpCode (
-                       0xff << 0 | 0x06 << 8 | (byte) Code.Ldloc_0 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldloc_1 = new OpCode (
-                       0xff << 0 | 0x07 << 8 | (byte) Code.Ldloc_1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldloc_2 = new OpCode (
-                       0xff << 0 | 0x08 << 8 | (byte) Code.Ldloc_2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldloc_3 = new OpCode (
-                       0xff << 0 | 0x09 << 8 | (byte) Code.Ldloc_3 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Stloc_0 = new OpCode (
-                       0xff << 0 | 0x0a << 8 | (byte) Code.Stloc_0 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stloc_1 = new OpCode (
-                       0xff << 0 | 0x0b << 8 | (byte) Code.Stloc_1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stloc_2 = new OpCode (
-                       0xff << 0 | 0x0c << 8 | (byte) Code.Stloc_2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stloc_3 = new OpCode (
-                       0xff << 0 | 0x0d << 8 | (byte) Code.Stloc_3 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldarg_S = new OpCode (
-                       0xff << 0 | 0x0e << 8 | (byte) Code.Ldarg_S << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineArg << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldarga_S = new OpCode (
-                       0xff << 0 | 0x0f << 8 | (byte) Code.Ldarga_S << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineArg << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Starg_S = new OpCode (
-                       0xff << 0 | 0x10 << 8 | (byte) Code.Starg_S << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineArg << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldloc_S = new OpCode (
-                       0xff << 0 | 0x11 << 8 | (byte) Code.Ldloc_S << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineVar << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldloca_S = new OpCode (
-                       0xff << 0 | 0x12 << 8 | (byte) Code.Ldloca_S << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineVar << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Stloc_S = new OpCode (
-                       0xff << 0 | 0x13 << 8 | (byte) Code.Stloc_S << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineVar << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldnull = new OpCode (
-                       0xff << 0 | 0x14 << 8 | (byte) Code.Ldnull << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushref << 24);
-
-               public static readonly OpCode Ldc_I4_M1 = new OpCode (
-                       0xff << 0 | 0x15 << 8 | (byte) Code.Ldc_I4_M1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_0 = new OpCode (
-                       0xff << 0 | 0x16 << 8 | (byte) Code.Ldc_I4_0 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_1 = new OpCode (
-                       0xff << 0 | 0x17 << 8 | (byte) Code.Ldc_I4_1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_2 = new OpCode (
-                       0xff << 0 | 0x18 << 8 | (byte) Code.Ldc_I4_2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_3 = new OpCode (
-                       0xff << 0 | 0x19 << 8 | (byte) Code.Ldc_I4_3 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_4 = new OpCode (
-                       0xff << 0 | 0x1a << 8 | (byte) Code.Ldc_I4_4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_5 = new OpCode (
-                       0xff << 0 | 0x1b << 8 | (byte) Code.Ldc_I4_5 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_6 = new OpCode (
-                       0xff << 0 | 0x1c << 8 | (byte) Code.Ldc_I4_6 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_7 = new OpCode (
-                       0xff << 0 | 0x1d << 8 | (byte) Code.Ldc_I4_7 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_8 = new OpCode (
-                       0xff << 0 | 0x1e << 8 | (byte) Code.Ldc_I4_8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4_S = new OpCode (
-                       0xff << 0 | 0x1f << 8 | (byte) Code.Ldc_I4_S << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineI << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I4 = new OpCode (
-                       0xff << 0 | 0x20 << 8 | (byte) Code.Ldc_I4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineI << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldc_I8 = new OpCode (
-                       0xff << 0 | 0x21 << 8 | (byte) Code.Ldc_I8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineI8 << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi8 << 24);
-
-               public static readonly OpCode Ldc_R4 = new OpCode (
-                       0xff << 0 | 0x22 << 8 | (byte) Code.Ldc_R4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.ShortInlineR << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushr4 << 24);
-
-               public static readonly OpCode Ldc_R8 = new OpCode (
-                       0xff << 0 | 0x23 << 8 | (byte) Code.Ldc_R8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineR << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushr8 << 24);
-
-               public static readonly OpCode Dup = new OpCode (
-                       0xff << 0 | 0x25 << 8 | (byte) Code.Dup << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push1_push1 << 24);
-
-               public static readonly OpCode Pop = new OpCode (
-                       0xff << 0 | 0x26 << 8 | (byte) Code.Pop << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Jmp = new OpCode (
-                       0xff << 0 | 0x27 << 8 | (byte) Code.Jmp << 16 | (byte) FlowControl.Call << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineMethod << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Call = new OpCode (
-                       0xff << 0 | 0x28 << 8 | (byte) Code.Call << 16 | (byte) FlowControl.Call << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineMethod << 8 | (byte) StackBehaviour.Varpop << 16 | (byte) StackBehaviour.Varpush << 24);
-
-               public static readonly OpCode Calli = new OpCode (
-                       0xff << 0 | 0x29 << 8 | (byte) Code.Calli << 16 | (byte) FlowControl.Call << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineSig << 8 | (byte) StackBehaviour.Varpop << 16 | (byte) StackBehaviour.Varpush << 24);
-
-               public static readonly OpCode Ret = new OpCode (
-                       0xff << 0 | 0x2a << 8 | (byte) Code.Ret << 16 | (byte) FlowControl.Return << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Varpop << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Br_S = new OpCode (
-                       0xff << 0 | 0x2b << 8 | (byte) Code.Br_S << 16 | (byte) FlowControl.Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Brfalse_S = new OpCode (
-                       0xff << 0 | 0x2c << 8 | (byte) Code.Brfalse_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Brtrue_S = new OpCode (
-                       0xff << 0 | 0x2d << 8 | (byte) Code.Brtrue_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Beq_S = new OpCode (
-                       0xff << 0 | 0x2e << 8 | (byte) Code.Beq_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bge_S = new OpCode (
-                       0xff << 0 | 0x2f << 8 | (byte) Code.Bge_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bgt_S = new OpCode (
-                       0xff << 0 | 0x30 << 8 | (byte) Code.Bgt_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ble_S = new OpCode (
-                       0xff << 0 | 0x31 << 8 | (byte) Code.Ble_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Blt_S = new OpCode (
-                       0xff << 0 | 0x32 << 8 | (byte) Code.Blt_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bne_Un_S = new OpCode (
-                       0xff << 0 | 0x33 << 8 | (byte) Code.Bne_Un_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bge_Un_S = new OpCode (
-                       0xff << 0 | 0x34 << 8 | (byte) Code.Bge_Un_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bgt_Un_S = new OpCode (
-                       0xff << 0 | 0x35 << 8 | (byte) Code.Bgt_Un_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ble_Un_S = new OpCode (
-                       0xff << 0 | 0x36 << 8 | (byte) Code.Ble_Un_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Blt_Un_S = new OpCode (
-                       0xff << 0 | 0x37 << 8 | (byte) Code.Blt_Un_S << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Br = new OpCode (
-                       0xff << 0 | 0x38 << 8 | (byte) Code.Br << 16 | (byte) FlowControl.Branch << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Brfalse = new OpCode (
-                       0xff << 0 | 0x39 << 8 | (byte) Code.Brfalse << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Brtrue = new OpCode (
-                       0xff << 0 | 0x3a << 8 | (byte) Code.Brtrue << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Beq = new OpCode (
-                       0xff << 0 | 0x3b << 8 | (byte) Code.Beq << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bge = new OpCode (
-                       0xff << 0 | 0x3c << 8 | (byte) Code.Bge << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bgt = new OpCode (
-                       0xff << 0 | 0x3d << 8 | (byte) Code.Bgt << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ble = new OpCode (
-                       0xff << 0 | 0x3e << 8 | (byte) Code.Ble << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Blt = new OpCode (
-                       0xff << 0 | 0x3f << 8 | (byte) Code.Blt << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bne_Un = new OpCode (
-                       0xff << 0 | 0x40 << 8 | (byte) Code.Bne_Un << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bge_Un = new OpCode (
-                       0xff << 0 | 0x41 << 8 | (byte) Code.Bge_Un << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Bgt_Un = new OpCode (
-                       0xff << 0 | 0x42 << 8 | (byte) Code.Bgt_Un << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ble_Un = new OpCode (
-                       0xff << 0 | 0x43 << 8 | (byte) Code.Ble_Un << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Blt_Un = new OpCode (
-                       0xff << 0 | 0x44 << 8 | (byte) Code.Blt_Un << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Switch = new OpCode (
-                       0xff << 0 | 0x45 << 8 | (byte) Code.Switch << 16 | (byte) FlowControl.Cond_Branch << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineSwitch << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldind_I1 = new OpCode (
-                       0xff << 0 | 0x46 << 8 | (byte) Code.Ldind_I1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldind_U1 = new OpCode (
-                       0xff << 0 | 0x47 << 8 | (byte) Code.Ldind_U1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldind_I2 = new OpCode (
-                       0xff << 0 | 0x48 << 8 | (byte) Code.Ldind_I2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldind_U2 = new OpCode (
-                       0xff << 0 | 0x49 << 8 | (byte) Code.Ldind_U2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldind_I4 = new OpCode (
-                       0xff << 0 | 0x4a << 8 | (byte) Code.Ldind_I4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldind_U4 = new OpCode (
-                       0xff << 0 | 0x4b << 8 | (byte) Code.Ldind_U4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldind_I8 = new OpCode (
-                       0xff << 0 | 0x4c << 8 | (byte) Code.Ldind_I8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushi8 << 24);
-
-               public static readonly OpCode Ldind_I = new OpCode (
-                       0xff << 0 | 0x4d << 8 | (byte) Code.Ldind_I << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldind_R4 = new OpCode (
-                       0xff << 0 | 0x4e << 8 | (byte) Code.Ldind_R4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushr4 << 24);
-
-               public static readonly OpCode Ldind_R8 = new OpCode (
-                       0xff << 0 | 0x4f << 8 | (byte) Code.Ldind_R8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushr8 << 24);
-
-               public static readonly OpCode Ldind_Ref = new OpCode (
-                       0xff << 0 | 0x50 << 8 | (byte) Code.Ldind_Ref << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushref << 24);
-
-               public static readonly OpCode Stind_Ref = new OpCode (
-                       0xff << 0 | 0x51 << 8 | (byte) Code.Stind_Ref << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stind_I1 = new OpCode (
-                       0xff << 0 | 0x52 << 8 | (byte) Code.Stind_I1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stind_I2 = new OpCode (
-                       0xff << 0 | 0x53 << 8 | (byte) Code.Stind_I2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stind_I4 = new OpCode (
-                       0xff << 0 | 0x54 << 8 | (byte) Code.Stind_I4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stind_I8 = new OpCode (
-                       0xff << 0 | 0x55 << 8 | (byte) Code.Stind_I8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popi8 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stind_R4 = new OpCode (
-                       0xff << 0 | 0x56 << 8 | (byte) Code.Stind_R4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popr4 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stind_R8 = new OpCode (
-                       0xff << 0 | 0x57 << 8 | (byte) Code.Stind_R8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popr8 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Add = new OpCode (
-                       0xff << 0 | 0x58 << 8 | (byte) Code.Add << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Sub = new OpCode (
-                       0xff << 0 | 0x59 << 8 | (byte) Code.Sub << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Mul = new OpCode (
-                       0xff << 0 | 0x5a << 8 | (byte) Code.Mul << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Div = new OpCode (
-                       0xff << 0 | 0x5b << 8 | (byte) Code.Div << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Div_Un = new OpCode (
-                       0xff << 0 | 0x5c << 8 | (byte) Code.Div_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Rem = new OpCode (
-                       0xff << 0 | 0x5d << 8 | (byte) Code.Rem << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Rem_Un = new OpCode (
-                       0xff << 0 | 0x5e << 8 | (byte) Code.Rem_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode And = new OpCode (
-                       0xff << 0 | 0x5f << 8 | (byte) Code.And << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Or = new OpCode (
-                       0xff << 0 | 0x60 << 8 | (byte) Code.Or << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Xor = new OpCode (
-                       0xff << 0 | 0x61 << 8 | (byte) Code.Xor << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Shl = new OpCode (
-                       0xff << 0 | 0x62 << 8 | (byte) Code.Shl << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Shr = new OpCode (
-                       0xff << 0 | 0x63 << 8 | (byte) Code.Shr << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Shr_Un = new OpCode (
-                       0xff << 0 | 0x64 << 8 | (byte) Code.Shr_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Neg = new OpCode (
-                       0xff << 0 | 0x65 << 8 | (byte) Code.Neg << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Not = new OpCode (
-                       0xff << 0 | 0x66 << 8 | (byte) Code.Not << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Conv_I1 = new OpCode (
-                       0xff << 0 | 0x67 << 8 | (byte) Code.Conv_I1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_I2 = new OpCode (
-                       0xff << 0 | 0x68 << 8 | (byte) Code.Conv_I2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_I4 = new OpCode (
-                       0xff << 0 | 0x69 << 8 | (byte) Code.Conv_I4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_I8 = new OpCode (
-                       0xff << 0 | 0x6a << 8 | (byte) Code.Conv_I8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi8 << 24);
-
-               public static readonly OpCode Conv_R4 = new OpCode (
-                       0xff << 0 | 0x6b << 8 | (byte) Code.Conv_R4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushr4 << 24);
-
-               public static readonly OpCode Conv_R8 = new OpCode (
-                       0xff << 0 | 0x6c << 8 | (byte) Code.Conv_R8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushr8 << 24);
-
-               public static readonly OpCode Conv_U4 = new OpCode (
-                       0xff << 0 | 0x6d << 8 | (byte) Code.Conv_U4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_U8 = new OpCode (
-                       0xff << 0 | 0x6e << 8 | (byte) Code.Conv_U8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi8 << 24);
-
-               public static readonly OpCode Callvirt = new OpCode (
-                       0xff << 0 | 0x6f << 8 | (byte) Code.Callvirt << 16 | (byte) FlowControl.Call << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineMethod << 8 | (byte) StackBehaviour.Varpop << 16 | (byte) StackBehaviour.Varpush << 24);
-
-               public static readonly OpCode Cpobj = new OpCode (
-                       0xff << 0 | 0x70 << 8 | (byte) Code.Cpobj << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldobj = new OpCode (
-                       0xff << 0 | 0x71 << 8 | (byte) Code.Ldobj << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldstr = new OpCode (
-                       0xff << 0 | 0x72 << 8 | (byte) Code.Ldstr << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineString << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushref << 24);
-
-               public static readonly OpCode Newobj = new OpCode (
-                       0xff << 0 | 0x73 << 8 | (byte) Code.Newobj << 16 | (byte) FlowControl.Call << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineMethod << 8 | (byte) StackBehaviour.Varpop << 16 | (byte) StackBehaviour.Pushref << 24);
-
-               public static readonly OpCode Castclass = new OpCode (
-                       0xff << 0 | 0x74 << 8 | (byte) Code.Castclass << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popref << 16 | (byte) StackBehaviour.Pushref << 24);
-
-               public static readonly OpCode Isinst = new OpCode (
-                       0xff << 0 | 0x75 << 8 | (byte) Code.Isinst << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popref << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_R_Un = new OpCode (
-                       0xff << 0 | 0x76 << 8 | (byte) Code.Conv_R_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushr8 << 24);
-
-               public static readonly OpCode Unbox = new OpCode (
-                       0xff << 0 | 0x79 << 8 | (byte) Code.Unbox << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popref << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Throw = new OpCode (
-                       0xff << 0 | 0x7a << 8 | (byte) Code.Throw << 16 | (byte) FlowControl.Throw << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldfld = new OpCode (
-                       0xff << 0 | 0x7b << 8 | (byte) Code.Ldfld << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineField << 8 | (byte) StackBehaviour.Popref << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldflda = new OpCode (
-                       0xff << 0 | 0x7c << 8 | (byte) Code.Ldflda << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineField << 8 | (byte) StackBehaviour.Popref << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Stfld = new OpCode (
-                       0xff << 0 | 0x7d << 8 | (byte) Code.Stfld << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineField << 8 | (byte) StackBehaviour.Popref_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldsfld = new OpCode (
-                       0xff << 0 | 0x7e << 8 | (byte) Code.Ldsfld << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineField << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldsflda = new OpCode (
-                       0xff << 0 | 0x7f << 8 | (byte) Code.Ldsflda << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineField << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Stsfld = new OpCode (
-                       0xff << 0 | 0x80 << 8 | (byte) Code.Stsfld << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineField << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stobj = new OpCode (
-                       0xff << 0 | 0x81 << 8 | (byte) Code.Stobj << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popi_pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Conv_Ovf_I1_Un = new OpCode (
-                       0xff << 0 | 0x82 << 8 | (byte) Code.Conv_Ovf_I1_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_I2_Un = new OpCode (
-                       0xff << 0 | 0x83 << 8 | (byte) Code.Conv_Ovf_I2_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_I4_Un = new OpCode (
-                       0xff << 0 | 0x84 << 8 | (byte) Code.Conv_Ovf_I4_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_I8_Un = new OpCode (
-                       0xff << 0 | 0x85 << 8 | (byte) Code.Conv_Ovf_I8_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi8 << 24);
-
-               public static readonly OpCode Conv_Ovf_U1_Un = new OpCode (
-                       0xff << 0 | 0x86 << 8 | (byte) Code.Conv_Ovf_U1_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_U2_Un = new OpCode (
-                       0xff << 0 | 0x87 << 8 | (byte) Code.Conv_Ovf_U2_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_U4_Un = new OpCode (
-                       0xff << 0 | 0x88 << 8 | (byte) Code.Conv_Ovf_U4_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_U8_Un = new OpCode (
-                       0xff << 0 | 0x89 << 8 | (byte) Code.Conv_Ovf_U8_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi8 << 24);
-
-               public static readonly OpCode Conv_Ovf_I_Un = new OpCode (
-                       0xff << 0 | 0x8a << 8 | (byte) Code.Conv_Ovf_I_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_U_Un = new OpCode (
-                       0xff << 0 | 0x8b << 8 | (byte) Code.Conv_Ovf_U_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Box = new OpCode (
-                       0xff << 0 | 0x8c << 8 | (byte) Code.Box << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushref << 24);
-
-               public static readonly OpCode Newarr = new OpCode (
-                       0xff << 0 | 0x8d << 8 | (byte) Code.Newarr << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushref << 24);
-
-               public static readonly OpCode Ldlen = new OpCode (
-                       0xff << 0 | 0x8e << 8 | (byte) Code.Ldlen << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldelema = new OpCode (
-                       0xff << 0 | 0x8f << 8 | (byte) Code.Ldelema << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldelem_I1 = new OpCode (
-                       0xff << 0 | 0x90 << 8 | (byte) Code.Ldelem_I1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldelem_U1 = new OpCode (
-                       0xff << 0 | 0x91 << 8 | (byte) Code.Ldelem_U1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldelem_I2 = new OpCode (
-                       0xff << 0 | 0x92 << 8 | (byte) Code.Ldelem_I2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldelem_U2 = new OpCode (
-                       0xff << 0 | 0x93 << 8 | (byte) Code.Ldelem_U2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldelem_I4 = new OpCode (
-                       0xff << 0 | 0x94 << 8 | (byte) Code.Ldelem_I4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldelem_U4 = new OpCode (
-                       0xff << 0 | 0x95 << 8 | (byte) Code.Ldelem_U4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldelem_I8 = new OpCode (
-                       0xff << 0 | 0x96 << 8 | (byte) Code.Ldelem_I8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushi8 << 24);
-
-               public static readonly OpCode Ldelem_I = new OpCode (
-                       0xff << 0 | 0x97 << 8 | (byte) Code.Ldelem_I << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldelem_R4 = new OpCode (
-                       0xff << 0 | 0x98 << 8 | (byte) Code.Ldelem_R4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushr4 << 24);
-
-               public static readonly OpCode Ldelem_R8 = new OpCode (
-                       0xff << 0 | 0x99 << 8 | (byte) Code.Ldelem_R8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushr8 << 24);
-
-               public static readonly OpCode Ldelem_Ref = new OpCode (
-                       0xff << 0 | 0x9a << 8 | (byte) Code.Ldelem_Ref << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Pushref << 24);
-
-               public static readonly OpCode Stelem_I = new OpCode (
-                       0xff << 0 | 0x9b << 8 | (byte) Code.Stelem_I << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stelem_I1 = new OpCode (
-                       0xff << 0 | 0x9c << 8 | (byte) Code.Stelem_I1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stelem_I2 = new OpCode (
-                       0xff << 0 | 0x9d << 8 | (byte) Code.Stelem_I2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stelem_I4 = new OpCode (
-                       0xff << 0 | 0x9e << 8 | (byte) Code.Stelem_I4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stelem_I8 = new OpCode (
-                       0xff << 0 | 0x9f << 8 | (byte) Code.Stelem_I8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi_popi8 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stelem_R4 = new OpCode (
-                       0xff << 0 | 0xa0 << 8 | (byte) Code.Stelem_R4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi_popr4 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stelem_R8 = new OpCode (
-                       0xff << 0 | 0xa1 << 8 | (byte) Code.Stelem_R8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi_popr8 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stelem_Ref = new OpCode (
-                       0xff << 0 | 0xa2 << 8 | (byte) Code.Stelem_Ref << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popref_popi_popref << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldelem_Any = new OpCode (
-                       0xff << 0 | 0xa3 << 8 | (byte) Code.Ldelem_Any << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popref_popi << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Stelem_Any = new OpCode (
-                       0xff << 0 | 0xa4 << 8 | (byte) Code.Stelem_Any << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popref_popi_popref << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Unbox_Any = new OpCode (
-                       0xff << 0 | 0xa5 << 8 | (byte) Code.Unbox_Any << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popref << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Conv_Ovf_I1 = new OpCode (
-                       0xff << 0 | 0xb3 << 8 | (byte) Code.Conv_Ovf_I1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_U1 = new OpCode (
-                       0xff << 0 | 0xb4 << 8 | (byte) Code.Conv_Ovf_U1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_I2 = new OpCode (
-                       0xff << 0 | 0xb5 << 8 | (byte) Code.Conv_Ovf_I2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_U2 = new OpCode (
-                       0xff << 0 | 0xb6 << 8 | (byte) Code.Conv_Ovf_U2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_I4 = new OpCode (
-                       0xff << 0 | 0xb7 << 8 | (byte) Code.Conv_Ovf_I4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_U4 = new OpCode (
-                       0xff << 0 | 0xb8 << 8 | (byte) Code.Conv_Ovf_U4 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_I8 = new OpCode (
-                       0xff << 0 | 0xb9 << 8 | (byte) Code.Conv_Ovf_I8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi8 << 24);
-
-               public static readonly OpCode Conv_Ovf_U8 = new OpCode (
-                       0xff << 0 | 0xba << 8 | (byte) Code.Conv_Ovf_U8 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi8 << 24);
-
-               public static readonly OpCode Refanyval = new OpCode (
-                       0xff << 0 | 0xc2 << 8 | (byte) Code.Refanyval << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ckfinite = new OpCode (
-                       0xff << 0 | 0xc3 << 8 | (byte) Code.Ckfinite << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushr8 << 24);
-
-               public static readonly OpCode Mkrefany = new OpCode (
-                       0xff << 0 | 0xc6 << 8 | (byte) Code.Mkrefany << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldtoken = new OpCode (
-                       0xff << 0 | 0xd0 << 8 | (byte) Code.Ldtoken << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineTok << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_U2 = new OpCode (
-                       0xff << 0 | 0xd1 << 8 | (byte) Code.Conv_U2 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_U1 = new OpCode (
-                       0xff << 0 | 0xd2 << 8 | (byte) Code.Conv_U1 << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_I = new OpCode (
-                       0xff << 0 | 0xd3 << 8 | (byte) Code.Conv_I << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_I = new OpCode (
-                       0xff << 0 | 0xd4 << 8 | (byte) Code.Conv_Ovf_I << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Conv_Ovf_U = new OpCode (
-                       0xff << 0 | 0xd5 << 8 | (byte) Code.Conv_Ovf_U << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Add_Ovf = new OpCode (
-                       0xff << 0 | 0xd6 << 8 | (byte) Code.Add_Ovf << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Add_Ovf_Un = new OpCode (
-                       0xff << 0 | 0xd7 << 8 | (byte) Code.Add_Ovf_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Mul_Ovf = new OpCode (
-                       0xff << 0 | 0xd8 << 8 | (byte) Code.Mul_Ovf << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Mul_Ovf_Un = new OpCode (
-                       0xff << 0 | 0xd9 << 8 | (byte) Code.Mul_Ovf_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Sub_Ovf = new OpCode (
-                       0xff << 0 | 0xda << 8 | (byte) Code.Sub_Ovf << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Sub_Ovf_Un = new OpCode (
-                       0xff << 0 | 0xdb << 8 | (byte) Code.Sub_Ovf_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Endfinally = new OpCode (
-                       0xff << 0 | 0xdc << 8 | (byte) Code.Endfinally << 16 | (byte) FlowControl.Return << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Leave = new OpCode (
-                       0xff << 0 | 0xdd << 8 | (byte) Code.Leave << 16 | (byte) FlowControl.Branch << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineBrTarget << 8 | (byte) StackBehaviour.PopAll << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Leave_S = new OpCode (
-                       0xff << 0 | 0xde << 8 | (byte) Code.Leave_S << 16 | (byte) FlowControl.Branch << 24,
-                       (byte) OpCodeType.Macro << 0 | (byte) OperandType.ShortInlineBrTarget << 8 | (byte) StackBehaviour.PopAll << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Stind_I = new OpCode (
-                       0xff << 0 | 0xdf << 8 | (byte) Code.Stind_I << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Conv_U = new OpCode (
-                       0xff << 0 | 0xe0 << 8 | (byte) Code.Conv_U << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Arglist = new OpCode (
-                       0xfe << 0 | 0x00 << 8 | (byte) Code.Arglist << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ceq = new OpCode (
-                       0xfe << 0 | 0x01 << 8 | (byte) Code.Ceq << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Cgt = new OpCode (
-                       0xfe << 0 | 0x02 << 8 | (byte) Code.Cgt << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Cgt_Un = new OpCode (
-                       0xfe << 0 | 0x03 << 8 | (byte) Code.Cgt_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Clt = new OpCode (
-                       0xfe << 0 | 0x04 << 8 | (byte) Code.Clt << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Clt_Un = new OpCode (
-                       0xfe << 0 | 0x05 << 8 | (byte) Code.Clt_Un << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1_pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldftn = new OpCode (
-                       0xfe << 0 | 0x06 << 8 | (byte) Code.Ldftn << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineMethod << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldvirtftn = new OpCode (
-                       0xfe << 0 | 0x07 << 8 | (byte) Code.Ldvirtftn << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineMethod << 8 | (byte) StackBehaviour.Popref << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Ldarg = new OpCode (
-                       0xfe << 0 | 0x09 << 8 | (byte) Code.Ldarg << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineArg << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldarga = new OpCode (
-                       0xfe << 0 | 0x0a << 8 | (byte) Code.Ldarga << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineArg << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Starg = new OpCode (
-                       0xfe << 0 | 0x0b << 8 | (byte) Code.Starg << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineArg << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Ldloc = new OpCode (
-                       0xfe << 0 | 0x0c << 8 | (byte) Code.Ldloc << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineVar << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push1 << 24);
-
-               public static readonly OpCode Ldloca = new OpCode (
-                       0xfe << 0 | 0x0d << 8 | (byte) Code.Ldloca << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineVar << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Stloc = new OpCode (
-                       0xfe << 0 | 0x0e << 8 | (byte) Code.Stloc << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineVar << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Localloc = new OpCode (
-                       0xfe << 0 | 0x0f << 8 | (byte) Code.Localloc << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Endfilter = new OpCode (
-                       0xfe << 0 | 0x11 << 8 | (byte) Code.Endfilter << 16 | (byte) FlowControl.Return << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Unaligned = new OpCode (
-                       0xfe << 0 | 0x12 << 8 | (byte) Code.Unaligned << 16 | (byte) FlowControl.Meta << 24,
-                       (byte) OpCodeType.Prefix << 0 | (byte) OperandType.ShortInlineI << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Volatile = new OpCode (
-                       0xfe << 0 | 0x13 << 8 | (byte) Code.Volatile << 16 | (byte) FlowControl.Meta << 24,
-                       (byte) OpCodeType.Prefix << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Tail = new OpCode (
-                       0xfe << 0 | 0x14 << 8 | (byte) Code.Tail << 16 | (byte) FlowControl.Meta << 24,
-                       (byte) OpCodeType.Prefix << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Initobj = new OpCode (
-                       0xfe << 0 | 0x15 << 8 | (byte) Code.Initobj << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Constrained = new OpCode (
-                       0xfe << 0 | 0x16 << 8 | (byte) Code.Constrained << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Prefix << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Cpblk = new OpCode (
-                       0xfe << 0 | 0x17 << 8 | (byte) Code.Cpblk << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Initblk = new OpCode (
-                       0xfe << 0 | 0x18 << 8 | (byte) Code.Initblk << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Popi_popi_popi << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode No = new OpCode (
-                       0xfe << 0 | 0x19 << 8 | (byte) Code.No << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Prefix << 0 | (byte) OperandType.ShortInlineI << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Rethrow = new OpCode (
-                       0xfe << 0 | 0x1a << 8 | (byte) Code.Rethrow << 16 | (byte) FlowControl.Throw << 24,
-                       (byte) OpCodeType.Objmodel << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-
-               public static readonly OpCode Sizeof = new OpCode (
-                       0xfe << 0 | 0x1c << 8 | (byte) Code.Sizeof << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineType << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Refanytype = new OpCode (
-                       0xfe << 0 | 0x1d << 8 | (byte) Code.Refanytype << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Primitive << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop1 << 16 | (byte) StackBehaviour.Pushi << 24);
-
-               public static readonly OpCode Readonly = new OpCode (
-                       0xfe << 0 | 0x1e << 8 | (byte) Code.Readonly << 16 | (byte) FlowControl.Next << 24,
-                       (byte) OpCodeType.Prefix << 0 | (byte) OperandType.InlineNone << 8 | (byte) StackBehaviour.Pop0 << 16 | (byte) StackBehaviour.Push0 << 24);
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/SequencePoint.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/SequencePoint.cs
deleted file mode 100644 (file)
index ef87e30..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-//
-// SequencePoint.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil.Cil {
-
-       public sealed class SequencePoint {
-
-               Document document;
-
-               int start_line;
-               int start_column;
-               int end_line;
-               int end_column;
-
-               public int StartLine {
-                       get { return start_line; }
-                       set { start_line = value; }
-               }
-
-               public int StartColumn {
-                       get { return start_column; }
-                       set { start_column = value; }
-               }
-
-               public int EndLine {
-                       get { return end_line; }
-                       set { end_line = value; }
-               }
-
-               public int EndColumn {
-                       get { return end_column; }
-                       set { end_column = value; }
-               }
-
-               public Document Document {
-                       get { return document; }
-                       set { document = value; }
-               }
-
-               public SequencePoint (Document document)
-               {
-                       this.document = document;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/Symbols.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/Symbols.cs
deleted file mode 100644 (file)
index 426c4a7..0000000
+++ /dev/null
@@ -1,277 +0,0 @@
-//
-// Symbols.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.IO;
-using System.Runtime.InteropServices;
-using SR = System.Reflection;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil.Cil {
-
-       [StructLayout (LayoutKind.Sequential)]
-       public struct ImageDebugDirectory {
-               public int Characteristics;
-               public int TimeDateStamp;
-               public short MajorVersion;
-               public short MinorVersion;
-               public int Type;
-               public int SizeOfData;
-               public int AddressOfRawData;
-               public int PointerToRawData;
-       }
-
-       public sealed class Scope : IVariableDefinitionProvider {
-
-               Instruction start;
-               Instruction end;
-
-               Collection<Scope> scopes;
-               Collection<VariableDefinition> variables;
-
-               public Instruction Start {
-                       get { return start; }
-                       set { start = value; }
-               }
-
-               public Instruction End {
-                       get { return end; }
-                       set { end = value; }
-               }
-
-               public bool HasScopes {
-                       get { return !scopes.IsNullOrEmpty (); }
-               }
-
-               public Collection<Scope> Scopes {
-                       get {
-                               if (scopes == null)
-                                       scopes = new Collection<Scope> ();
-
-                               return scopes;
-                       }
-               }
-
-               public bool HasVariables {
-                       get { return !variables.IsNullOrEmpty (); }
-               }
-
-               public Collection<VariableDefinition> Variables {
-                       get {
-                               if (variables == null)
-                                       variables = new Collection<VariableDefinition> ();
-
-                               return variables;
-                       }
-               }
-       }
-
-       public struct InstructionSymbol {
-
-               public readonly int Offset;
-               public readonly SequencePoint SequencePoint;
-
-               public InstructionSymbol (int offset, SequencePoint sequencePoint)
-               {
-                       this.Offset = offset;
-                       this.SequencePoint = sequencePoint;
-               }
-       }
-
-       public sealed class MethodSymbols {
-
-               internal int code_size;
-               internal string method_name;
-               internal MetadataToken method_token;
-               internal MetadataToken local_var_token;
-               internal Collection<VariableDefinition> variables;
-               internal Collection<InstructionSymbol> instructions;
-
-               public bool HasVariables {
-                       get { return !variables.IsNullOrEmpty (); }
-               }
-
-               public Collection<VariableDefinition> Variables {
-                       get {
-                               if (variables == null)
-                                       variables = new Collection<VariableDefinition> ();
-
-                               return variables;
-                       }
-               }
-
-               public Collection<InstructionSymbol> Instructions {
-                       get {
-                               if (instructions == null)
-                                       instructions = new Collection<InstructionSymbol> ();
-
-                               return instructions;
-                       }
-               }
-
-               public int CodeSize {
-                       get { return code_size; }
-               }
-
-               public string MethodName {
-                       get { return method_name; }
-               }
-
-               public MetadataToken MethodToken {
-                       get { return method_token; }
-               }
-
-               public MetadataToken LocalVarToken {
-                       get { return local_var_token; }
-               }
-
-               internal MethodSymbols (string methodName)
-               {
-                       this.method_name = methodName;
-               }
-
-               public MethodSymbols (MetadataToken methodToken)
-               {
-                       this.method_token = methodToken;
-               }
-       }
-
-       public delegate Instruction InstructionMapper (int offset);
-
-       public interface ISymbolReader : IDisposable {
-
-               bool ProcessDebugHeader (ImageDebugDirectory directory, byte [] header);
-               void Read (MethodBody body, InstructionMapper mapper);
-               void Read (MethodSymbols symbols);
-       }
-
-       public interface ISymbolReaderProvider {
-
-               ISymbolReader GetSymbolReader (ModuleDefinition module, string fileName);
-               ISymbolReader GetSymbolReader (ModuleDefinition module, Stream symbolStream);
-       }
-
-       static class SymbolProvider {
-
-               static readonly string symbol_kind = Type.GetType ("Mono.Runtime") != null ? "Mdb" : "Pdb";
-
-               static SR.AssemblyName GetPlatformSymbolAssemblyName ()
-               {
-                       var cecil_name = typeof (SymbolProvider).Assembly.GetName ();
-
-                       var name = new SR.AssemblyName {
-                               Name = "Mono.Cecil." + symbol_kind,
-                               Version = cecil_name.Version,
-                       };
-
-                       name.SetPublicKeyToken (cecil_name.GetPublicKeyToken ());
-
-                       return name;
-               }
-
-               static Type GetPlatformType (string fullname)
-               {
-                       var type = Type.GetType (fullname);
-                       if (type != null)
-                               return type;
-
-                       var assembly_name = GetPlatformSymbolAssemblyName ();
-
-                       type = Type.GetType (fullname + ", " + assembly_name.FullName);
-                       if (type != null)
-                               return type;
-
-                       try {
-                               var assembly = SR.Assembly.Load (assembly_name);
-                               if (assembly != null)
-                                       return assembly.GetType (fullname);
-                       } catch (FileNotFoundException) {
-#if !CF
-                       } catch (FileLoadException) {
-#endif
-                       }
-
-                       return null;
-               }
-
-               static ISymbolReaderProvider reader_provider;
-
-               public static ISymbolReaderProvider GetPlatformReaderProvider ()
-               {
-                       if (reader_provider != null)
-                               return reader_provider;
-
-                       var type = GetPlatformType (GetProviderTypeName ("ReaderProvider"));
-                       if (type == null)
-                               return null;
-
-                       return reader_provider = (ISymbolReaderProvider) Activator.CreateInstance (type);
-               }
-
-               static string GetProviderTypeName (string name)
-               {
-                       return "Mono.Cecil." + symbol_kind + "." + symbol_kind + name;
-               }
-
-#if !READ_ONLY
-
-               static ISymbolWriterProvider writer_provider;
-
-               public static ISymbolWriterProvider GetPlatformWriterProvider ()
-               {
-                       if (writer_provider != null)
-                               return writer_provider;
-
-                       var type = GetPlatformType (GetProviderTypeName ("WriterProvider"));
-                       if (type == null)
-                               return null;
-
-                       return writer_provider = (ISymbolWriterProvider) Activator.CreateInstance (type);
-               }
-
-#endif
-       }
-
-#if !READ_ONLY
-
-       public interface ISymbolWriter : IDisposable {
-
-               bool GetDebugHeader (out ImageDebugDirectory directory, out byte [] header);
-               void Write (MethodBody body);
-               void Write (MethodSymbols symbols);
-       }
-
-       public interface ISymbolWriterProvider {
-
-               ISymbolWriter GetSymbolWriter (ModuleDefinition module, string fileName);
-               ISymbolWriter GetSymbolWriter (ModuleDefinition module, Stream symbolStream);
-       }
-
-#endif
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/VariableDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/VariableDefinition.cs
deleted file mode 100644 (file)
index f501bca..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-//
-// VariableDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil.Cil {
-
-       public sealed class VariableDefinition : VariableReference {
-
-               public bool IsPinned {
-                       get { return variable_type.IsPinned; }
-               }
-
-               public VariableDefinition (TypeReference variableType)
-                       : base (variableType)
-               {
-               }
-
-               public VariableDefinition (string name, TypeReference variableType)
-                       : base (name, variableType)
-               {
-               }
-
-               public override VariableDefinition Resolve ()
-               {
-                       return this;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Cil/VariableReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Cil/VariableReference.cs
deleted file mode 100644 (file)
index ce0b4cd..0000000
+++ /dev/null
@@ -1,75 +0,0 @@
-//
-// VariableReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil.Cil {
-
-       public abstract class VariableReference {
-
-               string name;
-               internal int index = -1;
-               protected TypeReference variable_type;
-
-               public string Name {
-                       get { return name; }
-                       set { name = value; }
-               }
-
-               public TypeReference VariableType {
-                       get { return variable_type; }
-                       set { variable_type = value; }
-               }
-
-               public int Index {
-                       get { return index; }
-               }
-
-               internal VariableReference (TypeReference variable_type)
-                       : this (string.Empty, variable_type)
-               {
-               }
-
-               internal VariableReference (string name, TypeReference variable_type)
-               {
-                       this.name = name;
-                       this.variable_type = variable_type;
-               }
-
-               public abstract VariableDefinition Resolve ();
-
-               public override string ToString ()
-               {
-                       if (!string.IsNullOrEmpty (name))
-                               return name;
-
-                       if (index >= 0)
-                               return "V_" + index;
-
-                       return string.Empty;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/BlobHeap.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/BlobHeap.cs
deleted file mode 100644 (file)
index e7e2928..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-//
-// BlobHeap.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Cecil.PE;
-
-namespace Mono.Cecil.Metadata {
-
-       sealed class BlobHeap : Heap {
-
-               public BlobHeap (Section section, uint start, uint size)
-                       : base (section, start, size)
-               {
-               }
-
-               public byte [] Read (uint index)
-               {
-                       if (index == 0 || index > Size - 1)
-                               return Empty<byte>.Array;
-
-                       var data = Section.Data;
-
-                       int position = (int) (index + Offset);
-                       int length = (int) data.ReadCompressedUInt32 (ref position);
-
-                       var buffer = new byte [length];
-
-                       Buffer.BlockCopy (data, position, buffer, 0, length);
-
-                       return buffer;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Buffers.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Buffers.cs
deleted file mode 100644 (file)
index 1c54fdb..0000000
+++ /dev/null
@@ -1,373 +0,0 @@
-//
-// TableHeapBuffer.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-using System.Text;
-
-using Mono.Cecil.PE;
-
-using RVA = System.UInt32;
-
-#if !READ_ONLY
-
-namespace Mono.Cecil.Metadata {
-
-       sealed class TableHeapBuffer : HeapBuffer {
-
-               readonly ModuleDefinition module;
-               readonly MetadataBuilder metadata;
-
-               internal MetadataTable [] tables = new MetadataTable [45];
-
-               bool large_string;
-               bool large_blob;
-               readonly int [] coded_index_sizes = new int [13];
-               readonly Func<Table, int> counter;
-
-               public override bool IsEmpty {
-                       get { return false; }
-               }
-
-               public TableHeapBuffer (ModuleDefinition module, MetadataBuilder metadata)
-                       : base (24)
-               {
-                       this.module = module;
-                       this.metadata = metadata;
-                       this.counter = GetTableLength;
-               }
-
-               int GetTableLength (Table table)
-               {
-                       var md_table = tables [(int) table];
-                       return md_table != null ? md_table.Length : 0;
-               }
-
-               public TTable GetTable<TTable> (Table table) where TTable : MetadataTable, new ()
-               {
-                       var md_table = (TTable) tables [(int) table];
-                       if (md_table != null)
-                               return md_table;
-
-                       md_table = new TTable ();
-                       tables [(int) table] = md_table;
-                       return md_table;
-               }
-
-               public void WriteBySize (uint value, int size)
-               {
-                       if (size == 4)
-                               WriteUInt32 (value);
-                       else
-                               WriteUInt16 ((ushort) value);
-               }
-
-               public void WriteBySize (uint value, bool large)
-               {
-                       if (large)
-                               WriteUInt32 (value);
-                       else
-                               WriteUInt16 ((ushort) value);
-               }
-
-               public void WriteString (uint @string)
-               {
-                       WriteBySize (@string, large_string);
-               }
-
-               public void WriteBlob (uint blob)
-               {
-                       WriteBySize (blob, large_blob);
-               }
-
-               public void WriteRID (uint rid, Table table)
-               {
-                       var md_table = tables [(int) table];
-                       WriteBySize (rid, md_table == null ? false : md_table.IsLarge);
-               }
-
-               int GetCodedIndexSize (CodedIndex coded_index)
-               {
-                       var index = (int) coded_index;
-                       var size = coded_index_sizes [index];
-                       if (size != 0)
-                               return size;
-
-                       return coded_index_sizes [index] = coded_index.GetSize (counter);
-               }
-
-               public void WriteCodedRID (uint rid, CodedIndex coded_index)
-               {
-                       WriteBySize (rid, GetCodedIndexSize (coded_index));
-               }
-
-               public void WriteTableHeap ()
-               {
-                       WriteUInt32 (0);                                        // Reserved
-                       WriteByte (GetTableHeapVersion ());     // MajorVersion
-                       WriteByte (0);                                          // MinorVersion
-                       WriteByte (GetHeapSizes ());            // HeapSizes
-                       WriteByte (10);                                         // Reserved2
-                       WriteUInt64 (GetValid ());                      // Valid
-                       WriteUInt64 (0x0016003301fa00);         // Sorted
-
-                       WriteRowCount ();
-                       WriteTables ();
-               }
-
-               void WriteRowCount ()
-               {
-                       for (int i = 0; i < tables.Length; i++) {
-                               var table = tables [i];
-                               if (table == null || table.Length == 0)
-                                       continue;
-
-                               WriteUInt32 ((uint) table.Length);
-                       }
-               }
-
-               void WriteTables ()
-               {
-                       for (int i = 0; i < tables.Length; i++) {
-                               var table = tables [i];
-                               if (table == null || table.Length == 0)
-                                       continue;
-
-                               table.Write (this);
-                       }
-               }
-
-               ulong GetValid ()
-               {
-                       ulong valid = 0;
-
-                       for (int i = 0; i < tables.Length; i++) {
-                               var table = tables [i];
-                               if (table == null || table.Length == 0)
-                                       continue;
-
-                               table.Sort ();
-                               valid |= (1UL << i);
-                       }
-
-                       return valid;
-               }
-
-               byte GetHeapSizes ()
-               {
-                       byte heap_sizes = 0;
-
-                       if (metadata.string_heap.IsLarge) {
-                               large_string = true;
-                               heap_sizes |= 0x01;
-                       }
-
-                       if (metadata.blob_heap.IsLarge) {
-                               large_blob = true;
-                               heap_sizes |= 0x04;
-                       }
-
-                       return heap_sizes;
-               }
-
-               byte GetTableHeapVersion ()
-               {
-                       switch (module.Runtime) {
-                       case TargetRuntime.Net_1_0:
-                       case TargetRuntime.Net_1_1:
-                               return 1;
-                       default:
-                               return 2;
-                       }
-               }
-
-               public void FixupData (RVA data_rva)
-               {
-                       var table = GetTable<FieldRVATable> (Table.FieldRVA);
-                       if (table.length == 0)
-                               return;
-
-                       var field_idx_size = GetTable<FieldTable> (Table.Field).IsLarge ? 4 : 2;
-                       var previous = this.position;
-
-                       base.position = table.position;
-                       for (int i = 0; i < table.length; i++) {
-                               var rva = ReadUInt32 ();
-                               base.position -= 4;
-                               WriteUInt32 (rva + data_rva);
-                               base.position += field_idx_size;
-                       }
-
-                       base.position = previous;
-               }
-       }
-
-       sealed class ResourceBuffer : ByteBuffer {
-
-               public ResourceBuffer ()
-                       : base (0)
-               {
-               }
-
-               public uint AddResource (byte [] resource)
-               {
-                       var offset = (uint) this.position;
-                       WriteInt32 (resource.Length);
-                       WriteBytes (resource);
-                       return offset;
-               }
-       }
-
-       sealed class DataBuffer : ByteBuffer {
-
-               public DataBuffer ()
-                       : base (0)
-               {
-               }
-
-               public RVA AddData (byte [] data)
-               {
-                       var rva = (RVA) position;
-                       WriteBytes (data);
-                       return rva;
-               }
-       }
-
-       abstract class HeapBuffer : ByteBuffer {
-
-               public bool IsLarge {
-                       get { return base.length > 65535; }
-               }
-
-               public abstract bool IsEmpty { get; }
-
-               protected HeapBuffer (int length)
-                       : base (length)
-               {
-               }
-       }
-
-       class StringHeapBuffer : HeapBuffer {
-
-               readonly Dictionary<string, uint> strings = new Dictionary<string, uint> ();
-
-               public sealed override bool IsEmpty {
-                       get { return length <= 1; }
-               }
-
-               public StringHeapBuffer ()
-                       : base (1)
-               {
-                       WriteByte (0);
-               }
-
-               public uint GetStringIndex (string @string)
-               {
-                       uint index;
-                       if (strings.TryGetValue (@string, out index))
-                               return index;
-
-                       index = (uint) base.position;
-                       WriteString (@string);
-                       strings.Add (@string, index);
-                       return index;
-               }
-
-               protected virtual void WriteString (string @string)
-               {
-                       WriteBytes (Encoding.UTF8.GetBytes (@string));
-                       WriteByte (0);
-               }
-       }
-
-       sealed class BlobHeapBuffer : HeapBuffer {
-
-               readonly Dictionary<ByteBuffer, uint> blobs = new Dictionary<ByteBuffer, uint> (new ByteBufferEqualityComparer ());
-
-               public override bool IsEmpty {
-                       get { return length <= 1; }
-               }
-
-               public BlobHeapBuffer ()
-                       : base (1)
-               {
-                       WriteByte (0);
-               }
-
-               public uint GetBlobIndex (ByteBuffer blob)
-               {
-                       uint index;
-                       if (blobs.TryGetValue (blob, out index))
-                               return index;
-
-                       index = (uint) base.position;
-                       WriteBlob (blob);
-                       blobs.Add (blob, index);
-                       return index;
-               }
-
-               void WriteBlob (ByteBuffer blob)
-               {
-                       WriteCompressedUInt32 ((uint) blob.length);
-                       WriteBytes (blob);
-               }
-       }
-
-       sealed class UserStringHeapBuffer : StringHeapBuffer {
-
-               protected override void WriteString (string @string)
-               {
-                       WriteCompressedUInt32 ((uint) @string.Length * 2 + 1);
-
-                       byte special = 0;
-
-                       for (int i = 0; i < @string.Length; i++) {
-                               var @char = @string [i];
-                               WriteUInt16 (@char);
-
-                               if (special == 1)
-                                       continue;
-
-                               if (@char < 0x20 || @char > 0x7e) {
-                                       if (@char > 0x7e
-                                               || (@char >= 0x01 && @char <= 0x08)
-                                               || (@char >= 0x0e && @char <= 0x1f)
-                                               || @char == 0x27
-                                               || @char == 0x2d) {
-
-                                               special = 1;
-                                       }
-                               }
-                       }
-
-                       WriteByte (special);
-               }
-       }
-}
-
-#endif
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/CodedIndex.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/CodedIndex.cs
deleted file mode 100644 (file)
index 3e30fd8..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-//
-// CodedIndex.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil.Metadata {
-
-       enum CodedIndex {
-               TypeDefOrRef,
-               HasConstant,
-               HasCustomAttribute,
-               HasFieldMarshal,
-               HasDeclSecurity,
-               MemberRefParent,
-               HasSemantics,
-               MethodDefOrRef,
-               MemberForwarded,
-               Implementation,
-               CustomAttributeType,
-               ResolutionScope,
-               TypeOrMethodDef
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/ElementType.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/ElementType.cs
deleted file mode 100644 (file)
index 72fc1cc..0000000
+++ /dev/null
@@ -1,73 +0,0 @@
-//
-// ElementType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil.Metadata {
-
-       enum ElementType : byte {
-               None = 0x00,
-               Void = 0x01,
-               Boolean = 0x02,
-               Char = 0x03,
-               I1 = 0x04,
-               U1 = 0x05,
-               I2 = 0x06,
-               U2 = 0x07,
-               I4 = 0x08,
-               U4 = 0x09,
-               I8 = 0x0a,
-               U8 = 0x0b,
-               R4 = 0x0c,
-               R8 = 0x0d,
-               String = 0x0e,
-               Ptr = 0x0f,   // Followed by <type> token
-               ByRef = 0x10,   // Followed by <type> token
-               ValueType = 0x11,   // Followed by <type> token
-               Class = 0x12,   // Followed by <type> token
-               Var = 0x13,   // Followed by generic parameter number
-               Array = 0x14,   // <type> <rank> <boundsCount> <bound1>  <loCount> <lo1>
-               GenericInst = 0x15,   // <type> <type-arg-count> <type-1> ... <type-n> */
-               TypedByRef = 0x16,
-               I = 0x18,   // System.IntPtr
-               U = 0x19,   // System.UIntPtr
-               FnPtr = 0x1b,   // Followed by full method signature
-               Object = 0x1c,   // System.Object
-               SzArray = 0x1d,   // Single-dim array with 0 lower bound
-               MVar = 0x1e,   // Followed by generic parameter number
-               CModReqD = 0x1f,   // Required modifier : followed by a TypeDef or TypeRef token
-               CModOpt = 0x20,   // Optional modifier : followed by a TypeDef or TypeRef token
-               Internal = 0x21,   // Implemented within the CLI
-               Modifier = 0x40,   // Or'd with following element types
-               Sentinel = 0x41,   // Sentinel for varargs method signature
-               Pinned = 0x45,   // Denotes a local variable that points at a pinned object
-
-               // special undocumented constants
-               Type = 0x50,
-               Boxed = 0x51,
-               Enum = 0x55
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/GuidHeap.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/GuidHeap.cs
deleted file mode 100644 (file)
index 1adc079..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-//
-// GuidHeap.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Cecil.PE;
-
-namespace Mono.Cecil.Metadata {
-
-       sealed class GuidHeap : Heap {
-
-               public GuidHeap (Section section, uint start, uint size)
-                       : base (section, start, size)
-               {
-               }
-
-               public Guid Read (uint index)
-               {
-                       if (index == 0)
-                               return new Guid ();
-
-                       const int guid_size = 16;
-
-                       var buffer = new byte [guid_size];
-
-                       index--;
-
-                       Buffer.BlockCopy (Section.Data, (int) (Offset + index), buffer, 0, guid_size);
-
-                       return new Guid (buffer);
-
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Heap.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Heap.cs
deleted file mode 100644 (file)
index bc21acd..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-//
-// Heap.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using Mono.Cecil.PE;
-
-namespace Mono.Cecil.Metadata {
-
-       abstract class Heap {
-
-               public int IndexSize;
-
-               public readonly Section Section;
-               public readonly uint Offset;
-               public readonly uint Size;
-
-               protected Heap (Section section, uint offset, uint size)
-               {
-                       this.Section = section;
-                       this.Offset = offset;
-                       this.Size = size;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/MetadataToken.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/MetadataToken.cs
deleted file mode 100644 (file)
index bda56b0..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-//
-// MetadataToken.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public struct MetadataToken {
-
-               readonly uint token;
-
-               public uint RID {
-                       get { return token & 0x00ffffff; }
-               }
-
-               public TokenType TokenType {
-                       get { return (TokenType) (token & 0xff000000); }
-               }
-
-               public static readonly MetadataToken Zero = new MetadataToken ((uint) 0);
-
-               public MetadataToken (uint token)
-               {
-                       this.token = token;
-               }
-
-               public MetadataToken (TokenType type)
-                       : this (type, 0)
-               {
-               }
-
-               public MetadataToken (TokenType type, uint rid)
-               {
-                       token = (uint) type | rid;
-               }
-
-               public MetadataToken (TokenType type, int rid)
-               {
-                       token = (uint) type | (uint) rid;
-               }
-
-               public int ToInt32 ()
-               {
-                       return (int) token;
-               }
-
-               public uint ToUInt32 ()
-               {
-                       return token;
-               }
-
-               public override int GetHashCode ()
-               {
-                       return (int) token;
-               }
-
-               public override bool Equals (object obj)
-               {
-                       if (obj is MetadataToken) {
-                               var other = (MetadataToken) obj;
-                               return other.token == token;
-                       }
-
-                       return false;
-               }
-
-               public static bool operator == (MetadataToken one, MetadataToken other)
-               {
-                       return one.token == other.token;
-               }
-
-               public static bool operator != (MetadataToken one, MetadataToken other)
-               {
-                       return one.token != other.token;
-               }
-
-               public override string ToString ()
-               {
-                       return string.Format ("[{0}:0x{1}]", TokenType, RID.ToString ("x4"));
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Row.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Row.cs
deleted file mode 100644 (file)
index dfda00a..0000000
+++ /dev/null
@@ -1,170 +0,0 @@
-//
-// Row.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System.Collections.Generic;
-
-namespace Mono.Cecil.Metadata {
-
-       struct Row<T1, T2> {
-               internal T1 Col1;
-               internal T2 Col2;
-
-               public Row (T1 col1, T2 col2)
-               {
-                       Col1 = col1;
-                       Col2 = col2;
-               }
-       }
-
-       struct Row<T1, T2, T3> {
-               internal T1 Col1;
-               internal T2 Col2;
-               internal T3 Col3;
-
-               public Row (T1 col1, T2 col2, T3 col3)
-               {
-                       Col1 = col1;
-                       Col2 = col2;
-                       Col3 = col3;
-               }
-       }
-
-       struct Row<T1, T2, T3, T4> {
-               internal T1 Col1;
-               internal T2 Col2;
-               internal T3 Col3;
-               internal T4 Col4;
-
-               public Row (T1 col1, T2 col2, T3 col3, T4 col4)
-               {
-                       Col1 = col1;
-                       Col2 = col2;
-                       Col3 = col3;
-                       Col4 = col4;
-               }
-       }
-
-       struct Row<T1, T2, T3, T4, T5> {
-               internal T1 Col1;
-               internal T2 Col2;
-               internal T3 Col3;
-               internal T4 Col4;
-               internal T5 Col5;
-
-               public Row (T1 col1, T2 col2, T3 col3, T4 col4, T5 col5)
-               {
-                       Col1 = col1;
-                       Col2 = col2;
-                       Col3 = col3;
-                       Col4 = col4;
-                       Col5 = col5;
-               }
-       }
-
-       struct Row<T1, T2, T3, T4, T5, T6> {
-               internal T1 Col1;
-               internal T2 Col2;
-               internal T3 Col3;
-               internal T4 Col4;
-               internal T5 Col5;
-               internal T6 Col6;
-
-               public Row (T1 col1, T2 col2, T3 col3, T4 col4, T5 col5, T6 col6)
-               {
-                       Col1 = col1;
-                       Col2 = col2;
-                       Col3 = col3;
-                       Col4 = col4;
-                       Col5 = col5;
-                       Col6 = col6;
-               }
-       }
-
-       struct Row<T1, T2, T3, T4, T5, T6, T7, T8, T9> {
-               internal T1 Col1;
-               internal T2 Col2;
-               internal T3 Col3;
-               internal T4 Col4;
-               internal T5 Col5;
-               internal T6 Col6;
-               internal T7 Col7;
-               internal T8 Col8;
-               internal T9 Col9;
-
-               public Row (T1 col1, T2 col2, T3 col3, T4 col4, T5 col5, T6 col6, T7 col7, T8 col8, T9 col9)
-               {
-                       Col1 = col1;
-                       Col2 = col2;
-                       Col3 = col3;
-                       Col4 = col4;
-                       Col5 = col5;
-                       Col6 = col6;
-                       Col7 = col7;
-                       Col8 = col8;
-                       Col9 = col9;
-               }
-       }
-
-       sealed class RowEqualityComparer : IEqualityComparer<Row<string, string>>, IEqualityComparer<Row<uint, uint>>, IEqualityComparer<Row<uint, uint, uint>> {
-
-               public bool Equals (Row<string, string> x, Row<string, string> y)
-               {
-                       return x.Col1 == y.Col1
-                               && x.Col2 == y.Col2;
-               }
-
-               public int GetHashCode (Row<string, string> obj)
-               {
-                       string x = obj.Col1, y = obj.Col2;
-                       return (x != null ? x.GetHashCode () : 0) ^ (y != null ? y.GetHashCode () : 0);
-               }
-
-               public bool Equals (Row<uint, uint> x, Row<uint, uint> y)
-               {
-                       return x.Col1 == y.Col1
-                               && x.Col2 == y.Col2;
-               }
-
-               public int GetHashCode (Row<uint, uint> obj)
-               {
-                       return (int) (obj.Col1 ^ obj.Col2);
-               }
-
-               public bool Equals (Row<uint, uint, uint> x, Row<uint, uint, uint> y)
-               {
-                       return x.Col1 == y.Col1
-                               && x.Col2 == y.Col2
-                               && x.Col3 == y.Col3;
-               }
-
-               public int GetHashCode (Row<uint, uint, uint> obj)
-               {
-                       return (int) (obj.Col1 ^ obj.Col2 ^ obj.Col3);
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/StringHeap.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/StringHeap.cs
deleted file mode 100644 (file)
index 4a0a0af..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-//
-// StringHeap.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-using System.Text;
-
-using Mono.Cecil.PE;
-
-namespace Mono.Cecil.Metadata {
-
-       class StringHeap : Heap {
-
-               readonly Dictionary<uint, string> strings = new Dictionary<uint, string> ();
-
-               public StringHeap (Section section, uint start, uint size)
-                       : base (section, start, size)
-               {
-               }
-
-               public string Read (uint index)
-               {
-                       if (index == 0)
-                               return string.Empty;
-
-                       string @string;
-                       if (strings.TryGetValue (index, out @string))
-                               return @string;
-
-                       if (index > Size - 1)
-                               return string.Empty;
-
-                       @string = ReadStringAt (index);
-                       if (@string.Length != 0)
-                               strings.Add (index, @string);
-
-                       return @string;
-               }
-
-               protected virtual string ReadStringAt (uint index)
-               {
-                       int length = 0;
-                       byte [] data = Section.Data;
-                       int start = (int) (index + Offset);
-
-                       for (int i = start; ; i++) {
-                               if (data [i] == 0)
-                                       break;
-
-                               length++;
-                       }
-
-                       return Encoding.UTF8.GetString (data, start, length);
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/TableHeap.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/TableHeap.cs
deleted file mode 100644 (file)
index 9bc0edd..0000000
+++ /dev/null
@@ -1,111 +0,0 @@
-//
-// TableHeap.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using Mono.Cecil.PE;
-
-namespace Mono.Cecil.Metadata {
-
-       enum Table : byte {
-               Module = 0x00,
-               TypeRef = 0x01,
-               TypeDef = 0x02,
-               FieldPtr = 0x03,
-               Field = 0x04,
-               MethodPtr = 0x05,
-               Method = 0x06,
-               ParamPtr = 0x07,
-               Param = 0x08,
-               InterfaceImpl = 0x09,
-               MemberRef = 0x0a,
-               Constant = 0x0b,
-               CustomAttribute = 0x0c,
-               FieldMarshal = 0x0d,
-               DeclSecurity = 0x0e,
-               ClassLayout = 0x0f,
-               FieldLayout = 0x10,
-               StandAloneSig = 0x11,
-               EventMap = 0x12,
-               EventPtr = 0x13,
-               Event = 0x14,
-               PropertyMap = 0x15,
-               PropertyPtr = 0x16,
-               Property = 0x17,
-               MethodSemantics = 0x18,
-               MethodImpl = 0x19,
-               ModuleRef = 0x1a,
-               TypeSpec = 0x1b,
-               ImplMap = 0x1c,
-               FieldRVA = 0x1d,
-               EncLog = 0x1e,
-               EncMap = 0x1f,
-               Assembly = 0x20,
-               AssemblyProcessor = 0x21,
-               AssemblyOS = 0x22,
-               AssemblyRef = 0x23,
-               AssemblyRefProcessor = 0x24,
-               AssemblyRefOS = 0x25,
-               File = 0x26,
-               ExportedType = 0x27,
-               ManifestResource = 0x28,
-               NestedClass = 0x29,
-               GenericParam = 0x2a,
-               MethodSpec = 0x2b,
-               GenericParamConstraint = 0x2c,
-       }
-
-       struct TableInformation {
-               public uint Offset;
-               public uint Length;
-               public uint RowSize;
-       }
-
-       sealed class TableHeap : Heap {
-
-               public long Valid;
-               public long Sorted;
-
-               public const int TableCount = 45;
-
-               public readonly TableInformation [] Tables = new TableInformation [TableCount];
-
-               public TableInformation this [Table table] {
-                       get { return Tables [(int) table]; }
-               }
-
-               public TableHeap (Section section, uint start, uint size)
-                       : base (section, start, size)
-               {
-               }
-
-               public bool HasTable (Table table)
-               {
-                       return (Valid & (1L << (int) table)) != 0;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/TokenType.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/TokenType.cs
deleted file mode 100644 (file)
index 2c2010f..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-//
-// TokenType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public enum TokenType : uint {
-               Module = 0x00000000,
-               TypeRef = 0x01000000,
-               TypeDef = 0x02000000,
-               Field = 0x04000000,
-               Method = 0x06000000,
-               Param = 0x08000000,
-               InterfaceImpl = 0x09000000,
-               MemberRef = 0x0a000000,
-               CustomAttribute = 0x0c000000,
-               Permission = 0x0e000000,
-               Signature = 0x11000000,
-               Event = 0x14000000,
-               Property = 0x17000000,
-               ModuleRef = 0x1a000000,
-               TypeSpec = 0x1b000000,
-               Assembly = 0x20000000,
-               AssemblyRef = 0x23000000,
-               File = 0x26000000,
-               ExportedType = 0x27000000,
-               ManifestResource = 0x28000000,
-               GenericParam = 0x2a000000,
-               MethodSpec = 0x2b000000,
-               String = 0x70000000,
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/UserStringHeap.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/UserStringHeap.cs
deleted file mode 100644 (file)
index 5910508..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-//
-// UserStringHeap.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Cecil.PE;
-
-namespace Mono.Cecil.Metadata {
-
-       sealed class UserStringHeap : StringHeap {
-
-               public UserStringHeap (Section section, uint start, uint size)
-                       : base (section, start, size)
-               {
-               }
-
-               protected override string ReadStringAt (uint index)
-               {
-                       byte [] data = Section.Data;
-                       int start = (int) (index + Offset);
-
-                       uint length = (uint) (data.ReadCompressedUInt32 (ref start) & ~1);
-                       if (length < 1)
-                               return string.Empty;
-
-                       var chars = new char [length / 2];
-
-                       for (int i = start, j = 0; i < start + length; i += 2)
-                               chars [j++] = (char) (data [i] | (data [i + 1] << 8));
-
-                       return new string (chars);
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Utilities.cs b/mcs/class/Mono.Cecil/Mono.Cecil.Metadata/Utilities.cs
deleted file mode 100644 (file)
index d752b24..0000000
+++ /dev/null
@@ -1,529 +0,0 @@
-//
-// Utilities.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       static partial class Mixin {
-
-               public static uint ReadCompressedUInt32 (this byte [] data, ref int position)
-               {
-                       uint integer;
-                       if ((data [position] & 0x80) == 0) {
-                               integer = data [position];
-                               position++;
-                       } else if ((data [position] & 0x40) == 0) {
-                               integer = (uint) (data [position] & ~0x80) << 8;
-                               integer |= data [position + 1];
-                               position += 2;
-                       } else {
-                               integer = (uint) (data [position] & ~0xc0) << 24;
-                               integer |= (uint) data [position + 1] << 16;
-                               integer |= (uint) data [position + 2] << 8;
-                               integer |= (uint) data [position + 3];
-                               position += 4;
-                       }
-                       return integer;
-               }
-
-               public static MetadataToken GetMetadataToken (this CodedIndex self, uint data)
-               {
-                       uint rid;
-                       TokenType token_type;
-                       switch (self) {
-                       case CodedIndex.TypeDefOrRef:
-                               rid = data >> 2;
-                               switch (data & 3) {
-                               case 0:
-                                       token_type = TokenType.TypeDef; goto ret;
-                               case 1:
-                                       token_type = TokenType.TypeRef; goto ret;
-                               case 2:
-                                       token_type = TokenType.TypeSpec; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasConstant:
-                               rid = data >> 2;
-                               switch (data & 3) {
-                               case 0:
-                                       token_type = TokenType.Field; goto ret;
-                               case 1:
-                                       token_type = TokenType.Param; goto ret;
-                               case 2:
-                                       token_type = TokenType.Property; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasCustomAttribute:
-                               rid = data >> 5;
-                               switch (data & 31) {
-                               case 0:
-                                       token_type = TokenType.Method; goto ret;
-                               case 1:
-                                       token_type = TokenType.Field; goto ret;
-                               case 2:
-                                       token_type = TokenType.TypeRef; goto ret;
-                               case 3:
-                                       token_type = TokenType.TypeDef; goto ret;
-                               case 4:
-                                       token_type = TokenType.Param; goto ret;
-                               case 5:
-                                       token_type = TokenType.InterfaceImpl; goto ret;
-                               case 6:
-                                       token_type = TokenType.MemberRef; goto ret;
-                               case 7:
-                                       token_type = TokenType.Module; goto ret;
-                               case 8:
-                                       token_type = TokenType.Permission; goto ret;
-                               case 9:
-                                       token_type = TokenType.Property; goto ret;
-                               case 10:
-                                       token_type = TokenType.Event; goto ret;
-                               case 11:
-                                       token_type = TokenType.Signature; goto ret;
-                               case 12:
-                                       token_type = TokenType.ModuleRef; goto ret;
-                               case 13:
-                                       token_type = TokenType.TypeSpec; goto ret;
-                               case 14:
-                                       token_type = TokenType.Assembly; goto ret;
-                               case 15:
-                                       token_type = TokenType.AssemblyRef; goto ret;
-                               case 16:
-                                       token_type = TokenType.File; goto ret;
-                               case 17:
-                                       token_type = TokenType.ExportedType; goto ret;
-                               case 18:
-                                       token_type = TokenType.ManifestResource; goto ret;
-                               case 19:
-                                       token_type = TokenType.GenericParam; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasFieldMarshal:
-                               rid = data >> 1;
-                               switch (data & 1) {
-                               case 0:
-                                       token_type = TokenType.Field; goto ret;
-                               case 1:
-                                       token_type = TokenType.Param; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasDeclSecurity:
-                               rid = data >> 2;
-                               switch (data & 3) {
-                               case 0:
-                                       token_type = TokenType.TypeDef; goto ret;
-                               case 1:
-                                       token_type = TokenType.Method; goto ret;
-                               case 2:
-                                       token_type = TokenType.Assembly; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.MemberRefParent:
-                               rid = data >> 3;
-                               switch (data & 7) {
-                               case 0:
-                                       token_type = TokenType.TypeDef; goto ret;
-                               case 1:
-                                       token_type = TokenType.TypeRef; goto ret;
-                               case 2:
-                                       token_type = TokenType.ModuleRef; goto ret;
-                               case 3:
-                                       token_type = TokenType.Method; goto ret;
-                               case 4:
-                                       token_type = TokenType.TypeSpec; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasSemantics:
-                               rid = data >> 1;
-                               switch (data & 1) {
-                               case 0:
-                                       token_type = TokenType.Event; goto ret;
-                               case 1:
-                                       token_type = TokenType.Property; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.MethodDefOrRef:
-                               rid = data >> 1;
-                               switch (data & 1) {
-                               case 0:
-                                       token_type = TokenType.Method; goto ret;
-                               case 1:
-                                       token_type = TokenType.MemberRef; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.MemberForwarded:
-                               rid = data >> 1;
-                               switch (data & 1) {
-                               case 0:
-                                       token_type = TokenType.Field; goto ret;
-                               case 1:
-                                       token_type = TokenType.Method; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.Implementation:
-                               rid = data >> 2;
-                               switch (data & 3) {
-                               case 0:
-                                       token_type = TokenType.File; goto ret;
-                               case 1:
-                                       token_type = TokenType.AssemblyRef; goto ret;
-                               case 2:
-                                       token_type = TokenType.ExportedType; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.CustomAttributeType:
-                               rid = data >> 3;
-                               switch (data & 7) {
-                               case 2:
-                                       token_type = TokenType.Method; goto ret;
-                               case 3:
-                                       token_type = TokenType.MemberRef; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.ResolutionScope:
-                               rid = data >> 2;
-                               switch (data & 3) {
-                               case 0:
-                                       token_type = TokenType.Module; goto ret;
-                               case 1:
-                                       token_type = TokenType.ModuleRef; goto ret;
-                               case 2:
-                                       token_type = TokenType.AssemblyRef; goto ret;
-                               case 3:
-                                       token_type = TokenType.TypeRef; goto ret;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.TypeOrMethodDef:
-                               rid = data >> 1;
-                               switch (data & 1) {
-                               case 0:
-                                       token_type = TokenType.TypeDef; goto ret;
-                               case 1:
-                                       token_type = TokenType.Method; goto ret;
-                               default: goto exit;
-                               }
-                       default:
-                               goto exit;
-                       }
-               ret:
-                       return new MetadataToken (token_type, rid);
-               exit:
-                       return MetadataToken.Zero;
-               }
-
-#if !READ_ONLY
-               public static uint CompressMetadataToken (this CodedIndex self, MetadataToken token)
-               {
-                       uint ret = 0;
-                       if (token.RID == 0)
-                               return ret;
-                       switch (self) {
-                       case CodedIndex.TypeDefOrRef:
-                               ret = token.RID << 2;
-                               switch (token.TokenType) {
-                               case TokenType.TypeDef:
-                                       return ret | 0;
-                               case TokenType.TypeRef:
-                                       return ret | 1;
-                               case TokenType.TypeSpec:
-                                       return ret | 2;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasConstant:
-                               ret = token.RID << 2;
-                               switch (token.TokenType) {
-                               case TokenType.Field:
-                                       return ret | 0;
-                               case TokenType.Param:
-                                       return ret | 1;
-                               case TokenType.Property:
-                                       return ret | 2;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasCustomAttribute:
-                               ret = token.RID << 5;
-                               switch (token.TokenType) {
-                               case TokenType.Method:
-                                       return ret | 0;
-                               case TokenType.Field:
-                                       return ret | 1;
-                               case TokenType.TypeRef:
-                                       return ret | 2;
-                               case TokenType.TypeDef:
-                                       return ret | 3;
-                               case TokenType.Param:
-                                       return ret | 4;
-                               case TokenType.InterfaceImpl:
-                                       return ret | 5;
-                               case TokenType.MemberRef:
-                                       return ret | 6;
-                               case TokenType.Module:
-                                       return ret | 7;
-                               case TokenType.Permission:
-                                       return ret | 8;
-                               case TokenType.Property:
-                                       return ret | 9;
-                               case TokenType.Event:
-                                       return ret | 10;
-                               case TokenType.Signature:
-                                       return ret | 11;
-                               case TokenType.ModuleRef:
-                                       return ret | 12;
-                               case TokenType.TypeSpec:
-                                       return ret | 13;
-                               case TokenType.Assembly:
-                                       return ret | 14;
-                               case TokenType.AssemblyRef:
-                                       return ret | 15;
-                               case TokenType.File:
-                                       return ret | 16;
-                               case TokenType.ExportedType:
-                                       return ret | 17;
-                               case TokenType.ManifestResource:
-                                       return ret | 18;
-                               case TokenType.GenericParam:
-                                       return ret | 19;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasFieldMarshal:
-                               ret = token.RID << 1;
-                               switch (token.TokenType) {
-                               case TokenType.Field:
-                                       return ret | 0;
-                               case TokenType.Param:
-                                       return ret | 1;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasDeclSecurity:
-                               ret = token.RID << 2;
-                               switch (token.TokenType) {
-                               case TokenType.TypeDef:
-                                       return ret | 0;
-                               case TokenType.Method:
-                                       return ret | 1;
-                               case TokenType.Assembly:
-                                       return ret | 2;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.MemberRefParent:
-                               ret = token.RID << 3;
-                               switch (token.TokenType) {
-                               case TokenType.TypeDef:
-                                       return ret | 0;
-                               case TokenType.TypeRef:
-                                       return ret | 1;
-                               case TokenType.ModuleRef:
-                                       return ret | 2;
-                               case TokenType.Method:
-                                       return ret | 3;
-                               case TokenType.TypeSpec:
-                                       return ret | 4;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.HasSemantics:
-                               ret = token.RID << 1;
-                               switch (token.TokenType) {
-                               case TokenType.Event:
-                                       return ret | 0;
-                               case TokenType.Property:
-                                       return ret | 1;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.MethodDefOrRef:
-                               ret = token.RID << 1;
-                               switch (token.TokenType) {
-                               case TokenType.Method:
-                                       return ret | 0;
-                               case TokenType.MemberRef:
-                                       return ret | 1;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.MemberForwarded:
-                               ret = token.RID << 1;
-                               switch (token.TokenType) {
-                               case TokenType.Field:
-                                       return ret | 0;
-                               case TokenType.Method:
-                                       return ret | 1;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.Implementation:
-                               ret = token.RID << 2;
-                               switch (token.TokenType) {
-                               case TokenType.File:
-                                       return ret | 0;
-                               case TokenType.AssemblyRef:
-                                       return ret | 1;
-                               case TokenType.ExportedType:
-                                       return ret | 2;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.CustomAttributeType:
-                               ret = token.RID << 3;
-                               switch (token.TokenType) {
-                               case TokenType.Method:
-                                       return ret | 2;
-                               case TokenType.MemberRef:
-                                       return ret | 3;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.ResolutionScope:
-                               ret = token.RID << 2;
-                               switch (token.TokenType) {
-                               case TokenType.Module:
-                                       return ret | 0;
-                               case TokenType.ModuleRef:
-                                       return ret | 1;
-                               case TokenType.AssemblyRef:
-                                       return ret | 2;
-                               case TokenType.TypeRef:
-                                       return ret | 3;
-                               default:
-                                       goto exit;
-                               }
-                       case CodedIndex.TypeOrMethodDef:
-                               ret = token.RID << 1;
-                               switch (token.TokenType) {
-                               case TokenType.TypeDef:
-                                       return ret | 0;
-                               case TokenType.Method:
-                                       return ret | 1;
-                               default:
-                                       goto exit;
-                               }
-                       default:
-                               goto exit;
-                       }
-               exit:
-                       throw new ArgumentException ();
-               }
-#endif
-
-               public static int GetSize (this CodedIndex self, Func<Table, int> counter)
-               {
-                       int bits;
-                       Table [] tables;
-
-                       switch (self) {
-                       case CodedIndex.TypeDefOrRef:
-                               bits = 2;
-                               tables = new [] { Table.TypeDef, Table.TypeRef, Table.TypeSpec };
-                               break;
-                       case CodedIndex.HasConstant:
-                               bits = 2;
-                               tables = new [] { Table.Field, Table.Param, Table.Property };
-                               break;
-                       case CodedIndex.HasCustomAttribute:
-                               bits = 5;
-                               tables = new [] {
-                                       Table.Method, Table.Field, Table.TypeRef, Table.TypeDef, Table.Param, Table.InterfaceImpl, Table.MemberRef,
-                                       Table.Module, Table.DeclSecurity, Table.Property, Table.Event, Table.StandAloneSig, Table.ModuleRef,
-                                       Table.TypeSpec, Table.Assembly, Table.AssemblyRef, Table.File, Table.ExportedType,
-                                       Table.ManifestResource, Table.GenericParam
-                               };
-                               break;
-                       case CodedIndex.HasFieldMarshal:
-                               bits = 1;
-                               tables = new [] { Table.Field, Table.Param };
-                               break;
-                       case CodedIndex.HasDeclSecurity:
-                               bits = 2;
-                               tables = new [] { Table.TypeDef, Table.Method, Table.Assembly };
-                               break;
-                       case CodedIndex.MemberRefParent:
-                               bits = 3;
-                               tables = new [] { Table.TypeDef, Table.TypeRef, Table.ModuleRef, Table.Method, Table.TypeSpec };
-                               break;
-                       case CodedIndex.HasSemantics:
-                               bits = 1;
-                               tables = new [] { Table.Event, Table.Property };
-                               break;
-                       case CodedIndex.MethodDefOrRef:
-                               bits = 1;
-                               tables = new [] { Table.Method, Table.MemberRef };
-                               break;
-                       case CodedIndex.MemberForwarded:
-                               bits = 1;
-                               tables = new [] { Table.Field, Table.Method };
-                               break;
-                       case CodedIndex.Implementation:
-                               bits = 2;
-                               tables = new [] { Table.File, Table.AssemblyRef, Table.ExportedType };
-                               break;
-                       case CodedIndex.CustomAttributeType:
-                               bits = 3;
-                               tables = new [] { Table.Method, Table.MemberRef };
-                               break;
-                       case CodedIndex.ResolutionScope:
-                               bits = 2;
-                               tables = new [] { Table.Module, Table.ModuleRef, Table.AssemblyRef, Table.TypeRef };
-                               break;
-                       case CodedIndex.TypeOrMethodDef:
-                               bits = 1;
-                               tables = new [] { Table.TypeDef, Table.Method };
-                               break;
-                       default:
-                               throw new ArgumentException ();
-                       }
-
-                       int max = 0;
-
-                       for (int i = 0; i < tables.Length; i++) {
-                               max = System.Math.Max (counter (tables [i]), max);
-                       }
-
-                       return max < (1 << (16 - bits)) ? 2 : 4;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/BinaryStreamReader.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/BinaryStreamReader.cs
deleted file mode 100644 (file)
index ec2477c..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-//
-// BinaryStreamReader.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.IO;
-
-namespace Mono.Cecil.PE {
-
-       class BinaryStreamReader : BinaryReader {
-
-               public BinaryStreamReader (Stream stream)
-                       : base (stream)
-               {
-               }
-
-               protected void Advance (int bytes)
-               {
-                       BaseStream.Seek (bytes, SeekOrigin.Current);
-               }
-
-               protected DataDirectory ReadDataDirectory ()
-               {
-                       return new DataDirectory (ReadUInt32 (), ReadUInt32 ());
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/BinaryStreamWriter.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/BinaryStreamWriter.cs
deleted file mode 100644 (file)
index 2bf6ccc..0000000
+++ /dev/null
@@ -1,96 +0,0 @@
-//
-// BinaryStreamWriter.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.IO;
-
-#if !READ_ONLY
-
-namespace Mono.Cecil.PE {
-
-       class BinaryStreamWriter : BinaryWriter {
-
-               public BinaryStreamWriter (Stream stream)
-                       : base (stream)
-               {
-               }
-
-               public void WriteByte (byte value)
-               {
-                       Write (value);
-               }
-
-               public void WriteUInt16 (ushort value)
-               {
-                       Write (value);
-               }
-
-               public void WriteInt16 (short value)
-               {
-                       Write (value);
-               }
-
-               public void WriteUInt32 (uint value)
-               {
-                       Write (value);
-               }
-
-               public void WriteInt32 (int value)
-               {
-                       Write (value);
-               }
-
-               public void WriteUInt64 (ulong value)
-               {
-                       Write (value);
-               }
-
-               public void WriteBytes (byte [] bytes)
-               {
-                       Write (bytes);
-               }
-
-               public void WriteDataDirectory (DataDirectory directory)
-               {
-                       Write (directory.VirtualAddress);
-                       Write (directory.Size);
-               }
-
-               public void WriteBuffer (ByteBuffer buffer)
-               {
-                       Write (buffer.buffer, 0, buffer.length);
-               }
-
-               protected void Advance (int bytes)
-               {
-                       BaseStream.Seek (bytes, SeekOrigin.Current);
-               }
-       }
-}
-
-#endif
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/ByteBuffer.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/ByteBuffer.cs
deleted file mode 100644 (file)
index c7ae7ae..0000000
+++ /dev/null
@@ -1,359 +0,0 @@
-//
-// ByteBuffer.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil.PE {
-
-       class ByteBuffer {
-
-               internal byte [] buffer;
-               internal int length;
-               internal int position;
-
-               public ByteBuffer ()
-               {
-                       this.buffer = Empty<byte>.Array;
-               }
-
-               public ByteBuffer (int length)
-               {
-                       this.buffer = new byte [length];
-               }
-
-               public ByteBuffer (byte [] buffer)
-               {
-                       this.buffer = buffer ?? Empty<byte>.Array;
-                       this.length = this.buffer.Length;
-               }
-
-               public void Reset (byte [] buffer)
-               {
-                       this.buffer = buffer ?? Empty<byte>.Array;
-                       this.length = this.buffer.Length;
-               }
-
-               public void Advance (int length)
-               {
-                       position += length;
-               }
-
-               public byte ReadByte ()
-               {
-                       return buffer [position++];
-               }
-
-               public sbyte ReadSByte ()
-               {
-                       return (sbyte) ReadByte ();
-               }
-
-               public byte [] ReadBytes (int length)
-               {
-                       var bytes = new byte [length];
-                       Buffer.BlockCopy (buffer, position, bytes, 0, length);
-                       position += length;
-                       return bytes;
-               }
-
-               public ushort ReadUInt16 ()
-               {
-                       ushort value = (ushort) (buffer [position]
-                               | (buffer [position + 1] << 8));
-                       position += 2;
-                       return value;
-               }
-
-               public short ReadInt16 ()
-               {
-                       return (short) ReadUInt16 ();
-               }
-
-               public uint ReadUInt32 ()
-               {
-                       uint value = (uint) (buffer [position]
-                               | (buffer [position + 1] << 8)
-                               | (buffer [position + 2] << 16)
-                               | (buffer [position + 3] << 24));
-                       position += 4;
-                       return value;
-               }
-
-               public int ReadInt32 ()
-               {
-                       return (int) ReadUInt32 ();
-               }
-
-               public ulong ReadUInt64 ()
-               {
-                       uint low = ReadUInt32 ();
-                       uint high = ReadUInt32 ();
-
-                       return (((ulong) high) << 32) | low;
-               }
-
-               public long ReadInt64 ()
-               {
-                       return (long) ReadUInt64 ();
-               }
-
-               public uint ReadCompressedUInt32 ()
-               {
-                       byte first = ReadByte ();
-                       if ((first & 0x80) == 0)
-                               return first;
-
-                       if ((first & 0x40) == 0)
-                               return ((uint) (first & ~0x80) << 8)
-                                       | ReadByte ();
-
-                       return ((uint) (first & ~0xc0) << 24)
-                               | (uint) ReadByte () << 16
-                               | (uint) ReadByte () << 8
-                               | ReadByte ();
-               }
-
-               public int ReadCompressedInt32 ()
-               {
-                       var value = (int) (ReadCompressedUInt32 () >> 1);
-                       if ((value & 1) == 0)
-                               return value;
-                       if (value < 0x40)
-                               return value - 0x40;
-                       if (value < 0x2000)
-                               return value - 0x2000;
-                       if (value < 0x10000000)
-                               return value - 0x10000000;
-                       return value - 0x20000000;
-               }
-
-               public float ReadSingle ()
-               {
-                       if (!BitConverter.IsLittleEndian) {
-                               var bytes = ReadBytes (4);
-                               Array.Reverse (bytes);
-                               return BitConverter.ToSingle (bytes, 0);
-                       }
-
-                       float value = BitConverter.ToSingle (buffer, position);
-                       position += 4;
-                       return value;
-               }
-
-               public double ReadDouble ()
-               {
-                       if (!BitConverter.IsLittleEndian) {
-                               var bytes = ReadBytes (8);
-                               Array.Reverse (bytes);
-                               return BitConverter.ToDouble (bytes, 0);
-                       }
-
-                       double value = BitConverter.ToDouble (buffer, position);
-                       position += 8;
-                       return value;
-               }
-
-#if !READ_ONLY
-
-               public void WriteByte (byte value)
-               {
-                       if (position == buffer.Length)
-                               Grow (1);
-
-                       buffer [position++] = value;
-
-                       if (position > length)
-                               length = position;
-               }
-
-               public void WriteSByte (sbyte value)
-               {
-                       WriteByte ((byte) value);
-               }
-
-               public void WriteUInt16 (ushort value)
-               {
-                       if (position + 2 > buffer.Length)
-                               Grow (2);
-
-                       buffer [position++] = (byte) value;
-                       buffer [position++] = (byte) (value >> 8);
-
-                       if (position > length)
-                               length = position;
-               }
-
-               public void WriteInt16 (short value)
-               {
-                       WriteUInt16 ((ushort) value);
-               }
-
-               public void WriteUInt32 (uint value)
-               {
-                       if (position + 4 > buffer.Length)
-                               Grow (4);
-
-                       buffer [position++] = (byte) value;
-                       buffer [position++] = (byte) (value >> 8);
-                       buffer [position++] = (byte) (value >> 16);
-                       buffer [position++] = (byte) (value >> 24);
-
-                       if (position > length)
-                               length = position;
-               }
-
-               public void WriteInt32 (int value)
-               {
-                       WriteUInt32 ((uint) value);
-               }
-
-               public void WriteUInt64 (ulong value)
-               {
-                       if (position + 8 > buffer.Length)
-                               Grow (8);
-
-                       buffer [position++] = (byte) value;
-                       buffer [position++] = (byte) (value >> 8);
-                       buffer [position++] = (byte) (value >> 16);
-                       buffer [position++] = (byte) (value >> 24);
-                       buffer [position++] = (byte) (value >> 32);
-                       buffer [position++] = (byte) (value >> 40);
-                       buffer [position++] = (byte) (value >> 48);
-                       buffer [position++] = (byte) (value >> 56);
-
-                       if (position > length)
-                               length = position;
-               }
-
-               public void WriteInt64 (long value)
-               {
-                       WriteUInt64 ((ulong) value);
-               }
-
-               public void WriteCompressedUInt32 (uint value)
-               {
-                       if (value < 0x80)
-                               WriteByte ((byte) value);
-                       else if (value < 0x4000) {
-                               WriteByte ((byte) (0x80 | (value >> 8)));
-                               WriteByte ((byte) (value & 0xff));
-                       } else {
-                               WriteByte ((byte) ((value >> 24) | 0xc0));
-                               WriteByte ((byte) ((value >> 16) & 0xff));
-                               WriteByte ((byte) ((value >> 8) & 0xff));
-                               WriteByte ((byte) (value & 0xff));
-                       }
-               }
-
-               public void WriteCompressedInt32 (int value)
-               {
-                       if (value >= 0) {
-                               WriteCompressedUInt32 ((uint) (value << 1));
-                               return;
-                       }
-
-                       if (value > -0x40)
-                               value = 0x40 + value;
-                       else if (value >= -0x2000)
-                               value = 0x2000 + value;
-                       else if (value >= -0x20000000)
-                               value = 0x20000000 + value;
-
-                       WriteCompressedUInt32 ((uint) ((value << 1) | 1));
-               }
-
-               public void WriteBytes (byte [] bytes)
-               {
-                       var length = bytes.Length;
-                       if (position + length > buffer.Length)
-                               Grow (length);
-
-                       Buffer.BlockCopy (bytes, 0, buffer, position, length);
-                       position += length;
-
-                       if (position > this.length)
-                               this.length = position;
-               }
-
-               public void WriteBytes (int length)
-               {
-                       if (position + length > buffer.Length)
-                               Grow (length);
-
-                       position += length;
-
-                       if (position > this.length)
-                               this.length = position;
-               }
-
-               public void WriteBytes (ByteBuffer buffer)
-               {
-                       if (position + buffer.length > this.buffer.Length)
-                               Grow (buffer.length);
-
-                       Buffer.BlockCopy (buffer.buffer, 0, this.buffer, position, buffer.length);
-                       position += buffer.length;
-
-                       if (position > this.length)
-                               this.length = position;
-               }
-
-               public void WriteSingle (float value)
-               {
-                       var bytes = BitConverter.GetBytes (value);
-
-                       if (!BitConverter.IsLittleEndian)
-                               Array.Reverse (bytes);
-
-                       WriteBytes (bytes);
-               }
-
-               public void WriteDouble (double value)
-               {
-                       var bytes = BitConverter.GetBytes (value);
-
-                       if (!BitConverter.IsLittleEndian)
-                               Array.Reverse (bytes);
-
-                       WriteBytes (bytes);
-               }
-
-               void Grow (int desired)
-               {
-                       var current = this.buffer;
-                       var current_length = current.Length;
-
-                       var buffer = new byte [System.Math.Max (current_length + desired, current_length * 2)];
-                       Buffer.BlockCopy (current, 0, buffer, 0, current_length);
-                       this.buffer = buffer;
-               }
-
-#endif
-
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/ByteBufferEqualityComparer.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/ByteBufferEqualityComparer.cs
deleted file mode 100644 (file)
index 70e8916..0000000
+++ /dev/null
@@ -1,78 +0,0 @@
-//
-// ByteBufferEqualityComparer.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-
-namespace Mono.Cecil.PE {
-
-       sealed class ByteBufferEqualityComparer : IEqualityComparer<ByteBuffer> {
-
-               public bool Equals (ByteBuffer x, ByteBuffer y)
-               {
-                       if (x.length != y.length)
-                               return false;
-
-                       var x_buffer = x.buffer;
-                       var y_buffer = y.buffer;
-
-                       for (int i = 0; i < x.length; i++)
-                               if (x_buffer [i] != y_buffer [i])
-                                       return false;
-
-                       return true;
-               }
-
-               public int GetHashCode (ByteBuffer buffer)
-               {
-#if !BYTE_BUFFER_WELL_DISTRIBUTED_HASH
-                       var hash = 0;
-                       var bytes = buffer.buffer;
-                       for (int i = 0; i < buffer.length; i++)
-                               hash = (hash * 37) ^ bytes [i];
-
-                       return hash;
-#else
-                       const uint p = 16777619;
-                       uint hash = 2166136261;
-
-                       var bytes = buffer.buffer;
-                       for (int i = 0; i < buffer.length; i++)
-                           hash = (hash ^ bytes [i]) * p;
-
-                       hash += hash << 13;
-                       hash ^= hash >> 7;
-                       hash += hash << 3;
-                       hash ^= hash >> 17;
-                       hash += hash << 5;
-
-                       return (int) hash;
-#endif
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/DataDirectory.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/DataDirectory.cs
deleted file mode 100644 (file)
index fedd0e2..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-//
-// DataDirectory.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using RVA = System.UInt32;
-
-namespace Mono.Cecil.PE {
-
-       struct DataDirectory {
-
-               public readonly RVA VirtualAddress;
-               public readonly uint Size;
-
-               public bool IsZero {
-                       get { return VirtualAddress == 0 && Size == 0; }
-               }
-
-               public DataDirectory (RVA rva, uint size)
-               {
-                       this.VirtualAddress = rva;
-                       this.Size = size;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/Image.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/Image.cs
deleted file mode 100644 (file)
index 9a04494..0000000
+++ /dev/null
@@ -1,159 +0,0 @@
-//
-// Image.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono;
-using Mono.Cecil.Cil;
-using Mono.Cecil.Metadata;
-
-using RVA = System.UInt32;
-
-namespace Mono.Cecil.PE {
-
-       sealed class Image {
-
-               public ModuleKind Kind;
-               public TargetRuntime Runtime;
-               public TargetArchitecture Architecture;
-               public string FileName;
-
-               public Section [] Sections;
-
-               public Section MetadataSection;
-
-               public uint EntryPointToken;
-               public ModuleAttributes Attributes;
-
-               public DataDirectory Debug;
-               public DataDirectory Resources;
-
-               public StringHeap StringHeap;
-               public BlobHeap BlobHeap;
-               public UserStringHeap UserStringHeap;
-               public GuidHeap GuidHeap;
-               public TableHeap TableHeap;
-
-               readonly int [] coded_index_sizes = new int [13];
-
-               readonly Func<Table, int> counter;
-
-               public Image ()
-               {
-                       counter = GetTableLength;
-               }
-
-               public bool HasTable (Table table)
-               {
-                       return GetTableLength (table) > 0;
-               }
-
-               public int GetTableLength (Table table)
-               {
-                       return (int) TableHeap [table].Length;
-               }
-
-               public int GetTableIndexSize (Table table)
-               {
-                       return GetTableLength (table) < 65536 ? 2 : 4;
-               }
-
-               public int GetCodedIndexSize (CodedIndex coded_index)
-               {
-                       var index = (int) coded_index;
-                       var size = coded_index_sizes [index];
-                       if (size != 0)
-                               return size;
-
-                       return coded_index_sizes [index] = coded_index.GetSize (counter);
-               }
-
-               public uint ResolveVirtualAddress (RVA rva)
-               {
-                       var section = GetSectionAtVirtualAddress (rva);
-                       if (section == null)
-                               throw new ArgumentOutOfRangeException ();
-
-                       return ResolveVirtualAddressInSection (rva, section);
-               }
-
-               public uint ResolveVirtualAddressInSection (RVA rva, Section section)
-               {
-                       return rva + section.PointerToRawData - section.VirtualAddress;
-               }
-
-               public Section GetSection (string name)
-               {
-                       var sections = this.Sections;
-                       for (int i = 0; i < sections.Length; i++) {
-                               var section = sections [i];
-                               if (section.Name == name)
-                                       return section;
-                       }
-
-                       return null;
-               }
-
-               public Section GetSectionAtVirtualAddress (RVA rva)
-               {
-                       var sections = this.Sections;
-                       for (int i = 0; i < sections.Length; i++) {
-                               var section = sections [i];
-                               if (rva >= section.VirtualAddress && rva < section.VirtualAddress + section.SizeOfRawData)
-                                       return section;
-                       }
-
-                       return null;
-               }
-
-               public ImageDebugDirectory GetDebugHeader (out byte [] header)
-               {
-                       var section = GetSectionAtVirtualAddress (Debug.VirtualAddress);
-                       var buffer = new ByteBuffer (section.Data);
-                       buffer.position = (int) (Debug.VirtualAddress - section.VirtualAddress);
-
-                       var directory = new ImageDebugDirectory {
-                               Characteristics = buffer.ReadInt32 (),
-                               TimeDateStamp = buffer.ReadInt32 (),
-                               MajorVersion = buffer.ReadInt16 (),
-                               MinorVersion = buffer.ReadInt16 (),
-                               Type = buffer.ReadInt32 (),
-                               SizeOfData = buffer.ReadInt32 (),
-                               AddressOfRawData = buffer.ReadInt32 (),
-                               PointerToRawData = buffer.ReadInt32 (),
-                       };
-
-                       buffer.position = (int) (directory.PointerToRawData - section.PointerToRawData);
-
-                       header = new byte [directory.SizeOfData];
-                       Buffer.BlockCopy (buffer.buffer, buffer.position, header, 0, header.Length);
-
-                       return directory;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/ImageReader.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/ImageReader.cs
deleted file mode 100644 (file)
index 734b00a..0000000
+++ /dev/null
@@ -1,676 +0,0 @@
-//
-// ImageReader.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.IO;
-
-using Mono.Cecil.Metadata;
-
-using RVA = System.UInt32;
-
-namespace Mono.Cecil.PE {
-
-       sealed class ImageReader : BinaryStreamReader {
-
-               readonly Image image;
-
-               DataDirectory cli;
-               DataDirectory metadata;
-
-               public ImageReader (Stream stream)
-                       : base (stream)
-               {
-                       image = new Image ();
-
-                       image.FileName = stream.GetFullyQualifiedName ();
-               }
-
-               void MoveTo (DataDirectory directory)
-               {
-                       BaseStream.Position = image.ResolveVirtualAddress (directory.VirtualAddress);
-               }
-
-               void MoveTo (uint position)
-               {
-                       BaseStream.Position = position;
-               }
-
-               void ReadImage ()
-               {
-                       if (BaseStream.Length < 128)
-                               throw new BadImageFormatException ();
-
-                       // - DOSHeader
-
-                       // PE                                   2
-                       // Start                                58
-                       // Lfanew                               4
-                       // End                                  64
-
-                       if (ReadUInt16 () != 0x5a4d)
-                               throw new BadImageFormatException ();
-
-                       Advance (58);
-
-                       MoveTo (ReadUInt32 ());
-
-                       if (ReadUInt32 () != 0x00004550)
-                               throw new BadImageFormatException ();
-
-                       // - PEFileHeader
-
-                       // Machine                              2
-                       image.Architecture = ReadArchitecture ();
-
-                       // NumberOfSections             2
-                       ushort sections = ReadUInt16 ();
-
-                       // TimeDateStamp                4
-                       // PointerToSymbolTable 4
-                       // NumberOfSymbols              4
-                       // OptionalHeaderSize   2
-                       Advance (14);
-
-                       // Characteristics              2
-                       ushort characteristics = ReadUInt16 ();
-
-                       ushort subsystem;
-                       ReadOptionalHeaders (out subsystem);
-                       ReadSections (sections);
-                       ReadCLIHeader ();
-                       ReadMetadata ();
-
-                       image.Kind = GetModuleKind (characteristics, subsystem);
-               }
-
-               TargetArchitecture ReadArchitecture ()
-               {
-                       var machine = ReadUInt16 ();
-                       switch (machine) {
-                       case 0x014c:
-                               return TargetArchitecture.I386;
-                       case 0x8664:
-                               return TargetArchitecture.AMD64;
-                       case 0x0200:
-                               return TargetArchitecture.IA64;
-                       }
-
-                       throw new NotSupportedException ();
-               }
-
-               static ModuleKind GetModuleKind (ushort characteristics, ushort subsystem)
-               {
-                       if ((characteristics & 0x2000) != 0) // ImageCharacteristics.Dll
-                               return ModuleKind.Dll;
-
-                       if (subsystem == 0x2 || subsystem == 0x9) // SubSystem.WindowsGui || SubSystem.WindowsCeGui
-                               return ModuleKind.Windows;
-
-                       return ModuleKind.Console;
-               }
-
-               void ReadOptionalHeaders (out ushort subsystem)
-               {
-                       // - PEOptionalHeader
-                       //   - StandardFieldsHeader
-
-                       // Magic                                2
-                       bool pe64 = ReadUInt16 () == 0x20b;
-
-                       //                                              pe32 || pe64
-
-                       // LMajor                               1
-                       // LMinor                               1
-                       // CodeSize                             4
-                       // InitializedDataSize  4
-                       // UninitializedDataSize4
-                       // EntryPointRVA                4
-                       // BaseOfCode                   4
-                       // BaseOfData                   4 || 0
-
-                       //   - NTSpecificFieldsHeader
-
-                       // ImageBase                    4 || 8
-                       // SectionAlignment             4
-                       // FileAlignement               4
-                       // OSMajor                              2
-                       // OSMinor                              2
-                       // UserMajor                    2
-                       // UserMinor                    2
-                       // SubSysMajor                  2
-                       // SubSysMinor                  2
-                       // Reserved                             4
-                       // ImageSize                    4
-                       // HeaderSize                   4
-                       // FileChecksum                 4
-                       Advance (66);
-
-                       // SubSystem                    2
-                       subsystem = ReadUInt16 ();
-
-                       // DLLFlags                             2
-                       // StackReserveSize             4 || 8
-                       // StackCommitSize              4 || 8
-                       // HeapReserveSize              4 || 8
-                       // HeapCommitSize               4 || 8
-                       // LoaderFlags                  4
-                       // NumberOfDataDir              4
-
-                       //   - DataDirectoriesHeader
-
-                       // ExportTable                  8
-                       // ImportTable                  8
-                       // ResourceTable                8
-                       // ExceptionTable               8
-                       // CertificateTable             8
-                       // BaseRelocationTable  8
-
-                       Advance (pe64 ? 90 : 74);
-
-                       // Debug                                8
-                       image.Debug = ReadDataDirectory ();
-
-                       // Copyright                    8
-                       // GlobalPtr                    8
-                       // TLSTable                             8
-                       // LoadConfigTable              8
-                       // BoundImport                  8
-                       // IAT                                  8
-                       // DelayImportDescriptor8
-                       Advance (56);
-
-                       // CLIHeader                    8
-                       cli = ReadDataDirectory ();
-
-                       if (cli.IsZero)
-                               throw new BadImageFormatException ();
-
-                       // Reserved                             8
-                       Advance (8);
-               }
-
-               string ReadAlignedString (int length)
-               {
-                       int read = 0;
-                       var buffer = new char [length];
-                       while (read < length) {
-                               var current = ReadByte ();
-                               if (current == 0)
-                                       break;
-
-                               buffer [read++] = (char) current;
-                       }
-
-                       Advance (-1 + ((read + 4) & ~3) - read);
-
-                       return new string (buffer, 0, read);
-               }
-
-               string ReadZeroTerminatedString (int length)
-               {
-                       int read = 0;
-                       var buffer = new char [length];
-                       var bytes = ReadBytes (length);
-                       while (read < length) {
-                               var current = bytes [read];
-                               if (current == 0)
-                                       break;
-
-                               buffer [read++] = (char) current;
-                       }
-
-                       return new string (buffer, 0, read);
-               }
-
-               void ReadSections (ushort count)
-               {
-                       var sections = new Section [count];
-
-                       for (int i = 0; i < count; i++) {
-                               var section = new Section ();
-
-                               // Name
-                               section.Name = ReadZeroTerminatedString (8);
-
-                               // VirtualSize          4
-                               Advance (4);
-
-                               // VirtualAddress       4
-                               section.VirtualAddress = ReadUInt32 ();
-                               // SizeOfRawData        4
-                               section.SizeOfRawData = ReadUInt32 ();
-                               // PointerToRawData     4
-                               section.PointerToRawData = ReadUInt32 ();
-
-                               // PointerToRelocations         4
-                               // PointerToLineNumbers         4
-                               // NumberOfRelocations          2
-                               // NumberOfLineNumbers          2
-                               // Characteristics                      4
-                               Advance (16);
-
-                               sections [i] = section;
-
-                               ReadSectionData (section);
-                       }
-
-                       image.Sections = sections;
-               }
-
-               void ReadSectionData (Section section)
-               {
-                       var position = BaseStream.Position;
-
-                       MoveTo (section.PointerToRawData);
-
-                       var length = (int) section.SizeOfRawData;
-                       var data = new byte [length];
-                       int offset = 0, read;
-
-                       while ((read = Read (data, offset, length - offset)) > 0)
-                               offset += read;
-
-                       section.Data = data;
-
-                       BaseStream.Position = position;
-               }
-
-               void ReadCLIHeader ()
-               {
-                       MoveTo (cli);
-
-                       // - CLIHeader
-
-                       // Cb                                           4
-                       // MajorRuntimeVersion          2
-                       // MinorRuntimeVersion          2
-                       Advance (8);
-
-                       // Metadata                                     8
-                       metadata = ReadDataDirectory ();
-                       // Flags                                        4
-                       image.Attributes = (ModuleAttributes) ReadUInt32 ();
-                       // EntryPointToken                      4
-                       image.EntryPointToken = ReadUInt32 ();
-                       // Resources                            8
-                       image.Resources = ReadDataDirectory ();
-                       // StrongNameSignature          8
-                       // CodeManagerTable                     8
-                       // VTableFixups                         8
-                       // ExportAddressTableJumps      8
-                       // ManagedNativeHeader          8
-               }
-
-               void ReadMetadata ()
-               {
-                       MoveTo (metadata);
-
-                       if (ReadUInt32 () != 0x424a5342)
-                               throw new BadImageFormatException ();
-
-                       // MajorVersion                 2
-                       // MinorVersion                 2
-                       // Reserved                             4
-                       Advance (8);
-
-                       var version = ReadZeroTerminatedString (ReadInt32 ());
-                       image.Runtime = version.ParseRuntime ();
-
-                       // Flags                2
-                       Advance (2);
-
-                       var streams = ReadUInt16 ();
-
-                       var section = image.GetSectionAtVirtualAddress (metadata.VirtualAddress);
-                       if (section == null)
-                               throw new BadImageFormatException ();
-
-                       image.MetadataSection = section;
-
-                       for (int i = 0; i < streams; i++)
-                               ReadMetadataStream (section);
-
-                       if (image.TableHeap != null)
-                               ReadTableHeap ();
-               }
-
-               void ReadMetadataStream (Section section)
-               {
-                       // Offset               4
-                       uint start = metadata.VirtualAddress - section.VirtualAddress + ReadUInt32 (); // relative to the section start
-
-                       // Size                 4
-                       uint size = ReadUInt32 ();
-
-                       var name = ReadAlignedString (16);
-                       switch (name) {
-                       case "#~":
-                       case "#-":
-                               image.TableHeap = new TableHeap (section, start, size);
-                               break;
-                       case "#Strings":
-                               image.StringHeap = new StringHeap (section, start, size);
-                               break;
-                       case "#Blob":
-                               image.BlobHeap = new BlobHeap (section, start, size);
-                               break;
-                       case "#GUID":
-                               image.GuidHeap = new GuidHeap (section, start, size);
-                               break;
-                       case "#US":
-                               image.UserStringHeap = new UserStringHeap (section, start, size);
-                               break;
-                       }
-               }
-
-               void ReadTableHeap ()
-               {
-                       var heap = image.TableHeap;
-
-                       uint start = heap.Section.PointerToRawData;
-
-                       MoveTo (heap.Offset + start);
-
-                       // Reserved                     4
-                       // MajorVersion         1
-                       // MinorVersion         1
-                       Advance (6);
-
-                       // HeapSizes            1
-                       var sizes = ReadByte ();
-
-                       // Reserved2            1
-                       Advance (1);
-
-                       // Valid                        8
-                       heap.Valid = ReadInt64 ();
-
-                       // Sorted                       8
-                       heap.Sorted = ReadInt64 ();
-
-                       for (int i = 0; i < TableHeap.TableCount; i++) {
-                               if (!heap.HasTable ((Table) i))
-                                       continue;
-
-                               heap.Tables [i].Length = ReadUInt32 ();
-                       }
-
-                       SetIndexSize (image.StringHeap, sizes, 0x1);
-                       SetIndexSize (image.GuidHeap, sizes, 0x2);
-                       SetIndexSize (image.BlobHeap, sizes, 0x4);
-
-                       ComputeTableInformations ();
-               }
-
-               static void SetIndexSize (Heap heap, uint sizes, byte flag)
-               {
-                       if (heap == null)
-                               return;
-
-                       heap.IndexSize = (sizes & flag) > 0 ? 4 : 2;
-               }
-
-               int GetTableIndexSize (Table table)
-               {
-                       return image.GetTableIndexSize (table);
-               }
-
-               int GetCodedIndexSize (CodedIndex index)
-               {
-                       return image.GetCodedIndexSize (index);
-               }
-
-               void ComputeTableInformations ()
-               {
-                       uint offset = (uint) BaseStream.Position - image.MetadataSection.PointerToRawData; // header
-
-                       int stridx_size = image.StringHeap.IndexSize;
-                       int blobidx_size = image.BlobHeap != null ? image.BlobHeap.IndexSize : 2;
-
-                       var heap = image.TableHeap;
-                       var tables = heap.Tables;
-
-                       for (int i = 0; i < TableHeap.TableCount; i++) {
-                               var table = (Table) i;
-                               if (!heap.HasTable (table))
-                                       continue;
-
-                               int size;
-                               switch (table) {
-                               case Table.Module:
-                                       size = 2        // Generation
-                                               + stridx_size   // Name
-                                               + (image.GuidHeap.IndexSize * 3);       // Mvid, EncId, EncBaseId
-                                       break;
-                               case Table.TypeRef:
-                                       size = GetCodedIndexSize (CodedIndex.ResolutionScope)   // ResolutionScope
-                                               + (stridx_size * 2);    // Name, Namespace
-                                       break;
-                               case Table.TypeDef:
-                                       size = 4        // Flags
-                                               + (stridx_size * 2)     // Name, Namespace
-                                               + GetCodedIndexSize (CodedIndex.TypeDefOrRef)   // BaseType
-                                               + GetTableIndexSize (Table.Field)       // FieldList
-                                               + GetTableIndexSize (Table.Method);     // MethodList
-                                       break;
-                               case Table.FieldPtr:
-                                       size = GetTableIndexSize (Table.Field); // Field
-                                       break;
-                               case Table.Field:
-                                       size = 2        // Flags
-                                               + stridx_size   // Name
-                                               + blobidx_size; // Signature
-                                       break;
-                               case Table.MethodPtr:
-                                       size = GetTableIndexSize (Table.Method);        // Method
-                                       break;
-                               case Table.Method:
-                                       size = 8        // Rva 4, ImplFlags 2, Flags 2
-                                               + stridx_size   // Name
-                                               + blobidx_size  // Signature
-                                               + GetTableIndexSize (Table.Param); // ParamList
-                                       break;
-                               case Table.ParamPtr:
-                                       size = GetTableIndexSize (Table.Param); // Param
-                                       break;
-                               case Table.Param:
-                                       size = 4        // Flags 2, Sequence 2
-                                               + stridx_size;  // Name
-                                       break;
-                               case Table.InterfaceImpl:
-                                       size = GetTableIndexSize (Table.TypeDef)        // Class
-                                               + GetCodedIndexSize (CodedIndex.TypeDefOrRef);  // Interface
-                                       break;
-                               case Table.MemberRef:
-                                       size = GetCodedIndexSize (CodedIndex.MemberRefParent)   // Class
-                                               + stridx_size   // Name
-                                               + blobidx_size; // Signature
-                                       break;
-                               case Table.Constant:
-                                       size = 2        // Type
-                                               + GetCodedIndexSize (CodedIndex.HasConstant)    // Parent
-                                               + blobidx_size; // Value
-                                       break;
-                               case Table.CustomAttribute:
-                                       size = GetCodedIndexSize (CodedIndex.HasCustomAttribute)        // Parent
-                                               + GetCodedIndexSize (CodedIndex.CustomAttributeType)    // Type
-                                               + blobidx_size; // Value
-                                       break;
-                               case Table.FieldMarshal:
-                                       size = GetCodedIndexSize (CodedIndex.HasFieldMarshal)   // Parent
-                                               + blobidx_size; // NativeType
-                                       break;
-                               case Table.DeclSecurity:
-                                       size = 2        // Action
-                                               + GetCodedIndexSize (CodedIndex.HasDeclSecurity)        // Parent
-                                               + blobidx_size; // PermissionSet
-                                       break;
-                               case Table.ClassLayout:
-                                       size = 6        // PackingSize 2, ClassSize 4
-                                               + GetTableIndexSize (Table.TypeDef);    // Parent
-                                       break;
-                               case Table.FieldLayout:
-                                       size = 4        // Offset
-                                               + GetTableIndexSize (Table.Field);      // Field
-                                       break;
-                               case Table.StandAloneSig:
-                                       size = blobidx_size;    // Signature
-                                       break;
-                               case Table.EventMap:
-                                       size = GetTableIndexSize (Table.TypeDef)        // Parent
-                                               + GetTableIndexSize (Table.Event);      // EventList
-                                       break;
-                               case Table.EventPtr:
-                                       size = GetTableIndexSize (Table.Event); // Event
-                                       break;
-                               case Table.Event:
-                                       size = 2        // Flags
-                                               + stridx_size // Name
-                                               + GetCodedIndexSize (CodedIndex.TypeDefOrRef);  // EventType
-                                       break;
-                               case Table.PropertyMap:
-                                       size = GetTableIndexSize (Table.TypeDef)        // Parent
-                                               + GetTableIndexSize (Table.Property);   // PropertyList
-                                       break;
-                               case Table.PropertyPtr:
-                                       size = GetTableIndexSize (Table.Property);      // Property
-                                       break;
-                               case Table.Property:
-                                       size = 2        // Flags
-                                               + stridx_size   // Name
-                                               + blobidx_size; // Type
-                                       break;
-                               case Table.MethodSemantics:
-                                       size = 2        // Semantics
-                                               + GetTableIndexSize (Table.Method)      // Method
-                                               + GetCodedIndexSize (CodedIndex.HasSemantics);  // Association
-                                       break;
-                               case Table.MethodImpl:
-                                       size = GetTableIndexSize (Table.TypeDef)        // Class
-                                               + GetCodedIndexSize (CodedIndex.MethodDefOrRef) // MethodBody
-                                               + GetCodedIndexSize (CodedIndex.MethodDefOrRef);        // MethodDeclaration
-                                       break;
-                               case Table.ModuleRef:
-                                       size = stridx_size;     // Name
-                                       break;
-                               case Table.TypeSpec:
-                                       size = blobidx_size;    // Signature
-                                       break;
-                               case Table.ImplMap:
-                                       size = 2        // MappingFlags
-                                               + GetCodedIndexSize (CodedIndex.MemberForwarded)        // MemberForwarded
-                                               + stridx_size   // ImportName
-                                               + GetTableIndexSize (Table.ModuleRef);  // ImportScope
-                                       break;
-                               case Table.FieldRVA:
-                                       size = 4        // RVA
-                                               + GetTableIndexSize (Table.Field);      // Field
-                                       break;
-                               case Table.EncLog:
-                               case Table.EncMap:
-                                       size = 4;
-                                       break;
-                               case Table.Assembly:
-                                       size = 16 // HashAlgId 4, Version 4 * 2, Flags 4
-                                               + blobidx_size  // PublicKey
-                                               + (stridx_size * 2);    // Name, Culture
-                                       break;
-                               case Table.AssemblyProcessor:
-                                       size = 4;       // Processor
-                                       break;
-                               case Table.AssemblyOS:
-                                       size = 12;      // Platform 4, Version 2 * 4
-                                       break;
-                               case Table.AssemblyRef:
-                                       size = 12       // Version 2 * 4 + Flags 4
-                                               + (blobidx_size * 2)    // PublicKeyOrToken, HashValue
-                                               + (stridx_size * 2);    // Name, Culture
-                                       break;
-                               case Table.AssemblyRefProcessor:
-                                       size = 4        // Processor
-                                               + GetTableIndexSize (Table.AssemblyRef);        // AssemblyRef
-                                       break;
-                               case Table.AssemblyRefOS:
-                                       size = 12       // Platform 4, Version 2 * 4
-                                               + GetTableIndexSize (Table.AssemblyRef);        // AssemblyRef
-                                       break;
-                               case Table.File:
-                                       size = 4        // Flags
-                                               + stridx_size   // Name
-                                               + blobidx_size; // HashValue
-                                       break;
-                               case Table.ExportedType:
-                                       size = 8        // Flags 4, TypeDefId 4
-                                               + (stridx_size * 2)     // Name, Namespace
-                                               + GetCodedIndexSize (CodedIndex.Implementation);        // Implementation
-                                       break;
-                               case Table.ManifestResource:
-                                       size = 8        // Offset, Flags
-                                               + stridx_size   // Name
-                                               + GetCodedIndexSize (CodedIndex.Implementation);        // Implementation
-                                       break;
-                               case Table.NestedClass:
-                                       size = GetTableIndexSize (Table.TypeDef)        // NestedClass
-                                               + GetTableIndexSize (Table.TypeDef);    // EnclosingClass
-                                       break;
-                               case Table.GenericParam:
-                                       size = 4        // Number, Flags
-                                               + GetCodedIndexSize (CodedIndex.TypeOrMethodDef)        // Owner
-                                               + stridx_size;  // Name
-                                       break;
-                               case Table.MethodSpec:
-                                       size = GetCodedIndexSize (CodedIndex.MethodDefOrRef)    // Method
-                                               + blobidx_size; // Instantiation
-                                       break;
-                               case Table.GenericParamConstraint:
-                                       size = GetTableIndexSize (Table.GenericParam)   // Owner
-                                               + GetCodedIndexSize (CodedIndex.TypeDefOrRef);  // Constraint
-                                       break;
-                               default:
-                                       throw new NotSupportedException ();
-                               }
-
-                               tables [i].RowSize = (uint) size;
-                               tables [i].Offset = offset;
-
-                               offset += (uint) size * tables [i].Length;
-                       }
-               }
-
-               public static Image ReadImageFrom (Stream stream)
-               {
-                       try {
-                               var reader = new ImageReader (stream);
-                               reader.ReadImage ();
-                               return reader.image;
-                       } catch (EndOfStreamException e) {
-                               throw new BadImageFormatException (stream.GetFullyQualifiedName (), e);
-                       }
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/ImageWriter.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/ImageWriter.cs
deleted file mode 100644 (file)
index 6f921d9..0000000
+++ /dev/null
@@ -1,820 +0,0 @@
-//
-// ImageWriter.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.IO;
-
-#if !READ_ONLY
-
-using Mono.Cecil.Cil;
-using Mono.Cecil.Metadata;
-
-using RVA = System.UInt32;
-
-namespace Mono.Cecil.PE {
-
-       sealed class ImageWriter : BinaryStreamWriter {
-
-               readonly ModuleDefinition module;
-               readonly MetadataBuilder metadata;
-               readonly TextMap text_map;
-
-               ImageDebugDirectory debug_directory;
-               byte [] debug_data;
-
-               ByteBuffer win32_resources;
-
-               const uint pe_header_size = 0x178u;
-               const uint section_header_size = 0x28u;
-               const uint file_alignment = 0x200;
-               const uint section_alignment = 0x2000;
-               const ulong image_base = 0x00400000;
-
-               internal const RVA text_rva = 0x2000;
-
-               readonly bool pe64;
-               readonly uint time_stamp;
-
-               internal Section text;
-               internal Section rsrc;
-               internal Section reloc;
-
-               ushort sections;
-
-               ImageWriter (ModuleDefinition module, MetadataBuilder metadata, Stream stream)
-                       : base (stream)
-               {
-                       this.module = module;
-                       this.metadata = metadata;
-                       this.GetDebugHeader ();
-                       this.GetWin32Resources ();
-                       this.text_map = BuildTextMap ();
-                       this.sections = 2; // text + reloc
-                       this.pe64 = module.Architecture != TargetArchitecture.I386;
-                       this.time_stamp = (uint) DateTime.UtcNow.Subtract (new DateTime (1970, 1, 1)).TotalSeconds;
-               }
-
-               void GetDebugHeader ()
-               {
-                       var symbol_writer = metadata.symbol_writer;
-                       if (symbol_writer == null)
-                               return;
-
-                       if (!symbol_writer.GetDebugHeader (out debug_directory, out debug_data))
-                               debug_data = Empty<byte>.Array;
-               }
-
-               void GetWin32Resources ()
-               {
-                       var rsrc = GetImageResourceSection ();
-                       if (rsrc == null)
-                               return;
-
-                       var raw_resources = new byte [rsrc.Data.Length];
-                       Buffer.BlockCopy (rsrc.Data, 0, raw_resources, 0, rsrc.Data.Length);
-                       win32_resources = new ByteBuffer (raw_resources);
-               }
-
-               Section GetImageResourceSection ()
-               {
-                       if (!module.HasImage)
-                               return null;
-
-                       const string rsrc_section = ".rsrc";
-
-                       return module.Image.GetSection (rsrc_section);
-               }
-
-               public static ImageWriter CreateWriter (ModuleDefinition module, MetadataBuilder metadata, Stream stream)
-               {
-                       var writer = new ImageWriter (module, metadata, stream);
-                       writer.BuildSections ();
-                       return writer;
-               }
-
-               void BuildSections ()
-               {
-                       var has_win32_resources = win32_resources != null;
-                       if (has_win32_resources)
-                               sections++;
-
-                       text = CreateSection (".text", text_map.GetLength (), null);
-                       var previous = text;
-
-                       if (has_win32_resources) {
-                               rsrc = CreateSection (".rsrc", (uint) win32_resources.length, previous);
-
-                               PatchWin32Resources (win32_resources);
-                               previous = rsrc;
-                       }
-
-                       reloc = CreateSection (".reloc", 12u, previous);
-               }
-
-               Section CreateSection (string name, uint size, Section previous)
-               {
-                       return new Section {
-                               Name = name,
-                               VirtualAddress = previous != null
-                                       ? previous.VirtualAddress + Align (previous.VirtualSize, section_alignment)
-                                       : text_rva,
-                               VirtualSize = size,
-                               PointerToRawData = previous != null
-                                       ? previous.PointerToRawData + previous.SizeOfRawData
-                                       : Align (GetHeaderSize (), file_alignment),
-                               SizeOfRawData = Align (size, file_alignment)
-                       };
-               }
-
-               static uint Align (uint value, uint align)
-               {
-                       align--;
-                       return (value + align) & ~align;
-               }
-
-               void WriteDOSHeader ()
-               {
-                       Write (new byte [] {
-                               // dos header start
-                               0x4d, 0x5a, 0x90, 0x00, 0x03, 0x00, 0x00,
-                               0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0xff,
-                               0x00, 0x00, 0xb8, 0x00, 0x00, 0x00, 0x00,
-                               0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00,
-                               0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-                               0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-                               0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-                               0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-                               0x00, 0x00, 0x00, 0x00,
-                               // lfanew
-                               0x80, 0x00, 0x00, 0x00,
-                               // dos header end
-                               0x0e, 0x1f, 0xba, 0x0e, 0x00, 0xb4, 0x09,
-                               0xcd, 0x21, 0xb8, 0x01, 0x4c, 0xcd, 0x21,
-                               0x54, 0x68, 0x69, 0x73, 0x20, 0x70, 0x72,
-                               0x6f, 0x67, 0x72, 0x61, 0x6d, 0x20, 0x63,
-                               0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x20, 0x62,
-                               0x65, 0x20, 0x72, 0x75, 0x6e, 0x20, 0x69,
-                               0x6e, 0x20, 0x44, 0x4f, 0x53, 0x20, 0x6d,
-                               0x6f, 0x64, 0x65, 0x2e, 0x0d, 0x0d, 0x0a,
-                               0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-                               0x00
-                       });
-               }
-
-               void WritePEFileHeader ()
-               {
-                       WriteUInt32 (0x00004550);               // Magic
-                       WriteUInt16 (GetMachine ());    // Machine
-                       WriteUInt16 (sections);                 // NumberOfSections
-                       WriteUInt32 (time_stamp);
-                       WriteUInt32 (0);        // PointerToSymbolTable
-                       WriteUInt32 (0);        // NumberOfSymbols
-                       WriteUInt16 ((ushort) (!pe64 ? 0xe0 : 0xf0));   // SizeOfOptionalHeader
-
-                       // ExecutableImage | (pe64 ? 32BitsMachine : LargeAddressAware)
-                       var characteristics = (ushort) (0x0002 | (!pe64 ? 0x0100 : 0x0020));
-                       if (module.Kind == ModuleKind.Dll || module.Kind == ModuleKind.NetModule)
-                               characteristics |= 0x2000;
-                       WriteUInt16 (characteristics);  // Characteristics
-               }
-
-               ushort GetMachine ()
-               {
-                       switch (module.Architecture) {
-                       case TargetArchitecture.I386:
-                               return 0x014c;
-                       case TargetArchitecture.AMD64:
-                               return 0x8664;
-                       case TargetArchitecture.IA64:
-                               return 0x0200;
-                       }
-
-                       throw new NotSupportedException ();
-               }
-
-               void WriteOptionalHeaders ()
-               {
-                       WriteUInt16 ((ushort) (!pe64 ? 0x10b : 0x20b)); // Magic
-                       WriteByte (8);  // LMajor
-                       WriteByte (0);  // LMinor
-                       WriteUInt32 (text.SizeOfRawData);       // CodeSize
-                       WriteUInt32 (reloc.SizeOfRawData
-                               + (rsrc != null ? rsrc.SizeOfRawData : 0));     // InitializedDataSize
-                       WriteUInt32 (0);        // UninitializedDataSize
-
-                       var entry_point_rva = text_map.GetRVA (TextSegment.StartupStub);
-                       if (module.Architecture == TargetArchitecture.IA64)
-                               entry_point_rva += 0x20;
-                       WriteUInt32 (entry_point_rva); // EntryPointRVA
-                       WriteUInt32 (text_rva); // BaseOfCode
-
-                       if (!pe64) {
-                               WriteUInt32 (0);        // BaseOfData
-                               WriteUInt32 ((uint) image_base);        // ImageBase
-                       } else {
-                               WriteUInt64 (image_base);       // ImageBase
-                       }
-
-                       WriteUInt32 (section_alignment);        // SectionAlignment
-                       WriteUInt32 (file_alignment);           // FileAlignment
-
-                       WriteUInt16 (4);        // OSMajor
-                       WriteUInt16 (0);        // OSMinor
-                       WriteUInt16 (0);        // UserMajor
-                       WriteUInt16 (0);        // UserMinor
-                       WriteUInt16 (4);        // SubSysMajor
-                       WriteUInt16 (0);        // SubSysMinor
-                       WriteUInt32 (0);        // Reserved
-
-                       WriteUInt32 (reloc.VirtualAddress + Align (reloc.VirtualSize, section_alignment));      // ImageSize
-                       WriteUInt32 (text.PointerToRawData);    // HeaderSize
-
-                       WriteUInt32 (0);        // Checksum
-                       WriteUInt16 (GetSubSystem ());  // SubSystem
-                       WriteUInt16 (0x8540);   // DLLFlags
-
-                       const ulong stack_reserve = 0x100000;
-                       const ulong stack_commit = 0x1000;
-                       const ulong heap_reserve = 0x100000;
-                       const ulong heap_commit = 0x1000;
-
-                       if (!pe64) {
-                               WriteUInt32 ((uint) stack_reserve);
-                               WriteUInt32 ((uint) stack_commit);
-                               WriteUInt32 ((uint) heap_reserve);
-                               WriteUInt32 ((uint) heap_commit);
-                       } else {
-                               WriteUInt64 (stack_reserve);
-                               WriteUInt64 (stack_commit);
-                               WriteUInt64 (heap_reserve);
-                               WriteUInt64 (heap_commit);
-                       }
-
-                       WriteUInt32 (0);        // LoaderFlags
-                       WriteUInt32 (16);       // NumberOfDataDir
-
-                       WriteZeroDataDirectory ();      // ExportTable
-                       WriteDataDirectory (text_map.GetDataDirectory (TextSegment.ImportDirectory));   // ImportTable
-                       if (rsrc != null) {                                                     // ResourceTable
-                               WriteUInt32 (rsrc.VirtualAddress);
-                               WriteUInt32 (rsrc.VirtualSize);
-                       } else
-                               WriteZeroDataDirectory ();
-
-                       WriteZeroDataDirectory ();      // ExceptionTable
-                       WriteZeroDataDirectory ();      // CertificateTable
-                       WriteUInt32 (reloc.VirtualAddress);                     // BaseRelocationTable
-                       WriteUInt32 (reloc.VirtualSize);
-
-                       if (text_map.GetLength (TextSegment.DebugDirectory) > 0) {
-                               WriteUInt32 (text_map.GetRVA (TextSegment.DebugDirectory));
-                               WriteUInt32 (28u);
-                       } else
-                               WriteZeroDataDirectory ();
-
-                       WriteZeroDataDirectory ();      // Copyright
-                       WriteZeroDataDirectory ();      // GlobalPtr
-                       WriteZeroDataDirectory ();      // TLSTable
-                       WriteZeroDataDirectory ();      // LoadConfigTable
-                       WriteZeroDataDirectory ();      // BoundImport
-                       WriteDataDirectory (text_map.GetDataDirectory (TextSegment.ImportAddressTable));        // IAT
-                       WriteZeroDataDirectory ();      // DelayImportDesc
-                       WriteDataDirectory (text_map.GetDataDirectory (TextSegment.CLIHeader)); // CLIHeader
-                       WriteZeroDataDirectory ();      // Reserved
-               }
-
-               void WriteZeroDataDirectory ()
-               {
-                       WriteUInt32 (0);
-                       WriteUInt32 (0);
-               }
-
-               ushort GetSubSystem ()
-               {
-                       switch (module.Kind) {
-                       case ModuleKind.Console:
-                       case ModuleKind.Dll:
-                       case ModuleKind.NetModule:
-                               return 0x3;
-                       case ModuleKind.Windows:
-                               return 0x2;
-                       default:
-                               throw new ArgumentOutOfRangeException ();
-                       }
-               }
-
-               void WriteSectionHeaders ()
-               {
-                       WriteSection (text, 0x60000020);
-
-                       if (rsrc != null)
-                               WriteSection (rsrc, 0x40000040);
-
-                       WriteSection (reloc, 0x42000040);
-               }
-
-               void WriteSection (Section section, uint characteristics)
-               {
-                       var name = new byte [8];
-                       var sect_name = section.Name;
-                       for (int i = 0; i < sect_name.Length; i++)
-                               name [i] = (byte) sect_name [i];
-
-                       WriteBytes (name);
-                       WriteUInt32 (section.VirtualSize);
-                       WriteUInt32 (section.VirtualAddress);
-                       WriteUInt32 (section.SizeOfRawData);
-                       WriteUInt32 (section.PointerToRawData);
-                       WriteUInt32 (0);        // PointerToRelocations
-                       WriteUInt32 (0);        // PointerToLineNumbers
-                       WriteUInt16 (0);        // NumberOfRelocations
-                       WriteUInt16 (0);        // NumberOfLineNumbers
-                       WriteUInt32 (characteristics);
-               }
-
-               void MoveTo (uint pointer)
-               {
-                       BaseStream.Seek (pointer, SeekOrigin.Begin);
-               }
-
-               void MoveToRVA (Section section, RVA rva)
-               {
-                       BaseStream.Seek (section.PointerToRawData + rva - section.VirtualAddress, SeekOrigin.Begin);
-               }
-
-               void MoveToRVA (TextSegment segment)
-               {
-                       MoveToRVA (text, text_map.GetRVA (segment));
-               }
-
-               void WriteRVA (RVA rva)
-               {
-                       if (!pe64)
-                               WriteUInt32 (rva);
-                       else
-                               WriteUInt64 (rva);
-               }
-
-               void WriteText ()
-               {
-                       MoveTo (text.PointerToRawData);
-
-                       // ImportAddressTable
-
-                       WriteRVA (text_map.GetRVA (TextSegment.ImportHintNameTable));
-                       WriteRVA (0);
-
-                       // CLIHeader
-
-                       WriteUInt32 (0x48);
-                       WriteUInt16 (2);
-                       WriteUInt16 ((ushort) ((module.Runtime <= TargetRuntime.Net_1_1) ? 0 : 5));
-
-                       WriteUInt32 (text_map.GetRVA (TextSegment.MetadataHeader));
-                       WriteUInt32 (GetMetadataLength ());
-                       WriteUInt32 ((uint) module.Attributes);
-                       WriteUInt32 (metadata.entry_point.ToUInt32 ());
-                       WriteDataDirectory (text_map.GetDataDirectory (TextSegment.Resources));
-                       WriteDataDirectory (text_map.GetDataDirectory (TextSegment.StrongNameSignature));
-                       WriteZeroDataDirectory ();      // CodeManagerTable
-                       WriteZeroDataDirectory ();      // VTableFixups
-                       WriteZeroDataDirectory ();      // ExportAddressTableJumps
-                       WriteZeroDataDirectory ();      // ManagedNativeHeader
-
-                       // Code
-
-                       MoveToRVA (TextSegment.Code);
-                       WriteBuffer (metadata.code);
-
-                       // Resources
-
-                       MoveToRVA (TextSegment.Resources);
-                       WriteBuffer (metadata.resources);
-
-                       // Data
-
-                       if (metadata.data.length > 0) {
-                               MoveToRVA (TextSegment.Data);
-                               WriteBuffer (metadata.data);
-                       }
-
-                       // StrongNameSignature
-                       // stays blank
-
-                       // MetadataHeader
-
-                       MoveToRVA (TextSegment.MetadataHeader);
-                       WriteMetadataHeader ();
-
-                       WriteMetadata ();
-
-                       // DebugDirectory
-                       if (text_map.GetLength (TextSegment.DebugDirectory) > 0) {
-                               MoveToRVA (TextSegment.DebugDirectory);
-                               WriteDebugDirectory ();
-                       }
-
-                       // ImportDirectory
-                       MoveToRVA (TextSegment.ImportDirectory);
-                       WriteImportDirectory ();
-
-                       // StartupStub
-                       MoveToRVA (TextSegment.StartupStub);
-                       WriteStartupStub ();
-               }
-
-               uint GetMetadataLength ()
-               {
-                       return text_map.GetRVA (TextSegment.DebugDirectory) - text_map.GetRVA (TextSegment.MetadataHeader);
-               }
-
-               void WriteMetadataHeader ()
-               {
-                       WriteUInt32 (0x424a5342);       // Signature
-                       WriteUInt16 (1);        // MajorVersion
-                       WriteUInt16 (1);        // MinorVersion
-                       WriteUInt32 (0);        // Reserved
-
-                       var version = GetZeroTerminatedString (GetVersion ());
-                       WriteUInt32 ((uint) version.Length);
-                       WriteBytes (version);
-                       WriteUInt16 (0);        // Flags
-                       WriteUInt16 (GetStreamCount ());
-
-                       uint offset = text_map.GetRVA (TextSegment.TableHeap) - text_map.GetRVA (TextSegment.MetadataHeader);
-
-                       WriteStreamHeader (ref offset, TextSegment.TableHeap, "#~");
-                       WriteStreamHeader (ref offset, TextSegment.StringHeap, "#Strings");
-                       WriteStreamHeader (ref offset, TextSegment.UserStringHeap, "#US");
-                       WriteStreamHeader (ref offset, TextSegment.GuidHeap, "#GUID");
-                       WriteStreamHeader (ref offset, TextSegment.BlobHeap, "#Blob");
-               }
-
-               string GetVersion ()
-               {
-                       switch (module.Runtime) {
-                       case TargetRuntime.Net_1_0:
-                               return "v1.0.3705";
-                       case TargetRuntime.Net_1_1:
-                               return "v1.1.4322";
-                       case TargetRuntime.Net_2_0:
-                               return "v2.0.50727";
-                       case TargetRuntime.Net_4_0:
-                       default:
-                               return "v4.0.30319";
-                       }
-               }
-
-               ushort GetStreamCount ()
-               {
-                       return (ushort) (
-                               1       // #~
-                               + 1     // #Strings
-                               + (metadata.user_string_heap.IsEmpty ? 0 : 1)   // #US
-                               + 1     // GUID
-                               + (metadata.blob_heap.IsEmpty ? 0 : 1));        // #Blob
-               }
-
-               void WriteStreamHeader (ref uint offset, TextSegment heap, string name)
-               {
-                       var length = (uint) text_map.GetLength (heap);
-                       if (length == 0)
-                               return;
-
-                       WriteUInt32 (offset);
-                       WriteUInt32 (length);
-                       WriteBytes (GetZeroTerminatedString (name));
-                       offset += length;
-               }
-
-               static byte [] GetZeroTerminatedString (string @string)
-               {
-                       return GetString (@string, (@string.Length + 1 + 3) & ~3);
-               }
-
-               static byte [] GetSimpleString (string @string)
-               {
-                       return GetString (@string, @string.Length);
-               }
-
-               static byte [] GetString (string @string, int length)
-               {
-                       var bytes = new byte [length];
-                       for (int i = 0; i < @string.Length; i++)
-                               bytes [i] = (byte) @string [i];
-
-                       return bytes;
-               }
-
-               void WriteMetadata ()
-               {
-                       WriteHeap (TextSegment.TableHeap, metadata.table_heap);
-                       WriteHeap (TextSegment.StringHeap, metadata.string_heap);
-                       WriteHeap (TextSegment.UserStringHeap, metadata.user_string_heap);
-                       WriteGuidHeap ();
-                       WriteHeap (TextSegment.BlobHeap, metadata.blob_heap);
-               }
-
-               void WriteHeap (TextSegment heap, HeapBuffer buffer)
-               {
-                       if (buffer.IsEmpty)
-                               return;
-
-                       MoveToRVA (heap);
-                       WriteBuffer (buffer);
-               }
-
-               void WriteGuidHeap ()
-               {
-                       MoveToRVA (TextSegment.GuidHeap);
-                       WriteBytes (module.Mvid.ToByteArray ());
-               }
-
-               void WriteDebugDirectory ()
-               {
-                       WriteInt32 (debug_directory.Characteristics);
-                       WriteUInt32 (time_stamp);
-                       WriteInt16 (debug_directory.MajorVersion);
-                       WriteInt16 (debug_directory.MinorVersion);
-                       WriteInt32 (debug_directory.Type);
-                       WriteInt32 (debug_directory.SizeOfData);
-                       WriteInt32 (debug_directory.AddressOfRawData);
-                       WriteInt32 ((int) BaseStream.Position + 4);
-
-                       WriteBytes (debug_data);
-               }
-
-               void WriteImportDirectory ()
-               {
-                       WriteUInt32 (text_map.GetRVA (TextSegment.ImportDirectory) + 40);       // ImportLookupTable
-                       WriteUInt32 (0);        // DateTimeStamp
-                       WriteUInt32 (0);        // ForwarderChain
-                       WriteUInt32 (text_map.GetRVA (TextSegment.ImportHintNameTable) + 14);
-                       WriteUInt32 (text_map.GetRVA (TextSegment.ImportAddressTable));
-                       Advance (20);
-
-                       // ImportLookupTable
-                       WriteUInt32 (text_map.GetRVA (TextSegment.ImportHintNameTable));
-
-                       // ImportHintNameTable
-                       MoveToRVA (TextSegment.ImportHintNameTable);
-
-                       WriteUInt16 (0);        // Hint
-                       WriteBytes (GetRuntimeMain ());
-                       WriteByte (0);
-                       WriteBytes (GetSimpleString ("mscoree.dll"));
-                       WriteUInt16 (0);
-               }
-
-               byte [] GetRuntimeMain ()
-               {
-                       return module.Kind == ModuleKind.Dll || module.Kind == ModuleKind.NetModule
-                               ? GetSimpleString ("_CorDllMain")
-                               : GetSimpleString ("_CorExeMain");
-               }
-
-               void WriteStartupStub ()
-               {
-                       switch (module.Architecture) {
-                       case TargetArchitecture.I386:
-                               WriteUInt16 (0x25ff);
-                               WriteUInt32 ((uint) image_base + text_map.GetRVA (TextSegment.ImportAddressTable));
-                               return;
-                       case TargetArchitecture.AMD64:
-                               WriteUInt16 (0xa148);
-                               WriteUInt32 ((uint) image_base + text_map.GetRVA (TextSegment.ImportAddressTable));
-                               WriteUInt16 (0xe0ff);
-                               return;
-                       case TargetArchitecture.IA64:
-                               WriteBytes (new byte [] {
-                                       0x0b, 0x48, 0x00, 0x02, 0x18, 0x10, 0xa0, 0x40, 0x24, 0x30, 0x28, 0x00, 0x00, 0x00, 0x04, 0x00,
-                                       0x10, 0x08, 0x00, 0x12, 0x18, 0x10, 0x60, 0x50, 0x04, 0x80, 0x03, 0x00, 0x60, 0x00, 0x80, 0x00
-                               });
-                               WriteUInt32 ((uint) image_base + text_map.GetRVA (TextSegment.StartupStub));
-                               WriteUInt32 ((uint) image_base + text_rva);
-                               return;
-                       }
-               }
-
-               void WriteRsrc ()
-               {
-                       MoveTo (rsrc.PointerToRawData);
-                       WriteBuffer (win32_resources);
-               }
-
-               void WriteReloc ()
-               {
-                       MoveTo (reloc.PointerToRawData);
-
-                       var reloc_rva = text_map.GetRVA (TextSegment.StartupStub);
-                       reloc_rva += module.Architecture == TargetArchitecture.IA64 ? 0x20u : 2;
-                       var page_rva = reloc_rva & ~0xfffu;
-
-                       WriteUInt32 (page_rva); // PageRVA
-                       WriteUInt32 (0x000c);   // Block Size
-
-                       switch (module.Architecture) {
-                       case TargetArchitecture.I386:
-                               WriteUInt32 (0x3000 + reloc_rva - page_rva);
-                               break;
-                       case TargetArchitecture.AMD64:
-                               WriteUInt32 (0xa000 + reloc_rva - page_rva);
-                               break;
-                       case TargetArchitecture.IA64:
-                               WriteUInt16 ((ushort) (0xa000 + reloc_rva - page_rva));
-                               WriteUInt16 ((ushort) (0xa000 + reloc_rva - page_rva + 8));
-                               break;
-                       }
-
-                       WriteBytes (new byte [file_alignment - reloc.VirtualSize]);
-               }
-
-               public void WriteImage ()
-               {
-                       WriteDOSHeader ();
-                       WritePEFileHeader ();
-                       WriteOptionalHeaders ();
-                       WriteSectionHeaders ();
-                       WriteText ();
-                       if (rsrc != null)
-                               WriteRsrc ();
-                       WriteReloc ();
-               }
-
-               TextMap BuildTextMap ()
-               {
-                       var map = metadata.text_map;
-
-                       map.AddMap (TextSegment.Code, metadata.code.length, !pe64 ? 4 : 16);
-                       map.AddMap (TextSegment.Resources, metadata.resources.length, 8);
-                       map.AddMap (TextSegment.Data, metadata.data.length, 4);
-                       if (metadata.data.length > 0)
-                               metadata.table_heap.FixupData (map.GetRVA (TextSegment.Data));
-                       map.AddMap (TextSegment.StrongNameSignature, GetStrongNameLength (), 4);
-
-                       map.AddMap (TextSegment.MetadataHeader, GetMetadataHeaderLength ());
-                       map.AddMap (TextSegment.TableHeap, metadata.table_heap.length, 4);
-                       map.AddMap (TextSegment.StringHeap, metadata.string_heap.length, 4);
-                       map.AddMap (TextSegment.UserStringHeap, metadata.user_string_heap.IsEmpty ? 0 : metadata.user_string_heap.length, 4);
-                       map.AddMap (TextSegment.GuidHeap, 16);
-                       map.AddMap (TextSegment.BlobHeap, metadata.blob_heap.IsEmpty ? 0 : metadata.blob_heap.length, 4);
-
-                       int debug_dir_len = 0;
-                       if (!debug_data.IsNullOrEmpty ()) {
-                               const int debug_dir_header_len = 28;
-
-                               debug_directory.AddressOfRawData = (int) map.GetNextRVA (TextSegment.BlobHeap) + debug_dir_header_len;
-                               debug_dir_len = debug_data.Length + debug_dir_header_len;
-                       }
-
-                       map.AddMap (TextSegment.DebugDirectory, debug_dir_len, 4);
-
-                       RVA import_dir_rva = map.GetNextRVA (TextSegment.DebugDirectory);
-                       RVA import_hnt_rva = import_dir_rva + (!pe64 ? 48u : 52u);
-                       import_hnt_rva = (import_hnt_rva + 15u) & ~15u;
-                       uint import_dir_len = (import_hnt_rva - import_dir_rva) + 27u;
-
-                       RVA startup_stub_rva = import_dir_rva + import_dir_len;
-                       startup_stub_rva = module.Architecture == TargetArchitecture.IA64
-                               ? (startup_stub_rva + 15u) & ~15u
-                               : 2 + ((startup_stub_rva + 3u) & ~3u);
-
-                       map.AddMap (TextSegment.ImportDirectory, new Range (import_dir_rva, import_dir_len));
-                       map.AddMap (TextSegment.ImportHintNameTable, new Range (import_hnt_rva, 0));
-                       map.AddMap (TextSegment.StartupStub, new Range (startup_stub_rva, GetStartupStubLength ()));
-
-                       return map;
-               }
-
-               uint GetStartupStubLength ()
-               {
-                       switch (module.Architecture) {
-                       case TargetArchitecture.I386:
-                               return 6;
-                       case TargetArchitecture.AMD64:
-                               return 12;
-                       case TargetArchitecture.IA64:
-                               return 48;
-                       default:
-                               throw new InvalidOperationException ();
-                       }
-               }
-
-               int GetMetadataHeaderLength ()
-               {
-                       return
-                               // MetadataHeader
-                               40
-                               // #~ header
-                               + 12
-                               // #Strings header
-                               + 20
-                               // #US header
-                               + (metadata.user_string_heap.IsEmpty ? 0 : 12)
-                               // #GUID header
-                               + 16
-                               // #Blob header
-                               + (metadata.blob_heap.IsEmpty ? 0 : 16);
-               }
-
-               int GetStrongNameLength ()
-               {
-                       if ((module.Attributes & ModuleAttributes.StrongNameSigned) == 0)
-                               return 0;
-
-                       if (module.Assembly == null)
-                               throw new InvalidOperationException ();
-
-                       var public_key = module.Assembly.Name.PublicKey;
-
-                       if (public_key != null) {
-                               // in fx 2.0 the key may be from 384 to 16384 bits
-                               // so we must calculate the signature size based on
-                               // the size of the public key (minus the 32 byte header)
-                               int size = public_key.Length;
-                               if (size > 32)
-                                       return size - 32;
-                               // note: size == 16 for the ECMA "key" which is replaced
-                               // by the runtime with a 1024 bits key (128 bytes)
-                       }
-
-                       return 128; // default strongname signature size
-               }
-
-               public DataDirectory GetStrongNameSignatureDirectory ()
-               {
-                       return text_map.GetDataDirectory (TextSegment.StrongNameSignature);
-               }
-
-               public uint GetHeaderSize ()
-               {
-                       return pe_header_size + (sections * section_header_size);
-               }
-
-               void PatchWin32Resources (ByteBuffer resources)
-               {
-                       PatchResourceDirectoryTable (resources);
-               }
-
-               void PatchResourceDirectoryTable (ByteBuffer resources)
-               {
-                       resources.Advance (12);
-
-                       var entries = resources.ReadUInt16 () + resources.ReadUInt16 ();
-
-                       for (int i = 0; i < entries; i++)
-                               PatchResourceDirectoryEntry (resources);
-               }
-
-               void PatchResourceDirectoryEntry (ByteBuffer resources)
-               {
-                       resources.Advance (4);
-                       var child = resources.ReadUInt32 ();
-
-                       var position = resources.position;
-                       resources.position = (int) child & 0x7fffffff;
-
-                       if ((child & 0x80000000) != 0)
-                               PatchResourceDirectoryTable (resources);
-                       else
-                               PatchResourceDataEntry (resources);
-
-                       resources.position = position;
-               }
-
-               void PatchResourceDataEntry (ByteBuffer resources)
-               {
-                       var old_rsrc = GetImageResourceSection ();
-                       var rva = resources.ReadUInt32 ();
-                       resources.position -= 4;
-                       resources.WriteUInt32 (rva - old_rsrc.VirtualAddress + rsrc.VirtualAddress);
-               }
-       }
-}
-
-#endif
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/Section.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/Section.cs
deleted file mode 100644 (file)
index 6a4c7ba..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-//
-// Section.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using RVA = System.UInt32;
-
-namespace Mono.Cecil.PE {
-
-       sealed class Section {
-               public string Name;
-               public RVA VirtualAddress;
-               public uint VirtualSize;
-               public uint SizeOfRawData;
-               public uint PointerToRawData;
-               public byte [] Data;
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil.PE/TextMap.cs b/mcs/class/Mono.Cecil/Mono.Cecil.PE/TextMap.cs
deleted file mode 100644 (file)
index 047a4c1..0000000
+++ /dev/null
@@ -1,129 +0,0 @@
-//
-// TextMap.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-#if !READ_ONLY
-
-using RVA = System.UInt32;
-
-namespace Mono.Cecil.PE {
-
-       enum TextSegment {
-               ImportAddressTable,
-               CLIHeader,
-               Code,
-               Resources,
-               Data,
-               StrongNameSignature,
-
-               // Metadata
-               MetadataHeader,
-               TableHeap,
-               StringHeap,
-               UserStringHeap,
-               GuidHeap,
-               BlobHeap,
-               // End Metadata
-
-               DebugDirectory,
-               ImportDirectory,
-               ImportHintNameTable,
-               StartupStub,
-       }
-
-       sealed class TextMap {
-
-               readonly Range [] map = new Range [16 /*Enum.GetValues (typeof (TextSegment)).Length*/];
-
-               public void AddMap (TextSegment segment, int length)
-               {
-                       map [(int) segment] = new Range (GetStart (segment), (uint) length);
-               }
-
-               public void AddMap (TextSegment segment, int length, int align)
-               {
-                       align--;
-
-                       AddMap (segment, (length + align) & ~align);
-               }
-
-               public void AddMap (TextSegment segment, Range range)
-               {
-                       map [(int) segment] = range;
-               }
-
-               public Range GetRange (TextSegment segment)
-               {
-                       return map [(int) segment];
-               }
-
-               public DataDirectory GetDataDirectory (TextSegment segment)
-               {
-                       var range = map [(int) segment];
-
-                       return new DataDirectory (range.Length == 0 ? 0 : range.Start, range.Length);
-               }
-
-               public RVA GetRVA (TextSegment segment)
-               {
-                       return map [(int) segment].Start;
-               }
-
-               public RVA GetNextRVA (TextSegment segment)
-               {
-                       var i = (int) segment;
-                       return map [i].Start + map [i].Length;
-               }
-
-               public int GetLength (TextSegment segment)
-               {
-                       return (int) map [(int) segment].Length;
-               }
-
-               RVA GetStart (TextSegment segment)
-               {
-                       var index = (int) segment;
-                       return index == 0 ? ImageWriter.text_rva : ComputeStart (index);
-               }
-
-               RVA ComputeStart (int index)
-               {
-                       index--;
-                       return map [index].Start + map [index].Length;
-               }
-
-               public uint GetLength ()
-               {
-                       var range = map [(int) TextSegment.StartupStub];
-                       return range.Start - ImageWriter.text_rva + range.Length;
-               }
-       }
-}
-
-#endif
index 95bb7f353690eb55bd8fa2b60c930cab00fe598a..231d5d77bdcc63fb70c1b3fdf003a2596b3777e4 100644 (file)
-./Mono.Collections.Generic/Collection.cs
-./Mono.Collections.Generic/ReadOnlyCollection.cs
-./Mono.Cecil.PE/ImageWriter.cs
-./Mono.Cecil.PE/BinaryStreamWriter.cs
-./Mono.Cecil.PE/BinaryStreamReader.cs
-./Mono.Cecil.PE/DataDirectory.cs
-./Mono.Cecil.PE/ByteBuffer.cs
-./Mono.Cecil.PE/ByteBufferEqualityComparer.cs
-./Mono.Cecil.PE/TextMap.cs
-./Mono.Cecil.PE/Section.cs
-./Mono.Cecil.PE/Image.cs
-./Mono.Cecil.PE/ImageReader.cs
-./Mono.Cecil.Metadata/TableHeap.cs
-./Mono.Cecil.Metadata/GuidHeap.cs
-./Mono.Cecil.Metadata/Heap.cs
-./Mono.Cecil.Metadata/TokenType.cs
-./Mono.Cecil.Metadata/CodedIndex.cs
-./Mono.Cecil.Metadata/ElementType.cs
-./Mono.Cecil.Metadata/BlobHeap.cs
-./Mono.Cecil.Metadata/Row.cs
-./Mono.Cecil.Metadata/MetadataToken.cs
-./Mono.Cecil.Metadata/UserStringHeap.cs
-./Mono.Cecil.Metadata/Utilities.cs
-./Mono.Cecil.Metadata/StringHeap.cs
-./Mono.Cecil.Metadata/Buffers.cs
-./System.Runtime.CompilerServices/ExtensionAttribute.cs
-./Mono.Security.Cryptography/CryptoService.cs
-./Mono.Security.Cryptography/CryptoConvert.cs
-./Mono/Empty.cs
-./Mono/Funcs.cs
-./Mono/Actions.cs
-./Mono.Cecil.Cil/ILProcessor.cs
-./Mono.Cecil.Cil/VariableReference.cs
-./Mono.Cecil.Cil/OpCodes.cs
-./Mono.Cecil.Cil/MethodBody.cs
-./Mono.Cecil.Cil/Instruction.cs
-./Mono.Cecil.Cil/Code.cs
-./Mono.Cecil.Cil/Symbols.cs
-./Mono.Cecil.Cil/CodeWriter.cs
-./Mono.Cecil.Cil/CodeReader.cs
-./Mono.Cecil.Cil/SequencePoint.cs
-./Mono.Cecil.Cil/Document.cs
-./Mono.Cecil.Cil/OpCode.cs
-./Mono.Cecil.Cil/ExceptionHandler.cs
-./Mono.Cecil.Cil/VariableDefinition.cs
-./Mono.Cecil/ModuleReference.cs
-./Mono.Cecil/TypeParser.cs
-./Mono.Cecil/LinkedResource.cs
-./Mono.Cecil/IMemberDefinition.cs
-./Mono.Cecil/Resource.cs
-./Mono.Cecil/ICustomAttributeProvider.cs
-./Mono.Cecil/MethodReference.cs
-./Mono.Cecil/EventAttributes.cs
-./Mono.Cecil/FieldReference.cs
-./Mono.Cecil/SentinelType.cs
-./Mono.Cecil/MemberReference.cs
-./Mono.Cecil/AssemblyReader.cs
-./Mono.Cecil/TargetRuntime.cs
-./Mono.Cecil/TypeAttributes.cs
-./Mono.Cecil/GenericParameter.cs
-./Mono.Cecil/MethodImplAttributes.cs
-./Mono.Cecil/FileAttributes.cs
-./Mono.Cecil/ManifestResourceAttributes.cs
-./Mono.Cecil/SecurityDeclaration.cs
-./Mono.Cecil/NativeType.cs
-./Mono.Cecil/EventReference.cs
-./Mono.Cecil/AssemblyWriter.cs
-./Mono.Cecil/Modifiers.cs
-./Mono.Cecil/IGenericParameterProvider.cs
-./Mono.Cecil/ParameterDefinition.cs
-./Mono.Cecil/IMetadataScope.cs
-./Mono.Cecil/AssemblyNameReference.cs
-./Mono.Cecil/ParameterAttributes.cs
-./Mono.Cecil/TypeSpecification.cs
-./Mono.Cecil/IMetadataTokenProvider.cs
-./Mono.Cecil/MethodAttributes.cs
-./Mono.Cecil/AssemblyInfo.cs
-./Mono.Cecil/IMarshalInfoProvider.cs
-./Mono.Cecil/PointerType.cs
-./Mono.Cecil/ArrayType.cs
-./Mono.Cecil/TypeDefinition.cs
-./Mono.Cecil/FunctionPointerType.cs
-./Mono.Cecil/MetadataResolver.cs
-./Mono.Cecil/Import.cs
-./Mono.Cecil/IGenericInstance.cs
-./Mono.Cecil/ExportedType.cs
-./Mono.Cecil/PInvokeAttributes.cs
-./Mono.Cecil/AssemblyHashAlgorithm.cs
-./Mono.Cecil/MethodReturnType.cs
-./Mono.Cecil/ParameterReference.cs
-./Mono.Cecil/AssemblyLinkedResource.cs
-./Mono.Cecil/EventDefinition.cs
-./Mono.Cecil/FieldAttributes.cs
-./Mono.Cecil/AssemblyNameDefinition.cs
-./Mono.Cecil/ParameterDefinitionCollection.cs
-./Mono.Cecil/ModuleDefinition.cs
-./Mono.Cecil/MetadataSystem.cs
-./Mono.Cecil/AssemblyFlags.cs
-./Mono.Cecil/TypeDefinitionCollection.cs
-./Mono.Cecil/CustomAttribute.cs
-./Mono.Cecil/MemberDefinitionCollection.cs
-./Mono.Cecil/PropertyDefinition.cs
-./Mono.Cecil/GenericInstanceType.cs
-./Mono.Cecil/ModuleKind.cs
-./Mono.Cecil/DefaultAssemblyResolver.cs
-./Mono.Cecil/MethodSemanticsAttributes.cs
-./Mono.Cecil/EmbeddedResource.cs
-./Mono.Cecil/PropertyAttributes.cs
-./Mono.Cecil/MethodSpecification.cs
-./Mono.Cecil/TypeReference.cs
-./Mono.Cecil/IConstantProvider.cs
-./Mono.Cecil/MethodDefinition.cs
-./Mono.Cecil/PinnedType.cs
-./Mono.Cecil/VariantType.cs
-./Mono.Cecil/MethodCallingConvention.cs
-./Mono.Cecil/TypeSystem.cs
-./Mono.Cecil/IMethodSignature.cs
-./Mono.Cecil/FieldDefinition.cs
-./Mono.Cecil/BaseAssemblyResolver.cs
-./Mono.Cecil/PropertyReference.cs
-./Mono.Cecil/MarshalInfo.cs
-./Mono.Cecil/GenericInstanceMethod.cs
-./Mono.Cecil/ReferenceType.cs
-./Mono.Cecil/PInvokeInfo.cs
-./Mono.Cecil/CallSite.cs
-./Mono.Cecil/AssemblyDefinition.cs
-./Mono.Cecil/GenericParameterAttributes.cs
+../../../external/cecil/Mono.Collections.Generic/Collection.cs
+../../../external/cecil/Mono.Collections.Generic/ReadOnlyCollection.cs
+../../../external/cecil/Mono.Cecil.PE/ImageWriter.cs
+../../../external/cecil/Mono.Cecil.PE/BinaryStreamWriter.cs
+../../../external/cecil/Mono.Cecil.PE/BinaryStreamReader.cs
+../../../external/cecil/Mono.Cecil.PE/DataDirectory.cs
+../../../external/cecil/Mono.Cecil.PE/ByteBuffer.cs
+../../../external/cecil/Mono.Cecil.PE/ByteBufferEqualityComparer.cs
+../../../external/cecil/Mono.Cecil.PE/TextMap.cs
+../../../external/cecil/Mono.Cecil.PE/Section.cs
+../../../external/cecil/Mono.Cecil.PE/Image.cs
+../../../external/cecil/Mono.Cecil.PE/ImageReader.cs
+../../../external/cecil/Mono.Cecil.Metadata/TableHeap.cs
+../../../external/cecil/Mono.Cecil.Metadata/GuidHeap.cs
+../../../external/cecil/Mono.Cecil.Metadata/Heap.cs
+../../../external/cecil/Mono.Cecil.Metadata/TokenType.cs
+../../../external/cecil/Mono.Cecil.Metadata/CodedIndex.cs
+../../../external/cecil/Mono.Cecil.Metadata/ElementType.cs
+../../../external/cecil/Mono.Cecil.Metadata/BlobHeap.cs
+../../../external/cecil/Mono.Cecil.Metadata/Row.cs
+../../../external/cecil/Mono.Cecil.Metadata/MetadataToken.cs
+../../../external/cecil/Mono.Cecil.Metadata/UserStringHeap.cs
+../../../external/cecil/Mono.Cecil.Metadata/Utilities.cs
+../../../external/cecil/Mono.Cecil.Metadata/StringHeap.cs
+../../../external/cecil/Mono.Cecil.Metadata/Buffers.cs
+../../../external/cecil/System.Runtime.CompilerServices/ExtensionAttribute.cs
+../../../external/cecil/Mono.Security.Cryptography/CryptoService.cs
+../../../external/cecil/Mono.Security.Cryptography/CryptoConvert.cs
+../../../external/cecil/Mono/Empty.cs
+../../../external/cecil/Mono/Funcs.cs
+../../../external/cecil/Mono/Actions.cs
+../../../external/cecil/Mono.Cecil.Cil/ILProcessor.cs
+../../../external/cecil/Mono.Cecil.Cil/VariableReference.cs
+../../../external/cecil/Mono.Cecil.Cil/OpCodes.cs
+../../../external/cecil/Mono.Cecil.Cil/MethodBody.cs
+../../../external/cecil/Mono.Cecil.Cil/Instruction.cs
+../../../external/cecil/Mono.Cecil.Cil/Code.cs
+../../../external/cecil/Mono.Cecil.Cil/Symbols.cs
+../../../external/cecil/Mono.Cecil.Cil/CodeWriter.cs
+../../../external/cecil/Mono.Cecil.Cil/CodeReader.cs
+../../../external/cecil/Mono.Cecil.Cil/SequencePoint.cs
+../../../external/cecil/Mono.Cecil.Cil/Document.cs
+../../../external/cecil/Mono.Cecil.Cil/OpCode.cs
+../../../external/cecil/Mono.Cecil.Cil/ExceptionHandler.cs
+../../../external/cecil/Mono.Cecil.Cil/VariableDefinition.cs
+../../../external/cecil/Mono.Cecil/ModuleReference.cs
+../../../external/cecil/Mono.Cecil/TypeParser.cs
+../../../external/cecil/Mono.Cecil/LinkedResource.cs
+../../../external/cecil/Mono.Cecil/IMemberDefinition.cs
+../../../external/cecil/Mono.Cecil/Resource.cs
+../../../external/cecil/Mono.Cecil/ICustomAttributeProvider.cs
+../../../external/cecil/Mono.Cecil/MethodReference.cs
+../../../external/cecil/Mono.Cecil/EventAttributes.cs
+../../../external/cecil/Mono.Cecil/FieldReference.cs
+../../../external/cecil/Mono.Cecil/SentinelType.cs
+../../../external/cecil/Mono.Cecil/MemberReference.cs
+../../../external/cecil/Mono.Cecil/AssemblyReader.cs
+../../../external/cecil/Mono.Cecil/TargetRuntime.cs
+../../../external/cecil/Mono.Cecil/TypeAttributes.cs
+../../../external/cecil/Mono.Cecil/GenericParameter.cs
+../../../external/cecil/Mono.Cecil/MethodImplAttributes.cs
+../../../external/cecil/Mono.Cecil/FileAttributes.cs
+../../../external/cecil/Mono.Cecil/ManifestResourceAttributes.cs
+../../../external/cecil/Mono.Cecil/SecurityDeclaration.cs
+../../../external/cecil/Mono.Cecil/NativeType.cs
+../../../external/cecil/Mono.Cecil/EventReference.cs
+../../../external/cecil/Mono.Cecil/AssemblyWriter.cs
+../../../external/cecil/Mono.Cecil/Modifiers.cs
+../../../external/cecil/Mono.Cecil/IGenericParameterProvider.cs
+../../../external/cecil/Mono.Cecil/ParameterDefinition.cs
+../../../external/cecil/Mono.Cecil/IMetadataScope.cs
+../../../external/cecil/Mono.Cecil/AssemblyNameReference.cs
+../../../external/cecil/Mono.Cecil/ParameterAttributes.cs
+../../../external/cecil/Mono.Cecil/TypeSpecification.cs
+../../../external/cecil/Mono.Cecil/IMetadataTokenProvider.cs
+../../../external/cecil/Mono.Cecil/MethodAttributes.cs
+../../../external/cecil/Mono.Cecil/AssemblyInfo.cs
+../../../external/cecil/Mono.Cecil/IMarshalInfoProvider.cs
+../../../external/cecil/Mono.Cecil/PointerType.cs
+../../../external/cecil/Mono.Cecil/ArrayType.cs
+../../../external/cecil/Mono.Cecil/TypeDefinition.cs
+../../../external/cecil/Mono.Cecil/FunctionPointerType.cs
+../../../external/cecil/Mono.Cecil/MetadataResolver.cs
+../../../external/cecil/Mono.Cecil/Import.cs
+../../../external/cecil/Mono.Cecil/IGenericInstance.cs
+../../../external/cecil/Mono.Cecil/ExportedType.cs
+../../../external/cecil/Mono.Cecil/PInvokeAttributes.cs
+../../../external/cecil/Mono.Cecil/AssemblyHashAlgorithm.cs
+../../../external/cecil/Mono.Cecil/MethodReturnType.cs
+../../../external/cecil/Mono.Cecil/ParameterReference.cs
+../../../external/cecil/Mono.Cecil/AssemblyLinkedResource.cs
+../../../external/cecil/Mono.Cecil/EventDefinition.cs
+../../../external/cecil/Mono.Cecil/FieldAttributes.cs
+../../../external/cecil/Mono.Cecil/AssemblyNameDefinition.cs
+../../../external/cecil/Mono.Cecil/ParameterDefinitionCollection.cs
+../../../external/cecil/Mono.Cecil/ModuleDefinition.cs
+../../../external/cecil/Mono.Cecil/MetadataSystem.cs
+../../../external/cecil/Mono.Cecil/AssemblyFlags.cs
+../../../external/cecil/Mono.Cecil/TypeDefinitionCollection.cs
+../../../external/cecil/Mono.Cecil/CustomAttribute.cs
+../../../external/cecil/Mono.Cecil/MemberDefinitionCollection.cs
+../../../external/cecil/Mono.Cecil/PropertyDefinition.cs
+../../../external/cecil/Mono.Cecil/GenericInstanceType.cs
+../../../external/cecil/Mono.Cecil/ModuleKind.cs
+../../../external/cecil/Mono.Cecil/DefaultAssemblyResolver.cs
+../../../external/cecil/Mono.Cecil/MethodSemanticsAttributes.cs
+../../../external/cecil/Mono.Cecil/EmbeddedResource.cs
+../../../external/cecil/Mono.Cecil/PropertyAttributes.cs
+../../../external/cecil/Mono.Cecil/MethodSpecification.cs
+../../../external/cecil/Mono.Cecil/TypeReference.cs
+../../../external/cecil/Mono.Cecil/IConstantProvider.cs
+../../../external/cecil/Mono.Cecil/MethodDefinition.cs
+../../../external/cecil/Mono.Cecil/PinnedType.cs
+../../../external/cecil/Mono.Cecil/VariantType.cs
+../../../external/cecil/Mono.Cecil/MethodCallingConvention.cs
+../../../external/cecil/Mono.Cecil/TypeSystem.cs
+../../../external/cecil/Mono.Cecil/IMethodSignature.cs
+../../../external/cecil/Mono.Cecil/FieldDefinition.cs
+../../../external/cecil/Mono.Cecil/BaseAssemblyResolver.cs
+../../../external/cecil/Mono.Cecil/PropertyReference.cs
+../../../external/cecil/Mono.Cecil/MarshalInfo.cs
+../../../external/cecil/Mono.Cecil/GenericInstanceMethod.cs
+../../../external/cecil/Mono.Cecil/ReferenceType.cs
+../../../external/cecil/Mono.Cecil/PInvokeInfo.cs
+../../../external/cecil/Mono.Cecil/CallSite.cs
+../../../external/cecil/Mono.Cecil/AssemblyDefinition.cs
+../../../external/cecil/Mono.Cecil/GenericParameterAttributes.cs
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ArrayType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ArrayType.cs
deleted file mode 100644 (file)
index 55c59d8..0000000
+++ /dev/null
@@ -1,159 +0,0 @@
-//
-// ArrayType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Text;
-using Mono.Collections.Generic;
-using MD = Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public struct ArrayDimension {
-
-               int? lower_bound;
-               int? upper_bound;
-
-               public int? LowerBound {
-                       get { return lower_bound; }
-                       set { lower_bound = value; }
-               }
-
-               public int? UpperBound {
-                       get { return upper_bound; }
-                       set { upper_bound = value; }
-               }
-
-               public bool IsSized {
-                       get { return lower_bound.HasValue || upper_bound.HasValue; }
-               }
-
-               public ArrayDimension (int? lowerBound, int? upperBound)
-               {
-                       this.lower_bound = lowerBound;
-                       this.upper_bound = upperBound;
-               }
-
-               public override string ToString ()
-               {
-                       return !IsSized
-                               ? string.Empty
-                               : lower_bound + "..." + upper_bound;
-               }
-       }
-
-       public sealed class ArrayType : TypeSpecification {
-
-               Collection<ArrayDimension> dimensions;
-
-               public Collection<ArrayDimension> Dimensions {
-                       get {
-                               if (dimensions != null)
-                                       return dimensions;
-
-                               dimensions = new Collection<ArrayDimension> ();
-                               dimensions.Add (new ArrayDimension ());
-                               return dimensions;
-                       }
-               }
-
-               public int Rank {
-                       get { return dimensions == null ? 1 : dimensions.Count; }
-               }
-
-               public bool IsVector {
-                       get {
-                               if (dimensions == null)
-                                       return true;
-
-                               if (dimensions.Count > 1)
-                                       return false;
-
-                               var dimension = dimensions [0];
-
-                               return !dimension.IsSized;
-                       }
-               }
-
-               public override bool IsValueType {
-                       get { return false; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override string Name {
-                       get { return base.Name + Suffix; }
-               }
-
-               public override string FullName {
-                       get { return base.FullName + Suffix; }
-               }
-
-               string Suffix {
-                       get {
-                               if (IsVector)
-                                       return "[]";
-
-                               var suffix = new StringBuilder ();
-                               suffix.Append ("[");
-                               for (int i = 0; i < dimensions.Count; i++) {
-                                       if (i > 0)
-                                               suffix.Append (",");
-
-                                       suffix.Append (dimensions [i].ToString ());
-                               }
-                               suffix.Append ("]");
-
-                               return suffix.ToString ();
-                       }
-               }
-
-               public override bool IsArray {
-                       get { return true; }
-               }
-
-               public ArrayType (TypeReference type)
-                       : base (type)
-               {
-                       Mixin.CheckType (type);
-                       this.etype = MD.ElementType.Array;
-               }
-
-               public ArrayType (TypeReference type, int rank)
-                       : this (type)
-               {
-                       Mixin.CheckType (type);
-
-                       if (rank == 1)
-                               return;
-
-                       dimensions = new Collection<ArrayDimension> (rank);
-                       for (int i = 0; i < rank; i++)
-                               dimensions.Add (new ArrayDimension ());
-                       this.etype = MD.ElementType.Array;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyDefinition.cs
deleted file mode 100644 (file)
index f1b5d25..0000000
+++ /dev/null
@@ -1,189 +0,0 @@
-//
-// AssemblyDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.IO;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public sealed class AssemblyDefinition : ICustomAttributeProvider, ISecurityDeclarationProvider {
-
-               AssemblyNameDefinition name;
-
-               internal ModuleDefinition main_module;
-               Collection<ModuleDefinition> modules;
-               Collection<CustomAttribute> custom_attributes;
-               Collection<SecurityDeclaration> security_declarations;
-
-               public AssemblyNameDefinition Name {
-                       get { return name; }
-                       set { name = value; }
-               }
-
-               public string FullName {
-                       get { return name != null ? name.FullName : string.Empty; }
-               }
-
-               public MetadataToken MetadataToken {
-                       get { return new MetadataToken (TokenType.Assembly, 1); }
-                       set { }
-               }
-
-               public Collection<ModuleDefinition> Modules {
-                       get {
-                               if (modules != null)
-                                       return modules;
-
-                               if (main_module.HasImage)
-                                       return modules = main_module.Read (this, (_, reader) => reader.ReadModules ());
-
-                               return modules = new Collection<ModuleDefinition> (1) { main_module };
-                       }
-               }
-
-               public ModuleDefinition MainModule {
-                       get { return main_module; }
-               }
-
-               public MethodDefinition EntryPoint {
-                       get { return main_module.EntryPoint; }
-                       set { main_module.EntryPoint = value; }
-               }
-
-               public bool HasCustomAttributes {
-                       get {
-                               if (custom_attributes != null)
-                                       return custom_attributes.Count > 0;
-
-                               return this.GetHasCustomAttributes (main_module);
-                       }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return custom_attributes ?? (custom_attributes = this.GetCustomAttributes (main_module)); }
-               }
-
-               public bool HasSecurityDeclarations {
-                       get {
-                               if (security_declarations != null)
-                                       return security_declarations.Count > 0;
-
-                               return this.GetHasSecurityDeclarations (main_module);
-                       }
-               }
-
-               public Collection<SecurityDeclaration> SecurityDeclarations {
-                       get { return security_declarations ?? (security_declarations = this.GetSecurityDeclarations (main_module)); }
-               }
-
-               internal AssemblyDefinition ()
-               {
-               }
-
-#if !READ_ONLY
-               public static AssemblyDefinition CreateAssembly (AssemblyNameDefinition assemblyName, string moduleName, ModuleKind kind)
-               {
-                       return CreateAssembly (assemblyName, moduleName, new ModuleParameters { Kind = kind });
-               }
-
-               public static AssemblyDefinition CreateAssembly (AssemblyNameDefinition assemblyName, string moduleName, ModuleParameters parameters)
-               {
-                       if (assemblyName == null)
-                               throw new ArgumentNullException ("assemblyName");
-                       if (moduleName == null)
-                               throw new ArgumentNullException ("moduleName");
-                       Mixin.CheckParameters (parameters);
-                       if (parameters.Kind == ModuleKind.NetModule)
-                               throw new ArgumentException ("kind");
-
-                       var assembly = ModuleDefinition.CreateModule (moduleName, parameters).Assembly;
-                       assembly.Name = assemblyName;
-
-                       return assembly;
-               }
-#endif
-
-               public static AssemblyDefinition ReadAssembly (string fileName)
-               {
-                       return ReadAssembly (ModuleDefinition.ReadModule (fileName));
-               }
-
-               public static AssemblyDefinition ReadAssembly (string fileName, ReaderParameters parameters)
-               {
-                       return ReadAssembly (ModuleDefinition.ReadModule (fileName, parameters));
-               }
-
-               public static AssemblyDefinition ReadAssembly (Stream stream)
-               {
-                       return ReadAssembly (ModuleDefinition.ReadModule (stream));
-               }
-
-               public static AssemblyDefinition ReadAssembly (Stream stream, ReaderParameters parameters)
-               {
-                       return ReadAssembly (ModuleDefinition.ReadModule (stream, parameters));
-               }
-
-               static AssemblyDefinition ReadAssembly (ModuleDefinition module)
-               {
-                       var assembly = module.Assembly;
-                       if (assembly == null)
-                               throw new ArgumentException ();
-
-                       return assembly;
-               }
-
-#if !READ_ONLY
-               public void Write (string fileName)
-               {
-                       Write (fileName, new WriterParameters ());
-               }
-
-               public void Write (Stream stream)
-               {
-                       Write (stream, new WriterParameters ());
-               }
-
-               public void Write (string fileName, WriterParameters parameters)
-               {
-                       main_module.Write (fileName, parameters);
-               }
-
-               public void Write (Stream stream, WriterParameters parameters)
-               {
-                       main_module.Write (stream, parameters);
-               }
-#endif
-
-               public override string ToString ()
-               {
-                       return this.FullName;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyFlags.cs b/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyFlags.cs
deleted file mode 100644 (file)
index e466e78..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-//
-// AssemblyFlags.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum AssemblyAttributes : uint {
-               PublicKey                                               = 0x0001,
-               SideBySideCompatible                    = 0x0000,
-               Retargetable                                    = 0x0100,
-               DisableJITCompileOptimizer              = 0x4000,
-               EnableJITCompileTracking                = 0x8000,
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyHashAlgorithm.cs b/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyHashAlgorithm.cs
deleted file mode 100644 (file)
index 79a5699..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-//
-// AssemblyHashAlgorithm.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public enum AssemblyHashAlgorithm : uint {
-               None            = 0x0000,
-               Reserved        = 0x8003,       // MD5
-               SHA1            = 0x8004
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyInfo.cs b/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyInfo.cs
deleted file mode 100644 (file)
index 8a9f809..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-//
-// AssemblyInfo.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System.Reflection;
-using System.Runtime.CompilerServices;
-using System.Runtime.InteropServices;
-
-[assembly: AssemblyTitle ("Mono.Cecil")]
-[assembly: AssemblyProduct ("Mono.Cecil")]
-[assembly: AssemblyCopyright ("Copyright © 2008 - 2011 Jb Evain")]
-
-[assembly: ComVisible (false)]
-
-[assembly: Guid ("fd225bb4-fa53-44b2-a6db-85f5e48dcb54")]
-
-[assembly: AssemblyVersion ("0.9.5.0")]
-#if !CF
-[assembly: AssemblyFileVersion ("0.9.5.0")]
-#endif
-
-[assembly: InternalsVisibleTo ("Mono.Cecil.Pdb, PublicKey=002400000480000094000000060200000024000052534131000400000100010079159977d2d03a8e6bea7a2e74e8d1afcc93e8851974952bb480a12c9134474d04062447c37e0e68c080536fcf3c3fbe2ff9c979ce998475e506e8ce82dd5b0f350dc10e93bf2eeecf874b24770c5081dbea7447fddafa277b22de47d6ffea449674a4f9fccf84d15069089380284dbdd35f46cdff12a1bd78e4ef0065d016df")]
-[assembly: InternalsVisibleTo ("Mono.Cecil.Mdb, PublicKey=002400000480000094000000060200000024000052534131000400000100010079159977d2d03a8e6bea7a2e74e8d1afcc93e8851974952bb480a12c9134474d04062447c37e0e68c080536fcf3c3fbe2ff9c979ce998475e506e8ce82dd5b0f350dc10e93bf2eeecf874b24770c5081dbea7447fddafa277b22de47d6ffea449674a4f9fccf84d15069089380284dbdd35f46cdff12a1bd78e4ef0065d016df")]
-[assembly: InternalsVisibleTo ("Mono.Cecil.Rocks, PublicKey=002400000480000094000000060200000024000052534131000400000100010079159977d2d03a8e6bea7a2e74e8d1afcc93e8851974952bb480a12c9134474d04062447c37e0e68c080536fcf3c3fbe2ff9c979ce998475e506e8ce82dd5b0f350dc10e93bf2eeecf874b24770c5081dbea7447fddafa277b22de47d6ffea449674a4f9fccf84d15069089380284dbdd35f46cdff12a1bd78e4ef0065d016df")]
-[assembly: InternalsVisibleTo ("Mono.Cecil.Tests, PublicKey=002400000480000094000000060200000024000052534131000400000100010079159977d2d03a8e6bea7a2e74e8d1afcc93e8851974952bb480a12c9134474d04062447c37e0e68c080536fcf3c3fbe2ff9c979ce998475e506e8ce82dd5b0f350dc10e93bf2eeecf874b24770c5081dbea7447fddafa277b22de47d6ffea449674a4f9fccf84d15069089380284dbdd35f46cdff12a1bd78e4ef0065d016df")]
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyLinkedResource.cs b/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyLinkedResource.cs
deleted file mode 100644 (file)
index 4d8bac0..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-//
-// AssemblyLinkedResource.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       public sealed class AssemblyLinkedResource : Resource {
-
-               AssemblyNameReference reference;
-
-               public AssemblyNameReference Assembly {
-                       get { return reference; }
-                       set { reference = value; }
-               }
-
-               public override ResourceType ResourceType {
-                       get { return ResourceType.AssemblyLinked; }
-               }
-
-               public AssemblyLinkedResource (string name, ManifestResourceAttributes flags)
-                       : base (name, flags)
-               {
-               }
-
-               public AssemblyLinkedResource (string name, ManifestResourceAttributes flags, AssemblyNameReference reference)
-                       : base (name, flags)
-               {
-                       this.reference = reference;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyNameDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyNameDefinition.cs
deleted file mode 100644 (file)
index dc6b905..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-//
-// AssemblyNameDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       public sealed class AssemblyNameDefinition : AssemblyNameReference {
-
-               public override byte [] Hash {
-                       get { return Empty<byte>.Array; }
-               }
-
-               internal AssemblyNameDefinition ()
-               {
-                       this.token = new MetadataToken (TokenType.Assembly, 1);
-               }
-
-               public AssemblyNameDefinition (string name, Version version)
-                       : base (name, version)
-               {
-                       this.token = new MetadataToken (TokenType.Assembly, 1);
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyNameReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyNameReference.cs
deleted file mode 100644 (file)
index c252c52..0000000
+++ /dev/null
@@ -1,263 +0,0 @@
-//
-// AssemblyNameReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Globalization;
-using System.Security.Cryptography;
-using System.Text;
-
-namespace Mono.Cecil {
-
-       public class AssemblyNameReference : IMetadataScope {
-
-               string name;
-               string culture;
-               Version version;
-               uint attributes;
-               byte [] public_key;
-               byte [] public_key_token;
-               AssemblyHashAlgorithm hash_algorithm;
-               byte [] hash;
-
-               internal MetadataToken token;
-
-               string full_name;
-
-               public string Name {
-                       get { return name; }
-                       set {
-                               name = value;
-                               full_name = null;
-                       }
-               }
-
-               public string Culture {
-                       get { return culture; }
-                       set {
-                               culture = value;
-                               full_name = null;
-                       }
-               }
-
-               public Version Version {
-                       get { return version; }
-                       set {
-                                version = value;
-                                full_name = null;
-                       }
-               }
-
-               public AssemblyAttributes Attributes {
-                       get { return (AssemblyAttributes) attributes; }
-                       set { attributes = (uint) value; }
-               }
-
-               public bool HasPublicKey {
-                       get { return attributes.GetAttributes ((uint) AssemblyAttributes.PublicKey); }
-                       set { attributes = attributes.SetAttributes ((uint) AssemblyAttributes.PublicKey, value); }
-               }
-
-               public bool IsSideBySideCompatible {
-                       get { return attributes.GetAttributes ((uint) AssemblyAttributes.SideBySideCompatible); }
-                       set { attributes = attributes.SetAttributes ((uint) AssemblyAttributes.SideBySideCompatible, value); }
-               }
-
-               public bool IsRetargetable {
-                       get { return attributes.GetAttributes ((uint) AssemblyAttributes.Retargetable); }
-                       set { attributes = attributes.SetAttributes ((uint) AssemblyAttributes.Retargetable, value); }
-               }
-
-               public byte [] PublicKey {
-                       get { return public_key; }
-                       set {
-                               public_key = value;
-                               HasPublicKey = !public_key.IsNullOrEmpty ();
-                               public_key_token = Empty<byte>.Array;
-                               full_name = null;
-                       }
-               }
-
-               public byte [] PublicKeyToken {
-                       get {
-                               if (public_key_token.IsNullOrEmpty () && !public_key.IsNullOrEmpty ()) {
-                                       var hash = HashPublicKey ();
-                                       // we need the last 8 bytes in reverse order
-                                       public_key_token = new byte [8];
-                                       Array.Copy (hash, (hash.Length - 8), public_key_token, 0, 8);
-                                       Array.Reverse (public_key_token, 0, 8);
-                               }
-                               return public_key_token;
-                       }
-                       set {
-                               public_key_token = value;
-                               full_name = null;
-                       }
-               }
-
-               byte [] HashPublicKey ()
-               {
-                       HashAlgorithm algorithm;
-
-                       switch (hash_algorithm) {
-                       case AssemblyHashAlgorithm.Reserved:
-#if SILVERLIGHT
-                               throw new NotSupportedException ();
-#else
-                               algorithm = MD5.Create ();
-                               break;
-#endif
-                       default:
-                               // None default to SHA1
-#if SILVERLIGHT
-                               algorithm = new SHA1Managed ();
-                               break;
-#else
-                               algorithm = SHA1.Create ();
-                               break;
-#endif
-                       }
-
-                       using (algorithm)
-                               return algorithm.ComputeHash (public_key);
-               }
-
-               public virtual MetadataScopeType MetadataScopeType {
-                       get { return MetadataScopeType.AssemblyNameReference; }
-               }
-
-               public string FullName {
-                       get {
-                               if (full_name != null)
-                                       return full_name;
-
-                               const string sep = ", ";
-
-                               var builder = new StringBuilder ();
-                               builder.Append (name);
-                               if (version != null) {
-                                       builder.Append (sep);
-                                       builder.Append ("Version=");
-                                       builder.Append (version.ToString ());
-                               }
-                               builder.Append (sep);
-                               builder.Append ("Culture=");
-                               builder.Append (string.IsNullOrEmpty (culture) ? "neutral" : culture);
-                               builder.Append (sep);
-                               builder.Append ("PublicKeyToken=");
-
-                               if (this.PublicKeyToken != null && public_key_token.Length > 0) {
-                                       for (int i = 0 ; i < public_key_token.Length ; i++) {
-                                               builder.Append (public_key_token [i].ToString ("x2"));
-                                       }
-                               } else
-                                       builder.Append ("null");
-
-                               return full_name = builder.ToString ();
-                       }
-               }
-
-               public static AssemblyNameReference Parse (string fullName)
-               {
-                       if (fullName == null)
-                               throw new ArgumentNullException ("fullName");
-                       if (fullName.Length == 0)
-                               throw new ArgumentException ("Name can not be empty");
-
-                       var name = new AssemblyNameReference ();
-                       var tokens = fullName.Split (',');
-                       for (int i = 0; i < tokens.Length; i++) {
-                               var token = tokens [i].Trim ();
-
-                               if (i == 0) {
-                                       name.Name = token;
-                                       continue;
-                               }
-
-                               var parts = token.Split ('=');
-                               if (parts.Length != 2)
-                                       throw new ArgumentException ("Malformed name");
-
-                               switch (parts [0]) {
-                               case "Version":
-                                       name.Version = new Version (parts [1]);
-                                       break;
-                               case "Culture":
-                                       name.Culture = parts [1];
-                                       break;
-                               case "PublicKeyToken":
-                                       string pk_token = parts [1];
-                                       if (pk_token == "null")
-                                               break;
-
-                                       name.PublicKeyToken = new byte [pk_token.Length / 2];
-                                       for (int j = 0; j < name.PublicKeyToken.Length; j++) {
-                                               name.PublicKeyToken [j] = Byte.Parse (pk_token.Substring (j * 2, 2), NumberStyles.HexNumber);
-                                       }
-                                       break;
-                               }
-                       }
-
-                       return name;
-               }
-
-               public AssemblyHashAlgorithm HashAlgorithm {
-                       get { return hash_algorithm; }
-                       set { hash_algorithm = value; }
-               }
-
-               public virtual byte [] Hash {
-                       get { return hash; }
-                       set { hash = value; }
-               }
-
-               public MetadataToken MetadataToken {
-                       get { return token; }
-                       set { token = value; }
-               }
-
-               internal AssemblyNameReference ()
-               {
-               }
-
-               public AssemblyNameReference (string name, Version version)
-               {
-                       if (name == null)
-                               throw new ArgumentNullException ("name");
-
-                       this.name = name;
-                       this.version = version;
-                       this.hash_algorithm = AssemblyHashAlgorithm.None;
-                       this.token = new MetadataToken (TokenType.AssemblyRef);
-               }
-
-               public override string ToString ()
-               {
-                       return this.FullName;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyReader.cs b/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyReader.cs
deleted file mode 100644 (file)
index 72cb480..0000000
+++ /dev/null
@@ -1,3157 +0,0 @@
-//
-// AssemblyReader.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-using System.IO;
-using System.Text;
-
-using Mono.Collections.Generic;
-using Mono.Cecil.Cil;
-using Mono.Cecil.Metadata;
-using Mono.Cecil.PE;
-
-using RVA = System.UInt32;
-
-namespace Mono.Cecil {
-
-       abstract class ModuleReader {
-
-               readonly protected Image image;
-               readonly protected ModuleDefinition module;
-
-               protected ModuleReader (Image image, ReadingMode mode)
-               {
-                       this.image = image;
-                       this.module = new ModuleDefinition (image);
-                       this.module.ReadingMode = mode;
-               }
-
-               protected abstract void ReadModule ();
-
-               protected void ReadModuleManifest (MetadataReader reader)
-               {
-                       reader.Populate (module);
-
-                       ReadAssembly (reader);
-               }
-
-               void ReadAssembly (MetadataReader reader)
-               {
-                       var name = reader.ReadAssemblyNameDefinition ();
-                       if (name == null) {
-                               module.kind = ModuleKind.NetModule;
-                               return;
-                       }
-
-                       var assembly = new AssemblyDefinition ();
-                       assembly.Name = name;
-
-                       module.assembly = assembly;
-                       assembly.main_module = module;
-               }
-
-               public static ModuleDefinition CreateModuleFrom (Image image, ReaderParameters parameters)
-               {
-                       var module = ReadModule (image, parameters);
-
-                       ReadSymbols (module, parameters);
-
-                       if (parameters.AssemblyResolver != null)
-                               module.assembly_resolver = parameters.AssemblyResolver;
-
-                       if (parameters.MetadataResolver != null)
-                               module.metadata_resolver = parameters.MetadataResolver;
-
-                       return module;
-               }
-
-               static void ReadSymbols (ModuleDefinition module, ReaderParameters parameters)
-               {
-                       var symbol_reader_provider = parameters.SymbolReaderProvider;
-
-                       if (symbol_reader_provider == null && parameters.ReadSymbols)
-                               symbol_reader_provider = SymbolProvider.GetPlatformReaderProvider ();
-
-                       if (symbol_reader_provider != null) {
-                               module.SymbolReaderProvider = symbol_reader_provider;
-
-                               var reader = parameters.SymbolStream != null
-                                       ? symbol_reader_provider.GetSymbolReader (module, parameters.SymbolStream)
-                                       : symbol_reader_provider.GetSymbolReader (module, module.FullyQualifiedName);
-
-                               module.ReadSymbols (reader);
-                       }
-               }
-
-               static ModuleDefinition ReadModule (Image image, ReaderParameters parameters)
-               {
-                       var reader = CreateModuleReader (image, parameters.ReadingMode);
-                       reader.ReadModule ();
-                       return reader.module;
-               }
-
-               static ModuleReader CreateModuleReader (Image image, ReadingMode mode)
-               {
-                       switch (mode) {
-                       case ReadingMode.Immediate:
-                               return new ImmediateModuleReader (image);
-                       case ReadingMode.Deferred:
-                               return new DeferredModuleReader (image);
-                       default:
-                               throw new ArgumentException ();
-                       }
-               }
-       }
-
-       sealed class ImmediateModuleReader : ModuleReader {
-
-               public ImmediateModuleReader (Image image)
-                       : base (image, ReadingMode.Immediate)
-               {
-               }
-
-               protected override void ReadModule ()
-               {
-                       this.module.Read (this.module, (module, reader) => {
-                               ReadModuleManifest (reader);
-                               ReadModule (module);
-                               return module;
-                       });
-               }
-
-               public static void ReadModule (ModuleDefinition module)
-               {
-                       if (module.HasAssemblyReferences)
-                               Read (module.AssemblyReferences);
-                       if (module.HasResources)
-                               Read (module.Resources);
-                       if (module.HasModuleReferences)
-                               Read (module.ModuleReferences);
-                       if (module.HasTypes)
-                               ReadTypes (module.Types);
-                       if (module.HasExportedTypes)
-                               Read (module.ExportedTypes);
-                       if (module.HasCustomAttributes)
-                               Read (module.CustomAttributes);
-
-                       var assembly = module.Assembly;
-                       if (assembly == null)
-                               return;
-
-                       if (assembly.HasCustomAttributes)
-                               Read (assembly.CustomAttributes);
-                       if (assembly.HasSecurityDeclarations)
-                               Read (assembly.SecurityDeclarations);
-               }
-
-               static void ReadTypes (Collection<TypeDefinition> types)
-               {
-                       for (int i = 0; i < types.Count; i++)
-                               ReadType (types [i]);
-               }
-
-               static void ReadType (TypeDefinition type)
-               {
-                       ReadGenericParameters (type);
-
-                       if (type.HasInterfaces)
-                               Read (type.Interfaces);
-
-                       if (type.HasNestedTypes)
-                               ReadTypes (type.NestedTypes);
-
-                       if (type.HasLayoutInfo)
-                               Read (type.ClassSize);
-
-                       if (type.HasFields)
-                               ReadFields (type);
-
-                       if (type.HasMethods)
-                               ReadMethods (type);
-
-                       if (type.HasProperties)
-                               ReadProperties (type);
-
-                       if (type.HasEvents)
-                               ReadEvents (type);
-
-                       ReadSecurityDeclarations (type);
-                       ReadCustomAttributes (type);
-               }
-
-               static void ReadGenericParameters (IGenericParameterProvider provider)
-               {
-                       if (!provider.HasGenericParameters)
-                               return;
-
-                       var parameters = provider.GenericParameters;
-
-                       for (int i = 0; i < parameters.Count; i++) {
-                               var parameter = parameters [i];
-
-                               if (parameter.HasConstraints)
-                                       Read (parameter.Constraints);
-
-                               if (parameter.HasCustomAttributes)
-                                       Read (parameter.CustomAttributes);
-                       }
-               }
-
-               static void ReadSecurityDeclarations (ISecurityDeclarationProvider provider)
-               {
-                       if (provider.HasSecurityDeclarations)
-                               Read (provider.SecurityDeclarations);
-               }
-
-               static void ReadCustomAttributes (ICustomAttributeProvider provider)
-               {
-                       if (provider.HasCustomAttributes)
-                               Read (provider.CustomAttributes);
-               }
-
-               static void ReadFields (TypeDefinition type)
-               {
-                       var fields = type.Fields;
-
-                       for (int i = 0; i < fields.Count; i++) {
-                               var field = fields [i];
-
-                               if (field.HasConstant)
-                                       Read (field.Constant);
-
-                               if (field.HasLayoutInfo)
-                                       Read (field.Offset);
-
-                               if (field.RVA > 0)
-                                       Read (field.InitialValue);
-
-                               if (field.HasMarshalInfo)
-                                       Read (field.MarshalInfo);
-
-                               ReadCustomAttributes (field);
-                       }
-               }
-
-               static void ReadMethods (TypeDefinition type)
-               {
-                       var methods = type.Methods;
-
-                       for (int i = 0; i < methods.Count; i++) {
-                               var method = methods [i];
-
-                               ReadGenericParameters (method);
-
-                               if (method.HasParameters)
-                                       ReadParameters (method);
-
-                               if (method.HasOverrides)
-                                       Read (method.Overrides);
-
-                               if (method.IsPInvokeImpl)
-                                       Read (method.PInvokeInfo);
-
-                               ReadSecurityDeclarations (method);
-                               ReadCustomAttributes (method);
-
-                               var return_type = method.MethodReturnType;
-                               if (return_type.HasConstant)
-                                       Read (return_type.Constant);
-
-                               if (return_type.HasMarshalInfo)
-                                       Read (return_type.MarshalInfo);
-
-                               ReadCustomAttributes (return_type);
-                       }
-               }
-
-               static void ReadParameters (MethodDefinition method)
-               {
-                       var parameters = method.Parameters;
-
-                       for (int i = 0; i < parameters.Count; i++) {
-                               var parameter = parameters [i];
-
-                               if (parameter.HasConstant)
-                                       Read (parameter.Constant);
-
-                               if (parameter.HasMarshalInfo)
-                                       Read (parameter.MarshalInfo);
-
-                               ReadCustomAttributes (parameter);
-                       }
-               }
-
-               static void ReadProperties (TypeDefinition type)
-               {
-                       var properties = type.Properties;
-
-                       for (int i = 0; i < properties.Count; i++) {
-                               var property = properties [i];
-
-                               Read (property.GetMethod);
-
-                               if (property.HasConstant)
-                                       Read (property.Constant);
-
-                               ReadCustomAttributes (property);
-                       }
-               }
-
-               static void ReadEvents (TypeDefinition type)
-               {
-                       var events = type.Events;
-
-                       for (int i = 0; i < events.Count; i++) {
-                               var @event = events [i];
-
-                               Read (@event.AddMethod);
-
-                               ReadCustomAttributes (@event);
-                       }
-               }
-
-               static void Read (object collection)
-               {
-               }
-       }
-
-       sealed class DeferredModuleReader : ModuleReader {
-
-               public DeferredModuleReader (Image image)
-                       : base (image, ReadingMode.Deferred)
-               {
-               }
-
-               protected override void ReadModule ()
-               {
-                       this.module.Read (this.module, (module, reader) => {
-                               ReadModuleManifest (reader);
-                               return module;
-                       });
-               }
-       }
-
-       sealed class MetadataReader : ByteBuffer {
-
-               readonly internal Image image;
-               readonly internal ModuleDefinition module;
-               readonly internal MetadataSystem metadata;
-
-               internal IGenericContext context;
-               internal CodeReader code;
-
-               uint Position {
-                       get { return (uint) base.position; }
-                       set { base.position = (int) value; }
-               }
-
-               public MetadataReader (ModuleDefinition module)
-                       : base (module.Image.MetadataSection.Data)
-               {
-                       this.image = module.Image;
-                       this.module = module;
-                       this.metadata = module.MetadataSystem;
-                       this.code = new CodeReader (image.MetadataSection, this);
-               }
-
-               int GetCodedIndexSize (CodedIndex index)
-               {
-                       return image.GetCodedIndexSize (index);
-               }
-
-               uint ReadByIndexSize (int size)
-               {
-                       if (size == 4)
-                               return ReadUInt32 ();
-                       else
-                               return ReadUInt16 ();
-               }
-
-               byte [] ReadBlob ()
-               {
-                       var blob_heap = image.BlobHeap;
-                       if (blob_heap == null) {
-                               position += 2;
-                               return Empty<byte>.Array;
-                       }
-
-                       return blob_heap.Read (ReadBlobIndex ());
-               }
-
-               byte [] ReadBlob (uint signature)
-               {
-                       var blob_heap = image.BlobHeap;
-                       if (blob_heap == null)
-                               return Empty<byte>.Array;
-
-                       return blob_heap.Read (signature);
-               }
-
-               uint ReadBlobIndex ()
-               {
-                       var blob_heap = image.BlobHeap;
-                       return ReadByIndexSize (blob_heap != null ? blob_heap.IndexSize : 2);
-               }
-
-               string ReadString ()
-               {
-                       return image.StringHeap.Read (ReadByIndexSize (image.StringHeap.IndexSize));
-               }
-
-               uint ReadStringIndex ()
-               {
-                       return ReadByIndexSize (image.StringHeap.IndexSize);
-               }
-
-               uint ReadTableIndex (Table table)
-               {
-                       return ReadByIndexSize (image.GetTableIndexSize (table));
-               }
-
-               MetadataToken ReadMetadataToken (CodedIndex index)
-               {
-                       return index.GetMetadataToken (ReadByIndexSize (GetCodedIndexSize (index)));
-               }
-
-               int MoveTo (Table table)
-               {
-                       var info = image.TableHeap [table];
-                       if (info.Length != 0)
-                               Position = info.Offset;
-
-                       return (int) info.Length;
-               }
-
-               bool MoveTo (Table table, uint row)
-               {
-                       var info = image.TableHeap [table];
-                       var length = info.Length;
-                       if (length == 0 || row > length)
-                               return false;
-
-                       Position = info.Offset + (info.RowSize * (row - 1));
-                       return true;
-               }
-
-               public AssemblyNameDefinition ReadAssemblyNameDefinition ()
-               {
-                       if (MoveTo (Table.Assembly) == 0)
-                               return null;
-
-                       var name = new AssemblyNameDefinition ();
-
-                       name.HashAlgorithm = (AssemblyHashAlgorithm) ReadUInt32 ();
-
-                       PopulateVersionAndFlags (name);
-
-                       name.PublicKey = ReadBlob ();
-
-                       PopulateNameAndCulture (name);
-
-                       return name;
-               }
-
-               public ModuleDefinition Populate (ModuleDefinition module)
-               {
-                       if (MoveTo (Table.Module) == 0)
-                               return module;
-
-                       Advance (2); // Generation
-
-                       module.Name = ReadString ();
-                       module.Mvid = image.GuidHeap.Read (ReadByIndexSize (image.GuidHeap.IndexSize));
-
-                       return module;
-               }
-
-               void InitializeAssemblyReferences ()
-               {
-                       if (metadata.AssemblyReferences != null)
-                               return;
-
-                       int length = MoveTo (Table.AssemblyRef);
-                       var references = metadata.AssemblyReferences = new AssemblyNameReference [length];
-
-                       for (uint i = 0; i < length; i++) {
-                               var reference = new AssemblyNameReference ();
-                               reference.token = new MetadataToken (TokenType.AssemblyRef, i + 1);
-
-                               PopulateVersionAndFlags (reference);
-
-                               var key_or_token = ReadBlob ();
-
-                               if (reference.HasPublicKey)
-                                       reference.PublicKey = key_or_token;
-                               else
-                                       reference.PublicKeyToken = key_or_token;
-
-                               PopulateNameAndCulture (reference);
-
-                               reference.Hash = ReadBlob ();
-
-                               references [i] = reference;
-                       }
-               }
-
-               public Collection<AssemblyNameReference> ReadAssemblyReferences ()
-               {
-                       InitializeAssemblyReferences ();
-
-                       return new Collection<AssemblyNameReference> (metadata.AssemblyReferences);
-               }
-
-               public MethodDefinition ReadEntryPoint ()
-               {
-                       if (module.Image.EntryPointToken == 0)
-                               return null;
-
-                       var token = new MetadataToken (module.Image.EntryPointToken);
-                       return GetMethodDefinition (token.RID);
-               }
-
-               public Collection<ModuleDefinition> ReadModules ()
-               {
-                       var modules = new Collection<ModuleDefinition> (1);
-                       modules.Add (this.module);
-
-                       int length = MoveTo (Table.File);
-                       for (uint i = 1; i <= length; i++) {
-                               var attributes = (FileAttributes) ReadUInt32 ();
-                               var name = ReadString ();
-                               ReadBlobIndex ();
-
-                               if (attributes != FileAttributes.ContainsMetaData)
-                                       continue;
-
-                               var parameters = new ReaderParameters {
-                                       ReadingMode = module.ReadingMode,
-                                       SymbolReaderProvider = module.SymbolReaderProvider,
-                               };
-
-                               modules.Add (ModuleDefinition.ReadModule (
-                                       GetModuleFileName (name), parameters));
-                       }
-
-                       return modules;
-               }
-
-               string GetModuleFileName (string name)
-               {
-                       if (module.FullyQualifiedName == null)
-                               throw new NotSupportedException ();
-
-                       var path = Path.GetDirectoryName (module.FullyQualifiedName);
-                       return Path.Combine (path, name);
-               }
-
-               void InitializeModuleReferences ()
-               {
-                       if (metadata.ModuleReferences != null)
-                               return;
-
-                       int length = MoveTo (Table.ModuleRef);
-                       var references = metadata.ModuleReferences = new ModuleReference [length];
-
-                       for (uint i = 0; i < length; i++) {
-                               var reference = new ModuleReference (ReadString ());
-                               reference.token = new MetadataToken (TokenType.ModuleRef, i + 1);
-
-                               references [i] = reference;
-                       }
-               }
-
-               public Collection<ModuleReference> ReadModuleReferences ()
-               {
-                       InitializeModuleReferences ();
-
-                       return new Collection<ModuleReference> (metadata.ModuleReferences);
-               }
-
-               public bool HasFileResource ()
-               {
-                       int length = MoveTo (Table.File);
-                       if (length == 0)
-                               return false;
-
-                       for (uint i = 1; i <= length; i++)
-                               if (ReadFileRecord (i).Col1 == FileAttributes.ContainsNoMetaData)
-                                       return true;
-
-                       return false;
-               }
-
-               public Collection<Resource> ReadResources ()
-               {
-                       int length = MoveTo (Table.ManifestResource);
-                       var resources = new Collection<Resource> (length);
-
-                       for (int i = 1; i <= length; i++) {
-                               var offset = ReadUInt32 ();
-                               var flags = (ManifestResourceAttributes) ReadUInt32 ();
-                               var name = ReadString ();
-                               var implementation = ReadMetadataToken (CodedIndex.Implementation);
-
-                               Resource resource;
-
-                               if (implementation.RID == 0) {
-                                       resource = new EmbeddedResource (name, flags, offset, this);
-                               } else if (implementation.TokenType == TokenType.AssemblyRef) {
-                                       resource = new AssemblyLinkedResource (name, flags) {
-                                               Assembly = (AssemblyNameReference) GetTypeReferenceScope (implementation),
-                                       };
-                               } else if (implementation.TokenType == TokenType.File) {
-                                       var file_record = ReadFileRecord (implementation.RID);
-
-                                       resource = new LinkedResource (name, flags) {
-                                               File = file_record.Col2,
-                                               hash = ReadBlob (file_record.Col3)
-                                       };
-                               } else
-                                       throw new NotSupportedException ();
-
-                               resources.Add (resource);
-                       }
-
-                       return resources;
-               }
-
-               Row<FileAttributes, string, uint> ReadFileRecord (uint rid)
-               {
-                       var position = this.position;
-
-                       if (!MoveTo (Table.File, rid))
-                               throw new ArgumentException ();
-
-                       var record = new Row<FileAttributes, string, uint> (
-                               (FileAttributes) ReadUInt32 (),
-                               ReadString (),
-                               ReadBlobIndex ());
-
-                       this.position = position;
-
-                       return record;
-               }
-
-               public MemoryStream GetManagedResourceStream (uint offset)
-               {
-                       var rva = image.Resources.VirtualAddress;
-                       var section = image.GetSectionAtVirtualAddress (rva);
-                       var position = (rva - section.VirtualAddress) + offset;
-                       var buffer = section.Data;
-
-                       var length = buffer [position]
-                               | (buffer [position + 1] << 8)
-                               | (buffer [position + 2] << 16)
-                               | (buffer [position + 3] << 24);
-
-                       return new MemoryStream (buffer, (int) position + 4, length);
-               }
-
-               void PopulateVersionAndFlags (AssemblyNameReference name)
-               {
-                       name.Version = new Version (
-                               ReadUInt16 (),
-                               ReadUInt16 (),
-                               ReadUInt16 (),
-                               ReadUInt16 ());
-
-                       name.Attributes = (AssemblyAttributes) ReadUInt32 ();
-               }
-
-               void PopulateNameAndCulture (AssemblyNameReference name)
-               {
-                       name.Name = ReadString ();
-                       name.Culture = ReadString ();
-               }
-
-               public TypeDefinitionCollection ReadTypes ()
-               {
-                       InitializeTypeDefinitions ();
-                       var mtypes = metadata.Types;
-                       var type_count = mtypes.Length - metadata.NestedTypes.Count;
-                       var types = new TypeDefinitionCollection (module, type_count);
-
-                       for (int i = 0; i < mtypes.Length; i++) {
-                               var type = mtypes [i];
-                               if (IsNested (type.Attributes))
-                                       continue;
-
-                               types.Add (type);
-                       }
-
-                       if (image.HasTable (Table.MethodPtr) || image.HasTable (Table.FieldPtr))
-                               CompleteTypes ();
-
-                       return types;
-               }
-
-               void CompleteTypes ()
-               {
-                       var types = metadata.Types;
-
-                       for (int i = 0; i < types.Length; i++) {
-                               var type = types [i];
-
-                               InitializeCollection (type.Fields);
-                               InitializeCollection (type.Methods);
-                       }
-               }
-
-               void InitializeTypeDefinitions ()
-               {
-                       if (metadata.Types != null)
-                               return;
-
-                       InitializeNestedTypes ();
-                       InitializeFields ();
-                       InitializeMethods ();
-
-                       int length = MoveTo (Table.TypeDef);
-                       var types = metadata.Types = new TypeDefinition [length];
-
-                       for (uint i = 0; i < length; i++) {
-                               if (types [i] != null)
-                                       continue;
-
-                               types [i] = ReadType (i + 1);
-                       }
-               }
-
-               static bool IsNested (TypeAttributes attributes)
-               {
-                       switch (attributes & TypeAttributes.VisibilityMask) {
-                       case TypeAttributes.NestedAssembly:
-                       case TypeAttributes.NestedFamANDAssem:
-                       case TypeAttributes.NestedFamily:
-                       case TypeAttributes.NestedFamORAssem:
-                       case TypeAttributes.NestedPrivate:
-                       case TypeAttributes.NestedPublic:
-                               return true;
-                       default:
-                               return false;
-                       }
-               }
-
-               public bool HasNestedTypes (TypeDefinition type)
-               {
-                       uint [] mapping;
-                       InitializeNestedTypes ();
-
-                       if (!metadata.TryGetNestedTypeMapping (type, out mapping))
-                               return false;
-
-                       return mapping.Length > 0;
-               }
-
-               public Collection<TypeDefinition> ReadNestedTypes (TypeDefinition type)
-               {
-                       InitializeNestedTypes ();
-                       uint [] mapping;
-                       if (!metadata.TryGetNestedTypeMapping (type, out mapping))
-                               return new MemberDefinitionCollection<TypeDefinition> (type);
-
-                       var nested_types = new MemberDefinitionCollection<TypeDefinition> (type, mapping.Length);
-
-                       for (int i = 0; i < mapping.Length; i++)
-                               nested_types.Add (GetTypeDefinition (mapping [i]));
-
-                       metadata.RemoveNestedTypeMapping (type);
-
-                       return nested_types;
-               }
-
-               void InitializeNestedTypes ()
-               {
-                       if (metadata.NestedTypes != null)
-                               return;
-
-                       var length = MoveTo (Table.NestedClass);
-
-                       metadata.NestedTypes = new Dictionary<uint, uint []> (length);
-                       metadata.ReverseNestedTypes = new Dictionary<uint, uint> (length);
-
-                       if (length == 0)
-                               return;
-
-                       for (int i = 1; i <= length; i++) {
-                               var nested = ReadTableIndex (Table.TypeDef);
-                               var declaring = ReadTableIndex (Table.TypeDef);
-
-                               AddNestedMapping (declaring, nested);
-                       }
-               }
-
-               void AddNestedMapping (uint declaring, uint nested)
-               {
-                       metadata.SetNestedTypeMapping (declaring, AddMapping (metadata.NestedTypes, declaring, nested));
-                       metadata.SetReverseNestedTypeMapping (nested, declaring);
-               }
-
-               static TValue [] AddMapping<TKey, TValue> (Dictionary<TKey, TValue []> cache, TKey key, TValue value)
-               {
-                       TValue [] mapped;
-                       if (!cache.TryGetValue (key, out mapped)) {
-                               mapped = new [] { value };
-                               return mapped;
-                       }
-
-                       var new_mapped = new TValue [mapped.Length + 1];
-                       Array.Copy (mapped, new_mapped, mapped.Length);
-                       new_mapped [mapped.Length] = value;
-                       return new_mapped;
-               }
-
-               TypeDefinition ReadType (uint rid)
-               {
-                       if (!MoveTo (Table.TypeDef, rid))
-                               return null;
-
-                       var attributes = (TypeAttributes) ReadUInt32 ();
-                       var name = ReadString ();
-                       var @namespace = ReadString ();
-                       var type = new TypeDefinition (@namespace, name, attributes);
-                       type.token = new MetadataToken (TokenType.TypeDef, rid);
-                       type.scope = module;
-                       type.module = module;
-
-                       metadata.AddTypeDefinition (type);
-
-                       this.context = type;
-
-                       type.BaseType = GetTypeDefOrRef (ReadMetadataToken (CodedIndex.TypeDefOrRef));
-
-                       type.fields_range = ReadFieldsRange (rid);
-                       type.methods_range = ReadMethodsRange (rid);
-
-                       if (IsNested (attributes))
-                               type.DeclaringType = GetNestedTypeDeclaringType (type);
-
-                       return type;
-               }
-
-               TypeDefinition GetNestedTypeDeclaringType (TypeDefinition type)
-               {
-                       uint declaring_rid;
-                       if (!metadata.TryGetReverseNestedTypeMapping (type, out declaring_rid))
-                               return null;
-
-                       metadata.RemoveReverseNestedTypeMapping (type);
-                       return GetTypeDefinition (declaring_rid);
-               }
-
-               Range ReadFieldsRange (uint type_index)
-               {
-                       return ReadListRange (type_index, Table.TypeDef, Table.Field);
-               }
-
-               Range ReadMethodsRange (uint type_index)
-               {
-                       return ReadListRange (type_index, Table.TypeDef, Table.Method);
-               }
-
-               Range ReadListRange (uint current_index, Table current, Table target)
-               {
-                       var list = new Range ();
-
-                       list.Start = ReadTableIndex (target);
-
-                       uint next_index;
-                       var current_table = image.TableHeap [current];
-
-                       if (current_index == current_table.Length)
-                               next_index = image.TableHeap [target].Length + 1;
-                       else {
-                               var position = Position;
-                               Position += (uint) (current_table.RowSize - image.GetTableIndexSize (target));
-                               next_index = ReadTableIndex (target);
-                               Position = position;
-                       }
-
-                       list.Length = next_index - list.Start;
-
-                       return list;
-               }
-
-               public Row<short, int> ReadTypeLayout (TypeDefinition type)
-               {
-                       InitializeTypeLayouts ();
-                       Row<ushort, uint> class_layout;
-                       var rid = type.token.RID;
-                       if (!metadata.ClassLayouts.TryGetValue (rid, out class_layout))
-                               return new Row<short, int> (Mixin.NoDataMarker, Mixin.NoDataMarker);
-
-                       type.PackingSize = (short) class_layout.Col1;
-                       type.ClassSize = (int) class_layout.Col2;
-
-                       metadata.ClassLayouts.Remove (rid);
-
-                       return new Row<short, int> ((short) class_layout.Col1, (int) class_layout.Col2);
-               }
-
-               void InitializeTypeLayouts ()
-               {
-                       if (metadata.ClassLayouts != null)
-                               return;
-
-                       int length = MoveTo (Table.ClassLayout);
-
-                       var class_layouts = metadata.ClassLayouts = new Dictionary<uint, Row<ushort, uint>> (length);
-
-                       for (uint i = 0; i < length; i++) {
-                               var packing_size = ReadUInt16 ();
-                               var class_size = ReadUInt32 ();
-
-                               var parent = ReadTableIndex (Table.TypeDef);
-
-                               class_layouts.Add (parent, new Row<ushort, uint> (packing_size, class_size));
-                       }
-               }
-
-               public TypeReference GetTypeDefOrRef (MetadataToken token)
-               {
-                       return (TypeReference) LookupToken (token);
-               }
-
-               public TypeDefinition GetTypeDefinition (uint rid)
-               {
-                       InitializeTypeDefinitions ();
-
-                       var type = metadata.GetTypeDefinition (rid);
-                       if (type != null)
-                               return type;
-
-                       return ReadTypeDefinition (rid);
-               }
-
-               TypeDefinition ReadTypeDefinition (uint rid)
-               {
-                       if (!MoveTo (Table.TypeDef, rid))
-                               return null;
-
-                       return ReadType (rid);
-               }
-
-               void InitializeTypeReferences ()
-               {
-                       if (metadata.TypeReferences != null)
-                               return;
-
-                       metadata.TypeReferences = new TypeReference [image.GetTableLength (Table.TypeRef)];
-               }
-
-               public TypeReference GetTypeReference (string scope, string full_name)
-               {
-                       InitializeTypeReferences ();
-
-                       var length = metadata.TypeReferences.Length;
-
-                       for (uint i = 1; i <= length; i++) {
-                               var type = GetTypeReference (i);
-
-                               if (type.FullName != full_name)
-                                       continue;
-
-                               if (string.IsNullOrEmpty (scope))
-                                       return type;
-
-                               if (type.Scope.Name == scope)
-                                       return type;
-                       }
-
-                       return null;
-               }
-
-               TypeReference GetTypeReference (uint rid)
-               {
-                       InitializeTypeReferences ();
-
-                       var type = metadata.GetTypeReference (rid);
-                       if (type != null)
-                               return type;
-
-                       return ReadTypeReference (rid);
-               }
-
-               TypeReference ReadTypeReference (uint rid)
-               {
-                       if (!MoveTo (Table.TypeRef, rid))
-                               return null;
-
-                       TypeReference declaring_type = null;
-                       IMetadataScope scope;
-
-                       var scope_token = ReadMetadataToken (CodedIndex.ResolutionScope);
-
-                       var name = ReadString ();
-                       var @namespace = ReadString ();
-
-                       var type = new TypeReference (
-                               @namespace,
-                               name,
-                               module,
-                               null);
-
-                       type.token = new MetadataToken (TokenType.TypeRef, rid);
-
-                       metadata.AddTypeReference (type);
-
-                       if (scope_token.TokenType == TokenType.TypeRef) {
-                               declaring_type = GetTypeDefOrRef (scope_token);
-
-                               scope = declaring_type != null
-                                       ? declaring_type.Scope
-                                       : module;
-                       } else
-                               scope = GetTypeReferenceScope (scope_token);
-
-                       type.scope = scope;
-                       type.DeclaringType = declaring_type;
-
-                       MetadataSystem.TryProcessPrimitiveType (type);
-
-                       return type;
-               }
-
-               IMetadataScope GetTypeReferenceScope (MetadataToken scope)
-               {
-                       switch (scope.TokenType) {
-                       case TokenType.AssemblyRef:
-                               InitializeAssemblyReferences ();
-                               return metadata.AssemblyReferences [(int) scope.RID - 1];
-                       case TokenType.ModuleRef:
-                               InitializeModuleReferences ();
-                               return metadata.ModuleReferences [(int) scope.RID - 1];
-                       case TokenType.Module:
-                               return module;
-                       default:
-                               throw new NotSupportedException ();
-                       }
-               }
-
-               public IEnumerable<TypeReference> GetTypeReferences ()
-               {
-                       InitializeTypeReferences ();
-
-                       var length = image.GetTableLength (Table.TypeRef);
-
-                       var type_references = new TypeReference [length];
-
-                       for (uint i = 1; i <= length; i++)
-                               type_references [i - 1] = GetTypeReference (i);
-
-                       return type_references;
-               }
-
-               TypeReference GetTypeSpecification (uint rid)
-               {
-                       if (!MoveTo (Table.TypeSpec, rid))
-                               return null;
-
-                       var reader = ReadSignature (ReadBlobIndex ());
-                       var type = reader.ReadTypeSignature ();
-                       if (type.token.RID == 0)
-                               type.token = new MetadataToken (TokenType.TypeSpec, rid);
-
-                       return type;
-               }
-
-               SignatureReader ReadSignature (uint signature)
-               {
-                       return new SignatureReader (signature, this);
-               }
-
-               public bool HasInterfaces (TypeDefinition type)
-               {
-                       InitializeInterfaces ();
-                       MetadataToken [] mapping;
-
-                       return metadata.TryGetInterfaceMapping (type, out mapping);
-               }
-
-               public Collection<TypeReference> ReadInterfaces (TypeDefinition type)
-               {
-                       InitializeInterfaces ();
-                       MetadataToken [] mapping;
-
-                       if (!metadata.TryGetInterfaceMapping (type, out mapping))
-                               return new Collection<TypeReference> ();
-
-                       var interfaces = new Collection<TypeReference> (mapping.Length);
-
-                       this.context = type;
-
-                       for (int i = 0; i < mapping.Length; i++)
-                               interfaces.Add (GetTypeDefOrRef (mapping [i]));
-
-                       metadata.RemoveInterfaceMapping (type);
-
-                       return interfaces;
-               }
-
-               void InitializeInterfaces ()
-               {
-                       if (metadata.Interfaces != null)
-                               return;
-
-                       int length = MoveTo (Table.InterfaceImpl);
-
-                       metadata.Interfaces = new Dictionary<uint, MetadataToken []> (length);
-
-                       for (int i = 0; i < length; i++) {
-                               var type = ReadTableIndex (Table.TypeDef);
-                               var @interface = ReadMetadataToken (CodedIndex.TypeDefOrRef);
-
-                               AddInterfaceMapping (type, @interface);
-                       }
-               }
-
-               void AddInterfaceMapping (uint type, MetadataToken @interface)
-               {
-                       metadata.SetInterfaceMapping (type, AddMapping (metadata.Interfaces, type, @interface));
-               }
-
-               public Collection<FieldDefinition> ReadFields (TypeDefinition type)
-               {
-                       var fields_range = type.fields_range;
-                       if (fields_range.Length == 0)
-                               return new MemberDefinitionCollection<FieldDefinition> (type);
-
-                       var fields = new MemberDefinitionCollection<FieldDefinition> (type, (int) fields_range.Length);
-                       this.context = type;
-
-                       if (!MoveTo (Table.FieldPtr, fields_range.Start)) {
-                               if (!MoveTo (Table.Field, fields_range.Start))
-                                       return fields;
-
-                               for (uint i = 0; i < fields_range.Length; i++)
-                                       ReadField (fields_range.Start + i, fields);
-                       } else
-                               ReadPointers (Table.FieldPtr, Table.Field, fields_range, fields, ReadField);
-
-                       return fields;
-               }
-
-               void ReadField (uint field_rid, Collection<FieldDefinition> fields)
-               {
-                       var attributes = (FieldAttributes) ReadUInt16 ();
-                       var name = ReadString ();
-                       var signature = ReadBlobIndex ();
-
-                       var field = new FieldDefinition (name, attributes, ReadFieldType (signature));
-                       field.token = new MetadataToken (TokenType.Field, field_rid);
-                       metadata.AddFieldDefinition (field);
-
-                       if (IsDeleted (field))
-                               return;
-
-                       fields.Add (field);
-               }
-
-               void InitializeFields ()
-               {
-                       if (metadata.Fields != null)
-                               return;
-
-                       metadata.Fields = new FieldDefinition [image.GetTableLength (Table.Field)];
-               }
-
-               TypeReference ReadFieldType (uint signature)
-               {
-                       var reader = ReadSignature (signature);
-
-                       const byte field_sig = 0x6;
-
-                       if (reader.ReadByte () != field_sig)
-                               throw new NotSupportedException ();
-
-                       return reader.ReadTypeSignature ();
-               }
-
-               public int ReadFieldRVA (FieldDefinition field)
-               {
-                       InitializeFieldRVAs ();
-                       var rid = field.token.RID;
-
-                       RVA rva;
-                       if (!metadata.FieldRVAs.TryGetValue (rid, out rva))
-                               return 0;
-
-                       var size = GetFieldTypeSize (field.FieldType);
-
-                       if (size == 0 || rva == 0)
-                               return 0;
-
-                       metadata.FieldRVAs.Remove (rid);
-
-                       field.InitialValue = GetFieldInitializeValue (size, rva);
-
-                       return (int) rva;
-               }
-
-               byte [] GetFieldInitializeValue (int size, RVA rva)
-               {
-                       var section = image.GetSectionAtVirtualAddress (rva);
-                       if (section == null)
-                               return Empty<byte>.Array;
-
-                       var value = new byte [size];
-                       Buffer.BlockCopy (section.Data, (int) (rva - section.VirtualAddress), value, 0, size);
-                       return value;
-               }
-
-               static int GetFieldTypeSize (TypeReference type)
-               {
-                       int size = 0;
-
-                       switch (type.etype) {
-                       case ElementType.Boolean:
-                       case ElementType.U1:
-                       case ElementType.I1:
-                               size = 1;
-                               break;
-                       case ElementType.U2:
-                       case ElementType.I2:
-                       case ElementType.Char:
-                               size = 2;
-                               break;
-                       case ElementType.U4:
-                       case ElementType.I4:
-                       case ElementType.R4:
-                               size = 4;
-                               break;
-                       case ElementType.U8:
-                       case ElementType.I8:
-                       case ElementType.R8:
-                               size = 8;
-                               break;
-                       case ElementType.Ptr:
-                       case ElementType.FnPtr:
-                               size = IntPtr.Size;
-                               break;
-                       case ElementType.CModOpt:
-                       case ElementType.CModReqD:
-                               return GetFieldTypeSize (((IModifierType) type).ElementType);
-                       default:
-                               var field_type = type.CheckedResolve ();
-                               if (field_type.HasLayoutInfo)
-                                       size = field_type.ClassSize;
-
-                               break;
-                       }
-
-                       return size;
-               }
-
-               void InitializeFieldRVAs ()
-               {
-                       if (metadata.FieldRVAs != null)
-                               return;
-
-                       int length = MoveTo (Table.FieldRVA);
-
-                       var field_rvas = metadata.FieldRVAs = new Dictionary<uint, uint> (length);
-
-                       for (int i = 0; i < length; i++) {
-                               var rva = ReadUInt32 ();
-                               var field = ReadTableIndex (Table.Field);
-
-                               field_rvas.Add (field, rva);
-                       }
-               }
-
-               public int ReadFieldLayout (FieldDefinition field)
-               {
-                       InitializeFieldLayouts ();
-                       var rid = field.token.RID;
-                       uint offset;
-                       if (!metadata.FieldLayouts.TryGetValue (rid, out offset))
-                               return Mixin.NoDataMarker;
-
-                       metadata.FieldLayouts.Remove (rid);
-
-                       return (int) offset;
-               }
-
-               void InitializeFieldLayouts ()
-               {
-                       if (metadata.FieldLayouts != null)
-                               return;
-
-                       int length = MoveTo (Table.FieldLayout);
-
-                       var field_layouts = metadata.FieldLayouts = new Dictionary<uint, uint> (length);
-
-                       for (int i = 0; i < length; i++) {
-                               var offset = ReadUInt32 ();
-                               var field = ReadTableIndex (Table.Field);
-
-                               field_layouts.Add (field, offset);
-                       }
-               }
-
-               public bool HasEvents (TypeDefinition type)
-               {
-                       InitializeEvents ();
-
-                       Range range;
-                       if (!metadata.TryGetEventsRange (type, out range))
-                               return false;
-
-                       return range.Length > 0;
-               }
-
-               public Collection<EventDefinition> ReadEvents (TypeDefinition type)
-               {
-                       InitializeEvents ();
-                       Range range;
-
-                       if (!metadata.TryGetEventsRange (type, out range))
-                               return new MemberDefinitionCollection<EventDefinition> (type);
-
-                       var events = new MemberDefinitionCollection<EventDefinition> (type, (int) range.Length);
-
-                       metadata.RemoveEventsRange (type);
-
-                       if (range.Length == 0)
-                               return events;
-
-                       this.context = type;
-
-                       if (!MoveTo (Table.EventPtr, range.Start)) {
-                               if (!MoveTo (Table.Event, range.Start))
-                                       return events;
-
-                               for (uint i = 0; i < range.Length; i++)
-                                       ReadEvent (range.Start + i, events);
-                       } else
-                               ReadPointers (Table.EventPtr, Table.Event, range, events, ReadEvent);
-
-                       return events;
-               }
-
-               void ReadEvent (uint event_rid, Collection<EventDefinition> events)
-               {
-                       var attributes = (EventAttributes) ReadUInt16 ();
-                       var name = ReadString ();
-                       var event_type = GetTypeDefOrRef (ReadMetadataToken (CodedIndex.TypeDefOrRef));
-
-                       var @event = new EventDefinition (name, attributes, event_type);
-                       @event.token = new MetadataToken (TokenType.Event, event_rid);
-
-                       if (IsDeleted (@event))
-                               return;
-
-                       events.Add (@event);
-               }
-
-               void InitializeEvents ()
-               {
-                       if (metadata.Events != null)
-                               return;
-
-                       int length = MoveTo (Table.EventMap);
-
-                       metadata.Events = new Dictionary<uint, Range> (length);
-
-                       for (uint i = 1; i <= length; i++) {
-                               var type_rid = ReadTableIndex (Table.TypeDef);
-                               Range events_range = ReadEventsRange (i);
-                               metadata.AddEventsRange (type_rid, events_range);
-                       }
-               }
-
-               Range ReadEventsRange (uint rid)
-               {
-                       return ReadListRange (rid, Table.EventMap, Table.Event);
-               }
-
-               public bool HasProperties (TypeDefinition type)
-               {
-                       InitializeProperties ();
-
-                       Range range;
-                       if (!metadata.TryGetPropertiesRange (type, out range))
-                               return false;
-
-                       return range.Length > 0;
-               }
-
-               public Collection<PropertyDefinition> ReadProperties (TypeDefinition type)
-               {
-                       InitializeProperties ();
-
-                       Range range;
-
-                       if (!metadata.TryGetPropertiesRange (type, out range))
-                               return new MemberDefinitionCollection<PropertyDefinition> (type);
-
-                       metadata.RemovePropertiesRange (type);
-
-                       var properties = new MemberDefinitionCollection<PropertyDefinition> (type, (int) range.Length);
-
-                       if (range.Length == 0)
-                               return properties;
-
-                       this.context = type;
-
-                       if (!MoveTo (Table.PropertyPtr, range.Start)) {
-                               if (!MoveTo (Table.Property, range.Start))
-                                       return properties;
-                               for (uint i = 0; i < range.Length; i++)
-                                       ReadProperty (range.Start + i, properties);
-                       } else
-                               ReadPointers (Table.PropertyPtr, Table.Property, range, properties, ReadProperty);
-
-                       return properties;
-               }
-
-               void ReadProperty (uint property_rid, Collection<PropertyDefinition> properties)
-               {
-                       var attributes = (PropertyAttributes) ReadUInt16 ();
-                       var name = ReadString ();
-                       var signature = ReadBlobIndex ();
-
-                       var reader = ReadSignature (signature);
-                       const byte property_signature = 0x8;
-
-                       var calling_convention = reader.ReadByte ();
-
-                       if ((calling_convention & property_signature) == 0)
-                               throw new NotSupportedException ();
-
-                       var has_this = (calling_convention & 0x20) != 0;
-
-                       reader.ReadCompressedUInt32 (); // count
-
-                       var property = new PropertyDefinition (name, attributes, reader.ReadTypeSignature ());
-                       property.HasThis = has_this;
-                       property.token = new MetadataToken (TokenType.Property, property_rid);
-
-                       if (IsDeleted (property))
-                               return;
-
-                       properties.Add (property);
-               }
-
-               void InitializeProperties ()
-               {
-                       if (metadata.Properties != null)
-                               return;
-
-                       int length = MoveTo (Table.PropertyMap);
-
-                       metadata.Properties = new Dictionary<uint, Range> (length);
-
-                       for (uint i = 1; i <= length; i++) {
-                               var type_rid = ReadTableIndex (Table.TypeDef);
-                               var properties_range = ReadPropertiesRange (i);
-                               metadata.AddPropertiesRange (type_rid, properties_range);
-                       }
-               }
-
-               Range ReadPropertiesRange (uint rid)
-               {
-                       return ReadListRange (rid, Table.PropertyMap, Table.Property);
-               }
-
-               MethodSemanticsAttributes ReadMethodSemantics (MethodDefinition method)
-               {
-                       InitializeMethodSemantics ();
-                       Row<MethodSemanticsAttributes, MetadataToken> row;
-                       if (!metadata.Semantics.TryGetValue (method.token.RID, out row))
-                               return MethodSemanticsAttributes.None;
-
-                       var type = method.DeclaringType;
-
-                       switch (row.Col1) {
-                       case MethodSemanticsAttributes.AddOn:
-                               GetEvent (type, row.Col2).add_method = method;
-                               break;
-                       case MethodSemanticsAttributes.Fire:
-                               GetEvent (type, row.Col2).invoke_method = method;
-                               break;
-                       case MethodSemanticsAttributes.RemoveOn:
-                               GetEvent (type, row.Col2).remove_method = method;
-                               break;
-                       case MethodSemanticsAttributes.Getter:
-                               GetProperty (type, row.Col2).get_method = method;
-                               break;
-                       case MethodSemanticsAttributes.Setter:
-                               GetProperty (type, row.Col2).set_method = method;
-                               break;
-                       case MethodSemanticsAttributes.Other:
-                               switch (row.Col2.TokenType) {
-                               case TokenType.Event: {
-                                       var @event = GetEvent (type, row.Col2);
-                                       if (@event.other_methods == null)
-                                               @event.other_methods = new Collection<MethodDefinition> ();
-
-                                       @event.other_methods.Add (method);
-                                       break;
-                               }
-                               case TokenType.Property: {
-                                       var property = GetProperty (type, row.Col2);
-                                       if (property.other_methods == null)
-                                               property.other_methods = new Collection<MethodDefinition> ();
-
-                                       property.other_methods.Add (method);
-
-                                       break;
-                               }
-                               default:
-                                       throw new NotSupportedException ();
-                               }
-                               break;
-                       default:
-                               throw new NotSupportedException ();
-                       }
-
-                       metadata.Semantics.Remove (method.token.RID);
-
-                       return row.Col1;
-               }
-
-               static EventDefinition GetEvent (TypeDefinition type, MetadataToken token)
-               {
-                       if (token.TokenType != TokenType.Event)
-                               throw new ArgumentException ();
-
-                       return GetMember (type.Events, token);
-               }
-
-               static PropertyDefinition GetProperty (TypeDefinition type, MetadataToken token)
-               {
-                       if (token.TokenType != TokenType.Property)
-                               throw new ArgumentException ();
-
-                       return GetMember (type.Properties, token);
-               }
-
-               static TMember GetMember<TMember> (Collection<TMember> members, MetadataToken token) where TMember : IMemberDefinition
-               {
-                       for (int i = 0; i < members.Count; i++) {
-                               var member = members [i];
-                               if (member.MetadataToken == token)
-                                       return member;
-                       }
-
-                       throw new ArgumentException ();
-               }
-
-               void InitializeMethodSemantics ()
-               {
-                       if (metadata.Semantics != null)
-                               return;
-
-                       int length = MoveTo (Table.MethodSemantics);
-
-                       var semantics = metadata.Semantics = new Dictionary<uint, Row<MethodSemanticsAttributes, MetadataToken>> (0);
-
-                       for (uint i = 0; i < length; i++) {
-                               var attributes = (MethodSemanticsAttributes) ReadUInt16 ();
-                               var method_rid = ReadTableIndex (Table.Method);
-                               var association = ReadMetadataToken (CodedIndex.HasSemantics);
-
-                               semantics [method_rid] = new Row<MethodSemanticsAttributes, MetadataToken> (attributes, association);
-                       }
-               }
-
-               public PropertyDefinition ReadMethods (PropertyDefinition property)
-               {
-                       ReadAllSemantics (property.DeclaringType);
-                       return property;
-               }
-
-               public EventDefinition ReadMethods (EventDefinition @event)
-               {
-                       ReadAllSemantics (@event.DeclaringType);
-                       return @event;
-               }
-
-               public MethodSemanticsAttributes ReadAllSemantics (MethodDefinition method)
-               {
-                       ReadAllSemantics (method.DeclaringType);
-
-                       return method.SemanticsAttributes;
-               }
-
-               void ReadAllSemantics (TypeDefinition type)
-               {
-                       var methods = type.Methods;
-                       for (int i = 0; i < methods.Count; i++) {
-                               var method = methods [i];
-                               if (method.sem_attrs.HasValue)
-                                       continue;
-
-                               method.sem_attrs = ReadMethodSemantics (method);
-                       }
-               }
-
-               Range ReadParametersRange (uint method_rid)
-               {
-                       return ReadListRange (method_rid, Table.Method, Table.Param);
-               }
-
-               public Collection<MethodDefinition> ReadMethods (TypeDefinition type)
-               {
-                       var methods_range = type.methods_range;
-                       if (methods_range.Length == 0)
-                               return new MemberDefinitionCollection<MethodDefinition> (type);
-
-                       var methods = new MemberDefinitionCollection<MethodDefinition> (type, (int) methods_range.Length);
-                       if (!MoveTo (Table.MethodPtr, methods_range.Start)) {
-                               if (!MoveTo (Table.Method, methods_range.Start))
-                                       return methods;
-
-                               for (uint i = 0; i < methods_range.Length; i++)
-                                       ReadMethod (methods_range.Start + i, methods);
-                       } else
-                               ReadPointers (Table.MethodPtr, Table.Method, methods_range, methods, ReadMethod);
-
-                       return methods;
-               }
-
-               void ReadPointers<TMember> (Table ptr, Table table, Range range, Collection<TMember> members, Action<uint, Collection<TMember>> reader)
-                       where TMember : IMemberDefinition
-               {
-                       for (uint i = 0; i < range.Length; i++) {
-                               MoveTo (ptr, range.Start + i);
-
-                               var rid = ReadTableIndex (table);
-                               MoveTo (table, rid);
-
-                               reader (rid, members);
-                       }
-               }
-
-               static bool IsDeleted (IMemberDefinition member)
-               {
-                       return member.IsSpecialName && member.Name == "_Deleted";
-               }
-
-               void InitializeMethods ()
-               {
-                       if (metadata.Methods != null)
-                               return;
-
-                       metadata.Methods = new MethodDefinition [image.GetTableLength (Table.Method)];
-               }
-
-               void ReadMethod (uint method_rid, Collection<MethodDefinition> methods)
-               {
-                       var method = new MethodDefinition ();
-                       method.rva = ReadUInt32 ();
-                       method.ImplAttributes = (MethodImplAttributes) ReadUInt16 ();
-                       method.Attributes = (MethodAttributes) ReadUInt16 ();
-                       method.Name = ReadString ();
-                       method.token = new MetadataToken (TokenType.Method, method_rid);
-
-                       if (IsDeleted (method))
-                               return;
-
-                       methods.Add (method); // attach method
-
-                       var signature = ReadBlobIndex ();
-                       var param_range = ReadParametersRange (method_rid);
-
-                       this.context = method;
-
-                       ReadMethodSignature (signature, method);
-                       metadata.AddMethodDefinition (method);
-
-                       if (param_range.Length == 0)
-                               return;
-
-                       var position = base.position;
-                       ReadParameters (method, param_range);
-                       base.position = position;
-               }
-
-               void ReadParameters (MethodDefinition method, Range param_range)
-               {
-                       if (!MoveTo (Table.ParamPtr, param_range.Start)) {
-                               if (!MoveTo (Table.Param, param_range.Start))
-                                       return;
-
-                               for (uint i = 0; i < param_range.Length; i++)
-                                       ReadParameter (param_range.Start + i, method);
-                       } else
-                               ReadParameterPointers (method, param_range);
-               }
-
-               void ReadParameterPointers (MethodDefinition method, Range range)
-               {
-                       for (uint i = 0; i < range.Length; i++) {
-                               MoveTo (Table.ParamPtr, range.Start + i);
-
-                               var rid = ReadTableIndex (Table.Param);
-
-                               MoveTo (Table.Param, rid);
-
-                               ReadParameter (rid, method);
-                       }
-               }
-
-               void ReadParameter (uint param_rid, MethodDefinition method)
-               {
-                       var attributes = (ParameterAttributes) ReadUInt16 ();
-                       var sequence = ReadUInt16 ();
-                       var name = ReadString ();
-
-                       var parameter = sequence == 0
-                               ? method.MethodReturnType.Parameter
-                               : method.Parameters [sequence - 1];
-
-                       parameter.token = new MetadataToken (TokenType.Param, param_rid);
-                       parameter.Name = name;
-                       parameter.Attributes = attributes;
-               }
-
-               void ReadMethodSignature (uint signature, IMethodSignature method)
-               {
-                       var reader = ReadSignature (signature);
-                       reader.ReadMethodSignature (method);
-               }
-
-               public PInvokeInfo ReadPInvokeInfo (MethodDefinition method)
-               {
-                       InitializePInvokes ();
-                       Row<PInvokeAttributes, uint, uint> row;
-
-                       var rid = method.token.RID;
-
-                       if (!metadata.PInvokes.TryGetValue (rid, out row))
-                               return null;
-
-                       metadata.PInvokes.Remove (rid);
-
-                       return new PInvokeInfo (
-                               row.Col1,
-                               image.StringHeap.Read (row.Col2),
-                               module.ModuleReferences [(int) row.Col3 - 1]);
-               }
-
-               void InitializePInvokes ()
-               {
-                       if (metadata.PInvokes != null)
-                               return;
-
-                       int length = MoveTo (Table.ImplMap);
-
-                       var pinvokes = metadata.PInvokes = new Dictionary<uint, Row<PInvokeAttributes, uint, uint>> (length);
-
-                       for (int i = 1; i <= length; i++) {
-                               var attributes = (PInvokeAttributes) ReadUInt16 ();
-                               var method = ReadMetadataToken (CodedIndex.MemberForwarded);
-                               var name = ReadStringIndex ();
-                               var scope = ReadTableIndex (Table.File);
-
-                               if (method.TokenType != TokenType.Method)
-                                       continue;
-
-                               pinvokes.Add (method.RID, new Row<PInvokeAttributes, uint, uint> (attributes, name, scope));
-                       }
-               }
-
-               public bool HasGenericParameters (IGenericParameterProvider provider)
-               {
-                       InitializeGenericParameters ();
-
-                       Range range;
-                       if (!metadata.TryGetGenericParameterRange (provider, out range))
-                               return false;
-
-                       return range.Length > 0;
-               }
-
-               public Collection<GenericParameter> ReadGenericParameters (IGenericParameterProvider provider)
-               {
-                       InitializeGenericParameters ();
-
-                       Range range;
-                       if (!metadata.TryGetGenericParameterRange (provider, out range)
-                               || !MoveTo (Table.GenericParam, range.Start))
-                               return new GenericParameterCollection (provider);
-
-                       metadata.RemoveGenericParameterRange (provider);
-
-                       var generic_parameters = new GenericParameterCollection (provider, (int) range.Length);
-
-                       for (uint i = 0; i < range.Length; i++) {
-                               ReadUInt16 (); // index
-                               var flags = (GenericParameterAttributes) ReadUInt16 ();
-                               ReadMetadataToken (CodedIndex.TypeOrMethodDef);
-                               var name = ReadString ();
-
-                               var parameter = new GenericParameter (name, provider);
-                               parameter.token = new MetadataToken (TokenType.GenericParam, range.Start + i);
-                               parameter.Attributes = flags;
-
-                               generic_parameters.Add (parameter);
-                       }
-
-                       return generic_parameters;
-               }
-
-               void InitializeGenericParameters ()
-               {
-                       if (metadata.GenericParameters != null)
-                               return;
-
-                       metadata.GenericParameters = InitializeRanges (
-                               Table.GenericParam, () => {
-                                       Advance (4);
-                                       var next = ReadMetadataToken (CodedIndex.TypeOrMethodDef);
-                                       ReadStringIndex ();
-                                       return next;
-                       });
-               }
-
-               Dictionary<MetadataToken, Range> InitializeRanges (Table table, Func<MetadataToken> get_next)
-               {
-                       int length = MoveTo (table);
-                       var ranges = new Dictionary<MetadataToken, Range> (length);
-
-                       if (length == 0)
-                               return ranges;
-
-                       MetadataToken owner = MetadataToken.Zero;
-                       Range range = new Range (1, 0);
-
-                       for (uint i = 1; i <= length; i++) {
-                               var next = get_next ();
-
-                               if (i == 1) {
-                                       owner = next;
-                                       range.Length++;
-                               } else if (next != owner) {
-                                       if (owner.RID != 0)
-                                               ranges.Add (owner, range);
-                                       range = new Range (i, 1);
-                                       owner = next;
-                               } else
-                                       range.Length++;
-                       }
-
-                       if (owner != MetadataToken.Zero && !ranges.ContainsKey (owner))
-                               ranges.Add (owner, range);
-
-                       return ranges;
-               }
-
-               public bool HasGenericConstraints (GenericParameter generic_parameter)
-               {
-                       InitializeGenericConstraints ();
-
-                       MetadataToken [] mapping;
-                       if (!metadata.TryGetGenericConstraintMapping (generic_parameter, out mapping))
-                               return false;
-
-                       return mapping.Length > 0;
-               }
-
-               public Collection<TypeReference> ReadGenericConstraints (GenericParameter generic_parameter)
-               {
-                       InitializeGenericConstraints ();
-
-                       MetadataToken [] mapping;
-                       if (!metadata.TryGetGenericConstraintMapping (generic_parameter, out mapping))
-                               return new Collection<TypeReference> ();
-
-                       var constraints = new Collection<TypeReference> (mapping.Length);
-
-                       this.context = (IGenericContext) generic_parameter.Owner;
-
-                       for (int i = 0; i < mapping.Length; i++)
-                               constraints.Add (GetTypeDefOrRef (mapping [i]));
-
-                       metadata.RemoveGenericConstraintMapping (generic_parameter);
-
-                       return constraints;
-               }
-
-               void InitializeGenericConstraints ()
-               {
-                       if (metadata.GenericConstraints != null)
-                               return;
-
-                       var length = MoveTo (Table.GenericParamConstraint);
-
-                       metadata.GenericConstraints = new Dictionary<uint, MetadataToken []> (length);
-
-                       for (int i = 1; i <= length; i++)
-                               AddGenericConstraintMapping (
-                                       ReadTableIndex (Table.GenericParam),
-                                       ReadMetadataToken (CodedIndex.TypeDefOrRef));
-               }
-
-               void AddGenericConstraintMapping (uint generic_parameter, MetadataToken constraint)
-               {
-                       metadata.SetGenericConstraintMapping (
-                               generic_parameter,
-                               AddMapping (metadata.GenericConstraints, generic_parameter, constraint));
-               }
-
-               public bool HasOverrides (MethodDefinition method)
-               {
-                       InitializeOverrides ();
-                       MetadataToken [] mapping;
-
-                       if (!metadata.TryGetOverrideMapping (method, out mapping))
-                               return false;
-
-                       return mapping.Length > 0;
-               }
-
-               public Collection<MethodReference> ReadOverrides (MethodDefinition method)
-               {
-                       InitializeOverrides ();
-
-                       MetadataToken [] mapping;
-                       if (!metadata.TryGetOverrideMapping (method, out mapping))
-                               return new Collection<MethodReference> ();
-
-                       var overrides = new Collection<MethodReference> (mapping.Length);
-
-                       this.context = method;
-
-                       for (int i = 0; i < mapping.Length; i++)
-                               overrides.Add ((MethodReference) LookupToken (mapping [i]));
-
-                       metadata.RemoveOverrideMapping (method);
-
-                       return overrides;
-               }
-
-               void InitializeOverrides ()
-               {
-                       if (metadata.Overrides != null)
-                               return;
-
-                       var length = MoveTo (Table.MethodImpl);
-
-                       metadata.Overrides = new Dictionary<uint, MetadataToken []> (length);
-
-                       for (int i = 1; i <= length; i++) {
-                               ReadTableIndex (Table.TypeDef);
-
-                               var method = ReadMetadataToken (CodedIndex.MethodDefOrRef);
-                               if (method.TokenType != TokenType.Method)
-                                       throw new NotSupportedException ();
-
-                               var @override = ReadMetadataToken (CodedIndex.MethodDefOrRef);
-
-                               AddOverrideMapping (method.RID, @override);
-                       }
-               }
-
-               void AddOverrideMapping (uint method_rid, MetadataToken @override)
-               {
-                       metadata.SetOverrideMapping (
-                               method_rid,
-                               AddMapping (metadata.Overrides, method_rid, @override));
-               }
-
-               public MethodBody ReadMethodBody (MethodDefinition method)
-               {
-                       return code.ReadMethodBody (method);
-               }
-
-               public CallSite ReadCallSite (MetadataToken token)
-               {
-                       if (!MoveTo (Table.StandAloneSig, token.RID))
-                               return null;
-
-                       var signature = ReadBlobIndex ();
-
-                       var call_site = new CallSite ();
-
-                       ReadMethodSignature (signature, call_site);
-
-                       call_site.MetadataToken = token;
-
-                       return call_site;
-               }
-
-               public VariableDefinitionCollection ReadVariables (MetadataToken local_var_token)
-               {
-                       if (!MoveTo (Table.StandAloneSig, local_var_token.RID))
-                               return null;
-
-                       var reader = ReadSignature (ReadBlobIndex ());
-                       const byte local_sig = 0x7;
-
-                       if (reader.ReadByte () != local_sig)
-                               throw new NotSupportedException ();
-
-                       var count = reader.ReadCompressedUInt32 ();
-                       if (count == 0)
-                               return null;
-
-                       var variables = new VariableDefinitionCollection ((int) count);
-
-                       for (int i = 0; i < count; i++)
-                               variables.Add (new VariableDefinition (reader.ReadTypeSignature ()));
-
-                       return variables;
-               }
-
-               public IMetadataTokenProvider LookupToken (MetadataToken token)
-               {
-                       var rid = token.RID;
-
-                       if (rid == 0)
-                               return null;
-
-                       IMetadataTokenProvider element;
-                       var position = this.position;
-                       var context = this.context;
-
-                       switch (token.TokenType) {
-                       case TokenType.TypeDef:
-                               element = GetTypeDefinition (rid);
-                               break;
-                       case TokenType.TypeRef:
-                               element = GetTypeReference (rid);
-                               break;
-                       case TokenType.TypeSpec:
-                               element = GetTypeSpecification (rid);
-                               break;
-                       case TokenType.Field:
-                               element = GetFieldDefinition (rid);
-                               break;
-                       case TokenType.Method:
-                               element = GetMethodDefinition (rid);
-                               break;
-                       case TokenType.MemberRef:
-                               element = GetMemberReference (rid);
-                               break;
-                       case TokenType.MethodSpec:
-                               element = GetMethodSpecification (rid);
-                               break;
-                       default:
-                               return null;
-                       }
-
-                       this.position = position;
-                       this.context = context;
-
-                       return element;
-               }
-
-               public FieldDefinition GetFieldDefinition (uint rid)
-               {
-                       InitializeTypeDefinitions ();
-
-                       var field = metadata.GetFieldDefinition (rid);
-                       if (field != null)
-                               return field;
-
-                       return LookupField (rid);
-               }
-
-               FieldDefinition LookupField (uint rid)
-               {
-                       var type = metadata.GetFieldDeclaringType (rid);
-                       if (type == null)
-                               return null;
-
-                       InitializeCollection (type.Fields);
-
-                       return metadata.GetFieldDefinition (rid);
-               }
-
-               public MethodDefinition GetMethodDefinition (uint rid)
-               {
-                       InitializeTypeDefinitions ();
-
-                       var method = metadata.GetMethodDefinition (rid);
-                       if (method != null)
-                               return method;
-
-                       return LookupMethod (rid);
-               }
-
-               MethodDefinition LookupMethod (uint rid)
-               {
-                       var type = metadata.GetMethodDeclaringType (rid);
-                       if (type == null)
-                               return null;
-
-                       InitializeCollection (type.Methods);
-
-                       return metadata.GetMethodDefinition (rid);
-               }
-
-               MethodSpecification GetMethodSpecification (uint rid)
-               {
-                       if (!MoveTo (Table.MethodSpec, rid))
-                               return null;
-
-                       var element_method = (MethodReference) LookupToken (
-                               ReadMetadataToken (CodedIndex.MethodDefOrRef));
-                       var signature = ReadBlobIndex ();
-
-                       var method_spec = ReadMethodSpecSignature (signature, element_method);
-                       method_spec.token = new MetadataToken (TokenType.MethodSpec, rid);
-                       return method_spec;
-               }
-
-               MethodSpecification ReadMethodSpecSignature (uint signature, MethodReference method)
-               {
-                       var reader = ReadSignature (signature);
-                       const byte methodspec_sig = 0x0a;
-
-                       var call_conv = reader.ReadByte ();
-
-                       if (call_conv != methodspec_sig)
-                               throw new NotSupportedException ();
-
-                       var instance = new GenericInstanceMethod (method);
-
-                       reader.ReadGenericInstanceSignature (method, instance);
-
-                       return instance;
-               }
-
-               MemberReference GetMemberReference (uint rid)
-               {
-                       InitializeMemberReferences ();
-
-                       var member = metadata.GetMemberReference (rid);
-                       if (member != null)
-                               return member;
-
-                       member = ReadMemberReference (rid);
-                       if (member != null && !member.ContainsGenericParameter)
-                               metadata.AddMemberReference (member);
-                       return member;
-               }
-
-               MemberReference ReadMemberReference (uint rid)
-               {
-                       if (!MoveTo (Table.MemberRef, rid))
-                               return null;
-
-                       var token = ReadMetadataToken (CodedIndex.MemberRefParent);
-                       var name = ReadString ();
-                       var signature = ReadBlobIndex ();
-
-                       MemberReference member;
-
-                       switch (token.TokenType) {
-                       case TokenType.TypeDef:
-                       case TokenType.TypeRef:
-                       case TokenType.TypeSpec:
-                               member = ReadTypeMemberReference (token, name, signature);
-                               break;
-                       case TokenType.Method:
-                               member = ReadMethodMemberReference (token, name, signature);
-                               break;
-                       default:
-                               throw new NotSupportedException ();
-                       }
-
-                       member.token = new MetadataToken (TokenType.MemberRef, rid);
-
-                       return member;
-               }
-
-               MemberReference ReadTypeMemberReference (MetadataToken type, string name, uint signature)
-               {
-                       var declaring_type = GetTypeDefOrRef (type);
-
-                       if (!declaring_type.IsArray)
-                               this.context = declaring_type;
-
-                       var member = ReadMemberReferenceSignature (signature, declaring_type);
-                       member.Name = name;
-
-                       return member;
-               }
-
-               MemberReference ReadMemberReferenceSignature (uint signature, TypeReference declaring_type)
-               {
-                       var reader = ReadSignature (signature);
-                       const byte field_sig = 0x6;
-
-                       if (reader.buffer [reader.position] == field_sig) {
-                               reader.position++;
-                               var field = new FieldReference ();
-                               field.DeclaringType = declaring_type;
-                               field.FieldType = reader.ReadTypeSignature ();
-                               return field;
-                       } else {
-                               var method = new MethodReference ();
-                               method.DeclaringType = declaring_type;
-                               reader.ReadMethodSignature (method);
-                               return method;
-                       }
-               }
-
-               MemberReference ReadMethodMemberReference (MetadataToken token, string name, uint signature)
-               {
-                       var method = GetMethodDefinition (token.RID);
-
-                       this.context = method;
-
-                       var member = ReadMemberReferenceSignature (signature, method.DeclaringType);
-                       member.Name = name;
-
-                       return member;
-               }
-
-               void InitializeMemberReferences ()
-               {
-                       if (metadata.MemberReferences != null)
-                               return;
-
-                       metadata.MemberReferences = new MemberReference [image.GetTableLength (Table.MemberRef)];
-               }
-
-               public IEnumerable<MemberReference> GetMemberReferences ()
-               {
-                       InitializeMemberReferences ();
-
-                       var length = image.GetTableLength (Table.MemberRef);
-
-                       var type_system = module.TypeSystem;
-
-                       var context = new MethodReference (string.Empty, type_system.Void);
-                       context.DeclaringType = new TypeReference (string.Empty, string.Empty, module, type_system.Corlib);
-
-                       var member_references = new MemberReference [length];
-
-                       for (uint i = 1; i <= length; i++) {
-                               this.context = context;
-                               member_references [i - 1] = GetMemberReference (i);
-                       }
-
-                       return member_references;
-               }
-
-               void InitializeConstants ()
-               {
-                       if (metadata.Constants != null)
-                               return;
-
-                       var length = MoveTo (Table.Constant);
-
-                       var constants = metadata.Constants = new Dictionary<MetadataToken, Row<ElementType, uint>> (length);
-
-                       for (uint i = 1; i <= length; i++) {
-                               var type = (ElementType) ReadUInt16 ();
-                               var owner = ReadMetadataToken (CodedIndex.HasConstant);
-                               var signature = ReadBlobIndex ();
-
-                               constants.Add (owner, new Row<ElementType, uint> (type, signature));
-                       }
-               }
-
-               public object ReadConstant (IConstantProvider owner)
-               {
-                       InitializeConstants ();
-
-                       Row<ElementType, uint> row;
-                       if (!metadata.Constants.TryGetValue (owner.MetadataToken, out row))
-                               return Mixin.NoValue;
-
-                       metadata.Constants.Remove (owner.MetadataToken);
-
-                       switch (row.Col1) {
-                       case ElementType.Class:
-                       case ElementType.Object:
-                               return null;
-                       case ElementType.String:
-                               return ReadConstantString (ReadBlob (row.Col2));
-                       default:
-                               return ReadConstantPrimitive (row.Col1, row.Col2);
-                       }
-               }
-
-               static string ReadConstantString (byte [] blob)
-               {
-                       var length = blob.Length;
-                       if ((length & 1) == 1)
-                               length--;
-
-                       return Encoding.Unicode.GetString (blob, 0, length);
-               }
-
-               object ReadConstantPrimitive (ElementType type, uint signature)
-               {
-                       var reader = ReadSignature (signature);
-                       return reader.ReadConstantSignature (type);
-               }
-
-               void InitializeCustomAttributes ()
-               {
-                       if (metadata.CustomAttributes != null)
-                               return;
-
-                       metadata.CustomAttributes = InitializeRanges (
-                               Table.CustomAttribute, () => {
-                                       var next = ReadMetadataToken (CodedIndex.HasCustomAttribute);
-                                       ReadMetadataToken (CodedIndex.CustomAttributeType);
-                                       ReadBlobIndex ();
-                                       return next;
-                       });
-               }
-
-               public bool HasCustomAttributes (ICustomAttributeProvider owner)
-               {
-                       InitializeCustomAttributes ();
-
-                       Range range;
-                       if (!metadata.TryGetCustomAttributeRange (owner, out range))
-                               return false;
-
-                       return range.Length > 0;
-               }
-
-               public Collection<CustomAttribute> ReadCustomAttributes (ICustomAttributeProvider owner)
-               {
-                       InitializeCustomAttributes ();
-
-                       Range range;
-                       if (!metadata.TryGetCustomAttributeRange (owner, out range)
-                               || !MoveTo (Table.CustomAttribute, range.Start))
-                               return new Collection<CustomAttribute> ();
-
-                       var custom_attributes = new Collection<CustomAttribute> ((int) range.Length);
-
-                       for (int i = 0; i < range.Length; i++) {
-                               ReadMetadataToken (CodedIndex.HasCustomAttribute);
-
-                               var constructor = (MethodReference) LookupToken (
-                                       ReadMetadataToken (CodedIndex.CustomAttributeType));
-
-                               var signature = ReadBlobIndex ();
-
-                               custom_attributes.Add (new CustomAttribute (signature, constructor));
-                       }
-
-                       metadata.RemoveCustomAttributeRange (owner);
-
-                       return custom_attributes;
-               }
-
-               public byte [] ReadCustomAttributeBlob (uint signature)
-               {
-                       return ReadBlob (signature);
-               }
-
-               public void ReadCustomAttributeSignature (CustomAttribute attribute)
-               {
-                       var reader = ReadSignature (attribute.signature);
-                       if (reader.ReadUInt16 () != 0x0001)
-                           throw new InvalidOperationException ();
-
-                       var constructor = attribute.Constructor;
-                       if (constructor.HasParameters)
-                               reader.ReadCustomAttributeConstructorArguments (attribute, constructor.Parameters);
-
-                       if (!reader.CanReadMore ())
-                               return;
-
-                       var named = reader.ReadUInt16 ();
-
-                       if (named == 0)
-                               return;
-
-                       reader.ReadCustomAttributeNamedArguments (named, ref attribute.fields, ref attribute.properties);
-               }
-
-               void InitializeMarshalInfos ()
-               {
-                       if (metadata.FieldMarshals != null)
-                               return;
-
-                       var length = MoveTo (Table.FieldMarshal);
-
-                       var marshals = metadata.FieldMarshals = new Dictionary<MetadataToken, uint> (length);
-
-                       for (int i = 0; i < length; i++) {
-                               var token = ReadMetadataToken (CodedIndex.HasFieldMarshal);
-                               var signature = ReadBlobIndex ();
-                               if (token.RID == 0)
-                                       continue;
-
-                               marshals.Add (token, signature);
-                       }
-               }
-
-               public bool HasMarshalInfo (IMarshalInfoProvider owner)
-               {
-                       InitializeMarshalInfos ();
-
-                       return metadata.FieldMarshals.ContainsKey (owner.MetadataToken);
-               }
-
-               public MarshalInfo ReadMarshalInfo (IMarshalInfoProvider owner)
-               {
-                       InitializeMarshalInfos ();
-
-                       uint signature;
-                       if (!metadata.FieldMarshals.TryGetValue (owner.MetadataToken, out signature))
-                               return null;
-
-                       var reader = ReadSignature (signature);
-
-                       metadata.FieldMarshals.Remove (owner.MetadataToken);
-
-                       return reader.ReadMarshalInfo ();
-               }
-
-               void InitializeSecurityDeclarations ()
-               {
-                       if (metadata.SecurityDeclarations != null)
-                               return;
-
-                       metadata.SecurityDeclarations = InitializeRanges (
-                               Table.DeclSecurity, () => {
-                                       ReadUInt16 ();
-                                       var next = ReadMetadataToken (CodedIndex.HasDeclSecurity);
-                                       ReadBlobIndex ();
-                                       return next;
-                       });
-               }
-
-               public bool HasSecurityDeclarations (ISecurityDeclarationProvider owner)
-               {
-                       InitializeSecurityDeclarations ();
-
-                       Range range;
-                       if (!metadata.TryGetSecurityDeclarationRange (owner, out range))
-                               return false;
-
-                       return range.Length > 0;
-               }
-
-               public Collection<SecurityDeclaration> ReadSecurityDeclarations (ISecurityDeclarationProvider owner)
-               {
-                       InitializeSecurityDeclarations ();
-
-                       Range range;
-                       if (!metadata.TryGetSecurityDeclarationRange (owner, out range)
-                               || !MoveTo (Table.DeclSecurity, range.Start))
-                               return new Collection<SecurityDeclaration> ();
-
-                       var security_declarations = new Collection<SecurityDeclaration> ((int) range.Length);
-
-                       for (int i = 0; i < range.Length; i++) {
-                               var action = (SecurityAction) ReadUInt16 ();
-                               ReadMetadataToken (CodedIndex.HasDeclSecurity);
-                               var signature = ReadBlobIndex ();
-
-                               security_declarations.Add (new SecurityDeclaration (action, signature, module));
-                       }
-
-                       metadata.RemoveSecurityDeclarationRange (owner);
-
-                       return security_declarations;
-               }
-
-               public byte [] ReadSecurityDeclarationBlob (uint signature)
-               {
-                       return ReadBlob (signature);
-               }
-
-               public void ReadSecurityDeclarationSignature (SecurityDeclaration declaration)
-               {
-                       var signature = declaration.signature;
-                       var reader = ReadSignature (signature);
-
-                       if (reader.buffer [reader.position] != '.') {
-                               ReadXmlSecurityDeclaration (signature, declaration);
-                               return;
-                       }
-
-                       reader.position++;
-                       var count = reader.ReadCompressedUInt32 ();
-                       var attributes = new Collection<SecurityAttribute> ((int) count);
-
-                       for (int i = 0; i < count; i++)
-                               attributes.Add (reader.ReadSecurityAttribute ());
-
-                       declaration.security_attributes = attributes;
-               }
-
-               void ReadXmlSecurityDeclaration (uint signature, SecurityDeclaration declaration)
-               {
-                       var blob = ReadBlob (signature);
-                       var attributes = new Collection<SecurityAttribute> (1);
-
-                       var attribute = new SecurityAttribute (
-                               module.TypeSystem.LookupType ("System.Security.Permissions", "PermissionSetAttribute"));
-
-                       attribute.properties = new Collection<CustomAttributeNamedArgument> (1);
-                       attribute.properties.Add (
-                               new CustomAttributeNamedArgument (
-                                       "XML",
-                                       new CustomAttributeArgument (
-                                               module.TypeSystem.String,
-                                               Encoding.Unicode.GetString (blob, 0, blob.Length))));
-
-                       attributes.Add (attribute);
-
-                       declaration.security_attributes = attributes;
-               }
-
-               public Collection<ExportedType> ReadExportedTypes ()
-               {
-                       var length = MoveTo (Table.ExportedType);
-                       if (length == 0)
-                               return new Collection<ExportedType> ();
-
-                       var exported_types = new Collection<ExportedType> (length);
-
-                       for (int i = 1; i <= length; i++) {
-                               var attributes = (TypeAttributes) ReadUInt32 ();
-                               var identifier = ReadUInt32 ();
-                               var name = ReadString ();
-                               var @namespace = ReadString ();
-                               var implementation = ReadMetadataToken (CodedIndex.Implementation);
-
-                               ExportedType declaring_type = null;
-                               IMetadataScope scope = null;
-
-                               switch (implementation.TokenType) {
-                               case TokenType.AssemblyRef:
-                               case TokenType.File:
-                                       scope = GetExportedTypeScope (implementation);
-                                       break;
-                               case TokenType.ExportedType:
-                                       // FIXME: if the table is not properly sorted
-                                       declaring_type = exported_types [(int) implementation.RID - 1];
-                                       break;
-                               }
-
-                               var exported_type = new ExportedType (@namespace, name, module, scope) {
-                                       Attributes = attributes,
-                                       Identifier = (int) identifier,
-                                       DeclaringType = declaring_type,
-                               };
-                               exported_type.token = new MetadataToken (TokenType.ExportedType, i);
-
-                               exported_types.Add (exported_type);
-                       }
-
-                       return exported_types;
-               }
-
-               IMetadataScope GetExportedTypeScope (MetadataToken token)
-               {
-                       var position = this.position;
-                       IMetadataScope scope;
-
-                       switch (token.TokenType) {
-                       case TokenType.AssemblyRef:
-                               InitializeAssemblyReferences ();
-                               scope = metadata.AssemblyReferences [(int) token.RID - 1];
-                               break;
-                       case TokenType.File:
-                               InitializeModuleReferences ();
-                               scope = GetModuleReferenceFromFile (token);
-                               break;
-                       default:
-                               throw new NotSupportedException ();
-                       }
-
-                       this.position = position;
-                       return scope;
-               }
-
-               ModuleReference GetModuleReferenceFromFile (MetadataToken token)
-               {
-                       if (!MoveTo (Table.File, token.RID))
-                               return null;
-
-                       ReadUInt32 ();
-                       var file_name = ReadString ();
-                       var modules = module.ModuleReferences;
-
-                       ModuleReference reference;
-                       for (int i = 0; i < modules.Count; i++) {
-                               reference = modules [i];
-                               if (reference.Name == file_name)
-                                       return reference;
-                       }
-
-                       reference = new ModuleReference (file_name);
-                       modules.Add (reference);
-                       return reference;
-               }
-
-               static void InitializeCollection (object o)
-               {
-               }
-       }
-
-       sealed class SignatureReader : ByteBuffer {
-
-               readonly MetadataReader reader;
-               readonly uint start, sig_length;
-
-               TypeSystem TypeSystem {
-                       get { return reader.module.TypeSystem; }
-               }
-
-               public SignatureReader (uint blob, MetadataReader reader)
-                       : base (reader.buffer)
-               {
-                       this.reader = reader;
-
-                       MoveToBlob (blob);
-
-                       this.sig_length = ReadCompressedUInt32 ();
-                       this.start = (uint) position;
-               }
-
-               void MoveToBlob (uint blob)
-               {
-                       position = (int) (reader.image.BlobHeap.Offset + blob);
-               }
-
-               MetadataToken ReadTypeTokenSignature ()
-               {
-                       return CodedIndex.TypeDefOrRef.GetMetadataToken (ReadCompressedUInt32 ());
-               }
-
-               GenericParameter GetGenericParameter (GenericParameterType type, uint var)
-               {
-                       var context = reader.context;
-                       int index = (int) var;
-
-                       if (context == null)
-                               return GetUnboundGenericParameter (type, index);
-
-                       IGenericParameterProvider provider;
-
-                       switch (type) {
-                       case GenericParameterType.Type:
-                               provider = context.Type;
-                               break;
-                       case GenericParameterType.Method:
-                               provider = context.Method;
-                               break;
-                       default:
-                               throw new NotSupportedException ();
-                       }
-
-                       if (!context.IsDefinition)
-                               CheckGenericContext (provider, index);
-
-                       if (index >= provider.GenericParameters.Count)
-                               return GetUnboundGenericParameter (type, index);
-
-                       return provider.GenericParameters [index];
-               }
-
-               GenericParameter GetUnboundGenericParameter (GenericParameterType type, int index)
-               {
-                       return new GenericParameter (index, type, reader.module);
-               }
-
-               static void CheckGenericContext (IGenericParameterProvider owner, int index)
-               {
-                       var owner_parameters = owner.GenericParameters;
-
-                       for (int i = owner_parameters.Count; i <= index; i++)
-                               owner_parameters.Add (new GenericParameter (owner));
-               }
-
-               public void ReadGenericInstanceSignature (IGenericParameterProvider provider, IGenericInstance instance)
-               {
-                       var arity = ReadCompressedUInt32 ();
-
-                       if (!provider.IsDefinition)
-                               CheckGenericContext (provider, (int) arity - 1);
-
-                       var instance_arguments = instance.GenericArguments;
-
-                       for (int i = 0; i < arity; i++)
-                               instance_arguments.Add (ReadTypeSignature ());
-               }
-
-               ArrayType ReadArrayTypeSignature ()
-               {
-                       var array = new ArrayType (ReadTypeSignature ());
-
-                       var rank = ReadCompressedUInt32 ();
-
-                       var sizes = new uint [ReadCompressedUInt32 ()];
-                       for (int i = 0; i < sizes.Length; i++)
-                               sizes [i] = ReadCompressedUInt32 ();
-
-                       var low_bounds = new int [ReadCompressedUInt32 ()];
-                       for (int i = 0; i < low_bounds.Length; i++)
-                               low_bounds [i] = ReadCompressedInt32 ();
-
-                       array.Dimensions.Clear ();
-
-                       for (int i = 0; i < rank; i++) {
-                               int? lower = null, upper = null;
-
-                               if (i < low_bounds.Length)
-                                       lower = low_bounds [i];
-
-                               if (i < sizes.Length)
-                                       upper = lower + (int) sizes [i] - 1;
-
-                               array.Dimensions.Add (new ArrayDimension (lower, upper));
-                       }
-
-                       return array;
-               }
-
-               TypeReference GetTypeDefOrRef (MetadataToken token)
-               {
-                       return reader.GetTypeDefOrRef (token);
-               }
-
-               public TypeReference ReadTypeSignature ()
-               {
-                       return ReadTypeSignature ((ElementType) ReadByte ());
-               }
-
-               TypeReference ReadTypeSignature (ElementType etype)
-               {
-                       switch (etype) {
-                       case ElementType.ValueType: {
-                               var value_type = GetTypeDefOrRef (ReadTypeTokenSignature ());
-                               value_type.IsValueType = true;
-                               return value_type;
-                       }
-                       case ElementType.Class:
-                               return GetTypeDefOrRef (ReadTypeTokenSignature ());
-                       case ElementType.Ptr:
-                               return new PointerType (ReadTypeSignature ());
-                       case ElementType.FnPtr: {
-                               var fptr = new FunctionPointerType ();
-                               ReadMethodSignature (fptr);
-                               return fptr;
-                       }
-                       case ElementType.ByRef:
-                               return new ByReferenceType (ReadTypeSignature ());
-                       case ElementType.Pinned:
-                               return new PinnedType (ReadTypeSignature ());
-                       case ElementType.SzArray:
-                               return new ArrayType (ReadTypeSignature ());
-                       case ElementType.Array:
-                               return ReadArrayTypeSignature ();
-                       case ElementType.CModOpt:
-                               return new OptionalModifierType (
-                                       GetTypeDefOrRef (ReadTypeTokenSignature ()), ReadTypeSignature ());
-                       case ElementType.CModReqD:
-                               return new RequiredModifierType (
-                                       GetTypeDefOrRef (ReadTypeTokenSignature ()), ReadTypeSignature ());
-                       case ElementType.Sentinel:
-                               return new SentinelType (ReadTypeSignature ());
-                       case ElementType.Var:
-                               return GetGenericParameter (GenericParameterType.Type, ReadCompressedUInt32 ());
-                       case ElementType.MVar:
-                               return GetGenericParameter (GenericParameterType.Method, ReadCompressedUInt32 ());
-                       case ElementType.GenericInst: {
-                               var is_value_type = ReadByte () == (byte) ElementType.ValueType;
-                               var element_type = GetTypeDefOrRef (ReadTypeTokenSignature ());
-                               var generic_instance = new GenericInstanceType (element_type);
-
-                               ReadGenericInstanceSignature (element_type, generic_instance);
-
-                               if (is_value_type) {
-                                       generic_instance.IsValueType = true;
-                                       element_type.GetElementType ().IsValueType = true;
-                               }
-
-                               return generic_instance;
-                       }
-                       case ElementType.Object: return TypeSystem.Object;
-                       case ElementType.Void: return TypeSystem.Void;
-                       case ElementType.TypedByRef: return TypeSystem.TypedReference;
-                       case ElementType.I: return TypeSystem.IntPtr;
-                       case ElementType.U: return TypeSystem.UIntPtr;
-                       default: return GetPrimitiveType (etype);
-                       }
-               }
-
-               public void ReadMethodSignature (IMethodSignature method)
-               {
-                       var calling_convention = ReadByte ();
-
-                       const byte has_this = 0x20;
-                       const byte explicit_this = 0x40;
-
-                       if ((calling_convention & has_this) != 0) {
-                               method.HasThis = true;
-                               calling_convention = (byte) (calling_convention & ~has_this);
-                       }
-
-                       if ((calling_convention & explicit_this) != 0) {
-                               method.ExplicitThis = true;
-                               calling_convention = (byte) (calling_convention & ~explicit_this);
-                       }
-
-                       method.CallingConvention = (MethodCallingConvention) calling_convention;
-
-                       var generic_context = method as MethodReference;
-                       if (generic_context != null && !generic_context.DeclaringType.IsArray)
-                               reader.context = generic_context;
-
-                       if ((calling_convention & 0x10) != 0) {
-                               var arity = ReadCompressedUInt32 ();
-
-                               if (generic_context != null && !generic_context.IsDefinition)
-                                       CheckGenericContext (generic_context, (int) arity -1 );
-                       }
-
-                       var param_count = ReadCompressedUInt32 ();
-
-                       method.MethodReturnType.ReturnType = ReadTypeSignature ();
-
-                       if (param_count == 0)
-                               return;
-
-                       Collection<ParameterDefinition> parameters;
-
-                       var method_ref = method as MethodReference;
-                       if (method_ref != null)
-                               parameters = method_ref.parameters = new ParameterDefinitionCollection (method, (int) param_count);
-                       else
-                               parameters = method.Parameters;
-
-                       for (int i = 0; i < param_count; i++)
-                               parameters.Add (new ParameterDefinition (ReadTypeSignature ()));
-               }
-
-               public object ReadConstantSignature (ElementType type)
-               {
-                       return ReadPrimitiveValue (type);
-               }
-
-               public void ReadCustomAttributeConstructorArguments (CustomAttribute attribute, Collection<ParameterDefinition> parameters)
-               {
-                       var count = parameters.Count;
-                       if (count == 0)
-                               return;
-
-                       attribute.arguments = new Collection<CustomAttributeArgument> (count);
-
-                       for (int i = 0; i < count; i++)
-                               attribute.arguments.Add (
-                                       ReadCustomAttributeFixedArgument (parameters [i].ParameterType));
-               }
-
-               CustomAttributeArgument ReadCustomAttributeFixedArgument (TypeReference type)
-               {
-                       if (type.IsArray)
-                               return ReadCustomAttributeFixedArrayArgument ((ArrayType) type);
-
-                       return ReadCustomAttributeElement (type);
-               }
-
-               public void ReadCustomAttributeNamedArguments (ushort count, ref Collection<CustomAttributeNamedArgument> fields, ref Collection<CustomAttributeNamedArgument> properties)
-               {
-                       for (int i = 0; i < count; i++)
-                               ReadCustomAttributeNamedArgument (ref fields, ref properties);
-               }
-
-               void ReadCustomAttributeNamedArgument (ref Collection<CustomAttributeNamedArgument> fields, ref Collection<CustomAttributeNamedArgument> properties)
-               {
-                       var kind = ReadByte ();
-                       var type = ReadCustomAttributeFieldOrPropType ();
-                       var name = ReadUTF8String ();
-
-                       Collection<CustomAttributeNamedArgument> container;
-                       switch (kind) {
-                       case 0x53:
-                               container = GetCustomAttributeNamedArgumentCollection (ref fields);
-                               break;
-                       case 0x54:
-                               container = GetCustomAttributeNamedArgumentCollection (ref properties);
-                               break;
-                       default:
-                               throw new NotSupportedException ();
-                       }
-
-                       container.Add (new CustomAttributeNamedArgument (name, ReadCustomAttributeFixedArgument (type)));
-               }
-
-               static Collection<CustomAttributeNamedArgument> GetCustomAttributeNamedArgumentCollection (ref Collection<CustomAttributeNamedArgument> collection)
-               {
-                       if (collection != null)
-                               return collection;
-
-                       return collection = new Collection<CustomAttributeNamedArgument> ();
-               }
-
-               CustomAttributeArgument ReadCustomAttributeFixedArrayArgument (ArrayType type)
-               {
-                       var length = ReadUInt32 ();
-
-                       if (length == 0xffffffff)
-                               return new CustomAttributeArgument (type, null);
-
-                       if (length == 0)
-                               return new CustomAttributeArgument (type, Empty<CustomAttributeArgument>.Array);
-
-                       var arguments = new CustomAttributeArgument [length];
-                       var element_type = type.ElementType;
-
-                       for (int i = 0; i < length; i++)
-                               arguments [i] = ReadCustomAttributeElement (element_type);
-
-                       return new CustomAttributeArgument (type, arguments);
-               }
-
-               CustomAttributeArgument ReadCustomAttributeElement (TypeReference type)
-               {
-                       if (type.IsArray)
-                               return ReadCustomAttributeFixedArrayArgument ((ArrayType) type);
-
-                       return new CustomAttributeArgument (
-                               type,
-                               type.etype == ElementType.Object
-                                       ? ReadCustomAttributeElement (ReadCustomAttributeFieldOrPropType ())
-                                       : ReadCustomAttributeElementValue (type));
-               }
-
-               object ReadCustomAttributeElementValue (TypeReference type)
-               {
-                       var etype = type.etype;
-
-                       switch (etype) {
-                       case ElementType.String:
-                               return ReadUTF8String ();
-                       case ElementType.None:
-                               if (type.IsTypeOf ("System", "Type"))
-                                       return ReadTypeReference ();
-
-                               return ReadCustomAttributeEnum (type);
-                       default:
-                               return ReadPrimitiveValue (etype);
-                       }
-               }
-
-               object ReadPrimitiveValue (ElementType type)
-               {
-                       switch (type) {
-                       case ElementType.Boolean:
-                               return ReadByte () == 1;
-                       case ElementType.I1:
-                               return (sbyte) ReadByte ();
-                       case ElementType.U1:
-                               return ReadByte ();
-                       case ElementType.Char:
-                               return (char) ReadUInt16 ();
-                       case ElementType.I2:
-                               return ReadInt16 ();
-                       case ElementType.U2:
-                               return ReadUInt16 ();
-                       case ElementType.I4:
-                               return ReadInt32 ();
-                       case ElementType.U4:
-                               return ReadUInt32 ();
-                       case ElementType.I8:
-                               return ReadInt64 ();
-                       case ElementType.U8:
-                               return ReadUInt64 ();
-                       case ElementType.R4:
-                               return ReadSingle ();
-                       case ElementType.R8:
-                               return ReadDouble ();
-                       default:
-                               throw new NotImplementedException (type.ToString ());
-                       }
-               }
-
-               TypeReference GetPrimitiveType (ElementType etype)
-               {
-                       switch (etype) {
-                       case ElementType.Boolean:
-                               return TypeSystem.Boolean;
-                       case ElementType.Char:
-                               return TypeSystem.Char;
-                       case ElementType.I1:
-                               return TypeSystem.SByte;
-                       case ElementType.U1:
-                               return TypeSystem.Byte;
-                       case ElementType.I2:
-                               return TypeSystem.Int16;
-                       case ElementType.U2:
-                               return TypeSystem.UInt16;
-                       case ElementType.I4:
-                               return TypeSystem.Int32;
-                       case ElementType.U4:
-                               return TypeSystem.UInt32;
-                       case ElementType.I8:
-                               return TypeSystem.Int64;
-                       case ElementType.U8:
-                               return TypeSystem.UInt64;
-                       case ElementType.R4:
-                               return TypeSystem.Single;
-                       case ElementType.R8:
-                               return TypeSystem.Double;
-                       case ElementType.String:
-                               return TypeSystem.String;
-                       default:
-                               throw new NotImplementedException (etype.ToString ());
-                       }
-               }
-
-               TypeReference ReadCustomAttributeFieldOrPropType ()
-               {
-                       var etype = (ElementType) ReadByte ();
-
-                       switch (etype) {
-                       case ElementType.Boxed:
-                               return TypeSystem.Object;
-                       case ElementType.SzArray:
-                               return new ArrayType (ReadCustomAttributeFieldOrPropType ());
-                       case ElementType.Enum:
-                               return ReadTypeReference ();
-                       case ElementType.Type:
-                               return TypeSystem.LookupType ("System", "Type");
-                       default:
-                               return GetPrimitiveType (etype);
-                       }
-               }
-
-               public TypeReference ReadTypeReference ()
-               {
-                       return TypeParser.ParseType (reader.module, ReadUTF8String ());
-               }
-
-               object ReadCustomAttributeEnum (TypeReference enum_type)
-               {
-                       var type = enum_type.CheckedResolve ();
-                       if (!type.IsEnum)
-                               throw new ArgumentException ();
-
-                       return ReadCustomAttributeElementValue (type.GetEnumUnderlyingType ());
-               }
-
-               public SecurityAttribute ReadSecurityAttribute ()
-               {
-                       var attribute = new SecurityAttribute (ReadTypeReference ());
-
-                       ReadCompressedUInt32 ();
-
-                       ReadCustomAttributeNamedArguments (
-                               (ushort) ReadCompressedUInt32 (),
-                               ref attribute.fields,
-                               ref attribute.properties);
-
-                       return attribute;
-               }
-
-               public MarshalInfo ReadMarshalInfo ()
-               {
-                       var native = ReadNativeType ();
-                       switch (native) {
-                       case NativeType.Array: {
-                               var array = new ArrayMarshalInfo ();
-                               if (CanReadMore ())
-                                       array.element_type = ReadNativeType ();
-                               if (CanReadMore ())
-                                       array.size_parameter_index = (int) ReadCompressedUInt32 ();
-                               if (CanReadMore ())
-                                       array.size = (int) ReadCompressedUInt32 ();
-                               if (CanReadMore ())
-                                       array.size_parameter_multiplier = (int) ReadCompressedUInt32 ();
-                               return array;
-                       }
-                       case NativeType.SafeArray: {
-                               var array = new SafeArrayMarshalInfo ();
-                               if (CanReadMore ())
-                                       array.element_type = ReadVariantType ();
-                               return array;
-                       }
-                       case NativeType.FixedArray: {
-                               var array = new FixedArrayMarshalInfo ();
-                               if (CanReadMore ())
-                                       array.size = (int) ReadCompressedUInt32 ();
-                               if (CanReadMore ())
-                                       array.element_type = ReadNativeType ();
-                               return array;
-                       }
-                       case NativeType.FixedSysString: {
-                               var sys_string = new FixedSysStringMarshalInfo ();
-                               if (CanReadMore ())
-                                       sys_string.size = (int) ReadCompressedUInt32 ();
-                               return sys_string;
-                       }
-                       case NativeType.CustomMarshaler: {
-                               var marshaler = new CustomMarshalInfo ();
-                               var guid_value = ReadUTF8String ();
-                               marshaler.guid = !string.IsNullOrEmpty (guid_value) ? new Guid (guid_value) : Guid.Empty;
-                               marshaler.unmanaged_type = ReadUTF8String ();
-                               marshaler.managed_type = ReadTypeReference ();
-                               marshaler.cookie = ReadUTF8String ();
-                               return marshaler;
-                       }
-                       default:
-                               return new MarshalInfo (native);
-                       }
-               }
-
-               NativeType ReadNativeType ()
-               {
-                       return (NativeType) ReadByte ();
-               }
-
-               VariantType ReadVariantType ()
-               {
-                       return (VariantType) ReadByte ();
-               }
-
-               string ReadUTF8String ()
-               {
-                       if (buffer [position] == 0xff) {
-                               position++;
-                               return null;
-                       }
-
-                       var length = (int) ReadCompressedUInt32 ();
-                       if (length == 0)
-                               return string.Empty;
-
-                       var @string = Encoding.UTF8.GetString (buffer, position,
-                               buffer [position + length - 1] == 0 ? length - 1 : length);
-
-                       position += length;
-                       return @string;
-               }
-
-               public bool CanReadMore ()
-               {
-                       return position - start < sig_length;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyWriter.cs b/mcs/class/Mono.Cecil/Mono.Cecil/AssemblyWriter.cs
deleted file mode 100644 (file)
index bf41d5b..0000000
+++ /dev/null
@@ -1,2573 +0,0 @@
-//
-// AssemblyWriter.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-using System.IO;
-using System.Text;
-
-using Mono.Collections.Generic;
-using Mono.Cecil.Cil;
-using Mono.Cecil.Metadata;
-using Mono.Cecil.PE;
-
-using RVA = System.UInt32;
-using RID = System.UInt32;
-using CodedRID = System.UInt32;
-using StringIndex = System.UInt32;
-using BlobIndex = System.UInt32;
-
-namespace Mono.Cecil {
-
-#if !READ_ONLY
-
-       using TypeRefRow     = Row<CodedRID, StringIndex, StringIndex>;
-       using TypeDefRow     = Row<TypeAttributes, StringIndex, StringIndex, CodedRID, RID, RID>;
-       using FieldRow       = Row<FieldAttributes, StringIndex, BlobIndex>;
-       using MethodRow      = Row<RVA, MethodImplAttributes, MethodAttributes, StringIndex, BlobIndex, RID>;
-       using ParamRow       = Row<ParameterAttributes, ushort, StringIndex>;
-       using InterfaceImplRow = Row<uint, CodedRID>;
-       using MemberRefRow   = Row<CodedRID, StringIndex, BlobIndex>;
-       using ConstantRow    = Row<ElementType, CodedRID, BlobIndex>;
-       using CustomAttributeRow = Row<CodedRID, CodedRID, BlobIndex>;
-       using FieldMarshalRow = Row<CodedRID, BlobIndex>;
-       using DeclSecurityRow = Row<SecurityAction, CodedRID, BlobIndex>;
-       using ClassLayoutRow = Row<ushort, uint, RID>;
-       using FieldLayoutRow = Row<uint, RID>;
-       using EventMapRow    = Row<RID, RID>;
-       using EventRow       = Row<EventAttributes, StringIndex, CodedRID>;
-       using PropertyMapRow = Row<RID, RID>;
-       using PropertyRow    = Row<PropertyAttributes, StringIndex, BlobIndex>;
-       using MethodSemanticsRow = Row<MethodSemanticsAttributes, RID, CodedRID>;
-       using MethodImplRow  = Row<RID, CodedRID, CodedRID>;
-       using ImplMapRow     = Row<PInvokeAttributes, CodedRID, StringIndex, RID>;
-       using FieldRVARow    = Row<RVA, RID>;
-       using AssemblyRow    = Row<AssemblyHashAlgorithm, ushort, ushort, ushort, ushort, AssemblyAttributes, uint, uint, uint>;
-       using AssemblyRefRow = Row<ushort, ushort, ushort, ushort, AssemblyAttributes, uint, uint, uint, uint>;
-       using FileRow        = Row<FileAttributes, StringIndex, BlobIndex>;
-       using ExportedTypeRow = Row<TypeAttributes, uint, StringIndex, StringIndex, CodedRID>;
-       using ManifestResourceRow = Row<uint, ManifestResourceAttributes, StringIndex, CodedRID>;
-       using NestedClassRow = Row<RID, RID>;
-       using GenericParamRow = Row<ushort, GenericParameterAttributes, CodedRID, StringIndex>;
-       using MethodSpecRow = Row<CodedRID, BlobIndex>;
-       using GenericParamConstraintRow = Row<RID, CodedRID>;
-
-       static class ModuleWriter {
-
-               public static void WriteModuleTo (ModuleDefinition module, Stream stream, WriterParameters parameters)
-               {
-                       if ((module.Attributes & ModuleAttributes.ILOnly) == 0)
-                               throw new ArgumentException ();
-
-                       if (module.HasImage && module.ReadingMode == ReadingMode.Deferred)
-                               ImmediateModuleReader.ReadModule (module);
-
-                       module.MetadataSystem.Clear ();
-
-                       var name = module.assembly != null ? module.assembly.Name : null;
-                       var fq_name = stream.GetFullyQualifiedName ();
-                       var symbol_writer_provider = parameters.SymbolWriterProvider;
-                       if (symbol_writer_provider == null && parameters.WriteSymbols)
-                               symbol_writer_provider = SymbolProvider.GetPlatformWriterProvider ();
-                       var symbol_writer = GetSymbolWriter (module, fq_name, symbol_writer_provider);
-
-#if !SILVERLIGHT && !CF
-                       if (parameters.StrongNameKeyPair != null && name != null)
-                               name.PublicKey = parameters.StrongNameKeyPair.PublicKey;
-#endif
-
-                       if (name != null && name.HasPublicKey)
-                               module.Attributes |= ModuleAttributes.StrongNameSigned;
-
-                       var metadata = new MetadataBuilder (module, fq_name,
-                               symbol_writer_provider, symbol_writer);
-
-                       BuildMetadata (module, metadata);
-
-                       if (module.SymbolReader != null)
-                               module.SymbolReader.Dispose ();
-
-                       var writer = ImageWriter.CreateWriter (module, metadata, stream);
-
-                       writer.WriteImage ();
-
-#if !SILVERLIGHT && !CF
-                       if (parameters.StrongNameKeyPair != null)
-                               CryptoService.StrongName (stream, writer, parameters.StrongNameKeyPair);
-#endif
-                       if (symbol_writer != null)
-                               symbol_writer.Dispose ();
-               }
-
-               static void BuildMetadata (ModuleDefinition module, MetadataBuilder metadata)
-               {
-                       if (!module.HasImage) {
-                               metadata.BuildMetadata ();
-                               return;
-                       }
-
-                       module.Read (metadata, (builder, _) => {
-                               builder.BuildMetadata ();
-                               return builder;
-                       });
-               }
-
-               static ISymbolWriter GetSymbolWriter (ModuleDefinition module, string fq_name, ISymbolWriterProvider symbol_writer_provider)
-               {
-                       if (symbol_writer_provider == null)
-                               return null;
-
-                       return symbol_writer_provider.GetSymbolWriter (module, fq_name);
-               }
-       }
-
-       abstract class MetadataTable {
-
-               public abstract int Length { get; }
-
-               public bool IsLarge {
-                       get { return Length > 65535; }
-               }
-
-               public abstract void Write (TableHeapBuffer buffer);
-               public abstract void Sort ();
-       }
-
-       abstract class OneRowTable<TRow> : MetadataTable where TRow : struct {
-
-               internal TRow row;
-
-               public sealed override int Length {
-                       get { return 1; }
-               }
-
-               public sealed override void Sort ()
-               {
-               }
-       }
-
-       abstract class MetadataTable<TRow> : MetadataTable where TRow : struct {
-
-               internal TRow [] rows = new TRow [2];
-               internal int length;
-
-               public sealed override int Length {
-                       get { return length; }
-               }
-
-               public int AddRow (TRow row)
-               {
-                       if (rows.Length == length)
-                               Grow ();
-
-                       rows [length++] = row;
-                       return length;
-               }
-
-               void Grow ()
-               {
-                       var rows = new TRow [this.rows.Length * 2];
-                       Array.Copy (this.rows, rows, this.rows.Length);
-                       this.rows = rows;
-               }
-
-               public override void Sort ()
-               {
-               }
-       }
-
-       abstract class SortedTable<TRow> : MetadataTable<TRow>, IComparer<TRow> where TRow : struct {
-
-               public sealed override void Sort ()
-               {
-                       Array.Sort (rows, 0, length, this);
-               }
-
-               protected int Compare (uint x, uint y)
-               {
-                       return x == y ? 0 : x > y ? 1 : -1;
-               }
-
-               public abstract int Compare (TRow x, TRow y);
-       }
-
-       sealed class ModuleTable : OneRowTable<uint> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       buffer.WriteUInt16 (0);         // Generation
-                       buffer.WriteString (row);       // Name
-                       buffer.WriteUInt16 (1);         // Mvid
-                       buffer.WriteUInt16 (0);         // EncId
-                       buffer.WriteUInt16 (0);         // EncBaseId
-               }
-       }
-
-       sealed class TypeRefTable : MetadataTable<TypeRefRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteCodedRID (
-                                       rows [i].Col1, CodedIndex.ResolutionScope);     // Scope
-                               buffer.WriteString (rows [i].Col2);                     // Name
-                               buffer.WriteString (rows [i].Col3);                     // Namespace
-                       }
-               }
-       }
-
-       sealed class TypeDefTable : MetadataTable<TypeDefRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt32 ((uint) rows [i].Col1);      // Attributes
-                               buffer.WriteString (rows [i].Col2);                     // Name
-                               buffer.WriteString (rows [i].Col3);                     // Namespace
-                               buffer.WriteCodedRID (
-                                       rows [i].Col4, CodedIndex.TypeDefOrRef);        // Extends
-                               buffer.WriteRID (rows [i].Col5, Table.Field);   // FieldList
-                               buffer.WriteRID (rows [i].Col6, Table.Method);  // MethodList
-                       }
-               }
-       }
-
-       sealed class FieldTable : MetadataTable<FieldRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 ((ushort) rows [i].Col1);    // Attributes
-                               buffer.WriteString (rows [i].Col2);                     // Name
-                               buffer.WriteBlob (rows [i].Col3);                       // Signature
-                       }
-               }
-       }
-
-       sealed class MethodTable : MetadataTable<MethodRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt32 (rows [i].Col1);             // RVA
-                               buffer.WriteUInt16 ((ushort) rows [i].Col2);    // ImplFlags
-                               buffer.WriteUInt16 ((ushort) rows [i].Col3);    // Flags
-                               buffer.WriteString (rows [i].Col4);             // Name
-                               buffer.WriteBlob (rows [i].Col5);               // Signature
-                               buffer.WriteRID (rows [i].Col6, Table.Param);   // ParamList
-                       }
-               }
-       }
-
-       sealed class ParamTable : MetadataTable<ParamRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 ((ushort) rows [i].Col1);    // Attributes
-                               buffer.WriteUInt16 (rows [i].Col2);             // Sequence
-                               buffer.WriteString (rows [i].Col3);             // Name
-                       }
-               }
-       }
-
-       sealed class InterfaceImplTable : MetadataTable<InterfaceImplRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteRID (rows [i].Col1, Table.TypeDef);         // Class
-                               buffer.WriteCodedRID (rows [i].Col2, CodedIndex.TypeDefOrRef);  // Interface
-                       }
-               }
-
-               /*public override int Compare (InterfaceImplRow x, InterfaceImplRow y)
-               {
-                       return (int) (x.Col1 == y.Col1 ? y.Col2 - x.Col2 : x.Col1 - y.Col1);
-               }*/
-       }
-
-       sealed class MemberRefTable : MetadataTable<MemberRefRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteCodedRID (rows [i].Col1, CodedIndex.MemberRefParent);
-                               buffer.WriteString (rows [i].Col2);
-                               buffer.WriteBlob (rows [i].Col3);
-                       }
-               }
-       }
-
-       sealed class ConstantTable : SortedTable<ConstantRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 ((ushort) rows [i].Col1);
-                               buffer.WriteCodedRID (rows [i].Col2, CodedIndex.HasConstant);
-                               buffer.WriteBlob (rows [i].Col3);
-                       }
-               }
-
-               public override int Compare (ConstantRow x, ConstantRow y)
-               {
-                       return Compare (x.Col2, y.Col2);
-               }
-       }
-
-       sealed class CustomAttributeTable : SortedTable<CustomAttributeRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteCodedRID (rows [i].Col1, CodedIndex.HasCustomAttribute);    // Parent
-                               buffer.WriteCodedRID (rows [i].Col2, CodedIndex.CustomAttributeType);   // Type
-                               buffer.WriteBlob (rows [i].Col3);
-                       }
-               }
-
-               public override int Compare (CustomAttributeRow x, CustomAttributeRow y)
-               {
-                       return Compare (x.Col1, y.Col1);
-               }
-       }
-
-       sealed class FieldMarshalTable : SortedTable<FieldMarshalRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteCodedRID (rows [i].Col1, CodedIndex.HasFieldMarshal);
-                               buffer.WriteBlob (rows [i].Col2);
-                       }
-               }
-
-               public override int Compare (FieldMarshalRow x, FieldMarshalRow y)
-               {
-                       return Compare (x.Col1, y.Col1);
-               }
-       }
-
-       sealed class DeclSecurityTable : SortedTable<DeclSecurityRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 ((ushort) rows [i].Col1);
-                               buffer.WriteCodedRID (rows [i].Col2, CodedIndex.HasDeclSecurity);
-                               buffer.WriteBlob (rows [i].Col3);
-                       }
-               }
-
-               public override int Compare (DeclSecurityRow x, DeclSecurityRow y)
-               {
-                       return Compare (x.Col2, y.Col2);
-               }
-       }
-
-       sealed class ClassLayoutTable : SortedTable<ClassLayoutRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 (rows [i].Col1);             // PackingSize
-                               buffer.WriteUInt32 (rows [i].Col2);             // ClassSize
-                               buffer.WriteRID (rows [i].Col3, Table.TypeDef); // Parent
-                       }
-               }
-
-               public override int Compare (ClassLayoutRow x, ClassLayoutRow y)
-               {
-                       return Compare (x.Col3, y.Col3);
-               }
-       }
-
-       sealed class FieldLayoutTable : SortedTable<FieldLayoutRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt32 (rows [i].Col1);             // Offset
-                               buffer.WriteRID (rows [i].Col2, Table.Field);   // Parent
-                       }
-               }
-
-               public override int Compare (FieldLayoutRow x, FieldLayoutRow y)
-               {
-                       return Compare (x.Col2, y.Col2);
-               }
-       }
-
-       sealed class StandAloneSigTable : MetadataTable<uint> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++)
-                               buffer.WriteBlob (rows [i]);
-               }
-       }
-
-       sealed class EventMapTable : MetadataTable<EventMapRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteRID (rows [i].Col1, Table.TypeDef);         // Parent
-                               buffer.WriteRID (rows [i].Col2, Table.Event);           // EventList
-                       }
-               }
-       }
-
-       sealed class EventTable : MetadataTable<EventRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 ((ushort) rows [i].Col1);    // Flags
-                               buffer.WriteString (rows [i].Col2);             // Name
-                               buffer.WriteCodedRID (rows [i].Col3, CodedIndex.TypeDefOrRef);  // EventType
-                       }
-               }
-       }
-
-       sealed class PropertyMapTable : MetadataTable<PropertyMapRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteRID (rows [i].Col1, Table.TypeDef);         // Parent
-                               buffer.WriteRID (rows [i].Col2, Table.Property);        // PropertyList
-                       }
-               }
-       }
-
-       sealed class PropertyTable : MetadataTable<PropertyRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 ((ushort) rows [i].Col1);    // Flags
-                               buffer.WriteString (rows [i].Col2);             // Name
-                               buffer.WriteBlob (rows [i].Col3);               // Type
-                       }
-               }
-       }
-
-       sealed class MethodSemanticsTable : SortedTable<MethodSemanticsRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 ((ushort) rows [i].Col1);    // Flags
-                               buffer.WriteRID (rows [i].Col2, Table.Method);  // Method
-                               buffer.WriteCodedRID (rows [i].Col3, CodedIndex.HasSemantics);  // Association
-                       }
-               }
-
-               public override int Compare (MethodSemanticsRow x, MethodSemanticsRow y)
-               {
-                       return Compare (x.Col3, y.Col3);
-               }
-       }
-
-       sealed class MethodImplTable : MetadataTable<MethodImplRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteRID (rows [i].Col1, Table.TypeDef); // Class
-                               buffer.WriteCodedRID (rows [i].Col2, CodedIndex.MethodDefOrRef);        // MethodBody
-                               buffer.WriteCodedRID (rows [i].Col3, CodedIndex.MethodDefOrRef);        // MethodDeclaration
-                       }
-               }
-       }
-
-       sealed class ModuleRefTable : MetadataTable<uint> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++)
-                               buffer.WriteString (rows [i]);  // Name
-               }
-       }
-
-       sealed class TypeSpecTable : MetadataTable<uint> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++)
-                               buffer.WriteBlob (rows [i]);    // Signature
-               }
-       }
-
-       sealed class ImplMapTable : SortedTable<ImplMapRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 ((ushort) rows [i].Col1);    // Flags
-                               buffer.WriteCodedRID (rows [i].Col2, CodedIndex.MemberForwarded);       // MemberForwarded
-                               buffer.WriteString (rows [i].Col3);             // ImportName
-                               buffer.WriteRID (rows [i].Col4, Table.ModuleRef);       // ImportScope
-                       }
-               }
-
-               public override int Compare (ImplMapRow x, ImplMapRow y)
-               {
-                       return Compare (x.Col2, y.Col2);
-               }
-       }
-
-       sealed class FieldRVATable : SortedTable<FieldRVARow> {
-
-               internal int position;
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       position = buffer.position;
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt32 (rows [i].Col1);             // RVA
-                               buffer.WriteRID (rows [i].Col2, Table.Field);   // Field
-                       }
-               }
-
-               public override int Compare (FieldRVARow x, FieldRVARow y)
-               {
-                       return Compare (x.Col2, y.Col2);
-               }
-       }
-
-       sealed class AssemblyTable : OneRowTable<AssemblyRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       buffer.WriteUInt32 ((uint) row.Col1);   // AssemblyHashAlgorithm
-                       buffer.WriteUInt16 (row.Col2);                  // MajorVersion
-                       buffer.WriteUInt16 (row.Col3);                  // MinorVersion
-                       buffer.WriteUInt16 (row.Col4);                  // Build
-                       buffer.WriteUInt16 (row.Col5);                  // Revision
-                       buffer.WriteUInt32 ((uint) row.Col6);   // Flags
-                       buffer.WriteBlob (row.Col7);                    // PublicKey
-                       buffer.WriteString (row.Col8);                  // Name
-                       buffer.WriteString (row.Col9);                  // Culture
-               }
-       }
-
-       sealed class AssemblyRefTable : MetadataTable<AssemblyRefRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 (rows [i].Col1);             // MajorVersion
-                               buffer.WriteUInt16 (rows [i].Col2);             // MinorVersion
-                               buffer.WriteUInt16 (rows [i].Col3);             // Build
-                               buffer.WriteUInt16 (rows [i].Col4);             // Revision
-                               buffer.WriteUInt32 ((uint) rows [i].Col5);      // Flags
-                               buffer.WriteBlob (rows [i].Col6);               // PublicKeyOrToken
-                               buffer.WriteString (rows [i].Col7);             // Name
-                               buffer.WriteString (rows [i].Col8);             // Culture
-                               buffer.WriteBlob (rows [i].Col9);               // Hash
-                       }
-               }
-       }
-
-       sealed class FileTable : MetadataTable<FileRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt32 ((uint) rows [i].Col1);
-                               buffer.WriteString (rows [i].Col2);
-                               buffer.WriteBlob (rows [i].Col3);
-                       }
-               }
-       }
-
-       sealed class ExportedTypeTable : MetadataTable<ExportedTypeRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt32 ((uint) rows [i].Col1);
-                               buffer.WriteUInt32 (rows [i].Col2);
-                               buffer.WriteString (rows [i].Col3);
-                               buffer.WriteString (rows [i].Col4);
-                               buffer.WriteCodedRID (rows [i].Col5, CodedIndex.Implementation);
-                       }
-               }
-       }
-
-       sealed class ManifestResourceTable : MetadataTable<ManifestResourceRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt32 (rows [i].Col1);
-                               buffer.WriteUInt32 ((uint) rows [i].Col2);
-                               buffer.WriteString (rows [i].Col3);
-                               buffer.WriteCodedRID (rows [i].Col4, CodedIndex.Implementation);
-                       }
-               }
-       }
-
-       sealed class NestedClassTable : SortedTable<NestedClassRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteRID (rows [i].Col1, Table.TypeDef);         // NestedClass
-                               buffer.WriteRID (rows [i].Col2, Table.TypeDef);         // EnclosingClass
-                       }
-               }
-
-               public override int Compare (NestedClassRow x, NestedClassRow y)
-               {
-                       return Compare (x.Col1, y.Col1);
-               }
-       }
-
-       sealed class GenericParamTable : MetadataTable<GenericParamRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteUInt16 (rows [i].Col1);             // Number
-                               buffer.WriteUInt16 ((ushort) rows [i].Col2);    // Flags
-                               buffer.WriteCodedRID (rows [i].Col3, CodedIndex.TypeOrMethodDef);       // Owner
-                               buffer.WriteString (rows [i].Col4);             // Name
-                       }
-               }
-       }
-
-       sealed class MethodSpecTable : MetadataTable<MethodSpecRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteCodedRID (rows [i].Col1, CodedIndex.MethodDefOrRef);        // Method
-                               buffer.WriteBlob (rows [i].Col2);       // Instantiation
-                       }
-               }
-       }
-
-       sealed class GenericParamConstraintTable : MetadataTable<GenericParamConstraintRow> {
-
-               public override void Write (TableHeapBuffer buffer)
-               {
-                       for (int i = 0; i < length; i++) {
-                               buffer.WriteRID (rows [i].Col1, Table.GenericParam);    // Owner
-                               buffer.WriteCodedRID (rows [i].Col2, CodedIndex.TypeDefOrRef);  // Constraint
-                       }
-               }
-       }
-
-       sealed class MetadataBuilder {
-
-               readonly internal ModuleDefinition module;
-               readonly internal ISymbolWriterProvider symbol_writer_provider;
-               readonly internal ISymbolWriter symbol_writer;
-               readonly internal TextMap text_map;
-               readonly internal string fq_name;
-
-               readonly Dictionary<TypeRefRow, MetadataToken> type_ref_map;
-               readonly Dictionary<uint, MetadataToken> type_spec_map;
-               readonly Dictionary<MemberRefRow, MetadataToken> member_ref_map;
-               readonly Dictionary<MethodSpecRow, MetadataToken> method_spec_map;
-               readonly Collection<GenericParameter> generic_parameters;
-               readonly Dictionary<MetadataToken, MetadataToken> method_def_map;
-
-               readonly internal CodeWriter code;
-               readonly internal DataBuffer data;
-               readonly internal ResourceBuffer resources;
-               readonly internal StringHeapBuffer string_heap;
-               readonly internal UserStringHeapBuffer user_string_heap;
-               readonly internal BlobHeapBuffer blob_heap;
-               readonly internal TableHeapBuffer table_heap;
-
-               internal MetadataToken entry_point;
-
-               RID type_rid = 1;
-               RID field_rid = 1;
-               RID method_rid = 1;
-               RID param_rid = 1;
-               RID property_rid = 1;
-               RID event_rid = 1;
-
-               readonly TypeRefTable type_ref_table;
-               readonly TypeDefTable type_def_table;
-               readonly FieldTable field_table;
-               readonly MethodTable method_table;
-               readonly ParamTable param_table;
-               readonly InterfaceImplTable iface_impl_table;
-               readonly MemberRefTable member_ref_table;
-               readonly ConstantTable constant_table;
-               readonly CustomAttributeTable custom_attribute_table;
-               readonly DeclSecurityTable declsec_table;
-               readonly StandAloneSigTable standalone_sig_table;
-               readonly EventMapTable event_map_table;
-               readonly EventTable event_table;
-               readonly PropertyMapTable property_map_table;
-               readonly PropertyTable property_table;
-               readonly TypeSpecTable typespec_table;
-               readonly MethodSpecTable method_spec_table;
-
-               readonly internal bool write_symbols;
-
-               public MetadataBuilder (ModuleDefinition module, string fq_name, ISymbolWriterProvider symbol_writer_provider, ISymbolWriter symbol_writer)
-               {
-                       this.module = module;
-                       this.text_map = CreateTextMap ();
-                       this.fq_name = fq_name;
-                       this.symbol_writer_provider = symbol_writer_provider;
-                       this.symbol_writer = symbol_writer;
-                       this.write_symbols = symbol_writer != null;
-                       this.code = new CodeWriter (this);
-                       this.data = new DataBuffer ();
-                       this.resources = new ResourceBuffer ();
-                       this.string_heap = new StringHeapBuffer ();
-                       this.user_string_heap = new UserStringHeapBuffer ();
-                       this.blob_heap = new BlobHeapBuffer ();
-                       this.table_heap = new TableHeapBuffer (module, this);
-
-                       this.type_ref_table = GetTable<TypeRefTable> (Table.TypeRef);
-                       this.type_def_table = GetTable<TypeDefTable> (Table.TypeDef);
-                       this.field_table = GetTable<FieldTable> (Table.Field);
-                       this.method_table = GetTable<MethodTable> (Table.Method);
-                       this.param_table = GetTable<ParamTable> (Table.Param);
-                       this.iface_impl_table = GetTable<InterfaceImplTable> (Table.InterfaceImpl);
-                       this.member_ref_table = GetTable<MemberRefTable> (Table.MemberRef);
-                       this.constant_table = GetTable<ConstantTable> (Table.Constant);
-                       this.custom_attribute_table = GetTable<CustomAttributeTable> (Table.CustomAttribute);
-                       this.declsec_table = GetTable<DeclSecurityTable> (Table.DeclSecurity);
-                       this.standalone_sig_table = GetTable<StandAloneSigTable> (Table.StandAloneSig);
-                       this.event_map_table = GetTable<EventMapTable> (Table.EventMap);
-                       this.event_table = GetTable<EventTable> (Table.Event);
-                       this.property_map_table = GetTable<PropertyMapTable> (Table.PropertyMap);
-                       this.property_table = GetTable<PropertyTable> (Table.Property);
-                       this.typespec_table = GetTable<TypeSpecTable> (Table.TypeSpec);
-                       this.method_spec_table = GetTable<MethodSpecTable> (Table.MethodSpec);
-
-                       var row_equality_comparer = new RowEqualityComparer ();
-                       type_ref_map = new Dictionary<TypeRefRow, MetadataToken> (row_equality_comparer);
-                       type_spec_map = new Dictionary<uint, MetadataToken> ();
-                       member_ref_map = new Dictionary<MemberRefRow, MetadataToken> (row_equality_comparer);
-                       method_spec_map = new Dictionary<MethodSpecRow, MetadataToken> (row_equality_comparer);
-                       generic_parameters = new Collection<GenericParameter> ();
-                       if (write_symbols)
-                               method_def_map = new Dictionary<MetadataToken, MetadataToken> ();
-               }
-
-               TextMap CreateTextMap ()
-               {
-                       var map = new TextMap ();
-                       map.AddMap (TextSegment.ImportAddressTable, module.Architecture == TargetArchitecture.I386 ? 8 : 16);
-                       map.AddMap (TextSegment.CLIHeader, 0x48, 8);
-                       return map;
-               }
-
-               TTable GetTable<TTable> (Table table) where TTable : MetadataTable, new ()
-               {
-                       return table_heap.GetTable<TTable> (table);
-               }
-
-               uint GetStringIndex (string @string)
-               {
-                       if (string.IsNullOrEmpty (@string))
-                               return 0;
-
-                       return string_heap.GetStringIndex (@string);
-               }
-
-               uint GetBlobIndex (ByteBuffer blob)
-               {
-                       if (blob.length == 0)
-                               return 0;
-
-                       return blob_heap.GetBlobIndex (blob);
-               }
-
-               uint GetBlobIndex (byte [] blob)
-               {
-                       if (blob.IsNullOrEmpty ())
-                               return 0;
-
-                       return GetBlobIndex (new ByteBuffer (blob));
-               }
-
-               public void BuildMetadata ()
-               {
-                       BuildModule ();
-
-                       table_heap.WriteTableHeap ();
-               }
-
-               void BuildModule ()
-               {
-                       var table = GetTable<ModuleTable> (Table.Module);
-                       table.row = GetStringIndex (module.Name);
-
-                       var assembly = module.Assembly;
-
-                       if (assembly != null)
-                               BuildAssembly ();
-
-                       if (module.HasAssemblyReferences)
-                               AddAssemblyReferences ();
-
-                       if (module.HasModuleReferences)
-                               AddModuleReferences ();
-
-                       if (module.HasResources)
-                               AddResources ();
-
-                       if (module.HasExportedTypes)
-                               AddExportedTypes ();
-
-                       BuildTypes ();
-
-                       if (assembly != null) {
-                               if (assembly.HasCustomAttributes)
-                                       AddCustomAttributes (assembly);
-
-                               if (assembly.HasSecurityDeclarations)
-                                       AddSecurityDeclarations (assembly);
-                       }
-
-                       if (module.HasCustomAttributes)
-                               AddCustomAttributes (module);
-
-                       if (module.EntryPoint != null)
-                               entry_point = LookupToken (module.EntryPoint);
-               }
-
-               void BuildAssembly ()
-               {
-                       var assembly = module.Assembly;
-                       var name = assembly.Name;
-
-                       var table = GetTable<AssemblyTable> (Table.Assembly);
-
-                       table.row = new AssemblyRow (
-                               name.HashAlgorithm,
-                               (ushort) name.Version.Major,
-                               (ushort) name.Version.Minor,
-                               (ushort) name.Version.Build,
-                               (ushort) name.Version.Revision,
-                               name.Attributes,
-                               GetBlobIndex (name.PublicKey),
-                               GetStringIndex (name.Name),
-                               GetStringIndex (name.Culture));
-
-                       if (assembly.Modules.Count > 1)
-                               BuildModules ();
-               }
-
-               void BuildModules ()
-               {
-                       var modules = this.module.Assembly.Modules;
-                       var table = GetTable<FileTable> (Table.File);
-
-                       for (int i = 0; i < modules.Count; i++) {
-                               var module = modules [i];
-                               if (module.IsMain)
-                                       continue;
-
-                               var parameters = new WriterParameters {
-                                       SymbolWriterProvider = symbol_writer_provider,
-                               };
-
-                               var file_name = GetModuleFileName (module.Name);
-                               module.Write (file_name, parameters);
-
-                               var hash = CryptoService.ComputeHash (file_name);
-
-                               table.AddRow (new FileRow (
-                                       FileAttributes.ContainsMetaData,
-                                       GetStringIndex (module.Name),
-                                       GetBlobIndex (hash)));
-                       }
-               }
-
-               string GetModuleFileName (string name)
-               {
-                       if (string.IsNullOrEmpty (name))
-                               throw new NotSupportedException ();
-
-                       var path = Path.GetDirectoryName (fq_name);
-                       return Path.Combine (path, name);
-               }
-
-               void AddAssemblyReferences ()
-               {
-                       var references = module.AssemblyReferences;
-                       var table = GetTable<AssemblyRefTable> (Table.AssemblyRef);
-
-                       for (int i = 0; i < references.Count; i++) {
-                               var reference = references [i];
-
-                               var key_or_token = reference.PublicKey.IsNullOrEmpty ()
-                                       ? reference.PublicKeyToken
-                                       : reference.PublicKey;
-
-                               var version = reference.Version;
-
-                               var rid = table.AddRow (new AssemblyRefRow (
-                                       (ushort) version.Major,
-                                       (ushort) version.Minor,
-                                       (ushort) version.Build,
-                                       (ushort) version.Revision,
-                                       reference.Attributes,
-                                       GetBlobIndex (key_or_token),
-                                       GetStringIndex (reference.Name),
-                                       GetStringIndex (reference.Culture),
-                                       GetBlobIndex (reference.Hash)));
-
-                               reference.token = new MetadataToken (TokenType.AssemblyRef, rid);
-                       }
-               }
-
-               void AddModuleReferences ()
-               {
-                       var references = module.ModuleReferences;
-                       var table = GetTable<ModuleRefTable> (Table.ModuleRef);
-
-                       for (int i = 0; i < references.Count; i++) {
-                               var reference = references [i];
-
-                               reference.token = new MetadataToken (
-                                       TokenType.ModuleRef,
-                                       table.AddRow (GetStringIndex (reference.Name)));
-                       }
-               }
-
-               void AddResources ()
-               {
-                       var resources = module.Resources;
-                       var table = GetTable<ManifestResourceTable> (Table.ManifestResource);
-
-                       for (int i = 0; i < resources.Count; i++) {
-                               var resource = resources [i];
-
-                               var row = new ManifestResourceRow (
-                                       0,
-                                       resource.Attributes,
-                                       GetStringIndex (resource.Name),
-                                       0);
-
-                               switch (resource.ResourceType) {
-                               case ResourceType.Embedded:
-                                       row.Col1 = AddEmbeddedResource ((EmbeddedResource) resource);
-                                       break;
-                               case ResourceType.Linked:
-                                       row.Col4 = CodedIndex.Implementation.CompressMetadataToken (
-                                               new MetadataToken (
-                                                       TokenType.File,
-                                                       AddLinkedResource ((LinkedResource) resource)));
-                                       break;
-                               case ResourceType.AssemblyLinked:
-                                       row.Col4 = CodedIndex.Implementation.CompressMetadataToken (
-                                               ((AssemblyLinkedResource) resource).Assembly.MetadataToken);
-                                       break;
-                               default:
-                                       throw new NotSupportedException ();
-                               }
-
-                               table.AddRow (row);
-                       }
-               }
-
-               uint AddLinkedResource (LinkedResource resource)
-               {
-                       var table = GetTable<FileTable> (Table.File);
-
-                       var hash = resource.Hash.IsNullOrEmpty ()
-                               ? CryptoService.ComputeHash (resource.File)
-                               : resource.Hash;
-
-                       return (uint) table.AddRow (new FileRow (
-                               FileAttributes.ContainsNoMetaData,
-                               GetStringIndex (resource.File),
-                               GetBlobIndex (hash)));
-               }
-
-               uint AddEmbeddedResource (EmbeddedResource resource)
-               {
-                       return resources.AddResource (resource.GetResourceData ());
-               }
-
-               void AddExportedTypes ()
-               {
-                       var exported_types = module.ExportedTypes;
-                       var table = GetTable<ExportedTypeTable> (Table.ExportedType);
-
-                       for (int i = 0; i < exported_types.Count; i++) {
-                               var exported_type = exported_types [i];
-
-                               var rid = table.AddRow (new ExportedTypeRow (
-                                       exported_type.Attributes,
-                                       (uint) exported_type.Identifier,
-                                       GetStringIndex (exported_type.Name),
-                                       GetStringIndex (exported_type.Namespace),
-                                       MakeCodedRID (GetExportedTypeScope (exported_type), CodedIndex.Implementation)));
-
-                               exported_type.token = new MetadataToken (TokenType.ExportedType, rid);
-                       }
-               }
-
-               MetadataToken GetExportedTypeScope (ExportedType exported_type)
-               {
-                       if (exported_type.DeclaringType != null)
-                               return exported_type.DeclaringType.MetadataToken;
-
-                       var scope = exported_type.Scope;
-                       switch (scope.MetadataToken.TokenType) {
-                       case TokenType.AssemblyRef:
-                               return scope.MetadataToken;
-                       case TokenType.ModuleRef:
-                               var file_table = GetTable<FileTable> (Table.File);
-                               for (int i = 0; i < file_table.length; i++)
-                                       if (file_table.rows [i].Col2 == GetStringIndex (scope.Name))
-                                               return new MetadataToken (TokenType.File, i + 1);
-
-                               break;
-                       }
-
-                       throw new NotSupportedException ();
-               }
-
-               void BuildTypes ()
-               {
-                       if (!module.HasTypes)
-                               return;
-
-                       AttachTokens ();
-                       AddTypeDefs ();
-                       AddGenericParameters ();
-               }
-
-               void AttachTokens ()
-               {
-                       var types = module.Types;
-
-                       for (int i = 0; i < types.Count; i++)
-                               AttachTypeDefToken (types [i]);
-               }
-
-               void AttachTypeDefToken (TypeDefinition type)
-               {
-                       type.token = new MetadataToken (TokenType.TypeDef, type_rid++);
-                       type.fields_range.Start = field_rid;
-                       type.methods_range.Start = method_rid;
-
-                       if (type.HasFields)
-                               AttachFieldsDefToken (type);
-
-                       if (type.HasMethods)
-                               AttachMethodsDefToken (type);
-
-                       if (type.HasNestedTypes)
-                               AttachNestedTypesDefToken (type);
-               }
-
-               void AttachNestedTypesDefToken (TypeDefinition type)
-               {
-                       var nested_types = type.NestedTypes;
-                       for (int i = 0; i < nested_types.Count; i++)
-                               AttachTypeDefToken (nested_types [i]);
-               }
-
-               void AttachFieldsDefToken (TypeDefinition type)
-               {
-                       var fields = type.Fields;
-                       type.fields_range.Length = (uint) fields.Count;
-                       for (int i = 0; i < fields.Count; i++)
-                               fields [i].token = new MetadataToken (TokenType.Field, field_rid++);
-               }
-
-               void AttachMethodsDefToken (TypeDefinition type)
-               {
-                       var methods = type.Methods;
-                       type.methods_range.Length = (uint) methods.Count;
-                       for (int i = 0; i < methods.Count; i++) {
-                               var method = methods [i];
-                               var new_token = new MetadataToken (TokenType.Method, method_rid++);
-
-                               if (write_symbols && method.token != MetadataToken.Zero)
-                                       method_def_map.Add (new_token, method.token);
-
-                               method.token = new_token;
-                       }
-               }
-
-               public bool TryGetOriginalMethodToken (MetadataToken new_token, out MetadataToken original)
-               {
-                       return method_def_map.TryGetValue (new_token, out original);
-               }
-
-               MetadataToken GetTypeToken (TypeReference type)
-               {
-                       if (type == null)
-                               return MetadataToken.Zero;
-
-                       if (type.IsDefinition)
-                               return type.token;
-
-                       if (type.IsTypeSpecification ())
-                               return GetTypeSpecToken (type);
-
-                       return GetTypeRefToken (type);
-               }
-
-               MetadataToken GetTypeSpecToken (TypeReference type)
-               {
-                       var row = GetBlobIndex (GetTypeSpecSignature (type));
-
-                       MetadataToken token;
-                       if (type_spec_map.TryGetValue (row, out token))
-                               return token;
-
-                       return AddTypeSpecification (type, row);
-               }
-
-               MetadataToken AddTypeSpecification (TypeReference type, uint row)
-               {
-                       type.token = new MetadataToken (TokenType.TypeSpec, typespec_table.AddRow (row));
-
-                       var token = type.token;
-                       type_spec_map.Add (row, token);
-                       return token;
-               }
-
-               MetadataToken GetTypeRefToken (TypeReference type)
-               {
-                       var row = CreateTypeRefRow (type);
-
-                       MetadataToken token;
-                       if (type_ref_map.TryGetValue (row, out token))
-                               return token;
-
-                       return AddTypeReference (type, row);
-               }
-
-               TypeRefRow CreateTypeRefRow (TypeReference type)
-               {
-                       var scope_token = type.IsNested
-                               ? GetTypeRefToken (type.DeclaringType)
-                               : type.Scope.MetadataToken;
-
-                       return new TypeRefRow (
-                               MakeCodedRID (scope_token, CodedIndex.ResolutionScope),
-                               GetStringIndex (type.Name),
-                               GetStringIndex (type.Namespace));
-               }
-
-               static CodedRID MakeCodedRID (IMetadataTokenProvider provider, CodedIndex index)
-               {
-                       return MakeCodedRID (provider.MetadataToken, index);
-               }
-
-               static CodedRID MakeCodedRID (MetadataToken token, CodedIndex index)
-               {
-                       return index.CompressMetadataToken (token);
-               }
-
-               MetadataToken AddTypeReference (TypeReference type, TypeRefRow row)
-               {
-                       type.token = new MetadataToken (TokenType.TypeRef, type_ref_table.AddRow (row));
-
-                       var token = type.token;
-                       type_ref_map.Add (row, token);
-                       return token;
-               }
-
-               void AddTypeDefs ()
-               {
-                       var types = module.Types;
-
-                       for (int i = 0; i < types.Count; i++)
-                               AddType (types [i]);
-               }
-
-               void AddType (TypeDefinition type)
-               {
-                       type_def_table.AddRow (new TypeDefRow (
-                               type.Attributes,
-                               GetStringIndex (type.Name),
-                               GetStringIndex (type.Namespace),
-                               MakeCodedRID (GetTypeToken (type.BaseType), CodedIndex.TypeDefOrRef),
-                               type.fields_range.Start,
-                               type.methods_range.Start));
-
-                       if (type.HasGenericParameters)
-                               AddGenericParameters (type);
-
-                       if (type.HasInterfaces)
-                               AddInterfaces (type);
-
-                       if (type.HasLayoutInfo)
-                               AddLayoutInfo (type);
-
-                       if (type.HasFields)
-                               AddFields (type);
-
-                       if (type.HasMethods)
-                               AddMethods (type);
-
-                       if (type.HasProperties)
-                               AddProperties (type);
-
-                       if (type.HasEvents)
-                               AddEvents (type);
-
-                       if (type.HasCustomAttributes)
-                               AddCustomAttributes (type);
-
-                       if (type.HasSecurityDeclarations)
-                               AddSecurityDeclarations (type);
-
-                       if (type.HasNestedTypes)
-                               AddNestedTypes (type);
-               }
-
-               void AddGenericParameters (IGenericParameterProvider owner)
-               {
-                       var parameters = owner.GenericParameters;
-
-                       for (int i = 0; i < parameters.Count; i++)
-                               generic_parameters.Add (parameters [i]);
-               }
-
-               sealed class GenericParameterComparer : IComparer<GenericParameter> {
-
-                       public int Compare (GenericParameter a, GenericParameter b)
-                       {
-                               var a_owner = MakeCodedRID (a.Owner, CodedIndex.TypeOrMethodDef);
-                               var b_owner = MakeCodedRID (b.Owner, CodedIndex.TypeOrMethodDef);
-                               if (a_owner == b_owner) {
-                                       var a_pos = a.Position;
-                                       var b_pos = b.Position;
-                                       return a_pos == b_pos ? 0 : a_pos > b_pos ? 1 : -1;
-                               }
-
-                               return a_owner > b_owner ? 1 : -1;
-                       }
-               }
-
-               void AddGenericParameters ()
-               {
-                       var items = this.generic_parameters.items;
-                       var size = this.generic_parameters.size;
-                       Array.Sort (items, 0, size, new GenericParameterComparer ());
-
-                       var generic_param_table = GetTable<GenericParamTable> (Table.GenericParam);
-                       var generic_param_constraint_table = GetTable<GenericParamConstraintTable> (Table.GenericParamConstraint);
-
-                       for (int i = 0; i < size; i++) {
-                               var generic_parameter = items [i];
-
-                               var rid = generic_param_table.AddRow (new GenericParamRow (
-                                       (ushort) generic_parameter.Position,
-                                       generic_parameter.Attributes,
-                                       MakeCodedRID (generic_parameter.Owner, CodedIndex.TypeOrMethodDef),
-                                       GetStringIndex (generic_parameter.Name)));
-
-                               generic_parameter.token = new MetadataToken (TokenType.GenericParam, rid);
-
-                               if (generic_parameter.HasConstraints)
-                                       AddConstraints (generic_parameter, generic_param_constraint_table);
-
-                               if (generic_parameter.HasCustomAttributes)
-                                       AddCustomAttributes (generic_parameter);
-                       }
-               }
-
-               void AddConstraints (GenericParameter generic_parameter, GenericParamConstraintTable table)
-               {
-                       var constraints = generic_parameter.Constraints;
-
-                       var rid = generic_parameter.token.RID;
-
-                       for (int i = 0; i < constraints.Count; i++)
-                               table.AddRow (new GenericParamConstraintRow (
-                                       rid,
-                                       MakeCodedRID (GetTypeToken (constraints [i]), CodedIndex.TypeDefOrRef)));
-               }
-
-               void AddInterfaces (TypeDefinition type)
-               {
-                       var interfaces = type.Interfaces;
-                       var type_rid = type.token.RID;
-
-                       for (int i = 0; i < interfaces.Count; i++)
-                               iface_impl_table.AddRow (new InterfaceImplRow (
-                                       type_rid,
-                                       MakeCodedRID (GetTypeToken (interfaces [i]), CodedIndex.TypeDefOrRef)));
-               }
-
-               void AddLayoutInfo (TypeDefinition type)
-               {
-                       var table = GetTable<ClassLayoutTable> (Table.ClassLayout);
-
-                       table.AddRow (new ClassLayoutRow (
-                               (ushort) type.PackingSize,
-                               (uint) type.ClassSize,
-                               type.token.RID));
-               }
-
-               void AddNestedTypes (TypeDefinition type)
-               {
-                       var nested_types = type.NestedTypes;
-                       var nested_table = GetTable<NestedClassTable> (Table.NestedClass);
-
-                       for (int i = 0; i < nested_types.Count; i++) {
-                               var nested = nested_types [i];
-                               AddType (nested);
-                               nested_table.AddRow (new NestedClassRow (nested.token.RID, type.token.RID));
-                       }
-               }
-
-               void AddFields (TypeDefinition type)
-               {
-                       var fields = type.Fields;
-
-                       for (int i = 0; i < fields.Count; i++)
-                               AddField (fields [i]);
-               }
-
-               void AddField (FieldDefinition field)
-               {
-                       field_table.AddRow (new FieldRow (
-                               field.Attributes,
-                               GetStringIndex (field.Name),
-                               GetBlobIndex (GetFieldSignature (field))));
-
-                       if (!field.InitialValue.IsNullOrEmpty ())
-                               AddFieldRVA (field);
-
-                       if (field.HasLayoutInfo)
-                               AddFieldLayout (field);
-
-                       if (field.HasCustomAttributes)
-                               AddCustomAttributes (field);
-
-                       if (field.HasConstant)
-                               AddConstant (field, field.FieldType);
-
-                       if (field.HasMarshalInfo)
-                               AddMarshalInfo (field);
-               }
-
-               void AddFieldRVA (FieldDefinition field)
-               {
-                       var table = GetTable<FieldRVATable> (Table.FieldRVA);
-                       table.AddRow (new FieldRVARow (
-                               data.AddData (field.InitialValue),
-                               field.token.RID));
-               }
-
-               void AddFieldLayout (FieldDefinition field)
-               {
-                       var table = GetTable<FieldLayoutTable> (Table.FieldLayout);
-                       table.AddRow (new FieldLayoutRow ((uint) field.Offset, field.token.RID));
-               }
-
-               void AddMethods (TypeDefinition type)
-               {
-                       var methods = type.Methods;
-
-                       for (int i = 0; i < methods.Count; i++)
-                               AddMethod (methods [i]);
-               }
-
-               void AddMethod (MethodDefinition method)
-               {
-                       method_table.AddRow (new MethodRow (
-                               method.HasBody ? code.WriteMethodBody (method) : 0,
-                               method.ImplAttributes,
-                               method.Attributes,
-                               GetStringIndex (method.Name),
-                               GetBlobIndex (GetMethodSignature (method)),
-                               param_rid));
-
-                       AddParameters (method);
-
-                       if (method.HasGenericParameters)
-                               AddGenericParameters (method);
-
-                       if (method.IsPInvokeImpl)
-                               AddPInvokeInfo (method);
-
-                       if (method.HasCustomAttributes)
-                               AddCustomAttributes (method);
-
-                       if (method.HasSecurityDeclarations)
-                               AddSecurityDeclarations (method);
-
-                       if (method.HasOverrides)
-                               AddOverrides (method);
-               }
-
-               void AddParameters (MethodDefinition method)
-               {
-                       var return_parameter = method.MethodReturnType.parameter;
-
-                       if (return_parameter != null && RequiresParameterRow (return_parameter))
-                               AddParameter (0, return_parameter, param_table);
-
-                       if (!method.HasParameters)
-                               return;
-
-                       var parameters = method.Parameters;
-
-                       for (int i = 0; i < parameters.Count; i++) {
-                               var parameter = parameters [i];
-                               if (!RequiresParameterRow (parameter))
-                                       continue;
-
-                               AddParameter ((ushort) (i + 1), parameter, param_table);
-                       }
-               }
-
-               void AddPInvokeInfo (MethodDefinition method)
-               {
-                       var pinvoke = method.PInvokeInfo;
-                       if (pinvoke == null)
-                               throw new ArgumentException ();
-
-                       var table = GetTable<ImplMapTable> (Table.ImplMap);
-                       table.AddRow (new ImplMapRow (
-                               pinvoke.Attributes,
-                               MakeCodedRID (method, CodedIndex.MemberForwarded),
-                               GetStringIndex (pinvoke.EntryPoint),
-                               pinvoke.Module.MetadataToken.RID));
-               }
-
-               void AddOverrides (MethodDefinition method)
-               {
-                       var overrides = method.Overrides;
-                       var table = GetTable<MethodImplTable> (Table.MethodImpl);
-
-                       for (int i = 0; i < overrides.Count; i++) {
-                               table.AddRow (new MethodImplRow (
-                                       method.DeclaringType.token.RID,
-                                       MakeCodedRID (method, CodedIndex.MethodDefOrRef),
-                                       MakeCodedRID (LookupToken (overrides [i]), CodedIndex.MethodDefOrRef)));
-                       }
-               }
-
-               static bool RequiresParameterRow (ParameterDefinition parameter)
-               {
-                       return !string.IsNullOrEmpty (parameter.Name)
-                               || parameter.Attributes != ParameterAttributes.None
-                               || parameter.HasMarshalInfo
-                               || parameter.HasConstant
-                               || parameter.HasCustomAttributes;
-               }
-
-               void AddParameter (ushort sequence, ParameterDefinition parameter, ParamTable table)
-               {
-                       table.AddRow (new ParamRow (
-                               parameter.Attributes,
-                               sequence,
-                               GetStringIndex (parameter.Name)));
-
-                       parameter.token = new MetadataToken (TokenType.Param, param_rid++);
-
-                       if (parameter.HasCustomAttributes)
-                               AddCustomAttributes (parameter);
-
-                       if (parameter.HasConstant)
-                               AddConstant (parameter, parameter.ParameterType);
-
-                       if (parameter.HasMarshalInfo)
-                               AddMarshalInfo (parameter);
-               }
-
-               void AddMarshalInfo (IMarshalInfoProvider owner)
-               {
-                       var table = GetTable<FieldMarshalTable> (Table.FieldMarshal);
-
-                       table.AddRow (new FieldMarshalRow (
-                               MakeCodedRID (owner, CodedIndex.HasFieldMarshal),
-                               GetBlobIndex (GetMarshalInfoSignature (owner))));
-               }
-
-               void AddProperties (TypeDefinition type)
-               {
-                       var properties = type.Properties;
-
-                       property_map_table.AddRow (new PropertyMapRow (type.token.RID, property_rid));
-
-                       for (int i = 0; i < properties.Count; i++)
-                               AddProperty (properties [i]);
-               }
-
-               void AddProperty (PropertyDefinition property)
-               {
-                       property_table.AddRow (new PropertyRow (
-                               property.Attributes,
-                               GetStringIndex (property.Name),
-                               GetBlobIndex (GetPropertySignature (property))));
-                       property.token = new MetadataToken (TokenType.Property, property_rid++);
-
-                       var method = property.GetMethod;
-                       if (method != null)
-                               AddSemantic (MethodSemanticsAttributes.Getter, property, method);
-
-                       method = property.SetMethod;
-                       if (method != null)
-                               AddSemantic (MethodSemanticsAttributes.Setter, property, method);
-
-                       if (property.HasOtherMethods)
-                               AddOtherSemantic (property, property.OtherMethods);
-
-                       if (property.HasCustomAttributes)
-                               AddCustomAttributes (property);
-
-                       if (property.HasConstant)
-                               AddConstant (property, property.PropertyType);
-               }
-
-               void AddOtherSemantic (IMetadataTokenProvider owner, Collection<MethodDefinition> others)
-               {
-                       for (int i = 0; i < others.Count; i++)
-                               AddSemantic (MethodSemanticsAttributes.Other, owner, others [i]);
-               }
-
-               void AddEvents (TypeDefinition type)
-               {
-                       var events = type.Events;
-
-                       event_map_table.AddRow (new EventMapRow (type.token.RID, event_rid));
-
-                       for (int i = 0; i < events.Count; i++)
-                               AddEvent (events [i]);
-               }
-
-               void AddEvent (EventDefinition @event)
-               {
-                       event_table.AddRow (new EventRow (
-                               @event.Attributes,
-                               GetStringIndex (@event.Name),
-                               MakeCodedRID (GetTypeToken (@event.EventType), CodedIndex.TypeDefOrRef)));
-                       @event.token = new MetadataToken (TokenType.Event, event_rid++);
-
-                       var method = @event.AddMethod;
-                       if (method != null)
-                               AddSemantic (MethodSemanticsAttributes.AddOn, @event, method);
-
-                       method = @event.InvokeMethod;
-                       if (method != null)
-                               AddSemantic (MethodSemanticsAttributes.Fire, @event, method);
-
-                       method = @event.RemoveMethod;
-                       if (method != null)
-                               AddSemantic (MethodSemanticsAttributes.RemoveOn, @event, method);
-
-                       if (@event.HasOtherMethods)
-                               AddOtherSemantic (@event, @event.OtherMethods);
-
-                       if (@event.HasCustomAttributes)
-                               AddCustomAttributes (@event);
-               }
-
-               void AddSemantic (MethodSemanticsAttributes semantics, IMetadataTokenProvider provider, MethodDefinition method)
-               {
-                       method.SemanticsAttributes = semantics;
-                       var table = GetTable<MethodSemanticsTable> (Table.MethodSemantics);
-
-                       table.AddRow (new MethodSemanticsRow (
-                               semantics,
-                               method.token.RID,
-                               MakeCodedRID (provider, CodedIndex.HasSemantics)));
-               }
-
-               void AddConstant (IConstantProvider owner, TypeReference type)
-               {
-                       var constant = owner.Constant;
-                       var etype = GetConstantType (type, constant);
-
-                       constant_table.AddRow (new ConstantRow (
-                               etype,
-                               MakeCodedRID (owner.MetadataToken, CodedIndex.HasConstant),
-                               GetBlobIndex (GetConstantSignature (etype, constant))));
-               }
-
-               static ElementType GetConstantType (TypeReference constant_type, object constant)
-               {
-                       if (constant == null)
-                               return ElementType.Class;
-
-                       var etype = constant_type.etype;
-                       switch (etype) {
-                       case ElementType.None:
-                               var type = constant_type.CheckedResolve ();
-                               if (type.IsEnum)
-                                       return GetConstantType (type.GetEnumUnderlyingType (), constant);
-
-                               return ElementType.Class;
-                       case ElementType.String:
-                               return ElementType.String;
-                       case ElementType.Object:
-                               return GetConstantType (constant.GetType ());
-                       case ElementType.Array:
-                       case ElementType.SzArray:
-                       case ElementType.MVar:
-                       case ElementType.Var:
-                               return ElementType.Class;
-                       case ElementType.GenericInst:
-                       case ElementType.CModOpt:
-                       case ElementType.CModReqD:
-                       case ElementType.ByRef:
-                       case ElementType.Sentinel:
-                               return GetConstantType (((TypeSpecification) constant_type).ElementType, constant);
-                       case ElementType.Boolean:
-                       case ElementType.Char:
-                       case ElementType.I:
-                       case ElementType.I1:
-                       case ElementType.I2:
-                       case ElementType.I4:
-                       case ElementType.I8:
-                       case ElementType.U:
-                       case ElementType.U1:
-                       case ElementType.U2:
-                       case ElementType.U4:
-                       case ElementType.U8:
-                       case ElementType.R4:
-                       case ElementType.R8:
-                               return GetConstantType (constant.GetType ());
-                       default:
-                               return etype;
-                       }
-               }
-
-               static ElementType GetConstantType (Type type)
-               {
-                       switch (Type.GetTypeCode (type)) {
-                       case TypeCode.Boolean:
-                               return ElementType.Boolean;
-                       case TypeCode.Byte:
-                               return ElementType.U1;
-                       case TypeCode.SByte:
-                               return ElementType.I1;
-                       case TypeCode.Char:
-                               return ElementType.Char;
-                       case TypeCode.Int16:
-                               return ElementType.I2;
-                       case TypeCode.UInt16:
-                               return ElementType.U2;
-                       case TypeCode.Int32:
-                               return ElementType.I4;
-                       case TypeCode.UInt32:
-                               return ElementType.U4;
-                       case TypeCode.Int64:
-                               return ElementType.I8;
-                       case TypeCode.UInt64:
-                               return ElementType.U8;
-                       case TypeCode.Single:
-                               return ElementType.R4;
-                       case TypeCode.Double:
-                               return ElementType.R8;
-                       case TypeCode.String:
-                               return ElementType.String;
-                       default:
-                               throw new NotSupportedException (type.FullName);
-                       }
-               }
-
-               void AddCustomAttributes (ICustomAttributeProvider owner)
-               {
-                       var custom_attributes = owner.CustomAttributes;
-
-                       for (int i = 0; i < custom_attributes.Count; i++) {
-                               var attribute = custom_attributes [i];
-
-                               custom_attribute_table.AddRow (new CustomAttributeRow (
-                                       MakeCodedRID (owner, CodedIndex.HasCustomAttribute),
-                                       MakeCodedRID (LookupToken (attribute.Constructor), CodedIndex.CustomAttributeType),
-                                       GetBlobIndex (GetCustomAttributeSignature (attribute))));
-                       }
-               }
-
-               void AddSecurityDeclarations (ISecurityDeclarationProvider owner)
-               {
-                       var declarations = owner.SecurityDeclarations;
-
-                       for (int i = 0; i < declarations.Count; i++) {
-                               var declaration = declarations [i];
-
-                               declsec_table.AddRow (new DeclSecurityRow (
-                                       declaration.Action,
-                                       MakeCodedRID (owner, CodedIndex.HasDeclSecurity),
-                                       GetBlobIndex (GetSecurityDeclarationSignature (declaration))));
-                       }
-               }
-
-               MetadataToken GetMemberRefToken (MemberReference member)
-               {
-                       var row = CreateMemberRefRow (member);
-
-                       MetadataToken token;
-                       if (member_ref_map.TryGetValue (row, out token))
-                               return token;
-
-                       AddMemberReference (member, row);
-
-                       return member.token;
-               }
-
-               MemberRefRow CreateMemberRefRow (MemberReference member)
-               {
-                       return new MemberRefRow (
-                               MakeCodedRID (GetTypeToken (member.DeclaringType), CodedIndex.MemberRefParent),
-                               GetStringIndex (member.Name),
-                               GetBlobIndex (GetMemberRefSignature (member)));
-               }
-
-               void AddMemberReference (MemberReference member, MemberRefRow row)
-               {
-                       member.token = new MetadataToken (TokenType.MemberRef, member_ref_table.AddRow (row));
-                       member_ref_map.Add (row, member.token);
-               }
-
-               MetadataToken GetMethodSpecToken (MethodSpecification method_spec)
-               {
-                       var row = CreateMethodSpecRow (method_spec);
-
-                       MetadataToken token;
-                       if (method_spec_map.TryGetValue (row, out token))
-                               return token;
-
-                       AddMethodSpecification (method_spec, row);
-
-                       return method_spec.token;
-               }
-
-               void AddMethodSpecification (MethodSpecification method_spec, MethodSpecRow row)
-               {
-                       method_spec.token = new MetadataToken (TokenType.MethodSpec, method_spec_table.AddRow (row));
-                       method_spec_map.Add (row, method_spec.token);
-               }
-
-               MethodSpecRow CreateMethodSpecRow (MethodSpecification method_spec)
-               {
-                       return new MethodSpecRow (
-                               MakeCodedRID (LookupToken (method_spec.ElementMethod), CodedIndex.MethodDefOrRef),
-                               GetBlobIndex (GetMethodSpecSignature (method_spec)));
-               }
-
-               SignatureWriter CreateSignatureWriter ()
-               {
-                       return new SignatureWriter (this);
-               }
-
-               SignatureWriter GetMethodSpecSignature (MethodSpecification method_spec)
-               {
-                       if (!method_spec.IsGenericInstance)
-                               throw new NotSupportedException ();
-
-                       var generic_instance = (GenericInstanceMethod) method_spec;
-
-                       var signature = CreateSignatureWriter ();
-                       signature.WriteByte (0x0a);
-
-                       signature.WriteGenericInstanceSignature (generic_instance);
-
-                       return signature;
-               }
-
-               public uint AddStandAloneSignature (uint signature)
-               {
-                       return (uint) standalone_sig_table.AddRow (signature);
-               }
-
-               public uint GetLocalVariableBlobIndex (Collection<VariableDefinition> variables)
-               {
-                       return GetBlobIndex (GetVariablesSignature (variables));
-               }
-
-               public uint GetCallSiteBlobIndex (CallSite call_site)
-               {
-                       return GetBlobIndex (GetMethodSignature (call_site));
-               }
-
-               SignatureWriter GetVariablesSignature (Collection<VariableDefinition> variables)
-               {
-                       var signature = CreateSignatureWriter ();
-                       signature.WriteByte (0x7);
-                       signature.WriteCompressedUInt32 ((uint) variables.Count);
-                       for (int i = 0; i < variables.Count; i++)
-                               signature.WriteTypeSignature (variables [i].VariableType);
-                       return signature;
-               }
-
-               SignatureWriter GetFieldSignature (FieldReference field)
-               {
-                       var signature = CreateSignatureWriter ();
-                       signature.WriteByte (0x6);
-                       signature.WriteTypeSignature (field.FieldType);
-                       return signature;
-               }
-
-               SignatureWriter GetMethodSignature (IMethodSignature method)
-               {
-                       var signature = CreateSignatureWriter ();
-                       signature.WriteMethodSignature (method);
-                       return signature;
-               }
-
-               SignatureWriter GetMemberRefSignature (MemberReference member)
-               {
-                       var field = member as FieldReference;
-                       if (field != null)
-                               return GetFieldSignature (field);
-
-                       var method = member as MethodReference;
-                       if (method != null)
-                               return GetMethodSignature (method);
-
-                       throw new NotSupportedException ();
-               }
-
-               SignatureWriter GetPropertySignature (PropertyDefinition property)
-               {
-                       var signature = CreateSignatureWriter ();
-                       byte calling_convention = 0x8;
-                       if (property.HasThis)
-                               calling_convention |= 0x20;
-
-                       uint param_count = 0;
-                       Collection<ParameterDefinition> parameters = null;
-
-                       if (property.HasParameters) {
-                               parameters = property.Parameters;
-                               param_count = (uint) parameters.Count;
-                       }
-
-                       signature.WriteByte (calling_convention);
-                       signature.WriteCompressedUInt32 (param_count);
-                       signature.WriteTypeSignature (property.PropertyType);
-
-                       if (param_count == 0)
-                               return signature;
-
-                       for (int i = 0; i < param_count; i++)
-                               signature.WriteTypeSignature (parameters [i].ParameterType);
-
-                       return signature;
-               }
-
-               SignatureWriter GetTypeSpecSignature (TypeReference type)
-               {
-                       var signature = CreateSignatureWriter ();
-                       signature.WriteTypeSignature (type);
-                       return signature;
-               }
-
-               SignatureWriter GetConstantSignature (ElementType type, object value)
-               {
-                       var signature = CreateSignatureWriter ();
-
-                       switch (type) {
-                       case ElementType.Array:
-                       case ElementType.SzArray:
-                       case ElementType.Class:
-                       case ElementType.Object:
-                       case ElementType.Var:
-                       case ElementType.MVar:
-                               signature.WriteInt32 (0);
-                               break;
-                       case ElementType.String:
-                               signature.WriteConstantString ((string) value);
-                               break;
-                       default:
-                               signature.WriteConstantPrimitive (value);
-                               break;
-                       }
-
-                       return signature;
-               }
-
-               SignatureWriter GetCustomAttributeSignature (CustomAttribute attribute)
-               {
-                       var signature = CreateSignatureWriter ();
-                       if (!attribute.resolved) {
-                               signature.WriteBytes (attribute.GetBlob ());
-                               return signature;
-                       }
-
-                       signature.WriteUInt16 (0x0001);
-
-                       signature.WriteCustomAttributeConstructorArguments (attribute);
-
-                       signature.WriteCustomAttributeNamedArguments (attribute);
-
-                       return signature;
-               }
-
-               SignatureWriter GetSecurityDeclarationSignature (SecurityDeclaration declaration)
-               {
-                       var signature = CreateSignatureWriter ();
-
-                       if (!declaration.resolved)
-                               signature.WriteBytes (declaration.GetBlob ());
-                       else if (module.Runtime < TargetRuntime.Net_2_0)
-                               signature.WriteXmlSecurityDeclaration (declaration);
-                       else
-                               signature.WriteSecurityDeclaration (declaration);
-
-                       return signature;
-               }
-
-               SignatureWriter GetMarshalInfoSignature (IMarshalInfoProvider owner)
-               {
-                       var signature = CreateSignatureWriter ();
-
-                       signature.WriteMarshalInfo (owner.MarshalInfo);
-
-                       return signature;
-               }
-
-               static Exception CreateForeignMemberException (MemberReference member)
-               {
-                       return new ArgumentException (string.Format ("Member '{0}' is declared in another module and needs to be imported", member));
-               }
-
-               public MetadataToken LookupToken (IMetadataTokenProvider provider)
-               {
-                       if (provider == null)
-                               throw new ArgumentNullException ();
-
-                       var member = provider as MemberReference;
-                       if (member == null || member.Module != module)
-                               throw CreateForeignMemberException (member);
-
-                       var token = provider.MetadataToken;
-
-                       switch (token.TokenType) {
-                       case TokenType.TypeDef:
-                       case TokenType.Method:
-                       case TokenType.Field:
-                       case TokenType.Event:
-                       case TokenType.Property:
-                               return token;
-                       case TokenType.TypeRef:
-                       case TokenType.TypeSpec:
-                       case TokenType.GenericParam:
-                               return GetTypeToken ((TypeReference) provider);
-                       case TokenType.MethodSpec:
-                               return GetMethodSpecToken ((MethodSpecification) provider);
-                       case TokenType.MemberRef:
-                               return GetMemberRefToken (member);
-                       default:
-                               throw new NotSupportedException ();
-                       }
-               }
-       }
-
-       sealed class SignatureWriter : ByteBuffer {
-
-               readonly MetadataBuilder metadata;
-
-               public SignatureWriter (MetadataBuilder metadata)
-                       : base (6)
-               {
-                       this.metadata = metadata;
-               }
-
-               public void WriteElementType (ElementType element_type)
-               {
-                       WriteByte ((byte) element_type);
-               }
-
-               public void WriteUTF8String (string @string)
-               {
-                       if (@string == null) {
-                               WriteByte (0xff);
-                               return;
-                       }
-
-                       var bytes = Encoding.UTF8.GetBytes (@string);
-                       WriteCompressedUInt32 ((uint) bytes.Length);
-                       WriteBytes (bytes);
-               }
-
-               public void WriteMethodSignature (IMethodSignature method)
-               {
-                       byte calling_convention = (byte) method.CallingConvention;
-                       if (method.HasThis)
-                               calling_convention |= 0x20;
-                       if (method.ExplicitThis)
-                               calling_convention |= 0x40;
-
-                       var generic_provider = method as IGenericParameterProvider;
-                       var generic_arity = generic_provider != null && generic_provider.HasGenericParameters
-                               ? generic_provider.GenericParameters.Count
-                               : 0;
-
-                       if (generic_arity > 0)
-                               calling_convention |= 0x10;
-
-                       var param_count = method.HasParameters ? method.Parameters.Count : 0;
-
-                       WriteByte (calling_convention);
-
-                       if (generic_arity > 0)
-                               WriteCompressedUInt32 ((uint) generic_arity);
-
-                       WriteCompressedUInt32 ((uint) param_count);
-                       WriteTypeSignature (method.ReturnType);
-
-                       if (param_count == 0)
-                               return;
-
-                       var parameters = method.Parameters;
-
-                       for (int i = 0; i < param_count; i++)
-                               WriteTypeSignature (parameters [i].ParameterType);
-               }
-
-               uint MakeTypeDefOrRefCodedRID (TypeReference type)
-               {
-                       return CodedIndex.TypeDefOrRef.CompressMetadataToken (metadata.LookupToken (type));
-               }
-
-               public void WriteTypeSignature (TypeReference type)
-               {
-                       if (type == null)
-                               throw new ArgumentNullException ();
-
-                       var etype = type.etype;
-
-                       switch (etype) {
-                       case ElementType.MVar:
-                       case ElementType.Var: {
-                               var generic_parameter = (GenericParameter) type;
-
-                               WriteElementType (etype);
-                               var position = generic_parameter.Position;
-                               if (position == -1)
-                                       throw new NotSupportedException ();
-
-                               WriteCompressedUInt32 ((uint) position);
-                               break;
-                       }
-
-                       case ElementType.GenericInst: {
-                               var generic_instance = (GenericInstanceType) type;
-                               WriteElementType (ElementType.GenericInst);
-                               WriteElementType (generic_instance.IsValueType ? ElementType.ValueType : ElementType.Class);
-                               WriteCompressedUInt32 (MakeTypeDefOrRefCodedRID (generic_instance.ElementType));
-
-                               WriteGenericInstanceSignature (generic_instance);
-                               break;
-                       }
-
-                       case ElementType.Ptr:
-                       case ElementType.ByRef:
-                       case ElementType.Pinned:
-                       case ElementType.Sentinel: {
-                               var type_spec = (TypeSpecification) type;
-                               WriteElementType (etype);
-                               WriteTypeSignature (type_spec.ElementType);
-                               break;
-                       }
-
-                       case ElementType.FnPtr: {
-                               var fptr = (FunctionPointerType) type;
-                               WriteElementType (ElementType.FnPtr);
-                               WriteMethodSignature (fptr);
-                               break;
-                       }
-
-                       case ElementType.CModOpt:
-                       case ElementType.CModReqD: {
-                               var modifier = (IModifierType) type;
-                               WriteModifierSignature (etype, modifier);
-                               break;
-                       }
-
-                       case ElementType.Array: {
-                               var array = (ArrayType) type;
-                               if (!array.IsVector) {
-                                       WriteArrayTypeSignature (array);
-                                       break;
-                               }
-
-                               WriteElementType (ElementType.SzArray);
-                               WriteTypeSignature (array.ElementType);
-                               break;
-                       }
-
-                       case ElementType.None: {
-                               WriteElementType (type.IsValueType ? ElementType.ValueType : ElementType.Class);
-                               WriteCompressedUInt32 (MakeTypeDefOrRefCodedRID (type));
-                               break;
-                       }
-
-                       default:
-                               if (!TryWriteElementType (type))
-                                       throw new NotSupportedException ();
-
-                               break;
-
-                       }
-               }
-
-               void WriteArrayTypeSignature (ArrayType array)
-               {
-                       WriteElementType (ElementType.Array);
-                       WriteTypeSignature (array.ElementType);
-
-                       var dimensions = array.Dimensions;
-                       var rank = dimensions.Count;
-
-                       WriteCompressedUInt32 ((uint) rank);
-
-                       var sized = 0;
-                       var lbounds = 0;
-
-                       for (int i = 0; i < rank; i++) {
-                               var dimension = dimensions [i];
-
-                               if (dimension.UpperBound.HasValue) {
-                                       sized++;
-                                       lbounds++;
-                               } else if (dimension.LowerBound.HasValue)
-                                       lbounds++;
-                       }
-
-                       var sizes = new int [sized];
-                       var low_bounds = new int [lbounds];
-
-                       for (int i = 0; i < lbounds; i++) {
-                               var dimension = dimensions [i];
-                               low_bounds [i] = dimension.LowerBound.GetValueOrDefault ();
-                               if (dimension.UpperBound.HasValue)
-                                       sizes [i] = dimension.UpperBound.Value - low_bounds [i] + 1;
-                       }
-
-                       WriteCompressedUInt32 ((uint) sized);
-                       for (int i = 0; i < sized; i++)
-                               WriteCompressedUInt32 ((uint) sizes [i]);
-
-                       WriteCompressedUInt32 ((uint) lbounds);
-                       for (int i = 0; i < lbounds; i++)
-                               WriteCompressedInt32 (low_bounds [i]);
-               }
-
-               public void WriteGenericInstanceSignature (IGenericInstance instance)
-               {
-                       var generic_arguments = instance.GenericArguments;
-                       var arity = generic_arguments.Count;
-
-                       WriteCompressedUInt32 ((uint) arity);
-                       for (int i = 0; i < arity; i++)
-                               WriteTypeSignature (generic_arguments [i]);
-               }
-
-               void WriteModifierSignature (ElementType element_type, IModifierType type)
-               {
-                       WriteElementType (element_type);
-                       WriteCompressedUInt32 (MakeTypeDefOrRefCodedRID (type.ModifierType));
-                       WriteTypeSignature (type.ElementType);
-               }
-
-               bool TryWriteElementType (TypeReference type)
-               {
-                       var element = type.etype;
-
-                       if (element == ElementType.None)
-                               return false;
-
-                       WriteElementType (element);
-                       return true;
-               }
-
-               public void WriteConstantString (string value)
-               {
-                       WriteBytes (Encoding.Unicode.GetBytes (value));
-               }
-
-               public void WriteConstantPrimitive (object value)
-               {
-                       WritePrimitiveValue (value);
-               }
-
-               public void WriteCustomAttributeConstructorArguments (CustomAttribute attribute)
-               {
-                       if (!attribute.HasConstructorArguments)
-                               return;
-
-                       var arguments = attribute.ConstructorArguments;
-                       var parameters = attribute.Constructor.Parameters;
-
-                       if (parameters.Count != arguments.Count)
-                               throw new InvalidOperationException ();
-
-                       for (int i = 0; i < arguments.Count; i++)
-                               WriteCustomAttributeFixedArgument (parameters [i].ParameterType, arguments [i]);
-               }
-
-               void WriteCustomAttributeFixedArgument (TypeReference type, CustomAttributeArgument argument)
-               {
-                       if (type.IsArray) {
-                               WriteCustomAttributeFixedArrayArgument ((ArrayType) type, argument);
-                               return;
-                       }
-
-                       WriteCustomAttributeElement (type, argument);
-               }
-
-               void WriteCustomAttributeFixedArrayArgument (ArrayType type, CustomAttributeArgument argument)
-               {
-                       var values = argument.Value as CustomAttributeArgument [];
-
-                       if (values == null) {
-                               WriteUInt32 (0xffffffff);
-                               return;
-                       }
-
-                       WriteInt32 (values.Length);
-
-                       if (values.Length == 0)
-                               return;
-
-                       var element_type = type.ElementType;
-
-                       for (int i = 0; i < values.Length; i++)
-                               WriteCustomAttributeElement (element_type, values [i]);
-               }
-
-               void WriteCustomAttributeElement (TypeReference type, CustomAttributeArgument argument)
-               {
-                       if (type.IsArray) {
-                               WriteCustomAttributeFixedArrayArgument ((ArrayType) type, argument);
-                               return;
-                       }
-
-                       if (type.etype == ElementType.Object) {
-                               argument = (CustomAttributeArgument) argument.Value;
-                               type = argument.Type;
-
-                               WriteCustomAttributeFieldOrPropType (type);
-                               WriteCustomAttributeElement (type, argument);
-                               return;
-                       }
-
-                       WriteCustomAttributeValue (type, argument.Value);
-               }
-
-               void WriteCustomAttributeValue (TypeReference type, object value)
-               {
-                       var etype = type.etype;
-
-                       switch (etype) {
-                       case ElementType.String:
-                               var @string = (string) value;
-                               if (@string == null)
-                                       WriteByte (0xff);
-                               else
-                                       WriteUTF8String (@string);
-                               break;
-                       case ElementType.None:
-                               if (type.IsTypeOf ("System", "Type"))
-                                       WriteTypeReference ((TypeReference) value);
-                               else
-                                       WriteCustomAttributeEnumValue (type, value);
-                               break;
-                       default:
-                               WritePrimitiveValue (value);
-                               break;
-                       }
-               }
-
-               void WritePrimitiveValue (object value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ();
-
-                       switch (Type.GetTypeCode (value.GetType ())) {
-                       case TypeCode.Boolean:
-                               WriteByte ((byte) (((bool) value) ? 1 : 0));
-                               break;
-                       case TypeCode.Byte:
-                               WriteByte ((byte) value);
-                               break;
-                       case TypeCode.SByte:
-                               WriteSByte ((sbyte) value);
-                               break;
-                       case TypeCode.Int16:
-                               WriteInt16 ((short) value);
-                               break;
-                       case TypeCode.UInt16:
-                               WriteUInt16 ((ushort) value);
-                               break;
-                       case TypeCode.Char:
-                               WriteInt16 ((short) (char) value);
-                               break;
-                       case TypeCode.Int32:
-                               WriteInt32 ((int) value);
-                               break;
-                       case TypeCode.UInt32:
-                               WriteUInt32 ((uint) value);
-                               break;
-                       case TypeCode.Single:
-                               WriteSingle ((float) value);
-                               break;
-                       case TypeCode.Int64:
-                               WriteInt64 ((long) value);
-                               break;
-                       case TypeCode.UInt64:
-                               WriteUInt64 ((ulong) value);
-                               break;
-                       case TypeCode.Double:
-                               WriteDouble ((double) value);
-                               break;
-                       default:
-                               throw new NotSupportedException (value.GetType ().FullName);
-                       }
-               }
-
-               void WriteCustomAttributeEnumValue (TypeReference enum_type, object value)
-               {
-                       var type = enum_type.CheckedResolve ();
-                       if (!type.IsEnum)
-                               throw new ArgumentException ();
-
-                       WriteCustomAttributeValue (type.GetEnumUnderlyingType (), value);
-               }
-
-               void WriteCustomAttributeFieldOrPropType (TypeReference type)
-               {
-                       if (type.IsArray) {
-                               var array = (ArrayType) type;
-                               WriteElementType (ElementType.SzArray);
-                               WriteCustomAttributeFieldOrPropType (array.ElementType);
-                               return;
-                       }
-
-                       var etype = type.etype;
-
-                       switch (etype) {
-                       case ElementType.Object:
-                               WriteElementType (ElementType.Boxed);
-                               return;
-                       case ElementType.None:
-                               if (type.IsTypeOf ("System", "Type"))
-                                       WriteElementType (ElementType.Type);
-                               else {
-                                       WriteElementType (ElementType.Enum);
-                                       WriteTypeReference (type);
-                               }
-                               return;
-                       default:
-                               WriteElementType (etype);
-                               return;
-                       }
-               }
-
-               public void WriteCustomAttributeNamedArguments (CustomAttribute attribute)
-               {
-                       var count = GetNamedArgumentCount (attribute);
-
-                       WriteUInt16 ((ushort) count);
-
-                       if (count == 0)
-                               return;
-
-                       WriteICustomAttributeNamedArguments (attribute);
-               }
-
-               static int GetNamedArgumentCount (ICustomAttribute attribute)
-               {
-                       int count = 0;
-
-                       if (attribute.HasFields)
-                               count += attribute.Fields.Count;
-
-                       if (attribute.HasProperties)
-                               count += attribute.Properties.Count;
-
-                       return count;
-               }
-
-               void WriteICustomAttributeNamedArguments (ICustomAttribute attribute)
-               {
-                       if (attribute.HasFields)
-                               WriteCustomAttributeNamedArguments (0x53, attribute.Fields);
-
-                       if (attribute.HasProperties)
-                               WriteCustomAttributeNamedArguments (0x54, attribute.Properties);
-               }
-
-               void WriteCustomAttributeNamedArguments (byte kind, Collection<CustomAttributeNamedArgument> named_arguments)
-               {
-                       for (int i = 0; i < named_arguments.Count; i++)
-                               WriteCustomAttributeNamedArgument (kind, named_arguments [i]);
-               }
-
-               void WriteCustomAttributeNamedArgument (byte kind, CustomAttributeNamedArgument named_argument)
-               {
-                       var argument = named_argument.Argument;
-
-                       WriteByte (kind);
-                       WriteCustomAttributeFieldOrPropType (argument.Type);
-                       WriteUTF8String (named_argument.Name);
-                       WriteCustomAttributeFixedArgument (argument.Type, argument);
-               }
-
-               void WriteSecurityAttribute (SecurityAttribute attribute)
-               {
-                       WriteTypeReference (attribute.AttributeType);
-
-                       var count = GetNamedArgumentCount (attribute);
-
-                       if (count == 0) {
-                               WriteCompressedUInt32 (1); // length
-                               WriteCompressedUInt32 (0); // count
-                               return;
-                       }
-
-                       var buffer = new SignatureWriter (metadata);
-                       buffer.WriteCompressedUInt32 ((uint) count);
-                       buffer.WriteICustomAttributeNamedArguments (attribute);
-
-                       WriteCompressedUInt32 ((uint) buffer.length);
-                       WriteBytes (buffer);
-               }
-
-               public void WriteSecurityDeclaration (SecurityDeclaration declaration)
-               {
-                       WriteByte ((byte) '.');
-
-                       var attributes = declaration.security_attributes;
-                       if (attributes == null)
-                               throw new NotSupportedException ();
-
-                       WriteCompressedUInt32 ((uint) attributes.Count);
-
-                       for (int i = 0; i < attributes.Count; i++)
-                               WriteSecurityAttribute (attributes [i]);
-               }
-
-               public void WriteXmlSecurityDeclaration (SecurityDeclaration declaration)
-               {
-                       var xml = GetXmlSecurityDeclaration (declaration);
-                       if (xml == null)
-                               throw new NotSupportedException ();
-
-                       WriteBytes (Encoding.Unicode.GetBytes (xml));
-               }
-
-               static string GetXmlSecurityDeclaration (SecurityDeclaration declaration)
-               {
-                       if (declaration.security_attributes == null || declaration.security_attributes.Count != 1)
-                               return null;
-
-                       var attribute = declaration.security_attributes [0];
-
-                       if (!attribute.AttributeType.IsTypeOf ("System.Security.Permissions", "PermissionSetAttribute"))
-                               return null;
-
-                       if (attribute.properties == null || attribute.properties.Count != 1)
-                               return null;
-
-                       var property = attribute.properties [0];
-                       if (property.Name != "XML")
-                               return null;
-
-                       return (string) property.Argument.Value;
-               }
-
-               void WriteTypeReference (TypeReference type)
-               {
-                       WriteUTF8String (TypeParser.ToParseable (type));
-               }
-
-               public void WriteMarshalInfo (MarshalInfo marshal_info)
-               {
-                       WriteNativeType (marshal_info.native);
-
-                       switch (marshal_info.native) {
-                       case NativeType.Array: {
-                               var array = (ArrayMarshalInfo) marshal_info;
-                               if (array.element_type != NativeType.None)
-                                       WriteNativeType (array.element_type);
-                               if (array.size_parameter_index > -1)
-                                       WriteCompressedUInt32 ((uint) array.size_parameter_index);
-                               if (array.size > -1)
-                                       WriteCompressedUInt32 ((uint) array.size);
-                               if (array.size_parameter_multiplier > -1)
-                                       WriteCompressedUInt32 ((uint) array.size_parameter_multiplier);
-                               return;
-                       }
-                       case NativeType.SafeArray: {
-                               var array = (SafeArrayMarshalInfo) marshal_info;
-                               if (array.element_type != VariantType.None)
-                                       WriteVariantType (array.element_type);
-                               return;
-                       }
-                       case NativeType.FixedArray: {
-                               var array = (FixedArrayMarshalInfo) marshal_info;
-                               if (array.size > -1)
-                                       WriteCompressedUInt32 ((uint) array.size);
-                               if (array.element_type != NativeType.None)
-                                       WriteNativeType (array.element_type);
-                               return;
-                       }
-                       case NativeType.FixedSysString:
-                               var sys_string = (FixedSysStringMarshalInfo) marshal_info;
-                               if (sys_string.size > -1)
-                                       WriteCompressedUInt32 ((uint) sys_string.size);
-                               return;
-                       case NativeType.CustomMarshaler:
-                               var marshaler = (CustomMarshalInfo) marshal_info;
-                               WriteUTF8String (marshaler.guid != Guid.Empty ? marshaler.guid.ToString () : string.Empty);
-                               WriteUTF8String (marshaler.unmanaged_type);
-                               WriteTypeReference (marshaler.managed_type);
-                               WriteUTF8String (marshaler.cookie);
-                               return;
-                       }
-               }
-
-               void WriteNativeType (NativeType native)
-               {
-                       WriteByte ((byte) native);
-               }
-
-               void WriteVariantType (VariantType variant)
-               {
-                       WriteByte ((byte) variant);
-               }
-       }
-
-#endif
-
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/BaseAssemblyResolver.cs b/mcs/class/Mono.Cecil/Mono.Cecil/BaseAssemblyResolver.cs
deleted file mode 100644 (file)
index 10ab2c3..0000000
+++ /dev/null
@@ -1,363 +0,0 @@
-//
-// BaseAssemblyResolver.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-using System.IO;
-using System.Text;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public delegate AssemblyDefinition AssemblyResolveEventHandler (object sender, AssemblyNameReference reference);
-
-       public sealed class AssemblyResolveEventArgs : EventArgs {
-
-               readonly AssemblyNameReference reference;
-
-               public AssemblyNameReference AssemblyReference {
-                       get { return reference; }
-               }
-
-               public AssemblyResolveEventArgs (AssemblyNameReference reference)
-               {
-                       this.reference = reference;
-               }
-       }
-
-#if !SILVERLIGHT && !CF
-       [Serializable]
-#endif
-       public class AssemblyResolutionException : FileNotFoundException {
-
-               readonly AssemblyNameReference reference;
-
-               public AssemblyNameReference AssemblyReference {
-                       get { return reference; }
-               }
-
-               public AssemblyResolutionException (AssemblyNameReference reference)
-                       : base (string.Format ("Failed to resolve assembly: '{0}'", reference))
-               {
-                       this.reference = reference;
-               }
-
-#if !SILVERLIGHT && !CF
-               protected AssemblyResolutionException (
-                       System.Runtime.Serialization.SerializationInfo info,
-                       System.Runtime.Serialization.StreamingContext context)
-                       : base (info, context)
-               {
-               }
-#endif
-       }
-
-       public abstract class BaseAssemblyResolver : IAssemblyResolver {
-
-               static readonly bool on_mono = Type.GetType ("Mono.Runtime") != null;
-
-               readonly Collection<string> directories;
-
-#if !SILVERLIGHT && !CF
-               Collection<string> gac_paths;
-#endif
-
-               public void AddSearchDirectory (string directory)
-               {
-                       directories.Add (directory);
-               }
-
-               public void RemoveSearchDirectory (string directory)
-               {
-                       directories.Remove (directory);
-               }
-
-               public string [] GetSearchDirectories ()
-               {
-                       var directories = new string [this.directories.size];
-                       Array.Copy (this.directories.items, directories, directories.Length);
-                       return directories;
-               }
-
-               public virtual AssemblyDefinition Resolve (string fullName)
-               {
-                       return Resolve (fullName, new ReaderParameters ());
-               }
-
-               public virtual AssemblyDefinition Resolve (string fullName, ReaderParameters parameters)
-               {
-                       if (fullName == null)
-                               throw new ArgumentNullException ("fullName");
-
-                       return Resolve (AssemblyNameReference.Parse (fullName), parameters);
-               }
-
-               public event AssemblyResolveEventHandler ResolveFailure;
-
-               protected BaseAssemblyResolver ()
-               {
-                       directories = new Collection<string> (2) { ".", "bin" };
-               }
-
-               AssemblyDefinition GetAssembly (string file, ReaderParameters parameters)
-               {
-                       if (parameters.AssemblyResolver == null)
-                               parameters.AssemblyResolver = this;
-
-                       return ModuleDefinition.ReadModule (file, parameters).Assembly;
-               }
-
-               public virtual AssemblyDefinition Resolve (AssemblyNameReference name)
-               {
-                       return Resolve (name, new ReaderParameters ());
-               }
-
-               public virtual AssemblyDefinition Resolve (AssemblyNameReference name, ReaderParameters parameters)
-               {
-                       if (name == null)
-                               throw new ArgumentNullException ("name");
-                       if (parameters == null)
-                               parameters = new ReaderParameters ();
-
-                       var assembly = SearchDirectory (name, directories, parameters);
-                       if (assembly != null)
-                               return assembly;
-
-#if !SILVERLIGHT && !CF
-                       var framework_dir = Path.GetDirectoryName (typeof (object).Module.FullyQualifiedName);
-
-                       if (IsZero (name.Version)) {
-                               assembly = SearchDirectory (name, new [] { framework_dir }, parameters);
-                               if (assembly != null)
-                                       return assembly;
-                       }
-
-                       if (name.Name == "mscorlib") {
-                               assembly = GetCorlib (name, parameters);
-                               if (assembly != null)
-                                       return assembly;
-                       }
-
-                       assembly = GetAssemblyInGac (name, parameters);
-                       if (assembly != null)
-                               return assembly;
-
-                       assembly = SearchDirectory (name, new [] { framework_dir }, parameters);
-                       if (assembly != null)
-                               return assembly;
-#endif
-
-                       if (ResolveFailure != null) {
-                               assembly = ResolveFailure (this, name);
-                               if (assembly != null)
-                                       return assembly;
-                       }
-
-                       throw new AssemblyResolutionException (name);
-               }
-
-               AssemblyDefinition SearchDirectory (AssemblyNameReference name, IEnumerable<string> directories, ReaderParameters parameters)
-               {
-                       var extensions = new [] { ".exe", ".dll" };
-                       foreach (var directory in directories) {
-                               foreach (var extension in extensions) {
-                                       string file = Path.Combine (directory, name.Name + extension);
-                                       if (File.Exists (file))
-                                               return GetAssembly (file, parameters);
-                               }
-                       }
-
-                       return null;
-               }
-
-               static bool IsZero (Version version)
-               {
-                       return version == null || (version.Major == 0 && version.Minor == 0 && version.Build == 0 && version.Revision == 0);
-               }
-
-#if !SILVERLIGHT && !CF
-               AssemblyDefinition GetCorlib (AssemblyNameReference reference, ReaderParameters parameters)
-               {
-                       var version = reference.Version;
-                       var corlib = typeof (object).Assembly.GetName ();
-
-                       if (corlib.Version == version || IsZero (version))
-                               return GetAssembly (typeof (object).Module.FullyQualifiedName, parameters);
-
-                       var path = Directory.GetParent (
-                               Directory.GetParent (
-                                       typeof (object).Module.FullyQualifiedName).FullName
-                               ).FullName;
-
-                       if (on_mono) {
-                               if (version.Major == 1)
-                                       path = Path.Combine (path, "1.0");
-                               else if (version.Major == 2) {
-                                       if (version.MajorRevision == 5)
-                                               path = Path.Combine (path, "2.1");
-                                       else
-                                               path = Path.Combine (path, "2.0");
-                               } else if (version.Major == 4)
-                                       path = Path.Combine (path, "4.0");
-                               else
-                                       throw new NotSupportedException ("Version not supported: " + version);
-                       } else {
-                               switch (version.Major) {
-                               case 1:
-                                       if (version.MajorRevision == 3300)
-                                               path = Path.Combine (path, "v1.0.3705");
-                                       else
-                                               path = Path.Combine (path, "v1.0.5000.0");
-                                       break;
-                               case 2:
-                                       path = Path.Combine (path, "v2.0.50727");
-                                       break;
-                               case 4:
-                                       path = Path.Combine (path, "v4.0.30319");
-                                       break;
-                               default:
-                                       throw new NotSupportedException ("Version not supported: " + version);
-                               }
-                       }
-
-                       var file = Path.Combine (path, "mscorlib.dll");
-                       if (File.Exists (file))
-                               return GetAssembly (file, parameters);
-
-                       return null;
-               }
-
-               static Collection<string> GetGacPaths ()
-               {
-                       if (on_mono)
-                               return GetDefaultMonoGacPaths ();
-
-                       var paths = new Collection<string> (2);
-                       var windir = Environment.GetEnvironmentVariable ("WINDIR");
-                       if (windir == null)
-                               return paths;
-
-                       paths.Add (Path.Combine (windir, "assembly"));
-                       paths.Add (Path.Combine (windir, Path.Combine ("Microsoft.NET", "assembly")));
-                       return paths;
-               }
-
-               static Collection<string> GetDefaultMonoGacPaths ()
-               {
-                       var paths = new Collection<string> (1);
-                       var gac = GetCurrentMonoGac ();
-                       if (gac != null)
-                               paths.Add (gac);
-
-                       var gac_paths_env = Environment.GetEnvironmentVariable ("MONO_GAC_PREFIX");
-                       if (string.IsNullOrEmpty (gac_paths_env))
-                               return paths;
-
-                       var prefixes = gac_paths_env.Split (Path.PathSeparator);
-                       foreach (var prefix in prefixes) {
-                               if (string.IsNullOrEmpty (prefix))
-                                       continue;
-
-                               var gac_path = Path.Combine (Path.Combine (Path.Combine (prefix, "lib"), "mono"), "gac");
-                               if (Directory.Exists (gac_path) && !paths.Contains (gac))
-                                       paths.Add (gac_path);
-                       }
-
-                       return paths;
-               }
-
-               static string GetCurrentMonoGac ()
-               {
-                       return Path.Combine (
-                               Directory.GetParent (
-                                       Path.GetDirectoryName (typeof (object).Module.FullyQualifiedName)).FullName,
-                               "gac");
-               }
-
-               AssemblyDefinition GetAssemblyInGac (AssemblyNameReference reference, ReaderParameters parameters)
-               {
-                       if (reference.PublicKeyToken == null || reference.PublicKeyToken.Length == 0)
-                               return null;
-
-                       if (gac_paths == null)
-                               gac_paths = GetGacPaths ();
-
-                       if (on_mono)
-                               return GetAssemblyInMonoGac (reference, parameters);
-
-                       return GetAssemblyInNetGac (reference, parameters);
-               }
-
-               AssemblyDefinition GetAssemblyInMonoGac (AssemblyNameReference reference, ReaderParameters parameters)
-               {
-                       for (int i = 0; i < gac_paths.Count; i++) {
-                               var gac_path = gac_paths [i];
-                               var file = GetAssemblyFile (reference, string.Empty, gac_path);
-                               if (File.Exists (file))
-                                       return GetAssembly (file, parameters);
-                       }
-
-                       return null;
-               }
-
-               AssemblyDefinition GetAssemblyInNetGac (AssemblyNameReference reference, ReaderParameters parameters)
-               {
-                       var gacs = new [] { "GAC_MSIL", "GAC_32", "GAC" };
-                       var prefixes = new [] { string.Empty, "v4.0_" };
-
-                       for (int i = 0; i < 2; i++) {
-                               for (int j = 0; j < gacs.Length; j++) {
-                                       var gac = Path.Combine (gac_paths [i], gacs [j]);
-                                       var file = GetAssemblyFile (reference, prefixes [i], gac);
-                                       if (Directory.Exists (gac) && File.Exists (file))
-                                               return GetAssembly (file, parameters);
-                               }
-                       }
-
-                       return null;
-               }
-
-               static string GetAssemblyFile (AssemblyNameReference reference, string prefix, string gac)
-               {
-                       var gac_folder = new StringBuilder ()
-                               .Append (prefix)
-                               .Append (reference.Version)
-                               .Append ("__");
-
-                       for (int i = 0; i < reference.PublicKeyToken.Length; i++)
-                               gac_folder.Append (reference.PublicKeyToken [i].ToString ("x2"));
-
-                       return Path.Combine (
-                               Path.Combine (
-                                       Path.Combine (gac, reference.Name), gac_folder.ToString ()),
-                               reference.Name + ".dll");
-               }
-#endif
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/CallSite.cs b/mcs/class/Mono.Cecil/Mono.Cecil/CallSite.cs
deleted file mode 100644 (file)
index 2d4ed41..0000000
+++ /dev/null
@@ -1,124 +0,0 @@
-//
-// CallSite.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Text;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public sealed class CallSite : IMethodSignature {
-
-               readonly MethodReference signature;
-
-               public bool HasThis {
-                       get { return signature.HasThis; }
-                       set { signature.HasThis = value; }
-               }
-
-               public bool ExplicitThis {
-                       get { return signature.ExplicitThis; }
-                       set { signature.ExplicitThis = value; }
-               }
-
-               public MethodCallingConvention CallingConvention {
-                       get { return signature.CallingConvention; }
-                       set { signature.CallingConvention = value; }
-               }
-
-               public bool HasParameters {
-                       get { return signature.HasParameters; }
-               }
-
-               public Collection<ParameterDefinition> Parameters {
-                       get { return signature.Parameters; }
-               }
-
-               public TypeReference ReturnType {
-                       get { return signature.MethodReturnType.ReturnType; }
-                       set { signature.MethodReturnType.ReturnType = value; }
-               }
-
-               public MethodReturnType MethodReturnType {
-                       get { return signature.MethodReturnType; }
-               }
-
-               public string Name {
-                       get { return string.Empty; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public string Namespace {
-                       get { return string.Empty; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public ModuleDefinition Module {
-                       get { return ReturnType.Module; }
-               }
-
-               public IMetadataScope Scope {
-                       get { return signature.ReturnType.Scope; }
-               }
-
-               public MetadataToken MetadataToken {
-                       get { return signature.token; }
-                       set { signature.token = value; }
-               }
-
-               public string FullName {
-                       get {
-                               var signature = new StringBuilder ();
-                               signature.Append (ReturnType.FullName);
-                               this.MethodSignatureFullName (signature);
-                               return signature.ToString ();
-                       }
-               }
-
-               internal CallSite ()
-               {
-                       this.signature = new MethodReference ();
-                       this.signature.token = new MetadataToken (TokenType.Signature, 0);
-               }
-
-               public CallSite (TypeReference returnType)
-                       : this ()
-               {
-                       if (returnType == null)
-                               throw new ArgumentNullException ("returnType");
-
-                       this.signature.ReturnType = returnType;
-               }
-
-               public override string ToString ()
-               {
-                       return FullName;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/CustomAttribute.cs b/mcs/class/Mono.Cecil/Mono.Cecil/CustomAttribute.cs
deleted file mode 100644 (file)
index 310f725..0000000
+++ /dev/null
@@ -1,232 +0,0 @@
-//
-// CustomAttribute.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public struct CustomAttributeArgument {
-
-               readonly TypeReference type;
-               readonly object value;
-
-               public TypeReference Type {
-                       get { return type; }
-               }
-
-               public object Value {
-                       get { return value; }
-               }
-
-               public CustomAttributeArgument (TypeReference type, object value)
-               {
-                       Mixin.CheckType (type);
-                       this.type = type;
-                       this.value = value;
-               }
-       }
-
-       public struct CustomAttributeNamedArgument {
-
-               readonly string name;
-               readonly CustomAttributeArgument argument;
-
-               public string Name {
-                       get { return name; }
-               }
-
-               public CustomAttributeArgument Argument {
-                       get { return argument; }
-               }
-
-               public CustomAttributeNamedArgument (string name, CustomAttributeArgument argument)
-               {
-                       Mixin.CheckName (name);
-                       this.name = name;
-                       this.argument = argument;
-               }
-       }
-
-       public interface ICustomAttribute {
-
-               TypeReference AttributeType { get; }
-
-               bool HasFields { get; }
-               bool HasProperties { get; }
-               Collection<CustomAttributeNamedArgument> Fields { get; }
-               Collection<CustomAttributeNamedArgument> Properties { get; }
-       }
-
-       public sealed class CustomAttribute : ICustomAttribute {
-
-               readonly internal uint signature;
-               internal bool resolved;
-               MethodReference constructor;
-               byte [] blob;
-               internal Collection<CustomAttributeArgument> arguments;
-               internal Collection<CustomAttributeNamedArgument> fields;
-               internal Collection<CustomAttributeNamedArgument> properties;
-
-               public MethodReference Constructor {
-                       get { return constructor; }
-                       set { constructor = value; }
-               }
-
-               public TypeReference AttributeType {
-                       get { return constructor.DeclaringType; }
-               }
-
-               public bool IsResolved {
-                       get { return resolved; }
-               }
-
-               public bool HasConstructorArguments {
-                       get {
-                               Resolve ();
-
-                               return !arguments.IsNullOrEmpty ();
-                       }
-               }
-
-               public Collection<CustomAttributeArgument> ConstructorArguments {
-                       get {
-                               Resolve ();
-
-                               return arguments ?? (arguments = new Collection<CustomAttributeArgument> ());
-                       }
-               }
-
-               public bool HasFields {
-                       get {
-                               Resolve ();
-
-                               return !fields.IsNullOrEmpty ();
-                       }
-               }
-
-               public Collection<CustomAttributeNamedArgument> Fields {
-                       get {
-                               Resolve ();
-
-                               return fields ?? (fields = new Collection<CustomAttributeNamedArgument> ());
-                       }
-               }
-
-               public bool HasProperties {
-                       get {
-                               Resolve ();
-
-                               return !properties.IsNullOrEmpty ();
-                       }
-               }
-
-               public Collection<CustomAttributeNamedArgument> Properties {
-                       get {
-                               Resolve ();
-
-                               return properties ?? (properties = new Collection<CustomAttributeNamedArgument> ());
-                       }
-               }
-
-               internal bool HasImage {
-                       get { return constructor != null && constructor.HasImage; }
-               }
-
-               internal ModuleDefinition Module {
-                       get { return constructor.Module; }
-               }
-
-               internal CustomAttribute (uint signature, MethodReference constructor)
-               {
-                       this.signature = signature;
-                       this.constructor = constructor;
-                       this.resolved = false;
-               }
-
-               public CustomAttribute (MethodReference constructor)
-               {
-                       this.constructor = constructor;
-                       this.resolved = true;
-               }
-
-               public CustomAttribute (MethodReference constructor, byte [] blob)
-               {
-                       this.constructor = constructor;
-                       this.resolved = false;
-                       this.blob = blob;
-               }
-
-               public byte [] GetBlob ()
-               {
-                       if (blob != null)
-                               return blob;
-
-                       if (!HasImage || signature == 0)
-                               throw new NotSupportedException ();
-
-                       return blob = Module.Read (this, (attribute, reader) => reader.ReadCustomAttributeBlob (attribute.signature));
-               }
-
-               void Resolve ()
-               {
-                       if (resolved || !HasImage)
-                               return;
-
-                       try {
-                               Module.Read (this, (attribute, reader) => {
-                                       reader.ReadCustomAttributeSignature (attribute);
-                                       return this;
-                               });
-
-                               resolved = true;
-                       } catch (ResolutionException) {
-                               if (arguments != null)
-                                       arguments.Clear ();
-                               if (fields != null)
-                                       fields.Clear ();
-                               if (properties != null)
-                                       properties.Clear ();
-
-                               resolved = false;
-                       }
-               }
-       }
-
-       static partial class Mixin {
-
-               public static void CheckName (string name)
-               {
-                       if (name == null)
-                               throw new ArgumentNullException ("name");
-                       if (name.Length == 0)
-                               throw new ArgumentException ("Empty name");
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/DefaultAssemblyResolver.cs b/mcs/class/Mono.Cecil/Mono.Cecil/DefaultAssemblyResolver.cs
deleted file mode 100644 (file)
index 93d2493..0000000
+++ /dev/null
@@ -1,75 +0,0 @@
-//
-// DefaultAssemblyResolver.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public static class GlobalAssemblyResolver {
-
-               public static readonly IAssemblyResolver Instance = new DefaultAssemblyResolver ();
-       }
-
-       public class DefaultAssemblyResolver : BaseAssemblyResolver {
-
-               readonly IDictionary<string, AssemblyDefinition> cache;
-
-               public DefaultAssemblyResolver ()
-               {
-                       cache = new Dictionary<string, AssemblyDefinition> ();
-               }
-
-               public override AssemblyDefinition Resolve (AssemblyNameReference name)
-               {
-                       if (name == null)
-                               throw new ArgumentNullException ("name");
-
-                       AssemblyDefinition assembly;
-                       if (cache.TryGetValue (name.FullName, out assembly))
-                               return assembly;
-
-                       assembly = base.Resolve (name);
-                       cache [name.FullName] = assembly;
-
-                       return assembly;
-               }
-
-               protected void RegisterAssembly (AssemblyDefinition assembly)
-               {
-                       if (assembly == null)
-                               throw new ArgumentNullException ("assembly");
-
-                       var name = assembly.Name.FullName;
-                       if (cache.ContainsKey (name))
-                               return;
-
-                       cache [name] = assembly;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/EmbeddedResource.cs b/mcs/class/Mono.Cecil/Mono.Cecil/EmbeddedResource.cs
deleted file mode 100644 (file)
index e12dd0b..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-//
-// EmbeddedResource.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.IO;
-
-namespace Mono.Cecil {
-
-       public sealed class EmbeddedResource : Resource {
-
-               readonly MetadataReader reader;
-
-               uint? offset;
-               byte [] data;
-               Stream stream;
-
-               public override ResourceType ResourceType {
-                       get { return ResourceType.Embedded; }
-               }
-
-               public EmbeddedResource (string name, ManifestResourceAttributes attributes, byte [] data) :
-                       base (name, attributes)
-               {
-                       this.data = data;
-               }
-
-               public EmbeddedResource (string name, ManifestResourceAttributes attributes, Stream stream) :
-                       base (name, attributes)
-               {
-                       this.stream = stream;
-               }
-
-               internal EmbeddedResource (string name, ManifestResourceAttributes attributes, uint offset, MetadataReader reader)
-                       : base (name, attributes)
-               {
-                       this.offset = offset;
-                       this.reader = reader;
-               }
-
-               public Stream GetResourceStream ()
-               {
-                       if (stream != null)
-                               return stream;
-
-                       if (data != null)
-                               return new MemoryStream (data);
-
-                       if (offset.HasValue)
-                               return reader.GetManagedResourceStream (offset.Value);
-
-                       throw new InvalidOperationException ();
-               }
-
-               public byte [] GetResourceData ()
-               {
-                       if (stream != null)
-                               return ReadStream (stream);
-
-                       if (data != null)
-                               return data;
-
-                       if (offset.HasValue)
-                               return reader.GetManagedResourceStream (offset.Value).ToArray ();
-
-                       throw new InvalidOperationException ();
-               }
-
-               static byte [] ReadStream (Stream stream)
-               {
-                       var length = (int) stream.Length;
-                       var data = new byte [length];
-                       int offset = 0, read;
-
-                       while ((read = stream.Read (data, offset, length - offset)) > 0)
-                               offset += read;
-
-                       return data;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/EventAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/EventAttributes.cs
deleted file mode 100644 (file)
index 815efa5..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-//
-// EventAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum EventAttributes : ushort {
-               None                    = 0x0000,
-               SpecialName             = 0x0200,       // Event is special
-               RTSpecialName   = 0x0400         // CLI provides 'special' behavior, depending upon the name of the event
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/EventDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/EventDefinition.cs
deleted file mode 100644 (file)
index 565186c..0000000
+++ /dev/null
@@ -1,168 +0,0 @@
-//
-// EventDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public sealed class EventDefinition : EventReference, IMemberDefinition {
-
-               ushort attributes;
-
-               Collection<CustomAttribute> custom_attributes;
-
-               internal MethodDefinition add_method;
-               internal MethodDefinition invoke_method;
-               internal MethodDefinition remove_method;
-               internal Collection<MethodDefinition> other_methods;
-
-               public EventAttributes Attributes {
-                       get { return (EventAttributes) attributes; }
-                       set { attributes = (ushort) value; }
-               }
-
-               public MethodDefinition AddMethod {
-                       get {
-                               if (add_method != null)
-                                       return add_method;
-
-                               InitializeMethods ();
-                               return add_method;
-                       }
-                       set { add_method = value; }
-               }
-
-               public MethodDefinition InvokeMethod {
-                       get {
-                               if (invoke_method != null)
-                                       return invoke_method;
-
-                               InitializeMethods ();
-                               return invoke_method;
-                       }
-                       set { invoke_method = value; }
-               }
-
-               public MethodDefinition RemoveMethod {
-                       get {
-                               if (remove_method != null)
-                                       return remove_method;
-
-                               InitializeMethods ();
-                               return remove_method;
-                       }
-                       set { remove_method = value; }
-               }
-
-               public bool HasOtherMethods {
-                       get {
-                               if (other_methods != null)
-                                       return other_methods.Count > 0;
-
-                               InitializeMethods ();
-                               return !other_methods.IsNullOrEmpty ();
-                       }
-               }
-
-               public Collection<MethodDefinition> OtherMethods {
-                       get {
-                               if (other_methods != null)
-                                       return other_methods;
-
-                               InitializeMethods ();
-
-                               if (other_methods != null)
-                                       return other_methods;
-
-                               return other_methods = new Collection<MethodDefinition> ();
-                       }
-               }
-
-               public bool HasCustomAttributes {
-                       get {
-                               if (custom_attributes != null)
-                                       return custom_attributes.Count > 0;
-
-                               return this.GetHasCustomAttributes (Module);
-                       }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return custom_attributes ?? (custom_attributes = this.GetCustomAttributes (Module)); }
-               }
-
-               #region EventAttributes
-
-               public bool IsSpecialName {
-                       get { return attributes.GetAttributes ((ushort) EventAttributes.SpecialName); }
-                       set { attributes = attributes.SetAttributes ((ushort) EventAttributes.SpecialName, value); }
-               }
-
-               public bool IsRuntimeSpecialName {
-                       get { return attributes.GetAttributes ((ushort) FieldAttributes.RTSpecialName); }
-                       set { attributes = attributes.SetAttributes ((ushort) FieldAttributes.RTSpecialName, value); }
-               }
-
-               #endregion
-
-               public new TypeDefinition DeclaringType {
-                       get { return (TypeDefinition) base.DeclaringType; }
-                       set { base.DeclaringType = value; }
-               }
-
-               public override bool IsDefinition {
-                       get { return true; }
-               }
-
-               public EventDefinition (string name, EventAttributes attributes, TypeReference eventType)
-                       : base (name, eventType)
-               {
-                       this.attributes = (ushort) attributes;
-                       this.token = new MetadataToken (TokenType.Event);
-               }
-
-               void InitializeMethods ()
-               {
-                       if (add_method != null
-                               || invoke_method != null
-                               || remove_method != null)
-                               return;
-
-                       var module = this.Module;
-                       if (!module.HasImage ())
-                               return;
-
-                       module.Read (this, (@event, reader) => reader.ReadMethods (@event));
-               }
-
-               public override EventDefinition Resolve ()
-               {
-                       return this;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/EventReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil/EventReference.cs
deleted file mode 100644 (file)
index 8952002..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-//
-// EventReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       public abstract class EventReference : MemberReference {
-
-               TypeReference event_type;
-
-               public TypeReference EventType {
-                       get { return event_type; }
-                       set { event_type = value; }
-               }
-
-               public override string FullName {
-                       get { return event_type.FullName + " " + MemberFullName (); }
-               }
-
-               protected EventReference (string name, TypeReference eventType)
-                       : base (name)
-               {
-                       if (eventType == null)
-                               throw new ArgumentNullException ("eventType");
-
-                       event_type = eventType;
-               }
-
-               public abstract EventDefinition Resolve ();
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ExportedType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ExportedType.cs
deleted file mode 100644 (file)
index c25f8d0..0000000
+++ /dev/null
@@ -1,249 +0,0 @@
-//
-// ExportedType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       public class ExportedType : IMetadataTokenProvider {
-
-               string @namespace;
-               string name;
-               uint attributes;
-               IMetadataScope scope;
-               ModuleDefinition module;
-               int identifier;
-               ExportedType declaring_type;
-               internal MetadataToken token;
-
-               public string Namespace {
-                       get { return @namespace; }
-                       set { @namespace = value; }
-               }
-
-               public string Name {
-                       get { return name; }
-                       set { name = value; }
-               }
-
-               public TypeAttributes Attributes {
-                       get { return (TypeAttributes) attributes; }
-                       set { attributes = (uint) value; }
-               }
-
-               public IMetadataScope Scope {
-                       get {
-                               if (declaring_type != null)
-                                       return declaring_type.Scope;
-
-                               return scope;
-                       }
-               }
-
-               public ExportedType DeclaringType {
-                       get { return declaring_type; }
-                       set { declaring_type = value; }
-               }
-
-               public MetadataToken MetadataToken {
-                       get { return token; }
-                       set { token = value; }
-               }
-
-               public int Identifier {
-                       get { return identifier; }
-                       set { identifier = value; }
-               }
-
-               #region TypeAttributes
-
-               public bool IsNotPublic {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NotPublic); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NotPublic, value); }
-               }
-
-               public bool IsPublic {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.Public); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.Public, value); }
-               }
-
-               public bool IsNestedPublic {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedPublic); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedPublic, value); }
-               }
-
-               public bool IsNestedPrivate {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedPrivate); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedPrivate, value); }
-               }
-
-               public bool IsNestedFamily {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamily); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamily, value); }
-               }
-
-               public bool IsNestedAssembly {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedAssembly); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedAssembly, value); }
-               }
-
-               public bool IsNestedFamilyAndAssembly {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamANDAssem); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamANDAssem, value); }
-               }
-
-               public bool IsNestedFamilyOrAssembly {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamORAssem); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamORAssem, value); }
-               }
-
-               public bool IsAutoLayout {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.AutoLayout); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.AutoLayout, value); }
-               }
-
-               public bool IsSequentialLayout {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.SequentialLayout); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.SequentialLayout, value); }
-               }
-
-               public bool IsExplicitLayout {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.ExplicitLayout); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.ExplicitLayout, value); }
-               }
-
-               public bool IsClass {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.ClassSemanticMask, (uint) TypeAttributes.Class); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.ClassSemanticMask, (uint) TypeAttributes.Class, value); }
-               }
-
-               public bool IsInterface {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.ClassSemanticMask, (uint) TypeAttributes.Interface); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.ClassSemanticMask, (uint) TypeAttributes.Interface, value); }
-               }
-
-               public bool IsAbstract {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.Abstract); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Abstract, value); }
-               }
-
-               public bool IsSealed {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.Sealed); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Sealed, value); }
-               }
-
-               public bool IsSpecialName {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.SpecialName); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.SpecialName, value); }
-               }
-
-               public bool IsImport {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.Import); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Import, value); }
-               }
-
-               public bool IsSerializable {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.Serializable); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Serializable, value); }
-               }
-
-               public bool IsAnsiClass {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AnsiClass); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AnsiClass, value); }
-               }
-
-               public bool IsUnicodeClass {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.UnicodeClass); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.UnicodeClass, value); }
-               }
-
-               public bool IsAutoClass {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AutoClass); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AutoClass, value); }
-               }
-
-               public bool IsBeforeFieldInit {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.BeforeFieldInit); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.BeforeFieldInit, value); }
-               }
-
-               public bool IsRuntimeSpecialName {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.RTSpecialName); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.RTSpecialName, value); }
-               }
-
-               public bool HasSecurity {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.HasSecurity); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.HasSecurity, value); }
-               }
-
-               #endregion
-
-               public bool IsForwarder {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.Forwarder); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Forwarder, value); }
-               }
-
-               public string FullName {
-                       get {
-                               if (declaring_type != null)
-                                       return declaring_type.FullName + "/" + name;
-
-                               if (string.IsNullOrEmpty (@namespace))
-                                       return name;
-
-                               return @namespace + "." + name;
-                       }
-               }
-
-               public ExportedType (string @namespace, string name, ModuleDefinition module, IMetadataScope scope)
-               {
-                       this.@namespace = @namespace;
-                       this.name = name;
-                       this.scope = scope;
-                       this.module = module;
-               }
-
-               public override string ToString ()
-               {
-                       return FullName;
-               }
-
-               public TypeDefinition Resolve ()
-               {
-                       return module.Resolve (CreateReference ());
-               }
-
-               internal TypeReference CreateReference ()
-               {
-                       return new TypeReference (@namespace, name, module, scope) {
-                               DeclaringType = declaring_type != null ? declaring_type.CreateReference () : null,
-                       };
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/FieldAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/FieldAttributes.cs
deleted file mode 100644 (file)
index dd6bf36..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-//
-// FieldAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum FieldAttributes : ushort {
-               FieldAccessMask         = 0x0007,
-               CompilerControlled      = 0x0000,       // Member not referenceable
-               Private                         = 0x0001,       // Accessible only by the parent type
-               FamANDAssem                     = 0x0002,       // Accessible by sub-types only in this assembly
-               Assembly                        = 0x0003,       // Accessible by anyone in the Assembly
-               Family                          = 0x0004,       // Accessible only by type and sub-types
-               FamORAssem                      = 0x0005,       // Accessible by sub-types anywhere, plus anyone in the assembly
-               Public                          = 0x0006,       // Accessible by anyone who has visibility to this scope field contract attributes
-
-               Static                          = 0x0010,       // Defined on type, else per instance
-               InitOnly                        = 0x0020,       // Field may only be initialized, not written after init
-               Literal                         = 0x0040,       // Value is compile time constant
-               NotSerialized           = 0x0080,       // Field does not have to be serialized when type is remoted
-               SpecialName                     = 0x0200,       // Field is special
-
-               // Interop Attributes
-               PInvokeImpl                     = 0x2000,       // Implementation is forwarded through PInvoke
-
-               // Additional flags
-               RTSpecialName           = 0x0400,       // CLI provides 'special' behavior, depending upon the name of the field
-               HasFieldMarshal         = 0x1000,       // Field has marshalling information
-               HasDefault                      = 0x8000,       // Field has default
-               HasFieldRVA                     = 0x0100         // Field has RVA
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/FieldDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/FieldDefinition.cs
deleted file mode 100644 (file)
index 29a1bc1..0000000
+++ /dev/null
@@ -1,279 +0,0 @@
-//
-// FieldDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public sealed class FieldDefinition : FieldReference, IMemberDefinition, IConstantProvider, IMarshalInfoProvider {
-
-               ushort attributes;
-               Collection<CustomAttribute> custom_attributes;
-
-               int offset = Mixin.NotResolvedMarker;
-
-               internal int rva = Mixin.NotResolvedMarker;
-               byte [] initial_value;
-
-               object constant = Mixin.NotResolved;
-
-               MarshalInfo marshal_info;
-
-               void ResolveLayout ()
-               {
-                       if (offset != Mixin.NotResolvedMarker)
-                               return;
-
-                       if (!HasImage) {
-                               offset = Mixin.NoDataMarker;
-                               return;
-                       }
-
-                       offset = Module.Read (this, (field, reader) => reader.ReadFieldLayout (field));
-               }
-
-               public bool HasLayoutInfo {
-                       get {
-                               if (offset >= 0)
-                                       return true;
-
-                               ResolveLayout ();
-
-                               return offset >= 0;
-                       }
-               }
-
-               public int Offset {
-                       get {
-                               if (offset >= 0)
-                                       return offset;
-
-                               ResolveLayout ();
-
-                               return offset >= 0 ? offset : -1;
-                       }
-                       set { offset = value; }
-               }
-
-               void ResolveRVA ()
-               {
-                       if (rva != Mixin.NotResolvedMarker)
-                               return;
-
-                       if (!HasImage)
-                               return;
-
-                       rva = Module.Read (this, (field, reader) => reader.ReadFieldRVA (field));
-               }
-
-               public int RVA {
-                       get {
-                               if (rva > 0)
-                                       return rva;
-
-                               ResolveRVA ();
-
-                               return rva > 0 ? rva : 0;
-                       }
-               }
-
-               public byte [] InitialValue {
-                       get {
-                               if (initial_value != null)
-                                       return initial_value;
-
-                               ResolveRVA ();
-
-                               if (initial_value == null)
-                                       initial_value = Empty<byte>.Array;
-
-                               return initial_value;
-                       }
-                       set { initial_value = value; }
-               }
-
-               public FieldAttributes Attributes {
-                       get { return (FieldAttributes) attributes; }
-                       set { attributes = (ushort) value; }
-               }
-
-               public bool HasConstant {
-                       get {
-                               ResolveConstant ();
-
-                               return constant != Mixin.NoValue;
-                       }
-                       set { if (!value) constant = Mixin.NoValue; }
-               }
-
-               public object Constant {
-                       get { return HasConstant ? constant : null;     }
-                       set { constant = value; }
-               }
-
-               void ResolveConstant ()
-               {
-                       if (constant != Mixin.NotResolved)
-                               return;
-
-                       this.ResolveConstant (ref constant, Module);
-               }
-
-               public bool HasCustomAttributes {
-                       get {
-                               if (custom_attributes != null)
-                                       return custom_attributes.Count > 0;
-
-                               return this.GetHasCustomAttributes (Module);
-                       }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return custom_attributes ?? (custom_attributes = this.GetCustomAttributes (Module)); }
-               }
-
-               public bool HasMarshalInfo {
-                       get {
-                               if (marshal_info != null)
-                                       return true;
-
-                               return this.GetHasMarshalInfo (Module);
-                       }
-               }
-
-               public MarshalInfo MarshalInfo {
-                       get { return marshal_info ?? (marshal_info = this.GetMarshalInfo (Module)); }
-                       set { marshal_info = value; }
-               }
-
-               #region FieldAttributes
-
-               public bool IsCompilerControlled {
-                       get { return attributes.GetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.CompilerControlled); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.CompilerControlled, value); }
-               }
-
-               public bool IsPrivate {
-                       get { return attributes.GetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.Private); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.Private, value); }
-               }
-
-               public bool IsFamilyAndAssembly {
-                       get { return attributes.GetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.FamANDAssem); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.FamANDAssem, value); }
-               }
-
-               public bool IsAssembly {
-                       get { return attributes.GetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.Assembly); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.Assembly, value); }
-               }
-
-               public bool IsFamily {
-                       get { return attributes.GetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.Family); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.Family, value); }
-               }
-
-               public bool IsFamilyOrAssembly {
-                       get { return attributes.GetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.FamORAssem); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.FamORAssem, value); }
-               }
-
-               public bool IsPublic {
-                       get { return attributes.GetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.Public); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) FieldAttributes.FieldAccessMask, (ushort) FieldAttributes.Public, value); }
-               }
-
-               public bool IsStatic {
-                       get { return attributes.GetAttributes ((ushort) FieldAttributes.Static); }
-                       set { attributes = attributes.SetAttributes ((ushort) FieldAttributes.Static, value); }
-               }
-
-               public bool IsInitOnly {
-                       get { return attributes.GetAttributes ((ushort) FieldAttributes.InitOnly); }
-                       set { attributes = attributes.SetAttributes ((ushort) FieldAttributes.InitOnly, value); }
-               }
-
-               public bool IsLiteral {
-                       get { return attributes.GetAttributes ((ushort) FieldAttributes.Literal); }
-                       set { attributes = attributes.SetAttributes ((ushort) FieldAttributes.Literal, value); }
-               }
-
-               public bool IsNotSerialized {
-                       get { return attributes.GetAttributes ((ushort) FieldAttributes.NotSerialized); }
-                       set { attributes = attributes.SetAttributes ((ushort) FieldAttributes.NotSerialized, value); }
-               }
-
-               public bool IsSpecialName {
-                       get { return attributes.GetAttributes ((ushort) FieldAttributes.SpecialName); }
-                       set { attributes = attributes.SetAttributes ((ushort) FieldAttributes.SpecialName, value); }
-               }
-
-               public bool IsPInvokeImpl {
-                       get { return attributes.GetAttributes ((ushort) FieldAttributes.PInvokeImpl); }
-                       set { attributes = attributes.SetAttributes ((ushort) FieldAttributes.PInvokeImpl, value); }
-               }
-
-               public bool IsRuntimeSpecialName {
-                       get { return attributes.GetAttributes ((ushort) FieldAttributes.RTSpecialName); }
-                       set { attributes = attributes.SetAttributes ((ushort) FieldAttributes.RTSpecialName, value); }
-               }
-
-               public bool HasDefault {
-                       get { return attributes.GetAttributes ((ushort) FieldAttributes.HasDefault); }
-                       set { attributes = attributes.SetAttributes ((ushort) FieldAttributes.HasDefault, value); }
-               }
-
-               #endregion
-
-               public override bool IsDefinition {
-                       get { return true; }
-               }
-
-               public new TypeDefinition DeclaringType {
-                       get { return (TypeDefinition) base.DeclaringType; }
-                       set { base.DeclaringType = value; }
-               }
-
-               public FieldDefinition (string name, FieldAttributes attributes, TypeReference fieldType)
-                       : base (name, fieldType)
-               {
-                       this.attributes = (ushort) attributes;
-               }
-
-               public override FieldDefinition Resolve ()
-               {
-                       return this;
-               }
-       }
-
-       static partial class Mixin {
-
-               public const int NotResolvedMarker = -2;
-               public const int NoDataMarker = -1;
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/FieldReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil/FieldReference.cs
deleted file mode 100644 (file)
index be58d3d..0000000
+++ /dev/null
@@ -1,83 +0,0 @@
-//
-// FieldReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       public class FieldReference : MemberReference {
-
-               TypeReference field_type;
-
-               public TypeReference FieldType {
-                       get { return field_type; }
-                       set { field_type = value; }
-               }
-
-               public override string FullName {
-                       get { return field_type.FullName + " " + MemberFullName (); }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get { return field_type.ContainsGenericParameter || base.ContainsGenericParameter; }
-               }
-
-               internal FieldReference ()
-               {
-                       this.token = new MetadataToken (TokenType.MemberRef);
-               }
-
-               public FieldReference (string name, TypeReference fieldType)
-                       : base (name)
-               {
-                       if (fieldType == null)
-                               throw new ArgumentNullException ("fieldType");
-
-                       this.field_type = fieldType;
-                       this.token = new MetadataToken (TokenType.MemberRef);
-               }
-
-               public FieldReference (string name, TypeReference fieldType, TypeReference declaringType)
-                       : this (name, fieldType)
-               {
-                       if (declaringType == null)
-                               throw new ArgumentNullException("declaringType");
-
-                       this.DeclaringType = declaringType;
-               }
-
-               public virtual FieldDefinition Resolve ()
-               {
-                       var module = this.Module;
-                       if (module == null)
-                               throw new NotSupportedException ();
-
-                       return module.Resolve (this);
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/FileAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/FileAttributes.cs
deleted file mode 100644 (file)
index 4d3b6ca..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-//
-// FileAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       enum FileAttributes : uint {
-               ContainsMetaData        = 0x0000,       // This is not a resource file
-               ContainsNoMetaData  = 0x0001,   // This is a resource file or other non-metadata-containing file
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/FunctionPointerType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/FunctionPointerType.cs
deleted file mode 100644 (file)
index db80f76..0000000
+++ /dev/null
@@ -1,128 +0,0 @@
-//
-// FunctionPointerType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Text;
-using Mono.Collections.Generic;
-using MD = Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public sealed class FunctionPointerType : TypeSpecification, IMethodSignature {
-
-               readonly MethodReference function;
-
-               public bool HasThis {
-                       get { return function.HasThis; }
-                       set { function.HasThis = value; }
-               }
-
-               public bool ExplicitThis {
-                       get { return function.ExplicitThis; }
-                       set { function.ExplicitThis = value; }
-               }
-
-               public MethodCallingConvention CallingConvention {
-                       get { return function.CallingConvention; }
-                       set { function.CallingConvention = value; }
-               }
-
-               public bool HasParameters {
-                       get { return function.HasParameters; }
-               }
-
-               public Collection<ParameterDefinition> Parameters {
-                       get { return function.Parameters; }
-               }
-
-               public TypeReference ReturnType {
-                       get { return function.MethodReturnType.ReturnType; }
-                       set { function.MethodReturnType.ReturnType = value; }
-               }
-
-               public MethodReturnType MethodReturnType {
-                       get { return function.MethodReturnType; }
-               }
-
-               public override string Name {
-                       get { return function.Name; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override string Namespace {
-                       get { return string.Empty; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override ModuleDefinition Module {
-                       get { return ReturnType.Module; }
-               }
-
-               public override IMetadataScope Scope {
-                       get { return function.ReturnType.Scope; }
-               }
-
-               public override bool IsFunctionPointer {
-                       get { return true; }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get { return function.ContainsGenericParameter; }
-               }
-
-               public override string FullName {
-                       get {
-                               var signature = new StringBuilder ();
-                               signature.Append (function.Name);
-                               signature.Append (" ");
-                               signature.Append (function.ReturnType.FullName);
-                               signature.Append (" *");
-                               this.MethodSignatureFullName (signature);
-                               return signature.ToString ();
-                       }
-               }
-
-               public FunctionPointerType ()
-                       : base (null)
-               {
-                       this.function = new MethodReference ();
-                       this.function.Name = "method";
-                       this.etype = MD.ElementType.FnPtr;
-               }
-
-               public override TypeDefinition Resolve ()
-               {
-                       return null;
-               }
-
-               public override TypeReference GetElementType ()
-               {
-                       return this;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/GenericInstanceMethod.cs b/mcs/class/Mono.Cecil/Mono.Cecil/GenericInstanceMethod.cs
deleted file mode 100644 (file)
index dbe720d..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-//
-// GenericInstanceMethod.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Text;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public sealed class GenericInstanceMethod : MethodSpecification, IGenericInstance, IGenericContext {
-
-               Collection<TypeReference> arguments;
-
-               public bool HasGenericArguments {
-                       get { return !arguments.IsNullOrEmpty (); }
-               }
-
-               public Collection<TypeReference> GenericArguments {
-                       get { return arguments ?? (arguments = new Collection<TypeReference> ()); }
-               }
-
-               public override bool IsGenericInstance {
-                       get { return true; }
-               }
-
-               IGenericParameterProvider IGenericContext.Method {
-                       get { return ElementMethod; }
-               }
-
-               IGenericParameterProvider IGenericContext.Type {
-                       get { return ElementMethod.DeclaringType; }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get { return this.ContainsGenericParameter () || base.ContainsGenericParameter; }
-               }
-
-               public override string FullName {
-                       get {
-                               var signature = new StringBuilder ();
-                               var method = this.ElementMethod;
-                               signature.Append (method.ReturnType.FullName)
-                                       .Append (" ")
-                                       .Append (method.DeclaringType.FullName)
-                                       .Append ("::")
-                                       .Append (method.Name);
-                               this.GenericInstanceFullName (signature);
-                               this.MethodSignatureFullName (signature);
-                               return signature.ToString ();
-
-                       }
-               }
-
-               public GenericInstanceMethod (MethodReference method)
-                       : base (method)
-               {
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/GenericInstanceType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/GenericInstanceType.cs
deleted file mode 100644 (file)
index 6554ff0..0000000
+++ /dev/null
@@ -1,83 +0,0 @@
-//
-// GenericInstanceType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Text;
-
-using Mono.Collections.Generic;
-
-using MD = Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public sealed class GenericInstanceType : TypeSpecification, IGenericInstance, IGenericContext {
-
-               Collection<TypeReference> arguments;
-
-               public bool HasGenericArguments {
-                       get { return !arguments.IsNullOrEmpty (); }
-               }
-
-               public Collection<TypeReference> GenericArguments {
-                       get { return arguments ?? (arguments = new Collection<TypeReference> ()); }
-               }
-
-               public override TypeReference DeclaringType {
-                       get { return ElementType.DeclaringType; }
-                       set { throw new NotSupportedException (); }
-               }
-
-               public override string FullName {
-                       get {
-                               var name = new StringBuilder ();
-                               name.Append (base.FullName);
-                               this.GenericInstanceFullName (name);
-                               return name.ToString ();
-                       }
-               }
-
-               public override bool IsGenericInstance {
-                       get { return true; }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get { return this.ContainsGenericParameter () || base.ContainsGenericParameter; }
-               }
-
-               IGenericParameterProvider IGenericContext.Type {
-                       get { return ElementType; }
-               }
-
-               public GenericInstanceType (TypeReference type)
-                       : base (type)
-               {
-                       base.IsValueType = type.IsValueType;
-                       this.etype = MD.ElementType.GenericInst;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/GenericParameter.cs b/mcs/class/Mono.Cecil/Mono.Cecil/GenericParameter.cs
deleted file mode 100644 (file)
index d694e29..0000000
+++ /dev/null
@@ -1,277 +0,0 @@
-//
-// GenericParameter.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-using Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public sealed class GenericParameter : TypeReference, ICustomAttributeProvider {
-
-               internal int position;
-               internal GenericParameterType type;
-               internal IGenericParameterProvider owner;
-
-               ushort attributes;
-               Collection<TypeReference> constraints;
-               Collection<CustomAttribute> custom_attributes;
-
-               public GenericParameterAttributes Attributes {
-                       get { return (GenericParameterAttributes) attributes; }
-                       set { attributes = (ushort) value; }
-               }
-
-               public int Position {
-                       get { return position; }
-               }
-
-               public GenericParameterType Type {
-                       get { return type; }
-               }
-
-               public IGenericParameterProvider Owner {
-                       get { return owner; }
-               }
-
-               public bool HasConstraints {
-                       get {
-                               if (constraints != null)
-                                       return constraints.Count > 0;
-
-                               if (HasImage)
-                                       return Module.Read (this, (generic_parameter, reader) => reader.HasGenericConstraints (generic_parameter));
-
-                               return false;
-                       }
-               }
-
-               public Collection<TypeReference> Constraints {
-                       get {
-                               if (constraints != null)
-                                       return constraints;
-
-                               if (HasImage)
-                                       return constraints = Module.Read (this, (generic_parameter, reader) => reader.ReadGenericConstraints (generic_parameter));
-
-                               return constraints = new Collection<TypeReference> ();
-                       }
-               }
-
-               public bool HasCustomAttributes {
-                       get {
-                               if (custom_attributes != null)
-                                       return custom_attributes.Count > 0;
-
-                               return this.GetHasCustomAttributes (Module);
-                       }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return custom_attributes ?? (custom_attributes = this.GetCustomAttributes (Module)); }
-               }
-
-               public override IMetadataScope Scope {
-                       get {
-                               if (owner == null)
-                                       return null;
-
-                               return owner.GenericParameterType == GenericParameterType.Method
-                                       ? ((MethodReference) owner).DeclaringType.Scope
-                                       : ((TypeReference) owner).Scope;
-                       }
-               }
-
-               public override ModuleDefinition Module {
-                       get { return module ?? owner.Module; }
-               }
-
-               public override string Name {
-                       get {
-                               if (!string.IsNullOrEmpty (base.Name))
-                                       return base.Name;
-
-                               return base.Name = (type == GenericParameterType.Method ? "!!" : "!") + position;
-                       }
-               }
-
-               public override string Namespace {
-                       get { return string.Empty; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override string FullName {
-                       get { return Name; }
-               }
-
-               public override bool IsGenericParameter {
-                       get { return true; }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get { return true; }
-               }
-
-               public override MetadataType MetadataType {
-                       get { return (MetadataType) etype; }
-               }
-
-               #region GenericParameterAttributes
-
-               public bool IsNonVariant {
-                       get { return attributes.GetMaskedAttributes ((ushort) GenericParameterAttributes.VarianceMask, (ushort) GenericParameterAttributes.NonVariant); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) GenericParameterAttributes.VarianceMask, (ushort) GenericParameterAttributes.NonVariant, value); }
-               }
-
-               public bool IsCovariant {
-                       get { return attributes.GetMaskedAttributes ((ushort) GenericParameterAttributes.VarianceMask, (ushort) GenericParameterAttributes.Covariant); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) GenericParameterAttributes.VarianceMask, (ushort) GenericParameterAttributes.Covariant, value); }
-               }
-
-               public bool IsContravariant {
-                       get { return attributes.GetMaskedAttributes ((ushort) GenericParameterAttributes.VarianceMask, (ushort) GenericParameterAttributes.Contravariant); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) GenericParameterAttributes.VarianceMask, (ushort) GenericParameterAttributes.Contravariant, value); }
-               }
-
-               public bool HasReferenceTypeConstraint {
-                       get { return attributes.GetAttributes ((ushort) GenericParameterAttributes.ReferenceTypeConstraint); }
-                       set { attributes = attributes.SetAttributes ((ushort) GenericParameterAttributes.ReferenceTypeConstraint, value); }
-               }
-
-               public bool HasNotNullableValueTypeConstraint {
-                       get { return attributes.GetAttributes ((ushort) GenericParameterAttributes.NotNullableValueTypeConstraint); }
-                       set { attributes = attributes.SetAttributes ((ushort) GenericParameterAttributes.NotNullableValueTypeConstraint, value); }
-               }
-
-               public bool HasDefaultConstructorConstraint {
-                       get { return attributes.GetAttributes ((ushort) GenericParameterAttributes.DefaultConstructorConstraint); }
-                       set { attributes = attributes.SetAttributes ((ushort) GenericParameterAttributes.DefaultConstructorConstraint, value); }
-               }
-
-               #endregion
-
-               public GenericParameter (IGenericParameterProvider owner)
-                       : this (string.Empty, owner)
-               {
-               }
-
-               public GenericParameter (string name, IGenericParameterProvider owner)
-                       : base (string.Empty, name)
-               {
-                       if (owner == null)
-                               throw new ArgumentNullException ();
-
-                       this.position = -1;
-                       this.owner = owner;
-                       this.type = owner.GenericParameterType;
-                       this.etype = ConvertGenericParameterType (this.type);
-               }
-
-               public GenericParameter (int position, GenericParameterType type, ModuleDefinition module)
-                       : base (string.Empty, string.Empty)
-               {
-                       if (module == null)
-                               throw new ArgumentNullException ();
-
-                       this.position = position;
-                       this.type = type;
-                       this.etype = ConvertGenericParameterType (type);
-                       this.module = module;
-               }
-
-               static ElementType ConvertGenericParameterType (GenericParameterType type)
-               {
-                       switch (type) {
-                       case GenericParameterType.Type:
-                               return ElementType.Var;
-                       case GenericParameterType.Method:
-                               return ElementType.MVar;
-                       }
-
-                       throw new ArgumentOutOfRangeException ();
-               }
-
-               public override TypeDefinition Resolve ()
-               {
-                       return null;
-               }
-       }
-
-       sealed class GenericParameterCollection : Collection<GenericParameter> {
-
-               readonly IGenericParameterProvider owner;
-
-               internal GenericParameterCollection (IGenericParameterProvider owner)
-               {
-                       this.owner = owner;
-               }
-
-               internal GenericParameterCollection (IGenericParameterProvider owner, int capacity)
-                       : base (capacity)
-               {
-                       this.owner = owner;
-               }
-
-               protected override void OnAdd (GenericParameter item, int index)
-               {
-                       UpdateGenericParameter (item, index);
-               }
-
-               protected override void OnInsert (GenericParameter item, int index)
-               {
-                       UpdateGenericParameter (item, index);
-
-                       for (int i = index; i < size; i++)
-                               items[i].position = i + 1;
-               }
-
-               protected override void OnSet (GenericParameter item, int index)
-               {
-                       UpdateGenericParameter (item, index);
-               }
-
-               void UpdateGenericParameter (GenericParameter item, int index)
-               {
-                       item.owner = owner;
-                       item.position = index;
-                       item.type = owner.GenericParameterType;
-               }
-
-               protected override void OnRemove (GenericParameter item, int index)
-               {
-                       item.owner = null;
-                       item.position = -1;
-                       item.type = GenericParameterType.Type;
-
-                       for (int i = index + 1; i < size; i++)
-                               items[i].position = i - 1;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/GenericParameterAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/GenericParameterAttributes.cs
deleted file mode 100644 (file)
index 6d77956..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-//
-// GenericParameterAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum GenericParameterAttributes : ushort {
-               VarianceMask    = 0x0003,
-               NonVariant              = 0x0000,
-               Covariant               = 0x0001,
-               Contravariant   = 0x0002,
-
-               SpecialConstraintMask                   = 0x001c,
-               ReferenceTypeConstraint                 = 0x0004,
-               NotNullableValueTypeConstraint  = 0x0008,
-               DefaultConstructorConstraint    = 0x0010
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/IConstantProvider.cs b/mcs/class/Mono.Cecil/Mono.Cecil/IConstantProvider.cs
deleted file mode 100644 (file)
index 8bcd7d7..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-//
-// IConstantProvider.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public interface IConstantProvider : IMetadataTokenProvider {
-
-               bool HasConstant { get; set; }
-               object Constant { get; set; }
-       }
-
-       static partial class Mixin {
-
-               internal static object NoValue = new object ();
-               internal static object NotResolved = new object ();
-
-               public static void ResolveConstant (
-                       this IConstantProvider self,
-                       ref object constant,
-                       ModuleDefinition module)
-               {
-                       constant = module.HasImage ()
-                               ? module.Read (self, (provider, reader) => reader.ReadConstant (provider))
-                               : Mixin.NoValue;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ICustomAttributeProvider.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ICustomAttributeProvider.cs
deleted file mode 100644 (file)
index 916ba0f..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-//
-// ICustomAttributeProvider.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public interface ICustomAttributeProvider : IMetadataTokenProvider {
-
-               Collection<CustomAttribute> CustomAttributes { get; }
-
-               bool HasCustomAttributes { get; }
-       }
-
-       static partial class Mixin {
-
-               public static bool GetHasCustomAttributes (
-                       this ICustomAttributeProvider self,
-                       ModuleDefinition module)
-               {
-                       return module.HasImage () && module.Read (self, (provider, reader) => reader.HasCustomAttributes (provider));
-               }
-
-               public static Collection<CustomAttribute> GetCustomAttributes (
-                       this ICustomAttributeProvider self,
-                       ModuleDefinition module)
-               {
-                       return module.HasImage ()
-                               ? module.Read (self, (provider, reader) => reader.ReadCustomAttributes (provider))
-                               : new Collection<CustomAttribute> ();
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/IGenericInstance.cs b/mcs/class/Mono.Cecil/Mono.Cecil/IGenericInstance.cs
deleted file mode 100644 (file)
index edc406c..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-//
-// IGenericInstance.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System.Text;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public interface IGenericInstance : IMetadataTokenProvider {
-
-               bool HasGenericArguments { get; }
-               Collection<TypeReference> GenericArguments { get; }
-       }
-
-       static partial class Mixin {
-
-               public static bool ContainsGenericParameter (this IGenericInstance self)
-               {
-                       var arguments = self.GenericArguments;
-
-                       for (int i = 0; i < arguments.Count; i++)
-                               if (arguments [i].ContainsGenericParameter)
-                                       return true;
-
-                       return false;
-               }
-
-               public static void GenericInstanceFullName (this IGenericInstance self, StringBuilder builder)
-               {
-                       builder.Append ("<");
-                       var arguments = self.GenericArguments;
-                       for (int i = 0; i < arguments.Count; i++) {
-                               if (i > 0)
-                                       builder.Append (",");
-                               builder.Append (arguments [i].FullName);
-                       }
-                       builder.Append (">");
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/IGenericParameterProvider.cs b/mcs/class/Mono.Cecil/Mono.Cecil/IGenericParameterProvider.cs
deleted file mode 100644 (file)
index d41b7f6..0000000
+++ /dev/null
@@ -1,73 +0,0 @@
-//
-// IGenericParameterProvider.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public interface IGenericParameterProvider : IMetadataTokenProvider {
-
-               bool HasGenericParameters { get; }
-               bool IsDefinition { get; }
-               ModuleDefinition Module { get; }
-               Collection<GenericParameter> GenericParameters { get; }
-               GenericParameterType GenericParameterType { get; }
-       }
-
-       public enum GenericParameterType {
-               Type,
-               Method
-       }
-
-       interface IGenericContext {
-
-               bool IsDefinition { get; }
-               IGenericParameterProvider Type { get; }
-               IGenericParameterProvider Method { get; }
-       }
-
-       static partial class Mixin {
-
-               public static bool GetHasGenericParameters (
-                       this IGenericParameterProvider self,
-                       ModuleDefinition module)
-               {
-                       return module.HasImage () && module.Read (self, (provider, reader) => reader.HasGenericParameters (provider));
-               }
-
-               public static Collection<GenericParameter> GetGenericParameters (
-                       this IGenericParameterProvider self,
-                       ModuleDefinition module)
-               {
-                       return module.HasImage ()
-                               ? module.Read (self, (provider, reader) => reader.ReadGenericParameters (provider))
-                               : new GenericParameterCollection (self);
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/IMarshalInfoProvider.cs b/mcs/class/Mono.Cecil/Mono.Cecil/IMarshalInfoProvider.cs
deleted file mode 100644 (file)
index 67a53a3..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-//
-// IMarshalInfoProvider.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public interface IMarshalInfoProvider : IMetadataTokenProvider {
-
-               bool HasMarshalInfo { get; }
-               MarshalInfo MarshalInfo { get; set; }
-       }
-
-       static partial class Mixin {
-
-               public static bool GetHasMarshalInfo (
-                       this IMarshalInfoProvider self,
-                       ModuleDefinition module)
-               {
-                       return module.HasImage () && module.Read (self, (provider, reader) => reader.HasMarshalInfo (provider));
-               }
-
-               public static MarshalInfo GetMarshalInfo (
-                       this IMarshalInfoProvider self,
-                       ModuleDefinition module)
-               {
-                       return module.HasImage ()
-                               ? module.Read (self, (provider, reader) => reader.ReadMarshalInfo (provider))
-                               : null;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/IMemberDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/IMemberDefinition.cs
deleted file mode 100644 (file)
index ee73d9d..0000000
+++ /dev/null
@@ -1,100 +0,0 @@
-//
-// IMemberDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public interface IMemberDefinition : ICustomAttributeProvider {
-
-               string Name { get; set; }
-               string FullName { get; }
-
-               bool IsSpecialName { get; set; }
-               bool IsRuntimeSpecialName { get; set; }
-
-               TypeDefinition DeclaringType { get; set; }
-       }
-
-       static partial class Mixin {
-
-               public static bool GetAttributes (this uint self, uint attributes)
-               {
-                       return (self & attributes) != 0;
-               }
-
-               public static uint SetAttributes (this uint self, uint attributes, bool value)
-               {
-                       if (value)
-                               return self | attributes;
-
-                       return self & ~attributes;
-               }
-
-               public static bool GetMaskedAttributes (this uint self, uint mask, uint attributes)
-               {
-                       return (self & mask) == attributes;
-               }
-
-               public static uint SetMaskedAttributes (this uint self, uint mask, uint attributes, bool value)
-               {
-                       if (value) {
-                               self &= ~mask;
-                               return self | attributes;
-                       }
-
-                       return self & ~(mask & attributes);
-               }
-
-               public static bool GetAttributes (this ushort self, ushort attributes)
-               {
-                       return (self & attributes) != 0;
-               }
-
-               public static ushort SetAttributes (this ushort self, ushort attributes, bool value)
-               {
-                       if (value)
-                               return (ushort) (self | attributes);
-
-                       return (ushort) (self & ~attributes);
-               }
-
-               public static bool GetMaskedAttributes (this ushort self, ushort mask, uint attributes)
-               {
-                       return (self & mask) == attributes;
-               }
-
-               public static ushort SetMaskedAttributes (this ushort self, ushort mask, uint attributes, bool value)
-               {
-                       if (value) {
-                               self = (ushort) (self & ~mask);
-                               return (ushort) (self | attributes);
-                       }
-
-                       return (ushort) (self & ~(mask & attributes));
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/IMetadataScope.cs b/mcs/class/Mono.Cecil/Mono.Cecil/IMetadataScope.cs
deleted file mode 100644 (file)
index 04a0228..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-//
-// IMetadataScope.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public enum MetadataScopeType {
-               AssemblyNameReference,
-               ModuleReference,
-               ModuleDefinition,
-       }
-
-       public interface IMetadataScope : IMetadataTokenProvider {
-               MetadataScopeType MetadataScopeType { get; }
-               string Name { get; set; }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/IMetadataTokenProvider.cs b/mcs/class/Mono.Cecil/Mono.Cecil/IMetadataTokenProvider.cs
deleted file mode 100644 (file)
index 6621835..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-//
-// IMetadataTokenProvider.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public interface IMetadataTokenProvider {
-
-               MetadataToken MetadataToken { get; set; }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/IMethodSignature.cs b/mcs/class/Mono.Cecil/Mono.Cecil/IMethodSignature.cs
deleted file mode 100644 (file)
index 491deec..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-//
-// IMethodSignature.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System.Text;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public interface IMethodSignature : IMetadataTokenProvider {
-
-               bool HasThis { get; set; }
-               bool ExplicitThis { get; set; }
-               MethodCallingConvention CallingConvention { get; set; }
-
-               bool HasParameters { get; }
-               Collection<ParameterDefinition> Parameters { get; }
-               TypeReference ReturnType { get; set; }
-               MethodReturnType MethodReturnType { get; }
-       }
-
-       static partial class Mixin {
-
-               public static void MethodSignatureFullName (this IMethodSignature self, StringBuilder builder)
-               {
-                       builder.Append ("(");
-
-                       if (self.HasParameters) {
-                               var parameters = self.Parameters;
-                               for (int i = 0; i < parameters.Count; i++) {
-                                       var parameter = parameters [i];
-                                       if (i > 0)
-                                               builder.Append (",");
-
-                                       if (parameter.ParameterType.IsSentinel)
-                                               builder.Append ("...,");
-
-                                       builder.Append (parameter.ParameterType.FullName);
-                               }
-                       }
-
-                       builder.Append (")");
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/Import.cs b/mcs/class/Mono.Cecil/Mono.Cecil/Import.cs
deleted file mode 100644 (file)
index 2a8293c..0000000
+++ /dev/null
@@ -1,566 +0,0 @@
-//
-// Import.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-using SR = System.Reflection;
-
-using Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       enum ImportGenericKind {
-               Definition,
-               Open,
-       }
-
-       class MetadataImporter {
-
-               readonly ModuleDefinition module;
-
-               public MetadataImporter (ModuleDefinition module)
-               {
-                       this.module = module;
-               }
-
-#if !CF
-               static readonly Dictionary<Type, ElementType> type_etype_mapping = new Dictionary<Type, ElementType> (18) {
-                       { typeof (void), ElementType.Void },
-                       { typeof (bool), ElementType.Boolean },
-                       { typeof (char), ElementType.Char },
-                       { typeof (sbyte), ElementType.I1 },
-                       { typeof (byte), ElementType.U1 },
-                       { typeof (short), ElementType.I2 },
-                       { typeof (ushort), ElementType.U2 },
-                       { typeof (int), ElementType.I4 },
-                       { typeof (uint), ElementType.U4 },
-                       { typeof (long), ElementType.I8 },
-                       { typeof (ulong), ElementType.U8 },
-                       { typeof (float), ElementType.R4 },
-                       { typeof (double), ElementType.R8 },
-                       { typeof (string), ElementType.String },
-                       { typeof (TypedReference), ElementType.TypedByRef },
-                       { typeof (IntPtr), ElementType.I },
-                       { typeof (UIntPtr), ElementType.U },
-                       { typeof (object), ElementType.Object },
-               };
-
-               public TypeReference ImportType (Type type, IGenericContext context)
-               {
-                       return ImportType (type, context, ImportGenericKind.Open);
-               }
-
-               public TypeReference ImportType (Type type, IGenericContext context, ImportGenericKind import_kind)
-               {
-                       if (IsTypeSpecification (type) || ImportOpenGenericType (type, import_kind))
-                               return ImportTypeSpecification (type, context);
-
-                       var reference = new TypeReference (
-                               string.Empty,
-                               type.Name,
-                               module,
-                               ImportScope (type.Assembly),
-                               type.IsValueType);
-
-                       reference.etype = ImportElementType (type);
-
-                       if (IsNestedType (type))
-                               reference.DeclaringType = ImportType (type.DeclaringType, context, import_kind);
-                       else
-                               reference.Namespace = type.Namespace;
-
-                       if (type.IsGenericType)
-                               ImportGenericParameters (reference, type.GetGenericArguments ());
-
-                       return reference;
-               }
-
-               static bool ImportOpenGenericType (Type type, ImportGenericKind import_kind)
-               {
-                       return type.IsGenericType && type.IsGenericTypeDefinition && import_kind == ImportGenericKind.Open;
-               }
-
-               static bool ImportOpenGenericMethod (SR.MethodBase method, ImportGenericKind import_kind)
-               {
-                       return method.IsGenericMethod && method.IsGenericMethodDefinition && import_kind == ImportGenericKind.Open;
-               }
-
-               static bool IsNestedType (Type type)
-               {
-#if !SILVERLIGHT
-                       return type.IsNested;
-#else
-                       return type.DeclaringType != null;
-#endif
-               }
-
-               TypeReference ImportTypeSpecification (Type type, IGenericContext context)
-               {
-                       if (type.IsByRef)
-                               return new ByReferenceType (ImportType (type.GetElementType (), context));
-
-                       if (type.IsPointer)
-                               return new PointerType (ImportType (type.GetElementType (), context));
-
-                       if (type.IsArray)
-                               return new ArrayType (ImportType (type.GetElementType (), context), type.GetArrayRank ());
-
-                       if (type.IsGenericType)
-                               return ImportGenericInstance (type, context);
-
-                       if (type.IsGenericParameter)
-                               return ImportGenericParameter (type, context);
-
-                       throw new NotSupportedException (type.FullName);
-               }
-
-               static TypeReference ImportGenericParameter (Type type, IGenericContext context)
-               {
-                       if (context == null)
-                               throw new InvalidOperationException ();
-
-                       var owner = type.DeclaringMethod != null
-                               ? context.Method
-                               : context.Type;
-
-                       if (owner == null)
-                               throw new InvalidOperationException ();
-
-                       return owner.GenericParameters [type.GenericParameterPosition];
-               }
-
-               TypeReference ImportGenericInstance (Type type, IGenericContext context)
-               {
-                       var element_type = ImportType (type.GetGenericTypeDefinition (), context, ImportGenericKind.Definition);
-                       var instance = new GenericInstanceType (element_type);
-                       var arguments = type.GetGenericArguments ();
-                       var instance_arguments = instance.GenericArguments;
-
-                       for (int i = 0; i < arguments.Length; i++)
-                               instance_arguments.Add (ImportType (arguments [i], context ?? element_type));
-
-                       return instance;
-               }
-
-               static bool IsTypeSpecification (Type type)
-               {
-                       return type.HasElementType
-                               || IsGenericInstance (type)
-                               || type.IsGenericParameter;
-               }
-
-               static bool IsGenericInstance (Type type)
-               {
-                       return type.IsGenericType && !type.IsGenericTypeDefinition;
-               }
-
-               static ElementType ImportElementType (Type type)
-               {
-                       ElementType etype;
-                       if (!type_etype_mapping.TryGetValue (type, out etype))
-                               return ElementType.None;
-
-                       return etype;
-               }
-
-               AssemblyNameReference ImportScope (SR.Assembly assembly)
-               {
-                       AssemblyNameReference scope;
-#if !SILVERLIGHT
-                       var name = assembly.GetName ();
-
-                       if (TryGetAssemblyNameReference (name, out scope))
-                               return scope;
-
-                       scope = new AssemblyNameReference (name.Name, name.Version) {
-                               Culture = name.CultureInfo.Name,
-                               PublicKeyToken = name.GetPublicKeyToken (),
-                               HashAlgorithm = (AssemblyHashAlgorithm) name.HashAlgorithm,
-                       };
-
-                       module.AssemblyReferences.Add (scope);
-
-                       return scope;
-#else
-                       var name = AssemblyNameReference.Parse (assembly.FullName);
-
-                       if (TryGetAssemblyNameReference (name, out scope))
-                               return scope;
-
-                       module.AssemblyReferences.Add (name);
-
-                       return name;
-#endif
-               }
-
-#if !SILVERLIGHT
-               bool TryGetAssemblyNameReference (SR.AssemblyName name, out AssemblyNameReference assembly_reference)
-               {
-                       var references = module.AssemblyReferences;
-
-                       for (int i = 0; i < references.Count; i++) {
-                               var reference = references [i];
-                               if (name.FullName != reference.FullName) // TODO compare field by field
-                                       continue;
-
-                               assembly_reference = reference;
-                               return true;
-                       }
-
-                       assembly_reference = null;
-                       return false;
-               }
-#endif
-
-               public FieldReference ImportField (SR.FieldInfo field, IGenericContext context)
-               {
-                       var declaring_type = ImportType (field.DeclaringType, context);
-
-                       if (IsGenericInstance (field.DeclaringType))
-                               field = ResolveFieldDefinition (field);
-
-                       return new FieldReference {
-                               Name = field.Name,
-                               DeclaringType = declaring_type,
-                               FieldType = ImportType (field.FieldType, context ?? declaring_type),
-                       };
-               }
-
-               static SR.FieldInfo ResolveFieldDefinition (SR.FieldInfo field)
-               {
-#if !SILVERLIGHT
-                       return field.Module.ResolveField (field.MetadataToken);
-#else
-                       return field.DeclaringType.GetGenericTypeDefinition ().GetField (field.Name,
-                               SR.BindingFlags.Public
-                               | SR.BindingFlags.NonPublic
-                               | (field.IsStatic ? SR.BindingFlags.Static : SR.BindingFlags.Instance));
-#endif
-               }
-
-               public MethodReference ImportMethod (SR.MethodBase method, IGenericContext context, ImportGenericKind import_kind)
-               {
-                       if (IsMethodSpecification (method) || ImportOpenGenericMethod (method, import_kind))
-                               return ImportMethodSpecification (method, context);
-
-                       var declaring_type = ImportType (method.DeclaringType, context);
-
-                       if (IsGenericInstance (method.DeclaringType))
-                               method = method.Module.ResolveMethod (method.MetadataToken);
-
-                       var reference = new MethodReference {
-                               Name = method.Name,
-                               HasThis = HasCallingConvention (method, SR.CallingConventions.HasThis),
-                               ExplicitThis = HasCallingConvention (method, SR.CallingConventions.ExplicitThis),
-                               DeclaringType = ImportType (method.DeclaringType, context, ImportGenericKind.Definition),
-                       };
-
-                       if (HasCallingConvention (method, SR.CallingConventions.VarArgs))
-                               reference.CallingConvention &= MethodCallingConvention.VarArg;
-
-                       if (method.IsGenericMethod)
-                               ImportGenericParameters (reference, method.GetGenericArguments ());
-
-                       var method_info = method as SR.MethodInfo;
-                       reference.ReturnType = method_info != null
-                               ? ImportType (method_info.ReturnType, context ?? reference)
-                               : ImportType (typeof (void), null);
-
-                       var parameters = method.GetParameters ();
-                       var reference_parameters = reference.Parameters;
-
-                       for (int i = 0; i < parameters.Length; i++)
-                               reference_parameters.Add (
-                                       new ParameterDefinition (ImportType (parameters [i].ParameterType, context ?? reference)));
-
-                       reference.DeclaringType = declaring_type;
-
-                       return reference;
-               }
-
-               static void ImportGenericParameters (IGenericParameterProvider provider, Type [] arguments)
-               {
-                       var provider_parameters = provider.GenericParameters;
-
-                       for (int i = 0; i < arguments.Length; i++)
-                               provider_parameters.Add (new GenericParameter (arguments [i].Name, provider));
-               }
-
-               static bool IsMethodSpecification (SR.MethodBase method)
-               {
-                       return method.IsGenericMethod && !method.IsGenericMethodDefinition;
-               }
-
-               MethodReference ImportMethodSpecification (SR.MethodBase method, IGenericContext context)
-               {
-                       var method_info = method as SR.MethodInfo;
-                       if (method_info == null)
-                               throw new InvalidOperationException ();
-
-                       var element_method = ImportMethod (method_info.GetGenericMethodDefinition (), context, ImportGenericKind.Definition);
-                       var instance = new GenericInstanceMethod (element_method);
-                       var arguments = method.GetGenericArguments ();
-                       var instance_arguments = instance.GenericArguments;
-
-                       for (int i = 0; i < arguments.Length; i++)
-                               instance_arguments.Add (ImportType (arguments [i], context ?? element_method));
-
-                       return instance;
-               }
-
-               static bool HasCallingConvention (SR.MethodBase method, SR.CallingConventions conventions)
-               {
-                       return (method.CallingConvention & conventions) != 0;
-               }
-#endif
-
-               public TypeReference ImportType (TypeReference type, IGenericContext context)
-               {
-                       if (type.IsTypeSpecification ())
-                               return ImportTypeSpecification (type, context);
-
-                       var reference = new TypeReference (
-                               type.Namespace,
-                               type.Name,
-                               module,
-                               ImportScope (type.Scope),
-                               type.IsValueType);
-
-                       MetadataSystem.TryProcessPrimitiveType (reference);
-
-                       if (type.IsNested)
-                               reference.DeclaringType = ImportType (type.DeclaringType, context);
-
-                       if (type.HasGenericParameters)
-                               ImportGenericParameters (reference, type);
-
-                       return reference;
-               }
-
-               IMetadataScope ImportScope (IMetadataScope scope)
-               {
-                       switch (scope.MetadataScopeType) {
-                       case MetadataScopeType.AssemblyNameReference:
-                               return ImportAssemblyName ((AssemblyNameReference) scope);
-                       case MetadataScopeType.ModuleDefinition:
-                               return ImportAssemblyName (((ModuleDefinition) scope).Assembly.Name);
-                       case MetadataScopeType.ModuleReference:
-                               throw new NotImplementedException ();
-                       }
-
-                       throw new NotSupportedException ();
-               }
-
-               AssemblyNameReference ImportAssemblyName (AssemblyNameReference name)
-               {
-                       AssemblyNameReference reference;
-                       if (TryGetAssemblyNameReference (name, out reference))
-                               return reference;
-
-                       reference = new AssemblyNameReference (name.Name, name.Version) {
-                               Culture = name.Culture,
-                               HashAlgorithm = name.HashAlgorithm,
-                       };
-
-                       var pk_token = !name.PublicKeyToken.IsNullOrEmpty ()
-                               ? new byte [name.PublicKeyToken.Length]
-                               : Empty<byte>.Array;
-
-                       if (pk_token.Length > 0)
-                               Buffer.BlockCopy (name.PublicKeyToken, 0, pk_token, 0, pk_token.Length);
-
-                       reference.PublicKeyToken = pk_token;
-
-                       module.AssemblyReferences.Add (reference);
-
-                       return reference;
-               }
-
-               bool TryGetAssemblyNameReference (AssemblyNameReference name_reference, out AssemblyNameReference assembly_reference)
-               {
-                       var references = module.AssemblyReferences;
-
-                       for (int i = 0; i < references.Count; i++) {
-                               var reference = references [i];
-                               if (name_reference.FullName != reference.FullName) // TODO compare field by field
-                                       continue;
-
-                               assembly_reference = reference;
-                               return true;
-                       }
-
-                       assembly_reference = null;
-                       return false;
-               }
-
-               static void ImportGenericParameters (IGenericParameterProvider imported, IGenericParameterProvider original)
-               {
-                       var parameters = original.GenericParameters;
-                       var imported_parameters = imported.GenericParameters;
-
-                       for (int i = 0; i < parameters.Count; i++)
-                               imported_parameters.Add (new GenericParameter (parameters [i].Name, imported));
-               }
-
-               TypeReference ImportTypeSpecification (TypeReference type, IGenericContext context)
-               {
-                       switch (type.etype) {
-                       case ElementType.SzArray:
-                               var vector = (ArrayType) type;
-                               return new ArrayType (ImportType (vector.ElementType, context));
-                       case ElementType.Ptr:
-                               var pointer = (PointerType) type;
-                               return new PointerType (ImportType (pointer.ElementType, context));
-                       case ElementType.ByRef:
-                               var byref = (ByReferenceType) type;
-                               return new ByReferenceType (ImportType (byref.ElementType, context));
-                       case ElementType.Pinned:
-                               var pinned = (PinnedType) type;
-                               return new PinnedType (ImportType (pinned.ElementType, context));
-                       case ElementType.Sentinel:
-                               var sentinel = (SentinelType) type;
-                               return new SentinelType (ImportType (sentinel.ElementType, context));
-                       case ElementType.CModOpt:
-                               var modopt = (OptionalModifierType) type;
-                               return new OptionalModifierType (
-                                       ImportType (modopt.ModifierType, context),
-                                       ImportType (modopt.ElementType, context));
-                       case ElementType.CModReqD:
-                               var modreq = (RequiredModifierType) type;
-                               return new RequiredModifierType (
-                                       ImportType (modreq.ModifierType, context),
-                                       ImportType (modreq.ElementType, context));
-                       case ElementType.Array:
-                               var array = (ArrayType) type;
-                               var imported_array = new ArrayType (ImportType (array.ElementType, context));
-                               if (array.IsVector)
-                                       return imported_array;
-
-                               var dimensions = array.Dimensions;
-                               var imported_dimensions = imported_array.Dimensions;
-
-                               imported_dimensions.Clear ();
-
-                               for (int i = 0; i < dimensions.Count; i++) {
-                                       var dimension = dimensions [i];
-
-                                       imported_dimensions.Add (new ArrayDimension (dimension.LowerBound, dimension.UpperBound));
-                               }
-
-                               return imported_array;
-                       case ElementType.GenericInst:
-                               var instance = (GenericInstanceType) type;
-                               var element_type = ImportType (instance.ElementType, context);
-                               var imported_instance = new GenericInstanceType (element_type);
-
-                               var arguments = instance.GenericArguments;
-                               var imported_arguments = imported_instance.GenericArguments;
-
-                               for (int i = 0; i < arguments.Count; i++)
-                                       imported_arguments.Add (ImportType (arguments [i], context));
-
-                               return imported_instance;
-                       case ElementType.Var:
-                               if (context == null || context.Type == null)
-                                       throw new InvalidOperationException ();
-
-                               return ((TypeReference) context.Type).GetElementType ().GenericParameters [((GenericParameter) type).Position];
-                       case ElementType.MVar:
-                               if (context == null || context.Method == null)
-                                       throw new InvalidOperationException ();
-
-                               return context.Method.GenericParameters [((GenericParameter) type).Position];
-                       }
-
-                       throw new NotSupportedException (type.etype.ToString ());
-               }
-
-               public FieldReference ImportField (FieldReference field, IGenericContext context)
-               {
-                       var declaring_type = ImportType (field.DeclaringType, context);
-
-                       return new FieldReference {
-                               Name = field.Name,
-                               DeclaringType = declaring_type,
-                               FieldType = ImportType (field.FieldType, context ?? declaring_type),
-                       };
-               }
-
-               public MethodReference ImportMethod (MethodReference method, IGenericContext context)
-               {
-                       if (method.IsGenericInstance)
-                               return ImportMethodSpecification (method, context);
-
-                       var declaring_type = ImportType (method.DeclaringType, context);
-
-                       var reference = new MethodReference {
-                               Name = method.Name,
-                               HasThis = method.HasThis,
-                               ExplicitThis = method.ExplicitThis,
-                               DeclaringType = declaring_type,
-                       };
-
-                       reference.CallingConvention = method.CallingConvention;
-
-                       if (method.HasGenericParameters)
-                               ImportGenericParameters (reference, method);
-
-                       reference.ReturnType = ImportType (method.ReturnType, context ?? reference);
-
-                       if (!method.HasParameters)
-                               return reference;
-
-                       var reference_parameters = reference.Parameters;
-
-                       var parameters = method.Parameters;
-                       for (int i = 0; i < parameters.Count; i++)
-                               reference_parameters.Add (
-                                       new ParameterDefinition (ImportType (parameters [i].ParameterType, context ?? reference)));
-
-                       return reference;
-               }
-
-               MethodSpecification ImportMethodSpecification (MethodReference method, IGenericContext context)
-               {
-                       if (!method.IsGenericInstance)
-                               throw new NotSupportedException ();
-
-                       var instance = (GenericInstanceMethod) method;
-                       var element_method = ImportMethod (instance.ElementMethod, context);
-                       var imported_instance = new GenericInstanceMethod (element_method);
-
-                       var arguments = instance.GenericArguments;
-                       var imported_arguments = imported_instance.GenericArguments;
-
-                       for (int i = 0; i < arguments.Count; i++)
-                               imported_arguments.Add (ImportType (arguments [i], context));
-
-                       return imported_instance;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/LinkedResource.cs b/mcs/class/Mono.Cecil/Mono.Cecil/LinkedResource.cs
deleted file mode 100644 (file)
index 16c1d59..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-//
-// LinkedResource.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public sealed class LinkedResource : Resource {
-
-               internal byte [] hash;
-               string file;
-
-               public byte [] Hash {
-                       get { return hash; }
-               }
-
-               public string File {
-                       get { return file; }
-                       set { file = value; }
-               }
-
-               public override ResourceType ResourceType {
-                       get { return ResourceType.Linked; }
-               }
-
-               public LinkedResource (string name, ManifestResourceAttributes flags)
-                       : base (name, flags)
-               {
-               }
-
-               public LinkedResource (string name, ManifestResourceAttributes flags, string file)
-                       : base (name, flags)
-               {
-                       this.file = file;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ManifestResourceAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ManifestResourceAttributes.cs
deleted file mode 100644 (file)
index 7d6bb19..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-//
-// ManifestResourceAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum ManifestResourceAttributes : uint {
-               VisibilityMask  = 0x0007,
-               Public                  = 0x0001,       // The resource is exported from the Assembly
-               Private                 = 0x0002         // The resource is private to the Assembly
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MarshalInfo.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MarshalInfo.cs
deleted file mode 100644 (file)
index 9d58738..0000000
+++ /dev/null
@@ -1,171 +0,0 @@
-//
-// MarshalInfo.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       public class MarshalInfo {
-
-               internal NativeType native;
-
-               public NativeType NativeType {
-                       get { return native; }
-                       set { native = value; }
-               }
-
-               public MarshalInfo (NativeType native)
-               {
-                       this.native = native;
-               }
-       }
-
-       public sealed class ArrayMarshalInfo : MarshalInfo {
-
-               internal NativeType element_type;
-               internal int size_parameter_index;
-               internal int size;
-               internal int size_parameter_multiplier;
-
-               public NativeType ElementType {
-                       get { return element_type; }
-                       set { element_type = value; }
-               }
-
-               public int SizeParameterIndex {
-                       get { return size_parameter_index; }
-                       set { size_parameter_index = value; }
-               }
-
-               public int Size {
-                       get { return size; }
-                       set { size = value; }
-               }
-
-               public int SizeParameterMultiplier {
-                       get { return size_parameter_multiplier; }
-                       set { size_parameter_multiplier = value; }
-               }
-
-               public ArrayMarshalInfo ()
-                       : base (NativeType.Array)
-               {
-                       element_type = NativeType.None;
-                       size_parameter_index = -1;
-                       size = -1;
-                       size_parameter_multiplier = -1;
-               }
-       }
-
-       public sealed class CustomMarshalInfo : MarshalInfo {
-
-               internal Guid guid;
-               internal string unmanaged_type;
-               internal TypeReference managed_type;
-               internal string cookie;
-
-               public Guid Guid {
-                       get { return guid; }
-                       set { guid = value; }
-               }
-
-               public string UnmanagedType {
-                       get { return unmanaged_type; }
-                       set { unmanaged_type = value; }
-               }
-
-               public TypeReference ManagedType {
-                       get { return managed_type; }
-                       set { managed_type = value; }
-               }
-
-               public string Cookie {
-                       get { return cookie; }
-                       set { cookie = value; }
-               }
-
-               public CustomMarshalInfo ()
-                       : base (NativeType.CustomMarshaler)
-               {
-               }
-       }
-
-       public sealed class SafeArrayMarshalInfo : MarshalInfo {
-
-               internal VariantType element_type;
-
-               public VariantType ElementType {
-                       get { return element_type; }
-                       set { element_type = value; }
-               }
-
-               public SafeArrayMarshalInfo ()
-                       : base (NativeType.SafeArray)
-               {
-                       element_type = VariantType.None;
-               }
-       }
-
-       public sealed class FixedArrayMarshalInfo : MarshalInfo {
-
-               internal NativeType element_type;
-               internal int size;
-
-               public NativeType ElementType {
-                       get { return element_type; }
-                       set { element_type = value; }
-               }
-
-               public int Size {
-                       get { return size; }
-                       set { size = value; }
-               }
-
-               public FixedArrayMarshalInfo ()
-                       : base (NativeType.FixedArray)
-               {
-                       element_type = NativeType.None;
-               }
-       }
-
-       public sealed class FixedSysStringMarshalInfo : MarshalInfo {
-
-               internal int size;
-
-               public int Size {
-                       get { return size; }
-                       set { size = value; }
-               }
-
-               public FixedSysStringMarshalInfo ()
-                       : base (NativeType.FixedSysString)
-               {
-                       size = -1;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MemberDefinitionCollection.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MemberDefinitionCollection.cs
deleted file mode 100644 (file)
index 707f36f..0000000
+++ /dev/null
@@ -1,92 +0,0 @@
-//
-// MemberDefinitionCollection.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       class MemberDefinitionCollection<T> : Collection<T> where T : IMemberDefinition {
-
-               TypeDefinition container;
-
-               internal MemberDefinitionCollection (TypeDefinition container)
-               {
-                       this.container = container;
-               }
-
-               internal MemberDefinitionCollection (TypeDefinition container, int capacity)
-                       : base (capacity)
-               {
-                       this.container = container;
-               }
-
-               protected override void OnAdd (T item, int index)
-               {
-                       Attach (item);
-               }
-
-               protected sealed override void OnSet (T item, int index)
-               {
-                       Attach (item);
-               }
-
-               protected sealed override void OnInsert (T item, int index)
-               {
-                       Attach (item);
-               }
-
-               protected sealed override void OnRemove (T item, int index)
-               {
-                       Detach (item);
-               }
-
-               protected sealed override void OnClear ()
-               {
-                       foreach (var definition in this)
-                               Detach (definition);
-               }
-
-               void Attach (T element)
-               {
-                       if (element.DeclaringType == container)
-                               return;
-
-                       if (element.DeclaringType != null)
-                               throw new ArgumentException ("Member already attached");
-
-                       element.DeclaringType = this.container;
-               }
-
-               static void Detach (T element)
-               {
-                       element.DeclaringType = null;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MemberReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MemberReference.cs
deleted file mode 100644 (file)
index b658c51..0000000
+++ /dev/null
@@ -1,101 +0,0 @@
-//
-// MemberReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public abstract class MemberReference : IMetadataTokenProvider {
-
-               string name;
-               TypeReference declaring_type;
-
-               internal MetadataToken token;
-
-               public virtual string Name {
-                       get { return name; }
-                       set { name = value; }
-               }
-
-               public abstract string FullName {
-                       get;
-               }
-
-               public virtual TypeReference DeclaringType {
-                       get { return declaring_type; }
-                       set { declaring_type = value; }
-               }
-
-               public MetadataToken MetadataToken {
-                       get { return token; }
-                       set { token = value; }
-               }
-
-               internal bool HasImage {
-                       get {
-                               var module = Module;
-                               if (module == null)
-                                       return false;
-
-                               return module.HasImage;
-                       }
-               }
-
-               public virtual ModuleDefinition Module {
-                       get { return declaring_type != null ? declaring_type.Module : null; }
-               }
-
-               public virtual bool IsDefinition {
-                       get { return false; }
-               }
-
-               internal virtual bool ContainsGenericParameter {
-                       get { return declaring_type != null && declaring_type.ContainsGenericParameter; }
-               }
-
-               internal MemberReference ()
-               {
-               }
-
-               internal MemberReference (string name)
-               {
-                       this.name = name ?? string.Empty;
-               }
-
-               internal string MemberFullName ()
-               {
-                       if (declaring_type == null)
-                               return name;
-
-                       return declaring_type.FullName + "::" + name;
-               }
-
-               public override string ToString ()
-               {
-                       return FullName;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MetadataResolver.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MetadataResolver.cs
deleted file mode 100644 (file)
index e69fcd7..0000000
+++ /dev/null
@@ -1,364 +0,0 @@
-//
-// MetadataResolver.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public interface IAssemblyResolver {
-               AssemblyDefinition Resolve (AssemblyNameReference name);
-               AssemblyDefinition Resolve (AssemblyNameReference name, ReaderParameters parameters);
-
-               AssemblyDefinition Resolve (string fullName);
-               AssemblyDefinition Resolve (string fullName, ReaderParameters parameters);
-       }
-
-       public interface IMetadataResolver {
-               TypeDefinition Resolve (TypeReference type);
-               FieldDefinition Resolve (FieldReference field);
-               MethodDefinition Resolve (MethodReference method);
-       }
-
-#if !SILVERLIGHT && !CF
-       [Serializable]
-#endif
-       public class ResolutionException : Exception {
-
-               readonly MemberReference member;
-
-               public MemberReference Member {
-                       get { return member; }
-               }
-
-               public ResolutionException (MemberReference member)
-                       : base ("Failed to resolve " + member.FullName)
-               {
-                       this.member = member;
-               }
-
-#if !SILVERLIGHT && !CF
-               protected ResolutionException (
-                       System.Runtime.Serialization.SerializationInfo info,
-                       System.Runtime.Serialization.StreamingContext context)
-                       : base (info, context)
-               {
-               }
-#endif
-       }
-
-       public class MetadataResolver : IMetadataResolver {
-
-               readonly IAssemblyResolver assembly_resolver;
-
-               public IAssemblyResolver AssemblyResolver {
-                       get { return assembly_resolver; }
-               }
-
-               public MetadataResolver (IAssemblyResolver assemblyResolver)
-               {
-                       if (assemblyResolver == null)
-                               throw new ArgumentNullException ("assemblyResolver");
-
-                       assembly_resolver = assemblyResolver;
-               }
-
-               public virtual TypeDefinition Resolve (TypeReference type)
-               {
-                       if (type == null)
-                               throw new ArgumentNullException ("type");
-
-                       type = type.GetElementType ();
-
-                       var scope = type.Scope;
-                       switch (scope.MetadataScopeType) {
-                       case MetadataScopeType.AssemblyNameReference:
-                               var assembly = assembly_resolver.Resolve ((AssemblyNameReference) scope);
-                               if (assembly == null)
-                                       return null;
-
-                               return GetType (assembly.MainModule, type);
-                       case MetadataScopeType.ModuleDefinition:
-                               return GetType ((ModuleDefinition) scope, type);
-                       case MetadataScopeType.ModuleReference:
-                               var modules = type.Module.Assembly.Modules;
-                               var module_ref = (ModuleReference) scope;
-                               for (int i = 0; i < modules.Count; i++) {
-                                       var netmodule = modules [i];
-                                       if (netmodule.Name == module_ref.Name)
-                                               return GetType (netmodule, type);
-                               }
-                               break;
-                       }
-
-                       throw new NotSupportedException ();
-               }
-
-               static TypeDefinition GetType (ModuleDefinition module, TypeReference reference)
-               {
-                       var type = GetTypeDefinition (module, reference);
-                       if (type != null)
-                               return type;
-
-                       if (!module.HasExportedTypes)
-                               return null;
-
-                       var exported_types = module.ExportedTypes;
-
-                       for (int i = 0; i < exported_types.Count; i++) {
-                               var exported_type = exported_types [i];
-                               if (exported_type.Name != reference.Name)
-                                       continue;
-
-                               if (exported_type.Namespace != reference.Namespace)
-                                       continue;
-
-                               return exported_type.Resolve ();
-                       }
-
-                       return null;
-               }
-
-               static TypeDefinition GetTypeDefinition (ModuleDefinition module, TypeReference type)
-               {
-                       if (!type.IsNested)
-                               return module.GetType (type.Namespace, type.Name);
-
-                       var declaring_type = type.DeclaringType.Resolve ();
-                       if (declaring_type == null)
-                               return null;
-
-                       return declaring_type.GetNestedType (type.Name);
-               }
-
-               public virtual FieldDefinition Resolve (FieldReference field)
-               {
-                       if (field == null)
-                               throw new ArgumentNullException ("field");
-
-                       var type = Resolve (field.DeclaringType);
-                       if (type == null)
-                               return null;
-
-                       if (!type.HasFields)
-                               return null;
-
-                       return GetField (type, field);
-               }
-
-               FieldDefinition GetField (TypeDefinition type, FieldReference reference)
-               {
-                       while (type != null) {
-                               var field = GetField (type.Fields, reference);
-                               if (field != null)
-                                       return field;
-
-                               if (type.BaseType == null)
-                                       return null;
-
-                               type = Resolve (type.BaseType);
-                       }
-
-                       return null;
-               }
-
-               static FieldDefinition GetField (Collection<FieldDefinition> fields, FieldReference reference)
-               {
-                       for (int i = 0; i < fields.Count; i++) {
-                               var field = fields [i];
-
-                               if (field.Name != reference.Name)
-                                       continue;
-
-                               if (!AreSame (field.FieldType, reference.FieldType))
-                                       continue;
-
-                               return field;
-                       }
-
-                       return null;
-               }
-
-               public virtual MethodDefinition Resolve (MethodReference method)
-               {
-                       if (method == null)
-                               throw new ArgumentNullException ("method");
-
-                       var type = Resolve (method.DeclaringType);
-                       if (type == null)
-                               return null;
-
-                       method = method.GetElementMethod ();
-
-                       if (!type.HasMethods)
-                               return null;
-
-                       return GetMethod (type, method);
-               }
-
-               MethodDefinition GetMethod (TypeDefinition type, MethodReference reference)
-               {
-                       while (type != null) {
-                               var method = GetMethod (type.Methods, reference);
-                               if (method != null)
-                                       return method;
-
-                               if (type.BaseType == null)
-                                       return null;
-
-                               type = Resolve (type.BaseType);
-                       }
-
-                       return null;
-               }
-
-               public static MethodDefinition GetMethod (Collection<MethodDefinition> methods, MethodReference reference)
-               {
-                       for (int i = 0; i < methods.Count; i++) {
-                               var method = methods [i];
-
-                               if (method.Name != reference.Name)
-                                       continue;
-
-                               if (method.HasGenericParameters != reference.HasGenericParameters)
-                                       continue;
-
-                               if (method.HasGenericParameters && method.GenericParameters.Count != reference.GenericParameters.Count)
-                                       continue;
-
-                               if (!AreSame (method.ReturnType, reference.ReturnType))
-                                       continue;
-
-                               if (method.HasParameters != reference.HasParameters)
-                                       continue;
-
-                               if (!method.HasParameters && !reference.HasParameters)
-                                       return method;
-
-                               if (!AreSame (method.Parameters, reference.Parameters))
-                                       continue;
-
-                               return method;
-                       }
-
-                       return null;
-               }
-
-               static bool AreSame (Collection<ParameterDefinition> a, Collection<ParameterDefinition> b)
-               {
-                       var count = a.Count;
-
-                       if (count != b.Count)
-                               return false;
-
-                       if (count == 0)
-                               return true;
-
-                       for (int i = 0; i < count; i++)
-                               if (!AreSame (a [i].ParameterType, b [i].ParameterType))
-                                       return false;
-
-                       return true;
-               }
-
-               static bool AreSame (TypeSpecification a, TypeSpecification b)
-               {
-                       if (!AreSame (a.ElementType, b.ElementType))
-                               return false;
-
-                       if (a.IsGenericInstance)
-                               return AreSame ((GenericInstanceType) a, (GenericInstanceType) b);
-
-                       if (a.IsRequiredModifier || a.IsOptionalModifier)
-                               return AreSame ((IModifierType) a, (IModifierType) b);
-
-                       if (a.IsArray)
-                               return AreSame ((ArrayType) a, (ArrayType) b);
-
-                       return true;
-               }
-
-               static bool AreSame (ArrayType a, ArrayType b)
-               {
-                       if (a.Rank != b.Rank)
-                               return false;
-
-                       // TODO: dimensions
-
-                       return true;
-               }
-
-               static bool AreSame (IModifierType a, IModifierType b)
-               {
-                       return AreSame (a.ModifierType, b.ModifierType);
-               }
-
-               static bool AreSame (GenericInstanceType a, GenericInstanceType b)
-               {
-                       if (a.GenericArguments.Count != b.GenericArguments.Count)
-                               return false;
-
-                       for (int i = 0; i < a.GenericArguments.Count; i++)
-                               if (!AreSame (a.GenericArguments [i], b.GenericArguments [i]))
-                                       return false;
-
-                       return true;
-               }
-
-               static bool AreSame (GenericParameter a, GenericParameter b)
-               {
-                       return a.Position == b.Position;
-               }
-
-               static bool AreSame (TypeReference a, TypeReference b)
-               {
-                       if (ReferenceEquals (a, b))
-                               return true;
-
-                       if (a == null || b == null)
-                               return false;
-
-                       if (a.etype != b.etype)
-                               return false;
-
-                       if (a.IsGenericParameter)
-                               return AreSame ((GenericParameter) a, (GenericParameter) b);
-
-                       if (a.IsTypeSpecification ())
-                               return AreSame ((TypeSpecification) a, (TypeSpecification) b);
-
-                       if (a.Name != b.Name || a.Namespace != b.Namespace)
-                               return false;
-
-                       //TODO: check scope
-
-                       return AreSame (a.DeclaringType, b.DeclaringType);
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MetadataSystem.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MetadataSystem.cs
deleted file mode 100644 (file)
index bfe7fc5..0000000
+++ /dev/null
@@ -1,380 +0,0 @@
-//
-// MetadataSystem.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-
-using Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       struct Range {
-               public uint Start;
-               public uint Length;
-
-               public Range (uint index, uint length)
-               {
-                       this.Start = index;
-                       this.Length = length;
-               }
-       }
-
-       sealed class MetadataSystem {
-
-               internal AssemblyNameReference [] AssemblyReferences;
-               internal ModuleReference [] ModuleReferences;
-
-               internal TypeDefinition [] Types;
-               internal TypeReference [] TypeReferences;
-
-               internal FieldDefinition [] Fields;
-               internal MethodDefinition [] Methods;
-               internal MemberReference [] MemberReferences;
-
-               internal Dictionary<uint, uint []> NestedTypes;
-               internal Dictionary<uint, uint> ReverseNestedTypes;
-               internal Dictionary<uint, MetadataToken []> Interfaces;
-               internal Dictionary<uint, Row<ushort, uint>> ClassLayouts;
-               internal Dictionary<uint, uint> FieldLayouts;
-               internal Dictionary<uint, uint> FieldRVAs;
-               internal Dictionary<MetadataToken, uint> FieldMarshals;
-               internal Dictionary<MetadataToken, Row<ElementType, uint>> Constants;
-               internal Dictionary<uint, MetadataToken []> Overrides;
-               internal Dictionary<MetadataToken, Range> CustomAttributes;
-               internal Dictionary<MetadataToken, Range> SecurityDeclarations;
-               internal Dictionary<uint, Range> Events;
-               internal Dictionary<uint, Range> Properties;
-               internal Dictionary<uint, Row<MethodSemanticsAttributes, MetadataToken>> Semantics;
-               internal Dictionary<uint, Row<PInvokeAttributes, uint, uint>> PInvokes;
-               internal Dictionary<MetadataToken, Range> GenericParameters;
-               internal Dictionary<uint, MetadataToken []> GenericConstraints;
-
-               static Dictionary<string, Row<ElementType, bool>> primitive_value_types;
-
-               static void InitializePrimitives ()
-               {
-                       primitive_value_types = new Dictionary<string, Row<ElementType, bool>> (18) {
-                               { "Void", new Row<ElementType, bool> (ElementType.Void, false) },
-                               { "Boolean", new Row<ElementType, bool> (ElementType.Boolean, true) },
-                               { "Char", new Row<ElementType, bool> (ElementType.Char, true) },
-                               { "SByte", new Row<ElementType, bool> (ElementType.I1, true) },
-                               { "Byte", new Row<ElementType, bool> (ElementType.U1, true) },
-                               { "Int16", new Row<ElementType, bool> (ElementType.I2, true) },
-                               { "UInt16", new Row<ElementType, bool> (ElementType.U2, true) },
-                               { "Int32", new Row<ElementType, bool> (ElementType.I4, true) },
-                               { "UInt32", new Row<ElementType, bool> (ElementType.U4, true) },
-                               { "Int64", new Row<ElementType, bool> (ElementType.I8, true) },
-                               { "UInt64", new Row<ElementType, bool> (ElementType.U8, true) },
-                               { "Single", new Row<ElementType, bool> (ElementType.R4, true) },
-                               { "Double", new Row<ElementType, bool> (ElementType.R8, true) },
-                               { "String", new Row<ElementType, bool> (ElementType.String, false) },
-                               { "TypedReference", new Row<ElementType, bool> (ElementType.TypedByRef, false) },
-                               { "IntPtr", new Row<ElementType, bool> (ElementType.I, true) },
-                               { "UIntPtr", new Row<ElementType, bool> (ElementType.U, true) },
-                               { "Object", new Row<ElementType, bool> (ElementType.Object, false) },
-                       };
-               }
-
-               public static void TryProcessPrimitiveType (TypeReference type)
-               {
-                       var scope = type.scope;
-                       if (scope == null)
-                               return;
-
-                       if (scope.MetadataScopeType != MetadataScopeType.AssemblyNameReference)
-                               return;
-
-                       if (scope.Name != "mscorlib")
-                               return;
-
-                       if (type.Namespace != "System")
-                               return;
-
-                       if (primitive_value_types == null)
-                               InitializePrimitives ();
-
-                       Row<ElementType, bool> primitive_data;
-                       if (!primitive_value_types.TryGetValue (type.Name, out primitive_data))
-                               return;
-
-                       type.etype = primitive_data.Col1;
-                       type.IsValueType = primitive_data.Col2;
-               }
-
-               public void Clear ()
-               {
-                       if (NestedTypes != null) NestedTypes.Clear ();
-                       if (ReverseNestedTypes != null) ReverseNestedTypes.Clear ();
-                       if (Interfaces != null) Interfaces.Clear ();
-                       if (ClassLayouts != null) ClassLayouts.Clear ();
-                       if (FieldLayouts != null) FieldLayouts.Clear ();
-                       if (FieldRVAs != null) FieldRVAs.Clear ();
-                       if (FieldMarshals != null) FieldMarshals.Clear ();
-                       if (Constants != null) Constants.Clear ();
-                       if (Overrides != null) Overrides.Clear ();
-                       if (CustomAttributes != null) CustomAttributes.Clear ();
-                       if (SecurityDeclarations != null) SecurityDeclarations.Clear ();
-                       if (Events != null) Events.Clear ();
-                       if (Properties != null) Properties.Clear ();
-                       if (Semantics != null) Semantics.Clear ();
-                       if (PInvokes != null) PInvokes.Clear ();
-                       if (GenericParameters != null) GenericParameters.Clear ();
-                       if (GenericConstraints != null) GenericConstraints.Clear ();
-               }
-
-               public TypeDefinition GetTypeDefinition (uint rid)
-               {
-                       if (rid < 1 || rid > Types.Length)
-                               return null;
-
-                       return Types [rid - 1];
-               }
-
-               public void AddTypeDefinition (TypeDefinition type)
-               {
-                       Types [type.token.RID - 1] = type;
-               }
-
-               public TypeReference GetTypeReference (uint rid)
-               {
-                       if (rid < 1 || rid > TypeReferences.Length)
-                               return null;
-
-                       return TypeReferences [rid - 1];
-               }
-
-               public void AddTypeReference (TypeReference type)
-               {
-                       TypeReferences [type.token.RID - 1] = type;
-               }
-
-               public FieldDefinition GetFieldDefinition (uint rid)
-               {
-                       if (rid < 1 || rid > Fields.Length)
-                               return null;
-
-                       return Fields [rid - 1];
-               }
-
-               public void AddFieldDefinition (FieldDefinition field)
-               {
-                       Fields [field.token.RID - 1] = field;
-               }
-
-               public MethodDefinition GetMethodDefinition (uint rid)
-               {
-                       if (rid < 1 || rid > Methods.Length)
-                               return null;
-
-                       return Methods [rid - 1];
-               }
-
-               public void AddMethodDefinition (MethodDefinition method)
-               {
-                       Methods [method.token.RID - 1] = method;
-               }
-
-               public MemberReference GetMemberReference (uint rid)
-               {
-                       if (rid < 1 || rid > MemberReferences.Length)
-                               return null;
-
-                       return MemberReferences [rid - 1];
-               }
-
-               public void AddMemberReference (MemberReference member)
-               {
-                       MemberReferences [member.token.RID - 1] = member;
-               }
-
-               public bool TryGetNestedTypeMapping (TypeDefinition type, out uint [] mapping)
-               {
-                       return NestedTypes.TryGetValue (type.token.RID, out mapping);
-               }
-
-               public void SetNestedTypeMapping (uint type_rid, uint [] mapping)
-               {
-                       NestedTypes [type_rid] = mapping;
-               }
-
-               public void RemoveNestedTypeMapping (TypeDefinition type)
-               {
-                       NestedTypes.Remove (type.token.RID);
-               }
-
-               public bool TryGetReverseNestedTypeMapping (TypeDefinition type, out uint declaring)
-               {
-                       return ReverseNestedTypes.TryGetValue (type.token.RID, out declaring);
-               }
-
-               public void SetReverseNestedTypeMapping (uint nested, uint declaring)
-               {
-                       ReverseNestedTypes.Add (nested, declaring);
-               }
-
-               public void RemoveReverseNestedTypeMapping (TypeDefinition type)
-               {
-                       ReverseNestedTypes.Remove (type.token.RID);
-               }
-
-               public bool TryGetInterfaceMapping (TypeDefinition type, out MetadataToken [] mapping)
-               {
-                       return Interfaces.TryGetValue (type.token.RID, out mapping);
-               }
-
-               public void SetInterfaceMapping (uint type_rid, MetadataToken [] mapping)
-               {
-                       Interfaces [type_rid] = mapping;
-               }
-
-               public void RemoveInterfaceMapping (TypeDefinition type)
-               {
-                       Interfaces.Remove (type.token.RID);
-               }
-
-               public void AddPropertiesRange (uint type_rid, Range range)
-               {
-                       Properties.Add (type_rid, range);
-               }
-
-               public bool TryGetPropertiesRange (TypeDefinition type, out Range range)
-               {
-                       return Properties.TryGetValue (type.token.RID, out range);
-               }
-
-               public void RemovePropertiesRange (TypeDefinition type)
-               {
-                       Properties.Remove (type.token.RID);
-               }
-
-               public void AddEventsRange (uint type_rid, Range range)
-               {
-                       Events.Add (type_rid, range);
-               }
-
-               public bool TryGetEventsRange (TypeDefinition type, out Range range)
-               {
-                       return Events.TryGetValue (type.token.RID, out range);
-               }
-
-               public void RemoveEventsRange (TypeDefinition type)
-               {
-                       Events.Remove (type.token.RID);
-               }
-
-               public bool TryGetGenericParameterRange (IGenericParameterProvider owner, out Range range)
-               {
-                       return GenericParameters.TryGetValue (owner.MetadataToken, out range);
-               }
-
-               public void RemoveGenericParameterRange (IGenericParameterProvider owner)
-               {
-                       GenericParameters.Remove (owner.MetadataToken);
-               }
-
-               public bool TryGetCustomAttributeRange (ICustomAttributeProvider owner, out Range range)
-               {
-                       return CustomAttributes.TryGetValue (owner.MetadataToken, out range);
-               }
-
-               public void RemoveCustomAttributeRange (ICustomAttributeProvider owner)
-               {
-                       CustomAttributes.Remove (owner.MetadataToken);
-               }
-
-               public bool TryGetSecurityDeclarationRange (ISecurityDeclarationProvider owner, out Range range)
-               {
-                       return SecurityDeclarations.TryGetValue (owner.MetadataToken, out range);
-               }
-
-               public void RemoveSecurityDeclarationRange (ISecurityDeclarationProvider owner)
-               {
-                       SecurityDeclarations.Remove (owner.MetadataToken);
-               }
-
-               public bool TryGetGenericConstraintMapping (GenericParameter generic_parameter, out MetadataToken [] mapping)
-               {
-                       return GenericConstraints.TryGetValue (generic_parameter.token.RID, out mapping);
-               }
-
-               public void SetGenericConstraintMapping (uint gp_rid, MetadataToken [] mapping)
-               {
-                       GenericConstraints [gp_rid] = mapping;
-               }
-
-               public void RemoveGenericConstraintMapping (GenericParameter generic_parameter)
-               {
-                       GenericConstraints.Remove (generic_parameter.token.RID);
-               }
-
-               public bool TryGetOverrideMapping (MethodDefinition method, out MetadataToken [] mapping)
-               {
-                       return Overrides.TryGetValue (method.token.RID, out mapping);
-               }
-
-               public void SetOverrideMapping (uint rid, MetadataToken [] mapping)
-               {
-                       Overrides [rid] = mapping;
-               }
-
-               public void RemoveOverrideMapping (MethodDefinition method)
-               {
-                       Overrides.Remove (method.token.RID);
-               }
-
-               public TypeDefinition GetFieldDeclaringType (uint field_rid)
-               {
-                       return BinaryRangeSearch (Types, field_rid, true);
-               }
-
-               public TypeDefinition GetMethodDeclaringType (uint method_rid)
-               {
-                       return BinaryRangeSearch (Types, method_rid, false);
-               }
-
-               static TypeDefinition BinaryRangeSearch (TypeDefinition [] types, uint rid, bool field)
-               {
-                       int min = 0;
-                       int max = types.Length - 1;
-                       while (min <= max) {
-                               int mid = min + ((max - min) / 2);
-                               var type = types [mid];
-                               var range = field ? type.fields_range : type.methods_range;
-
-                               if (rid < range.Start)
-                                       max = mid - 1;
-                               else if (rid >= range.Start + range.Length)
-                                       min = mid + 1;
-                               else
-                                       return type;
-                       }
-
-                       return null;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MethodAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MethodAttributes.cs
deleted file mode 100644 (file)
index 626a97b..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-//
-// MethodAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum MethodAttributes : ushort {
-               MemberAccessMask        = 0x0007,
-               CompilerControlled      = 0x0000,       // Member not referenceable
-               Private                         = 0x0001,       // Accessible only by the parent type
-               FamANDAssem                     = 0x0002,       // Accessible by sub-types only in this Assembly
-               Assembly                                = 0x0003,       // Accessibly by anyone in the Assembly
-               Family                          = 0x0004,       // Accessible only by type and sub-types
-               FamORAssem                      = 0x0005,       // Accessibly by sub-types anywhere, plus anyone in assembly
-               Public                          = 0x0006,       // Accessibly by anyone who has visibility to this scope
-
-               Static                          = 0x0010,       // Defined on type, else per instance
-               Final                           = 0x0020,       // Method may not be overridden
-               Virtual                         = 0x0040,       // Method is virtual
-               HideBySig                       = 0x0080,       // Method hides by name+sig, else just by name
-
-               VtableLayoutMask        = 0x0100,       // Use this mask to retrieve vtable attributes
-               ReuseSlot                       = 0x0000,       // Method reuses existing slot in vtable
-               NewSlot                         = 0x0100,       // Method always gets a new slot in the vtable
-
-               CheckAccessOnOverride = 0x0200,   // Method can only be overriden if also accessible
-               Abstract                        = 0x0400,       // Method does not provide an implementation
-               SpecialName                     = 0x0800,       // Method is special
-
-               // Interop Attributes
-               PInvokeImpl                     = 0x2000,       // Implementation is forwarded through PInvoke
-               UnmanagedExport         = 0x0008,       // Reserved: shall be zero for conforming implementations
-
-               // Additional flags
-               RTSpecialName           = 0x1000,       // CLI provides 'special' behavior, depending upon the name of the method
-               HasSecurity                     = 0x4000,       // Method has security associate with it
-               RequireSecObject        = 0x8000         // Method calls another method containing security code
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MethodCallingConvention.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MethodCallingConvention.cs
deleted file mode 100644 (file)
index bd7188d..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-//
-// MethodCallingConvention.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public enum MethodCallingConvention : byte {
-               Default         = 0x0,
-               C                       = 0x1,
-               StdCall         = 0x2,
-               ThisCall        = 0x3,
-               FastCall        = 0x4,
-               VarArg          = 0x5,
-               Generic         = 0x10,
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MethodDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MethodDefinition.cs
deleted file mode 100644 (file)
index cbda745..0000000
+++ /dev/null
@@ -1,487 +0,0 @@
-//
-// MethodDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using Mono.Cecil.Cil;
-using Mono.Collections.Generic;
-
-using RVA = System.UInt32;
-
-namespace Mono.Cecil {
-
-       public sealed class MethodDefinition : MethodReference, IMemberDefinition, ISecurityDeclarationProvider {
-
-               ushort attributes;
-               ushort impl_attributes;
-               internal MethodSemanticsAttributes? sem_attrs;
-               Collection<CustomAttribute> custom_attributes;
-               Collection<SecurityDeclaration> security_declarations;
-
-               internal RVA rva;
-               internal PInvokeInfo pinvoke;
-               Collection<MethodReference> overrides;
-
-               internal MethodBody body;
-
-               public MethodAttributes Attributes {
-                       get { return (MethodAttributes) attributes; }
-                       set { attributes = (ushort) value; }
-               }
-
-               public MethodImplAttributes ImplAttributes {
-                       get { return (MethodImplAttributes) impl_attributes; }
-                       set { impl_attributes = (ushort) value; }
-               }
-
-               public MethodSemanticsAttributes SemanticsAttributes {
-                       get {
-                               if (sem_attrs.HasValue)
-                                       return sem_attrs.Value;
-
-                               if (HasImage) {
-                                       ReadSemantics ();
-                                       return sem_attrs.Value;
-                               }
-
-                               sem_attrs = MethodSemanticsAttributes.None;
-                               return sem_attrs.Value;
-                       }
-                       set { sem_attrs = value; }
-               }
-
-               internal void ReadSemantics ()
-               {
-                       if (sem_attrs.HasValue)
-                               return;
-
-                       var module = this.Module;
-                       if (module == null)
-                               return;
-
-                       if (!module.HasImage)
-                               return;
-
-                       module.Read (this, (method, reader) => reader.ReadAllSemantics (method));
-               }
-
-               public bool HasSecurityDeclarations {
-                       get {
-                               if (security_declarations != null)
-                                       return security_declarations.Count > 0;
-
-                               return this.GetHasSecurityDeclarations (Module);
-                       }
-               }
-
-               public Collection<SecurityDeclaration> SecurityDeclarations {
-                       get { return security_declarations ?? (security_declarations = this.GetSecurityDeclarations (Module)); }
-               }
-
-               public bool HasCustomAttributes {
-                       get {
-                               if (custom_attributes != null)
-                                       return custom_attributes.Count > 0;
-
-                               return this.GetHasCustomAttributes (Module);
-                       }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return custom_attributes ?? (custom_attributes = this.GetCustomAttributes (Module)); }
-               }
-
-               public int RVA {
-                       get { return (int) rva; }
-               }
-
-               public bool HasBody {
-                       get {
-                               return (attributes & (ushort) MethodAttributes.Abstract) == 0 &&
-                                       (attributes & (ushort) MethodAttributes.PInvokeImpl) == 0 &&
-                                       (impl_attributes & (ushort) MethodImplAttributes.InternalCall) == 0 &&
-                                       (impl_attributes & (ushort) MethodImplAttributes.Native) == 0 &&
-                                       (impl_attributes & (ushort) MethodImplAttributes.Unmanaged) == 0 &&
-                                       (impl_attributes & (ushort) MethodImplAttributes.Runtime) == 0;
-                       }
-               }
-
-               public MethodBody Body {
-                       get {
-                               if (body != null)
-                                       return body;
-
-                               if (!HasBody)
-                                       return null;
-
-                               if (HasImage && rva != 0)
-                                       return body = Module.Read (this, (method, reader) => reader.ReadMethodBody (method));
-
-                               return body = new MethodBody (this);
-                       }
-                       set { body = value; }
-               }
-
-               public bool HasPInvokeInfo {
-                       get {
-                               if (pinvoke != null)
-                                       return true;
-
-                               return IsPInvokeImpl;
-                       }
-               }
-
-               public PInvokeInfo PInvokeInfo {
-                       get {
-                               if (pinvoke != null)
-                                       return pinvoke;
-
-                               if (HasImage && IsPInvokeImpl)
-                                       return pinvoke = Module.Read (this, (method, reader) => reader.ReadPInvokeInfo (method));
-
-                               return null;
-                       }
-                       set {
-                               IsPInvokeImpl = true;
-                               pinvoke = value;
-                       }
-               }
-
-               public bool HasOverrides {
-                       get {
-                               if (overrides != null)
-                                       return overrides.Count > 0;
-
-                               if (HasImage)
-                                       return Module.Read (this, (method, reader) => reader.HasOverrides (method));
-
-                               return false;
-                       }
-               }
-
-               public Collection<MethodReference> Overrides {
-                       get {
-                               if (overrides != null)
-                                       return overrides;
-
-                               if (HasImage)
-                                       return overrides = Module.Read (this, (method, reader) => reader.ReadOverrides (method));
-
-                               return overrides = new Collection<MethodReference> ();
-                       }
-               }
-
-               public override bool HasGenericParameters {
-                       get {
-                               if (generic_parameters != null)
-                                       return generic_parameters.Count > 0;
-
-                               return this.GetHasGenericParameters (Module);
-                       }
-               }
-
-               public override Collection<GenericParameter> GenericParameters {
-                       get { return generic_parameters ?? (generic_parameters = this.GetGenericParameters (Module)); }
-               }
-
-               #region MethodAttributes
-
-               public bool IsCompilerControlled {
-                       get { return attributes.GetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.CompilerControlled); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.CompilerControlled, value); }
-               }
-
-               public bool IsPrivate {
-                       get { return attributes.GetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.Private); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.Private, value); }
-               }
-
-               public bool IsFamilyAndAssembly {
-                       get { return attributes.GetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.FamANDAssem); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.FamANDAssem, value); }
-               }
-
-               public bool IsAssembly {
-                       get { return attributes.GetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.Assembly); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.Assembly, value); }
-               }
-
-               public bool IsFamily {
-                       get { return attributes.GetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.Family); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.Family, value); }
-               }
-
-               public bool IsFamilyOrAssembly {
-                       get { return attributes.GetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.FamORAssem); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.FamORAssem, value); }
-               }
-
-               public bool IsPublic {
-                       get { return attributes.GetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.Public); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) MethodAttributes.MemberAccessMask, (ushort) MethodAttributes.Public, value); }
-               }
-
-               public bool IsStatic {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.Static); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.Static, value); }
-               }
-
-               public bool IsFinal {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.Final); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.Final, value); }
-               }
-
-               public bool IsVirtual {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.Virtual); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.Virtual, value); }
-               }
-
-               public bool IsHideBySig {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.HideBySig); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.HideBySig, value); }
-               }
-
-               public bool IsReuseSlot {
-                       get { return attributes.GetMaskedAttributes ((ushort) MethodAttributes.VtableLayoutMask, (ushort) MethodAttributes.ReuseSlot); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) MethodAttributes.VtableLayoutMask, (ushort) MethodAttributes.ReuseSlot, value); }
-               }
-
-               public bool IsNewSlot {
-                       get { return attributes.GetMaskedAttributes ((ushort) MethodAttributes.VtableLayoutMask, (ushort) MethodAttributes.NewSlot); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) MethodAttributes.VtableLayoutMask, (ushort) MethodAttributes.NewSlot, value); }
-               }
-
-               public bool IsCheckAccessOnOverride {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.CheckAccessOnOverride); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.CheckAccessOnOverride, value); }
-               }
-
-               public bool IsAbstract {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.Abstract); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.Abstract, value); }
-               }
-
-               public bool IsSpecialName {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.SpecialName); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.SpecialName, value); }
-               }
-
-               public bool IsPInvokeImpl {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.PInvokeImpl); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.PInvokeImpl, value); }
-               }
-
-               public bool IsUnmanagedExport {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.UnmanagedExport); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.UnmanagedExport, value); }
-               }
-
-               public bool IsRuntimeSpecialName {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.RTSpecialName); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.RTSpecialName, value); }
-               }
-
-               public bool HasSecurity {
-                       get { return attributes.GetAttributes ((ushort) MethodAttributes.HasSecurity); }
-                       set { attributes = attributes.SetAttributes ((ushort) MethodAttributes.HasSecurity, value); }
-               }
-
-               #endregion
-
-               #region MethodImplAttributes
-
-               public bool IsIL {
-                       get { return impl_attributes.GetMaskedAttributes ((ushort) MethodImplAttributes.CodeTypeMask, (ushort) MethodImplAttributes.IL); }
-                       set { impl_attributes = impl_attributes.SetMaskedAttributes ((ushort) MethodImplAttributes.CodeTypeMask, (ushort) MethodImplAttributes.IL, value); }
-               }
-
-               public bool IsNative {
-                       get { return impl_attributes.GetMaskedAttributes ((ushort) MethodImplAttributes.CodeTypeMask, (ushort) MethodImplAttributes.Native); }
-                       set { impl_attributes = impl_attributes.SetMaskedAttributes ((ushort) MethodImplAttributes.CodeTypeMask, (ushort) MethodImplAttributes.Native, value); }
-               }
-
-               public bool IsRuntime {
-                       get { return impl_attributes.GetMaskedAttributes ((ushort) MethodImplAttributes.CodeTypeMask, (ushort) MethodImplAttributes.Runtime); }
-                       set { impl_attributes = impl_attributes.SetMaskedAttributes ((ushort) MethodImplAttributes.CodeTypeMask, (ushort) MethodImplAttributes.Runtime, value); }
-               }
-
-               public bool IsUnmanaged {
-                       get { return impl_attributes.GetMaskedAttributes ((ushort) MethodImplAttributes.ManagedMask, (ushort) MethodImplAttributes.Unmanaged); }
-                       set { impl_attributes = impl_attributes.SetMaskedAttributes ((ushort) MethodImplAttributes.ManagedMask, (ushort) MethodImplAttributes.Unmanaged, value); }
-               }
-
-               public bool IsManaged {
-                       get { return impl_attributes.GetMaskedAttributes ((ushort) MethodImplAttributes.ManagedMask, (ushort) MethodImplAttributes.Managed); }
-                       set { impl_attributes = impl_attributes.SetMaskedAttributes ((ushort) MethodImplAttributes.ManagedMask, (ushort) MethodImplAttributes.Managed, value); }
-               }
-
-               public bool IsForwardRef {
-                       get { return impl_attributes.GetAttributes ((ushort) MethodImplAttributes.ForwardRef); }
-                       set { impl_attributes = impl_attributes.SetAttributes ((ushort) MethodImplAttributes.ForwardRef, value); }
-               }
-
-               public bool IsPreserveSig {
-                       get { return impl_attributes.GetAttributes ((ushort) MethodImplAttributes.PreserveSig); }
-                       set { impl_attributes = impl_attributes.SetAttributes ((ushort) MethodImplAttributes.PreserveSig, value); }
-               }
-
-               public bool IsInternalCall {
-                       get { return impl_attributes.GetAttributes ((ushort) MethodImplAttributes.InternalCall); }
-                       set { impl_attributes = impl_attributes.SetAttributes ((ushort) MethodImplAttributes.InternalCall, value); }
-               }
-
-               public bool IsSynchronized {
-                       get { return impl_attributes.GetAttributes ((ushort) MethodImplAttributes.Synchronized); }
-                       set { impl_attributes = impl_attributes.SetAttributes ((ushort) MethodImplAttributes.Synchronized, value); }
-               }
-
-               public bool NoInlining {
-                       get { return impl_attributes.GetAttributes ((ushort) MethodImplAttributes.NoInlining); }
-                       set { impl_attributes = impl_attributes.SetAttributes ((ushort) MethodImplAttributes.NoInlining, value); }
-               }
-
-               public bool NoOptimization {
-                       get { return impl_attributes.GetAttributes ((ushort) MethodImplAttributes.NoOptimization); }
-                       set { impl_attributes = impl_attributes.SetAttributes ((ushort) MethodImplAttributes.NoOptimization, value); }
-               }
-
-               #endregion
-
-               #region MethodSemanticsAttributes
-
-               public bool IsSetter {
-                       get { return this.GetSemantics (MethodSemanticsAttributes.Setter); }
-                       set { this.SetSemantics (MethodSemanticsAttributes.Setter, value); }
-               }
-
-               public bool IsGetter {
-                       get { return this.GetSemantics (MethodSemanticsAttributes.Getter); }
-                       set { this.SetSemantics (MethodSemanticsAttributes.Getter, value); }
-               }
-
-               public bool IsOther {
-                       get { return this.GetSemantics (MethodSemanticsAttributes.Other); }
-                       set { this.SetSemantics (MethodSemanticsAttributes.Other, value); }
-               }
-
-               public bool IsAddOn {
-                       get { return this.GetSemantics (MethodSemanticsAttributes.AddOn); }
-                       set { this.SetSemantics (MethodSemanticsAttributes.AddOn, value); }
-               }
-
-               public bool IsRemoveOn {
-                       get { return this.GetSemantics (MethodSemanticsAttributes.RemoveOn); }
-                       set { this.SetSemantics (MethodSemanticsAttributes.RemoveOn, value); }
-               }
-
-               public bool IsFire {
-                       get { return this.GetSemantics (MethodSemanticsAttributes.Fire); }
-                       set { this.SetSemantics (MethodSemanticsAttributes.Fire, value); }
-               }
-
-               #endregion
-
-               public new TypeDefinition DeclaringType {
-                       get { return (TypeDefinition) base.DeclaringType; }
-                       set { base.DeclaringType = value; }
-               }
-
-               public bool IsConstructor {
-                       get {
-                               return this.IsRuntimeSpecialName
-                                       && this.IsSpecialName
-                                       && (this.Name == ".cctor" || this.Name == ".ctor");
-                       }
-               }
-
-               public override bool IsDefinition {
-                       get { return true; }
-               }
-
-               internal MethodDefinition ()
-               {
-                       this.token = new MetadataToken (TokenType.Method);
-               }
-
-               public MethodDefinition (string name, MethodAttributes attributes, TypeReference returnType)
-                       : base (name, returnType)
-               {
-                       this.attributes = (ushort) attributes;
-                       this.HasThis = !this.IsStatic;
-                       this.token = new MetadataToken (TokenType.Method);
-               }
-
-               public override MethodDefinition Resolve ()
-               {
-                       return this;
-               }
-       }
-
-       static partial class Mixin {
-
-               public static ParameterDefinition GetParameter (this MethodBody self, int index)
-               {
-                       var method = self.method;
-
-                       if (method.HasThis) {
-                               if (index == 0)
-                                       return self.ThisParameter;
-
-                               index--;
-                       }
-
-                       var parameters = method.Parameters;
-
-                       if (index < 0 || index >= parameters.size)
-                               return null;
-
-                       return parameters [index];
-               }
-
-               public static VariableDefinition GetVariable (this MethodBody self, int index)
-               {
-                       var variables = self.Variables;
-
-                       if (index < 0 || index >= variables.size)
-                               return null;
-
-                       return variables [index];
-               }
-
-               public static bool GetSemantics (this MethodDefinition self, MethodSemanticsAttributes semantics)
-               {
-                       return (self.SemanticsAttributes & semantics) != 0;
-               }
-
-               public static void SetSemantics (this MethodDefinition self, MethodSemanticsAttributes semantics, bool value)
-               {
-                       if (value)
-                               self.SemanticsAttributes |= semantics;
-                       else
-                               self.SemanticsAttributes &= ~semantics;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MethodImplAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MethodImplAttributes.cs
deleted file mode 100644 (file)
index b24fcf7..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-//
-// MethodImplAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum MethodImplAttributes : ushort {
-               CodeTypeMask            = 0x0003,
-               IL                                      = 0x0000,       // Method impl is CIL
-               Native                          = 0x0001,       // Method impl is native
-               OPTIL                           = 0x0002,       // Reserved: shall be zero in conforming implementations
-               Runtime                         = 0x0003,       // Method impl is provided by the runtime
-
-               ManagedMask                     = 0x0004,       // Flags specifying whether the code is managed or unmanaged
-               Unmanaged                       = 0x0004,       // Method impl is unmanaged, otherwise managed
-               Managed                         = 0x0000,       // Method impl is managed
-
-               // Implementation info and interop
-               ForwardRef                      = 0x0010,       // Indicates method is defined; used primarily in merge scenarios
-               PreserveSig                     = 0x0080,       // Reserved: conforming implementations may ignore
-               InternalCall            = 0x1000,       // Reserved: shall be zero in conforming implementations
-               Synchronized            = 0x0020,       // Method is single threaded through the body
-               NoOptimization          = 0x0040,       // Method is not optimized by the JIT.
-               NoInlining                      = 0x0008,       // Method may not be inlined
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MethodReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MethodReference.cs
deleted file mode 100644 (file)
index 0adab45..0000000
+++ /dev/null
@@ -1,214 +0,0 @@
-//
-// MethodReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Text;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public class MethodReference : MemberReference, IMethodSignature, IGenericParameterProvider, IGenericContext {
-
-               internal ParameterDefinitionCollection parameters;
-               MethodReturnType return_type;
-
-               bool has_this;
-               bool explicit_this;
-               MethodCallingConvention calling_convention;
-               internal Collection<GenericParameter> generic_parameters;
-
-               public virtual bool HasThis {
-                       get { return has_this; }
-                       set { has_this = value; }
-               }
-
-               public virtual bool ExplicitThis {
-                       get { return explicit_this; }
-                       set { explicit_this = value; }
-               }
-
-               public virtual MethodCallingConvention CallingConvention {
-                       get { return calling_convention; }
-                       set { calling_convention = value; }
-               }
-
-               public virtual bool HasParameters {
-                       get { return !parameters.IsNullOrEmpty (); }
-               }
-
-               public virtual Collection<ParameterDefinition> Parameters {
-                       get {
-                               if (parameters == null)
-                                       parameters = new ParameterDefinitionCollection (this);
-
-                               return parameters;
-                       }
-               }
-
-               IGenericParameterProvider IGenericContext.Type {
-                       get {
-                               var declaring_type = this.DeclaringType;
-                               var instance = declaring_type as GenericInstanceType;
-                               if (instance != null)
-                                       return instance.ElementType;
-
-                               return declaring_type;
-                       }
-               }
-
-               IGenericParameterProvider IGenericContext.Method {
-                       get { return this; }
-               }
-
-               GenericParameterType IGenericParameterProvider.GenericParameterType {
-                       get { return GenericParameterType.Method; }
-               }
-
-               public virtual bool HasGenericParameters {
-                       get { return !generic_parameters.IsNullOrEmpty (); }
-               }
-
-               public virtual Collection<GenericParameter> GenericParameters {
-                       get {
-                               if (generic_parameters != null)
-                                       return generic_parameters;
-
-                               return generic_parameters = new GenericParameterCollection (this);
-                       }
-               }
-
-               public TypeReference ReturnType {
-                       get {
-                               var return_type = MethodReturnType;
-                               return return_type != null ? return_type.ReturnType : null;
-                       }
-                       set {
-                               var return_type = MethodReturnType;
-                               if (return_type != null)
-                                       return_type.ReturnType = value;
-                       }
-               }
-
-               public virtual MethodReturnType MethodReturnType {
-                       get { return return_type; }
-                       set { return_type = value; }
-               }
-
-               public override string FullName {
-                       get {
-                               var builder = new StringBuilder ();
-                               builder.Append (ReturnType.FullName)
-                                       .Append (" ")
-                                       .Append (MemberFullName ());
-                               this.MethodSignatureFullName (builder);
-                               return builder.ToString ();
-                       }
-               }
-
-               public virtual bool IsGenericInstance {
-                       get { return false; }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get {
-                               if (this.ReturnType.ContainsGenericParameter || base.ContainsGenericParameter)
-                                       return true;
-
-                               var parameters = this.Parameters;
-
-                               for (int i = 0; i < parameters.Count; i++)
-                                       if (parameters [i].ParameterType.ContainsGenericParameter)
-                                               return true;
-
-                               return false;
-                       }
-               }
-
-               internal MethodReference ()
-               {
-                       this.return_type = new MethodReturnType (this);
-                       this.token = new MetadataToken (TokenType.MemberRef);
-               }
-
-               public MethodReference (string name, TypeReference returnType)
-                       : base (name)
-               {
-                       if (returnType == null)
-                               throw new ArgumentNullException ("returnType");
-
-                       this.return_type = new MethodReturnType (this);
-                       this.return_type.ReturnType = returnType;
-                       this.token = new MetadataToken (TokenType.MemberRef);
-               }
-
-               public MethodReference (string name, TypeReference returnType, TypeReference declaringType)
-                       : this (name, returnType)
-               {
-                       if (declaringType == null)
-                               throw new ArgumentNullException ("declaringType");
-
-                       this.DeclaringType = declaringType;
-               }
-
-               public virtual MethodReference GetElementMethod ()
-               {
-                       return this;
-               }
-
-               public virtual MethodDefinition Resolve ()
-               {
-                       var module = this.Module;
-                       if (module == null)
-                               throw new NotSupportedException ();
-
-                       return module.Resolve (this);
-               }
-       }
-
-       static partial class Mixin {
-
-               public static bool IsVarArg (this IMethodSignature self)
-               {
-                       return (self.CallingConvention & MethodCallingConvention.VarArg) != 0;
-               }
-
-               public static int GetSentinelPosition (this IMethodSignature self)
-               {
-                       if (!self.HasParameters)
-                               return -1;
-
-                       var parameters = self.Parameters;
-                       for (int i = 0; i < parameters.Count; i++)
-                               if (parameters [i].ParameterType.IsSentinel)
-                                       return i;
-
-                       return -1;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MethodReturnType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MethodReturnType.cs
deleted file mode 100644 (file)
index f2e2eaa..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-//
-// MethodReturnType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public sealed class MethodReturnType : IConstantProvider, ICustomAttributeProvider, IMarshalInfoProvider {
-
-               internal IMethodSignature method;
-               internal ParameterDefinition parameter;
-               TypeReference return_type;
-
-               public IMethodSignature Method {
-                       get { return method; }
-               }
-
-               public TypeReference ReturnType {
-                       get { return return_type; }
-                       set { return_type = value; }
-               }
-
-               internal ParameterDefinition Parameter {
-                       get { return parameter ?? (parameter = new ParameterDefinition (return_type)); }
-                       set { parameter = value; }
-               }
-
-               public MetadataToken MetadataToken {
-                       get { return Parameter.MetadataToken; }
-                       set { Parameter.MetadataToken = value; }
-               }
-
-               public ParameterAttributes Attributes {
-                       get { return Parameter.Attributes; }
-                       set { Parameter.Attributes = value; }
-               }
-
-               public bool HasCustomAttributes {
-                       get { return parameter != null && parameter.HasCustomAttributes; }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return Parameter.CustomAttributes; }
-               }
-
-               public bool HasDefault {
-                       get { return parameter != null && parameter.HasDefault; }
-                       set { Parameter.HasDefault = value; }
-               }
-
-               public bool HasConstant {
-                       get { return parameter != null && parameter.HasConstant; }
-                       set { Parameter.HasConstant = value; }
-               }
-
-               public object Constant {
-                       get { return Parameter.Constant; }
-                       set { Parameter.Constant = value; }
-               }
-
-               public bool HasFieldMarshal {
-                       get { return parameter != null && parameter.HasFieldMarshal; }
-                       set { Parameter.HasFieldMarshal = value; }
-               }
-
-               public bool HasMarshalInfo {
-                       get { return parameter != null && parameter.HasMarshalInfo; }
-               }
-
-               public MarshalInfo MarshalInfo {
-                       get { return Parameter.MarshalInfo; }
-                       set { Parameter.MarshalInfo = value; }
-               }
-
-               public MethodReturnType (IMethodSignature method)
-               {
-                       this.method = method;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MethodSemanticsAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MethodSemanticsAttributes.cs
deleted file mode 100644 (file)
index dd0f474..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-//
-// MethodSemanticsattributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum MethodSemanticsAttributes : ushort {
-               None            = 0x0000,
-               Setter          = 0x0001,       // Setter for property
-               Getter          = 0x0002,       // Getter for property
-               Other           = 0x0004,       // Other method for property or event
-               AddOn           = 0x0008,       // AddOn method for event
-               RemoveOn        = 0x0010,       // RemoveOn method for event
-               Fire            = 0x0020         // Fire method for event
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/MethodSpecification.cs b/mcs/class/Mono.Cecil/Mono.Cecil/MethodSpecification.cs
deleted file mode 100644 (file)
index 73b5c14..0000000
+++ /dev/null
@@ -1,103 +0,0 @@
-//
-// MethodSpecification.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public abstract class MethodSpecification : MethodReference {
-
-               readonly MethodReference method;
-
-               public MethodReference ElementMethod {
-                       get { return method; }
-               }
-
-               public override string Name {
-                       get { return method.Name; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override MethodCallingConvention CallingConvention {
-                       get { return method.CallingConvention; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override bool HasThis {
-                       get { return method.HasThis; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override bool ExplicitThis {
-                       get { return method.ExplicitThis; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override MethodReturnType MethodReturnType {
-                       get { return method.MethodReturnType; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override TypeReference DeclaringType {
-                       get { return method.DeclaringType; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override ModuleDefinition Module {
-                       get { return method.Module; }
-               }
-
-               public override bool HasParameters {
-                       get { return method.HasParameters; }
-               }
-
-               public override Collection<ParameterDefinition> Parameters {
-                       get { return method.Parameters; }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get { return method.ContainsGenericParameter; }
-               }
-
-               internal MethodSpecification (MethodReference method)
-               {
-                       if (method == null)
-                               throw new ArgumentNullException ("method");
-
-                       this.method = method;
-                       this.token = new MetadataToken (TokenType.MethodSpec);
-               }
-
-               public sealed override MethodReference GetElementMethod ()
-               {
-                       return method.GetElementMethod ();
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/Modifiers.cs b/mcs/class/Mono.Cecil/Mono.Cecil/Modifiers.cs
deleted file mode 100644 (file)
index ad31bc0..0000000
+++ /dev/null
@@ -1,137 +0,0 @@
-//
-// Modifiers.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using MD = Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public interface IModifierType {
-               TypeReference ModifierType { get; }
-               TypeReference ElementType { get; }
-       }
-
-       public sealed class OptionalModifierType : TypeSpecification, IModifierType {
-
-               TypeReference modifier_type;
-
-               public TypeReference ModifierType {
-                       get { return modifier_type; }
-                       set { modifier_type = value; }
-               }
-
-               public override string Name {
-                       get { return base.Name + Suffix; }
-               }
-
-               public override string FullName {
-                       get { return base.FullName + Suffix; }
-               }
-
-               string Suffix {
-                       get { return " modopt(" + modifier_type + ")"; }
-               }
-
-               public override bool IsValueType {
-                       get { return false; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override bool IsOptionalModifier {
-                       get { return true; }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get { return modifier_type.ContainsGenericParameter || base.ContainsGenericParameter; }
-               }
-
-               public OptionalModifierType (TypeReference modifierType, TypeReference type)
-                       : base (type)
-               {
-                       Mixin.CheckModifier (modifierType, type);
-                       this.modifier_type = modifierType;
-                       this.etype = MD.ElementType.CModOpt;
-               }
-       }
-
-       public sealed class RequiredModifierType : TypeSpecification, IModifierType {
-
-               TypeReference modifier_type;
-
-               public TypeReference ModifierType {
-                       get { return modifier_type; }
-                       set { modifier_type = value; }
-               }
-
-               public override string Name {
-                       get { return base.Name + Suffix; }
-               }
-
-               public override string FullName {
-                       get { return base.FullName + Suffix; }
-               }
-
-               string Suffix {
-                       get { return " modreq(" + modifier_type + ")"; }
-               }
-
-               public override bool IsValueType {
-                       get { return false; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override bool IsRequiredModifier {
-                       get { return true; }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get { return modifier_type.ContainsGenericParameter || base.ContainsGenericParameter; }
-               }
-
-               public RequiredModifierType (TypeReference modifierType, TypeReference type)
-                       : base (type)
-               {
-                       Mixin.CheckModifier (modifierType, type);
-                       this.modifier_type = modifierType;
-                       this.etype = MD.ElementType.CModReqD;
-               }
-
-       }
-
-       static partial class Mixin {
-
-               public static void CheckModifier (TypeReference modifierType, TypeReference type)
-               {
-                       if (modifierType == null)
-                               throw new ArgumentNullException ("modifierType");
-                       if (type == null)
-                               throw new ArgumentNullException ("type");
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ModuleDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ModuleDefinition.cs
deleted file mode 100644 (file)
index 0d137e0..0000000
+++ /dev/null
@@ -1,1025 +0,0 @@
-//
-// ModuleDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-using System.IO;
-using SR = System.Reflection;
-
-using Mono.Cecil.Cil;
-using Mono.Cecil.Metadata;
-using Mono.Cecil.PE;
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public enum ReadingMode {
-               Immediate = 1,
-               Deferred = 2,
-       }
-
-       public sealed class ReaderParameters {
-
-               ReadingMode reading_mode;
-               IAssemblyResolver assembly_resolver;
-               IMetadataResolver metadata_resolver;
-               Stream symbol_stream;
-               ISymbolReaderProvider symbol_reader_provider;
-               bool read_symbols;
-
-               public ReadingMode ReadingMode {
-                       get { return reading_mode; }
-                       set { reading_mode = value; }
-               }
-
-               public IAssemblyResolver AssemblyResolver {
-                       get { return assembly_resolver; }
-                       set { assembly_resolver = value; }
-               }
-
-               public IMetadataResolver MetadataResolver {
-                       get { return metadata_resolver; }
-                       set { metadata_resolver = value; }
-               }
-
-               public Stream SymbolStream {
-                       get { return symbol_stream; }
-                       set { symbol_stream = value; }
-               }
-
-               public ISymbolReaderProvider SymbolReaderProvider {
-                       get { return symbol_reader_provider; }
-                       set { symbol_reader_provider = value; }
-               }
-
-               public bool ReadSymbols {
-                       get { return read_symbols; }
-                       set { read_symbols = value; }
-               }
-
-               public ReaderParameters ()
-                       : this (ReadingMode.Deferred)
-               {
-               }
-
-               public ReaderParameters (ReadingMode readingMode)
-               {
-                       this.reading_mode = readingMode;
-               }
-       }
-
-#if !READ_ONLY
-
-       public sealed class ModuleParameters {
-
-               ModuleKind kind;
-               TargetRuntime runtime;
-               TargetArchitecture architecture;
-               IAssemblyResolver assembly_resolver;
-               IMetadataResolver metadata_resolver;
-
-               public ModuleKind Kind {
-                       get { return kind; }
-                       set { kind = value; }
-               }
-
-               public TargetRuntime Runtime {
-                       get { return runtime; }
-                       set { runtime = value; }
-               }
-
-               public TargetArchitecture Architecture {
-                       get { return architecture; }
-                       set { architecture = value; }
-               }
-
-               public IAssemblyResolver AssemblyResolver {
-                       get { return assembly_resolver; }
-                       set { assembly_resolver = value; }
-               }
-
-               public IMetadataResolver MetadataResolver {
-                       get { return metadata_resolver; }
-                       set { metadata_resolver = value; }
-               }
-
-               public ModuleParameters ()
-               {
-                       this.kind = ModuleKind.Dll;
-                       this.runtime = GetCurrentRuntime ();
-                       this.architecture = TargetArchitecture.I386;
-               }
-
-               static TargetRuntime GetCurrentRuntime ()
-               {
-#if !CF
-                       return typeof (object).Assembly.ImageRuntimeVersion.ParseRuntime ();
-#else
-                       var corlib_version = typeof (object).Assembly.GetName ().Version;
-                       switch (corlib_version.Major) {
-                       case 1:
-                               return corlib_version.Minor == 0
-                                       ? TargetRuntime.Net_1_0
-                                       : TargetRuntime.Net_1_1;
-                       case 2:
-                               return TargetRuntime.Net_2_0;
-                       case 4:
-                               return TargetRuntime.Net_4_0;
-                       default:
-                               throw new NotSupportedException ();
-                       }
-#endif
-               }
-       }
-
-       public sealed class WriterParameters {
-
-               Stream symbol_stream;
-               ISymbolWriterProvider symbol_writer_provider;
-               bool write_symbols;
-#if !SILVERLIGHT && !CF
-               SR.StrongNameKeyPair key_pair;
-#endif
-               public Stream SymbolStream {
-                       get { return symbol_stream; }
-                       set { symbol_stream = value; }
-               }
-
-               public ISymbolWriterProvider SymbolWriterProvider {
-                       get { return symbol_writer_provider; }
-                       set { symbol_writer_provider = value; }
-               }
-
-               public bool WriteSymbols {
-                       get { return write_symbols; }
-                       set { write_symbols = value; }
-               }
-#if !SILVERLIGHT && !CF
-               public SR.StrongNameKeyPair StrongNameKeyPair {
-                       get { return key_pair; }
-                       set { key_pair = value; }
-               }
-#endif
-       }
-
-#endif
-
-       public sealed class ModuleDefinition : ModuleReference, ICustomAttributeProvider {
-
-               internal Image Image;
-               internal MetadataSystem MetadataSystem;
-               internal ReadingMode ReadingMode;
-               internal ISymbolReaderProvider SymbolReaderProvider;
-               internal ISymbolReader SymbolReader;
-
-               internal IAssemblyResolver assembly_resolver;
-               internal IMetadataResolver metadata_resolver;
-               internal TypeSystem type_system;
-
-               readonly MetadataReader reader;
-               readonly string fq_name;
-
-               internal ModuleKind kind;
-               TargetRuntime runtime;
-               TargetArchitecture architecture;
-               ModuleAttributes attributes;
-               Guid mvid;
-
-               internal AssemblyDefinition assembly;
-               MethodDefinition entry_point;
-
-#if !READ_ONLY
-               MetadataImporter importer;
-#endif
-               Collection<CustomAttribute> custom_attributes;
-               Collection<AssemblyNameReference> references;
-               Collection<ModuleReference> modules;
-               Collection<Resource> resources;
-               Collection<ExportedType> exported_types;
-               TypeDefinitionCollection types;
-
-               public bool IsMain {
-                       get { return kind != ModuleKind.NetModule; }
-               }
-
-               public ModuleKind Kind {
-                       get { return kind; }
-                       set { kind = value; }
-               }
-
-               public TargetRuntime Runtime {
-                       get { return runtime; }
-                       set { runtime = value; }
-               }
-
-               public TargetArchitecture Architecture {
-                       get { return architecture; }
-                       set { architecture = value; }
-               }
-
-               public ModuleAttributes Attributes {
-                       get { return attributes; }
-                       set { attributes = value; }
-               }
-
-               public string FullyQualifiedName {
-                       get { return fq_name; }
-               }
-
-               public Guid Mvid {
-                       get { return mvid; }
-                       set { mvid = value; }
-               }
-
-               internal bool HasImage {
-                       get { return Image != null; }
-               }
-
-               public bool HasSymbols {
-                       get { return SymbolReader != null; }
-               }
-
-               public override MetadataScopeType MetadataScopeType {
-                       get { return MetadataScopeType.ModuleDefinition; }
-               }
-
-               public AssemblyDefinition Assembly {
-                       get { return assembly; }
-               }
-
-#if !READ_ONLY
-               internal MetadataImporter MetadataImporter {
-                       get { return importer ?? (importer = new MetadataImporter (this)); }
-               }
-#endif
-
-               public IAssemblyResolver AssemblyResolver {
-                       get { return assembly_resolver; }
-               }
-
-               public IMetadataResolver MetadataResolver {
-                       get { return metadata_resolver ?? (metadata_resolver = new MetadataResolver (assembly_resolver)); }
-               }
-
-               public TypeSystem TypeSystem {
-                       get { return type_system ?? (type_system = TypeSystem.CreateTypeSystem (this)); }
-               }
-
-               public bool HasAssemblyReferences {
-                       get {
-                               if (references != null)
-                                       return references.Count > 0;
-
-                               return HasImage && Image.HasTable (Table.AssemblyRef);
-                       }
-               }
-
-               public Collection<AssemblyNameReference> AssemblyReferences {
-                       get {
-                               if (references != null)
-                                       return references;
-
-                               if (HasImage)
-                                       return references = Read (this, (_, reader) => reader.ReadAssemblyReferences ());
-
-                               return references = new Collection<AssemblyNameReference> ();
-                       }
-               }
-
-               public bool HasModuleReferences {
-                       get {
-                               if (modules != null)
-                                       return modules.Count > 0;
-
-                               return HasImage && Image.HasTable (Table.ModuleRef);
-                       }
-               }
-
-               public Collection<ModuleReference> ModuleReferences {
-                       get {
-                               if (modules != null)
-                                       return modules;
-
-                               if (HasImage)
-                                       return modules = Read (this, (_, reader) => reader.ReadModuleReferences ());
-
-                               return modules = new Collection<ModuleReference> ();
-                       }
-               }
-
-               public bool HasResources {
-                       get {
-                               if (resources != null)
-                                       return resources.Count > 0;
-
-                               if (HasImage)
-                                       return Image.HasTable (Table.ManifestResource) || Read (this, (_, reader) => reader.HasFileResource ());
-
-                               return false;
-                       }
-               }
-
-               public Collection<Resource> Resources {
-                       get {
-                               if (resources != null)
-                                       return resources;
-
-                               if (HasImage)
-                                       return resources = Read (this, (_, reader) => reader.ReadResources ());
-
-                               return resources = new Collection<Resource> ();
-                       }
-               }
-
-               public bool HasCustomAttributes {
-                       get {
-                               if (custom_attributes != null)
-                                       return custom_attributes.Count > 0;
-
-                               return this.GetHasCustomAttributes (this);
-                       }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return custom_attributes ?? (custom_attributes = this.GetCustomAttributes (this)); }
-               }
-
-               public bool HasTypes {
-                       get {
-                               if (types != null)
-                                       return types.Count > 0;
-
-                               return HasImage && Image.HasTable (Table.TypeDef);
-                       }
-               }
-
-               public Collection<TypeDefinition> Types {
-                       get {
-                               if (types != null)
-                                       return types;
-
-                               if (HasImage)
-                                       return types = Read (this, (_, reader) => reader.ReadTypes ());
-
-                               return types = new TypeDefinitionCollection (this);
-                       }
-               }
-
-               public bool HasExportedTypes {
-                       get {
-                               if (exported_types != null)
-                                       return exported_types.Count > 0;
-
-                               return HasImage && Image.HasTable (Table.ExportedType);
-                       }
-               }
-
-               public Collection<ExportedType> ExportedTypes {
-                       get {
-                               if (exported_types != null)
-                                       return exported_types;
-
-                               if (HasImage)
-                                       return exported_types = Read (this, (_, reader) => reader.ReadExportedTypes ());
-
-                               return exported_types = new Collection<ExportedType> ();
-                       }
-               }
-
-               public MethodDefinition EntryPoint {
-                       get {
-                               if (entry_point != null)
-                                       return entry_point;
-
-                               if (HasImage)
-                                       return entry_point = Read (this, (_, reader) => reader.ReadEntryPoint ());
-
-                               return entry_point = null;
-                       }
-                       set { entry_point = value; }
-               }
-
-               internal ModuleDefinition ()
-               {
-                       this.MetadataSystem = new MetadataSystem ();
-                       this.token = new MetadataToken (TokenType.Module, 1);
-                       this.assembly_resolver = GlobalAssemblyResolver.Instance;
-               }
-
-               internal ModuleDefinition (Image image)
-                       : this ()
-               {
-                       this.Image = image;
-                       this.kind = image.Kind;
-                       this.runtime = image.Runtime;
-                       this.architecture = image.Architecture;
-                       this.attributes = image.Attributes;
-                       this.fq_name = image.FileName;
-
-                       this.reader = new MetadataReader (this);
-               }
-
-               public bool HasTypeReference (string fullName)
-               {
-                       return HasTypeReference (string.Empty, fullName);
-               }
-
-               public bool HasTypeReference (string scope, string fullName)
-               {
-                       CheckFullName (fullName);
-
-                       if (!HasImage)
-                               return false;
-
-                       return GetTypeReference (scope, fullName) != null;
-               }
-
-               public bool TryGetTypeReference (string fullName, out TypeReference type)
-               {
-                       return TryGetTypeReference (string.Empty, fullName, out type);
-               }
-
-               public bool TryGetTypeReference (string scope, string fullName, out TypeReference type)
-               {
-                       CheckFullName (fullName);
-
-                       if (!HasImage) {
-                               type = null;
-                               return false;
-                       }
-
-                       return (type = GetTypeReference (scope, fullName)) != null;
-               }
-
-               TypeReference GetTypeReference (string scope, string fullname)
-               {
-                       return Read (new Row<string, string> (scope, fullname), (row, reader) => reader.GetTypeReference (row.Col1, row.Col2));
-               }
-
-               public IEnumerable<TypeReference> GetTypeReferences ()
-               {
-                       if (!HasImage)
-                               return Empty<TypeReference>.Array;
-
-                       return Read (this, (_, reader) => reader.GetTypeReferences ());
-               }
-
-               public IEnumerable<MemberReference> GetMemberReferences ()
-               {
-                       if (!HasImage)
-                               return Empty<MemberReference>.Array;
-
-                       return Read (this, (_, reader) => reader.GetMemberReferences ());
-               }
-
-               public TypeReference GetType (string fullName, bool runtimeName)
-               {
-                       return runtimeName
-                               ? TypeParser.ParseType (this, fullName)
-                               : GetType (fullName);
-               }
-
-               public TypeDefinition GetType (string fullName)
-               {
-                       CheckFullName (fullName);
-
-                       var position = fullName.IndexOf ('/');
-                       if (position > 0)
-                               return GetNestedType (fullName);
-
-                       return ((TypeDefinitionCollection) this.Types).GetType (fullName);
-               }
-
-               public TypeDefinition GetType (string @namespace, string name)
-               {
-                       Mixin.CheckName (name);
-
-                       return ((TypeDefinitionCollection) this.Types).GetType (@namespace ?? string.Empty, name);
-               }
-
-               public IEnumerable<TypeDefinition> GetTypes ()
-               {
-                       return GetTypes (Types);
-               }
-
-               static IEnumerable<TypeDefinition> GetTypes (Collection<TypeDefinition> types)
-               {
-                       for (int i = 0; i < types.Count; i++) {
-                               var type = types [i];
-
-                               yield return type;
-
-                               if (!type.HasNestedTypes)
-                                       continue;
-
-                               foreach (var nested in GetTypes (type.NestedTypes))
-                                       yield return nested;
-                       }
-               }
-
-               static void CheckFullName (string fullName)
-               {
-                       if (fullName == null)
-                               throw new ArgumentNullException ("fullName");
-                       if (fullName.Length == 0)
-                               throw new ArgumentException ();
-               }
-
-               TypeDefinition GetNestedType (string fullname)
-               {
-                       var names = fullname.Split ('/');
-                       var type = GetType (names [0]);
-
-                       if (type == null)
-                               return null;
-
-                       for (int i = 1; i < names.Length; i++) {
-                               var nested_type = type.GetNestedType (names [i]);
-                               if (nested_type == null)
-                                       return null;
-
-                               type = nested_type;
-                       }
-
-                       return type;
-               }
-
-               internal FieldDefinition Resolve (FieldReference field)
-               {
-                       return MetadataResolver.Resolve (field);
-               }
-
-               internal MethodDefinition Resolve (MethodReference method)
-               {
-                       return MetadataResolver.Resolve (method);
-               }
-
-               internal TypeDefinition Resolve (TypeReference type)
-               {
-                       return MetadataResolver.Resolve (type);
-               }
-
-#if !READ_ONLY
-
-               static void CheckType (object type)
-               {
-                       if (type == null)
-                               throw new ArgumentNullException ("type");
-               }
-
-               static void CheckField (object field)
-               {
-                       if (field == null)
-                               throw new ArgumentNullException ("field");
-               }
-
-               static void CheckMethod (object method)
-               {
-                       if (method == null)
-                               throw new ArgumentNullException ("method");
-               }
-
-               static void CheckContext (IGenericParameterProvider context, ModuleDefinition module)
-               {
-                       if (context == null)
-                               return;
-
-                       if (context.Module != module)
-                               throw new ArgumentException ();
-               }
-
-#if !CF
-               public TypeReference Import (Type type)
-               {
-                       CheckType (type);
-
-                       return MetadataImporter.ImportType (type, null, ImportGenericKind.Definition);
-               }
-
-               public TypeReference Import (Type type, TypeReference context)
-               {
-                       return Import (type, (IGenericParameterProvider) context);
-               }
-
-               public TypeReference Import (Type type, MethodReference context)
-               {
-                       return Import (type, (IGenericParameterProvider) context);
-               }
-
-               TypeReference Import (Type type, IGenericParameterProvider context)
-               {
-                       CheckType (type);
-                       CheckContext (context, this);
-
-                       return MetadataImporter.ImportType (
-                               type,
-                               (IGenericContext) context,
-                               context != null
-                                       ? ImportGenericKind.Open
-                                       : ImportGenericKind.Definition);
-               }
-
-               public FieldReference Import (SR.FieldInfo field)
-               {
-                       CheckField (field);
-
-                       return MetadataImporter.ImportField (field, null);
-               }
-
-               public FieldReference Import (SR.FieldInfo field, TypeReference context)
-               {
-                       return Import (field, (IGenericParameterProvider) context);
-               }
-
-               public FieldReference Import (SR.FieldInfo field, MethodReference context)
-               {
-                       return Import (field, (IGenericParameterProvider) context);
-               }
-
-               FieldReference Import (SR.FieldInfo field, IGenericParameterProvider context)
-               {
-                       CheckField (field);
-                       CheckContext (context, this);
-
-                       return MetadataImporter.ImportField (field, (IGenericContext) context);
-               }
-
-               public MethodReference Import (SR.MethodBase method)
-               {
-                       CheckMethod (method);
-
-                       return MetadataImporter.ImportMethod (method, null, ImportGenericKind.Definition);
-               }
-
-               public MethodReference Import (SR.MethodBase method, TypeReference context)
-               {
-                       return Import (method, (IGenericParameterProvider) context);
-               }
-
-               public MethodReference Import (SR.MethodBase method, MethodReference context)
-               {
-                       return Import (method, (IGenericParameterProvider) context);
-               }
-
-               MethodReference Import (SR.MethodBase method, IGenericParameterProvider context)
-               {
-                       CheckMethod (method);
-                       CheckContext (context, this);
-
-                       return MetadataImporter.ImportMethod (method,
-                               (IGenericContext) context,
-                               context != null
-                                       ? ImportGenericKind.Open
-                                       : ImportGenericKind.Definition);
-               }
-#endif
-
-               public TypeReference Import (TypeReference type)
-               {
-                       CheckType (type);
-
-                       if (type.Module == this)
-                               return type;
-
-                       return MetadataImporter.ImportType (type, null);
-               }
-
-               public TypeReference Import (TypeReference type, TypeReference context)
-               {
-                       return Import (type, (IGenericParameterProvider) context);
-               }
-
-               public TypeReference Import (TypeReference type, MethodReference context)
-               {
-                       return Import (type, (IGenericParameterProvider) context);
-               }
-
-               TypeReference Import (TypeReference type, IGenericParameterProvider context)
-               {
-                       CheckType (type);
-
-                       if (type.Module == this)
-                               return type;
-
-                       CheckContext (context, this);
-
-                       return MetadataImporter.ImportType (type, (IGenericContext) context);
-               }
-
-               public FieldReference Import (FieldReference field)
-               {
-                       CheckField (field);
-
-                       if (field.Module == this)
-                               return field;
-
-                       return MetadataImporter.ImportField (field, null);
-               }
-
-               public FieldReference Import (FieldReference field, TypeReference context)
-               {
-                       return Import (field, (IGenericParameterProvider) context);
-               }
-
-               public FieldReference Import (FieldReference field, MethodReference context)
-               {
-                       return Import (field, (IGenericParameterProvider) context);
-               }
-
-               FieldReference Import (FieldReference field, IGenericParameterProvider context)
-               {
-                       CheckField (field);
-
-                       if (field.Module == this)
-                               return field;
-
-                       CheckContext (context, this);
-
-                       return MetadataImporter.ImportField (field, (IGenericContext) context);
-               }
-
-               public MethodReference Import (MethodReference method)
-               {
-                       CheckMethod (method);
-
-                       if (method.Module == this)
-                               return method;
-
-                       return MetadataImporter.ImportMethod (method, null);
-               }
-
-               public MethodReference Import (MethodReference method, TypeReference context)
-               {
-                       return Import (method, (IGenericParameterProvider) context);
-               }
-
-               public MethodReference Import (MethodReference method, MethodReference context)
-               {
-                       return Import (method, (IGenericParameterProvider) context);
-               }
-
-               MethodReference Import (MethodReference method, IGenericParameterProvider context)
-               {
-                       CheckMethod (method);
-
-                       if (method.Module == this)
-                               return method;
-
-                       CheckContext (context, this);
-
-                       return MetadataImporter.ImportMethod (method, (IGenericContext) context);
-               }
-
-#endif
-
-               public IMetadataTokenProvider LookupToken (int token)
-               {
-                       return LookupToken (new MetadataToken ((uint) token));
-               }
-
-               public IMetadataTokenProvider LookupToken (MetadataToken token)
-               {
-                       return Read (token, (t, reader) => reader.LookupToken (t));
-               }
-
-               internal TRet Read<TItem, TRet> (TItem item, Func<TItem, MetadataReader, TRet> read)
-               {
-                       var position = reader.position;
-                       var context = reader.context;
-
-                       var ret = read (item, reader);
-
-                       reader.position = position;
-                       reader.context = context;
-
-                       return ret;
-               }
-
-               void ProcessDebugHeader ()
-               {
-                       if (Image == null || Image.Debug.IsZero)
-                               return;
-
-                       byte [] header;
-                       var directory = Image.GetDebugHeader (out header);
-
-                       if (!SymbolReader.ProcessDebugHeader (directory, header))
-                               throw new InvalidOperationException ();
-               }
-
-#if !READ_ONLY
-
-               public static ModuleDefinition CreateModule (string name, ModuleKind kind)
-               {
-                       return CreateModule (name, new ModuleParameters { Kind = kind });
-               }
-
-               public static ModuleDefinition CreateModule (string name, ModuleParameters parameters)
-               {
-                       Mixin.CheckName (name);
-                       Mixin.CheckParameters (parameters);
-
-                       var module = new ModuleDefinition {
-                               Name = name,
-                               kind = parameters.Kind,
-                               runtime = parameters.Runtime,
-                               architecture = parameters.Architecture,
-                               mvid = Guid.NewGuid (),
-                               Attributes = ModuleAttributes.ILOnly,
-                       };
-
-                       if (parameters.AssemblyResolver != null)
-                               module.assembly_resolver = parameters.AssemblyResolver;
-
-                       if (parameters.MetadataResolver != null)
-                               module.metadata_resolver = parameters.MetadataResolver;
-
-                       if (parameters.Kind != ModuleKind.NetModule) {
-                               var assembly = new AssemblyDefinition ();
-                               module.assembly = assembly;
-                               module.assembly.Name = CreateAssemblyName (name);
-                               assembly.main_module = module;
-                       }
-
-                       module.Types.Add (new TypeDefinition (string.Empty, "<Module>", TypeAttributes.NotPublic));
-
-                       return module;
-               }
-
-               static AssemblyNameDefinition CreateAssemblyName (string name)
-               {
-                       if (name.EndsWith (".dll") || name.EndsWith (".exe"))
-                               name = name.Substring (0, name.Length - 4);
-
-                       return new AssemblyNameDefinition (name, new Version (0, 0, 0, 0));
-               }
-
-#endif
-
-               public void ReadSymbols ()
-               {
-                       if (string.IsNullOrEmpty (fq_name))
-                               throw new InvalidOperationException ();
-
-                       var provider = SymbolProvider.GetPlatformReaderProvider ();
-                       if (provider == null)
-                               throw new InvalidOperationException ();
-
-                       ReadSymbols (provider.GetSymbolReader (this, fq_name));
-               }
-
-               public void ReadSymbols (ISymbolReader reader)
-               {
-                       if (reader == null)
-                               throw new ArgumentNullException ("reader");
-
-                       SymbolReader = reader;
-
-                       ProcessDebugHeader ();
-               }
-
-               public static ModuleDefinition ReadModule (string fileName)
-               {
-                       return ReadModule (fileName, new ReaderParameters (ReadingMode.Deferred));
-               }
-
-               public static ModuleDefinition ReadModule (Stream stream)
-               {
-                       return ReadModule (stream, new ReaderParameters (ReadingMode.Deferred));
-               }
-
-               public static ModuleDefinition ReadModule (string fileName, ReaderParameters parameters)
-               {
-                       using (var stream = GetFileStream (fileName, FileMode.Open, FileAccess.Read, FileShare.Read)) {
-                               return ReadModule (stream, parameters);
-                       }
-               }
-
-               static void CheckStream (object stream)
-               {
-                       if (stream == null)
-                               throw new ArgumentNullException ("stream");
-               }
-
-               public static ModuleDefinition ReadModule (Stream stream, ReaderParameters parameters)
-               {
-                       CheckStream (stream);
-                       if (!stream.CanRead || !stream.CanSeek)
-                               throw new ArgumentException ();
-                       Mixin.CheckParameters (parameters);
-
-                       return ModuleReader.CreateModuleFrom (
-                               ImageReader.ReadImageFrom (stream),
-                               parameters);
-               }
-
-               static Stream GetFileStream (string fileName, FileMode mode, FileAccess access, FileShare share)
-               {
-                       if (fileName == null)
-                               throw new ArgumentNullException ("fileName");
-                       if (fileName.Length == 0)
-                               throw new ArgumentException ();
-
-                       return new FileStream (fileName, mode, access, share);
-               }
-
-#if !READ_ONLY
-
-               public void Write (string fileName)
-               {
-                       Write (fileName, new WriterParameters ());
-               }
-
-               public void Write (Stream stream)
-               {
-                       Write (stream, new WriterParameters ());
-               }
-
-               public void Write (string fileName, WriterParameters parameters)
-               {
-                       using (var stream = GetFileStream (fileName, FileMode.Create, FileAccess.ReadWrite, FileShare.None)) {
-                               Write (stream, parameters);
-                       }
-               }
-
-               public void Write (Stream stream, WriterParameters parameters)
-               {
-                       CheckStream (stream);
-                       if (!stream.CanWrite || !stream.CanSeek)
-                               throw new ArgumentException ();
-                       Mixin.CheckParameters (parameters);
-
-                       ModuleWriter.WriteModuleTo (this, stream, parameters);
-               }
-
-#endif
-
-       }
-
-       static partial class Mixin {
-
-               public static void CheckParameters (object parameters)
-               {
-                       if (parameters == null)
-                               throw new ArgumentNullException ("parameters");
-               }
-
-               public static bool HasImage (this ModuleDefinition self)
-               {
-                       return self != null && self.HasImage;
-               }
-
-               public static string GetFullyQualifiedName (this Stream self)
-               {
-#if !SILVERLIGHT
-                       var file_stream = self as FileStream;
-                       if (file_stream == null)
-                               return string.Empty;
-
-                       return Path.GetFullPath (file_stream.Name);
-#else
-                       return string.Empty;
-#endif
-               }
-
-               public static TargetRuntime ParseRuntime (this string self)
-               {
-                       switch (self [1]) {
-                       case '1':
-                               return self [3] == '0'
-                                       ? TargetRuntime.Net_1_0
-                                       : TargetRuntime.Net_1_1;
-                       case '2':
-                               return TargetRuntime.Net_2_0;
-                       case '4':
-                       default:
-                               return TargetRuntime.Net_4_0;
-                       }
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ModuleKind.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ModuleKind.cs
deleted file mode 100644 (file)
index e5f7458..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-//
-// ModuleKind.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       public enum ModuleKind {
-               Dll,
-               Console,
-               Windows,
-               NetModule,
-       }
-
-       public enum TargetArchitecture {
-               I386,
-               AMD64,
-               IA64,
-       }
-
-       [Flags]
-       public enum ModuleAttributes {
-               ILOnly = 1,
-               Required32Bit = 2,
-               StrongNameSigned = 8,
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ModuleReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ModuleReference.cs
deleted file mode 100644 (file)
index 3934b3c..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-//
-// ModuleReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public class ModuleReference : IMetadataScope {
-
-               string name;
-
-               internal MetadataToken token;
-
-               public string Name {
-                       get { return name; }
-                       set { name = value; }
-               }
-
-               public virtual MetadataScopeType MetadataScopeType {
-                       get { return MetadataScopeType.ModuleReference; }
-               }
-
-               public MetadataToken MetadataToken {
-                       get { return token; }
-                       set { token = value; }
-               }
-
-               internal ModuleReference ()
-               {
-                       this.token = new MetadataToken (TokenType.ModuleRef);
-               }
-
-               public ModuleReference (string name)
-                       : this ()
-               {
-                       this.name = name;
-               }
-
-               public override string ToString ()
-               {
-                       return name;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/NativeType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/NativeType.cs
deleted file mode 100644 (file)
index 88da980..0000000
+++ /dev/null
@@ -1,73 +0,0 @@
-//
-// NativeType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public enum NativeType {
-               None = 0x66,
-
-               Boolean = 0x02,
-               I1 = 0x03,
-               U1 = 0x04,
-               I2 = 0x05,
-               U2 = 0x06,
-               I4 = 0x07,
-               U4 = 0x08,
-               I8 = 0x09,
-               U8 = 0x0a,
-               R4 = 0x0b,
-               R8 = 0x0c,
-               LPStr = 0x14,
-               Int = 0x1f,
-               UInt = 0x20,
-               Func = 0x26,
-               Array = 0x2a,
-
-               // Msft specific
-               Currency = 0x0f,
-               BStr = 0x13,
-               LPWStr = 0x15,
-               LPTStr = 0x16,
-               FixedSysString = 0x17,
-               IUnknown = 0x19,
-               IDispatch = 0x1a,
-               Struct = 0x1b,
-               IntF = 0x1c,
-               SafeArray = 0x1d,
-               FixedArray = 0x1e,
-               ByValStr = 0x22,
-               ANSIBStr = 0x23,
-               TBStr = 0x24,
-               VariantBool = 0x25,
-               ASAny = 0x28,
-               LPStruct = 0x2b,
-               CustomMarshaler = 0x2c,
-               Error = 0x2d,
-               Max = 0x50
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/PInvokeAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/PInvokeAttributes.cs
deleted file mode 100644 (file)
index bb36838..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-//
-// PInvokeAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum PInvokeAttributes : ushort {
-               NoMangle                        = 0x0001,       // PInvoke is to use the member name as specified
-
-               // Character set
-               CharSetMask                     = 0x0006,
-               CharSetNotSpec          = 0x0000,
-               CharSetAnsi                     = 0x0002,
-               CharSetUnicode          = 0x0004,
-               CharSetAuto                     = 0x0006,
-
-               SupportsLastError       = 0x0040,       // Information about target function. Not relevant for fields
-
-               // Calling convetion
-               CallConvMask            = 0x0700,
-               CallConvWinapi          = 0x0100,
-               CallConvCdecl           = 0x0200,
-               CallConvStdCall         = 0x0300,
-               CallConvThiscall        = 0x0400,
-               CallConvFastcall        = 0x0500,
-
-               BestFitMask                     = 0x0030,
-               BestFitEnabled          = 0x0010,
-               BestFitDisabled         = 0x0020,
-
-               ThrowOnUnmappableCharMask = 0x3000,
-               ThrowOnUnmappableCharEnabled = 0x1000,
-               ThrowOnUnmappableCharDisabled = 0x2000,
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/PInvokeInfo.cs b/mcs/class/Mono.Cecil/Mono.Cecil/PInvokeInfo.cs
deleted file mode 100644 (file)
index cfd817c..0000000
+++ /dev/null
@@ -1,138 +0,0 @@
-//
-// PInvokeInfo.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public sealed class PInvokeInfo {
-
-               ushort attributes;
-               string entry_point;
-               ModuleReference module;
-
-               public PInvokeAttributes Attributes {
-                       get { return (PInvokeAttributes) attributes; }
-                       set { attributes = (ushort) value; }
-               }
-
-               public string EntryPoint {
-                       get { return entry_point; }
-                       set { entry_point = value; }
-               }
-
-               public ModuleReference Module {
-                       get { return module; }
-                       set { module = value; }
-               }
-
-               #region PInvokeAttributes
-
-               public bool IsNoMangle {
-                       get { return attributes.GetAttributes ((ushort) PInvokeAttributes.NoMangle); }
-                       set { attributes = attributes.SetAttributes ((ushort) PInvokeAttributes.NoMangle, value); }
-               }
-
-               public bool IsCharSetNotSpec {
-                       get { return attributes.GetMaskedAttributes((ushort) PInvokeAttributes.CharSetMask, (ushort) PInvokeAttributes.CharSetNotSpec); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.CharSetMask, (ushort) PInvokeAttributes.CharSetNotSpec, value); }
-               }
-
-               public bool IsCharSetAnsi {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.CharSetMask, (ushort) PInvokeAttributes.CharSetAnsi); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.CharSetMask, (ushort) PInvokeAttributes.CharSetAnsi, value); }
-               }
-
-               public bool IsCharSetUnicode {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.CharSetMask, (ushort) PInvokeAttributes.CharSetUnicode); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.CharSetMask, (ushort) PInvokeAttributes.CharSetUnicode, value); }
-               }
-
-               public bool IsCharSetAuto {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.CharSetMask, (ushort) PInvokeAttributes.CharSetAuto); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.CharSetMask, (ushort) PInvokeAttributes.CharSetAuto, value); }
-               }
-
-               public bool SupportsLastError {
-                       get { return attributes.GetAttributes ((ushort) PInvokeAttributes.SupportsLastError); }
-                       set { attributes = attributes.SetAttributes ((ushort) PInvokeAttributes.SupportsLastError, value); }
-               }
-
-               public bool IsCallConvWinapi {
-                       get { return attributes.GetMaskedAttributes((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvWinapi); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvWinapi, value); }
-               }
-
-               public bool IsCallConvCdecl {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvCdecl); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvCdecl, value); }
-               }
-
-               public bool IsCallConvStdCall {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvStdCall); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvStdCall, value); }
-               }
-
-               public bool IsCallConvThiscall {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvThiscall); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvThiscall, value); }
-               }
-
-               public bool IsCallConvFastcall {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvFastcall); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.CallConvMask, (ushort) PInvokeAttributes.CallConvFastcall, value); }
-               }
-
-               public bool IsBestFitEnabled {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.BestFitMask, (ushort) PInvokeAttributes.BestFitEnabled); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.BestFitMask, (ushort) PInvokeAttributes.BestFitEnabled, value); }
-               }
-
-               public bool IsBestFitDisabled {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.BestFitMask, (ushort) PInvokeAttributes.BestFitDisabled); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.BestFitMask, (ushort) PInvokeAttributes.BestFitDisabled, value); }
-               }
-
-               public bool IsThrowOnUnmappableCharEnabled {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.ThrowOnUnmappableCharMask, (ushort) PInvokeAttributes.ThrowOnUnmappableCharEnabled); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.ThrowOnUnmappableCharMask, (ushort) PInvokeAttributes.ThrowOnUnmappableCharEnabled, value); }
-               }
-
-               public bool IsThrowOnUnmappableCharDisabled {
-                       get { return attributes.GetMaskedAttributes ((ushort) PInvokeAttributes.ThrowOnUnmappableCharMask, (ushort) PInvokeAttributes.ThrowOnUnmappableCharDisabled); }
-                       set { attributes = attributes.SetMaskedAttributes ((ushort) PInvokeAttributes.ThrowOnUnmappableCharMask, (ushort) PInvokeAttributes.ThrowOnUnmappableCharDisabled, value); }
-               }
-
-               #endregion
-
-               public PInvokeInfo (PInvokeAttributes attributes, string entryPoint, ModuleReference module)
-               {
-                       this.attributes = (ushort) attributes;
-                       this.entry_point = entryPoint;
-                       this.module = module;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ParameterAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ParameterAttributes.cs
deleted file mode 100644 (file)
index e0bc825..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-//
-// ParameterAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum ParameterAttributes : ushort {
-               None                            = 0x0000,
-               In                                      = 0x0001,       // Param is [In]
-               Out                                     = 0x0002,       // Param is [Out]
-               Lcid                            = 0x0004,
-               Retval                          = 0x0008,
-               Optional                        = 0x0010,       // Param is optional
-               HasDefault                      = 0x1000,       // Param has default value
-               HasFieldMarshal         = 0x2000,       // Param has field marshal
-               Unused                          = 0xcfe0         // Reserved: shall be zero in a conforming implementation
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ParameterDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ParameterDefinition.cs
deleted file mode 100644 (file)
index 8902615..0000000
+++ /dev/null
@@ -1,166 +0,0 @@
-//
-// ParameterDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public sealed class ParameterDefinition : ParameterReference, ICustomAttributeProvider, IConstantProvider, IMarshalInfoProvider {
-
-               ushort attributes;
-
-               internal IMethodSignature method;
-
-               object constant = Mixin.NotResolved;
-               Collection<CustomAttribute> custom_attributes;
-               MarshalInfo marshal_info;
-
-               public ParameterAttributes Attributes {
-                       get { return (ParameterAttributes) attributes; }
-                       set { attributes = (ushort) value; }
-               }
-
-               public IMethodSignature Method {
-                       get { return method; }
-               }
-
-               public int Sequence {
-                       get {
-                               if (method == null)
-                                       return -1;
-
-                               return method.HasThis ? index + 1 : index;
-                       }
-               }
-
-               public bool HasConstant {
-                       get {
-                               ResolveConstant ();
-
-                               return constant != Mixin.NoValue;
-                       }
-                       set { if (!value) constant = Mixin.NoValue; }
-               }
-
-               public object Constant {
-                       get { return HasConstant ? constant : null;     }
-                       set { constant = value; }
-               }
-
-               void ResolveConstant ()
-               {
-                       if (constant != Mixin.NotResolved)
-                               return;
-
-                       this.ResolveConstant (ref constant, parameter_type.Module);
-               }
-
-               public bool HasCustomAttributes {
-                       get {
-                               if (custom_attributes != null)
-                                       return custom_attributes.Count > 0;
-
-                               return this.GetHasCustomAttributes (parameter_type.Module);
-                       }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return custom_attributes ?? (custom_attributes = this.GetCustomAttributes (parameter_type.Module)); }
-               }
-
-               public bool HasMarshalInfo {
-                       get {
-                               if (marshal_info != null)
-                                       return true;
-
-                               return this.GetHasMarshalInfo (parameter_type.Module);
-                       }
-               }
-
-               public MarshalInfo MarshalInfo {
-                       get { return marshal_info ?? (marshal_info = this.GetMarshalInfo (parameter_type.Module)); }
-                       set { marshal_info = value; }
-               }
-
-               #region ParameterAttributes
-
-               public bool IsIn {
-                       get { return attributes.GetAttributes ((ushort) ParameterAttributes.In); }
-                       set { attributes = attributes.SetAttributes ((ushort) ParameterAttributes.In, value); }
-               }
-
-               public bool IsOut {
-                       get { return attributes.GetAttributes ((ushort) ParameterAttributes.Out); }
-                       set { attributes = attributes.SetAttributes ((ushort) ParameterAttributes.Out, value); }
-               }
-
-               public bool IsLcid {
-                       get { return attributes.GetAttributes ((ushort) ParameterAttributes.Lcid); }
-                       set { attributes = attributes.SetAttributes ((ushort) ParameterAttributes.Lcid, value); }
-               }
-
-               public bool IsReturnValue {
-                       get { return attributes.GetAttributes ((ushort) ParameterAttributes.Retval); }
-                       set { attributes = attributes.SetAttributes ((ushort) ParameterAttributes.Retval, value); }
-               }
-
-               public bool IsOptional {
-                       get { return attributes.GetAttributes ((ushort) ParameterAttributes.Optional); }
-                       set { attributes = attributes.SetAttributes ((ushort) ParameterAttributes.Optional, value); }
-               }
-
-               public bool HasDefault {
-                       get { return attributes.GetAttributes ((ushort) ParameterAttributes.HasDefault); }
-                       set { attributes = attributes.SetAttributes ((ushort) ParameterAttributes.HasDefault, value); }
-               }
-
-               public bool HasFieldMarshal {
-                       get { return attributes.GetAttributes ((ushort) ParameterAttributes.HasFieldMarshal); }
-                       set { attributes = attributes.SetAttributes ((ushort) ParameterAttributes.HasFieldMarshal, value); }
-               }
-
-               #endregion
-
-               public ParameterDefinition (TypeReference parameterType)
-                       : this (string.Empty, ParameterAttributes.None, parameterType)
-               {
-               }
-
-               public ParameterDefinition (string name, ParameterAttributes attributes, TypeReference parameterType)
-                       : base (name, parameterType)
-               {
-                       this.attributes = (ushort) attributes;
-                       this.token = new MetadataToken (TokenType.Param);
-               }
-
-               public override ParameterDefinition Resolve ()
-               {
-                       return this;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ParameterDefinitionCollection.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ParameterDefinitionCollection.cs
deleted file mode 100644 (file)
index bd8b1c1..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-//
-// ParameterDefinitionCollection.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       sealed class ParameterDefinitionCollection : Collection<ParameterDefinition> {
-
-               readonly IMethodSignature method;
-
-               internal ParameterDefinitionCollection (IMethodSignature method)
-               {
-                       this.method = method;
-               }
-
-               internal ParameterDefinitionCollection (IMethodSignature method, int capacity)
-                       : base (capacity)
-               {
-                       this.method = method;
-               }
-
-               protected override void OnAdd (ParameterDefinition item, int index)
-               {
-                       item.method = method;
-                       item.index = index;
-               }
-
-               protected override void OnInsert (ParameterDefinition item, int index)
-               {
-                       item.method = method;
-                       item.index = index;
-
-                       for (int i = index; i < size; i++)
-                               items [i].index = i + 1;
-               }
-
-               protected override void OnSet (ParameterDefinition item, int index)
-               {
-                       item.method = method;
-                       item.index = index;
-               }
-
-               protected override void OnRemove (ParameterDefinition item, int index)
-               {
-                       item.method = null;
-                       item.index = -1;
-
-                       for (int i = index + 1; i < size; i++)
-                               items [i].index = i - 1;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ParameterReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ParameterReference.cs
deleted file mode 100644 (file)
index 46b057c..0000000
+++ /dev/null
@@ -1,75 +0,0 @@
-//
-// ParameterReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       public abstract class ParameterReference : IMetadataTokenProvider {
-
-               string name;
-               internal int index = -1;
-               protected TypeReference parameter_type;
-               internal MetadataToken token;
-
-               public string Name {
-                       get { return name; }
-                       set { name = value; }
-               }
-
-               public int Index {
-                       get { return index; }
-               }
-
-               public TypeReference ParameterType {
-                       get { return parameter_type; }
-                       set { parameter_type = value; }
-               }
-
-               public MetadataToken MetadataToken {
-                       get { return token; }
-                       set { token = value; }
-               }
-
-               internal ParameterReference (string name, TypeReference parameterType)
-               {
-                       if (parameterType == null)
-                               throw new ArgumentNullException ("parameterType");
-
-                       this.name = name ?? string.Empty;
-                       this.parameter_type = parameterType;
-               }
-
-               public override string ToString ()
-               {
-                       return name;
-               }
-
-               public abstract ParameterDefinition Resolve ();
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/PinnedType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/PinnedType.cs
deleted file mode 100644 (file)
index ff59cfb..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-//
-// PinnedType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using MD = Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public sealed class PinnedType : TypeSpecification {
-
-               public override bool IsValueType {
-                       get { return false; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override bool IsPinned {
-                       get { return true; }
-               }
-
-               public PinnedType (TypeReference type)
-                       : base (type)
-               {
-                       Mixin.CheckType (type);
-                       this.etype = MD.ElementType.Pinned;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/PointerType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/PointerType.cs
deleted file mode 100644 (file)
index a142e14..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-//
-// PointerType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using MD = Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public sealed class PointerType : TypeSpecification {
-
-               public override string Name {
-                       get { return base.Name + "*"; }
-               }
-
-               public override string FullName {
-                       get { return base.FullName + "*"; }
-               }
-
-               public override bool IsValueType {
-                       get { return false; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override bool IsPointer {
-                       get { return true; }
-               }
-
-               public PointerType (TypeReference type)
-                       : base (type)
-               {
-                       Mixin.CheckType (type);
-                       this.etype = MD.ElementType.Ptr;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/PropertyAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/PropertyAttributes.cs
deleted file mode 100644 (file)
index 1be0413..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-//
-// PropertyAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum PropertyAttributes : ushort {
-               None                    = 0x0000,
-               SpecialName             = 0x0200,       // Property is special
-               RTSpecialName   = 0x0400,       // Runtime(metadata internal APIs) should check name encoding
-               HasDefault              = 0x1000,       // Property has default
-               Unused                  = 0xe9ff         // Reserved: shall be zero in a conforming implementation
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/PropertyDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/PropertyDefinition.cs
deleted file mode 100644 (file)
index 42878a0..0000000
+++ /dev/null
@@ -1,265 +0,0 @@
-//
-// PropertyDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System.Text;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public sealed class PropertyDefinition : PropertyReference, IMemberDefinition, IConstantProvider {
-
-               bool? has_this;
-               ushort attributes;
-
-               Collection<CustomAttribute> custom_attributes;
-
-               internal MethodDefinition get_method;
-               internal MethodDefinition set_method;
-               internal Collection<MethodDefinition> other_methods;
-
-               object constant = Mixin.NotResolved;
-
-               public PropertyAttributes Attributes {
-                       get { return (PropertyAttributes) attributes; }
-                       set { attributes = (ushort) value; }
-               }
-
-               public bool HasThis {
-                       get {
-                               if (has_this.HasValue)
-                                       return has_this.Value;
-
-                               if (GetMethod != null)
-                                       return get_method.HasThis;
-
-                               if (SetMethod != null)
-                                       return set_method.HasThis;
-
-                               return false;
-                       }
-                       set { has_this = value; }
-               }
-
-               public bool HasCustomAttributes {
-                       get {
-                               if (custom_attributes != null)
-                                       return custom_attributes.Count > 0;
-
-                               return this.GetHasCustomAttributes (Module);
-                       }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return custom_attributes ?? (custom_attributes = this.GetCustomAttributes (Module)); }
-               }
-
-               public MethodDefinition GetMethod {
-                       get {
-                               if (get_method != null)
-                                       return get_method;
-
-                               InitializeMethods ();
-                               return get_method;
-                       }
-                       set { get_method = value; }
-               }
-
-               public MethodDefinition SetMethod {
-                       get {
-                               if (set_method != null)
-                                       return set_method;
-
-                               InitializeMethods ();
-                               return set_method;
-                       }
-                       set { set_method = value; }
-               }
-
-               public bool HasOtherMethods {
-                       get {
-                               if (other_methods != null)
-                                       return other_methods.Count > 0;
-
-                               InitializeMethods ();
-                               return !other_methods.IsNullOrEmpty ();
-                       }
-               }
-
-               public Collection<MethodDefinition> OtherMethods {
-                       get {
-                               if (other_methods != null)
-                                       return other_methods;
-
-                               InitializeMethods ();
-
-                               if (other_methods != null)
-                                       return other_methods;
-
-                               return other_methods = new Collection<MethodDefinition> ();
-                       }
-               }
-
-               public bool HasParameters {
-                       get {
-                               InitializeMethods ();
-
-                               if (get_method != null)
-                                       return get_method.HasParameters;
-
-                               if (set_method != null)
-                                       return set_method.HasParameters && set_method.Parameters.Count > 1;
-
-                               return false;
-                       }
-               }
-
-               public override Collection<ParameterDefinition> Parameters {
-                       get {
-                               InitializeMethods ();
-
-                               if (get_method != null)
-                                       return MirrorParameters (get_method, 0);
-
-                               if (set_method != null)
-                                       return MirrorParameters (set_method, 1);
-
-                               return new Collection<ParameterDefinition> ();
-                       }
-               }
-
-               static Collection<ParameterDefinition> MirrorParameters (MethodDefinition method, int bound)
-               {
-                       var parameters = new Collection<ParameterDefinition> ();
-                       if (!method.HasParameters)
-                               return parameters;
-
-                       var original_parameters = method.Parameters;
-                       var end = original_parameters.Count - bound;
-
-                       for (int i = 0; i < end; i++)
-                               parameters.Add (original_parameters [i]);
-
-                       return parameters;
-               }
-
-               public bool HasConstant {
-                       get {
-                               ResolveConstant ();
-
-                               return constant != Mixin.NoValue;
-                       }
-                       set { if (!value) constant = Mixin.NoValue; }
-               }
-
-               public object Constant {
-                       get { return HasConstant ? constant : null;     }
-                       set { constant = value; }
-               }
-
-               void ResolveConstant ()
-               {
-                       if (constant != Mixin.NotResolved)
-                               return;
-
-                       this.ResolveConstant (ref constant, Module);
-               }
-
-               #region PropertyAttributes
-
-               public bool IsSpecialName {
-                       get { return attributes.GetAttributes ((ushort) PropertyAttributes.SpecialName); }
-                       set { attributes = attributes.SetAttributes ((ushort) PropertyAttributes.SpecialName, value); }
-               }
-
-               public bool IsRuntimeSpecialName {
-                       get { return attributes.GetAttributes ((ushort) PropertyAttributes.RTSpecialName); }
-                       set { attributes = attributes.SetAttributes ((ushort) PropertyAttributes.RTSpecialName, value); }
-               }
-
-               public bool HasDefault {
-                       get { return attributes.GetAttributes ((ushort) PropertyAttributes.HasDefault); }
-                       set { attributes = attributes.SetAttributes ((ushort) PropertyAttributes.HasDefault, value); }
-               }
-
-               #endregion
-
-               public new TypeDefinition DeclaringType {
-                       get { return (TypeDefinition) base.DeclaringType; }
-                       set { base.DeclaringType = value; }
-               }
-
-               public override bool IsDefinition {
-                       get { return true; }
-               }
-
-               public override string FullName {
-                       get {
-                               var builder = new StringBuilder ();
-                               builder.Append (PropertyType.ToString ());
-                               builder.Append (' ');
-                               builder.Append (MemberFullName ());
-                               builder.Append ('(');
-                               if (HasParameters) {
-                                       var parameters = Parameters;
-                                       for (int i = 0; i < parameters.Count; i++) {
-                                               if (i > 0)
-                                                       builder.Append (',');
-                                               builder.Append (parameters [i].ParameterType.FullName);
-                                       }
-                               }
-                               builder.Append (')');
-                               return builder.ToString ();
-                       }
-               }
-
-               public PropertyDefinition (string name, PropertyAttributes attributes, TypeReference propertyType)
-                       : base (name, propertyType)
-               {
-                       this.attributes = (ushort) attributes;
-                       this.token = new MetadataToken (TokenType.Property);
-               }
-
-               void InitializeMethods ()
-               {
-                       if (get_method != null || set_method != null)
-                               return;
-
-                       var module = this.Module;
-                       if (!module.HasImage ())
-                               return;
-
-                       module.Read (this, (property, reader) => reader.ReadMethods (property));
-               }
-
-               public override PropertyDefinition Resolve ()
-               {
-                       return this;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/PropertyReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil/PropertyReference.cs
deleted file mode 100644 (file)
index 0dcfc95..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-//
-// PropertyReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public abstract class PropertyReference : MemberReference {
-
-               TypeReference property_type;
-
-               public TypeReference PropertyType {
-                       get { return property_type; }
-                       set { property_type = value; }
-               }
-
-               public abstract Collection<ParameterDefinition> Parameters {
-                       get;
-               }
-
-               internal PropertyReference (string name, TypeReference propertyType)
-                       : base (name)
-               {
-                       if (propertyType == null)
-                               throw new ArgumentNullException ("propertyType");
-
-                       property_type = propertyType;
-               }
-
-               public abstract PropertyDefinition Resolve ();
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/ReferenceType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/ReferenceType.cs
deleted file mode 100644 (file)
index 7940c61..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-//
-// ByReferenceType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using MD = Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public sealed class ByReferenceType : TypeSpecification {
-
-               public override string Name {
-                       get { return base.Name + "&"; }
-               }
-
-               public override string FullName {
-                       get { return base.FullName + "&"; }
-               }
-
-               public override bool IsValueType {
-                       get { return false; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override bool IsByReference {
-                       get { return true; }
-               }
-
-               public ByReferenceType (TypeReference type)
-                       : base (type)
-               {
-                       Mixin.CheckType (type);
-                       this.etype = MD.ElementType.ByRef;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/Resource.cs b/mcs/class/Mono.Cecil/Mono.Cecil/Resource.cs
deleted file mode 100644 (file)
index eff7f41..0000000
+++ /dev/null
@@ -1,76 +0,0 @@
-//
-// ResourceType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public enum ResourceType {
-               Linked,
-               Embedded,
-               AssemblyLinked,
-       }
-
-       public abstract class Resource {
-
-               string name;
-               uint attributes;
-
-               public string Name {
-                       get { return name; }
-                       set { name = value; }
-               }
-
-               public ManifestResourceAttributes Attributes {
-                       get { return (ManifestResourceAttributes) attributes; }
-                       set { attributes = (uint) value; }
-               }
-
-               public abstract ResourceType ResourceType {
-                       get;
-               }
-
-               #region ManifestResourceAttributes
-
-               public bool IsPublic {
-                       get { return attributes.GetMaskedAttributes ((uint) ManifestResourceAttributes.VisibilityMask, (uint) ManifestResourceAttributes.Public); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) ManifestResourceAttributes.VisibilityMask, (uint) ManifestResourceAttributes.Public, value); }
-               }
-
-               public bool IsPrivate {
-                       get { return attributes.GetMaskedAttributes ((uint) ManifestResourceAttributes.VisibilityMask, (uint) ManifestResourceAttributes.Private); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) ManifestResourceAttributes.VisibilityMask, (uint) ManifestResourceAttributes.Private, value); }
-               }
-
-               #endregion
-
-               internal Resource (string name, ManifestResourceAttributes attributes)
-               {
-                       this.name = name;
-                       this.attributes = (uint) attributes;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/SecurityDeclaration.cs b/mcs/class/Mono.Cecil/Mono.Cecil/SecurityDeclaration.cs
deleted file mode 100644 (file)
index 837472a..0000000
+++ /dev/null
@@ -1,191 +0,0 @@
-//
-// SecurityDeclaration.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public enum SecurityAction : ushort {
-               Request = 1,
-               Demand = 2,
-               Assert = 3,
-               Deny = 4,
-               PermitOnly = 5,
-               LinkDemand = 6,
-               InheritDemand = 7,
-               RequestMinimum = 8,
-               RequestOptional = 9,
-               RequestRefuse = 10,
-               PreJitGrant = 11,
-               PreJitDeny = 12,
-               NonCasDemand = 13,
-               NonCasLinkDemand = 14,
-               NonCasInheritance = 15
-       }
-
-       public interface ISecurityDeclarationProvider : IMetadataTokenProvider {
-
-               bool HasSecurityDeclarations { get; }
-               Collection<SecurityDeclaration> SecurityDeclarations { get; }
-       }
-
-       public sealed class SecurityAttribute : ICustomAttribute {
-
-               TypeReference attribute_type;
-
-               internal Collection<CustomAttributeNamedArgument> fields;
-               internal Collection<CustomAttributeNamedArgument> properties;
-
-               public TypeReference AttributeType {
-                       get { return attribute_type; }
-                       set { attribute_type = value; }
-               }
-
-               public bool HasFields {
-                       get { return !fields.IsNullOrEmpty (); }
-               }
-
-               public Collection<CustomAttributeNamedArgument> Fields {
-                       get { return fields ?? (fields = new Collection<CustomAttributeNamedArgument> ()); }
-               }
-
-               public bool HasProperties {
-                       get { return !properties.IsNullOrEmpty (); }
-               }
-
-               public Collection<CustomAttributeNamedArgument> Properties {
-                       get { return properties ?? (properties = new Collection<CustomAttributeNamedArgument> ()); }
-               }
-
-               public SecurityAttribute (TypeReference attributeType)
-               {
-                       this.attribute_type = attributeType;
-               }
-       }
-
-       public sealed class SecurityDeclaration {
-
-               readonly internal uint signature;
-               byte [] blob;
-               readonly ModuleDefinition module;
-
-               internal bool resolved;
-               SecurityAction action;
-               internal Collection<SecurityAttribute> security_attributes;
-
-               public SecurityAction Action {
-                       get { return action; }
-                       set { action = value; }
-               }
-
-               public bool HasSecurityAttributes {
-                       get {
-                               Resolve ();
-
-                               return !security_attributes.IsNullOrEmpty ();
-                       }
-               }
-
-               public Collection<SecurityAttribute> SecurityAttributes {
-                       get {
-                               Resolve ();
-
-                               return security_attributes ?? (security_attributes = new Collection<SecurityAttribute> ());
-                       }
-               }
-
-               internal bool HasImage {
-                       get { return module != null && module.HasImage; }
-               }
-
-               internal SecurityDeclaration (SecurityAction action, uint signature, ModuleDefinition module)
-               {
-                       this.action = action;
-                       this.signature = signature;
-                       this.module = module;
-               }
-
-               public SecurityDeclaration (SecurityAction action)
-               {
-                       this.action = action;
-                       this.resolved = true;
-               }
-
-               public SecurityDeclaration (SecurityAction action, byte [] blob)
-               {
-                       this.action = action;
-                       this.resolved = false;
-                       this.blob = blob;
-               }
-
-               public byte [] GetBlob ()
-               {
-                       if (blob != null)
-                               return blob;
-
-                       if (!HasImage || signature == 0)
-                               throw new NotSupportedException ();
-
-                       return blob = module.Read (this, (declaration, reader) => reader.ReadSecurityDeclarationBlob (declaration.signature));
-               }
-
-               void Resolve ()
-               {
-                       if (resolved || !HasImage)
-                               return;
-
-                       module.Read (this, (declaration, reader) => {
-                               reader.ReadSecurityDeclarationSignature (declaration);
-                               return this;
-                       });
-
-                       resolved = true;
-               }
-       }
-
-       static partial class Mixin {
-
-               public static bool GetHasSecurityDeclarations (
-                       this ISecurityDeclarationProvider self,
-                       ModuleDefinition module)
-               {
-                       return module.HasImage () && module.Read (self, (provider, reader) => reader.HasSecurityDeclarations (provider));
-               }
-
-               public static Collection<SecurityDeclaration> GetSecurityDeclarations (
-                       this ISecurityDeclarationProvider self,
-                       ModuleDefinition module)
-               {
-                       return module.HasImage ()
-                               ? module.Read (self, (provider, reader) => reader.ReadSecurityDeclarations (provider))
-                               : new Collection<SecurityDeclaration> ();
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/SentinelType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/SentinelType.cs
deleted file mode 100644 (file)
index 664d75b..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-//
-// SentinelType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using MD = Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public sealed class SentinelType : TypeSpecification {
-
-               public override bool IsValueType {
-                       get { return false; }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public override bool IsSentinel {
-                       get { return true; }
-               }
-
-               public SentinelType (TypeReference type)
-                       : base (type)
-               {
-                       Mixin.CheckType (type);
-                       this.etype = MD.ElementType.Sentinel;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/TargetRuntime.cs b/mcs/class/Mono.Cecil/Mono.Cecil/TargetRuntime.cs
deleted file mode 100644 (file)
index 9b49a5f..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-//
-// TargetRuntime.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public enum TargetRuntime {
-               Net_1_0,
-               Net_1_1,
-               Net_2_0,
-               Net_4_0,
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/TypeAttributes.cs b/mcs/class/Mono.Cecil/Mono.Cecil/TypeAttributes.cs
deleted file mode 100644 (file)
index bc4e18f..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-//
-// TypeAttributes.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-namespace Mono.Cecil {
-
-       [Flags]
-       public enum TypeAttributes : uint {
-               // Visibility attributes
-               VisibilityMask          = 0x00000007,   // Use this mask to retrieve visibility information
-               NotPublic                       = 0x00000000,   // Class has no public scope
-               Public                          = 0x00000001,   // Class has public scope
-               NestedPublic            = 0x00000002,   // Class is nested with public visibility
-               NestedPrivate           = 0x00000003,   // Class is nested with private visibility
-               NestedFamily            = 0x00000004,   // Class is nested with family visibility
-               NestedAssembly          = 0x00000005,   // Class is nested with assembly visibility
-               NestedFamANDAssem       = 0x00000006,   // Class is nested with family and assembly visibility
-               NestedFamORAssem        = 0x00000007,   // Class is nested with family or assembly visibility
-
-               // Class layout attributes
-               LayoutMask                      = 0x00000018,   // Use this mask to retrieve class layout information
-               AutoLayout                      = 0x00000000,   // Class fields are auto-laid out
-               SequentialLayout        = 0x00000008,   // Class fields are laid out sequentially
-               ExplicitLayout          = 0x00000010,   // Layout is supplied explicitly
-
-               // Class semantics attributes
-               ClassSemanticMask       = 0x00000020,   // Use this mask to retrieve class semantics information
-               Class                           = 0x00000000,   // Type is a class
-               Interface                       = 0x00000020,   // Type is an interface
-
-               // Special semantics in addition to class semantics
-               Abstract                        = 0x00000080,   // Class is abstract
-               Sealed                          = 0x00000100,   // Class cannot be extended
-               SpecialName                     = 0x00000400,   // Class name is special
-
-               // Implementation attributes
-               Import                          = 0x00001000,   // Class/Interface is imported
-               Serializable            = 0x00002000,   // Class is serializable
-
-               // String formatting attributes
-               StringFormatMask        = 0x00030000,   // Use this mask to retrieve string information for native interop
-               AnsiClass                       = 0x00000000,   // LPSTR is interpreted as ANSI
-               UnicodeClass            = 0x00010000,   // LPSTR is interpreted as Unicode
-               AutoClass                       = 0x00020000,   // LPSTR is interpreted automatically
-
-               // Class initialization attributes
-               BeforeFieldInit         = 0x00100000,   // Initialize the class before first static field access
-
-               // Additional flags
-               RTSpecialName           = 0x00000800,   // CLI provides 'special' behavior, depending upon the name of the Type
-               HasSecurity                     = 0x00040000,   // Type has security associate with it
-               Forwarder                       = 0x00200000,   // Exported type is a type forwarder
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/TypeDefinition.cs b/mcs/class/Mono.Cecil/Mono.Cecil/TypeDefinition.cs
deleted file mode 100644 (file)
index a1575e1..0000000
+++ /dev/null
@@ -1,495 +0,0 @@
-//
-// TypeDefinition.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public sealed class TypeDefinition : TypeReference, IMemberDefinition, ISecurityDeclarationProvider {
-
-               uint attributes;
-               TypeReference base_type;
-               internal Range fields_range;
-               internal Range methods_range;
-
-               short packing_size = Mixin.NotResolvedMarker;
-               int class_size = Mixin.NotResolvedMarker;
-
-               Collection<TypeReference> interfaces;
-               Collection<TypeDefinition> nested_types;
-               Collection<MethodDefinition> methods;
-               Collection<FieldDefinition> fields;
-               Collection<EventDefinition> events;
-               Collection<PropertyDefinition> properties;
-               Collection<CustomAttribute> custom_attributes;
-               Collection<SecurityDeclaration> security_declarations;
-
-               public TypeAttributes Attributes {
-                       get { return (TypeAttributes) attributes; }
-                       set { attributes = (uint) value; }
-               }
-
-               public TypeReference BaseType {
-                       get { return base_type; }
-                       set { base_type = value; }
-               }
-
-               void ResolveLayout ()
-               {
-                       if (packing_size != Mixin.NotResolvedMarker || class_size != Mixin.NotResolvedMarker)
-                               return;
-
-                       if (!HasImage) {
-                               packing_size = Mixin.NoDataMarker;
-                               class_size = Mixin.NoDataMarker;
-                               return;
-                       }
-
-                       var row = Module.Read (this, (type, reader) => reader.ReadTypeLayout (type));
-
-                       packing_size = row.Col1;
-                       class_size = row.Col2;
-               }
-
-               public bool HasLayoutInfo {
-                       get {
-                               if (packing_size >= 0 || class_size >= 0)
-                                       return true;
-
-                               ResolveLayout ();
-
-                               return packing_size >= 0 || class_size >= 0;
-                       }
-               }
-
-               public short PackingSize {
-                       get {
-                               if (packing_size >= 0)
-                                       return packing_size;
-
-                               ResolveLayout ();
-
-                               return packing_size >= 0 ? packing_size : (short) -1;
-                       }
-                       set { packing_size = value; }
-               }
-
-               public int ClassSize {
-                       get {
-                               if (class_size >= 0)
-                                       return class_size;
-
-                               ResolveLayout ();
-
-                               return class_size >= 0 ? class_size : -1;
-                       }
-                       set { class_size = value; }
-               }
-
-               public bool HasInterfaces {
-                       get {
-                               if (interfaces != null)
-                                       return interfaces.Count > 0;
-
-                               if (HasImage)
-                                       return Module.Read (this, (type, reader) => reader.HasInterfaces (type));
-
-                               return false;
-                       }
-               }
-
-               public Collection<TypeReference> Interfaces {
-                       get {
-                               if (interfaces != null)
-                                       return interfaces;
-
-                               if (HasImage)
-                                       return interfaces = Module.Read (this, (type, reader) => reader.ReadInterfaces (type));
-
-                               return interfaces = new Collection<TypeReference> ();
-                       }
-               }
-
-               public bool HasNestedTypes {
-                       get {
-                               if (nested_types != null)
-                                       return nested_types.Count > 0;
-
-                               if (HasImage)
-                                       return Module.Read (this, (type, reader) => reader.HasNestedTypes (type));
-
-                               return false;
-                       }
-               }
-
-               public Collection<TypeDefinition> NestedTypes {
-                       get {
-                               if (nested_types != null)
-                                       return nested_types;
-
-                               if (HasImage)
-                                       return nested_types = Module.Read (this, (type, reader) => reader.ReadNestedTypes (type));
-
-                               return nested_types = new MemberDefinitionCollection<TypeDefinition> (this);
-                       }
-               }
-
-               public bool HasMethods {
-                       get {
-                               if (methods != null)
-                                       return methods.Count > 0;
-
-                               if (HasImage)
-                                       return methods_range.Length > 0;
-
-                               return false;
-                       }
-               }
-
-               public Collection<MethodDefinition> Methods {
-                       get {
-                               if (methods != null)
-                                       return methods;
-
-                               if (HasImage)
-                                       return methods = Module.Read (this, (type, reader) => reader.ReadMethods (type));
-
-                               return methods = new MemberDefinitionCollection<MethodDefinition> (this);
-                       }
-               }
-
-               public bool HasFields {
-                       get {
-                               if (fields != null)
-                                       return fields.Count > 0;
-
-                               if (HasImage)
-                                       return fields_range.Length > 0;
-
-                               return false;
-                       }
-               }
-
-               public Collection<FieldDefinition> Fields {
-                       get {
-                               if (fields != null)
-                                       return fields;
-
-                               if (HasImage)
-                                       return fields = Module.Read (this, (type, reader) => reader.ReadFields (type));
-
-                               return fields = new MemberDefinitionCollection<FieldDefinition> (this);
-                       }
-               }
-
-               public bool HasEvents {
-                       get {
-                               if (events != null)
-                                       return events.Count > 0;
-
-                               if (HasImage)
-                                       return Module.Read (this, (type, reader) => reader.HasEvents (type));
-
-                               return false;
-                       }
-               }
-
-               public Collection<EventDefinition> Events {
-                       get {
-                               if (events != null)
-                                       return events;
-
-                               if (HasImage)
-                                       return events = Module.Read (this, (type, reader) => reader.ReadEvents (type));
-
-                               return events = new MemberDefinitionCollection<EventDefinition> (this);
-                       }
-               }
-
-               public bool HasProperties {
-                       get {
-                               if (properties != null)
-                                       return properties.Count > 0;
-
-                               if (HasImage)
-                                       return Module.Read (this, (type, reader) => reader.HasProperties (type));
-
-                               return false;
-                       }
-               }
-
-               public Collection<PropertyDefinition> Properties {
-                       get {
-                               if (properties != null)
-                                       return properties;
-
-                               if (HasImage)
-                                       return properties = Module.Read (this, (type, reader) => reader.ReadProperties (type));
-
-                               return properties = new MemberDefinitionCollection<PropertyDefinition> (this);
-                       }
-               }
-
-               public bool HasSecurityDeclarations {
-                       get {
-                               if (security_declarations != null)
-                                       return security_declarations.Count > 0;
-
-                               return this.GetHasSecurityDeclarations (Module);
-                       }
-               }
-
-               public Collection<SecurityDeclaration> SecurityDeclarations {
-                       get { return security_declarations ?? (security_declarations = this.GetSecurityDeclarations (Module)); }
-               }
-
-               public bool HasCustomAttributes {
-                       get {
-                               if (custom_attributes != null)
-                                       return custom_attributes.Count > 0;
-
-                               return this.GetHasCustomAttributes (Module);
-                       }
-               }
-
-               public Collection<CustomAttribute> CustomAttributes {
-                       get { return custom_attributes ?? (custom_attributes = this.GetCustomAttributes (Module)); }
-               }
-
-               public override bool HasGenericParameters {
-                       get {
-                               if (generic_parameters != null)
-                                       return generic_parameters.Count > 0;
-
-                               return this.GetHasGenericParameters (Module);
-                       }
-               }
-
-               public override Collection<GenericParameter> GenericParameters {
-                       get { return generic_parameters ?? (generic_parameters = this.GetGenericParameters (Module)); }
-               }
-
-               #region TypeAttributes
-
-               public bool IsNotPublic {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NotPublic); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NotPublic, value); }
-               }
-
-               public bool IsPublic {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.Public); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.Public, value); }
-               }
-
-               public bool IsNestedPublic {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedPublic); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedPublic, value); }
-               }
-
-               public bool IsNestedPrivate {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedPrivate); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedPrivate, value); }
-               }
-
-               public bool IsNestedFamily {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamily); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamily, value); }
-               }
-
-               public bool IsNestedAssembly {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedAssembly); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedAssembly, value); }
-               }
-
-               public bool IsNestedFamilyAndAssembly {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamANDAssem); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamANDAssem, value); }
-               }
-
-               public bool IsNestedFamilyOrAssembly {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamORAssem); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.VisibilityMask, (uint) TypeAttributes.NestedFamORAssem, value); }
-               }
-
-               public bool IsAutoLayout {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.AutoLayout); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.AutoLayout, value); }
-               }
-
-               public bool IsSequentialLayout {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.SequentialLayout); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.SequentialLayout, value); }
-               }
-
-               public bool IsExplicitLayout {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.ExplicitLayout); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.LayoutMask, (uint) TypeAttributes.ExplicitLayout, value); }
-               }
-
-               public bool IsClass {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.ClassSemanticMask, (uint) TypeAttributes.Class); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.ClassSemanticMask, (uint) TypeAttributes.Class, value); }
-               }
-
-               public bool IsInterface {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.ClassSemanticMask, (uint) TypeAttributes.Interface); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.ClassSemanticMask, (uint) TypeAttributes.Interface, value); }
-               }
-
-               public bool IsAbstract {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.Abstract); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Abstract, value); }
-               }
-
-               public bool IsSealed {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.Sealed); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Sealed, value); }
-               }
-
-               public bool IsSpecialName {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.SpecialName); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.SpecialName, value); }
-               }
-
-               public bool IsImport {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.Import); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Import, value); }
-               }
-
-               public bool IsSerializable {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.Serializable); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.Serializable, value); }
-               }
-
-               public bool IsAnsiClass {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AnsiClass); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AnsiClass, value); }
-               }
-
-               public bool IsUnicodeClass {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.UnicodeClass); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.UnicodeClass, value); }
-               }
-
-               public bool IsAutoClass {
-                       get { return attributes.GetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AutoClass); }
-                       set { attributes = attributes.SetMaskedAttributes ((uint) TypeAttributes.StringFormatMask, (uint) TypeAttributes.AutoClass, value); }
-               }
-
-               public bool IsBeforeFieldInit {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.BeforeFieldInit); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.BeforeFieldInit, value); }
-               }
-
-               public bool IsRuntimeSpecialName {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.RTSpecialName); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.RTSpecialName, value); }
-               }
-
-               public bool HasSecurity {
-                       get { return attributes.GetAttributes ((uint) TypeAttributes.HasSecurity); }
-                       set { attributes = attributes.SetAttributes ((uint) TypeAttributes.HasSecurity, value); }
-               }
-
-               #endregion
-
-               public bool IsEnum {
-                       get { return base_type != null && base_type.IsTypeOf ("System", "Enum"); }
-               }
-
-               public override bool IsValueType {
-                       get {
-                               if (base_type == null)
-                                       return false;
-
-                               return base_type.IsTypeOf ("System", "Enum") || (base_type.IsTypeOf ("System", "ValueType") && !this.IsTypeOf ("System", "Enum"));
-                       }
-               }
-
-               public override bool IsDefinition {
-                       get { return true; }
-               }
-
-               public new TypeDefinition DeclaringType {
-                       get { return (TypeDefinition) base.DeclaringType; }
-                       set { base.DeclaringType = value; }
-               }
-
-               public TypeDefinition (string @namespace, string name, TypeAttributes attributes)
-                       : base (@namespace, name)
-               {
-                       this.attributes = (uint) attributes;
-                       this.token = new MetadataToken (TokenType.TypeDef);
-               }
-
-               public TypeDefinition (string @namespace, string name, TypeAttributes attributes, TypeReference baseType) :
-                       this (@namespace, name, attributes)
-               {
-                       this.BaseType = baseType;
-               }
-
-               public override TypeDefinition Resolve ()
-               {
-                       return this;
-               }
-       }
-
-       static partial class Mixin {
-
-               public static TypeReference GetEnumUnderlyingType (this TypeDefinition self)
-               {
-                       var fields = self.Fields;
-
-                       for (int i = 0; i < fields.Count; i++) {
-                               var field = fields [i];
-                               if (!field.IsStatic)
-                                       return field.FieldType;
-                       }
-
-                       throw new ArgumentException ();
-               }
-
-               public static TypeDefinition GetNestedType (this TypeDefinition self, string name)
-               {
-                       if (!self.HasNestedTypes)
-                               return null;
-
-                       var nested_types = self.NestedTypes;
-
-                       for (int i = 0; i < nested_types.Count; i++) {
-                               var nested_type = nested_types [i];
-                               if (nested_type.Name == name)
-                                       return nested_type;
-                       }
-
-                       return null;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/TypeDefinitionCollection.cs b/mcs/class/Mono.Cecil/Mono.Cecil/TypeDefinitionCollection.cs
deleted file mode 100644 (file)
index eae7122..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-//
-// TypeDefinitionCollection.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections.Generic;
-
-using Mono.Cecil.Metadata;
-
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       using Slot = Row<string, string>;
-
-       sealed class TypeDefinitionCollection : Collection<TypeDefinition> {
-
-               readonly ModuleDefinition container;
-               readonly Dictionary<Slot, TypeDefinition> name_cache;
-
-               internal TypeDefinitionCollection (ModuleDefinition container)
-               {
-                       this.container = container;
-                       this.name_cache = new Dictionary<Slot, TypeDefinition> (new RowEqualityComparer ());
-               }
-
-               internal TypeDefinitionCollection (ModuleDefinition container, int capacity)
-                       : base (capacity)
-               {
-                       this.container = container;
-                       this.name_cache = new Dictionary<Slot, TypeDefinition> (capacity, new RowEqualityComparer ());
-               }
-
-               protected override void OnAdd (TypeDefinition item, int index)
-               {
-                       Attach (item);
-               }
-
-               protected override void OnSet (TypeDefinition item, int index)
-               {
-                       Attach (item);
-               }
-
-               protected override void OnInsert (TypeDefinition item, int index)
-               {
-                       Attach (item);
-               }
-
-               protected override void OnRemove (TypeDefinition item, int index)
-               {
-                       Detach (item);
-               }
-
-               protected override void OnClear ()
-               {
-                       foreach (var type in this)
-                               Detach (type);
-               }
-
-               void Attach (TypeDefinition type)
-               {
-                       if (type.Module != null && type.Module != container)
-                               throw new ArgumentException ("Type already attached");
-
-                       type.module = container;
-                       type.scope = container;
-                       name_cache [new Slot (type.Namespace, type.Name)] = type;
-               }
-
-               void Detach (TypeDefinition type)
-               {
-                       type.module = null;
-                       type.scope = null;
-                       name_cache.Remove (new Slot (type.Namespace, type.Name));
-               }
-
-               public TypeDefinition GetType (string fullname)
-               {
-                       string @namespace, name;
-                       TypeParser.SplitFullName (fullname, out @namespace, out name);
-
-                       return GetType (@namespace, name);
-               }
-
-               public TypeDefinition GetType (string @namespace, string name)
-               {
-                       TypeDefinition type;
-                       if (name_cache.TryGetValue (new Slot (@namespace, name), out type))
-                               return type;
-
-                       return null;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/TypeParser.cs b/mcs/class/Mono.Cecil/Mono.Cecil/TypeParser.cs
deleted file mode 100644 (file)
index 733c422..0000000
+++ /dev/null
@@ -1,555 +0,0 @@
-//
-// TypeParser.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Text;
-
-using Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       class TypeParser {
-
-               class Type {
-                       public const int Ptr = -1;
-                       public const int ByRef = -2;
-                       public const int SzArray = -3;
-
-                       public string type_fullname;
-                       public string [] nested_names;
-                       public int arity;
-                       public int [] specs;
-                       public Type [] generic_arguments;
-                       public string assembly;
-               }
-
-               readonly string fullname;
-               readonly int length;
-
-               int position;
-
-               TypeParser (string fullname)
-               {
-                       this.fullname = fullname;
-                       this.length = fullname.Length;
-               }
-
-               Type ParseType (bool fq_name)
-               {
-                       var type = new Type ();
-                       type.type_fullname = ParsePart ();
-
-                       type.nested_names = ParseNestedNames ();
-
-                       if (TryGetArity (type))
-                               type.generic_arguments = ParseGenericArguments (type.arity);
-
-                       type.specs = ParseSpecs ();
-
-                       if (fq_name)
-                               type.assembly = ParseAssemblyName ();
-
-                       return type;
-               }
-
-               static bool TryGetArity (Type type)
-               {
-                       int arity = 0;
-
-                       TryAddArity (type.type_fullname, ref arity);
-
-                       var nested_names = type.nested_names;
-                       if (!nested_names.IsNullOrEmpty ()) {
-                               for (int i = 0; i < nested_names.Length; i++)
-                                       TryAddArity (nested_names [i], ref arity);
-                       }
-
-                       type.arity = arity;
-                       return arity > 0;
-               }
-
-               static bool TryGetArity (string name, out int arity)
-               {
-                       arity = 0;
-                       var index = name.LastIndexOf ('`');
-                       if (index == -1)
-                               return false;
-
-                       return ParseInt32 (name.Substring (index + 1), out arity);
-               }
-
-               static bool ParseInt32 (string value, out int result)
-               {
-#if CF
-                       try {
-                               result = int.Parse (value);
-                               return true;
-                       } catch {
-                               result = 0;
-                               return false;
-                       }
-#else
-                       return int.TryParse (value, out result);
-#endif
-               }
-
-               static void TryAddArity (string name, ref int arity)
-               {
-                       int type_arity;
-                       if (!TryGetArity (name, out type_arity))
-                               return;
-
-                       arity += type_arity;
-               }
-
-               string ParsePart ()
-               {
-                       int start = position;
-                       while (position < length && !IsDelimiter (fullname [position]))
-                               position++;
-
-                       return fullname.Substring (start, position - start);
-               }
-
-               static bool IsDelimiter (char chr)
-               {
-                       return "+,[]*&".IndexOf (chr) != -1;
-               }
-
-               void TryParseWhiteSpace ()
-               {
-                       while (position < length && Char.IsWhiteSpace (fullname [position]))
-                               position++;
-               }
-
-               string [] ParseNestedNames ()
-               {
-                       string [] nested_names = null;
-                       while (TryParse ('+'))
-                               Add (ref nested_names, ParsePart ());
-
-                       return nested_names;
-               }
-
-               bool TryParse (char chr)
-               {
-                       if (position < length && fullname [position] == chr) {
-                               position++;
-                               return true;
-                       }
-
-                       return false;
-               }
-
-               static void Add<T> (ref T [] array, T item)
-               {
-                       if (array == null) {
-                               array = new [] { item };
-                               return;
-                       }
-
-#if !CF
-                       Array.Resize (ref array, array.Length + 1);
-#else
-                       var copy = new T [array.Length + 1];
-                       Array.Copy (array, copy, array.Length);
-                       array = copy;
-#endif
-                       array [array.Length - 1] = item;
-               }
-
-               int [] ParseSpecs ()
-               {
-                       int [] specs = null;
-
-                       while (position < length) {
-                               switch (fullname [position]) {
-                               case '*':
-                                       position++;
-                                       Add (ref specs, Type.Ptr);
-                                       break;
-                               case '&':
-                                       position++;
-                                       Add (ref specs, Type.ByRef);
-                                       break;
-                               case '[':
-                                       position++;
-                                       switch (fullname [position]) {
-                                       case ']':
-                                               position++;
-                                               Add (ref specs, Type.SzArray);
-                                               break;
-                                       case '*':
-                                               position++;
-                                               Add (ref specs, 1);
-                                               break;
-                                       default:
-                                               var rank = 1;
-                                               while (TryParse (','))
-                                                       rank++;
-
-                                               Add (ref specs, rank);
-
-                                               TryParse (']');
-                                               break;
-                                       }
-                                       break;
-                               default:
-                                       return specs;
-                               }
-                       }
-
-                       return specs;
-               }
-
-               Type [] ParseGenericArguments (int arity)
-               {
-                       Type [] generic_arguments = null;
-
-                       if (position == length || fullname [position] != '[')
-                               return generic_arguments;
-
-                       TryParse ('[');
-
-                       for (int i = 0; i < arity; i++) {
-                               var fq_argument = TryParse ('[');
-                               Add (ref generic_arguments, ParseType (fq_argument));
-                               if (fq_argument)
-                                       TryParse (']');
-
-                               TryParse (',');
-                               TryParseWhiteSpace ();
-                       }
-
-                       TryParse (']');
-
-                       return generic_arguments;
-               }
-
-               string ParseAssemblyName ()
-               {
-                       if (!TryParse (','))
-                               return string.Empty;
-
-                       TryParseWhiteSpace ();
-
-                       var start = position;
-                       while (position < length) {
-                               var chr = fullname [position];
-                               if (chr == '[' || chr == ']')
-                                       break;
-
-                               position++;
-                       }
-
-                       return fullname.Substring (start, position - start);
-               }
-
-               public static TypeReference ParseType (ModuleDefinition module, string fullname)
-               {
-                       if (fullname == null)
-                               return null;
-
-                       var parser = new TypeParser (fullname);
-                       return GetTypeReference (module, parser.ParseType (true));
-               }
-
-               static TypeReference GetTypeReference (ModuleDefinition module, Type type_info)
-               {
-                       TypeReference type;
-                       if (!TryGetDefinition (module, type_info, out type))
-                               type = CreateReference (type_info, module, GetMetadataScope (module, type_info));
-
-                       return CreateSpecs (type, type_info);
-               }
-
-               static TypeReference CreateSpecs (TypeReference type, Type type_info)
-               {
-                       type = TryCreateGenericInstanceType (type, type_info);
-
-                       var specs = type_info.specs;
-                       if (specs.IsNullOrEmpty ())
-                               return type;
-
-                       for (int i = 0; i < specs.Length; i++) {
-                               switch (specs [i]) {
-                               case Type.Ptr:
-                                       type = new PointerType (type);
-                                       break;
-                               case Type.ByRef:
-                                       type = new ByReferenceType (type);
-                                       break;
-                               case Type.SzArray:
-                                       type = new ArrayType (type);
-                                       break;
-                               default:
-                                       var array = new ArrayType (type);
-                                       array.Dimensions.Clear ();
-
-                                       for (int j = 0; j < specs [i]; j++)
-                                               array.Dimensions.Add (new ArrayDimension ());
-
-                                       type = array;
-                                       break;
-                               }
-                       }
-
-                       return type;
-               }
-
-               static TypeReference TryCreateGenericInstanceType (TypeReference type, Type type_info)
-               {
-                       var generic_arguments = type_info.generic_arguments;
-                       if (generic_arguments.IsNullOrEmpty ())
-                               return type;
-
-                       var instance = new GenericInstanceType (type);
-                       var instance_arguments = instance.GenericArguments;
-
-                       for (int i = 0; i < generic_arguments.Length; i++)
-                               instance_arguments.Add (GetTypeReference (type.Module, generic_arguments [i]));
-
-                       return instance;
-               }
-
-               public static void SplitFullName (string fullname, out string @namespace, out string name)
-               {
-                       var last_dot = fullname.LastIndexOf ('.');
-
-                       if (last_dot == -1) {
-                               @namespace = string.Empty;
-                               name = fullname;
-                       } else {
-                               @namespace = fullname.Substring (0, last_dot);
-                               name = fullname.Substring (last_dot + 1);
-                       }
-               }
-
-               static TypeReference CreateReference (Type type_info, ModuleDefinition module, IMetadataScope scope)
-               {
-                       string @namespace, name;
-                       SplitFullName (type_info.type_fullname, out @namespace, out name);
-
-                       var type = new TypeReference (@namespace, name, module, scope);
-                       MetadataSystem.TryProcessPrimitiveType (type);
-
-                       AdjustGenericParameters (type);
-
-                       var nested_names = type_info.nested_names;
-                       if (nested_names.IsNullOrEmpty ())
-                               return type;
-
-                       for (int i = 0; i < nested_names.Length; i++) {
-                               type = new TypeReference (string.Empty, nested_names [i], module, null) {
-                                       DeclaringType = type,
-                               };
-
-                               AdjustGenericParameters (type);
-                       }
-
-                       return type;
-               }
-
-               static void AdjustGenericParameters (TypeReference type)
-               {
-                       int arity;
-                       if (!TryGetArity (type.Name, out arity))
-                               return;
-
-                       for (int i = 0; i < arity; i++)
-                               type.GenericParameters.Add (new GenericParameter (type));
-               }
-
-               static IMetadataScope GetMetadataScope (ModuleDefinition module, Type type_info)
-               {
-                       if (string.IsNullOrEmpty (type_info.assembly))
-                               return module.TypeSystem.Corlib;
-
-                       return MatchReference (module, AssemblyNameReference.Parse (type_info.assembly));
-               }
-
-               static AssemblyNameReference MatchReference (ModuleDefinition module, AssemblyNameReference pattern)
-               {
-                       var references = module.AssemblyReferences;
-
-                       for (int i = 0; i < references.Count; i++) {
-                               var reference = references [i];
-                               if (reference.FullName == pattern.FullName)
-                                       return reference;
-                       }
-
-                       return pattern;
-               }
-
-               static bool TryGetDefinition (ModuleDefinition module, Type type_info, out TypeReference type)
-               {
-                       type = null;
-                       if (!TryCurrentModule (module, type_info))
-                               return false;
-
-                       var typedef = module.GetType (type_info.type_fullname);
-                       if (typedef == null)
-                               return false;
-
-                       var nested_names = type_info.nested_names;
-                       if (!nested_names.IsNullOrEmpty ()) {
-                               for (int i = 0; i < nested_names.Length; i++)
-                                       typedef = typedef.GetNestedType (nested_names [i]);
-                       }
-
-                       type = typedef;
-                       return true;
-               }
-
-               static bool TryCurrentModule (ModuleDefinition module, Type type_info)
-               {
-                       if (string.IsNullOrEmpty (type_info.assembly))
-                               return true;
-
-                       if (module.assembly != null && module.assembly.Name.FullName == type_info.assembly)
-                               return true;
-
-                       return false;
-               }
-
-               public static string ToParseable (TypeReference type)
-               {
-                       if (type == null)
-                               return null;
-
-                       var name = new StringBuilder ();
-                       AppendType (type, name, true, true);
-                       return name.ToString ();
-               }
-
-               static void AppendType (TypeReference type, StringBuilder name, bool fq_name, bool top_level)
-               {
-                       var declaring_type = type.DeclaringType;
-                       if (declaring_type != null) {
-                               AppendType (declaring_type, name, false, top_level);
-                               name.Append ('+');
-                       }
-
-                       var @namespace = type.Namespace;
-                       if (!string.IsNullOrEmpty (@namespace)) {
-                               name.Append (@namespace);
-                               name.Append ('.');
-                       }
-
-                       name.Append (type.GetElementType ().Name);
-
-                       if (!fq_name)
-                               return;
-
-                       if (type.IsTypeSpecification ())
-                               AppendTypeSpecification ((TypeSpecification) type, name);
-
-                       if (RequiresFullyQualifiedName (type, top_level)) {
-                               name.Append (", ");
-                               name.Append (GetScopeFullName (type));
-                       }
-               }
-
-               static string GetScopeFullName (TypeReference type)
-               {
-                       var scope = type.Scope;
-                       switch (scope.MetadataScopeType) {
-                       case MetadataScopeType.AssemblyNameReference:
-                               return ((AssemblyNameReference) scope).FullName;
-                       case MetadataScopeType.ModuleDefinition:
-                               return ((ModuleDefinition) scope).Assembly.Name.FullName;
-                       }
-
-                       throw new ArgumentException ();
-               }
-
-               static void AppendTypeSpecification (TypeSpecification type, StringBuilder name)
-               {
-                       if (type.ElementType.IsTypeSpecification ())
-                               AppendTypeSpecification ((TypeSpecification) type.ElementType, name);
-
-                       switch (type.etype) {
-                       case ElementType.Ptr:
-                               name.Append ('*');
-                               break;
-                       case ElementType.ByRef:
-                               name.Append ('&');
-                               break;
-                       case ElementType.SzArray:
-                       case ElementType.Array:
-                               var array = (ArrayType) type;
-                               if (array.IsVector) {
-                                       name.Append ("[]");
-                               } else {
-                                       name.Append ('[');
-                                       for (int i = 1; i < array.Rank; i++)
-                                               name.Append (',');
-                                       name.Append (']');
-                               }
-                               break;
-                       case ElementType.GenericInst:
-                               var instance = (GenericInstanceType) type;
-                               var arguments = instance.GenericArguments;
-
-                               name.Append ('[');
-
-                               for (int i = 0; i < arguments.Count; i++) {
-                                       if (i > 0)
-                                               name.Append (',');
-
-                                       var argument = arguments [i];
-                                       var requires_fqname = argument.Scope != argument.Module;
-
-                                       if (requires_fqname)
-                                               name.Append ('[');
-
-                                       AppendType (argument, name, true, false);
-
-                                       if (requires_fqname)
-                                               name.Append (']');
-                               }
-
-                               name.Append (']');
-                               break;
-                       default:
-                               return;
-                       }
-               }
-
-               static bool RequiresFullyQualifiedName (TypeReference type, bool top_level)
-               {
-                       if (type.Scope == type.Module)
-                               return false;
-
-                       if (type.Scope.Name == "mscorlib" && top_level)
-                               return false;
-
-                       return true;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/TypeReference.cs b/mcs/class/Mono.Cecil/Mono.Cecil/TypeReference.cs
deleted file mode 100644 (file)
index 757c83a..0000000
+++ /dev/null
@@ -1,327 +0,0 @@
-//
-// TypeReference.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Cecil.Metadata;
-using Mono.Collections.Generic;
-
-namespace Mono.Cecil {
-
-       public enum MetadataType : byte {
-               Void = ElementType.Void,
-               Boolean = ElementType.Boolean,
-               Char = ElementType.Char,
-               SByte = ElementType.I1,
-               Byte = ElementType.U1,
-               Int16 = ElementType.I2,
-               UInt16 = ElementType.U2,
-               Int32 = ElementType.I4,
-               UInt32 = ElementType.U4,
-               Int64 = ElementType.I8,
-               UInt64 = ElementType.U8,
-               Single = ElementType.R4,
-               Double = ElementType.R8,
-               String = ElementType.String,
-               Pointer = ElementType.Ptr,
-               ByReference = ElementType.ByRef,
-               ValueType = ElementType.ValueType,
-               Class = ElementType.Class,
-               Var = ElementType.Var,
-               Array = ElementType.Array,
-               GenericInstance = ElementType.GenericInst,
-               TypedByReference = ElementType.TypedByRef,
-               IntPtr = ElementType.I,
-               UIntPtr = ElementType.U,
-               FunctionPointer = ElementType.FnPtr,
-               Object = ElementType.Object,
-               MVar = ElementType.MVar,
-               RequiredModifier = ElementType.CModReqD,
-               OptionalModifier = ElementType.CModOpt,
-               Sentinel = ElementType.Sentinel,
-               Pinned = ElementType.Pinned,
-       }
-
-       public class TypeReference : MemberReference, IGenericParameterProvider, IGenericContext {
-
-               string @namespace;
-               bool value_type;
-               internal IMetadataScope scope;
-               internal ModuleDefinition module;
-
-               internal ElementType etype = ElementType.None;
-
-               string fullname;
-
-               protected Collection<GenericParameter> generic_parameters;
-
-               public override string Name {
-                       get { return base.Name; }
-                       set {
-                               base.Name = value;
-                               fullname = null;
-                       }
-               }
-
-               public virtual string Namespace {
-                       get { return @namespace; }
-                       set {
-                               @namespace = value;
-                               fullname = null;
-                       }
-               }
-
-               public virtual bool IsValueType {
-                       get { return value_type; }
-                       set { value_type = value; }
-               }
-
-               public override ModuleDefinition Module {
-                       get {
-                               if (module != null)
-                                       return module;
-
-                               var declaring_type = this.DeclaringType;
-                               if (declaring_type != null)
-                                       return declaring_type.Module;
-
-                               return null;
-                       }
-               }
-
-               IGenericParameterProvider IGenericContext.Type {
-                       get { return this; }
-               }
-
-               IGenericParameterProvider IGenericContext.Method {
-                       get { return null; }
-               }
-
-               GenericParameterType IGenericParameterProvider.GenericParameterType {
-                       get { return GenericParameterType.Type; }
-               }
-
-               public virtual bool HasGenericParameters {
-                       get { return !generic_parameters.IsNullOrEmpty (); }
-               }
-
-               public virtual Collection<GenericParameter> GenericParameters {
-                       get {
-                               if (generic_parameters != null)
-                                       return generic_parameters;
-
-                               return generic_parameters = new GenericParameterCollection (this);
-                       }
-               }
-
-               public virtual IMetadataScope Scope {
-                       get {
-                               var declaring_type = this.DeclaringType;
-                               if (declaring_type != null)
-                                       return declaring_type.Scope;
-
-                               return scope;
-                       }
-               }
-
-               public bool IsNested {
-                       get { return this.DeclaringType != null; }
-               }
-
-               public override TypeReference DeclaringType {
-                       get { return base.DeclaringType; }
-                       set {
-                               base.DeclaringType = value;
-                               fullname = null;
-                       }
-               }
-
-               public override string FullName {
-                       get {
-                               if (fullname != null)
-                                       return fullname;
-
-                               if (IsNested)
-                                       return fullname = DeclaringType.FullName + "/" + Name;
-
-                               if (string.IsNullOrEmpty (@namespace))
-                                       return fullname = Name;
-
-                               return fullname = @namespace + "." + Name;
-                       }
-               }
-
-               public virtual bool IsByReference {
-                       get { return false; }
-               }
-
-               public virtual bool IsPointer {
-                       get { return false; }
-               }
-
-               public virtual bool IsSentinel {
-                       get { return false; }
-               }
-
-               public virtual bool IsArray {
-                       get { return false; }
-               }
-
-               public virtual bool IsGenericParameter {
-                       get { return false; }
-               }
-
-               public virtual bool IsGenericInstance {
-                       get { return false; }
-               }
-
-               public virtual bool IsRequiredModifier {
-                       get { return false; }
-               }
-
-               public virtual bool IsOptionalModifier {
-                       get { return false; }
-               }
-
-               public virtual bool IsPinned {
-                       get { return false; }
-               }
-
-               public virtual bool IsFunctionPointer {
-                       get { return false; }
-               }
-
-               public bool IsPrimitive {
-                       get {
-                               switch (etype) {
-                               case ElementType.Boolean:
-                               case ElementType.Char:
-                               case ElementType.I:
-                               case ElementType.U:
-                               case ElementType.I1:
-                               case ElementType.U1:
-                               case ElementType.I2:
-                               case ElementType.U2:
-                               case ElementType.I4:
-                               case ElementType.U4:
-                               case ElementType.I8:
-                               case ElementType.U8:
-                               case ElementType.R4:
-                               case ElementType.R8:
-                                       return true;
-                               default:
-                                       return false;
-                               }
-                       }
-               }
-
-               public virtual MetadataType MetadataType {
-                       get {
-                               switch (etype) {
-                               case ElementType.None:
-                                       return IsValueType ? MetadataType.ValueType : MetadataType.Class;
-                               default:
-                                       return (MetadataType) etype;
-                               }
-                       }
-               }
-
-               protected TypeReference (string @namespace, string name)
-                       : base (name)
-               {
-                       this.@namespace = @namespace ?? string.Empty;
-                       this.token = new MetadataToken (TokenType.TypeRef, 0);
-               }
-
-               public TypeReference (string @namespace, string name, ModuleDefinition module, IMetadataScope scope)
-                       : this (@namespace, name)
-               {
-                       this.module = module;
-                       this.scope = scope;
-               }
-
-               public TypeReference (string @namespace, string name, ModuleDefinition module, IMetadataScope scope, bool valueType) :
-                       this (@namespace, name, module, scope)
-               {
-                       value_type = valueType;
-               }
-
-               public virtual TypeReference GetElementType ()
-               {
-                       return this;
-               }
-
-               public virtual TypeDefinition Resolve ()
-               {
-                       var module = this.Module;
-                       if (module == null)
-                               throw new NotSupportedException ();
-
-                       return module.Resolve (this);
-               }
-       }
-
-       static partial class Mixin {
-
-               public static bool IsTypeOf (this TypeReference self, string @namespace, string name)
-               {
-                       return self.Name == name
-                               && self.Namespace == @namespace;
-               }
-
-               public static bool IsTypeSpecification (this TypeReference type)
-               {
-                       switch (type.etype) {
-                       case ElementType.Array:
-                       case ElementType.ByRef:
-                       case ElementType.CModOpt:
-                       case ElementType.CModReqD:
-                       case ElementType.FnPtr:
-                       case ElementType.GenericInst:
-                       case ElementType.MVar:
-                       case ElementType.Pinned:
-                       case ElementType.Ptr:
-                       case ElementType.SzArray:
-                       case ElementType.Sentinel:
-                       case ElementType.Var:
-                               return true;
-                       }
-
-                       return false;
-               }
-
-               public static TypeDefinition CheckedResolve (this TypeReference self)
-               {
-                       var type = self.Resolve ();
-                       if (type == null)
-                               throw new ResolutionException (self);
-
-                       return type;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/TypeSpecification.cs b/mcs/class/Mono.Cecil/Mono.Cecil/TypeSpecification.cs
deleted file mode 100644 (file)
index aa9b653..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-//
-// TypeSpecification.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public abstract class TypeSpecification : TypeReference {
-
-               readonly TypeReference element_type;
-
-               public TypeReference ElementType {
-                       get { return element_type; }
-               }
-
-               public override string Name {
-                       get { return element_type.Name; }
-                       set { throw new NotSupportedException (); }
-               }
-
-               public override string Namespace {
-                       get { return element_type.Namespace; }
-                       set { throw new NotSupportedException (); }
-               }
-
-               public override IMetadataScope Scope {
-                       get { return element_type.Scope; }
-               }
-
-               public override ModuleDefinition Module {
-                       get { return element_type.Module; }
-               }
-
-               public override string FullName {
-                       get { return element_type.FullName; }
-               }
-
-               internal override bool ContainsGenericParameter {
-                       get { return element_type.ContainsGenericParameter; }
-               }
-
-               public override MetadataType MetadataType {
-                       get { return (MetadataType) etype; }
-               }
-
-               internal TypeSpecification (TypeReference type)
-                       : base (null, null)
-               {
-                       this.element_type = type;
-                       this.token = new MetadataToken (TokenType.TypeSpec);
-               }
-
-               public override TypeReference GetElementType ()
-               {
-                       return element_type.GetElementType ();
-               }
-       }
-
-       static partial class Mixin {
-
-               public static void CheckType (TypeReference type)
-               {
-                       if (type == null)
-                               throw new ArgumentNullException ("type");
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/TypeSystem.cs b/mcs/class/Mono.Cecil/Mono.Cecil/TypeSystem.cs
deleted file mode 100644 (file)
index dc20b7b..0000000
+++ /dev/null
@@ -1,273 +0,0 @@
-//
-// TypeSystem.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-using Mono.Cecil.Metadata;
-
-namespace Mono.Cecil {
-
-       public abstract class TypeSystem {
-
-               sealed class CorlibTypeSystem : TypeSystem {
-
-                       public CorlibTypeSystem (ModuleDefinition module)
-                               : base (module)
-                       {
-                       }
-
-                       internal override TypeReference LookupType (string @namespace, string name)
-                       {
-                               var metadata = module.MetadataSystem;
-                               if (metadata.Types == null)
-                                       Initialize (module.Types);
-
-                               return module.Read (new Row<string, string> (@namespace, name), (row, reader) => {
-                                       var types = reader.metadata.Types;
-
-                                       for (int i = 0; i < types.Length; i++) {
-                                               if (types [i] == null)
-                                                       types [i] = reader.GetTypeDefinition ((uint) i + 1);
-
-                                               var type = types [i];
-
-                                               if (type.Name == row.Col2 && type.Namespace == row.Col1)
-                                                       return type;
-                                       }
-
-                                       return null;
-                               });
-                       }
-
-                       static void Initialize (object obj)
-                       {
-                       }
-               }
-
-               sealed class CommonTypeSystem : TypeSystem {
-
-                       AssemblyNameReference corlib;
-
-                       public CommonTypeSystem (ModuleDefinition module)
-                               : base (module)
-                       {
-                       }
-
-                       internal override TypeReference LookupType (string @namespace, string name)
-                       {
-                               return CreateTypeReference (@namespace, name);
-                       }
-
-                       public AssemblyNameReference GetCorlibReference ()
-                       {
-                               if (corlib != null)
-                                       return corlib;
-
-                               const string mscorlib = "mscorlib";
-
-                               var references = module.AssemblyReferences;
-
-                               for (int i = 0; i < references.Count; i++) {
-                                       var reference = references [i];
-                                       if (reference.Name == mscorlib)
-                                               return corlib = reference;
-                               }
-
-                               corlib = new AssemblyNameReference {
-                                       Name = mscorlib,
-                                       Version = GetCorlibVersion (),
-                                       PublicKeyToken = new byte [] { 0xb7, 0x7a, 0x5c, 0x56, 0x19, 0x34, 0xe0, 0x89 },
-                               };
-
-                               references.Add (corlib);
-
-                               return corlib;
-                       }
-
-                       Version GetCorlibVersion ()
-                       {
-                               switch (module.Runtime) {
-                               case TargetRuntime.Net_1_0:
-                               case TargetRuntime.Net_1_1:
-                                       return new Version (1, 0, 0, 0);
-                               case TargetRuntime.Net_2_0:
-                                       return new Version (2, 0, 0, 0);
-                               case TargetRuntime.Net_4_0:
-                                       return new Version (4, 0, 0, 0);
-                               default:
-                                       throw new NotSupportedException ();
-                               }
-                       }
-
-                       TypeReference CreateTypeReference (string @namespace, string name)
-                       {
-                               return new TypeReference (@namespace, name, module, GetCorlibReference ());
-                       }
-               }
-
-               readonly ModuleDefinition module;
-
-               TypeReference type_object;
-               TypeReference type_void;
-               TypeReference type_bool;
-               TypeReference type_char;
-               TypeReference type_sbyte;
-               TypeReference type_byte;
-               TypeReference type_int16;
-               TypeReference type_uint16;
-               TypeReference type_int32;
-               TypeReference type_uint32;
-               TypeReference type_int64;
-               TypeReference type_uint64;
-               TypeReference type_single;
-               TypeReference type_double;
-               TypeReference type_intptr;
-               TypeReference type_uintptr;
-               TypeReference type_string;
-               TypeReference type_typedref;
-
-               TypeSystem (ModuleDefinition module)
-               {
-                       this.module = module;
-               }
-
-               internal static TypeSystem CreateTypeSystem (ModuleDefinition module)
-               {
-                       if (IsCorlib (module))
-                               return new CorlibTypeSystem (module);
-
-                       return new CommonTypeSystem (module);
-               }
-
-               static bool IsCorlib (ModuleDefinition module)
-               {
-                       if (module.Assembly == null)
-                               return false;
-
-                       return module.Assembly.Name.Name == "mscorlib";
-               }
-
-               internal abstract TypeReference LookupType (string @namespace, string name);
-
-               TypeReference LookupSystemType (string name, ElementType element_type)
-               {
-                       var type = LookupType ("System", name);
-                       type.etype = element_type;
-                       return type;
-               }
-
-               TypeReference LookupSystemValueType (string name, ElementType element_type)
-               {
-                       var type = LookupSystemType (name, element_type);
-                       type.IsValueType = true;
-                       return type;
-               }
-
-               public IMetadataScope Corlib {
-                       get {
-                               var common = this as CommonTypeSystem;
-                               if (common == null)
-                                       return module;
-
-                               return common.GetCorlibReference ();
-                       }
-               }
-
-               public TypeReference Object {
-                       get { return type_object ?? (type_object = LookupSystemType ("Object", ElementType.Object)); }
-               }
-
-               public TypeReference Void {
-                       get { return type_void ?? (type_void = LookupSystemType ("Void", ElementType.Void)); }
-               }
-
-               public TypeReference Boolean {
-                       get { return type_bool ?? (type_bool = LookupSystemValueType ("Boolean", ElementType.Boolean)); }
-               }
-
-               public TypeReference Char {
-                       get { return type_char ?? (type_char = LookupSystemValueType ("Char", ElementType.Char)); }
-               }
-
-               public TypeReference SByte {
-                       get { return type_sbyte ?? (type_sbyte = LookupSystemValueType ("SByte", ElementType.I1)); }
-               }
-
-               public TypeReference Byte {
-                       get { return type_byte ?? (type_byte = LookupSystemValueType ("Byte", ElementType.U1)); }
-               }
-
-               public TypeReference Int16 {
-                       get { return type_int16 ?? (type_int16 = LookupSystemValueType ("Int16", ElementType.I2)); }
-               }
-
-               public TypeReference UInt16 {
-                       get { return type_uint16 ?? (type_uint16 = LookupSystemValueType ("UInt16", ElementType.U2)); }
-               }
-
-               public TypeReference Int32 {
-                       get { return type_int32 ?? (type_int32 = LookupSystemValueType ("Int32", ElementType.I4)); }
-               }
-
-               public TypeReference UInt32 {
-                       get { return type_uint32 ?? (type_uint32 = LookupSystemValueType ("UInt32", ElementType.U4)); }
-               }
-
-               public TypeReference Int64 {
-                       get { return type_int64 ?? (type_int64 = LookupSystemValueType ("Int64", ElementType.I8)); }
-               }
-
-               public TypeReference UInt64 {
-                       get { return type_uint64 ?? (type_uint64 = LookupSystemValueType ("UInt64", ElementType.U8)); }
-               }
-
-               public TypeReference Single {
-                       get { return type_single ?? (type_single = LookupSystemValueType ("Single", ElementType.R4)); }
-               }
-
-               public TypeReference Double {
-                       get { return type_double ?? (type_double = LookupSystemValueType ("Double", ElementType.R8)); }
-               }
-
-               public TypeReference IntPtr {
-                       get { return type_intptr ?? (type_intptr = LookupSystemValueType ("IntPtr", ElementType.I)); }
-               }
-
-               public TypeReference UIntPtr {
-                       get { return type_uintptr ?? (type_uintptr = LookupSystemValueType ("UIntPtr", ElementType.U)); }
-               }
-
-               public TypeReference String {
-                       get { return type_string ?? (type_string = LookupSystemType ("String", ElementType.String)); }
-               }
-
-               public TypeReference TypedReference {
-                       get { return type_typedref ?? (type_typedref = LookupSystemValueType ("TypedReference", ElementType.TypedByRef)); }
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Cecil/VariantType.cs b/mcs/class/Mono.Cecil/Mono.Cecil/VariantType.cs
deleted file mode 100644 (file)
index 76562f6..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-//
-// VariantType.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-namespace Mono.Cecil {
-
-       public enum VariantType {
-               None = 0,
-               I2 = 2,
-               I4 = 3,
-               R4 = 4,
-               R8 = 5,
-               CY = 6,
-               Date = 7,
-               BStr = 8,
-               Dispatch = 9,
-               Error = 10,
-               Bool = 11,
-               Variant = 12,
-               Unknown = 13,
-               Decimal = 14,
-               I1 = 16,
-               UI1 = 17,
-               UI2 = 18,
-               UI4 = 19,
-               Int = 22,
-               UInt = 23
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Collections.Generic/Collection.cs b/mcs/class/Mono.Cecil/Mono.Collections.Generic/Collection.cs
deleted file mode 100644 (file)
index 4d92717..0000000
+++ /dev/null
@@ -1,420 +0,0 @@
-//
-// Collection.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-
-namespace Mono.Collections.Generic {
-
-       public class Collection<T> : IList<T>, IList {
-
-               internal T [] items;
-               internal int size;
-               int version;
-
-               public int Count {
-                       get { return size; }
-               }
-
-               public T this [int index] {
-                       get {
-                               if (index >= size)
-                                       throw new ArgumentOutOfRangeException ();
-
-                               return items [index];
-                       }
-                       set {
-                               CheckIndex (index);
-                               if (index == size)
-                                       throw new ArgumentOutOfRangeException ();
-
-                               OnSet (value, index);
-
-                               items [index] = value;
-                       }
-               }
-
-               bool ICollection<T>.IsReadOnly {
-                       get { return false; }
-               }
-
-               bool IList.IsFixedSize {
-                       get { return false; }
-               }
-
-               bool IList.IsReadOnly {
-                       get { return false; }
-               }
-
-               object IList.this [int index] {
-                       get { return this [index]; }
-                       set {
-                               CheckIndex (index);
-
-                               try {
-                                       this [index] = (T) value;
-                                       return;
-                               } catch (InvalidCastException) {
-                               } catch (NullReferenceException) {
-                               }
-
-                               throw new ArgumentException ();
-                       }
-               }
-
-               int ICollection.Count {
-                       get { return Count; }
-               }
-
-               bool ICollection.IsSynchronized {
-                       get { return false; }
-               }
-
-               object ICollection.SyncRoot {
-                       get { return this; }
-               }
-
-               public Collection ()
-               {
-                       items = Empty<T>.Array;
-               }
-
-               public Collection (int capacity)
-               {
-                       if (capacity < 0)
-                               throw new ArgumentOutOfRangeException ();
-
-                       items = new T [capacity];
-               }
-
-               public Collection (ICollection<T> items)
-               {
-                       if (items == null)
-                               throw new ArgumentNullException ("items");
-
-                       this.items = new T [items.Count];
-                       items.CopyTo (this.items, 0);
-                       this.size = this.items.Length;
-               }
-
-               public void Add (T item)
-               {
-                       if (size == items.Length)
-                               Grow (1);
-
-                       OnAdd (item, size);
-
-                       items [size++] = item;
-                       version++;
-               }
-
-               public bool Contains (T item)
-               {
-                       return IndexOf (item) != -1;
-               }
-
-               public int IndexOf (T item)
-               {
-                       return Array.IndexOf (items, item, 0, size);
-               }
-
-               public void Insert (int index, T item)
-               {
-                       CheckIndex (index);
-                       if (size == items.Length)
-                               Grow (1);
-
-                       OnInsert (item, index);
-
-                       Shift (index, 1);
-                       items [index] = item;
-                       version++;
-               }
-
-               public void RemoveAt (int index)
-               {
-                       if (index < 0 || index >= size)
-                               throw new ArgumentOutOfRangeException ();
-
-                       var item = items [index];
-
-                       OnRemove (item, index);
-
-                       Shift (index, -1);
-                       Array.Clear (items, size, 1);
-                       version++;
-               }
-
-               public bool Remove (T item)
-               {
-                       var index = IndexOf (item);
-                       if (index == -1)
-                               return false;
-
-                       OnRemove (item, index);
-
-                       Shift (index, -1);
-                       Array.Clear (items, size, 1);
-                       version++;
-
-                       return true;
-               }
-
-               public void Clear ()
-               {
-                       OnClear ();
-
-                       Array.Clear (items, 0, size);
-                       size = 0;
-                       version++;
-               }
-
-               public void CopyTo (T [] array, int arrayIndex)
-               {
-                       Array.Copy (items, 0, array, arrayIndex, size);
-               }
-
-               public T [] ToArray ()
-               {
-                       var array = new T [size];
-                       Array.Copy (items, 0, array, 0, size);
-                       return array;
-               }
-
-               void CheckIndex (int index)
-               {
-                       if (index < 0 || index > size)
-                               throw new ArgumentOutOfRangeException ();
-               }
-
-               void Shift (int start, int delta)
-               {
-                       if (delta < 0)
-                               start -= delta;
-
-                       if (start < size)
-                               Array.Copy (items, start, items, start + delta, size - start);
-
-                       size += delta;
-
-                       if (delta < 0)
-                               Array.Clear (items, size, -delta);
-               }
-
-               protected virtual void OnAdd (T item, int index)
-               {
-               }
-
-               protected virtual void OnInsert (T item, int index)
-               {
-               }
-
-               protected virtual void OnSet (T item, int index)
-               {
-               }
-
-               protected virtual void OnRemove (T item, int index)
-               {
-               }
-
-               protected virtual void OnClear ()
-               {
-               }
-
-               internal virtual void Grow (int desired)
-               {
-                       int new_size = size + desired;
-                       if (new_size <= items.Length)
-                               return;
-
-                       const int default_capacity = 4;
-
-                       new_size = System.Math.Max (
-                               System.Math.Max (items.Length * 2, default_capacity),
-                               new_size);
-
-#if !CF
-                       Array.Resize (ref items, new_size);
-#else
-                       var array = new T [new_size];
-                       Array.Copy (items, array, size);
-                       items = array;
-#endif
-               }
-
-               int IList.Add (object value)
-               {
-                       try {
-                               Add ((T) value);
-                               return size - 1;
-                       } catch (InvalidCastException) {
-                       } catch (NullReferenceException) {
-                       }
-
-                       throw new ArgumentException ();
-               }
-
-               void IList.Clear ()
-               {
-                       Clear ();
-               }
-
-               bool IList.Contains (object value)
-               {
-                       return ((IList) this).IndexOf (value) > -1;
-               }
-
-               int IList.IndexOf (object value)
-               {
-                       try {
-                               return IndexOf ((T) value);
-                       } catch (InvalidCastException) {
-                       } catch (NullReferenceException) {
-                       }
-
-                       return -1;
-               }
-
-               void IList.Insert (int index, object value)
-               {
-                       CheckIndex (index);
-
-                       try {
-                               Insert (index, (T) value);
-                               return;
-                       } catch (InvalidCastException) {
-                       } catch (NullReferenceException) {
-                       }
-
-                       throw new ArgumentException ();
-               }
-
-               void IList.Remove (object value)
-               {
-                       try {
-                               Remove ((T) value);
-                       } catch (InvalidCastException) {
-                       } catch (NullReferenceException) {
-                       }
-               }
-
-               void IList.RemoveAt (int index)
-               {
-                       RemoveAt (index);
-               }
-
-               void ICollection.CopyTo (Array array, int index)
-               {
-                       Array.Copy (items, 0, array, index, size);
-               }
-
-               public Enumerator GetEnumerator ()
-               {
-                       return new Enumerator (this);
-               }
-
-               IEnumerator IEnumerable.GetEnumerator ()
-               {
-                       return new Enumerator (this);
-               }
-
-               IEnumerator<T> IEnumerable<T>.GetEnumerator ()
-               {
-                       return new Enumerator (this);
-               }
-
-               public struct Enumerator : IEnumerator<T>, IDisposable {
-
-                       Collection<T> collection;
-                       T current;
-
-                       int next;
-                       readonly int version;
-
-                       public T Current {
-                               get { return current; }
-                       }
-
-                       object IEnumerator.Current {
-                               get {
-                                       CheckState ();
-
-                                       if (next <= 0)
-                                               throw new InvalidOperationException ();
-
-                                       return current;
-                               }
-                       }
-
-                       internal Enumerator (Collection<T> collection)
-                               : this ()
-                       {
-                               this.collection = collection;
-                               this.version = collection.version;
-                       }
-
-                       public bool MoveNext ()
-                       {
-                               CheckState ();
-
-                               if (next < 0)
-                                       return false;
-
-                               if (next < collection.size) {
-                                       current = collection.items [next++];
-                                       return true;
-                               }
-
-                               next = -1;
-                               return false;
-                       }
-
-                       public void Reset ()
-                       {
-                               CheckState ();
-
-                               next = 0;
-                       }
-
-                       void CheckState ()
-                       {
-                               if (collection == null)
-                                       throw new ObjectDisposedException (GetType ().FullName);
-
-                               if (version != collection.version)
-                                       throw new InvalidOperationException ();
-                       }
-
-                       public void Dispose ()
-                       {
-                               collection = null;
-                       }
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Collections.Generic/ReadOnlyCollection.cs b/mcs/class/Mono.Cecil/Mono.Collections.Generic/ReadOnlyCollection.cs
deleted file mode 100644 (file)
index 7f24df6..0000000
+++ /dev/null
@@ -1,112 +0,0 @@
-//
-// ReadOnlyCollection.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Collections;
-using System .Collections.Generic;
-
-namespace Mono.Collections.Generic {
-
-       public sealed class ReadOnlyCollection<T> : Collection<T>, ICollection<T>, IList {
-
-               static ReadOnlyCollection<T> empty;
-
-               public static ReadOnlyCollection<T> Empty {
-                       get { return empty ?? (empty = new ReadOnlyCollection<T> ()); }
-               }
-
-               bool ICollection<T>.IsReadOnly {
-                       get { return true; }
-               }
-
-               bool IList.IsFixedSize {
-                       get { return true; }
-               }
-
-               bool IList.IsReadOnly {
-                       get { return true; }
-               }
-
-               private ReadOnlyCollection ()
-               {
-               }
-
-               public ReadOnlyCollection (T [] array)
-               {
-                       if (array == null)
-                               throw new ArgumentNullException ();
-
-                       Initialize (array, array.Length);
-               }
-
-               public ReadOnlyCollection (Collection<T> collection)
-               {
-                       if (collection == null)
-                               throw new ArgumentNullException ();
-
-                       Initialize (collection.items, collection.size);
-               }
-
-               void Initialize (T [] items, int size)
-               {
-                       this.items = new T [size];
-                       Array.Copy (items, 0, this.items, 0, size);
-                       this.size = size;
-               }
-
-               internal override void Grow (int desired)
-               {
-                       throw new InvalidOperationException ();
-               }
-
-               protected override void OnAdd (T item, int index)
-               {
-                       throw new InvalidOperationException ();
-               }
-
-               protected override void OnClear ()
-               {
-                       throw new InvalidOperationException ();
-               }
-
-               protected override void OnInsert (T item, int index)
-               {
-                       throw new InvalidOperationException ();
-               }
-
-               protected override void OnRemove (T item, int index)
-               {
-                       throw new InvalidOperationException ();
-               }
-
-               protected override void OnSet (T item, int index)
-               {
-                       throw new InvalidOperationException ();
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono.Security.Cryptography/CryptoConvert.cs b/mcs/class/Mono.Cecil/Mono.Security.Cryptography/CryptoConvert.cs
deleted file mode 100644 (file)
index 26a4ba2..0000000
+++ /dev/null
@@ -1,243 +0,0 @@
-//
-// CryptoConvert.cs - Crypto Convertion Routines
-//
-// Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
-//
-// (C) 2003 Motus Technologies Inc. (http://www.motus.com)
-// Copyright (C) 2004-2006 Novell Inc. (http://www.novell.com)
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.Security.Cryptography;
-
-#if !(SILVERLIGHT || READ_ONLY)
-
-namespace Mono.Security.Cryptography {
-
-       static class CryptoConvert {
-
-               static private int ToInt32LE (byte [] bytes, int offset)
-               {
-                       return (bytes [offset+3] << 24) | (bytes [offset+2] << 16) | (bytes [offset+1] << 8) | bytes [offset];
-               }
-
-               static private uint ToUInt32LE (byte [] bytes, int offset)
-               {
-                       return (uint)((bytes [offset+3] << 24) | (bytes [offset+2] << 16) | (bytes [offset+1] << 8) | bytes [offset]);
-               }
-
-               static private byte[] Trim (byte[] array)
-               {
-                       for (int i=0; i < array.Length; i++) {
-                               if (array [i] != 0x00) {
-                                       byte[] result = new byte [array.Length - i];
-                                       Buffer.BlockCopy (array, i, result, 0, result.Length);
-                                       return result;
-                               }
-                       }
-                       return null;
-               }
-
-               static RSA FromCapiPrivateKeyBlob (byte[] blob, int offset)
-               {
-                       RSAParameters rsap = new RSAParameters ();
-                       try {
-                               if ((blob [offset]   != 0x07) ||                                // PRIVATEKEYBLOB (0x07)
-                                   (blob [offset+1] != 0x02) ||                                // Version (0x02)
-                                   (blob [offset+2] != 0x00) ||                                // Reserved (word)
-                                   (blob [offset+3] != 0x00) ||
-                                   (ToUInt32LE (blob, offset+8) != 0x32415352))        // DWORD magic = RSA2
-                                       throw new CryptographicException ("Invalid blob header");
-
-                               // ALGID (CALG_RSA_SIGN, CALG_RSA_KEYX, ...)
-                               // int algId = ToInt32LE (blob, offset+4);
-
-                               // DWORD bitlen
-                               int bitLen = ToInt32LE (blob, offset+12);
-
-                               // DWORD public exponent
-                               byte[] exp = new byte [4];
-                               Buffer.BlockCopy (blob, offset+16, exp, 0, 4);
-                               Array.Reverse (exp);
-                               rsap.Exponent = Trim (exp);
-
-                               int pos = offset+20;
-                               // BYTE modulus[rsapubkey.bitlen/8];
-                               int byteLen = (bitLen >> 3);
-                               rsap.Modulus = new byte [byteLen];
-                               Buffer.BlockCopy (blob, pos, rsap.Modulus, 0, byteLen);
-                               Array.Reverse (rsap.Modulus);
-                               pos += byteLen;
-
-                               // BYTE prime1[rsapubkey.bitlen/16];
-                               int byteHalfLen = (byteLen >> 1);
-                               rsap.P = new byte [byteHalfLen];
-                               Buffer.BlockCopy (blob, pos, rsap.P, 0, byteHalfLen);
-                               Array.Reverse (rsap.P);
-                               pos += byteHalfLen;
-
-                               // BYTE prime2[rsapubkey.bitlen/16];
-                               rsap.Q = new byte [byteHalfLen];
-                               Buffer.BlockCopy (blob, pos, rsap.Q, 0, byteHalfLen);
-                               Array.Reverse (rsap.Q);
-                               pos += byteHalfLen;
-
-                               // BYTE exponent1[rsapubkey.bitlen/16];
-                               rsap.DP = new byte [byteHalfLen];
-                               Buffer.BlockCopy (blob, pos, rsap.DP, 0, byteHalfLen);
-                               Array.Reverse (rsap.DP);
-                               pos += byteHalfLen;
-
-                               // BYTE exponent2[rsapubkey.bitlen/16];
-                               rsap.DQ = new byte [byteHalfLen];
-                               Buffer.BlockCopy (blob, pos, rsap.DQ, 0, byteHalfLen);
-                               Array.Reverse (rsap.DQ);
-                               pos += byteHalfLen;
-
-                               // BYTE coefficient[rsapubkey.bitlen/16];
-                               rsap.InverseQ = new byte [byteHalfLen];
-                               Buffer.BlockCopy (blob, pos, rsap.InverseQ, 0, byteHalfLen);
-                               Array.Reverse (rsap.InverseQ);
-                               pos += byteHalfLen;
-
-                               // ok, this is hackish but CryptoAPI support it so...
-                               // note: only works because CRT is used by default
-                               // http://bugzilla.ximian.com/show_bug.cgi?id=57941
-                               rsap.D = new byte [byteLen]; // must be allocated
-                               if (pos + byteLen + offset <= blob.Length) {
-                                       // BYTE privateExponent[rsapubkey.bitlen/8];
-                                       Buffer.BlockCopy (blob, pos, rsap.D, 0, byteLen);
-                                       Array.Reverse (rsap.D);
-                               }
-                       }
-                       catch (Exception e) {
-                               throw new CryptographicException ("Invalid blob.", e);
-                       }
-
-                       RSA rsa = null;
-                       try {
-                               rsa = RSA.Create ();
-                               rsa.ImportParameters (rsap);
-                       }
-                       catch (CryptographicException ce) {
-                               // this may cause problem when this code is run under
-                               // the SYSTEM identity on Windows (e.g. ASP.NET). See
-                               // http://bugzilla.ximian.com/show_bug.cgi?id=77559
-                               try {
-                                       CspParameters csp = new CspParameters ();
-                                       csp.Flags = CspProviderFlags.UseMachineKeyStore;
-                                       rsa = new RSACryptoServiceProvider (csp);
-                                       rsa.ImportParameters (rsap);
-                               }
-                               catch {
-                                       // rethrow original, not the later, exception if this fails
-                                       throw ce;
-                               }
-                       }
-                       return rsa;
-               }
-
-               static RSA FromCapiPublicKeyBlob (byte[] blob, int offset)
-               {
-                       try {
-                               if ((blob [offset]   != 0x06) ||                                // PUBLICKEYBLOB (0x06)
-                                   (blob [offset+1] != 0x02) ||                                // Version (0x02)
-                                   (blob [offset+2] != 0x00) ||                                // Reserved (word)
-                                   (blob [offset+3] != 0x00) ||
-                                   (ToUInt32LE (blob, offset+8) != 0x31415352))        // DWORD magic = RSA1
-                                       throw new CryptographicException ("Invalid blob header");
-
-                               // ALGID (CALG_RSA_SIGN, CALG_RSA_KEYX, ...)
-                               // int algId = ToInt32LE (blob, offset+4);
-
-                               // DWORD bitlen
-                               int bitLen = ToInt32LE (blob, offset+12);
-
-                               // DWORD public exponent
-                               RSAParameters rsap = new RSAParameters ();
-                               rsap.Exponent = new byte [3];
-                               rsap.Exponent [0] = blob [offset+18];
-                               rsap.Exponent [1] = blob [offset+17];
-                               rsap.Exponent [2] = blob [offset+16];
-
-                               int pos = offset+20;
-                               // BYTE modulus[rsapubkey.bitlen/8];
-                               int byteLen = (bitLen >> 3);
-                               rsap.Modulus = new byte [byteLen];
-                               Buffer.BlockCopy (blob, pos, rsap.Modulus, 0, byteLen);
-                               Array.Reverse (rsap.Modulus);
-
-                               RSA rsa = null;
-                               try {
-                                       rsa = RSA.Create ();
-                                       rsa.ImportParameters (rsap);
-                               }
-                               catch (CryptographicException) {
-                                       // this may cause problem when this code is run under
-                                       // the SYSTEM identity on Windows (e.g. ASP.NET). See
-                                       // http://bugzilla.ximian.com/show_bug.cgi?id=77559
-                                       CspParameters csp = new CspParameters ();
-                                       csp.Flags = CspProviderFlags.UseMachineKeyStore;
-                                       rsa = new RSACryptoServiceProvider (csp);
-                                       rsa.ImportParameters (rsap);
-                               }
-                               return rsa;
-                       }
-                       catch (Exception e) {
-                               throw new CryptographicException ("Invalid blob.", e);
-                       }
-               }
-
-               // PRIVATEKEYBLOB
-               // PUBLICKEYBLOB
-               static public RSA FromCapiKeyBlob (byte[] blob)
-               {
-                       return FromCapiKeyBlob (blob, 0);
-               }
-
-               static public RSA FromCapiKeyBlob (byte[] blob, int offset)
-               {
-                       if (blob == null)
-                               throw new ArgumentNullException ("blob");
-                       if (offset >= blob.Length)
-                               throw new ArgumentException ("blob is too small.");
-
-                       switch (blob [offset]) {
-                               case 0x00:
-                                       // this could be a public key inside an header
-                                       // like "sn -e" would produce
-                                       if (blob [offset + 12] == 0x06) {
-                                               return FromCapiPublicKeyBlob (blob, offset + 12);
-                                       }
-                                       break;
-                               case 0x06:
-                                       return FromCapiPublicKeyBlob (blob, offset);
-                               case 0x07:
-                                       return FromCapiPrivateKeyBlob (blob, offset);
-                       }
-                       throw new CryptographicException ("Unknown blob format.");
-               }
-       }
-}
-
-#endif
diff --git a/mcs/class/Mono.Cecil/Mono.Security.Cryptography/CryptoService.cs b/mcs/class/Mono.Cecil/Mono.Security.Cryptography/CryptoService.cs
deleted file mode 100644 (file)
index 58b6cfa..0000000
+++ /dev/null
@@ -1,177 +0,0 @@
-//
-// CryptoService.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-using System.IO;
-using System.Reflection;
-using System.Security.Cryptography;
-
-#if !READ_ONLY
-
-#if !SILVERLIGHT && !CF
-using System.Runtime.Serialization;
-using Mono.Security.Cryptography;
-#endif
-
-using Mono.Cecil.PE;
-
-namespace Mono.Cecil {
-
-       // Most of this code has been adapted
-       // from Jeroen Frijters' fantastic work
-       // in IKVM.Reflection.Emit. Thanks!
-
-       static class CryptoService {
-
-#if !SILVERLIGHT && !CF
-               public static void StrongName (Stream stream, ImageWriter writer, StrongNameKeyPair key_pair)
-               {
-                       int strong_name_pointer;
-
-                       var strong_name = CreateStrongName (key_pair, HashStream (stream, writer, out strong_name_pointer));
-                       PatchStrongName (stream, strong_name_pointer, strong_name);
-               }
-
-               static void PatchStrongName (Stream stream, int strong_name_pointer, byte [] strong_name)
-               {
-                       stream.Seek (strong_name_pointer, SeekOrigin.Begin);
-                       stream.Write (strong_name, 0, strong_name.Length);
-               }
-
-               static byte [] CreateStrongName (StrongNameKeyPair key_pair, byte [] hash)
-               {
-                       const string hash_algo = "SHA1";
-
-                       using (var rsa = key_pair.CreateRSA ()) {
-                               var formatter = new RSAPKCS1SignatureFormatter (rsa);
-                               formatter.SetHashAlgorithm (hash_algo);
-
-                               byte [] signature = formatter.CreateSignature (hash);
-                               Array.Reverse (signature);
-
-                               return signature;
-                       }
-               }
-
-               static byte [] HashStream (Stream stream, ImageWriter writer, out int strong_name_pointer)
-               {
-                       const int buffer_size = 8192;
-
-                       var text = writer.text;
-                       var header_size = (int) writer.GetHeaderSize ();
-                       var text_section_pointer = (int) text.PointerToRawData;
-                       var strong_name_directory = writer.GetStrongNameSignatureDirectory ();
-
-                       if (strong_name_directory.Size == 0)
-                               throw new InvalidOperationException ();
-
-                       strong_name_pointer = (int) (text_section_pointer
-                               + (strong_name_directory.VirtualAddress - text.VirtualAddress));
-                       var strong_name_length = (int) strong_name_directory.Size;
-
-                       var sha1 = new SHA1Managed ();
-                       var buffer = new byte [buffer_size];
-                       using (var crypto_stream = new CryptoStream (Stream.Null, sha1, CryptoStreamMode.Write)) {
-
-                               stream.Seek (0, SeekOrigin.Begin);
-                               CopyStreamChunk (stream, crypto_stream, buffer, header_size);
-
-                               stream.Seek (text_section_pointer, SeekOrigin.Begin);
-                               CopyStreamChunk (stream, crypto_stream, buffer, (int) strong_name_pointer - text_section_pointer);
-
-                               stream.Seek (strong_name_length, SeekOrigin.Current);
-                               CopyStreamChunk (stream, crypto_stream, buffer, (int) (stream.Length - (strong_name_pointer + strong_name_length)));
-                       }
-
-                       return sha1.Hash;
-               }
-#endif
-               static void CopyStreamChunk (Stream stream, Stream dest_stream, byte [] buffer, int length)
-               {
-                       while (length > 0) {
-                               int read = stream.Read (buffer, 0, System.Math.Min (buffer.Length, length));
-                               dest_stream.Write (buffer, 0, read);
-                               length -= read;
-                       }
-               }
-
-               public static byte [] ComputeHash (string file)
-               {
-                       if (!File.Exists (file))
-                               return Empty<byte>.Array;
-
-                       const int buffer_size = 8192;
-
-                       var sha1 = new SHA1Managed ();
-
-                       using (var stream = new FileStream (file, FileMode.Open, FileAccess.Read, FileShare.Read)) {
-
-                               var buffer = new byte [buffer_size];
-
-                               using (var crypto_stream = new CryptoStream (Stream.Null, sha1, CryptoStreamMode.Write))
-                                       CopyStreamChunk (stream, crypto_stream, buffer, (int) stream.Length);
-                       }
-
-                       return sha1.Hash;
-               }
-       }
-
-#if !SILVERLIGHT && !CF
-       static partial class Mixin {
-
-               public static RSA CreateRSA (this StrongNameKeyPair key_pair)
-               {
-                       byte [] key;
-                       string key_container;
-
-                       if (!TryGetKeyContainer (key_pair, out key, out key_container))
-                               return CryptoConvert.FromCapiKeyBlob (key);
-
-                       var parameters = new CspParameters {
-                               Flags = CspProviderFlags.UseMachineKeyStore,
-                               KeyContainerName = key_container,
-                               KeyNumber = 2,
-                       };
-
-                       return new RSACryptoServiceProvider (parameters);
-               }
-
-               static bool TryGetKeyContainer (ISerializable key_pair, out byte [] key, out string key_container)
-               {
-                       var info = new SerializationInfo (typeof (StrongNameKeyPair), new FormatterConverter ());
-                       key_pair.GetObjectData (info, new StreamingContext ());
-
-                       key = (byte []) info.GetValue ("_keyPairArray", typeof (byte []));
-                       key_container = info.GetString ("_keyPairContainer");
-                       return key_container != null;
-               }
-       }
-#endif
-}
-
-#endif
diff --git a/mcs/class/Mono.Cecil/Mono/Actions.cs b/mcs/class/Mono.Cecil/Mono/Actions.cs
deleted file mode 100644 (file)
index 756438f..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-//
-// Actions.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-#if !NET_3_5 && !NET_4_0
-
-namespace Mono {
-       //delegate void Action ();
-       delegate void Action<T1, T2> (T1 arg1, T2 arg2);
-       //delegate void Action<T1, T2, T3> (T1 arg1, T2 arg2, T3 arg3);
-       //delegate void Action<T1, T2, T3, T4> (T1 arg1, T2 arg2, T3 arg3, T4 arg4);
-}
-
-#endif
diff --git a/mcs/class/Mono.Cecil/Mono/Empty.cs b/mcs/class/Mono.Cecil/Mono/Empty.cs
deleted file mode 100644 (file)
index d043a35..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-//
-// Empty.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using Mono.Collections.Generic;
-
-namespace Mono {
-
-       static class Empty<T> {
-
-               public static readonly T [] Array = new T [0];
-       }
-}
-
-namespace Mono.Cecil {
-
-       static partial class Mixin {
-
-               public static bool IsNullOrEmpty<T> (this T [] self)
-               {
-                       return self == null || self.Length == 0;
-               }
-
-               public static bool IsNullOrEmpty<T> (this Collection<T> self)
-               {
-                       return self == null || self.size == 0;
-               }
-       }
-}
diff --git a/mcs/class/Mono.Cecil/Mono/Funcs.cs b/mcs/class/Mono.Cecil/Mono/Funcs.cs
deleted file mode 100644 (file)
index 87bc6e9..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-//
-// Funcs.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-#if !NET_3_5 && !NET_4_0
-
-namespace Mono {
-       delegate TResult Func<TResult> ();
-       delegate TResult Func<T, TResult> (T arg1);
-       delegate TResult Func<T1, T2, TResult> (T1 arg1, T2 arg2);
-       //delegate TResult Func<T1, T2, T3, TResult> (T1 arg1, T2 arg2, T3 arg3);
-       //delegate TResult Func<T1, T2, T3, T4, TResult> (T1 arg1, T2 arg2, T3 arg3, T4 arg4);
-}
-
-#endif
diff --git a/mcs/class/Mono.Cecil/NOTES.txt b/mcs/class/Mono.Cecil/NOTES.txt
deleted file mode 100644 (file)
index 6f3618b..0000000
+++ /dev/null
@@ -1,189 +0,0 @@
-namespaces:
-
-       Mono.Cecil.Binary: deleted,
-       Mono.Cecil.Metadata: metadata table/rows: deleted.
-
-collections:
-
-       * Cecil now only exposes Collection of T as a public collection API.
-
-types:
-
-Mono.Cecil
-
-       - AssemblyFactory:
-               Use static Read methods on ModuleDefinition and AssemblyDefinition
-               to get them.
-
-       + ReadingMode:
-               specifies if the assembly is either loaded in a deffered
-               or immediate fashion.
-
-       + ReaderParameters
-               + ReadingMode
-               + ISymbolReaderProvider
-
-       + WriterParameters
-               + ISymbolWriterProvider
-
-       * AssemblyDefinition:
-
-                       * Runtime, Kind: moved to ModuleDefiniton
-
-       * ModuleDefinition:
-
-               properties:
-
-                       - Image
-                       - MemberReferences
-                       - TypeReferences
-                       - ExternTypes
-
-                       * Main -> IsMain. (set removed) : bool
-                       + FullyQualifiedName : string
-                       + Kind : ModuleKind
-                       + Runtime : TargetRuntime
-                       + Architecture : TargetArchitecture
-                       + Attributes : ModuleAttributes
-                       + HasSymbols : bool
-                       + HasExportedTypes : bool
-                       + ExportedTypes : ExportedTypeCollection
-
-                       * Types: doesn't contain NestedTypes anymore.
-
-       - AssemblyKind:
-               renamed to ModuleKind.
-
-       + ModuleKind:
-               + NetModule
-
-       + TargetArchitecture:
-               + I386
-               + AMD64
-               + IA64
-
-       + ModuleAttributes:
-               + ILOnly
-               + Required32Bit
-               + StrongNameSigned
-
-       * FieldDefinition:
-
-               * RVA : int
-
-       * IMethodSignature:
-               * ReturnType : TypeReference
-               + MethodReturnType : MethodReturnType
-
-       * TypeDefinition:
-               - HasConstructors
-               - Constructors
-               * ctor: swapped namespace and name parameter.
-
-       * ParameterDefinition:
-               * Method : IMethodSignature
-               * Sequence -> Index : int (0 based instead of 1)
-
-       * ArrayType:
-               * IsSizedArray -> IsVector : bool
-
-       * IHasConstant -> IConstantProvider
-       * IHasSecurity -> ISecurityDeclarationProvider
-       * IHasMarshal -> IMarshalInfoProvider
-
-       * MemberReference
-               + Module : ModuleDefinition
-
-       * MethodDefinition:
-               - This: moved to MethodBody
-               + HasPInvokeInfo : bool
-
-       * PInvokeInfo:
-               - Method
-
-       * MarshalSpec -> MarshalInfo
-
-       - ModType
-
-       * ModifierRequiredType -> RequiredModifierType
-       * ModifierOptionalType -> OptionalModifierType
-       * ReferenceType -> ByReferenceType
-
-       * TypeReference
-               + IsArray : bool
-               + IsPointer : bool
-               + IsByReference : bool
-               + IsRequiredModifier : bool
-               + IsOptionalModifier : bool
-               + IsSentinel : bool
-               + IsGenericInstance : bool
-               + IsGenericParameter : bool
-               + IsPinned : bool
-               + IsFunctionPointer : bool
-               + IsDefinition : bool
-
-               * GetOriginalType -> GetElementType
-               * ctor: swapped namespace and name parameter.
-
-       * MethodReference
-               + IsGenericInstance : bool
-               + IsDefinition : bool
-
-               * GetOriginalMethod -> GetElementMethod
-
-       * FieldReference
-               + IsDefinition : bool
-
-       + CustomAttributeArgument
-               + Type : TypeReference
-               + Value : object
-
-       * CustomAttribute
-               * ConstructorParameters -> ConstructorArguments : CustomAttributeArgumentCollection
-               * Properties : CustomAttributeNamedArgumentCollection
-               * Fields : CustomAttributeNamedArgumentCollection
-
-       * SecurityDeclaration
-               - PermissionSet
-               + SecurityAttributes : SecurityAttributeCollection
-
-       + SecurityAttribute
-               + AttributeType : TypeReference
-               + Fields : CustomAttributeNamedArgumentCollection
-               + Properties : CustomAttributeNamedArgumentCollection
-
-       * IMetadataScope
-               + MetadataScopeType
-
-       + MetadataScopeType
-               + AssemblyNameReference
-               + ModuleDefinition
-               + ModuleReference
-
-Mono.Cecil.Cil:
-
-       * ExceptionHandler
-               * Type -> HandlerType : TypeReference
-
-       * VariableDefinition
-               - Method
-
-       * Document* : from Guid to enums, the reader/writers are responsible for assigning them.
-
-       * MethodBody
-               * LocalVarToken : MetadataToken
-               * MaxStack -> MaxStackSize : int
-               + ThisParameter: from MethodDefinition
-
-       * OperandType
-               * ShortInlineParam : ShortInlineArg
-               * InlineParam : InlineArg
-
-       * CilWorker -> ILProcessor
-
-TODO:
-
-       * Mono.Cecil.Rocks
-               * ILGenerator
-
-       * HOWTOs
diff --git a/mcs/class/Mono.Cecil/README b/mcs/class/Mono.Cecil/README
deleted file mode 100644 (file)
index 3f79670..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-This copy of Mono.Cecil is a snapshot of the upstream Mono.Cecil located at:
-
-       http://github.com/jbevain/cecil
-
-To update the snapshot, simply run:
-
-       ruby update.rb
-
-in mono/mcs/class/Mono.Cecil. You need to have an updated clone of the upstream
-cecil in a sibling folder of your mono clone. You may have to update
-
-       mono/data/cecil.pc.in
-
-if Cecil's assembly version changed since the last update. This gets
-picked up by mono-tools to locate Cecil.
diff --git a/mcs/class/Mono.Cecil/System.Runtime.CompilerServices/ExtensionAttribute.cs b/mcs/class/Mono.Cecil/System.Runtime.CompilerServices/ExtensionAttribute.cs
deleted file mode 100644 (file)
index bb24f98..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-//
-// ExtensionAttribute.cs
-//
-// Author:
-//   Jb Evain (jbevain@gmail.com)
-//
-// Copyright (c) 2008 - 2011 Jb Evain
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-//
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-using System;
-
-#if !NET_3_5 && !NET_4_0
-
-namespace System.Runtime.CompilerServices {
-
-       [AttributeUsage (AttributeTargets.Method | AttributeTargets.Class | AttributeTargets.Assembly)]
-       sealed class ExtensionAttribute : Attribute {
-       }
-}
-
-#endif
diff --git a/mcs/class/Mono.Cecil/mono.snk b/mcs/class/Mono.Cecil/mono.snk
deleted file mode 100644 (file)
index 380116c..0000000
Binary files a/mcs/class/Mono.Cecil/mono.snk and /dev/null differ
diff --git a/mcs/class/Mono.Cecil/revision b/mcs/class/Mono.Cecil/revision
deleted file mode 100644 (file)
index d7805b6..0000000
+++ /dev/null
@@ -1 +0,0 @@
-5ce1cb68f1ce811ee530e18220fdf934b58d052c
diff --git a/mcs/class/Mono.Cecil/update.rb b/mcs/class/Mono.Cecil/update.rb
deleted file mode 100644 (file)
index 2466592..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-repository = "../../../../cecil"
-
-sources = {
-       "Mono.Cecil/*.cs" => "Mono.Cecil",
-       "Mono.Cecil.Cil/*.cs" => "Mono.Cecil.Cil",
-       "Mono.Cecil.Metadata/*.cs" => "Mono.Cecil.Metadata",
-       "Mono.Cecil.PE/*.cs" => "Mono.Cecil.PE",
-       "Mono.Collections.Generic/*.cs" => "Mono.Collections.Generic",
-       "Mono.Security.Cryptography/*.cs" => "Mono.Security.Cryptography",
-       "Mono/*.cs" => "Mono",
-       "System.Runtime.CompilerServices/*.cs" => "System.Runtime.CompilerServices",
-       "NOTES.txt" => ".",
-
-       "symbols/mdb/Mono.Cecil.Mdb/*.cs" => "../Mono.Cecil.Mdb/Mono.Cecil.Mdb/",
-}
-
-require "ftools"
-
-sources.each { |source, destination|
-       Dir[File::join(repository, source)].each { |file|
-               #puts "copying #{file} to #{destination}"
-               File.copy(file, destination)
-       }
-}
-
-dir = Dir.pwd
-
-begin
-       Dir.chdir(repository) 
-
-       log = IO.popen("git log -n1")
-
-       Dir.chdir(dir)
-
-       File.open("revision", File::WRONLY|File::TRUNC|File::CREAT, 0644) do |f|
-               f << log.gets[("commit ".length)..-1]
-       end
-rescue
-       Dir.chdir(dir)
-end
index b9ccfb06fdf65c24181694e4da138f660075e90f..6e2633d873a8d1757ab1f09e3308beca16b6c736 100644 (file)
@@ -4,7 +4,9 @@ include ../../build/rules.make
 
 LIBRARY = Mono.CodeContracts.dll
 
-LIB_MCS_FLAGS = -r:System -r:System.Core -r:Mono.Cecil.dll -r:Mono.Cecil.Mdb.dll 
+LIB_MCS_FLAGS = -r:System.dll -r:System.Core.dll -r:Mono.Cecil.dll -r:Mono.Cecil.Mdb.dll 
 #-r:Mono.Cecil.Pdb.dll
 
+TEST_MCS_FLAGS = -r:System.Core.dll
+
 include ../../build/library.make
index 21c73d103e6c046525449b37e497970580e25ba9..c05c4fd041b836b0f076ebc682df7f8f7e0848d1 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
-    <Reference Include="System">
+    <Reference Include="System.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System</HintPath>
+      <HintPath>System.dll</HintPath>
     </Reference>
-    <Reference Include="System.Core">
+    <Reference Include="System.Core.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Core</HintPath>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="Mono.Cecil.dll">
       <SpecificVersion>False</SpecificVersion>
index 0435203b59ec8e82849d13e3058f7e6a9dec83f1..f37c75c296925cd68a73de814ca61ba8fcdb81c6 100644 (file)
@@ -53,7 +53,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_5/Mono.CodeContracts.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 17e70cd221a6aea08b01f63d759ae1971b77bcfc..166b1d190fcb205e562ca0e059a0c43ada6c8f4d 100644 (file)
@@ -44,6 +44,7 @@
    <Compile Include="MonoSymbolWriter.cs" />
    <Compile Include="MonoSymbolTable.cs" />
    <Compile Include="MonoSymbolFile.cs" />
+   <Compile Include="SourceMethodBuilder.cs" />
    <Compile Include="SymbolWriterImpl.cs" />
 \r
   </ItemGroup>\r
@@ -58,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8b276786fac70f8a313feb8d691c93155d9f156e..fe6e36b9728de2b35f4be827c34d60f57bff5acf 100644 (file)
@@ -44,6 +44,7 @@
    <Compile Include="MonoSymbolWriter.cs" />
    <Compile Include="MonoSymbolTable.cs" />
    <Compile Include="MonoSymbolFile.cs" />
+   <Compile Include="SourceMethodBuilder.cs" />
    <Compile Include="SymbolWriterImpl.cs" />
 \r
   </ItemGroup>\r
@@ -58,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index bc53b774af9aceee32c29c3df54d7b3fbebda212..323dea0c3aa14f04b0d3c5d543fbf35912cb99e9 100644 (file)
@@ -44,6 +44,7 @@
    <Compile Include="MonoSymbolWriter.cs" />
    <Compile Include="MonoSymbolTable.cs" />
    <Compile Include="MonoSymbolFile.cs" />
+   <Compile Include="SourceMethodBuilder.cs" />
    <Compile Include="SymbolWriterImpl.cs" />
 \r
   </ItemGroup>\r
@@ -58,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
diff --git a/mcs/class/Mono.Data.Sqlite/.gitignore b/mcs/class/Mono.Data.Sqlite/.gitignore
new file mode 100644 (file)
index 0000000..902beaf
--- /dev/null
@@ -0,0 +1 @@
+SqliteTest.db
index 2b4a1ffe296a1c997979723d5136a94d0ddce031..2c1a6d6811c1eea1f0cb765446138084e282fc1c 100644 (file)
@@ -83,7 +83,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ee95eb60e0bc2feb3b87fad93bd94c1e8d2d7710..ab091444fcc07bfe5f61916fb15ef3533f70cfb9 100644 (file)
@@ -83,7 +83,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1ffa2240f324b83334cfae0de72f38606c6904dd..442207b78e73b119e4a76f1a1d07fdea1fed6dff 100644 (file)
@@ -83,7 +83,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e19b0fec8d30d1abdcc9c4032fcd3177aa7db4fc..fd5189f805fe58ac8535c686ee5d1ad59f05dfd8 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index be65f69f6d291ad74da82f9cc9c72aee48b946c2..018edf993d9203a9b47246102c6333854d9f5d49 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0fa3808358e14c520a6a267c3ded805a8406d08e..59d4c67870318b47ea58011e7cc74e3d5bd3ba4b 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a4cb95e62b1f37d208ed56513de497a05039d1a8..ca3a243f6500ac0713e3c23ace2a49133d3be3bb 100644 (file)
@@ -234,6 +234,9 @@ namespace Mono.Data.Sqlite
 \r
         // Not overly concerned with the return value from a rollback.\r
         UnsafeNativeMethods.sqlite3_exec(db, ToUTF8("ROLLBACK"), IntPtr.Zero, IntPtr.Zero, out stmt);\r
+        // but free the error message if any!\r
+        if (stmt != IntPtr.Zero)\r
+          UnsafeNativeMethods.sqlite3_free (stmt);\r
       }\r
     }\r
   }\r
index 386f912aab117fec9618d956a3d01a2c6a6cb39a..575c2ea04baaaf7942e9f7d7ddc03051e3df2dcc 100644 (file)
@@ -695,6 +695,7 @@ namespace Mono.Data.Sqlite
       new SQLiteTypeNames("SMALLINT", DbType.Int16),\r
       new SQLiteTypeNames("BIGINT", DbType.Int64),\r
       new SQLiteTypeNames("TIMESTAMP", DbType.DateTime),\r
+      new SQLiteTypeNames("DATETIME", DbType.DateTime),\r
     };\r
   }\r
 \r
index cb18d51d6beb14a22bc7f28438803c7e17af83d0..a295098e050c95ed620070b4b5245225882e5d3d 100644 (file)
@@ -125,8 +125,14 @@ namespace Mono.Data.Sqlite
             finally\r
             {\r
               // If the datareader's behavior includes closing the connection, then do so here.\r
-              if ((_commandBehavior & CommandBehavior.CloseConnection) != 0 && _command.Connection != null)\r
-                _command.Connection.Close();\r
+              if ((_commandBehavior & CommandBehavior.CloseConnection) != 0 && _command.Connection != null) {\r
+                // We need to call Dispose on the command before we call Dispose on the Connection,\r
+                // otherwise we'll get a SQLITE_LOCKED exception.\r
+                var conn = _command.Connection;\r
+                _command.Dispose ();\r
+                conn.Close();\r
+                _disposeCommand = false;\r
+              }\r
             }\r
           }\r
           finally\r
index bb01c8a10915e75212be5b4d04f5d1ae06cf4d6b..7e5c153906d13553975c0d4fa4cd8a6ee5bea346 100644 (file)
@@ -692,6 +692,13 @@ namespace Mono.Data.Sqlite
     [DllImport(SQLITE_DLL)]\r
 #endif\r
     internal static extern int sqlite3_config (SQLiteConfig config);\r
+               \r
+#if !PLATFORM_COMPACTFRAMEWORK\r
+    [DllImport(SQLITE_DLL, CallingConvention = CallingConvention.Cdecl)]\r
+#else\r
+    [DllImport(SQLITE_DLL)]\r
+#endif\r
+    internal static extern int sqlite3_free (IntPtr ptr);\r
 \r
     #endregion\r
   }\r
index 6f74042abf9a77fa412589a0f344278c2fc76255..aa70f5c160e9acb65a969e19c50d95a0fc7c902b 100644 (file)
@@ -43,15 +43,16 @@ namespace MonoTests.Mono.Data.Sqlite
                        {
                                throw e;
                        }
-                       
-                       SqliteCommand createCommand = new SqliteCommand("CREATE TABLE t1(t  TEXT,  f FLOAT, i INTEGER, b TEXT);",_conn);
-                       SqliteCommand insertCommand = new SqliteCommand("INSERT INTO t1  (t, f, i, b ) VALUES('" + stringvalue + "',123,123,'123')",_conn);
 
                        try
                        {
-                               _conn.Open();
-                               createCommand.ExecuteNonQuery();
-                               insertCommand.ExecuteNonQuery();
+                               using (SqliteCommand createCommand = new SqliteCommand("CREATE TABLE t1(t  TEXT,  f FLOAT, i INTEGER, b TEXT);", _conn))
+                               using (SqliteCommand insertCommand = new SqliteCommand("INSERT INTO t1  (t, f, i, b ) VALUES('" + stringvalue + "',123,123,'123')", _conn))
+                               {
+                                       _conn.Open();
+                                       createCommand.ExecuteNonQuery();
+                                       insertCommand.ExecuteNonQuery();
+                               }
                        }
                        catch(Exception e)
                        {
@@ -67,29 +68,31 @@ namespace MonoTests.Mono.Data.Sqlite
                [Test]  
                public void Select()
                {
-                       SqliteCommand simpleSelect = new SqliteCommand("SELECT * FROM t1;  ", _conn); // check trailing spaces
-                       using(_conn)
+                       using (_conn)
+                       using (SqliteCommand simpleSelect = new SqliteCommand("SELECT * FROM t1;  ", _conn)) // check trailing spaces
                        {
                                _conn.Open();
-                               SqliteDataReader dr = simpleSelect.ExecuteReader();
-                               while(dr.Read())
+                               using (SqliteDataReader dr = simpleSelect.ExecuteReader())
                                {
-                                       string test = dr[0].ToString();
-                                       Assert.AreEqual(dr["T"], stringvalue); // also checks case-insensitive column
-                                       Assert.AreEqual(dr["F"], 123);
-                                       Assert.AreEqual(dr["I"], 123);
-                                       Assert.AreEqual(dr["B"], "123");
+                                       while (dr.Read())
+                                       {
+                                               string test = dr[0].ToString();
+                                               Assert.AreEqual(dr["T"], stringvalue); // also checks case-insensitive column
+                                               Assert.AreEqual(dr["F"], 123);
+                                               Assert.AreEqual(dr["I"], 123);
+                                               Assert.AreEqual(dr["B"], "123");
+                                       }
+                                       Assert.IsTrue(dr.FieldCount>0);
                                }
-                               Assert.IsTrue(dr.FieldCount>0);
                        }
                }
-               
+
                [Test]
                public void Delete()
                {
-                       SqliteCommand insCmd = new SqliteCommand("INSERT INTO t1 VALUES ('todelete',0.1,0,'')",_conn);
-                       SqliteCommand delCmd = new SqliteCommand("DELETE FROM t1 WHERE t = 'todelete'",_conn);
-                       using(_conn)
+                       using (_conn)
+                       using (SqliteCommand insCmd = new SqliteCommand("INSERT INTO t1 VALUES ('todelete',0.1,0,'')", _conn))
+                       using (SqliteCommand delCmd = new SqliteCommand("DELETE FROM t1 WHERE t = 'todelete'", _conn))
                        {
                                _conn.Open();
                                int insReturn = insCmd.ExecuteNonQuery();
@@ -102,8 +105,8 @@ namespace MonoTests.Mono.Data.Sqlite
                [Test]
                public void Insert()
                {
-                       SqliteCommand insCmd = new SqliteCommand("INSERT INTO t1 VALUES ('inserted',0.1,0,'')",_conn);
-                       using(_conn)
+                       using (_conn)
+                       using (SqliteCommand insCmd = new SqliteCommand("INSERT INTO t1 VALUES ('inserted',0.1,0,'')", _conn))
                        {
                                _conn.Open();
                                int insReturn = insCmd.ExecuteNonQuery();
@@ -114,9 +117,9 @@ namespace MonoTests.Mono.Data.Sqlite
                [Test]
                public void Update()
                {
-                       SqliteCommand insCmd = new SqliteCommand("INSERT INTO t1 VALUES ('toupdate',0.1,0,'')",_conn);
-                       SqliteCommand updCmd = new SqliteCommand("UPDATE t1 SET t = 'updated' ,f = 2.0, i = 2, b = '' WHERE t = 'toupdate'",_conn);
-                       using(_conn)
+                       using (_conn)
+                       using (SqliteCommand insCmd = new SqliteCommand("INSERT INTO t1 VALUES ('toupdate',0.1,0,'')", _conn))
+                       using (SqliteCommand updCmd = new SqliteCommand("UPDATE t1 SET t = 'updated' ,f = 2.0, i = 2, b = '' WHERE t = 'toupdate'", _conn))
                        {
                                _conn.Open();
                                insCmd.ExecuteNonQuery();
@@ -129,8 +132,8 @@ namespace MonoTests.Mono.Data.Sqlite
                public void ScalarReturn()
                {
                        // This should return the 1 line that got inserted in CreateTable() Test
-                       SqliteCommand cmd = new SqliteCommand("SELECT COUNT(*) FROM t1 WHERE  t LIKE '%äöüß'",_conn);
-                       using(_conn)
+                       using (_conn)
+                       using (SqliteCommand cmd = new SqliteCommand("SELECT COUNT(*) FROM t1 WHERE  t LIKE '%äöüß'", _conn))
                        {
                                _conn.Open();
                                Assert.AreEqual(1, Convert.ToInt32(cmd.ExecuteScalar()));
@@ -141,12 +144,12 @@ namespace MonoTests.Mono.Data.Sqlite
                public void InsertWithTransaction()
                {
                        _conn.Open();
-                       SqliteTransaction t = _conn.BeginTransaction() as SqliteTransaction;
-                       SqliteCommand  c1 = new SqliteCommand("INSERT INTO t1 VALUES ('a',0.1,0,'0')",_conn,t);
-                       SqliteCommand  c2 = new SqliteCommand("INSERT INTO t1 VALUES ('b',1.2,0,'0')",_conn,t);
-                       SqliteCommand  c3 = new SqliteCommand("INSERT INTO t1 VALUES ('c',0.3,1,'0')",_conn,t);
-                       SqliteCommand  c4 = new SqliteCommand("INSERT INTO t1 VALUES ('d',0.4,0,'1')",_conn,t);
-                       using(_conn)
+                       using (_conn)
+                       using (SqliteTransaction t = _conn.BeginTransaction() as SqliteTransaction)
+                       using (SqliteCommand c1 = new SqliteCommand("INSERT INTO t1 VALUES ('a',0.1,0,'0')", _conn, t))
+                       using (SqliteCommand c2 = new SqliteCommand("INSERT INTO t1 VALUES ('b',1.2,0,'0')", _conn, t))
+                       using (SqliteCommand c3 = new SqliteCommand("INSERT INTO t1 VALUES ('c',0.3,1,'0')", _conn, t))
+                       using (SqliteCommand c4 = new SqliteCommand("INSERT INTO t1 VALUES ('d',0.4,0,'1')", _conn, t))
                        {
                                try
                                {
@@ -173,12 +176,12 @@ namespace MonoTests.Mono.Data.Sqlite
                public void InsertWithFailingTransaction()
                {
                        _conn.Open();
-                       SqliteTransaction t = _conn.BeginTransaction() as SqliteTransaction;
-                       SqliteCommand  c1 = new SqliteCommand("INSERT INTO t1 VALUES ('1','0','0','0')",_conn,t);
-                       SqliteCommand  c2 = new SqliteCommand("INSERT INTO t1 VALUES ('0','1','0','0')",_conn,t);
-                       SqliteCommand  c3 = new SqliteCommand("INSERT INTO t1 VALUES ('x',?,'x',?,'x',?,'x')",_conn,t);
-                       SqliteCommand  c4 = new SqliteCommand("INSERT INTO t1 VALUES ('0','0','0','1')",_conn,t);
-                       using(_conn)
+                       using (_conn)
+                       using (SqliteTransaction t = _conn.BeginTransaction() as SqliteTransaction)
+                       using (SqliteCommand c1 = new SqliteCommand("INSERT INTO t1 VALUES ('1','0','0','0')", _conn, t))
+                       using (SqliteCommand c2 = new SqliteCommand("INSERT INTO t1 VALUES ('0','1','0','0')", _conn, t))
+                       using (SqliteCommand c3 = new SqliteCommand("INSERT INTO t1 VALUES ('x',?,'x',?,'x',?,'x')", _conn, t))
+                       using (SqliteCommand c4 = new SqliteCommand("INSERT INTO t1 VALUES ('0','0','0','1')", _conn, t))
                        {
                                try
                                {
index a5a5604e45ab83dce62b34643d92e1dfb629905c..f14d5e08a6c0089bede4ccad7f43b9ae8f4d4c22 100644 (file)
@@ -141,5 +141,68 @@ namespace MonoTests.Mono.Data.Sqlite
                                }
                        }
                }
+               
+               [Test]
+               public void CloseConnectionTest ()
+               {
+                       // When this test fails it may confuse nunit a bit, causing it to show strange
+                       // exceptions, since it leaks file handles (and nunit tries to open files,
+                       // which it doesn't expect to fail).
+                       
+                       // For the same reason a lot of other tests will fail when this one fails.
+                       
+                       _conn.ConnectionString = _connectionString;
+                       using (_conn) {
+                               _conn.Open ();
+                               using (var cmd = (SqliteCommand) _conn.CreateCommand ()) {
+                                       cmd.CommandText = @"CREATE TABLE IF NOT EXISTS TestNullableDateTime (nullable TIMESTAMP NULL, dummy int); INSERT INTO TestNullableDateTime (nullable, dummy) VALUES (124123, 2);";
+                                       cmd.ExecuteNonQuery ();
+                               }
+                       }
+
+                       for (int i = 0; i < 1000; i++) {
+                               _conn.ConnectionString = _connectionString;
+                               using (_conn) {
+                                       _conn.Open ();
+                                       using (var cmd = (SqliteCommand) _conn.CreateCommand ()) {
+                                               cmd.CommandText = "SELECT * FROM TestNullableDateTime;";
+                                               cmd.CommandType = CommandType.Text;
+                                       
+                                               using (var reader = cmd.ExecuteReader (CommandBehavior.CloseConnection)) {
+                                                       reader.Read ();
+                                               }
+                                       }
+                               }
+                       }
+               }
+
+               [Test]
+               public void TestDateTimeType ()
+               {
+                       _conn.ConnectionString = _connectionString;
+                       using (_conn) {
+                               _conn.Open();
+                               
+                               using (var cm = _conn.CreateCommand ()) {
+                                       cm.CommandText = "DROP TABLE TEST; CREATE TABLE TEST (F2 DATETIME); INSERT INTO TEST (F2) VALUES (:F2)";
+
+                                       var dp2 = cm.CreateParameter ();
+                                       dp2.ParameterName = ":F2";
+                                       dp2.Value = DateTime.Now;
+                                       cm.Parameters.Add (dp2);
+                                       
+                                       cm.ExecuteNonQuery ();
+                               }
+                               
+                               using (var cm = _conn.CreateCommand ()) {
+                                       cm.CommandText = "SELECT F2 FROM TEST";
+                                       using (var dr = cm.ExecuteReader ()) {
+                                               dr.Read ();
+                                               
+                                               Assert.AreEqual ("System.DateTime", dr.GetFieldType (dr.GetOrdinal ("F2")).ToString ());
+                                       }
+                               }
+                       }
+               }
         }
 }
index 80c552ae754acd8aec3130c2dc875ad821775082..53ed46d7b7fdb1caebe521ce021829ee08ba9445 100644 (file)
@@ -4,6 +4,7 @@ include ../../build/rules.make
 
 LIBRARY = Mono.Data.Tds.dll
 LIB_MCS_FLAGS = /r:$(corlib) /r:System.dll /r:System.Xml.dll /r:Mono.Security.dll
-NO_TEST = yes
+
+TEST_MCS_FLAGS = /r:System.dll /r:System.Net.dll 
 
 include ../../build/library.make
index cb5990ce3122b2dd70ddce1b495583e902ee4163..3ba8a310e9787e17cbbea6fe6ec5c482156e03e9 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3e9dd5a624f111bd743df5c1cc043ef526dc7802..6f1d6d23948783962425880f1279ecd7346e85b0 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b28d3954247c790c068035b9b6828aff0fe0937d..505ed9985288459c422a1faabe134618e9c88b87 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 30636d4d2ba3f59ea00547158a9909ffe68a107c..4d43d7ec399d273c8b5fbd3aa4f1ce90fd78f01e 100644 (file)
@@ -224,6 +224,7 @@ retry:
                                retries--;
                                if (retries == 0)
                                        throw exc;
+                               result = null;
                                goto retry;
                        }
                        return result;
diff --git a/mcs/class/Mono.Data.Tds/Mono.Data.Tds_test.dll.sources b/mcs/class/Mono.Data.Tds/Mono.Data.Tds_test.dll.sources
new file mode 100644 (file)
index 0000000..5cefc19
--- /dev/null
@@ -0,0 +1 @@
+bug-4786.cs
diff --git a/mcs/class/Mono.Data.Tds/Test/bug-4786.cs b/mcs/class/Mono.Data.Tds/Test/bug-4786.cs
new file mode 100644 (file)
index 0000000..9bb7edf
--- /dev/null
@@ -0,0 +1,110 @@
+//
+// bug-4786.cs- 
+//      NUnit Test Cases for Mono.Data.Tds.Protocol.TdsConnectionPool
+//
+// Author:
+//      Robert Wilkens <robwilkens@gmail.com>
+//
+// Copyright (C) 2012 Robert Wilkens (http://www.robssoftwareprojects.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+namespace bug4786test
+{
+       
+  using NUnit.Framework;
+  using Mono.Data.Tds.Protocol;
+  using System;
+  using System.Net;
+  using System.Net.Sockets;
+
+
+  [TestFixture]
+  public class TdsConnectionPoolTest
+  {
+    const string SERVER="localhost";
+    [Test]
+    public void CheckNullException() 
+    {
+
+       //set up dummy sql listener, if there is a real sql server on this
+       //machine at that port, in theory this part will fail, but that's ok
+       //becuase something will be listening on the port and that's all we
+       //require at this point: a listener on port 1433...
+
+       try{
+               Socket Listener = new Socket(AddressFamily.InterNetwork, 
+                                         SocketType.Stream,
+                                         ProtocolType.Tcp);
+               IPAddress hostIP =Dns.GetHostEntry("localhost").AddressList[0];
+               IPEndPoint ep = new IPEndPoint(hostIP, 1433);
+               Listener.Bind(ep); 
+               Listener.Listen(1);
+       } catch (Exception){
+               //ignore
+       }
+
+       //try to connect twice, in earlier failure would get null exception
+       //on 2nd call to pool.GetConnection();
+       //Most of this code ripped from sqlConnection.Open()
+
+       TdsConnectionPool pool;
+       
+       TdsConnectionPoolManager sqlConnectionPools = 
+               new TdsConnectionPoolManager(TdsVersion.tds80); 
+       TdsConnectionInfo info=
+               new TdsConnectionInfo(SERVER/*dummyhost*/,1433/*port*/,
+               8192/*pktsize*/,15/*timeout*/,0/*minpoolsize*/,
+               100/*maxpoolsize*/);
+       pool=sqlConnectionPools.GetConnectionPool("test",info);
+       Tds tds=null;
+
+       //this first one succeeded regardless as long as something answered
+       //the phone on port 1433 of localhost
+       tds=pool.GetConnection();
+
+       pool.ReleaseConnection(tds);
+
+
+       // 2nd time thru: This will fail with nullreferenceexception 
+       // at pool.GetConnection() unless the patch by Rob Wilkens which 
+       // adds "result=null;" before retry in pool.getConnection() source
+
+       //First let's pretend we're calling this test fresh, as if we
+       //call sqlConnection.Open() again :
+
+       info=new TdsConnectionInfo(SERVER/*dummyhost*/,1433/*port*/,
+               8192/*pktsize*/,15/*timeout*/,0/*minpoolsize*/,
+               100/*maxpoolsize*/);
+
+       pool=sqlConnectionPools.GetConnectionPool("test",info);
+
+       //Then: Test for failure (will raise uncaught exception which
+       //causes failure of test if bug is not fixed
+       tds=pool.GetConnection();
+
+       pool.ReleaseConnection(tds);
+
+       //exit
+    }
+  }
+}
+
index f4d0f731809b9cfaaaaddcdaf8506c8fa1c3ef03..5a31821f7999a8187e9e4457b840df7f4be0b9fb 100644 (file)
@@ -6,10 +6,9 @@ LIBRARY_SNK = ../mono.snk
 
 LIB_MCS_FLAGS = /r:$(corlib) /r:System.dll /r:Mono.Cecil.dll /r:System.Core.dll /unsafe -D:MONO_DATACONVERTER_STATIC_METHODS -keyfile:$(LIBRARY_SNK)
 
-TEST_MCS_FLAGS = /r:Mono.Cecil.dll
+TEST_MCS_FLAGS = /r:Mono.Cecil.dll /r:System.dll /r:System.Core.dll
 
-test: dtest-app.exe dtest-excfilter.exe
-check: dtest-app.exe dtest-excfilter.exe
+test-local: dtest-app.exe dtest-excfilter.exe
 
 dtest-app.exe: Test/dtest-app.cs
        $(CSCOMPILE) -out:$@ -unsafe -debug Test/dtest-app.cs
index cb83031daaf08c94a4f9012a334edc07df3308f1..9fc20335d8b55e32f5f07d67afc0d6fdb9c4434c 100644 (file)
@@ -54,6 +54,7 @@
    <Compile Include="Mono.Debugger.Soft\ILInstruction.cs" />
    <Compile Include="Mono.Debugger.Soft\InterfaceMappingMirror.cs" />
    <Compile Include="Mono.Debugger.Soft\PrimitiveValue.cs" />
+   <Compile Include="Mono.Debugger.Soft\PointerValue.cs" />
    <Compile Include="Mono.Debugger.Soft\VMDisconnectedException.cs" />
    <Compile Include="Mono.Debugger.Soft\Mirror.cs" />
    <Compile Include="Mono.Debugger.Soft\EnumMirror.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a8f84020bd97bbfd3909f51cebad08fad2cf56ac..0bb1b993035ed04a2d34847384f01e1e32fb09d0 100644 (file)
@@ -54,6 +54,7 @@
    <Compile Include="Mono.Debugger.Soft\ILInstruction.cs" />
    <Compile Include="Mono.Debugger.Soft\InterfaceMappingMirror.cs" />
    <Compile Include="Mono.Debugger.Soft\PrimitiveValue.cs" />
+   <Compile Include="Mono.Debugger.Soft\PointerValue.cs" />
    <Compile Include="Mono.Debugger.Soft\VMDisconnectedException.cs" />
    <Compile Include="Mono.Debugger.Soft\Mirror.cs" />
    <Compile Include="Mono.Debugger.Soft\EnumMirror.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7dedbaef43a09cba6e661957ba7ce6decd11cb25..fe9c5b61acac742074499f750268ac8beee3f9c7 100644 (file)
@@ -54,6 +54,7 @@
    <Compile Include="Mono.Debugger.Soft\ILInstruction.cs" />
    <Compile Include="Mono.Debugger.Soft\InterfaceMappingMirror.cs" />
    <Compile Include="Mono.Debugger.Soft\PrimitiveValue.cs" />
+   <Compile Include="Mono.Debugger.Soft\PointerValue.cs" />
    <Compile Include="Mono.Debugger.Soft\VMDisconnectedException.cs" />
    <Compile Include="Mono.Debugger.Soft\Mirror.cs" />
    <Compile Include="Mono.Debugger.Soft\EnumMirror.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 78902263615db22328a5ef70fa5f7f1bfb8c14ca..d41e0de861311ccc30e5f7d80c6679effcd4a754 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Mono.Cecil.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index b60b4464e61fc0bb03ade6e309a3768c5c8dad74..9681ce16122c63043c07e45608d196614652d87f 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Mono.Cecil.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 2047fa4277ecf5071ee5f26462d5a74648fc8813..fad31b9274fa07984fdac6cd8891fe4c71a559e2 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>Mono.Cecil.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index a7cc5d555f48a93399d7e27d06254455260748d9..db2a4d73bcedf816a3ff6dd7e5702251106f800b 100644 (file)
@@ -12,8 +12,10 @@ Mono.Debugger.Soft/StackFrame.cs
 Mono.Debugger.Soft/CustomAttributeDataMirror.cs
 Mono.Debugger.Soft/ThreadStartEvent.cs
 Mono.Debugger.Soft/ILInstruction.cs
+Mono.Debugger.Soft/ILExceptionHandler.cs
 Mono.Debugger.Soft/InterfaceMappingMirror.cs
 Mono.Debugger.Soft/PrimitiveValue.cs
+Mono.Debugger.Soft/PointerValue.cs
 Mono.Debugger.Soft/VMDisconnectedException.cs
 Mono.Debugger.Soft/Mirror.cs
 Mono.Debugger.Soft/EnumMirror.cs
index 9c1da71e12baff2569809b70717f6d2df4e9e8bd..0b934c1d336cb15296e0a647bd5c0601eba377f8 100644 (file)
@@ -12,7 +12,8 @@ namespace Mono.Debugger.Soft
 
                public string FriendlyName {
                        get {
-                               if (friendly_name == null)
+                               /* The name can't be empty during domain creation */
+                               if (friendly_name == null || friendly_name == String.Empty)
                                        friendly_name = vm.conn.Domain_GetName (id);
                                return friendly_name;
                        }
index 70bfb86a4ee2f33555fcf51e1188593016ded1a7..6d6ad987e0e645f8b3f40dd8e28ad4ee967b89ed 100644 (file)
@@ -79,6 +79,24 @@ namespace Mono.Debugger.Soft
 
        class MethodBodyInfo {
                public byte[] il;
+               public ExceptionClauseInfo[] clauses;
+       }
+
+       struct ExceptionClauseInfo {
+               public ExceptionClauseFlags flags;
+               public int try_offset;
+               public int try_length;
+               public int handler_offset;
+               public int handler_length;
+               public int filter_offset;
+               public long catch_type_id;
+       }
+
+       enum ExceptionClauseFlags {
+               None = 0x0,
+               Filter = 0x1,
+               Finally = 0x2,
+               Fault = 0x4,
        }
 
        struct ParamInfo {
@@ -353,7 +371,7 @@ namespace Mono.Debugger.Soft
        /*
         * Represents the connection to the debuggee
         */
-       public abstract class Connection : IDisposable
+       public abstract class Connection
        {
                /*
                 * The protocol and the packet format is based on JDWP, the differences 
@@ -376,7 +394,7 @@ namespace Mono.Debugger.Soft
                 * with newer runtimes, and vice versa.
                 */
                internal const int MAJOR_VERSION = 2;
-               internal const int MINOR_VERSION = 17;
+               internal const int MINOR_VERSION = 18;
 
                enum WPSuspendPolicy {
                        NONE = 0,
@@ -1132,7 +1150,9 @@ namespace Mono.Debugger.Soft
                                        if (!res)
                                                break;
                                } catch (Exception ex) {
-                                       Console.WriteLine (ex);
+                                       if (!closed) {
+                                               Console.WriteLine (ex);
+                                       }
                                        break;
                                }
                        }
@@ -1755,6 +1775,28 @@ namespace Mono.Debugger.Soft
                        for (int i = 0; i < info.il.Length; ++i)
                                info.il [i] = (byte)res.ReadByte ();
 
+                       if (Version.AtLeast (2, 18)) {
+                               info.clauses = new ExceptionClauseInfo [res.ReadInt ()];
+
+                               for (int i = 0; i < info.clauses.Length; ++i) {
+                                       var clause = new ExceptionClauseInfo {
+                                               flags = (ExceptionClauseFlags) res.ReadInt (),
+                                               try_offset = res.ReadInt (),
+                                               try_length = res.ReadInt (),
+                                               handler_offset = res.ReadInt (),
+                                               handler_length = res.ReadInt (),
+                                       };
+
+                                       if (clause.flags == ExceptionClauseFlags.None)
+                                               clause.catch_type_id = res.ReadId ();
+                                       else if (clause.flags == ExceptionClauseFlags.Filter)
+                                               clause.filter_offset = res.ReadInt ();
+
+                                       info.clauses [i] = clause;
+                               }
+                       } else
+                               info.clauses = new ExceptionClauseInfo [0];
+
                        return info;
                }
 
@@ -2214,20 +2256,10 @@ namespace Mono.Debugger.Soft
                        res.domain_id = r.ReadId ();
                        return res;
                }
-               
-               public void Dispose ()
-               {
-                       Dispose (true);
-                       GC.SuppressFinalize (this);
-               }
-               
-               protected virtual void Dispose (bool disposing)
-               {
-               }
-               
-               ~Connection ()
+
+               public void ForceDisconnect ()
                {
-                       Dispose (false);
+                       TransportClose ();
                }
        }
        
@@ -2267,15 +2299,6 @@ namespace Mono.Debugger.Soft
                {
                        socket.Close ();
                }
-               
-               protected override void Dispose (bool disposing)
-               {
-                       if (disposing) {
-                               //Socket.Dispose is explicit in < .NET 4.0
-                               ((IDisposable)socket).Dispose ();
-                       }
-                       base.Dispose (disposing);
-               }
        }
 
        /* This is the interface exposed by the debugger towards the debugger agent */
diff --git a/mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/ILExceptionHandler.cs b/mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/ILExceptionHandler.cs
new file mode 100644 (file)
index 0000000..927949d
--- /dev/null
@@ -0,0 +1,33 @@
+using System;
+using System.IO;
+
+namespace Mono.Debugger.Soft
+{
+       public enum ILExceptionHandlerType
+       {
+               Catch = ExceptionClauseFlags.None,
+               Filter = ExceptionClauseFlags.Filter,
+               Finally = ExceptionClauseFlags.Finally,
+               Fault = ExceptionClauseFlags.Fault,
+       }
+
+       public class ILExceptionHandler
+       {
+               public int TryOffset { get; internal set; }
+               public int TryLength { get; internal set; }
+               public ILExceptionHandlerType HandlerType { get; internal set; }
+               public int HandlerOffset { get; internal set; }
+               public int HandlerLength { get; internal set;}
+               public int FilterOffset { get; internal set; }
+               public TypeMirror CatchType { get; internal set; }
+
+               internal ILExceptionHandler (int try_offset, int try_length, ILExceptionHandlerType handler_type, int handler_offset, int handler_length)
+               {
+                       TryOffset = try_offset;
+                       TryLength = try_length;
+                       HandlerType = handler_type;
+                       HandlerOffset = handler_offset;
+                       HandlerLength = handler_length;
+               }
+       }
+}
index c03f4cdb47625e076c12a4e5556013b26e35f6fd..c383005a0d41979d8d92977b7f96d93c4b7091f3 100644 (file)
@@ -4,6 +4,7 @@ using System.Text;
 using Mono.Cecil.Cil;
 using Mono.Cecil.Metadata;
 using System.IO;
+using System.Linq;
 using System.Reflection;
 
 namespace Mono.Debugger.Soft
@@ -11,11 +12,11 @@ namespace Mono.Debugger.Soft
        public class MethodBodyMirror : Mirror
        {
                MethodMirror method;
-               byte[] il;
+               MethodBodyInfo info;
 
-               internal MethodBodyMirror (VirtualMachine vm, MethodMirror method, byte[] il) : base (vm, 0) {
+               internal MethodBodyMirror (VirtualMachine vm, MethodMirror method, MethodBodyInfo info) : base (vm, 0) {
                        this.method = method;
-                       this.il = il;
+                       this.info = info;
                }
 
                public MethodMirror Method {
@@ -24,13 +25,29 @@ namespace Mono.Debugger.Soft
                        }
                }
 
+               public List<ILExceptionHandler> ExceptionHandlers {
+                       get {
+                               vm.CheckProtocolVersion (2, 18);
+                               return info.clauses.Select (c =>
+                               {
+                                       var handler = new ILExceptionHandler (c.try_offset, c.try_length, (ILExceptionHandlerType) c.flags, c.handler_offset, c.handler_length);
+                                       if (c.flags == ExceptionClauseFlags.None)
+                                               handler.CatchType = vm.GetType (c.catch_type_id);
+                                       else if (c.flags == ExceptionClauseFlags.Filter)
+                                               handler.FilterOffset = c.filter_offset;
+
+                                       return handler;
+                               }).ToList ();
+                       }
+               }
+
                public byte[] GetILAsByteArray () {
-                       return il;
+                       return info.il;
                }
 
                public List<ILInstruction> Instructions {
                        get {
-                               return ReadCilBody (new BinaryReader (new MemoryStream (il)), il.Length);
+                               return ReadCilBody (new BinaryReader (new MemoryStream (info.il)), info.il.Length);
                        }
                }
 
index 3034a01d33560703926814389da1c81cad98724e..7f315fd05d2b170101c870045d50da7824083533 100644 (file)
@@ -249,7 +249,7 @@ namespace Mono.Debugger.Soft
                        if (body == null) {
                                MethodBodyInfo info = vm.conn.Method_GetBody (id);
 
-                               body = new MethodBodyMirror (vm, this, info.il);
+                               body = new MethodBodyMirror (vm, this, info);
                        }
                        return body;
                }
diff --git a/mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/PointerValue.cs b/mcs/class/Mono.Debugger.Soft/Mono.Debugger.Soft/PointerValue.cs
new file mode 100644 (file)
index 0000000..3fa359f
--- /dev/null
@@ -0,0 +1,65 @@
+// 
+// PointerValue.cs
+//  
+// Author: Jeffrey Stedfast <jeff@xamarin.com>
+// 
+// Copyright (c) 2012 Xamarin Inc.
+// 
+// Permission is hereby granted, free of charge, to any person obtaining a copy
+// of this software and associated documentation files (the "Software"), to deal
+// in the Software without restriction, including without limitation the rights
+// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+// copies of the Software, and to permit persons to whom the Software is
+// furnished to do so, subject to the following conditions:
+// 
+// The above copyright notice and this permission notice shall be included in
+// all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+// THE SOFTWARE.
+
+using System;
+using System.Collections.Generic;
+
+namespace Mono.Debugger.Soft
+{
+       /*
+        * Represents a value of a pointer type in the debuggee
+        */
+       public class PointerValue : Value {
+               TypeMirror type;
+               long addr;
+
+               public PointerValue (VirtualMachine vm, TypeMirror type, long addr) : base (vm, 0) {
+                       this.type = type;
+                       this.addr = addr;
+               }
+
+               public long Address {
+                       get { return addr; }
+               }
+
+               public TypeMirror Type {
+                       get { return type; }
+               }
+
+               public override bool Equals (object obj) {
+                       if (obj != null && obj is PointerValue)
+                               return addr == (obj as PointerValue).addr;
+                       return base.Equals (obj);
+               }
+
+               public override int GetHashCode () {
+                       return base.GetHashCode ();
+               }
+
+               public override string ToString () {
+                       return string.Format ("PointerValue<({0}) 0x{1:x}>", type.CSharpName, addr);
+               }
+       }
+}
index 1c6c60a0e6716b94a94b2845b7444a10c8421017..696f6493f4043a726e058dcc41365c9c62290975 100644 (file)
@@ -7,7 +7,6 @@ namespace Mono.Debugger.Soft
         * Represents a value of a primitive type in the debuggee
         */
        public class PrimitiveValue : Value {
-
                object value;
 
                public PrimitiveValue (VirtualMachine vm, object value) : base (vm, 0) {
@@ -33,7 +32,25 @@ namespace Mono.Debugger.Soft
                }
 
                public override string ToString () {
-                       return "PrimitiveValue<" + Value + ">";
+                       object v = Value;
+
+                       return "PrimitiveValue<" + (v != null ? v.ToString () : "(null)") + ">";
+               }
+
+               public Value InvokeMethod (ThreadMirror thread, MethodMirror method, IList<Value> arguments) {
+                       return ObjectMirror.InvokeMethod (vm, thread, method, this, arguments, InvokeOptions.None);
+               }
+
+               public Value InvokeMethod (ThreadMirror thread, MethodMirror method, IList<Value> arguments, InvokeOptions options) {
+                       return ObjectMirror.InvokeMethod (vm, thread, method, this, arguments, options);
+               }
+
+               public IAsyncResult BeginInvokeMethod (ThreadMirror thread, MethodMirror method, IList<Value> arguments, InvokeOptions options, AsyncCallback callback, object state) {
+                       return ObjectMirror.BeginInvokeMethod (vm, thread, method, this, arguments, options, callback, state);
+               }
+
+               public Value EndInvokeMethod (IAsyncResult asyncResult) {
+                       return ObjectMirror.EndInvokeMethodInternal (asyncResult);
                }
        }
 }
\ No newline at end of file
index 00a8bb58dac870b3315d70e0d47609458b8006ed..7df5094781309e49acf1613e858c5ff6f2311f8b 100644 (file)
@@ -694,10 +694,46 @@ namespace Mono.Debugger.Soft
                                        m [i] = vm.GetMethod (ids [i]);
                                return m;
                        } else {
-                               if (flags != (BindingFlags.Public|BindingFlags.NonPublic|BindingFlags.Instance|BindingFlags.NonPublic))
+                               if ((flags & BindingFlags.IgnoreCase) != 0) {
+                                       flags &= ~BindingFlags.IgnoreCase;
+                                       ignoreCase = true;
+                               }
+                               
+                               if (flags == BindingFlags.Default)
+                                       flags = BindingFlags.Public|BindingFlags.NonPublic|BindingFlags.Instance|BindingFlags.Static;
+                               
+                               MethodAttributes access = (MethodAttributes) 0;
+                               bool matchInstance = false;
+                               bool matchStatic = false;
+                               
+                               if ((flags & BindingFlags.NonPublic) != 0) {
+                                       access |= MethodAttributes.Private;
+                                       flags &= ~BindingFlags.NonPublic;
+                               }
+                               if ((flags & BindingFlags.Public) != 0) {
+                                       access |= MethodAttributes.Public;
+                                       flags &= ~BindingFlags.Public;
+                               }
+                               if ((flags & BindingFlags.Instance) != 0) {
+                                       flags &= ~BindingFlags.Instance;
+                                       matchInstance = true;
+                               }
+                               if ((flags & BindingFlags.Static) != 0) {
+                                       flags &= ~BindingFlags.Static;
+                                       matchStatic = true;
+                               }
+                               
+                               if ((int) flags != 0)
                                        throw new NotImplementedException ();
+                               
                                var res = new List<MethodMirror> ();
                                foreach (MethodMirror m in GetMethods ()) {
+                                       if ((m.Attributes & access) == (MethodAttributes) 0)
+                                               continue;
+                                       
+                                       if (!((matchStatic && m.IsStatic) || (matchInstance && !m.IsStatic)))
+                                               continue;
+                                       
                                        if ((!ignoreCase && m.Name == name) || (ignoreCase && m.Name.Equals (name, StringComparison.CurrentCultureIgnoreCase)))
                                                res.Add (m);
                                }
index 440e1c82f05fa37ba6aac7ecefc1242597042773..61c284dfcfcdef30048998733af22ab625bc2607 100644 (file)
@@ -134,13 +134,23 @@ namespace Mono.Debugger.Soft
                        conn.VM_Exit (exitCode);
                }
 
-               public void Dispose () {
+               public void Detach () {
                        conn.VM_Dispose ();
                        conn.Close ();
-                       conn.Dispose ();
                        notify_vm_event (EventType.VMDisconnect, SuspendPolicy.None, 0, 0, null);
                }
 
+               [Obsolete ("This method was poorly named; use the Detach() method instead")]
+               public void Dispose ()
+               {
+                       Detach ();
+               }
+
+               public void ForceDisconnect ()
+               {
+                       conn.ForceDisconnect ();
+               }
+
                public IList<ThreadMirror> GetThreads () {
                        long[] ids = vm.conn.VM_GetThreads ();
                        ThreadMirror[] res = new ThreadMirror [ids.Length];
index 33dc157a8c57aeaccdddb60087093578ffe3e1a4..4e76c33b04a00afcdb90075fc3d9160864c82aac 100644 (file)
@@ -170,6 +170,7 @@ public class Tests : TestsBase
        double field_double;
        Thread field_class;
        IntPtr field_intptr;
+       int? field_nullable;
        static int static_i = 55;
        static string static_s = "A";
        public const int literal_i = 56;
@@ -214,6 +215,10 @@ public class Tests : TestsBase
                if (args.Length > 0 && args [0] == "suspend-test")
                        /* This contains an infinite loop, so execute it conditionally */
                        suspend ();
+               if (args.Length >0 && args [0] == "unhandled-exception") {
+                       unhandled_exception ();
+                       return 0;
+               }
                breakpoints ();
                single_stepping ();
                arguments ();
@@ -304,6 +309,7 @@ public class Tests : TestsBase
                        ss6 (b);
                } catch {
                }
+               ss7 ();
                ss_regress_654694 ();
        }
 
@@ -350,13 +356,32 @@ public class Tests : TestsBase
        [MethodImplAttribute (MethodImplOptions.NoInlining)]
        public static void ss6 (bool b) {
                if (b) {
-                       ss7 ();
+                       ss6_2 ();
                        throw new Exception ();
                }
        }
 
+       [MethodImplAttribute (MethodImplOptions.NoInlining)]
+       public static void ss6_2 () {
+       }
+
        [MethodImplAttribute (MethodImplOptions.NoInlining)]
        public static void ss7 () {
+               try {
+                       ss7_2 ();
+                       ss7_3 ();
+               } catch {
+               }
+               ss7_2 ();
+       }
+
+       [MethodImplAttribute (MethodImplOptions.NoInlining)]
+       public static void ss7_2 () {
+       }
+
+       [MethodImplAttribute (MethodImplOptions.NoInlining)]
+       public static void ss7_3 () {
+               throw new Exception ();
        }
 
        [MethodImplAttribute (MethodImplOptions.NoInlining)]
@@ -470,8 +495,9 @@ public class Tests : TestsBase
 
        [MethodImplAttribute (MethodImplOptions.NoInlining)]
        public static void locals () {
+               string s = null;
                locals1 (null);
-               locals2<string> (null, 5, "ABC");
+               locals2<string> (null, 5, "ABC", ref s);
                locals3 ();
                locals6 ();
        }
@@ -486,7 +512,7 @@ public class Tests : TestsBase
        }
 
        [MethodImplAttribute (MethodImplOptions.NoInlining)]
-       public static void locals2<T> (string[] args, int arg, T t) {
+       public static void locals2<T> (string[] args, int arg, T t, ref string rs) {
                long i = 42;
                string s = "AB";
 
@@ -496,6 +522,7 @@ public class Tests : TestsBase
                        if (t != null)
                                i ++;
                }
+               rs = "A";
        }
 
        [MethodImplAttribute (MethodImplOptions.NoInlining)]
@@ -765,6 +792,14 @@ public class Tests : TestsBase
                }
        }
 
+       [MethodImplAttribute (MethodImplOptions.NoInlining)]
+       public static void unhandled_exception () {
+               ThreadPool.QueueUserWorkItem (delegate {
+                               throw new InvalidOperationException ();
+                       });
+               Thread.Sleep (10000);
+       }
+
        internal static Delegate create_filter_delegate (Delegate dlg, MethodInfo filter_method)
        {
                if (dlg == null)
@@ -864,6 +899,8 @@ public class Tests : TestsBase
                CrossDomain o = (CrossDomain)domain.CreateInstanceAndUnwrap (
                                   typeof (CrossDomain).Assembly.FullName, "CrossDomain");
 
+               domains_2 (o, new CrossDomain ());
+
                o.invoke_2 ();
 
                o.invoke ();
@@ -872,11 +909,15 @@ public class Tests : TestsBase
 
                AppDomain.Unload (domain);
 
-               domains_2 ();
+               domains_3 ();
        }
 
        [MethodImplAttribute (MethodImplOptions.NoInlining)]
-       public static void domains_2 () {
+       public static void domains_2 (object o, object o2) {
+       }
+
+       [MethodImplAttribute (MethodImplOptions.NoInlining)]
+       public static void domains_3 () {
        }
 
        [MethodImplAttribute (MethodImplOptions.NoInlining)]
@@ -1012,6 +1053,10 @@ public class CrossDomain : MarshalByRefObject
        public void invoke_2 () {
                Tests.invoke_in_domain_2 ();
        }
+
+       public int invoke_3 () {
+               return 42;
+       }
 }      
 
 public class Foo
index dc4a479b3a8df338b3e3a003bbc4d1d52041f827..3e353172566697c7feecfac3c7220a22d1aac71f 100644 (file)
@@ -15,6 +15,9 @@ using NUnit.Framework;
 
 #pragma warning disable 0219
 
+namespace MonoTests
+{
+
 [TestFixture]
 public class DebuggerTests
 {
@@ -502,7 +505,25 @@ public class DebuggerTests
                e = GetNextEvent ();
                Assert.IsTrue (e is StepEvent);
                Assert.AreEqual ("ss6", (e as StepEvent).Method.Name);
+               req.Disable ();
 
+               // Check that a step over stops at an EH clause
+               e = run_until ("ss7_2");
+               req = vm.CreateStepRequest (e.Thread);
+               req.Depth = StepDepth.Out;
+               req.Enable ();
+               vm.Resume ();
+               e = GetNextEvent ();
+               Assert.IsTrue (e is StepEvent);
+               Assert.AreEqual ("ss7", (e as StepEvent).Method.Name);
+               req.Disable ();
+               req = vm.CreateStepRequest (e.Thread);
+               req.Depth = StepDepth.Over;
+               req.Enable ();
+               vm.Resume ();
+               e = GetNextEvent ();
+               Assert.IsTrue (e is StepEvent);
+               Assert.AreEqual ("ss7", (e as StepEvent).Method.Name);
                req.Disable ();
        }
 
@@ -867,7 +888,6 @@ public class DebuggerTests
                AssertValue (Int32.MaxValue - 5, (f as StructMirror).Fields [0]);
 
                // enums
-
                FieldInfoMirror field = o.Type.GetField ("field_enum");
                f = o.GetValue (field);
                (f as EnumMirror).Value = 5;
@@ -885,6 +905,20 @@ public class DebuggerTests
                f = o.GetValue (field);
                o.SetValue (field, f);
 
+               // nullables
+               field = o.Type.GetField ("field_nullable");
+               f = o.GetValue (field);
+               AssertValue (0, (f as StructMirror).Fields [0]);
+               AssertValue (false, (f as StructMirror).Fields [1]);
+               o.SetValue (field, vm.CreateValue (6));
+               f = o.GetValue (field);
+               AssertValue (6, (f as StructMirror).Fields [0]);
+               AssertValue (true, (f as StructMirror).Fields [1]);
+               o.SetValue (field, vm.CreateValue (null));
+               f = o.GetValue (field);
+               AssertValue (0, (f as StructMirror).Fields [0]);
+               AssertValue (false, (f as StructMirror).Fields [1]);
+
                // Argument checking
                AssertThrows<ArgumentNullException> (delegate () {
                                o.SetValues (null, new Value [0]);
@@ -1376,8 +1410,8 @@ public class DebuggerTests
                StackFrame frame = e.Thread.GetFrames () [0];
 
                var locals = frame.Method.GetLocals ();
-               Assert.AreEqual (6, locals.Length);
-               for (int i = 0; i < 6; ++i) {
+               Assert.AreEqual (7, locals.Length);
+               for (int i = 0; i < 7; ++i) {
                        if (locals [i].Name == "args") {
                                Assert.IsTrue (locals [i].IsArg);
                                Assert.AreEqual ("String[]", locals [i].Type.Name);
@@ -1397,6 +1431,9 @@ public class DebuggerTests
                                // gshared
                                Assert.IsTrue (locals [i].IsArg);
                                Assert.AreEqual ("String", locals [i].Type.Name);
+                       } else if (locals [i].Name == "rs") {
+                               Assert.IsTrue (locals [i].IsArg);
+                               Assert.AreEqual ("String", locals [i].Type.Name);
                        } else {
                                Assert.Fail ();
                        }
@@ -1563,7 +1600,7 @@ public class DebuggerTests
        public void Dispose () {
                run_until ("Main");
 
-               vm.Dispose ();
+               vm.Detach ();
 
                var e = GetNextEvent ();
                Assert.IsInstanceOfType (typeof (VMDisconnectEvent), e);
@@ -1665,7 +1702,7 @@ public class DebuggerTests
 
        [Test]
        public void Suspend () {
-               vm.Dispose ();
+               vm.Detach ();
 
                Start (new string [] { "dtest-app.exe", "suspend-test" });
 
@@ -1807,11 +1844,27 @@ public class DebuggerTests
                m = t.GetMethod ("invoke_return_nullable");
                v = this_obj.InvokeMethod (e.Thread, m, null);
                Assert.IsInstanceOfType (typeof (StructMirror), v);
+               var s = v as StructMirror;
+               AssertValue (42, s.Fields [0]);
+               AssertValue (true, s.Fields [1]);
+
+               // pass nullable as this
+               //m = vm.RootDomain.Corlib.GetType ("System.Object").GetMethod ("ToString");
+               m = s.Type.GetMethod ("ToString");
+               v = s.InvokeMethod (e.Thread, m, null);
 
                // return nullable null
                m = t.GetMethod ("invoke_return_nullable_null");
                v = this_obj.InvokeMethod (e.Thread, m, null);
-               AssertValue (null, v);
+               Assert.IsInstanceOfType (typeof (StructMirror), v);
+               s = v as StructMirror;
+               AssertValue (0, s.Fields [0]);
+               AssertValue (false, s.Fields [1]);
+
+               // pass nullable as this
+               //m = vm.RootDomain.Corlib.GetType ("System.Object").GetMethod ("ToString");
+               m = s.Type.GetMethod ("ToString");
+               v = s.InvokeMethod (e.Thread, m, null);
 
                // pass primitive
                m = t.GetMethod ("invoke_pass_primitive");
@@ -2028,7 +2081,7 @@ public class DebuggerTests
 
        [Test]
        public void InvokeSingleThreaded () {
-               vm.Dispose ();
+               vm.Detach ();
 
                Start (new string [] { "dtest-app.exe", "invoke-single-threaded" });
 
@@ -2126,6 +2179,11 @@ public class DebuggerTests
                frame.SetValue (p, vm.RootDomain.CreateString ("DEF"));
                AssertValue ("DEF", frame.GetValue (p));
 
+               // byref
+               p = frame.Method.GetParameters ()[3];
+               frame.SetValue (p, vm.RootDomain.CreateString ("DEF2"));
+               AssertValue ("DEF2", frame.GetValue (p));
+
                // argument checking
 
                // variable null
@@ -2350,7 +2408,7 @@ public class DebuggerTests
 
        [Test]
        public void ExceptionFilter2 () {
-               vm.Dispose ();
+               vm.Detach ();
 
                Start (new string [] { "dtest-excfilter.exe" });
 
@@ -2450,7 +2508,7 @@ public class DebuggerTests
 
        [Test]
        public void Domains () {
-               vm.Dispose ();
+               vm.Detach ();
 
                Start (new string [] { "dtest-app.exe", "domain-test" });
 
@@ -2465,6 +2523,17 @@ public class DebuggerTests
 
                var domain = (e as AppDomainCreateEvent).Domain;
 
+               // Check the object type
+               e = run_until ("domains_2");
+               var frame = e.Thread.GetFrames ()[0];
+               var o = frame.GetArgument (0) as ObjectMirror;
+               Assert.AreEqual ("CrossDomain", o.Type.Name);
+
+               // Do a remoting invoke
+               var cross_domain_type = o.Type;
+               var v = o.InvokeMethod (e.Thread, cross_domain_type.GetMethod ("invoke_3"), null);
+               AssertValue (42, v);
+
                // Run until the callback in the domain
                MethodMirror m = entry_point.DeclaringType.GetMethod ("invoke_in_domain");
                Assert.IsNotNull (m);
@@ -2519,7 +2588,7 @@ public class DebuggerTests
                Assert.AreEqual (domain, (e as AppDomainUnloadEvent).Domain);
 
                // Run past the unload
-               e = run_until ("domains_2");
+               e = run_until ("domains_3");
 
                // Test access to unloaded types
                // FIXME: Add an exception type for this
@@ -2545,7 +2614,7 @@ public class DebuggerTests
 
        [Test]
        public void RefEmit () {
-               vm.Dispose ();
+               vm.Detach ();
 
                Start (new string [] { "dtest-app.exe", "ref-emit-test" });
 
@@ -2581,7 +2650,7 @@ public class DebuggerTests
        [Test]
        public void StackTraceInNative () {
                // Check that stack traces can be produced for threads in native code
-               vm.Dispose ();
+               vm.Detach ();
 
                Start (new string [] { "dtest-app.exe", "frames-in-native" });
 
@@ -2926,4 +2995,25 @@ public class DebuggerTests
                Assert.AreEqual (1, args.Length);
                Assert.AreEqual ("T", args [0].Name);
        }
+
+       [Test]
+       public void UnhandledException () {
+               vm.Detach ();
+
+               Start (new string [] { "dtest-app.exe", "unhandled-exception" });
+
+               var req = vm.CreateExceptionRequest (null, false, true);
+               req.Enable ();
+
+               var e = run_until ("unhandled_exception");
+               vm.Resume ();
+
+               var e2 = GetNextEvent ();
+               Console.WriteLine (e2);
+
+               vm.Exit (0);
+               vm = null;
+       }
 }
+
+}
\ No newline at end of file
index 48394fe228dcc02f26f9d990ddd48f33f461aa6a..4e635847f6c6deaedec3e358dd2b6ca21d894b71 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_2_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -64,7 +64,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ddf0a505120b6f18b9d95bb08c59098a0697fdfd..5cfdd71c761fb7b68db2f6c5d4490afc5956a0aa 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -64,7 +64,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 39805c37bc7865ce528654cfd7b4e49214b739b2..9949465b5d378208519a387061bb15f856192c4d 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -64,7 +64,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 71af9cfa63f7be198fffc9b1e992b08631d81bc4..f0a7a70205d5dc1e039816f80b89209e25d34c37 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4becf0d23f0ca3d934524ab7b25684f2c5fa8831..826573c8a263b3464414d134edccabc9bfbe6d6c 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f7e662b7f08f82068d4a937bc7b8de8974b55a2e..1bed863e7b38b41a6bda9b48a14d7ac59325e152 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 07aaea6e4073b77d605bc8b453f02fe1629d50d8..a38d3e8298deed8f0f70eada910415995a3decd4 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_2_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -62,7 +62,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 44d52ce87f7b851ed8bfd627b9ffb005513244f4..7a8894d165036b5c6b70d0d513ef83117b169463 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -62,7 +62,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 57d4209ce9c8970050bd20c5ed0d2824626e00bc..807aa7b61d1a8b033918a2aad6fad4a6b9084432 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -62,7 +62,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9884e4c505ea0174a74ff59cd77ba99e0268bda0..9c845f5a51594e6c2d218203b81d06c0e7643b79 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,618,219,169</NoWarn>\r
+    <NoWarn>1699,618,618,219,169</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,618,219,169</NoWarn>\r
+    <NoWarn>1699,618,618,219,169</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,618,219,169</NoWarn>\r
+    <NoWarn>1699,618,618,219,169</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index efd08de407b31c2fb426a7f2e7e620af4af0025c..c94ac6df60a4409137d10d35876e4448e736e767 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,618,219,169</NoWarn>\r
+    <NoWarn>1699,618,618,219,169</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,618,219,169</NoWarn>\r
+    <NoWarn>1699,618,618,219,169</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,618,219,169</NoWarn>\r
+    <NoWarn>1699,618,618,219,169</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index cfe7272bb4359717fd8518a053c300217e69b27c..8a402fda5416c3bf7ac226aaeccdc897adc06013 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,618,219,169</NoWarn>\r
+    <NoWarn>1699,618,618,219,169</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,618,219,169</NoWarn>\r
+    <NoWarn>1699,618,618,219,169</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,618,219,169</NoWarn>\r
+    <NoWarn>1699,618,618,219,169</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d026034492ad4eee04c43d9a87c06d91ccaba33c..37188d22d323e773d95c58deb73f736a4711372c 100644 (file)
@@ -79,7 +79,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9fcd76ced91b30946bcb00a4927324a9a6fc01cd..a4e1bc628c80ee2b8fc7ccee9069a0ff318ca0b6 100644 (file)
@@ -79,7 +79,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a6c1d9e3cfa7d1b29b0d6860de92730a0bcdb941..c1e1b67c8e93bc228f205968a288f69b38590e55 100644 (file)
@@ -79,7 +79,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index cf6e8ec244083a8d3cf960892c089b46ee23f901..7017257880f196d058f6cb952c3d7766d6db2d81 100644 (file)
@@ -53,7 +53,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 149bc122c3f603e822c8228f99e7be1e049576ac..162e308c8b6755f89ff8e063c4acc3ccc7b4e3e4 100644 (file)
@@ -53,7 +53,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 17345e9adb8e3a5eba674d3bba8cbc943d76465e..21ca426812b15adcc6dc971836898e803bd216a1 100644 (file)
@@ -53,7 +53,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 33d962f481c89bc3a3f12526cfb7b16ade52bf5f..8f6ee01890df80bd160ee4ed9ff4efdc02ec62d0 100644 (file)
@@ -8,7 +8,7 @@ LIBRARY_PACKAGE = none
 NO_INSTALL = yes
 
 LIB_MCS_FLAGS = /r:$(corlib) /r:System.dll
-TEST_MCS_FLAGS = /r:Mono.Posix.dll /r:System.dll
+TEST_MCS_FLAGS = /r:Mono.Posix.dll /r:System.dll /r:System.Core.dll
 
 mono_sourcelibs_DIR  = $(DESTDIR)$(mono_libdir)/mono-source-libs
 mono_options_DATA = Mono.Options/Options.cs
index 984882126c1b8338f2c3b5f5c7e4e51bdab10dd1..c7d3ee415142d7480020f95ada9aa4244477261f 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9bfb2fcc23a6c558239a86a25be1c6af4bb1278f..265a37c06982766991b5be664173a00eaa53e326 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 60c0ae9e81d15c4ae20cfbe54c009d3a24b12876..be1bdbff3760bc8ef06c5371944c0c1996c27400 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index fc4cdfe66ce802025a76c2e0d63b36d56ca933b7..2404e6b3e8d6561ff9f45cf1afa0f29fde414781 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 6ad81b278a020a9f7ef6acac27dacaec9455e807..1ad0192849848fc2b302a17d8365917487c0e878 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index b20a60c1767f2a717c413d2a9e6000999893aa30..62d0318b3193224dfa86b6504e70305c75b9cd54 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 7be7e8b33ca542930129050885b3f6befc2d3ad6..76bb5417fc6f6ae417b3a146a09b8bd4932c3c89 100644 (file)
@@ -6,4 +6,6 @@ LIBRARY = Mono.Parallel.dll
 
 include ../../build/library.make
 
+TEST_MCS_FLAGS = /r:System.Core.dll
+
 LIB_MCS_FLAGS += -d:INSIDE_MONO_PARALLEL -r:$(corlib) -r:System.Core.dll -r:System.dll
index 2862ac69a026a767edab9c398ebb50b2577010cd..6c102a86334c0fae34e8ef875a6f79b1a08ae153 100644 (file)
@@ -68,7 +68,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 41a0b6b0f5f10b1397bd8773e9e7451c2e5c1d88..56170af6f8e96a9d6622e86313e61d6bec78d5f9 100644 (file)
@@ -68,7 +68,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index afbbbddea5b669f61318df3381b9ec2dc6d8d321..2c913a95296a05f3d843364e7435ea9fb5c079ca 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 834b952b0101c727b48adca34c32533970a3c746..47a7105f8087eb2c64aec83a7da50ab3cc14d27d 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ba24c9af8dffc5031050966fee75e5666ccf0ed3..e3fff9f10a094b362a0ce6a2322adbc3c601d736 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 44e6fb3761716fd359fefd10c1cfd606a88a6db0..072c3a4b80af14d925725a0aa15efed7180eb889 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b0547cca7457f62e954bb75d9c3d4012425b4814..5fdc72aa08d1d070232fd10296ed757a20bb85d8 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 039bb5531472b1a8460611107b4fe24b110dc4ea..d011bfc0e3c3a09fc31f7e5830ddac77a833e967 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2b8fcf770d930a457c3a89d244103f80ce175f8f..dadecb8467d923e050a4594df0fa5a68399f77b8 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 57e159fe6eb93b746126889c2ba2eaccb2220394..5f78bf74f0c2696a0679e374ec51a8fb492d6d1d 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 25d357be9470a74d5b77ca8e5278007e98a321fa..0d5a6b9d0e7170ae4dcf5f397bf8b4a0e5a95979 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a96559f7ee1073f9b420a81381cee45c9252a4f8..bef27c9a2b52df4b1c4895aaf3cf10b9026a9481 100644 (file)
@@ -12,7 +12,6 @@ using NUnit.Framework;
 using System;
 using System.Configuration;
 using System.Diagnostics;
-using System.Xml;
 
 using Mono.Unix;
 
index fd04ac2c5396733d643368b3c8c9ffb2400ec7e7..3e3561c8437c7241392b61f57b38e89f77e7f21c 100644 (file)
@@ -12,7 +12,6 @@ using NUnit.Framework;
 using System;
 using System.Configuration;
 using System.Diagnostics;
-using System.Xml;
 using System.Collections;
 
 using Mono.Unix;
index 630597daf1f0ff1d69df1f42f3ee099a3c7d356c..75b9f0cc2eb797c3f2d637f242526b925ac19f0b 100644 (file)
@@ -65,7 +65,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e445101fa80e6338da119c71d75215682e1be9b5..f3cd8190e9b57ab6c790352591e47fc91d5a99f2 100644 (file)
@@ -65,7 +65,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9a9b9e821854c59444276f0eb27a0383efa44cfb..1b2ccccba9301519eaac05aea6873c7a52652d35 100644 (file)
@@ -65,7 +65,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5b9c878bf7303af26c57b151f9c4f977328c3409..54b625012364b0fac0b683b4b2f829ecf965a45e 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <OutputPath>./../../class/lib/build/tmp</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>\r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3236f056dc3abd9bad964da1eef1cf89cb01829d..8cc08c1d8975703d765a8f6614749857d8cb2959 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <OutputPath>./../../class/lib/net_2_0/tmp</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>\r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5748a852e70db0f7b3345d5ccf11fd6cb9e3a34c..ab9f1577a03a356357e5572d0d608361af1f82b5 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_0/tmp</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>\r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0dc1b0c6e6702c316e2ab978d956df7e4780037e..a9abe2b5f9cb0701a355b38936ad2c0736ebd83c 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_5/tmp</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>\r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,1030</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3c6b17478798c0c47294727e333316e4363d9a65..0e581a2ad94c4f244350c09ac8f7ee3d036c576e 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,169,219,618,672</NoWarn>\r
+    <NoWarn>1699,1030,169,219,618,672</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>\r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,169,219,618,672</NoWarn>\r
+    <NoWarn>1699,1030,169,219,618,672</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,169,219,618,672</NoWarn>\r
+    <NoWarn>1699,1030,169,219,618,672</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -94,7 +94,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c952e681254f0b2217d23b49c84bb5ad72731c26..19093ced02ac974f771c36cab68049f11e09c95b 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,169,219,618,672</NoWarn>\r
+    <NoWarn>1699,1030,169,219,618,672</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>\r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,169,219,618,672</NoWarn>\r
+    <NoWarn>1699,1030,169,219,618,672</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,169,219,618,672</NoWarn>\r
+    <NoWarn>1699,1030,169,219,618,672</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -94,7 +94,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9d0df51c7836d24ae04401dcc2ca40b2cacc897d..1b4b5523497b7f09e7d0a719560bfa9f8db2cf44 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,169,219,618,672</NoWarn>\r
+    <NoWarn>1699,1030,169,219,618,672</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>\r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,169,219,618,672</NoWarn>\r
+    <NoWarn>1699,1030,169,219,618,672</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,169,219,618,672</NoWarn>\r
+    <NoWarn>1699,1030,169,219,618,672</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -94,7 +94,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 99e10ce2517d33069d233bc2e1256db87e655ace..2a54a7e4ae9f769ecf0eae39f7e0eb4ec26dfb6b 100644 (file)
@@ -70,9 +70,15 @@ namespace Mono.Security.Cryptography {
                }
 
                public override byte[] Key {
-                       get { return (byte[]) key.Clone (); }
+                       get {
+                               if (KeyValue == null)
+                                       GenerateKey ();
+                               return (byte[]) KeyValue.Clone (); 
+                       }
                        set { 
-                               key = (byte[]) value.Clone ();
+                               if (value == null)
+                                       throw new ArgumentNullException ("Key");
+                               KeyValue = key = (byte[]) value.Clone ();
                                KeySetup (key);
                        }
                }
@@ -101,7 +107,7 @@ namespace Mono.Security.Cryptography {
 
                public override void GenerateKey () 
                {
-                       Key = KeyBuilder.Key (KeySizeValue >> 3);
+                       KeyValue = KeyBuilder.Key (KeySizeValue >> 3);
                }
 
                public bool CanTransformMultipleBlocks {
index b7000b8997082e99f6ece7d12960f3d67506e68a..88d4fe59955af86f654d2a5f8ce3093d10720a63 100644 (file)
@@ -41,11 +41,13 @@ namespace Mono.Security.Cryptography {
                private ulong count;
                private byte[] _ProcessingBuffer;   // Used to start data when passed less than a block worth.
                private int _ProcessingBufferCount; // Counts how much data we have stored that still needs processed.
+               private uint[] buff;
 
                public SHA224Managed ()
                {
                        _H = new uint [8];
                        _ProcessingBuffer = new byte [BLOCK_SIZE_BYTES];
+                       buff = new uint[64];
                        Initialize ();
                }
 
@@ -155,22 +157,26 @@ namespace Mono.Security.Cryptography {
                        uint a, b, c, d, e, f, g, h;
                        uint t1, t2;
                        int i;
-                       uint[] buff;
+                       uint[] K1 = SHAConstants.K1;
+                       uint[] buff = this.buff;
                
                        count += BLOCK_SIZE_BYTES;
                
-                       buff = new uint[64];
-
                        for (i=0; i<16; i++) {
-                               buff[i] = ((uint)(inputBuffer[inputOffset+4*i]) << 24)
-                                       | ((uint)(inputBuffer[inputOffset+4*i+1]) << 16)
-                                       | ((uint)(inputBuffer[inputOffset+4*i+2]) <<  8)
-                                       | ((uint)(inputBuffer[inputOffset+4*i+3]));
+                               buff[i] = (uint)(((inputBuffer[inputOffset+4*i]) << 24)
+                                       | ((inputBuffer[inputOffset+4*i+1]) << 16)
+                                       | ((inputBuffer[inputOffset+4*i+2]) <<  8)
+                                       | ((inputBuffer[inputOffset+4*i+3])));
                        }
 
                
                        for (i=16; i<64; i++) {
-                               buff[i] = Ro1(buff[i-2]) + buff[i-7] + Ro0(buff[i-15]) + buff[i-16];
+                               t1 = buff[i - 15];
+                               t1 = (((t1 >> 7) | (t1 << 25)) ^ ((t1 >> 18) | (t1 << 14)) ^ (t1 >> 3));
+
+                               t2 = buff[i - 2];
+                               t2 = (((t2 >> 17) | (t2 << 15)) ^ ((t2 >> 19) | (t2 << 13)) ^ (t2 >> 10));
+                               buff[i] = t2 + buff[i - 7] + t1 + buff[i - 16];
                        }
 
                        a = _H[0];
@@ -183,8 +189,10 @@ namespace Mono.Security.Cryptography {
                        h = _H[7];
 
                        for (i=0; i<64; i++) {
-                               t1 = h + Sig1(e) + Ch(e,f,g) + SHAConstants.K1 [i] + buff[i];
-                               t2 = Sig0(a) + Maj(a,b,c);
+                               t1 = h + (((e >> 6) | (e << 26)) ^ ((e >> 11) | (e << 21)) ^ ((e >> 25) | (e << 7))) + ((e & f) ^ (~e & g)) + K1[i] + buff[i];
+
+                               t2 = (((a >> 2) | (a << 30)) ^ ((a >> 13) | (a << 19)) ^ ((a >> 22) | (a << 10)));
+                               t2 = t2 + ((a & b) ^ (a & c) ^ (b & c));
                                h = g;
                                g = f;
                                f = e;
index a86e4217234aea905661f840f53c0cb80788fbd9..40274a6200c1bd624d88675acc5ac345fb0d6696 100644 (file)
@@ -73,6 +73,15 @@ namespace Mono.Security.Protocol.Tls.Handshake.Server
                         * attributeValue ANY }
                         */
 
+                       /*
+                       *  From RFC 5246:
+                       *       If the certificate_authorities list is empty, then the client MAY
+                       *       send any certificate of the appropriate ClientCertificateType,
+                       *       unless there is some external arrangement to the contrary.
+                       *
+                       *  Better let the client choose which certificate instead of sending down
+                       *  a potentially large list of DNs.
+
                        if (context.ServerSettings.DistinguisedNames.Length > 0)
                        {
                                TlsStream list = new TlsStream ();
@@ -88,8 +97,9 @@ namespace Mono.Security.Protocol.Tls.Handshake.Server
                        }
                        else
                        {
+                       */
                                this.Write ((short)0);
-                       }
+                       //}
                }
 
                #endregion
index cc36ee83b74164a2e8235496372e4e8037777482..3c57868bf9b579588c54169c58cf1a512fc0787a 100644 (file)
@@ -263,15 +263,6 @@ namespace Mono.Security.Protocol.Tls
                                }
                        }
 
-                       if (certRequested) {
-                               X509Certificate client_cert = this.context.ClientSettings.ClientCertificate;
-                               if (client_cert == null && ((ServerContext)this.context).ClientCertificateRequired)
-                                       throw new TlsException (AlertDescription.BadCertificate, "No certificate received from client.");
-
-                               if (!RaiseClientCertificateValidation (client_cert, new int[0]))
-                                       throw new TlsException (AlertDescription.BadCertificate, "Client certificate not accepted.");
-                       }
-
                        // Send ChangeCipherSpec and ServerFinished messages
                        this.protocol.SendChangeCipherSpec();
                        this.protocol.SendRecord (HandshakeType.Finished);
index 9a618feafc4a09856a3f2f1029e1bd97ef3cbba0..b7307cc9b1b50a7291ab0de542c2cc10b458ca5c 100644 (file)
@@ -24,7 +24,7 @@ namespace MonoTests.Mono.Security.Cryptography {
 
        // MD2 is a abstract class - so ALL of the test included here wont be tested
        // on the abstract class but should be tested in ALL its descendants.
-       public class MD2Test : Assertion {
+       public abstract class MD2Test : Assertion {
 
                protected MD2 hash;
 
index 74e935c731dafd2db11ab45910fdd4d2e66ba1f1..dd36e8fa412911d19cf3d67b5ff43b8fbb1b8a68 100644 (file)
@@ -24,7 +24,7 @@ namespace MonoTests.Mono.Security.Cryptography {
 
        // MD4 is a abstract class - so ALL of the test included here wont be tested
        // on the abstract class but should be tested in ALL its descendants.
-       public class MD4Test : Assertion {
+       public abstract class MD4Test : Assertion {
 
                protected MD4 hash;
 
index 9aeeec781b5e05f0470c16c504c201d503c48c76..79bc2d9ca281c83f923810ab907c27c1bdef7382 100644 (file)
@@ -35,7 +35,7 @@ namespace MonoTests.Mono.Security.Protocol.Ntlm {
                        msg.Password = "WELCOME";
                        msg.Username = "username";
                        AssertEquals ("Type", 3, msg.Type);
-                       AssertEquals ("GetBytes", "4E-54-4C-4D-53-53-50-00-03-00-00-00-18-00-18-00-64-00-00-00-18-00-18-00-7C-00-00-00-0C-00-0C-00-40-00-00-00-10-00-10-00-4C-00-00-00-08-00-08-00-5C-00-00-00-00-00-00-00-94-00-00-00-01-82-00-00-44-00-4F-00-4D-00-41-00-49-00-4E-00-75-00-73-00-65-00-72-00-6E-00-61-00-6D-00-65-00-48-00-4F-00-53-00-54-00-CA-12-00-72-3C-41-D5-77-AB-18-C7-64-C6-DE-F3-4F-A6-1B-FA-06-71-EA-5F-C8-7A-CE-90-85-AB-CC-37-59-38-0B-1C-68-62-E3-98-C3-C0-EF-9C-FC-22-E8-A2-C2", BitConverter.ToString (msg.GetBytes ()));
+                       AssertEquals ("GetBytes", "4E-54-4C-4D-53-53-50-00-03-00-00-00-18-00-18-00-64-00-00-00-18-00-18-00-7C-00-00-00-0C-00-0C-00-40-00-00-00-10-00-10-00-4C-00-00-00-08-00-08-00-5C-00-00-00-00-00-00-00-94-00-00-00-01-B2-00-00-44-00-4F-00-4D-00-41-00-49-00-4E-00-75-00-73-00-65-00-72-00-6E-00-61-00-6D-00-65-00-48-00-4F-00-53-00-54-00-CA-12-00-72-3C-41-D5-77-AB-18-C7-64-C6-DE-F3-4F-A6-1B-FA-06-71-EA-5F-C8-7A-CE-90-85-AB-CC-37-59-38-0B-1C-68-62-E3-98-C3-C0-EF-9C-FC-22-E8-A2-C2", BitConverter.ToString (msg.GetBytes ()));
                }
 
                [Test]
@@ -49,7 +49,7 @@ namespace MonoTests.Mono.Security.Protocol.Ntlm {
                        msg.Password = "Beeblebrox";
                        msg.Username = "Zaphod";
                        AssertEquals ("Type", 3, msg.Type);
-                       AssertEquals ("GetBytes", "4E-54-4C-4D-53-53-50-00-03-00-00-00-18-00-18-00-72-00-00-00-18-00-18-00-8A-00-00-00-14-00-14-00-40-00-00-00-0C-00-0C-00-54-00-00-00-12-00-12-00-60-00-00-00-00-00-00-00-A2-00-00-00-01-82-00-00-55-00-52-00-53-00-41-00-2D-00-4D-00-49-00-4E-00-4F-00-52-00-5A-00-61-00-70-00-68-00-6F-00-64-00-4C-00-49-00-47-00-48-00-54-00-43-00-49-00-54-00-59-00-AD-87-CA-6D-EF-E3-46-85-B9-C4-3C-47-7A-8C-42-D6-00-66-7D-68-92-E7-E8-97-E0-E0-0D-E3-10-4A-1B-F2-05-3F-07-C7-DD-A8-2D-3C-48-9A-E9-89-E1-B0-00-D3", BitConverter.ToString (msg.GetBytes ()));
+                       AssertEquals ("GetBytes", "4E-54-4C-4D-53-53-50-00-03-00-00-00-18-00-18-00-72-00-00-00-18-00-18-00-8A-00-00-00-14-00-14-00-40-00-00-00-0C-00-0C-00-54-00-00-00-12-00-12-00-60-00-00-00-00-00-00-00-A2-00-00-00-01-B2-00-00-55-00-52-00-53-00-41-00-2D-00-4D-00-49-00-4E-00-4F-00-52-00-5A-00-61-00-70-00-68-00-6F-00-64-00-4C-00-49-00-47-00-48-00-54-00-43-00-49-00-54-00-59-00-AD-87-CA-6D-EF-E3-46-85-B9-C4-3C-47-7A-8C-42-D6-00-66-7D-68-92-E7-E8-97-E0-E0-0D-E3-10-4A-1B-F2-05-3F-07-C7-DD-A8-2D-3C-48-9A-E9-89-E1-B0-00-D3", BitConverter.ToString (msg.GetBytes ()));
                }
 
                [Test]
index 4370faccf84d841b0ab7c90b2cb45f80127464fc..caa8cf9b22fd4bd1023a8a16331173cf150cd18a 100644 (file)
@@ -107,7 +107,7 @@ namespace MonoTests.Mono.Security.X509 {
                        Assert.AreEqual ("<DSAKeyValue><P>3+URPtrptm4Q1uqd4p06sEe9RADHVsjMbtAzhFZHNT32VMjjwq27unXzLzMMpvkx7Gfj5Zlt/CluqleIcjTijgCQ4KOsZI7A9jwdj7TISkgwXn+qnHYmC9sTczODl8DFs+Y39T7/FQ3UoS66Mfirh9gLzHeYQm6sk5jCvS57NAs=</P><Q>zwYE2P+L6wDp9lwHlnP9lmU6Lwc=</Q><G>zOF8sM6SX2PsOLtEut2SNLZevmV72HF3BJ3sZnw7BM6281L+D5JVAu9OEqtdmi4vblbzcOxq7ZsiuKgTywycFurBCo4hJkSlDPmg7GLgcDHMaPULhaRKG2559MH5Nlo4b07vhFPfZ/3M91lij5yczRCPXKQPnLcH7GDzvq9+OZg=</G><Y>EfK52L5CK8WEvpECHPyMMnKLqGwh14iKFLowZXXAHD2CaWWnrJB6FB2Fe+VTwmD8sc9nr8HyLggyajjHkU47vDwJ0PlxbQjfJ0mNBXTYvUbQ21GlU7qH8/pdJYNPfwp15anjiadBd2NAXysshNLBcXgK22tXGeHnFAyexPYyOQ4=</Y></DSAKeyValue>", ca.DSA.ToXmlString (false), "DSA");
                        Assert.AreEqual (5, ca.Extensions.Count, "Extensions");
                        Assert.AreEqual ("20-98-19-23-3C-FC-D9-C9-02-BA-BE-C6-42-BF-87-15-54-A1-7A-39", BitConverter.ToString (ca.Hash), "Hash");
-                       Assert.IsTrue (ca.IsCurrent, "IsCurrent"); // true until 2011
+                       Assert.IsFalse (ca.IsCurrent, "IsCurrent"); // true until 2011
                        Assert.IsFalse (ca.IsSelfSigned, "IsSelfSigned");
                        Assert.AreEqual ("C=US, O=Test Certificates, CN=Trust Anchor", ca.IssuerName, "IssuerName");
                        Assert.AreEqual ("1.2.840.10040.4.1", ca.KeyAlgorithm, "KeyAlgorithm");
@@ -131,7 +131,7 @@ namespace MonoTests.Mono.Security.X509 {
                        X509Certificate ca = new X509Certificate (DSAParametersInheritedCACert_crt);
                        Assert.AreEqual (5, ca.Extensions.Count, "Extensions");
                        Assert.AreEqual ("F5-F0-0D-21-1E-87-B9-F6-E1-85-AB-04-5F-43-2A-FD-EA-96-BC-D9", BitConverter.ToString (ca.Hash), "Hash");
-                       Assert.IsTrue (ca.IsCurrent, "IsCurrent"); // true until 2011
+                       Assert.IsFalse (ca.IsCurrent, "IsCurrent"); // true until 2011
                        Assert.IsFalse (ca.IsSelfSigned, "IsSelfSigned");
                        Assert.AreEqual ("C=US, O=Test Certificates, CN=DSA CA", ca.IssuerName, "IssuerName");
                        Assert.AreEqual ("1.2.840.10040.4.1", ca.KeyAlgorithm, "KeyAlgorithm");
index ca1e5d46db1ac4fd074ce7d68b3edce13303455e..97a65bee7a5b8b36b358ce08ef9db4d6d2bc7d90 100644 (file)
@@ -71,7 +71,7 @@ namespace MonoTests.Mono.Security.X509 {
                        X509Crl crl = new X509Crl (basicConstraintsCriticalcAFalseCACRL_crl);
                        Assert.AreEqual (0, crl.Entries.Count, "Entries.Count");
                        Assert.AreEqual (2, crl.Extensions.Count, "Extensions.Count");
-                       Assert.IsTrue (crl.IsCurrent, "IsCurrent"); // true till 2011
+                       Assert.IsFalse (crl.IsCurrent, "IsCurrent"); // true till 2011
                        Assert.AreEqual ("C=US, O=Test Certificates, CN=basicConstraints Critical cA False CA", crl.IssuerName, "IssuerName");
                        Assert.AreEqual (634388218400000000, crl.NextUpdate.ToUniversalTime ().Ticks, "NextUpdate");
                        Assert.AreEqual ("32-BC-12-1F-84-D0-B6-3E-72-A0-FB-D9-75-99-CA-E5-2A-05-09-E6-C8-27-74-47-1C-DC-0C-D4-9F-BC-9F-B2-62-25-B4-6D-5B-E5-0B-E8-2A-8E-07-EB-3E-6B-C5-1E-9A-D2-14-FD-89-5B-C3-10-BF-19-77-67-0A-33-45-1B-BC-6C-ED-AF-84-30-59-FB-7C-71-95-63-60-31-9B-9B-0A-EA-77-F1-70-F1-B9-2E-D1-A9-04-42-66-94-B9-54-48-DB-44-56-56-1A-57-5A-01-0E-7C-4D-D7-C0-1F-5C-6F-13-F5-A3-57-88-6A-9A-71-CD-D5-AE-C3-00-B1-28", BitConverter.ToString (crl.Signature), "Signature");
index 005bb5568564ad3c52f3bf7a5f4c3d88101412b4..215b8192bf4bb513423ec75c78342e53adeca672 100644 (file)
@@ -69,7 +69,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4424729483d4d830a50e8e8175d8e826d1b9786c..b28d69d11e23e85dc0c81ccbf99fbc86835f7088 100644 (file)
@@ -69,7 +69,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index da2def139f355e52d5dc95373660f9141cf46438..7ddfeabe88d5b8583fbb8fb49a518926d6d5363c 100644 (file)
@@ -69,7 +69,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2fc9c5688e6162a760f86418b17c9eaab03d9658..60acc6116b38f1bc32f62bb347d3d67be954fd36 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 75fc4779bae113e555d253d6c8d1dcb221a650cb..c1baf512a0ac0c9b5f40194c5dd00669880a6eec 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0bc27ea9d713ad616e50fd80eaf0fb94f4966cf9..9b78daef9f762d469f38ef908b5ef937de28ade5 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d2c13e920574a323e439af14087fa9d6f4e15077..e6e7b977baa9cc2e666f860c8c81de69239dff77 100644 (file)
@@ -61,7 +61,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0b53aae7021f8783b46ce1ac694fdbb06289407b..0071e5a36edd7810fd7db1fa081e74a8a731762a 100644 (file)
@@ -61,7 +61,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0e29b755826d37e6bbc403516f55951daf5a2ab0..76a3dc491e977448854c4bca1ccb953e9e9d864d 100644 (file)
@@ -61,7 +61,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5c18c2618e5555c7de7db06b0cc56aa92f2bfbba..8511988b5072fc0b233636202594611c92ccd930 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,108</NoWarn>\r
+    <NoWarn>1699</NoWarn>\r
     <OutputPath>./../../class/lib/net_2_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,108</NoWarn>\r
+    <NoWarn>1699</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,108</NoWarn>\r
+    <NoWarn>1699</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 11eb213331fc0db7eb1244cc7f24d1f8a15af89f..051626ee5810ce3577c5fe5a75d24bc3fbba9863 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,108</NoWarn>\r
+    <NoWarn>1699</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,108</NoWarn>\r
+    <NoWarn>1699</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,108</NoWarn>\r
+    <NoWarn>1699</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index aa2d5e6ae77866e47ff916f0ffc798219fb70a5a..57352ebf44c7f4cf2c4066970902f8a511efd86a 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,108</NoWarn>\r
+    <NoWarn>1699</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,108</NoWarn>\r
+    <NoWarn>1699</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,108</NoWarn>\r
+    <NoWarn>1699</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 6bf2ff64352ac9a05ee3c8495a0239c41065f774..60c5abcbfb468483ea7eff6238cb6ce9499d6291 100644 (file)
@@ -8,7 +8,7 @@ LIBRARY_USE_INTERMEDIATE_FILE = yes
 ifeq ($(PROFILE),atomic)
 SCARY_LIB=
 else
-SCARY_LIB=/lib:$(prefix)/lib /noconfig
+SCARY_LIB=/lib:$(prefix)/lib
 endif
 
 LIB_MCS_FLAGS = $(SCARY_LIB) /unsafe /r:$(corlib) /r:System.dll /r:System.Xml.dll
index a0bacad7090601d85e5e8a996ed8785c6c3c2d45..7dff57adf38b69299846f10e3d441e5f21d9d3d4 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 68a7cc483fa297c87e33a0536de2195b02eb8ae0..b19d50f5d8861f7a160dfc5c73a31d817b766bc7 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2390f30935cc6672b259144ad085b64cdf7c9d6c..49f3787d69e75bdcd7188b71bca47fd8ebaa990f 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1be7ca070d324aae92e2cce5efa36a2f92cf6a0a..196a7c4be4dd584c38ac161933d5ae0e525b5e44 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,649,169,219,168</NoWarn>\r
+    <NoWarn>1699,612</NoWarn>\r
     <OutputPath>./../../class/lib/net_2_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,649,169,219,168</NoWarn>\r
+    <NoWarn>1699,612</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,649,169,219,168</NoWarn>\r
+    <NoWarn>1699,612</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index bcc6af9cba7069916282c09bb81db325535738d0..2b1327510e0611b38dc1f18d9645796998c97f03 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,649,169,219,168</NoWarn>\r
+    <NoWarn>1699,612</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,649,169,219,168</NoWarn>\r
+    <NoWarn>1699,612</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,649,169,219,168</NoWarn>\r
+    <NoWarn>1699,612</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2ca77d9fab7406a34eb43521c7cd48fae24a0ee6..0df5a4616a18ea3463cbdeb9d676fa6b5cc8d005 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699,649,169,219,168</NoWarn>\r
+    <NoWarn>1699,612</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699,649,169,219,168</NoWarn>\r
+    <NoWarn>1699,612</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699,649,169,219,168</NoWarn>\r
+    <NoWarn>1699,612</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 66d80cf395a1839cbc45497eab45a448742a2778..b39007b86ae2057fe18994d9ffec18b95de20bad 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 955a81c5469bf38ea987d7dd3e493a49d66547d8..dfc93f028fa9375e13566b77b39f80ea3d19d7a2 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 31b3b362e4dba5a4e9fc1f8ae8791f0b2e4468e9..b44d9f80291ec46c607df10af0f0b7b44b820196 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 74a70a428dd367f0e0d3ef1ada0f039b376006df..d2639929f9cc6f44c2f785fca2e08b8a30d6faa5 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 266d559ba3f8740d2f42053135914e68a47f4cca..bbbb51689fe131783cb5c70d70306d4aeb5e8db4 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4d87e1a3dd61578abd4cff29da4c524281fdf46c..ad8652f017f2b917312c9b0f764c7e3a18325eb8 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 6cec23ca3f7c62d13ba66d51a08cfd693eefaca7..57820b67a2de233ff4a188e82119cda29af6c57c 100644 (file)
@@ -56,7 +56,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 27fb79c8d98a4118167b45dc4d277c6abf4f6cf6..8bf0200fedd87edc0c92d1ae326948bb2e357301 100644 (file)
@@ -56,7 +56,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f81241c7a61999830d50fd17e934ae61be28472f..223933e5296caa945bf4a1e8f530c1f4f6b07ef0 100644 (file)
@@ -56,7 +56,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ac2443f0c57fbac780dd087fe115d8076ea1c8ab..b4dedac809ace6a4eeb8613ce91f296463641dd0 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2ca5f354a22234b1929b75c97fbd8e7b8d473f19..459d0195a8e100f4d04c0eeec7ef554e7c5e9eb6 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4ffa83b16af4331066deeab358b98ced27f881a0..eb0ab4038d32b51481ba8eaa3ef8b752da97f6a0 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3156187605ab90effd1ce97cbe4ed68f39de6471..1f58bd82286b71c7c462dc88641f15567b29b993 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_2_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7cae5d1f3e9eeee98360f894b53b15e82afdf182..bd0bac5e8e38b70ab8a6969b55aef1c76ddde42f 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7f94c2b1727ff024f46bc5b1abdf2c270e61263f..7d96992ee2e6f22ff7d9f85ec4ac09de15a54a83 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3e27f6df549bb21e493f3475013e0b7e1b7ad63c..125dac7967db57ecec57195b105e65c86c8a72d9 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../../../class/lib/net_2_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c4def4bf476ff7d347c8bca054ff5fba0093ccf0..672b27703c07774f4b5692517df3ae4e15842cd9 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../../../class/lib/net_4_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a960661833911ea616fa6ca2d3c3165976f616cb..bb01d258b60efb1c718b2e30480960614369b346 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../../../class/lib/net_4_5</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5b12a614624525f11cba2021449e46cc86844073..da023363b345d348a66345c29360cafd2425148e 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 548f784d9dbbcb538ac88f0f8305132bc58d65ab..cbe6bf5266ba0038af9e9b47d4ef199ca149bf38 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 72a75a4b2e3d7eb58be3ec470ecfa3e04f95d5ec..e05f4a423b03c173ddca48aca8871aac4a29bc4b 100644 (file)
@@ -79,7 +79,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ec5873b8876f1693d404bd6ffe5a113657a3819c..4600bdd3d1b015bc823c0505285d0816fd6e0f3b 100644 (file)
@@ -83,7 +83,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c3e376548bb2084c7e0b0fa2d18caedd00e70ea0..a85a66fbddd133de9e37a6b2bf3d80fa728b598f 100644 (file)
@@ -83,7 +83,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4e70412c7b304206b191ada01380fb411bbdee06..2df15f89bc6f49205acc2dc5dbe6576bcab09151 100644 (file)
@@ -65,7 +65,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5203e3ddfd1162f72d46098ad64c7f7736944fce..aee8336d8f3cd6a5cedc59d27cba7a4d9483ba77 100644 (file)
@@ -65,7 +65,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9d7f0a7e18862e43989fdff2b1c67a49fbbf2900..dde7a136da2cbd70b9d5a77b0424e6ad97b0abc9 100644 (file)
@@ -65,7 +65,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b087418b0c9979135a0f5b32e5b1db5c2dec048c..7ec3de881784807bd5e6990e34f0e23f40fc4c8a 100644 (file)
@@ -69,7 +69,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 6a2c16693c2f4687b5fb661a61389168ab5b9bfb..5c0b71b6f662a37002d76f28db5e83b078203b2f 100644 (file)
@@ -69,7 +69,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4e9bd4d1b188e5414522f2ba1b116a4b5fbb79e5..1d907a691829e02a4d41c2fbf67b06523c5cb23f 100644 (file)
@@ -69,7 +69,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5f9bd589a6575e716e23e3b0511a18b2d351eb97..0719bcc89e23566b64a9f0d965c78bd097f1698d 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_2_0/tmp</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index bf62825244bceff9da36c52b82a15e55e7c907ad..07d44ae99408a7a92c1a51ced58029295000309d 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_0/tmp</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5a24c1bf97fd5b37f36eb8c9fe65e642cc130530..4384eb89c8adc9c8d8eab917cadb55123781a3da 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_5/tmp</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 480d0bc1ff9a9c42ea52d45eb55dfb454abd68cd..b550414021e3ce0286a70e076f81979da496e83f 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -85,7 +85,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8d908c642e7303d746862c8967d4342d76577901..39f21a91c0c58aa425454d30a3766b6ec98c7595 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -85,7 +85,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5595a6415d8a4878b328adf044efbcc9c25b024b..2731b24f5a33280670bd0581df2e17abb31b9fbb 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <OutputPath>.\</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     \r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,618</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -85,7 +85,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c845fa045383f311cdcc2051423a16a66bd4052b..f21ffa26a3d9812ff939b80a2256e2de4ab21de1 100644 (file)
@@ -300,7 +300,7 @@ namespace System.Configuration {
                        sec.RawXml = xml;
                        sec.Reset (parentSection);
 
-                       if (xml != null && xml == data) {
+                       if (xml != null) {
                                XmlTextReader r = new ConfigXmlTextReader (new StringReader (xml), FilePath);
                                sec.DeserializeSection (r);
                                r.Close ();
index 2256270a13c0d0a53fac31d5158236467ca29a4b..8482c9330cb2d737ee02d46994b55aab071fafd7 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 46ba6c106e839acdeb068a1ae6540b2a0ae359fb..cec2511b404af2e3b63d855f784905b0cb63e39e 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 47ca2c1533d25675da6ca04c3731a37727fb1449..b83dae90a6b776a935d5ca8675d10f5e0972d2c4 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 35edd896af063fb1262e37536d0545b1f8cd87b6..4b02440eedc35006efe96e6ebc5c75edfd7db6e0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5d0645c62c1f54f08ac1469ba88b2cc6eb9547d5..2faa06229104b43f6aecf34715e658db3c61c798 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index dd480e9f6b00fe9bab9b8a9cc033e0b8e705f660..987950ef492fc08bf1cd21ee9ff745225e863dde 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f530e0a4258f75d94f5f3a9349d5e300bce0f291..08ec0e960a7313059ea09b890e7387e400abddb0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index cada3e7f05d64e4a01a47ab258c511731186c033..e09dfbf9543e143e154145ba89f3cfad81328d24 100644 (file)
@@ -35,7 +35,7 @@ namespace System.Linq.Parallel.QueryNodes
        internal class QueryConcatNode<TSource> : QueryMuxNode<TSource, TSource, TSource>
        {
                public QueryConcatNode (QueryBaseNode<TSource> first, QueryBaseNode<TSource> second)
-                       : this (first, second)
+                       : base (first, second)
                {
                }
 
index 9ecddc135637af5a770890fdc0786123860555cb..d2c2a348d5f3770b90ef44d5f66cb20bf4e0fe0c 100644 (file)
@@ -41,7 +41,6 @@ System.Collections.Generic/HashSet.cs
 System.Security.Cryptography/Aes.cs
 System.Security.Cryptography/AesManaged.cs
 System.Security.Cryptography/AesTransform.cs
-System.Threading/LockRecursionException.cs
 System.Threading/LockRecursionPolicy.cs
 System.Threading/ReaderWriterLockSlim.cs
 System.Threading/ThreadLockState.cs
index 8557ca9f2afc6c7229c09ac1781fa8431d0f0213..c83f55da3989be58f1549ef9b882934684c65090 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 075c00f8fcf174a3253f96a1cdbfa83a091b35b6..1a1eef304034df242346a8d55ab3fdb4017c9549 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index de02b4ea59d84c6cee8d510cdb491b31652ebd85..73815881a850e5bb77f992a692a899cb4fb38659 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 75f00def0d51b1400c7affdde051727d7bbd2dab..891d521e9c5fb22f33f7126a7f537f2be0d48fb2 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1aade9b045d545bfa34d34d167739a5abf4d3844..606722e8a715d02d288c281735610f02a525dbf7 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 338a7544c571ee5dd9c5aee5e0e61078197e798b..afee711a089f5bf12f89c6c8bdce9027aaaa1992 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 11fd906d60a0f700e8a0ad2d3b2f913f4971b321..c262be51a97be37d2be934b4c0a143165c1560fb 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9d5cc3daae1cdfb38ca25170c3bfa2ca32591bf0..c14d8fc525cfda2f42d2141a17c1fd36c1ab7ff6 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f4dd8795c52f38e5ef476dcb90a4d0a743f8d0de..ee37707e4855c126e847d7e406c58fa503901723 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9e8c0b02fe18ac71edb7fe784fd0b2416eb3ae09..b6c229efb5eb0e815a2f7371a64a2480c6bd3eb7 100644 (file)
@@ -294,7 +294,11 @@ namespace DbLinq.Data.Linq
             _VendorProvider = ObjectFactory.Get<IVendorProvider>();\r
             Vendor = vendor ?? \r
                 (connectionString != null ? GetVendor(ref connectionString) : null) ??\r
+#if MOBILE\r
+                _VendorProvider.FindVendorByProviderType(typeof(DbLinq.Sqlite.SqliteSqlProvider));\r
+#else\r
                 _VendorProvider.FindVendorByProviderType(typeof(SqlClient.Sql2005Provider));\r
+#endif\r
             \r
             DatabaseContext = databaseContext;\r
 \r
index 7fe3eafd4f7f2472140238aebc0faf358f727ac0..af98257847a099519f8004b354f858980e3b5334 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8fa468faee2a230d2aff9510ca023e5c0ed348e9..5205606051ca4d10ac61a0c3b8fb7e16904708f5 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 93ad841b9f7cd8a6729e2b690c19e5ff7587d7be..6e7b2f8605a96bb6450729fb015fe30e6d1e77c1 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 380a896ee638e393126beae5818a716a753a35e2..302e85e202a031cfa0425afbf40ac9c308b1d5dc 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 70d65beb018df7b82d91958b517ae19c4bd371ad..8b5a859599fce3e43a5a28b9e61a3d1a4101ff81 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 06eecb91a1089e16251dfc78e3c9c156dbf84f1b..f6f5cf9aa87b6a74cd7057eef1ed17e4985e6b4c 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b5b960f0ecf9403b1aa6993e0c6f1f29539c19d6..beb7333ce7dda4d5189e5a5b6980719238b79de0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
   </ItemGroup>\r
-  \r
+    <ItemGroup>
+    <EmbeddedResource Include="Client/System.Data.Services.Client.resources">
+       <LogicalName>System.Data.Services.Client.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
 </Project>\r
 
index 782c540d7f2c9228b216dab03336dcec338db3f4..43b963c02d9ae1aa0ec6647be23ce558f8a1cf6d 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
   </ItemGroup>\r
-  \r
+    <ItemGroup>
+    <EmbeddedResource Include="Client/System.Data.Services.Client.resources">
+       <LogicalName>System.Data.Services.Client.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
 </Project>\r
 
index 68209a64a727c1de818e910253db8ce2f834cbd5..e43b1a922e2e4e7f9b6922a5ed3b014c3dfcb7d0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
   </ItemGroup>\r
-  \r
+    <ItemGroup>
+    <EmbeddedResource Include="Client/System.Data.Services.Client.resources">
+       <LogicalName>System.Data.Services.Client.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
 </Project>\r
 
index 8ac26328afbd999ec5f579589f091db39c99f76c..fd39977f965b132bb9f794c9989e0a57b7210c40 100644 (file)
@@ -12,6 +12,6 @@ LIB_MCS_FLAGS = \
        -r:System.ServiceModel.Web.dll \
        -r:System.Data.Services.Client.dll
 
-TEST_MCS_FLAGS += -r:System.ServiceModel
+TEST_MCS_FLAGS = -r:System.ServiceModel.dll -r:System.Core.dll
 
 include ../../build/library.make
index 148d36dfd7ad4920eb733df69519da059a2fad5d..5a7c1958f5a5e94948337e2f29af72542e667824 100644 (file)
@@ -78,7 +78,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 12d1ac84c0ae71854448f7a9e1041cf6b91d3eaf..273d32a672ae8e88a978d7d5683252fb62edd9d7 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 95012dc0c840d2c5b8785bc9d22819ae16a6bf05..b40dd0ba6ce2c263072c31c0fac46be6c86b4c9e 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ae75a1a43f87f368b5d88465f6bbe876765ac2a4..a5d51e3ca2c7971a266595c70b3202d9c234625b 100644 (file)
@@ -63,7 +63,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_2_0/System.Data.Services.dll</HintPath>
     </Reference>
-    <Reference Include="System.ServiceModel">
+    <Reference Include="System.ServiceModel.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.ServiceModel</HintPath>
+      <HintPath>System.ServiceModel.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="nunit.framework" />
 \r
index 7543b064b7d108e616f0284729d23ad49d3279ed..09c35975cefdbd660c50d9136e2891d12843b03b 100644 (file)
@@ -63,7 +63,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_0/System.Data.Services.dll</HintPath>
     </Reference>
-    <Reference Include="System.ServiceModel">
+    <Reference Include="System.ServiceModel.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.ServiceModel</HintPath>
+      <HintPath>System.ServiceModel.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="nunit.framework" />
 \r
index 7ced73a7a7673a40d4fd3ea9dbf062c5bdff4a72..eaba660fb4eba54a773a5851801bbd8de6fdb00b 100644 (file)
@@ -63,7 +63,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_5/System.Data.Services.dll</HintPath>
     </Reference>
-    <Reference Include="System.ServiceModel">
+    <Reference Include="System.ServiceModel.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.ServiceModel</HintPath>
+      <HintPath>System.ServiceModel.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="nunit.framework" />
 \r
index 05e53c92b0c136cda0018b0072960bb7d10a9d94..648db864b4104ad7e366b8047e50a5963091ac42 100644 (file)
@@ -44,7 +44,7 @@ LIB_MCS_FLAGS += \
 endif
 endif
 
-TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) -nowarn:618,169,612,219,168
+TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) -r:System.Core.dll -nowarn:618,169,612,219,168
 
 TEST_MONO_PATH = .
 
index 1b3a8554db5092caaf374ce18eeee7a94c769082..47ad50c325b52a90c41bb5f7ad49cc3b0ce1e36e 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index cdf8880e8f78c20fdc90b3af49f78e12f2bda763..351cb53b3f8229ce670c12640fa75a6849b38459 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f2ca340880a8aaf7a5f4bb4d2f90ac546a06c225..210f50455e0c908e0ab068260ac0a58e486e0bc6 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b752e60bcea8411d9298e28d5020e10375444897..b3c18ee347b9e0403af4aef5c6a1761a2f7b6ffd 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Transactions.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index f1ff70e57efc10cbf1f03806f68b209d528d02eb..d923127c3a0ee1155cbb0b596668f1a30e4e8974 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Transactions.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index b4625ab641a8ef4638070174a7eefeec00d34daf..0f4922cf0bb79838e7ddae73ec6ff962eb4d5e5f 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Transactions.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 965810599ccbff1dc9aad2ad54ea69780fa51574..c82a032cf3026a96961daf21db52346ae23e72e7 100644 (file)
@@ -509,7 +509,10 @@ namespace System.Data {
                        
                        bool hasErrors = false;
                        foreach (DataRow row in Table.Rows) {
-                               // first we check if all values in _childColumns place are nulls.
+                               if (row.RowState == DataRowState.Deleted)
+                                       continue;
+                               
+                               // we check if all values in _childColumns place are nulls.
                                // if yes we return.
                                if (row.IsNullColumns(_childColumns))
                                        continue;
index b425842c71aa44fd32b332f6d7160a5a8bf74a03..5e633630f99e92e0eb185a02332653ec28f62f97 100644 (file)
@@ -526,5 +526,29 @@ namespace MonoTests.System.Data
                        t1.Rows [0][0]=20;
                        Assert("#1", (int)t2.Rows [0][0] == 20);
                }
+
+               [Test]
+               // https://bugzilla.novell.com/show_bug.cgi?id=650402
+               public void ForeignKey_650402 ()
+               {
+                       DataSet data = new DataSet ();
+                       DataTable parent = new DataTable ("parent");
+                       DataColumn pk = parent.Columns.Add ("PK");
+                       DataTable child = new DataTable ("child");
+                       DataColumn fk = child.Columns.Add ("FK");
+                       
+                       data.Tables.Add (parent);
+                       data.Tables.Add (child);
+                       data.Relations.Add (pk, fk);
+                       
+                       parent.Rows.Add ("value");
+                       child.Rows.Add ("value");
+                       data.AcceptChanges ();
+                       child.Rows[0].Delete ();
+                       parent.Rows[0][0] = "value2";
+                       
+                       data.EnforceConstraints = false;
+                       data.EnforceConstraints = true;
+               }
        }
 }
index f71c5bb86f4d9e35dd7ab7ea029c1235fdc98b8c..509e35492e76952158fb276cd6a62c8e3807ad4d 100644 (file)
@@ -4,25 +4,20 @@ include ../../build/rules.make
 
 LIBRARY = System.Design.dll
 
-ifneq (1, $(FRAMEWORK_VERSION_MAJOR))
-
 LIBRARY_USE_INTERMEDIATE_FILE = yes
 
-
 DRAWING_DESIGN_DEP := System.Drawing.Design.dll
 DRAWING_DESIGN_DEP_FILE := $(wildcard ../lib/$(PROFILE)/$(DRAWING_DESIGN_DEP))
 CYCLIC_DEPS := $(DRAWING_DESIGN_DEP)
 CYCLIC_DEP_FILES := $(DRAWING_DESIGN_DEP_FILE)
-endif
 
 
 LIB_MCS_FLAGS = -r:$(corlib) -r:System.dll -r:System.Xml.dll -r:System.Web.dll \
        -r:System.Windows.Forms.dll -r:System.Drawing.dll \
-       -r:Accessibility.dll -r:System.Data.dll
-
-ifneq (1, $(FRAMEWORK_VERSION_MAJOR))
-LIB_MCS_FLAGS += -r:System.Configuration.dll
-endif
+       -r:Accessibility.dll -r:System.Data.dll \
+       -r:System.Configuration.dll
+       
+TEST_MCS_FLAGS = /r:System.dll
 
 ifneq ($(CYCLIC_DEPS:%=../lib/$(PROFILE)/%), $(CYCLIC_DEP_FILES))
 NO_SIGN_ASSEMBLY = yes
index 665925ba2e76f6fdb36b8526c45f47d79640daec..44cfbf02dd87d54a5c7690c58c77b4ec42638e7b 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5b191e0392ade8c89b5b8055f95a1ad602444896..1752acaa54422da35404248d3bc2dc9564a264f4 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 944c699af6a29313e94fd069b18dca11223c0819..b6562cd6d524658471ebca946c9df29946f3a9ea 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2dbf803ff4e56fd74f607a2f48973043650ee8ff..5bc053c8e957ee871e57bd7756258c2e39b4e087 100644 (file)
@@ -56,7 +56,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_2_0/System.Design.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index d9482c0f2cb0e65eab05ca6c3f96add9c45493b7..c2bea1c4f14c7fb4599dcf673d54569700d4f6db 100644 (file)
@@ -56,7 +56,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_0/System.Design.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 44c8b877e939557b1f3be6634b7d1576c87ded9e..2d88968e4cf41de2f9365afaeb4b1b439acdc915 100644 (file)
@@ -56,7 +56,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_5/System.Design.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 453798d6c6d0bd97c6640b0f40dd673e068323c7..c84c7dafcd8c94d802a683df4404adb79fea2af2 100644 (file)
@@ -77,7 +77,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2b1c5395133121c2dbc4af644b83e920894a0ae1..dfaf411f0af42754f46f45fa8ce9bb970a7de4f4 100644 (file)
@@ -77,7 +77,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index de48a9085834e1e0498a8349af5fe1ded4e8312e..0bff0c310a6c12e6e5147c47ddb24158cc97350b 100644 (file)
@@ -77,7 +77,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3334db3d676072001a9b226a4565104fe3389794..8d1d89dbd295e4610ba9ebe72a5fafd1863589a8 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8417ea25bc23667a0609238bae3ef943513698ac..b038471690670d9b8217dc2efd7d3ba086f213f7 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e25bb12be403a50334db1af515d7d448803d9735..44172eb2f3f33e5de50b612e0179d45bbd284350 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 982001b2f2d0400e8ff946389deb323cb360b1df..da2554f467123973d1f4324a659c38e27ca7fd04 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8d4d3467726212046c61822dd296feba07d2981f..8c955052ef9dfe1c7b0ebdeefa899cb59bb6de50 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1b47e821c491cf241a312676170e13caee539e7e..2cbd573221cae90eb84a26b314c87ac950bb7276 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 6c4b986fb64efc593bb1d3981ecca42dbc86dc56..94b29d6b5fd4369c0390f686c26e4ee439230ab6 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e172f9ef1a9ff017cfd508952ae412dce878b33a..9cf035b9ffe1dd67d62e750bc7dc5f116fc690b3 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 422fd5f6462f193b140c3e3c5587983aabf90d25..ef1b170d7d72428f70ef72b2f800efc48eb84df8 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e5afaccca2d3e0069ba5bf16123141eda06e666b..6ab728a15e96cc831a458e948f8f819f59a37cb9 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 55a7328d6ea1ff43fcde9b12751a868b2f41f21b..dba2a9df82ab0581e1a550f18bd9cedda1b5fc97 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 65522bdcf6dde104e101fb3a8a3d192aad1a3f92..8c1c9936a84814e4058e713843746a325c48a9e0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 535e2b243e08226762f1ae637e2d71769491e457..2638031963a4bf6716332ac6a5ab92a0e3e896b5 100644 (file)
@@ -45,8 +45,11 @@ namespace System.Drawing
        [ComVisible (false)] 
 #endif 
        [Serializable]  
+#if !MONOTOUCH
        [Editor ("System.Drawing.Design.IconEditor, " + Consts.AssemblySystem_Drawing_Design, typeof (System.Drawing.Design.UITypeEditor))]
+#endif
        [TypeConverter(typeof(IconConverter))]
+
        public sealed class Icon : MarshalByRefObject, ISerializable, ICloneable, IDisposable
        {
                [StructLayout(LayoutKind.Sequential)]
@@ -105,9 +108,12 @@ namespace System.Drawing
                {
                }
 
+#if !MONOTOUCH
                private Icon (IntPtr handle)
                {
                        this.handle = handle;
+                       bitmap = Bitmap.FromHicon (handle);
+                       iconSize = new Size (bitmap.Width, bitmap.Height);
                        if (GDIPlus.RunningOnUnix ()) {
                                bitmap = Bitmap.FromHicon (handle);
                                iconSize = new Size (bitmap.Width, bitmap.Height);
@@ -124,6 +130,7 @@ namespace System.Drawing
                        }
                        undisposable = true;
                }
+#endif
 
                public Icon (Icon original, int width, int height)
                        : this (original, new Size (width, height))
@@ -287,12 +294,14 @@ namespace System.Drawing
                        // SystemIcons requires this
                        if (undisposable)
                                return;
-
+                       
                        if (!disposed) {
+#if !MONOTOUCH
                                if (GDIPlus.RunningOnWindows () && (handle != IntPtr.Zero)) {
                                        GDIPlus.DestroyIcon (handle);
                                        handle = IntPtr.Zero;
                                }
+#endif
                                if (bitmap != null) {
                                        bitmap.Dispose ();
                                        bitmap = null;
@@ -306,7 +315,8 @@ namespace System.Drawing
                {
                        return new Icon (this, Size);
                }
-
+               
+#if !MONOTOUCH
                [SecurityPermission (SecurityAction.LinkDemand, UnmanagedCode = true)]
                public static Icon FromHandle (IntPtr handle)
                {
@@ -315,7 +325,7 @@ namespace System.Drawing
 
                        return new Icon (handle);
                }
-
+#endif
                private void SaveIconImage (BinaryWriter writer, IconImage ii)
                {
                        BitmapInfoHeader bih = ii.iconHeader;
@@ -472,7 +482,7 @@ namespace System.Drawing
                        // save every icons available
                        Save (outputStream, -1, -1);
                }
-
+#if !MONOTOUCH
                internal Bitmap BuildBitmapOnWin32 ()
                {
                        Bitmap bmp;
@@ -580,13 +590,14 @@ namespace System.Drawing
                        //     Image16 for the differences
                        return new Bitmap (GetInternalBitmap ());
                }
-
+#endif
                public override string ToString ()
                {
                        //is this correct, this is what returned by .Net
                        return "<Icon>";                        
                }
-
+               
+#if !MONOTOUCH
                [Browsable (false)]
                public IntPtr Handle {
                        get {
@@ -606,7 +617,7 @@ namespace System.Drawing
                                return handle;
                        }
                }
-
+#endif
                [Browsable (false)]
                public int Height {
                        get {
index 8f0ba78e1956cdf6784f81ad8d3875b3b5dae207..8f9baacf2be8d679ab06113b276d2c3e775c4340 100644 (file)
@@ -8,7 +8,11 @@ using System.Reflection;
 using System.Xml.Serialization;\r
 using System.Collections;\r
 using System.Security.Cryptography;\r
+using System.Runtime.InteropServices;\r
+using System.Drawing.Imaging;\r
 \r
+#if MONOTOUCH\r
+#else\r
 #if TARGET_JVM\r
 using awt = java.awt;\r
 using javax.imageio;\r
@@ -17,8 +21,7 @@ using java.security;
 using java.awt.image;\r
 #else\r
 using System.Windows.Forms;\r
-using System.Drawing.Imaging;\r
-using System.Runtime.InteropServices;\r
+#endif\r
 #endif\r
 \r
 using NUnit.Framework;\r
@@ -333,7 +336,7 @@ namespace DrawingTestHelper
                private static void AssertAlmostEqual (float expected, float actual, float tolerance, string message)\r
                {\r
                        float error = System.Math.Abs ((expected - actual) / (expected + actual + float.Epsilon));\r
-                       Assert.IsTrue (error < tolerance, message);\r
+                       Assert.That (error < tolerance, Is.True, message);\r
                }\r
 \r
                public static void AssertAlmostEqual (PointF expected, PointF actual)\r
@@ -407,12 +410,12 @@ namespace DrawingTestHelper
 \r
                public void AssertCompare () {\r
                        CheckCounter ();\r
-                       Assert.IsTrue ((CompareToExpectedInternal () * 100) < DEFAULT_IMAGE_TOLERANCE);\r
+                       Assert.That ((CompareToExpectedInternal () * 100) < DEFAULT_IMAGE_TOLERANCE, Is.True);\r
                }\r
 \r
                public void AssertCompare (double tolerance) {\r
                        CheckCounter ();\r
-                       Assert.IsTrue ((CompareToExpectedInternal () * 100) < tolerance);\r
+                       Assert.That ((CompareToExpectedInternal () * 100) < tolerance, Is.True);\r
                }\r
                \r
                public double CompareToExpected () {\r
@@ -606,17 +609,33 @@ namespace DrawingTestHelper
                }\r
 \r
                protected override Bitmap GetReferenceImage(string testName) {\r
+                       string fileName = testName.Replace(":", "_") + ".png";\r
                        try{\r
-                               string fileName = testName.Replace(":", "_") + ".png";\r
-                               _bitmap.Save( fileName );\r
-                               GC.Collect();\r
+                               if (true){\r
+                                       return new Bitmap("/Developer/MonoTouch/Source/mono/mcs/class/System.Drawing/Test/DrawingTest/Test/PNGs/" + fileName);\r
+                               } else {\r
+                                       _bitmap.Save( fileName );\r
+                                       GC.Collect();\r
+                               }\r
                                return null;\r
                        }\r
                        catch(System.Exception e) {\r
-                               throw new System.Exception("Error creating .Net reference image");\r
+                               throw new System.Exception("Error loading .Net reference image: " + fileName);\r
                        }\r
                }\r
-\r
+               \r
+#if MONOTOUCH\r
+               private class NetForm:MonoTouch.UIKit.UIViewController,IMyForm {\r
+                       Image image;\r
+                       public NetForm(string title, Image anImage):base() {\r
+                               //base.Text = title;            \r
+                               image = anImage;\r
+                       }\r
+                       void IMyForm.Show () {\r
+                               this.image.Save("test.net.png");\r
+                       }\r
+               }\r
+#else\r
                private class NetForm:Form,IMyForm {\r
                        Image image;\r
                        public NetForm(string title, Image anImage):base() {\r
@@ -632,6 +651,7 @@ namespace DrawingTestHelper
                                this.image.Save("test.net.png");\r
                        }\r
                }\r
+#endif\r
                protected override IMyForm CreateForm(string title) {\r
                        return new NetForm (title, _bitmap);\r
                }\r
index dd4551c6398d8f75d7b094359090c3d64a1fa29e..cb922750f3f38819a36258d8c91389a3aa746745 100644 (file)
@@ -1,5 +1,5 @@
 MCS=mcs
-sources=AssemblyInfo.cs DrawingTest.cs
+sources=AssemblyInfo.cs DrawingTest.cs PDComparer.cs
 EXOCORTEX=Exocortex.DSP.dll
 
 DrawingTestHelper.dll: $(sources) $(EXOCORTEX)
index 689a1298f49234de799d95ef1efe6f660ee5eabf..a7754b38f2aa93e3aa585671bb3bc8fc96e35d38 100644 (file)
@@ -25,9 +25,13 @@ namespace DrawingTestHelper
                public PDComparer()\r
                {\r
                }\r
-\r
+               \r
+               static int j;\r
                public static double Compare(Bitmap b1, Bitmap b2)\r
                {\r
+                       b1.Save ("/tmp/fo" + j + ".jpg");\r
+                       b2.Save ("/tmp/so" + j + ".jpg");\r
+                       j++;\r
                        Point [] shapePoints = GetPointFromImage(b1);\r
                        double [] pointsDistance = new double[ shapePoints.Length ];\r
 \r
index 32d79a13b29da01bafa3c2ca7b839b6fe1feccb8..d1796375f2ced175dfce572d05d6ff4598230097 100644 (file)
@@ -38,6 +38,9 @@ using System.Drawing.Text;
 using System.Drawing.Imaging;\r
 using DrawingTestHelper;\r
 using System.IO;\r
+#if !MONOTOUCH\r
+using  NUnit.Framework.SyntaxHelpers;\r
+#endif\r
 \r
 namespace Test.Sys.Drawing.GraphicsFixtures {\r
        #region GraphicsFixtureProps\r
@@ -63,14 +66,14 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                [Test]\r
                public void ClipTest_1() {\r
                        Region r = new Region();\r
-                       Assert.IsTrue(r.Equals(t.Graphics.Clip, t.Graphics));\r
+                       Assert.That(r.Equals(t.Graphics.Clip, t.Graphics), Is.True);\r
                }\r
 \r
                [Test]\r
                public void ClipTest_2() {\r
                        Region r = new Region(new Rectangle(10, 10, 60, 60));\r
                        t.Graphics.Clip = r;\r
-                       Assert.IsTrue(r.Equals(t.Graphics.Clip, t.Graphics));\r
+                       Assert.That(r.Equals(t.Graphics.Clip, t.Graphics), Is.True);\r
 \r
                        Pen redPen   = new Pen(Color.Red, 3);\r
                        Pen greenPen = new Pen(Color.Green, 3);\r
@@ -94,7 +97,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw lines between original points to screen.\r
                        t.Graphics.DrawLines(redPen, curvePoints);\r
                        t.Show ();\r
-                       Assert.IsTrue(t.PDCompare(TOLERANCE));\r
+                       Assert.That(t.PDCompare(TOLERANCE), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -144,18 +147,18 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                [Test]\r
                public void ClipBoundsTest() {\r
                        Region r = new Region();\r
-                       Assert.IsTrue(t.Graphics.ClipBounds.Equals(r.GetBounds(t.Graphics)));\r
+                       Assert.That(t.Graphics.ClipBounds.Equals(r.GetBounds(t.Graphics)), Is.True);\r
 \r
                        RectangleF rf = new RectangleF(10, 10, 60, 60);\r
                        r = new Region(rf);\r
                        t.Graphics.Clip = r;\r
-                       Assert.IsTrue(rf.Equals(t.Graphics.ClipBounds));\r
+                       Assert.That(rf.Equals(t.Graphics.ClipBounds), Is.True);\r
                }\r
 \r
                [Test]\r
                public void CompositingModeTest() {\r
                        //TODO: seems to draw equal images\r
-                       Assert.AreEqual(CompositingMode.SourceOver, t.Graphics.CompositingMode);\r
+                       Assert.That (CompositingMode.SourceOver, Is.EqualTo (t.Graphics.CompositingMode));\r
 \r
                        Bitmap b = new Bitmap(100, 100);\r
                        Graphics g = Graphics.FromImage(b);\r
@@ -174,7 +177,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.DrawImage(b, 300, 300);\r
 \r
                        t.Show ();\r
-                       Assert.IsTrue(t.PDCompare(TOLERANCE));\r
+                       Assert.That(t.PDCompare(TOLERANCE), Is.True);\r
                }\r
 \r
                [Test] //TBD\r
@@ -183,91 +186,91 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
 \r
                [Test]\r
                public void DpiXTest() {\r
-                       Assert.IsTrue(t.Graphics.DpiX == 96f);\r
+                       Assert.That(t.Graphics.DpiX == 96f, Is.True);\r
                }\r
 \r
                [Test]\r
                public void DpiYTest() {\r
-                       Assert.IsTrue(t.Graphics.DpiY == 96f);\r
+                       Assert.That(t.Graphics.DpiY == 96f, Is.True);\r
                }\r
 \r
                [Test] //TBD\r
                public void InterpolationModeTest() {\r
-                       Assert.AreEqual(InterpolationMode.Bilinear, t.Graphics.InterpolationMode);\r
+                       Assert.That (InterpolationMode.Bilinear, Is.EqualTo (t.Graphics.InterpolationMode));\r
                }\r
 \r
                [Test]\r
                public void IsClipEmtpyTest() {\r
-                       Assert.IsFalse(t.Graphics.IsClipEmpty);\r
+                       Assert.That (t.Graphics.IsClipEmpty, Is.False);\r
 \r
                        try {\r
                                t.Graphics.Clip = null;\r
                                Assert.Fail("The ArgumentNullException was not thrown");\r
                        }\r
                        catch(Exception e) {\r
-                               Assert.AreEqual(e.GetType(), typeof(ArgumentNullException));\r
+                               Assert.That (e.GetType(), Is.EqualTo (typeof(ArgumentNullException)));\r
                        }\r
 \r
                        Region r = new Region(new Rectangle(10, 10, 0, 0));\r
                        t.Graphics.Clip = r;\r
 \r
-                       Assert.IsTrue( t.Graphics.IsClipEmpty);\r
+                       Assert.That( t.Graphics.IsClipEmpty, Is.True);\r
                }\r
 \r
                [Test]\r
                public void IsVisibleClipEmtpyTest() {\r
-                       Assert.IsFalse(t.Graphics.IsVisibleClipEmpty, "default t.Graphics.IsVisibleClipEmpty");\r
+                       Assert.That (t.Graphics.IsVisibleClipEmpty, Is.False, "default t.Graphics.IsVisibleClipEmpty");\r
 \r
                        Region r = new Region(new Rectangle(512, 512, 100, 100));\r
                        t.Graphics.Clip = r;\r
-                       Assert.IsFalse(t.Graphics.IsClipEmpty);\r
-                       Assert.IsTrue(t.Graphics.IsVisibleClipEmpty);\r
+                       Assert.That (t.Graphics.IsClipEmpty, Is.False);\r
+                       Assert.That(t.Graphics.IsVisibleClipEmpty, Is.True);\r
                }\r
 \r
                [Test]\r
                public void PageScaleTest() {\r
-                       Assert.AreEqual(1f, t.Graphics.PageScale);\r
+                       Assert.That (1f, Is.EqualTo (t.Graphics.PageScale));\r
                }\r
 \r
                [Test]\r
                public void PageUnitTest() {\r
-                       Assert.AreEqual(GraphicsUnit.Display, t.Graphics.PageUnit);\r
+                       Assert.That (GraphicsUnit.Display, Is.EqualTo (t.Graphics.PageUnit));\r
                }\r
 \r
                [Test]\r
                public void PixelOffsetModeTest() {\r
-                       Assert.AreEqual(PixelOffsetMode.Default, t.Graphics.PixelOffsetMode);\r
+                       Assert.That (PixelOffsetMode.Default, Is.EqualTo (t.Graphics.PixelOffsetMode));\r
                }\r
 \r
                [Test]\r
                [Category("NotWorking")]\r
                public void RenderingOriginTest() {\r
-                       Assert.AreEqual(new Point(0,0), t.Graphics.RenderingOrigin);\r
+                       Assert.That (new Point(0,0), Is.EqualTo (t.Graphics.RenderingOrigin));\r
                }\r
 \r
                [Test]\r
                public void SmoothingModeTest() {\r
-                       Assert.AreEqual(SmoothingMode.None, t.Graphics.SmoothingMode);\r
+                       Assert.That (SmoothingMode.None, Is.EqualTo (t.Graphics.SmoothingMode));\r
                }\r
 \r
                [Test]\r
                public void TextContrastTest() {\r
-                       Assert.AreEqual(4, t.Graphics.TextContrast);\r
+                       Assert.That (4, Is.EqualTo (t.Graphics.TextContrast));\r
                }\r
 \r
                [Test]\r
                public void TextRenderingHintTest() {\r
-                       Assert.AreEqual(TextRenderingHint.SystemDefault, t.Graphics.TextRenderingHint);\r
+                       Assert.That (TextRenderingHint.SystemDefault, Is.EqualTo (t.Graphics.TextRenderingHint));\r
                }\r
 \r
                [Test]\r
                public void TransformTest() {\r
-                       Assert.AreEqual(new Matrix(), t.Graphics.Transform);\r
+                       Assert.That (new Matrix(), Is.EqualTo (t.Graphics.Transform));\r
                }\r
 \r
                [Test]\r
                public void VisibleClipBoundsTest() {\r
-                       Assert.AreEqual(new RectangleF(0, 0, 512, 512), t.Graphics.VisibleClipBounds);\r
+                       Assert.That (new RectangleF(0, 0, 512, 512), Is.EqualTo (t.Graphics.VisibleClipBounds));\r
                }\r
        }\r
 \r
@@ -317,35 +320,35 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.DrawImage(bmp, new Point[]{new Point(170,10), new Point(250,0), new Point(100,100)}, src, GraphicsUnit.Pixel );\r
                        t.Graphics.DrawImage(bmp, new PointF[]{new PointF(70,10), new PointF(150,0), new PointF(10,100)}, srcF, GraphicsUnit.Pixel );\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImage2() {\r
                        t.Graphics.DrawImage(bmp, dst, src, GraphicsUnit.Pixel);\r
                        t.Graphics.DrawImage(bmp, dstF, srcF, GraphicsUnit.Pixel);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImage3() {\r
                        t.Graphics.DrawImage(bmp, 10.0F, 10.0F, srcF, GraphicsUnit.Pixel);\r
                        t.Graphics.DrawImage(bmp, 70.0F, 150.0F, 250.0F, 150.0F);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImage4() {\r
                        t.Graphics.DrawImage(bmp, dst);\r
                        t.Graphics.DrawImage(bmp, dstF);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImage5() {\r
                        t.Graphics.SetClip( new Rectangle(70, 0, 20, 200));\r
                        t.Graphics.DrawImage(bmp, new Point[]{new Point(50,50), new Point(250,30), new Point(100,150)}, src, GraphicsUnit.Pixel );\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImage6() {\r
@@ -353,28 +356,28 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.SetClip( new Rectangle(70, 0, 20, 200));\r
                        t.Graphics.DrawImage(bmp, new Point[]{new Point(50,50), new Point(250,30), new Point(100,150)}, src, GraphicsUnit.Pixel );\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImage7() {\r
                        t.Graphics.DrawImage(bmp, 170, 70, src, GraphicsUnit.Pixel);\r
                        t.Graphics.DrawImage(bmp, 70, 350, 350, 150);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImage8() {\r
                        t.Graphics.DrawImage(bmp, new Point[]{new Point(170,10), new Point(250,10), new Point(100,100)} );\r
                        t.Graphics.DrawImage(bmp, new PointF[]{new PointF(170,100), new PointF(250,100), new PointF(100,190)} );\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImage9() {\r
                        t.Graphics.DrawImage(bmp, 0, 0);\r
                        t.Graphics.DrawImage(bmp, 200, 200);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImagePageUnit() {\r
@@ -387,7 +390,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
 \r
                        t.Graphics.DrawImage(bmp2, p, new Rectangle(100, 100, 100, 100), GraphicsUnit.Pixel);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImagePageUnit_2() {\r
@@ -401,7 +404,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
 \r
                        t.Graphics.DrawImage(bmp2, p, new Rectangle(100, 100, 100, 100), GraphicsUnit.Pixel);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImagePageUnit_3() {\r
@@ -409,7 +412,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.ScaleTransform(0.3f, 0.3f);\r
                        t.Graphics.DrawImage(bmp2, new Rectangle(100, 100, 100, 100));\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImagePageUnit_4() {\r
@@ -417,7 +420,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.ScaleTransform(0.5f, 0.5f);\r
                        t.Graphics.DrawImage(bmp, 50, 50);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImagePageUnitClip() {\r
@@ -432,7 +435,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.SetClip( new Rectangle(120, 120, 50, 100) );\r
                        t.Graphics.DrawImage(bmp2, p, new Rectangle(100, 100, 100, 100), GraphicsUnit.Pixel);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
 #if TARGET_JVM\r
@@ -441,14 +444,14 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                public void DrawImageWithResolution() {\r
                        t.Graphics.DrawImage(bmp2, 0, 0);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImageInContainer1() {\r
                        t.Graphics.BeginContainer(new Rectangle(10, 10, 50, 50), new Rectangle(70, 70, 100, 100), GraphicsUnit.Pixel);\r
                        t.Graphics.DrawImage(bmp, 0, 0);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
 #if TARGET_JVM\r
@@ -458,7 +461,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.BeginContainer(new Rectangle(10, 10, 50, 50), new Rectangle(70, 70, 100, 100), GraphicsUnit.Pixel);\r
                        t.Graphics.DrawImage(bmp2, 0, 0);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImageInContainer3() {\r
@@ -467,7 +470,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.ScaleTransform(0.5f, 0.5f);\r
                        t.Graphics.DrawImage(bmp2, 0, 0);\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
                [Test]\r
                public void DrawImageInContainer4() {\r
@@ -482,7 +485,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.DrawImage(bmp2, p, new Rectangle(100, 100, 100, 100), GraphicsUnit.Pixel);\r
                        t.Graphics.EndContainer( c );\r
                        t.Show();\r
-                       Assert.IsTrue(t.Compare());\r
+                       Assert.That(t.Compare(), Is.True);\r
                }\r
        }\r
        #endregion\r
@@ -509,7 +512,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                [Test]\r
                public void FillModeAlternate() {\r
                        GraphicsPath p = new GraphicsPath();\r
-                       Assert.AreEqual(FillMode.Alternate, p.FillMode);\r
+                       Assert.That (FillMode.Alternate, Is.EqualTo (p.FillMode));\r
                }\r
                [Test]\r
                public void FillModeAlternate_1() {\r
@@ -528,7 +531,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        path.FillMode = FillMode.Alternate;\r
                        t.Graphics.FillPath( Brushes.Blue, path );\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
                [Test]\r
                public void FillModeAlternate_2() {\r
@@ -541,7 +544,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        path.FillMode = FillMode.Alternate;\r
                        t.Graphics.FillPath( Brushes.Blue, path );\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
                [Test]\r
                public void FillModeAlternate_3() {\r
@@ -559,7 +562,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        path.FillMode = FillMode.Alternate;\r
                        t.Graphics.FillPath( Brushes.Blue, path );\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
                [Test]\r
                public void FillModeWinding_1() {\r
@@ -578,7 +581,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        path.FillMode = FillMode.Winding;\r
                        t.Graphics.FillPath( Brushes.Blue, path );\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
                [Test]\r
                public void FillModeWinding_2() {\r
@@ -591,7 +594,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        path.FillMode = FillMode.Winding;\r
                        t.Graphics.FillPath( Brushes.Blue, path );\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
                [Test]\r
                public void FillModeWinding_3() {\r
@@ -609,7 +612,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        path.FillMode = FillMode.Winding;\r
                        t.Graphics.FillPath( Brushes.Blue, path );\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
        }\r
@@ -671,7 +674,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill untransformed rectangle with green.\r
                        t.Graphics.FillRectangle(new SolidBrush(Color.Green), 0.0F, 0.0F, 200.0F, 200.0F);\r
                        t.Show ();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -691,14 +694,14 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
 \r
                        SizeF size = graphics.MeasureString (drawString, drawFont, new PointF (0, 0), StringFormat.GenericTypographic);\r
 \r
-                       Assert.IsTrue (Math.Abs (size.Width - netWidth1) / netWidth1 < 0.01);\r
-                       Assert.IsTrue (Math.Abs (size.Height - netHeight1) / netHeight1 < 0.01);\r
+                       Assert.That (Math.Abs (size.Width - netWidth1) / netWidth1 < 0.01, Is.True);\r
+                       Assert.That (Math.Abs (size.Height - netHeight1) / netHeight1 < 0.01, Is.True);\r
 \r
                        graphics.PageUnit = GraphicsUnit.Pixel;\r
                        size = graphics.MeasureString (drawString, drawFont, new PointF (0, 0), StringFormat.GenericTypographic);\r
 \r
-                       Assert.IsTrue (Math.Abs (size.Width - netWidth2) / netWidth2 < 0.01);\r
-                       Assert.IsTrue (Math.Abs (size.Height - netHeight2) / netHeight2 < 0.01);\r
+                       Assert.That (Math.Abs (size.Width - netWidth2) / netWidth2 < 0.01, Is.True);\r
+                       Assert.That (Math.Abs (size.Height - netHeight2) / netHeight2 < 0.01, Is.True);\r
                }\r
 \r
                [Test]\r
@@ -727,16 +730,16 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.FillRectangle( Brushes.Yellow, new Rectangle(150, 80, 10, 10) );\r
 \r
                        t.Show ();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
                [Test]\r
                public virtual void ClearTest() {\r
                        // Clear screen with teal background.\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        t.Graphics.Clear(Color.Teal);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -754,37 +757,37 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw arc to screen.\r
                        t.Graphics.DrawArc(blackPen, (int)x, (int)y, (int)width, (int)height, (int)startAngle, (int)sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
                        startAngle =  10.0F;\r
                        sweepAngle = 120.0F;\r
                        t.Graphics.DrawArc(blackPen, new Rectangle((int)x, (int)y, (int)width, (int)height), startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
                        startAngle =  10.0F;\r
                        sweepAngle = 190.0F;\r
                        t.Graphics.DrawArc(blackPen, x, y, width, height, startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
                        startAngle =  10.0F;\r
                        sweepAngle = 300.0F;\r
                        t.Graphics.DrawArc(blackPen, new RectangleF(x, y, width, height), startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
                        startAngle =  -179.9F;\r
                        sweepAngle = -359.9F;\r
                        t.Graphics.DrawArc(blackPen, new RectangleF(x, y, width, height), startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
                        startAngle =  -10.0F;\r
                        sweepAngle = -300.0F;\r
                        t.Graphics.DrawArc(blackPen, new RectangleF(x, y, width, height), startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -806,21 +809,21 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                                controlX2, controlY2,\r
                                endX, endY);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
                        t.Graphics.DrawBezier(blackPen, new PointF( startX, startY),\r
                                new PointF(controlX1, controlY1),\r
                                new PointF(controlX2, controlY2),\r
                                new PointF(endX, endY));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
                        t.Graphics.DrawBezier(blackPen, new Point((int)startX, (int)startY),\r
                                new Point((int)controlX1, (int)controlY1),\r
                                new Point((int)controlX2, (int)controlY2),\r
                                new Point((int)endX, (int)endY));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -842,7 +845,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw arc to screen.\r
                        t.Graphics.DrawBeziers(blackPen, bezierPoints);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        PointF startF = new PointF(100.0F, 100.0F);\r
@@ -859,7 +862,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw arc to screen.\r
                        t.Graphics.DrawBeziers(blackPen, bezierPointsF);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -892,14 +895,14 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw closed curve to screen.\r
                        t.Graphics.DrawClosedCurve(greenPen, curvePoints, tension, aFillMode);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        aFillMode = FillMode.Winding;\r
                        // Draw closed curve to screen.\r
                        t.Graphics.DrawClosedCurve(greenPen, curvePoints, tension, aFillMode);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -933,17 +936,17 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw curve to screen.\r
                        t.Graphics.DrawCurve(greenPen, curvePoints, offset, numSegments, tension);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawCurve(greenPen, curvePoints, tension);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawCurve(greenPen, curvePoints);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -977,22 +980,22 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw curve to screen.\r
                        t.Graphics.DrawCurve(greenPen, curvePoints, offset, numSegments, tension);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawCurve(greenPen, curvePoints, offset, numSegments);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawCurve(greenPen, curvePoints, tension);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawCurve(greenPen, curvePoints);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1007,12 +1010,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw ellipse to screen.\r
                        t.Graphics.DrawEllipse(blackPen, x, y, width, height);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawEllipse(blackPen, new Rectangle(x, y, width, height));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1027,12 +1030,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw ellipse to screen.\r
                        t.Graphics.DrawEllipse(blackPen, x, y, width, height);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawEllipse(blackPen, new RectangleF(x, y, width, height));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                static string getInFile (string file) {\r
@@ -1059,11 +1062,11 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw icon to screen.\r
                        t.Graphics.DrawIcon(newIcon, x, y);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
 \r
                        t.Graphics.DrawIcon(newIcon, new Rectangle(200, 300, 125, 345));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1076,7 +1079,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw icon to screen.\r
                        t.Graphics.DrawIconUnstretched(newIcon, rect);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 #if INTPTR_SUPPORTED\r
                // Define DrawImageAbort callback method.\r
@@ -1142,22 +1145,22 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw image to screen.\r
                        t.Graphics.DrawImageUnscaled(newImage, x, y, 100, 125);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawImageUnscaled(newImage, new Rectangle(x, y, 34, 235));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawImageUnscaled(newImage, x, y);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawImageUnscaled(newImage, new Point(x, y));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1172,12 +1175,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw line to screen.\r
                        t.Graphics.DrawLine(blackPen, x1, y1, x2, y2);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawLine(blackPen, new Point( x1, y1), new Point( x2, y2));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1192,12 +1195,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw line to screen.\r
                        t.Graphics.DrawLine(blackPen, x1, y1, x2, y2);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawLine(blackPen, new PointF( x1, y1), new PointF( x2, y2));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1214,7 +1217,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        //Draw lines to screen.\r
                        t.Graphics.DrawLines(pen, points);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1231,7 +1234,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        //Draw lines to screen.\r
                        t.Graphics.DrawLines(pen, points);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1244,7 +1247,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw graphics path to screen.\r
                        t.Graphics.DrawPath(blackPen, graphPath);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1262,12 +1265,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw pie to screen.\r
                        t.Graphics.DrawPie(blackPen, x, y, width, height, startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawPie(blackPen, new RectangleF( x, y, width, height), startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1285,12 +1288,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw pie to screen.\r
                        t.Graphics.DrawPie(blackPen, x, y, width, height, startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawPie(blackPen, new Rectangle( x, y, width, height), startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1317,7 +1320,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw polygon to screen.\r
                        t.Graphics.DrawPolygon(blackPen, curvePoints);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare()); // .NET's lines of polygon is more wide\r
+                       Assert.That(t.PDCompare()); // .NET's lines of polygon is more wi, Is.Truede\r
                }\r
 \r
                [Test]\r
@@ -1344,7 +1347,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw polygon to screen.\r
                        t.Graphics.DrawPolygon(blackPen, curvePoints);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1359,17 +1362,17 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rectangle to screen.\r
                        t.Graphics.DrawRectangle(blackPen, x, y, width, height);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawRectangle(blackPen, (int)x, (int)y, (int)width, (int)height);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.DrawRectangle(blackPen, new Rectangle( (int)x, (int)y, (int)width, (int)height));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1385,7 +1388,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rectangles to screen.\r
                        t.Graphics.DrawRectangles(blackPen, rects);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1401,7 +1404,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rectangles to screen.\r
                        t.Graphics.DrawRectangles(blackPen, rects);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test] //TBD: add more combinations\r
@@ -1421,21 +1424,21 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw string to screen.\r
                        t.Graphics.DrawString(drawString, drawFont, drawBrush, x, y, drawFormat);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare()); // in .net the font is shmoothed\r
+                       Assert.That(t.PDCompare()); // in .net the font is shmooth, Is.Trueed\r
                        SetUp();\r
 \r
                        drawFormat.FormatFlags = StringFormatFlags.NoClip;\r
                        // Draw string to screen.\r
                        t.Graphics.DrawString(drawString, drawFont, drawBrush, x, y, drawFormat);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        drawFormat.FormatFlags = StringFormatFlags.FitBlackBox;\r
                        // Draw string to screen.\r
                        t.Graphics.DrawString(drawString, drawFont, drawBrush, x, y, drawFormat);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1452,7 +1455,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill untransformed rectangle with green.\r
                        t.Graphics.FillRectangle(new SolidBrush(Color.Green), 0, 0, 200, 200);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test] //TBD\r
@@ -1468,7 +1471,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill large rectangle to show clipping region.\r
                        t.Graphics.FillRectangle(new SolidBrush(Color.Blue), 0, 0, 300, 300);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1488,18 +1491,18 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill curve on screen.\r
                        t.Graphics.FillClosedCurve(redBrush, points);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
 \r
                        SetUp();\r
                        t.Graphics.FillClosedCurve(redBrush, points, newFillMode);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
 \r
                        SetUp();\r
                        newFillMode = FillMode.Alternate;\r
                        t.Graphics.FillClosedCurve(redBrush, points, newFillMode, tension);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1519,18 +1522,18 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill curve on screen.\r
                        t.Graphics.FillClosedCurve(redBrush, points);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillClosedCurve(redBrush, points, newFillMode);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        newFillMode = FillMode.Alternate;\r
                        t.Graphics.FillClosedCurve(redBrush, points, newFillMode, tension);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1545,12 +1548,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill ellipse on screen.\r
                        t.Graphics.FillEllipse(redBrush, x, y, width, height);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillEllipse(redBrush, new Rectangle( x, y, width, height));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1565,12 +1568,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill ellipse on screen.\r
                        t.Graphics.FillEllipse(redBrush, x, y, width, height);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillEllipse(redBrush, new RectangleF( x, y, width, height));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1583,7 +1586,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill graphics path to screen.\r
                        t.Graphics.FillPath(redBrush, graphPath);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1601,17 +1604,17 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill pie to screen.\r
                        t.Graphics.FillPie(redBrush, new Rectangle(x, y, width, height), startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillPie(redBrush, x, y, width, height, (int)startAngle, (int)sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillPie(redBrush, (float)x, (float)y, (float)width, (float)height, startAngle, sweepAngle);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1639,17 +1642,17 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill polygon to screen.\r
                        t.Graphics.FillPolygon(blueBrush, curvePoints, FillMode.Winding);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillPolygon(blueBrush, curvePoints, FillMode.Alternate);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillPolygon(blueBrush, curvePoints);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1677,17 +1680,17 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill polygon to screen.\r
                        t.Graphics.FillPolygon(blueBrush, curvePoints, FillMode.Winding);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillPolygon(blueBrush, curvePoints, FillMode.Alternate);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillPolygon(blueBrush, curvePoints);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1702,12 +1705,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill rectangle to screen.\r
                        t.Graphics.FillRectangle(blueBrush, x, y, width, height);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillRectangle(blueBrush, new Rectangle( x, y, width, height));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1722,12 +1725,12 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill rectangle to screen.\r
                        t.Graphics.FillRectangle(blueBrush, x, y, width, height);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                        SetUp();\r
 \r
                        t.Graphics.FillRectangle(blueBrush, new RectangleF( x, y, width, height));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1743,7 +1746,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill rectangles to screen.\r
                        t.Graphics.FillRectangles(blueBrush, rects);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1759,7 +1762,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill rectangles to screen.\r
                        t.Graphics.FillRectangles(blueBrush, rects);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1773,7 +1776,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill region to screen.\r
                        t.Graphics.FillRegion(blueBrush, fillRegion);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1803,7 +1806,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Show();\r
                        t.Graphics.DrawRectangle(new Pen(Color.Red), intersectRect);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1830,7 +1833,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                                t.Show();\r
                        }\r
 \r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1880,7 +1883,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                                new Pen(Color.Blue, 1),\r
                                Rectangle.Round(measureRect2));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test] //TBD: add more overloads\r
@@ -1926,7 +1929,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                                Brushes.Black,\r
                                new PointF(100, 0));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1944,7 +1947,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rotated, translated ellipse.\r
                        t.Graphics.DrawEllipse(new Pen(Color.Blue, 3), -80, -40, 160, 80);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1962,7 +1965,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rotated, translated ellipse.\r
                        t.Graphics.DrawEllipse(new Pen(Color.Blue, 3), -80, -40, 160, 80);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1980,7 +1983,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rotated, translated ellipse.\r
                        t.Graphics.DrawEllipse(new Pen(Color.Blue, 3), -80, -40, 160, 80);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -1999,7 +2002,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.DrawRectangle(new Pen(Color.Black), clipRect);\r
                        t.Graphics.DrawRectangle(new Pen(Color.Red), Rectangle.Round(intersectRectF));\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -2016,7 +2019,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.Restore(transState);\r
                        t.Graphics.FillRectangle(new SolidBrush(Color.Blue), 0, 0, 100, 100);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -2028,7 +2031,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw translated, rotated ellipse to screen.\r
                        t.Graphics.DrawEllipse(new Pen(Color.Blue, 3), 0, 0, 200, 80);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -2040,7 +2043,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw translated, rotated ellipse to screen.\r
                        t.Graphics.DrawEllipse(new Pen(Color.Blue, 3), 0, 0, 200, 80);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());  // Line width problem\r
+                       Assert.That(t.PDCompare());  // Line width probl, Is.Trueem\r
                }\r
 \r
                [Test]\r
@@ -2052,7 +2055,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rotated, scaled rectangle to screen.\r
                        t.Graphics.DrawRectangle(new Pen(Color.Blue, 3), 50, 0, 100, 40);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare()); // Line width problem\r
+                       Assert.That(t.PDCompare()); // Line width probl, Is.Trueem\r
                }\r
 \r
                [Test]\r
@@ -2064,7 +2067,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rotated, scaled rectangle to screen.\r
                        t.Graphics.DrawRectangle(new Pen(Color.Blue, 3), 50, 0, 100, 40);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test] //TBD: add more combination\r
@@ -2076,7 +2079,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill rectangle to demonstrate clip region.\r
                        t.Graphics.FillRectangle(new SolidBrush(Color.Black), 0, 0, 500, 300);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -2101,7 +2104,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                                points[0],\r
                                points[1]);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -2117,7 +2120,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Fill rectangle to demonstrate translated clip region.\r
                        t.Graphics.FillRectangle(new SolidBrush(Color.Black), 0, 0, 500, 300);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -2129,7 +2132,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rotated, translated ellipse to screen.\r
                        t.Graphics.DrawEllipse(new Pen(Color.Blue, 3), 0, 0, 200, 80);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare()); // Line width problem\r
+                       Assert.That(t.PDCompare()); // Line width probl, Is.Trueem\r
                }\r
 \r
                [Test]\r
@@ -2141,7 +2144,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        // Draw rotated, translated ellipse to screen.\r
                        t.Graphics.DrawEllipse(new Pen(Color.Blue, 3), 0, 0, 200, 80);\r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -2169,7 +2172,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.DrawLine(Pens.Yellow, 10, 70, 70, 10);\r
 \r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -2188,7 +2191,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.DrawLine(Pens.Green, 10, 70, 70, 10);\r
 \r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
                [Test]\r
                public virtual void TransfromPageScaleUnits_3() {\r
@@ -2218,7 +2221,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.DrawLine(Pens.Red, 10, 70, 70, 10);\r
 \r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
        }\r
 \r
@@ -3683,7 +3686,7 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        t.Graphics.FillRectangle( Brushes.SeaGreen, 0, 0, 100, 100 );\r
 \r
                        t.Show();\r
-                       Assert.IsTrue(t.PDCompare());\r
+                       Assert.That(t.PDCompare(), Is.True);\r
                }\r
 \r
                [Test]\r
@@ -3701,16 +3704,16 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
 \r
                        GraphicsContainer c1 = t.Graphics.BeginContainer();\r
 \r
-                       Assert.AreEqual(CompositingQuality.Default, t.Graphics.CompositingQuality);\r
-                       Assert.AreEqual(CompositingMode.SourceOver, t.Graphics.CompositingMode);\r
-                       Assert.AreEqual(InterpolationMode.Bilinear, t.Graphics.InterpolationMode);\r
-                       Assert.AreEqual(1.0F, t.Graphics.PageScale);\r
-                       Assert.AreEqual(GraphicsUnit.Display, t.Graphics.PageUnit);\r
-                       Assert.AreEqual(PixelOffsetMode.Default, t.Graphics.PixelOffsetMode);\r
-                       Assert.AreEqual(SmoothingMode.None, t.Graphics.SmoothingMode);\r
-                       Assert.AreEqual(true, t.Graphics.Transform.IsIdentity);\r
-                       Assert.AreEqual(4.0f, t.Graphics.TextContrast);\r
-                       Assert.AreEqual(TextRenderingHint.SystemDefault, t.Graphics.TextRenderingHint);\r
+                       Assert.That (CompositingQuality.Default, Is.EqualTo (t.Graphics.CompositingQuality));\r
+                       Assert.That (CompositingMode.SourceOver, Is.EqualTo (t.Graphics.CompositingMode));\r
+                       Assert.That (InterpolationMode.Bilinear, Is.EqualTo (t.Graphics.InterpolationMode));\r
+                       Assert.That (1.0F, Is.EqualTo (t.Graphics.PageScale));\r
+                       Assert.That (GraphicsUnit.Display, Is.EqualTo (t.Graphics.PageUnit));\r
+                       Assert.That (PixelOffsetMode.Default, Is.EqualTo (t.Graphics.PixelOffsetMode));\r
+                       Assert.That (SmoothingMode.None, Is.EqualTo (t.Graphics.SmoothingMode));\r
+                       Assert.That (true, Is.EqualTo (t.Graphics.Transform.IsIdentity));\r
+                       Assert.That (4.0f, Is.EqualTo (t.Graphics.TextContrast));\r
+                       Assert.That (TextRenderingHint.SystemDefault, Is.EqualTo (t.Graphics.TextRenderingHint));\r
 \r
                        t.Graphics.EndContainer(c1);\r
                }\r
@@ -3731,16 +3734,16 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
 \r
                        t.Graphics.Restore(s);\r
 \r
-                       Assert.AreEqual(CompositingQuality.Default, t.Graphics.CompositingQuality);\r
-                       Assert.AreEqual(CompositingMode.SourceOver, t.Graphics.CompositingMode);\r
-                       Assert.AreEqual(InterpolationMode.Bilinear, t.Graphics.InterpolationMode);\r
-                       Assert.AreEqual(1.0F, t.Graphics.PageScale);\r
-                       Assert.AreEqual(GraphicsUnit.Display, t.Graphics.PageUnit);\r
-                       Assert.AreEqual(PixelOffsetMode.Default, t.Graphics.PixelOffsetMode);\r
-                       Assert.AreEqual(SmoothingMode.None, t.Graphics.SmoothingMode);\r
-                       Assert.AreEqual(true, t.Graphics.Transform.IsIdentity);\r
-                       Assert.AreEqual(4.0f, t.Graphics.TextContrast);\r
-                       Assert.AreEqual(TextRenderingHint.SystemDefault, t.Graphics.TextRenderingHint);\r
+                       Assert.That (CompositingQuality.Default, Is.EqualTo (t.Graphics.CompositingQuality));\r
+                       Assert.That (CompositingMode.SourceOver, Is.EqualTo (t.Graphics.CompositingMode));\r
+                       Assert.That (InterpolationMode.Bilinear, Is.EqualTo (t.Graphics.InterpolationMode));\r
+                       Assert.That (1.0F, Is.EqualTo (t.Graphics.PageScale));\r
+                       Assert.That (GraphicsUnit.Display, Is.EqualTo (t.Graphics.PageUnit));\r
+                       Assert.That (PixelOffsetMode.Default, Is.EqualTo (t.Graphics.PixelOffsetMode));\r
+                       Assert.That (SmoothingMode.None, Is.EqualTo (t.Graphics.SmoothingMode));\r
+                       Assert.That (true, Is.EqualTo (t.Graphics.Transform.IsIdentity));\r
+                       Assert.That (4.0f, Is.EqualTo (t.Graphics.TextContrast));\r
+                       Assert.That (TextRenderingHint.SystemDefault, Is.EqualTo (t.Graphics.TextRenderingHint));\r
                }\r
 \r
                [Test]\r
@@ -3755,19 +3758,19 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        GraphicsContainer c3 = t.Graphics.BeginContainer();\r
 \r
                        t.Graphics.EndContainer(c2);\r
-                       Assert.AreEqual(3, t.Graphics.PageScale);\r
+                       Assert.That (3, Is.EqualTo (t.Graphics.PageScale));\r
 \r
                        t.Graphics.PageScale = 5;\r
                        GraphicsState c5 = t.Graphics.Save();\r
 \r
                        t.Graphics.EndContainer(c3);\r
-                       Assert.AreEqual(5, t.Graphics.PageScale);\r
+                       Assert.That (5, Is.EqualTo (t.Graphics.PageScale));\r
 \r
                        t.Graphics.Restore(c5);\r
-                       Assert.AreEqual(5, t.Graphics.PageScale);\r
+                       Assert.That (5, Is.EqualTo (t.Graphics.PageScale));\r
 \r
                        t.Graphics.EndContainer(c1);\r
-                       Assert.AreEqual(2, t.Graphics.PageScale);\r
+                       Assert.That (2, Is.EqualTo (t.Graphics.PageScale));\r
                }\r
                [Test]\r
                public void SaveRestoreGraphicsProps_4() {\r
@@ -3778,10 +3781,10 @@ namespace Test.Sys.Drawing.GraphicsFixtures {
                        GraphicsState c2 = t.Graphics.Save();\r
 \r
                        t.Graphics.EndContainer(c1);\r
-                       Assert.AreEqual(2, t.Graphics.PageScale);\r
+                       Assert.That (2, Is.EqualTo (t.Graphics.PageScale));\r
 \r
                        t.Graphics.Restore(c2);\r
-                       Assert.AreEqual(2, t.Graphics.PageScale);\r
+                       Assert.That (2, Is.EqualTo (t.Graphics.PageScale));\r
                }\r
        }\r
        #endregion\r
index 77f753da1530901c529fcaf39b279bfa18fcf9a0..37983a6aa39035b35f1d5f1325b25ef4c431614b 100644 (file)
@@ -15,3 +15,6 @@ $(DRAWING_TEST_HELPER):
 
 run-test: Test.dll
        MONO_PATH="../../../../../class/lib/net_1_1::$(MONO_PATH)" /home/andrews/monobuild/mono/runtime/mono-wrapper --debug ../../../../../class/lib/net_1_1/nunit-console.exe Test.dll $(NUNIT_FLAGS)
+
+clean:
+       rm *dll
\ No newline at end of file
index ee450fbb92102104e24dd754dcb24c270be7adda..793b8c86594b2da66ebec9ae4e43f8ce859ea7a5 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,169</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_0</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>\r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,169</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;CODEPLEX_40</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,169</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;CODEPLEX_40</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c23f8f14a2e4914403634efbf513c1c0c7ac2b55..cd0b58bc9dc88c32664fb4138da5646fd476c530 100644 (file)
@@ -7,7 +7,7 @@
     <SchemaVersion>2.0</SchemaVersion>\r
     <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
     <OutputType>Library</OutputType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,169</NoWarn>\r
     <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
     <NoStdLib>true</NoStdLib>\r
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>\r
@@ -20,7 +20,7 @@
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
     <DebugSymbols>true</DebugSymbols>\r
     <DebugType>full</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,169</NoWarn>\r
     <Optimize>false</Optimize>\r
     <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;CODEPLEX_40</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
@@ -29,7 +29,7 @@
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
     <DebugType>pdbonly</DebugType>\r
-    <NoWarn>1699</NoWarn>\r
+    <NoWarn>1699,414,169</NoWarn>\r
     <Optimize>true</Optimize>\r
     <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;CODEPLEX_40</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3dc41dfe83940b6a1e143463ac51d08a57e1b169..ef377cf829ddfd493cd4d41e03b4e81ac57be4bc 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c69b11b04a9fa4d5efa3f9ac6295426219fd9af5..905e160bd356e3f772ee6f1307d580125f8e1cf5 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index db45e55912b7c3a4c70c380c5b92f08751e08801..1a45fc72868592cb05d32f2a6716ffab66ab851a 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 54c52333968de6f03bbcff99dc80fb7e1c84548f..f346b7b693f0116419cef0bce69c5f5e5fb6e4a3 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7a6c37dad4bbf7793cde30c5d72b8a608df76b57..17b4f74a8630ef5299a43aa866ec0bd6f67c71bf 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 038be25fcb08010de466cde64d580b59df485870..24f7ab5f2dab10d2970d39e243373f45e18a41e6 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f485d8cf3cee4a3fee6040e3854975e0b572e45c..094731b2d28ca39e623b5f7657dd37feb9e84698 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index bd97da38266b33d7dabc398eb68f643957d97351..1e82d669ba95aa6dc9ac8971ce272e67812275c4 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 15ab27eb70de80f5b8e73ea02cf5ef4336770a3c..33b3c9ab21dfd94ad1a225f6c8f5562fc3455f31 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4406eb7b35e16be34ee2c0c391f1b4918e214d13..1fd447ccbee1f5f89a0b3d9dc63d1dff688dd997 100644 (file)
@@ -87,7 +87,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 21b9b79378f135b29c0a54fa8c6c362316d845ac..4fa36334d12248a559a2e231d3a10c871023a532 100644 (file)
@@ -87,7 +87,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b2aefb8744ab7a90198636fbdf9f921770969611..448fc6003da14f5766dfb0759fd329f273ed94ec 100644 (file)
@@ -87,7 +87,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b8c49cd952bd53eac4e7967132dddbb9b7d678c5..a550ea9caa15684f460fbd452d9e502c8f3ab66e 100755 (executable)
@@ -37,22 +37,6 @@ using System.Runtime.InteropServices;
 
 // General Information about the System.Json assembly
 
-[assembly: AssemblyTitle ("System.Json.dll")]
-[assembly: AssemblyDescription ("System.Json.dll")]
 [assembly: AssemblyDefaultAlias ("System.Json.dll")]
 
-[assembly: AssemblyCompany (Consts.MonoCompany)]
-[assembly: AssemblyProduct (Consts.MonoProduct)]
-[assembly: AssemblyCopyright (Consts.MonoCopyright)]
-[assembly: AssemblyVersion (Consts.FxVersion)]
-[assembly: SatelliteContractVersion (Consts.FxVersion)]
 [assembly: AssemblyInformationalVersion (Consts.FxFileVersion)]
-[assembly: AssemblyFileVersion (Consts.FxFileVersion)]
-
-[assembly: NeutralResourcesLanguage ("en-US")]
-[assembly: AssemblyDelaySign (true)]
-[assembly: AssemblyKeyFile ("../winfx.pub")]
-
-[assembly: ComVisible (false)]
-
-[assembly: SecurityCritical]
index 906b0bf48f178ac8324ae1a357d887ee160d6007..f83e3ed6a98e4a0f91039d278c8d9721538c4290 100644 (file)
@@ -2,24 +2,24 @@ thisdir = class/System.Json
 SUBDIRS = 
 include ../../build/rules.make
 
+System.Json.Properties.Resources.resources: ../../../external/aspnetwebstack/src/System.Json/Properties/Resources.resx
+       $(RESGEN) "$<" "$@"
+
 LIBRARY = System.Json.dll
-LIB_MCS_FLAGS = \
+LIB_MCS_FLAGS = /d:ASPNETMVC -keyfile:../winfx.pub -delaysign \
                /r:System.dll \
                /r:System.Xml.dll \
                /r:System.Core.dll \
-               /r:System.ServiceModel.Web.dll
-
-TEST_MCS_FLAGS = $(LIB_MCS_FLAGS)
-
-EXTRA_DISTFILES =
+               /r:System.Runtime.Serialization.dll \
+               /r:System.ServiceModel.Web.dll \
+               /resource:System.Json.Properties.Resources.resources
 
-VALID_PROFILE := $(filter 2 4, $(FRAMEWORK_VERSION_MAJOR))
-
-ifndef VALID_PROFILE
-LIBRARY_NAME = dummy-System.Json.dll
-NO_INSTALL = yes
-NO_SIGN_ASSEMBLY = yes
-NO_TEST = yes
+ifeq (4, $(FRAMEWORK_VERSION_MAJOR))
+LIB_MCS_FLAGS += /r:Microsoft.CSharp.dll
 endif
 
+TEST_MCS_FLAGS = $(LIB_MCS_FLAGS)
+
 include ../../build/library.make
+
+$(the_lib): System.Json.Properties.Resources.resources
index 2611515e0030c02a8c5190e8e086831a607b8086..c688fb4b3065201c5f139365a3359ab0c8283569 100644 (file)
@@ -22,7 +22,7 @@
     <DebugType>full</DebugType>\r
     <NoWarn>1699</NoWarn>\r
     <Optimize>false</Optimize>\r
-    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;ASPNETMVC</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <WarningLevel>4</WarningLevel>\r
     <AdditionalLibPaths>./../../class/lib/net_4_0</AdditionalLibPaths>\r
@@ -31,7 +31,7 @@
     <DebugType>pdbonly</DebugType>\r
     <NoWarn>1699</NoWarn>\r
     <Optimize>true</Optimize>\r
-    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;ASPNETMVC</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <WarningLevel>4</WarningLevel>\r
     <AdditionalLibPaths>./../../class/lib/net_4_0</AdditionalLibPaths>\r
   <ItemGroup>\r
    <Compile Include="..\..\build\common\Consts.cs" />
    <Compile Include="Assembly\AssemblyInfo.cs" />
-   <Compile Include="System.Json\JsonArray.cs" />
-   <Compile Include="System.Json\JsonObject.cs" />
-   <Compile Include="System.Json\JsonPrimitive.cs" />
-   <Compile Include="System.Json\JsonType.cs" />
-   <Compile Include="System.Json\JsonValue.cs" />
-   <Compile Include="..\System.ServiceModel.Web\System.Runtime.Serialization.Json\JavaScriptReader.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\RS.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\TransparentCommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\Properties\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\Extensions\JsonValueExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JXmlToJsonValueConverter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonArray.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonObject.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonPrimitive.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonType.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValue.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValueChange.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValueChangeEventArgs.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValueDynamicMetaObject.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValueLinqExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\NGenWrapper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\Properties\Resources.Designer.cs" />
 \r
   </ItemGroup>\r
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
@@ -59,7 +71,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Core.dll</HintPath>
     </Reference>
+    <Reference Include="System.Runtime.Serialization.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Runtime.Serialization.dll</HintPath>
+    </Reference>
     <Reference Include="System.ServiceModel.Web.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.ServiceModel.Web.dll</HintPath>
     </Reference>
+    <Reference Include="Microsoft.CSharp.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>Microsoft.CSharp.dll</HintPath>
+    </Reference>
 \r
   </ItemGroup>\r
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
   </ItemGroup>\r
-  \r
+    <ItemGroup>
+    <EmbeddedResource Include="System.Json.Properties.Resources.resources">
+       <LogicalName>System.Json.Properties.Resources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
 </Project>\r
 
index 3a0996f6c174566765d7222563d029e3333de366..faa961dba1849fd6306ac859104d8c9983c78edf 100644 (file)
@@ -22,7 +22,7 @@
     <DebugType>full</DebugType>\r
     <NoWarn>1699</NoWarn>\r
     <Optimize>false</Optimize>\r
-    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETMVC</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <WarningLevel>4</WarningLevel>\r
     <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
@@ -31,7 +31,7 @@
     <DebugType>pdbonly</DebugType>\r
     <NoWarn>1699</NoWarn>\r
     <Optimize>true</Optimize>\r
-    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETMVC</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <WarningLevel>4</WarningLevel>\r
     <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
   <ItemGroup>\r
    <Compile Include="..\..\build\common\Consts.cs" />
    <Compile Include="Assembly\AssemblyInfo.cs" />
-   <Compile Include="System.Json\JsonArray.cs" />
-   <Compile Include="System.Json\JsonObject.cs" />
-   <Compile Include="System.Json\JsonPrimitive.cs" />
-   <Compile Include="System.Json\JsonType.cs" />
-   <Compile Include="System.Json\JsonValue.cs" />
-   <Compile Include="..\System.ServiceModel.Web\System.Runtime.Serialization.Json\JavaScriptReader.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\RS.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\TransparentCommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\Properties\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\Extensions\JsonValueExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JXmlToJsonValueConverter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonArray.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonObject.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonPrimitive.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonType.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValue.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValueChange.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValueChangeEventArgs.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValueDynamicMetaObject.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\JsonValueLinqExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\NGenWrapper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Json\Properties\Resources.Designer.cs" />
 \r
   </ItemGroup>\r
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
@@ -59,7 +71,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Core.dll</HintPath>
     </Reference>
+    <Reference Include="System.Runtime.Serialization.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Runtime.Serialization.dll</HintPath>
+    </Reference>
     <Reference Include="System.ServiceModel.Web.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.ServiceModel.Web.dll</HintPath>
     </Reference>
+    <Reference Include="Microsoft.CSharp.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>Microsoft.CSharp.dll</HintPath>
+    </Reference>
 \r
   </ItemGroup>\r
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
   </ItemGroup>\r
-  \r
+    <ItemGroup>
+    <EmbeddedResource Include="System.Json.Properties.Resources.resources">
+       <LogicalName>System.Json.Properties.Resources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
 </Project>\r
 
index 903d919e9767ca36e9f3c67e2c86ca5f366d56c0..79067b89b4cde1531c2f619c59a087fae8dc1b4b 100644 (file)
@@ -22,7 +22,7 @@
     <DebugType>full</DebugType>\r
     <NoWarn>1699</NoWarn>\r
     <Optimize>false</Optimize>\r
-    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;ASPNETMVC</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <WarningLevel>4</WarningLevel>\r
     <AdditionalLibPaths>./../../class/lib/net_4_0</AdditionalLibPaths>\r
@@ -31,7 +31,7 @@
     <DebugType>pdbonly</DebugType>\r
     <NoWarn>1699</NoWarn>\r
     <Optimize>true</Optimize>\r
-    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0</DefineConstants>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;ASPNETMVC</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <WarningLevel>4</WarningLevel>\r
     <AdditionalLibPaths>./../../class/lib/net_4_0</AdditionalLibPaths>\r
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Core.dll</HintPath>
     </Reference>
+    <Reference Include="System.Runtime.Serialization.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Runtime.Serialization.dll</HintPath>
+    </Reference>
     <Reference Include="System.ServiceModel.Web.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.ServiceModel.Web.dll</HintPath>
     </Reference>
+    <Reference Include="Microsoft.CSharp.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>Microsoft.CSharp.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
   </ItemGroup>\r
-  \r
+    <ItemGroup>
+    <EmbeddedResource Include="System.Json.Properties.Resources.resources">
+       <LogicalName>System.Json.Properties.Resources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
 </Project>\r
 
index b35e9b3a428ea66fe7cc81a7bee85621305a41c4..3860e1c58b3b3cd174fe345ec88b212d265ccb97 100644 (file)
@@ -22,7 +22,7 @@
     <DebugType>full</DebugType>\r
     <NoWarn>1699</NoWarn>\r
     <Optimize>false</Optimize>\r
-    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETMVC</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <WarningLevel>4</WarningLevel>\r
     <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
@@ -31,7 +31,7 @@
     <DebugType>pdbonly</DebugType>\r
     <NoWarn>1699</NoWarn>\r
     <Optimize>true</Optimize>\r
-    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETMVC</DefineConstants>\r
     <ErrorReport>prompt</ErrorReport>\r
     <WarningLevel>4</WarningLevel>\r
     <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Core.dll</HintPath>
     </Reference>
+    <Reference Include="System.Runtime.Serialization.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Runtime.Serialization.dll</HintPath>
+    </Reference>
     <Reference Include="System.ServiceModel.Web.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.ServiceModel.Web.dll</HintPath>
     </Reference>
+    <Reference Include="Microsoft.CSharp.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>Microsoft.CSharp.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
   </ItemGroup>\r
-  \r
+    <ItemGroup>
+    <EmbeddedResource Include="System.Json.Properties.Resources.resources">
+       <LogicalName>System.Json.Properties.Resources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
 </Project>\r
 
index 47a9ceed63acc60eeff70671bb6a16c17d727b69..f829400c4a53cfa861c13d0f4da4d4cb898ce065 100644 (file)
@@ -1,8 +1,23 @@
 ../../build/common/Consts.cs
 Assembly/AssemblyInfo.cs
-System.Json/JsonArray.cs
-System.Json/JsonObject.cs
-System.Json/JsonPrimitive.cs
-System.Json/JsonType.cs
-System.Json/JsonValue.cs
-../System.ServiceModel.Web/System.Runtime.Serialization.Json/JavaScriptReader.cs
\ No newline at end of file
+
+../../../external/aspnetwebstack/src/RS.cs
+../../../external/aspnetwebstack/src/CommonAssemblyInfo.cs
+../../../external/aspnetwebstack/src/TransparentCommonAssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/System.Json/Properties/AssemblyInfo.cs
+../../../external/aspnetwebstack/src/System.Json/Extensions/JsonValueExtensions.cs
+../../../external/aspnetwebstack/src/System.Json/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/System.Json/JXmlToJsonValueConverter.cs
+../../../external/aspnetwebstack/src/System.Json/JsonArray.cs
+../../../external/aspnetwebstack/src/System.Json/JsonObject.cs
+../../../external/aspnetwebstack/src/System.Json/JsonPrimitive.cs
+../../../external/aspnetwebstack/src/System.Json/JsonType.cs
+../../../external/aspnetwebstack/src/System.Json/JsonValue.cs
+../../../external/aspnetwebstack/src/System.Json/JsonValueChange.cs
+../../../external/aspnetwebstack/src/System.Json/JsonValueChangeEventArgs.cs
+../../../external/aspnetwebstack/src/System.Json/JsonValueDynamicMetaObject.cs
+../../../external/aspnetwebstack/src/System.Json/JsonValueLinqExtensions.cs
+../../../external/aspnetwebstack/src/System.Json/NGenWrapper.cs
+../../../external/aspnetwebstack/src/System.Json/Properties/Resources.Designer.cs
+
diff --git a/mcs/class/System.Json/System.Json/ChangeLog b/mcs/class/System.Json/System.Json/ChangeLog
deleted file mode 100644 (file)
index 2c56ec1..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-2010-03-10  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonReader.cs : moved to Sys.SM.Web/Sys.R.S.Json.
-
-2010-03-10  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonValue.cs : use Sys.SM.Web.dll's JavaScriptObjectDeserializer
-         for silverlight sdk / moonlight compatibility.
-       * JsonReader.cs : renamed to JavaScriptReader (for disambiguation in
-         Sys.SM.Web.dll). Now it is native-type based and used by the above
-         deserializer.
-
-2010-02-18  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonValue.cs : fix string escaping, it was giving wrong output
-         after \" and \\.
-
-2010-02-18  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonReader.cs : line endings after a value should not result in
-         a parse error.
-       * JsonObject.cs : duplicate object key "SHOULD" not be used, but
-         they are not rejected. So, make it a bit sloppy.
-
-2010-01-27  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonReader.cs : oops, added previous change to wrong position.
-
-2010-01-27  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonReader.cs : It seems it can either return int, long or decimal
-         depending on the value. Users cannot really predict what type of
-         the primitive value can be returned and casts to specific types
-         very likely fail. doh.
-
-2010-01-27  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonReader.cs : use decimal instead of int to parse decimal part
-         of numeric value. It can parse bigger value than int now (like
-         tweet id).
-
-2009-10-05  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonReader.cs : \uXXXX parser was totally wrong, giving wrong #.
-
-2009-09-22  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonValue.cs, JsonReader.cs, JsonPrimitive.cs :
-         Handle "null" values, as string, so far (haven't tried what .NET
-         actually does).
-         Fix array ToString() that missed commas (while Save() worked fine -
-         it has different serialization logic).
-
-2009-01-15  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonReader.cs : consume ',' between items in an array.
-
-2008-09-15  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonObject.cs, JsonValue.cs : SL2b2 updates.
-
-2008-08-28  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonReader.cs : a ReadChar() is missing in number parsing.
-
-2008-06-10  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * JsonArray.cs, JsonObject.cs, JsonPrimitive.cs, JsonReader.cs,
-         JsonType.cs, JsonValue.cs, MergedEnumerator.cs : initial checkin.
-
diff --git a/mcs/class/System.Json/System.Json/JsonArray.cs b/mcs/class/System.Json/System.Json/JsonArray.cs
deleted file mode 100644 (file)
index c630044..0000000
+++ /dev/null
@@ -1,139 +0,0 @@
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Globalization;
-using System.IO;
-using System.Text;
-
-namespace System.Json
-{
-       public class JsonArray : JsonValue, IList<JsonValue>
-       {
-               List<JsonValue> list;
-
-               public JsonArray (params JsonValue [] items)
-               {
-                       list = new List<JsonValue> ();
-                       AddRange (items);
-               }
-
-               public JsonArray (IEnumerable<JsonValue> items)
-               {
-                       if (items == null)
-                               throw new ArgumentNullException ("items");
-
-                       list = new List<JsonValue> (items);
-               }
-
-               public override int Count {
-                       get { return list.Count; }
-               }
-
-               public bool IsReadOnly {
-                       get { return false; }
-               }
-
-               public override sealed JsonValue this [int index] {
-                       get { return list [index]; }
-                       set { list [index] = value; }
-               }
-
-               public override JsonType JsonType {
-                       get { return JsonType.Array; }
-               }
-
-               public void Add (JsonValue item)
-               {
-                       if (item == null)
-                               throw new ArgumentNullException ("item");
-
-                       list.Add (item);
-               }
-
-               public void AddRange (IEnumerable<JsonValue> items)
-               {
-                       if (items == null)
-                               throw new ArgumentNullException ("items");
-
-                       list.AddRange (items);
-               }
-
-               public void AddRange (params JsonValue [] items)
-               {
-                       if (items == null)
-                               return;
-
-                       list.AddRange (items);
-               }
-
-               public void Clear ()
-               {
-                       list.Clear ();
-               }
-
-               public bool Contains (JsonValue item)
-               {
-                       return list.Contains (item);
-               }
-
-               public void CopyTo (JsonValue [] array, int arrayIndex)
-               {
-                       list.CopyTo (array, arrayIndex);
-               }
-
-               public int IndexOf (JsonValue item)
-               {
-                       return list.IndexOf (item);
-               }
-
-               public void Insert (int index, JsonValue item)
-               {
-                       list.Insert (index, item);
-               }
-
-               public bool Remove (JsonValue item)
-               {
-                       return list.Remove (item);
-               }
-
-               public void RemoveAt (int index)
-               {
-                       list.RemoveAt (index);
-               }
-
-               public override void Save (Stream stream)
-               {
-                       if (stream == null)
-                               throw new ArgumentNullException ("stream");
-                       stream.WriteByte ((byte) '[');
-                       for (int i = 0; i < list.Count; i++) {
-                               JsonValue v = list [i];
-                               if (v != null)
-                                       v.Save (stream);
-                               else {
-                                       stream.WriteByte ((byte) 'n');
-                                       stream.WriteByte ((byte) 'u');
-                                       stream.WriteByte ((byte) 'l');
-                                       stream.WriteByte ((byte) 'l');
-                               }
-
-                               if (i < Count - 1) {
-                                       stream.WriteByte ((byte) ',');
-                                       stream.WriteByte ((byte) ' ');
-                               }
-                       }
-                       stream.WriteByte ((byte) ']');
-               }
-
-               IEnumerator<JsonValue> IEnumerable<JsonValue>.GetEnumerator ()
-               {
-                       return list.GetEnumerator ();
-               }
-
-               IEnumerator IEnumerable.GetEnumerator ()
-               {
-                       return list.GetEnumerator ();
-               }
-       }
-}
diff --git a/mcs/class/System.Json/System.Json/JsonObject.cs b/mcs/class/System.Json/System.Json/JsonObject.cs
deleted file mode 100644 (file)
index 33177b1..0000000
+++ /dev/null
@@ -1,160 +0,0 @@
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Globalization;
-using System.IO;
-using System.Text;
-
-using JsonPair = System.Collections.Generic.KeyValuePair<string, System.Json.JsonValue>;
-using JsonPairEnumerable = System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string, System.Json.JsonValue>>;
-
-namespace System.Json
-{
-       public class JsonObject : JsonValue, IDictionary<string, JsonValue>, ICollection<JsonPair>
-       {
-               Dictionary<string, JsonValue> map;
-
-               public JsonObject (params JsonPair [] items)
-               {
-                       map = new Dictionary<string, JsonValue> ();
-
-                       if (items != null)
-                               AddRange (items);
-               }
-
-               public JsonObject (JsonPairEnumerable items)
-               {
-                       if (items == null)
-                               throw new ArgumentNullException ("items");
-
-                       map = new Dictionary<string, JsonValue> ();
-                       AddRange (items);
-               }
-
-               public override int Count {
-                       get { return map.Count; }
-               }
-
-               public IEnumerator<JsonPair> GetEnumerator ()
-               {
-                       return map.GetEnumerator ();
-               }
-
-               IEnumerator IEnumerable.GetEnumerator ()
-               {
-                       return map.GetEnumerator ();
-               }
-
-               public override sealed JsonValue this [string key] {
-                       get { return map [key]; }
-                       set { map [key] = value; }
-               }
-
-               public override JsonType JsonType {
-                       get { return JsonType.Object; }
-               }
-
-               public ICollection<string> Keys {
-                       get { return map.Keys; }
-               }
-
-               public ICollection<JsonValue> Values {
-                       get { return map.Values; }
-               }
-
-               public void Add (string key, JsonValue value)
-               {
-                       if (key == null)
-                               throw new ArgumentNullException ("key");
-
-                       map.Add (key, value);
-               }
-
-               public void Add (JsonPair pair)
-               {
-                       Add (pair.Key, pair.Value);
-               }
-
-               public void AddRange (JsonPairEnumerable items)
-               {
-                       if (items == null)
-                               throw new ArgumentNullException ("items");
-
-                       foreach (var pair in items)
-                               map.Add (pair.Key, pair.Value);
-               }
-
-               public void AddRange (params JsonPair [] items)
-               {
-                       AddRange ((JsonPairEnumerable) items);
-               }
-
-               public void Clear ()
-               {
-                       map.Clear ();
-               }
-
-               bool ICollection<JsonPair>.Contains (JsonPair item)
-               {
-                       return (map as ICollection<JsonPair>).Contains (item);
-               }
-
-               bool ICollection<JsonPair>.Remove (JsonPair item)
-               {
-                       return (map as ICollection<JsonPair>).Remove (item);
-               }
-
-               public override bool ContainsKey (string key)
-               {
-                       if (key == null)
-                               throw new ArgumentNullException ("key");
-
-                       return map.ContainsKey (key);
-               }
-
-               public void CopyTo (JsonPair [] array, int arrayIndex)
-               {
-                       (map as ICollection<JsonPair>).CopyTo (array, arrayIndex);
-               }
-
-               public bool Remove (string key)
-               {
-                       if (key == null)
-                               throw new ArgumentNullException ("key");
-
-                       return map.Remove (key);
-               }
-
-               bool ICollection<JsonPair>.IsReadOnly {
-                       get { return false; }
-               }
-
-               public override void Save (Stream stream)
-               {
-                       if (stream == null)
-                               throw new ArgumentNullException ("stream");
-                       stream.WriteByte ((byte) '{');
-                       foreach (JsonPair pair in map) {
-                               stream.WriteByte ((byte) '"');
-                               byte [] bytes = Encoding.UTF8.GetBytes (EscapeString (pair.Key));
-                               stream.Write (bytes, 0, bytes.Length);
-                               stream.WriteByte ((byte) '"');
-                               stream.WriteByte ((byte) ',');
-                               stream.WriteByte ((byte) ' ');
-                               if (pair.Value == null) {
-                                       stream.WriteByte ((byte) 'n');
-                                       stream.WriteByte ((byte) 'u');
-                                       stream.WriteByte ((byte) 'l');
-                                       stream.WriteByte ((byte) 'l');
-                               } else
-                                       pair.Value.Save (stream);
-                       }
-                       stream.WriteByte ((byte) '}');
-               }
-
-               public bool TryGetValue (string key, out JsonValue value)
-               {
-                       return map.TryGetValue (key, out value);
-               }
-       }
-}
diff --git a/mcs/class/System.Json/System.Json/JsonPrimitive.cs b/mcs/class/System.Json/System.Json/JsonPrimitive.cs
deleted file mode 100644 (file)
index 6451878..0000000
+++ /dev/null
@@ -1,172 +0,0 @@
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Globalization;
-using System.IO;
-using System.Text;
-
-namespace System.Json
-{
-       public class JsonPrimitive : JsonValue
-       {
-               object value;
-
-               public JsonPrimitive (bool value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (byte value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (char value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (decimal value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (double value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (float value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (int value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (long value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (sbyte value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (short value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (string value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (DateTime value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (uint value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (ulong value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (ushort value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (DateTimeOffset value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (Guid value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (TimeSpan value)
-               {
-                       this.value = value;
-               }
-
-               public JsonPrimitive (Uri value)
-               {
-                       this.value = value;
-               }
-
-               internal object Value {
-                       get { return value; }
-               }
-
-               public override JsonType JsonType {
-                       get {
-                               // FIXME: what should we do for null? Handle it as null so far.
-                               if (value == null)
-                                       return JsonType.String;
-
-                               switch (Type.GetTypeCode (value.GetType ())) {
-                               case TypeCode.Boolean:
-                                       return JsonType.Boolean;
-                               case TypeCode.Char:
-                               case TypeCode.String:
-                               case TypeCode.DateTime:
-                               case TypeCode.Object: // DateTimeOffset || Guid || TimeSpan || Uri
-                                       return JsonType.String;
-                               default:
-                                       return JsonType.Number;
-                               }
-                       }
-               }
-
-               static readonly byte [] true_bytes = Encoding.UTF8.GetBytes ("true");
-               static readonly byte [] false_bytes = Encoding.UTF8.GetBytes ("false");
-
-               public override void Save (Stream stream)
-               {
-                       switch (JsonType) {
-                       case JsonType.Boolean:
-                               if ((bool) value)
-                                       stream.Write (true_bytes, 0, 4);
-                               else
-                                       stream.Write (false_bytes, 0, 5);
-                               break;
-                       case JsonType.String:
-                               stream.WriteByte ((byte) '\"');
-                               byte [] bytes = Encoding.UTF8.GetBytes (EscapeString (value.ToString ()));
-                               stream.Write (bytes, 0, bytes.Length);
-                               stream.WriteByte ((byte) '\"');
-                               break;
-                       default:
-                               bytes = Encoding.UTF8.GetBytes (GetFormattedString ());
-                               stream.Write (bytes, 0, bytes.Length);
-                               break;
-                       }
-               }
-
-               internal string GetFormattedString ()
-               {
-                       switch (JsonType) {
-                       case JsonType.String:
-                               if (value is string || value == null)
-                                       return (string) value;
-                               throw new NotImplementedException ("GetFormattedString from value type " + value.GetType ());
-                       case JsonType.Number:
-                               return ((IFormattable) value).ToString ("G", NumberFormatInfo.InvariantInfo);
-                       default:
-                               throw new InvalidOperationException ();
-                       }
-               }
-       }
-}
diff --git a/mcs/class/System.Json/System.Json/JsonType.cs b/mcs/class/System.Json/System.Json/JsonType.cs
deleted file mode 100644 (file)
index c04f574..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-namespace System.Json
-{
-       public enum JsonType
-       {
-               String,
-               Number,
-               Object,
-               Array,
-               Boolean,
-       }
-}
diff --git a/mcs/class/System.Json/System.Json/JsonValue.cs b/mcs/class/System.Json/System.Json/JsonValue.cs
deleted file mode 100644 (file)
index 1d16b88..0000000
+++ /dev/null
@@ -1,460 +0,0 @@
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.IO;
-using System.Linq;
-using System.Runtime.Serialization.Json;
-using System.Text;
-
-using JsonPair = System.Collections.Generic.KeyValuePair<string, System.Json.JsonValue>;
-
-
-namespace System.Json
-{
-       public abstract class JsonValue : IEnumerable
-       {
-               public static JsonValue Load (Stream stream)
-               {
-                       if (stream == null)
-                               throw new ArgumentNullException ("stream");
-                       return Load (new StreamReader (stream, true));
-               }
-
-               public static JsonValue Load (TextReader textReader)
-               {
-                       if (textReader == null)
-                               throw new ArgumentNullException ("textReader");
-
-                       var ret = new JavaScriptReader (textReader, true).Read ();
-
-                       return ToJsonValue (ret);
-               }
-
-               static IEnumerable<KeyValuePair<string,JsonValue>> ToJsonPairEnumerable (IEnumerable<KeyValuePair<string,object>> kvpc)
-               {
-                       foreach (var kvp in kvpc)
-                               yield return new KeyValuePair<string,JsonValue> (kvp.Key, ToJsonValue (kvp.Value));
-               }
-
-               static IEnumerable<JsonValue> ToJsonValueEnumerable (IEnumerable<object> arr)
-               {
-                       foreach (var obj in arr)
-                               yield return ToJsonValue (obj);
-               }
-
-               static JsonValue ToJsonValue (object ret)
-               {
-                       if (ret == null)
-                               return null;
-                       var kvpc = ret as IEnumerable<KeyValuePair<string,object>>;
-                       if (kvpc != null)
-                               return new JsonObject (ToJsonPairEnumerable (kvpc));
-                       var arr = ret as IEnumerable<object>;
-                       if (arr != null)
-                               return new JsonArray (ToJsonValueEnumerable (arr));
-
-                       if (ret is bool)
-                               return new JsonPrimitive ((bool) ret);
-                       if (ret is byte)
-                               return new JsonPrimitive ((byte) ret);
-                       if (ret is char)
-                               return new JsonPrimitive ((char) ret);
-                       if (ret is decimal)
-                               return new JsonPrimitive ((decimal) ret);
-                       if (ret is double)
-                               return new JsonPrimitive ((double) ret);
-                       if (ret is float)
-                               return new JsonPrimitive ((float) ret);
-                       if (ret is int)
-                               return new JsonPrimitive ((int) ret);
-                       if (ret is long)
-                               return new JsonPrimitive ((long) ret);
-                       if (ret is sbyte)
-                               return new JsonPrimitive ((sbyte) ret);
-                       if (ret is short)
-                               return new JsonPrimitive ((short) ret);
-                       if (ret is string)
-                               return new JsonPrimitive ((string) ret);
-                       if (ret is uint)
-                               return new JsonPrimitive ((uint) ret);
-                       if (ret is ulong)
-                               return new JsonPrimitive ((ulong) ret);
-                       if (ret is ushort)
-                               return new JsonPrimitive ((ushort) ret);
-                       if (ret is DateTime)
-                               return new JsonPrimitive ((DateTime) ret);
-                       if (ret is DateTimeOffset)
-                               return new JsonPrimitive ((DateTimeOffset) ret);
-                       if (ret is Guid)
-                               return new JsonPrimitive ((Guid) ret);
-                       if (ret is TimeSpan)
-                               return new JsonPrimitive ((TimeSpan) ret);
-                       if (ret is Uri)
-                               return new JsonPrimitive ((Uri) ret);
-                       throw new NotSupportedException (String.Format ("Unexpected parser return type: {0}", ret.GetType ()));
-               }
-
-               public static JsonValue Parse (string jsonString)
-               {
-                       if (jsonString == null)
-                               throw new ArgumentNullException ("jsonString");
-                       return Load (new StringReader (jsonString));
-               }
-
-               public virtual int Count {
-                       get { throw new InvalidOperationException (); }
-               }
-
-               public abstract JsonType JsonType { get; }
-
-               public virtual JsonValue this [int index] {
-                       get { throw new InvalidOperationException (); }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public virtual JsonValue this [string key] {
-                       get { throw new InvalidOperationException (); }
-                       set { throw new InvalidOperationException (); }
-               }
-
-               public virtual bool ContainsKey (string key)
-               {
-                       throw new InvalidOperationException ();
-               }
-
-               public virtual void Save (Stream stream)
-               {
-                       if (stream == null)
-                               throw new ArgumentNullException ("stream");
-                       Save (new StreamWriter (stream));
-               }
-
-               public virtual void Save (TextWriter textWriter)
-               {
-                       if (textWriter == null)
-                               throw new ArgumentNullException ("textWriter");
-                       SaveInternal (textWriter);
-               }
-               
-               void SaveInternal (TextWriter w)
-               {
-                       switch (JsonType) {
-                       case JsonType.Object:
-                               w.Write ('{');
-                               bool following = false;
-                               foreach (JsonPair pair in ((JsonObject) this)) {
-                                       if (following)
-                                               w.Write (", ");
-                                       w.Write ('\"');
-                                       w.Write (EscapeString (pair.Key));
-                                       w.Write ("\": ");
-                                       if (pair.Value == null)
-                                               w.Write ("null");
-                                       else
-                                               pair.Value.SaveInternal (w);
-                                       following = true;
-                               }
-                               w.Write ('}');
-                               break;
-                       case JsonType.Array:
-                               w.Write ('[');
-                               following = false;
-                               foreach (JsonValue v in ((JsonArray) this)) {
-                                       if (following)
-                                               w.Write (", ");
-                                       if (v != null) 
-                                               v.SaveInternal (w);
-                                       else
-                                               w.Write ("null");
-                                       following = true;
-                               }
-                               w.Write (']');
-                               break;
-                       case JsonType.Boolean:
-                               w.Write ((bool) this ? "true" : "false");
-                               break;
-                       case JsonType.String:
-                               w.Write ('"');
-                               w.Write (EscapeString (((JsonPrimitive) this).GetFormattedString ()));
-                               w.Write ('"');
-                               break;
-                       default:
-                               w.Write (((JsonPrimitive) this).GetFormattedString ());
-                               break;
-                       }
-               }
-
-               public override string ToString ()
-               {
-                       StringWriter sw = new StringWriter ();
-                       Save (sw);
-                       return sw.ToString ();
-               }
-
-               IEnumerator IEnumerable.GetEnumerator ()
-               {
-                       throw new InvalidOperationException ();
-               }
-
-               internal string EscapeString (string src)
-               {
-                       if (src == null)
-                               return null;
-
-                       for (int i = 0; i < src.Length; i++)
-                               if (src [i] == '"' || src [i] == '\\') {
-                                       var sb = new StringBuilder ();
-                                       if (i > 0)
-                                               sb.Append (src, 0, i);
-                                       return DoEscapeString (sb, src, i);
-                               }
-                       return src;
-               }
-
-               string DoEscapeString (StringBuilder sb, string src, int cur)
-               {
-                       int start = cur;
-                       for (int i = cur; i < src.Length; i++)
-                               if (src [i] == '"' || src [i] == '\\') {
-                                       sb.Append (src, start, i - start);
-                                       sb.Append ('\\');
-                                       sb.Append (src [i++]);
-                                       start = i;
-                               }
-                       sb.Append (src, start, src.Length - start);
-                       return sb.ToString ();
-               }
-
-               // CLI -> JsonValue
-
-               public static implicit operator JsonValue (bool value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (byte value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (char value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (decimal value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (double value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (float value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (int value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (long value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (sbyte value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (short value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (string value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (uint value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (ulong value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (ushort value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (DateTime value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (DateTimeOffset value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (Guid value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (TimeSpan value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               public static implicit operator JsonValue (Uri value)
-               {
-                       return new JsonPrimitive (value);
-               }
-
-               // JsonValue -> CLI
-
-               public static implicit operator bool (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToBoolean (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator byte (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToByte (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator char (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToChar (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator decimal (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToDecimal (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator double (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToDouble (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator float (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToSingle (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator int (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToInt32 (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator long (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToInt64 (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator sbyte (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToSByte (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator short (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToInt16 (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator string (JsonValue value)
-               {
-                       if (value == null)
-                               return null;
-                       return (string) ((JsonPrimitive) value).Value;
-               }
-
-               public static implicit operator uint (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToUInt16 (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator ulong (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToUInt64(((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator ushort (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return Convert.ToUInt16 (((JsonPrimitive) value).Value);
-               }
-
-               public static implicit operator DateTime (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return (DateTime) ((JsonPrimitive) value).Value;
-               }
-
-               public static implicit operator DateTimeOffset (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return (DateTimeOffset) ((JsonPrimitive) value).Value;
-               }
-
-               public static implicit operator TimeSpan (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return (TimeSpan) ((JsonPrimitive) value).Value;
-               }
-
-               public static implicit operator Guid (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return (Guid) ((JsonPrimitive) value).Value;
-               }
-
-               public static implicit operator Uri (JsonValue value)
-               {
-                       if (value == null)
-                               throw new ArgumentNullException ("value");
-                       return (Uri) ((JsonPrimitive) value).Value;
-               }
-       }
-}
index 2459c1fc3ad0f27478d902ffaccc6f2ec3f0d371..c302a5150733befb88c44d70e01f5b2b16d2d876 100644 (file)
@@ -17,15 +17,6 @@ namespace MonoTests.System
        [TestFixture]
        public class JsonValueTests {
                // Tests that a trailing comma is allowed in dictionary definitions
-               [Test]
-               public void LoadWithTrailingComma ()
-               {
-                       var j = JsonValue.Load (new StringReader ("{ \"a\": \"b\",}"));
-                       Assert.AreEqual (1, j.Count, "itemcount");
-                       Assert.AreEqual (JsonType.String, j ["a"].JsonType, "type");
-                       Assert.AreEqual ("b", (string) j ["a"], "value");
-               }
-
                // Test that we correctly serialize JsonArray with null elements.
                [Test]
                public void ToStringOnJsonArrayWithNulls () {
@@ -33,7 +24,7 @@ namespace MonoTests.System
                        Assert.AreEqual (4, j.Count, "itemcount");
                        Assert.AreEqual (JsonType.Array, j.JsonType, "type");
                        var str = j.ToString ();
-                       Assert.AreEqual (str, "[1, 2, 3, null]");
+                       Assert.AreEqual ("[1,2,3,null]", str);
                }
        }
 }
index 91040abc6b7be6ebb784498f8ed1fa0cf93286e0..8374e26ba0f54a4e724c708bc97cb593010ad7c8 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1bce9dc5d07b39641da57adb71421b2dad94ada1..e1354ae05fa6a2b5ac699f78952369c0de1e392b 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 840b0755f72e24e7deae3bd1985d85f2fc5f6b42..14c10b28dceb665ea597df0f483b6e8d2323cc09 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3e456a89c5951329f83f245718545c48779906a8..3b98a8eeea2b13e7c03a9e33585c70548569b322 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 83c0aaeef1909f20d62a4bc9e7da1e757a53fea3..af7263405b46e8b2504fffadccbb25b1234a092f 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 01d72d0f6b388d1cc0205823784d353bb4cc4be5..a1ea2d9d51ba944eb26179a2251286be7b956dcd 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0b53b9372c3fb9d8bddbe7a01ef6753b576d6fcb..b9277086c6fd8f0008bcbfe4fef7abc288382e98 100644 (file)
@@ -61,7 +61,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index dc895f97f51fc1666fd614531b31924eda2b69ab..08f2fb92f11c916a4d232799e50a539c456353f2 100644 (file)
@@ -61,7 +61,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 6e813cd84eecc41a18eb85bd47af12eddcba2cab..a7aa23697a31dc1a0f5c74b7809d12619834d5a2 100644 (file)
@@ -61,7 +61,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
diff --git a/mcs/class/System.Net.Http.Formatting/Extensions.cs b/mcs/class/System.Net.Http.Formatting/Extensions.cs
new file mode 100644 (file)
index 0000000..0f92f97
--- /dev/null
@@ -0,0 +1,47 @@
+//
+// Extension.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.Collections.Generic;
+using System.Net.Http.Headers;
+
+//
+// Workaround for not up-to-date aspnetwebstack, once it support .net 4.5 this could be deleted
+//
+static class Extensions
+{
+       public static void TryAddWithoutValidation (this HttpHeaders headers, string key, string value)
+       {
+               headers.AddWithoutValidation (key, value);
+       }
+       
+       public static bool TryAddWithoutValidation (this HttpHeaders headers, string key, IEnumerable<string> values)
+       {
+               headers.AddWithoutValidation (key, values);
+               return true;
+       }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Net.Http.Formatting/Makefile b/mcs/class/System.Net.Http.Formatting/Makefile
new file mode 100644 (file)
index 0000000..4238ea6
--- /dev/null
@@ -0,0 +1,21 @@
+thisdir = class/System.Net.Http.Formatting
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Net.Http.Formatting.dll
+
+
+System.Net.Http.Properties.CommonWebApiResources.resources: ../../../external/aspnetwebstack/src/Common/CommonWebApiResources.resx
+       $(RESGEN) "$<" "$@"
+       
+System.Net.Http.Properties.Resources.resources: ../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Properties/Resources.resx
+       $(RESGEN) "$<" "$@"
+
+LIB_MCS_FLAGS = -r:System.Core.dll -r:System.dll -r:System.Net.Http.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.Xml.Linq.dll -r:System.Data.dll -r:System.Configuration.dll \
+               -d:ASPNETMVC -keyfile:../winfx.pub -delaysign \
+               -resource:System.Net.Http.Properties.CommonWebApiResources.resources
+
+include ../../build/library.make
+
+$(the_lib): System.Net.Http.Properties.CommonWebApiResources.resources \
+       System.Net.Http.Properties.Resources.resources
\ No newline at end of file
diff --git a/mcs/class/System.Net.Http.Formatting/System.Net.Http.Formatting-net_4_5.csproj b/mcs/class/System.Net.Http.Formatting/System.Net.Http.Formatting-net_4_5.csproj
new file mode 100644 (file)
index 0000000..a785ed6
--- /dev/null
@@ -0,0 +1,339 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <NoWarn>1699</NoWarn>\r
+    <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
+    <NoStdLib>true</NoStdLib>\r
+    \r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <RootNamespace></RootNamespace>\r
+    <AssemblyName>System.Net.Http.Formatting</AssemblyName>\r
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>\r
+    <FileAlignment>512</FileAlignment>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>false</Optimize>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETMVC</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>true</Optimize>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETMVC</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <ItemGroup>\r
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\RS.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\TransparentCommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\CommonWebApiResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\DictionaryExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\Error.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\TaskHelpers.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\TaskHelpersExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\CloneableExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\BufferedMediaTypeFormatter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\ContentNegotiationResult.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\DefaultContentNegotiator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\DelegatingEnumerable.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\FormDataCollection.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\FormUrlEncodedJson.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\FormUrlEncodedMediaTypeFormatter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\IContentNegotiator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\IFormatterLogger.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\IRequiredMemberSelector.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\JsonContractResolver.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\JsonMediaTypeFormatter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\JsonReaderQuotaException.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\MediaRangeMapping.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\MediaTypeConstants.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\MediaTypeFormatterCollection.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\MediaTypeFormatter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\MediaTypeFormatterExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\MediaTypeHeaderValueExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\MediaTypeMapping.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\MediaTypeMatch.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\MediaTypeWithQualityHeaderValueComparer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\ParsedMediaTypeHeaderValue.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\Parsers\FormUrlEncodedParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\Parsers\HttpRequestHeaderParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\Parsers\HttpRequestLineParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\Parsers\HttpResponseHeaderParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\Parsers\HttpStatusLineParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\Parsers\InternetMessageFormatHeaderParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\Parsers\MimeMultipartBodyPartParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\Parsers\MimeMultipartParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\Parsers\ParserState.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\QueryStringMapping.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\RequestHeaderMapping.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\ResponseFormatterSelectionResult.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\ResponseMediaTypeMatch.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\SecureJsonTextReader.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\StringComparisonHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\StringWithQualityHeaderValueComparer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\FormattingUtilities.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\XHRRequestHeaderMapping.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Formatting\XmlMediaTypeFormatter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Headers\CookieHeaderValue.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Headers\CookieState.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpClientExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpContentCollectionExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpContentExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpContentMessageExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpContentMultipartExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpHeaderExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpMessageContent.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpRequestHeadersExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpRequestMessageExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpResponseHeadersExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpUnsortedHeaders.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpUnsortedRequest.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\HttpUnsortedResponse.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\IMultipartStreamProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Internal\AsyncResultWithExtraData.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Internal\DelegatingStream.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Internal\HttpValueCollection.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Internal\NonClosingDelegatingStream.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Internal\UriQueryUtility.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\MimeBodyPart.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\MultipartFileStreamProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\MultipartFormDataStreamProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\MultipartMemoryStreamProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\ObjectContent.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Properties\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\Properties\Resources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Net.Http.Formatting\UriExtensions.cs" />
+   <Compile Include="Extensions.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Bson\BsonBinaryType.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Bson\BsonBinaryWriter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Bson\BsonReader.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Bson\BsonToken.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Bson\BsonType.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Bson\BsonWriter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Bson\BsonObjectId.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\BinaryConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\DataSetConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\DataTableConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\CustomCreationConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\DateTimeConverterBase.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\EntityKeyMemberConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\ExpandoObjectConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\KeyValuePairConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\BsonObjectIdConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\RegexConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\StringEnumConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\ConstructorHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\VersionConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\DateFormatHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\DateTimeZoneHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Formatting.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonConstructorAttribute.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonPosition.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JPropertyKeyedCollection.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\DynamicProxy.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JPath.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JRaw.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Required.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonDynamicContract.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonFormatterConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonISerializableContract.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonLinqContract.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonPrimitiveContract.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\DynamicValueProvider.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\ErrorEventArgs.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JPropertyDescriptor.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\DefaultReferenceResolver.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\PreserveReferencesHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\IJsonLineInfo.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonArrayAttribute.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonContainerAttribute.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\DefaultValueHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonConverterAttribute.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonObjectAttribute.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonSerializerSettings.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonValidatingReader.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\IJEnumerable.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JTokenEqualityComparer.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\MemberSerialization.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\ObjectCreationHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\IsoDateTimeConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\JavaScriptDateTimeConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Converters\XmlNodeConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonTextReader.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonPropertyAttribute.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonIgnoreAttribute.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonTextWriter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonWriterException.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonReaderException.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonConverter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonConverterCollection.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonReader.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonConvert.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonSerializationException.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonSerializer.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\Extensions.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JConstructor.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JContainer.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JEnumerable.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JObject.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JArray.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JTokenReader.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JTokenWriter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JToken.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JProperty.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JTokenType.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Linq\JValue.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\Extensions.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaException.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaModel.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaModelBuilder.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaNodeCollection.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaNode.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaResolver.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaWriter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\UndefinedSchemaIdHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\ValidationEventArgs.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\ValidationEventHandler.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\CamelCasePropertyNamesContractResolver.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\DefaultContractResolver.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\DefaultSerializationBinder.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\ErrorContext.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\IContractResolver.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\IValueProvider.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonArrayContract.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonContract.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonDictionaryContract.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonProperty.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonPropertyCollection.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\MissingMemberHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\NullValueHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\ReferenceLoopHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchema.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaBuilder.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaConstants.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaGenerator.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\IReferenceResolver.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Schema\JsonSchemaType.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonObjectContract.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonSerializerInternalBase.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonSerializerInternalReader.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonSerializerInternalWriter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonSerializerProxy.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonStringContract.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\JsonTypeReflector.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\CachedAttributeGetter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\LateBoundMetadataTypeAttribute.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\ReflectionValueProvider.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\OnErrorAttribute.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\Base64Encoder.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\DynamicProxyMetaObject.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\DynamicUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\DynamicWrapper.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\DynamicReflectionDelegateFactory.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Serialization\ObjectConstructor.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\ILGeneratorExtensions.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\ReflectionDelegateFactory.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\LateBoundReflectionDelegateFactory.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\MethodCall.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\StringReference.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\ThreadSafeStore.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\TypeNameHandling.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\BidirectionalDictionary.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\ConvertUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\CollectionWrapper.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\DateTimeUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\DictionaryWrapper.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\EnumUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\EnumValue.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\EnumValues.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\JavaScriptUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonToken.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\JsonWriter.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\StringBuffer.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\CollectionUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\ListWrapper.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\MathUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\MiscellaneousUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\ReflectionUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\StringUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\TypeExtensions.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\Utilities\ValidationUtils.cs" />
+   <Compile Include="..\..\..\external\Newtonsoft.Json\Src\Newtonsoft.Json\WriteState.cs" />
+\r
+  </ItemGroup>\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+  <PropertyGroup>\r
+    <PreBuildEvent></PreBuildEvent>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="mscorlib.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>mscorlib.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Net.Http.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Net.Http.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Runtime.Serialization.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Runtime.Serialization.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.Linq.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.Linq.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Data.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Data.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Configuration.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Configuration.dll</HintPath>
+    </Reference>
+\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Folder Include="Properties\" />\r
+  </ItemGroup>\r
+    <ItemGroup>
+    <EmbeddedResource Include="System.Net.Http.Properties.CommonWebApiResources.resources">
+       <LogicalName>System.Net.Http.Properties.CommonWebApiResources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
+</Project>\r
+
diff --git a/mcs/class/System.Net.Http.Formatting/System.Net.Http.Formatting.dll.sources b/mcs/class/System.Net.Http.Formatting/System.Net.Http.Formatting.dll.sources
new file mode 100644 (file)
index 0000000..424472b
--- /dev/null
@@ -0,0 +1,242 @@
+../../../external/aspnetwebstack/src/CommonAssemblyInfo.cs
+../../../external/aspnetwebstack/src/RS.cs
+../../../external/aspnetwebstack/src/TransparentCommonAssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/Common/CommonWebApiResources.Designer.cs
+../../../external/aspnetwebstack/src/Common/DictionaryExtensions.cs
+../../../external/aspnetwebstack/src/Common/Error.cs
+../../../external/aspnetwebstack/src/Common/TaskHelpers.cs
+../../../external/aspnetwebstack/src/Common/TaskHelpersExtensions.cs
+
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/CloneableExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/BufferedMediaTypeFormatter.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/ContentNegotiationResult.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/DefaultContentNegotiator.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/DelegatingEnumerable.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/FormDataCollection.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/FormUrlEncodedJson.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/FormUrlEncodedMediaTypeFormatter.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/IContentNegotiator.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/IFormatterLogger.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/IRequiredMemberSelector.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/JsonContractResolver.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/JsonMediaTypeFormatter.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/JsonReaderQuotaException.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/MediaRangeMapping.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/MediaTypeConstants.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/MediaTypeFormatterCollection.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/MediaTypeFormatter.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/MediaTypeFormatterExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/MediaTypeHeaderValueExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/MediaTypeMapping.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/MediaTypeMatch.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/MediaTypeWithQualityHeaderValueComparer.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/ParsedMediaTypeHeaderValue.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/Parsers/FormUrlEncodedParser.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/Parsers/HttpRequestHeaderParser.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/Parsers/HttpRequestLineParser.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/Parsers/HttpResponseHeaderParser.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/Parsers/HttpStatusLineParser.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/Parsers/InternetMessageFormatHeaderParser.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/Parsers/MimeMultipartBodyPartParser.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/Parsers/MimeMultipartParser.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/Parsers/ParserState.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/QueryStringMapping.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/RequestHeaderMapping.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/ResponseFormatterSelectionResult.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/ResponseMediaTypeMatch.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/SecureJsonTextReader.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/StringComparisonHelper.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/StringWithQualityHeaderValueComparer.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/FormattingUtilities.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/XHRRequestHeaderMapping.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Formatting/XmlMediaTypeFormatter.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Headers/CookieHeaderValue.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Headers/CookieState.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpClientExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpContentCollectionExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpContentExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpContentMessageExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpContentMultipartExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpHeaderExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpMessageContent.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpRequestHeadersExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpRequestMessageExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpResponseHeadersExtensions.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpUnsortedHeaders.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpUnsortedRequest.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/HttpUnsortedResponse.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/IMultipartStreamProvider.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Internal/AsyncResultWithExtraData.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Internal/DelegatingStream.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Internal/HttpValueCollection.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Internal/NonClosingDelegatingStream.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Internal/UriQueryUtility.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/MimeBodyPart.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/MultipartFileStreamProvider.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/MultipartFormDataStreamProvider.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/MultipartMemoryStreamProvider.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/ObjectContent.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Properties/AssemblyInfo.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/Properties/Resources.Designer.cs
+../../../external/aspnetwebstack/src/System.Net.Http.Formatting/UriExtensions.cs
+
+
+Extensions.cs
+
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Bson/BsonBinaryType.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Bson/BsonBinaryWriter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Bson/BsonReader.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Bson/BsonToken.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Bson/BsonType.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Bson/BsonWriter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Bson/BsonObjectId.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/BinaryConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/DataSetConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/DataTableConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/CustomCreationConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/DateTimeConverterBase.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/EntityKeyMemberConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/ExpandoObjectConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/KeyValuePairConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/BsonObjectIdConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/RegexConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/StringEnumConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/ConstructorHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/VersionConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/DateFormatHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/DateTimeZoneHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Formatting.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonConstructorAttribute.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonPosition.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JPropertyKeyedCollection.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/DynamicProxy.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JPath.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JRaw.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Required.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonDynamicContract.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonFormatterConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonISerializableContract.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonLinqContract.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonPrimitiveContract.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/DynamicValueProvider.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/ErrorEventArgs.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JPropertyDescriptor.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/DefaultReferenceResolver.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/PreserveReferencesHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/IJsonLineInfo.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonArrayAttribute.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonContainerAttribute.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/DefaultValueHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonConverterAttribute.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonObjectAttribute.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonSerializerSettings.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonValidatingReader.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/IJEnumerable.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JTokenEqualityComparer.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/MemberSerialization.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/ObjectCreationHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/IsoDateTimeConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/JavaScriptDateTimeConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Converters/XmlNodeConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonTextReader.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonPropertyAttribute.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonIgnoreAttribute.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonTextWriter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonWriterException.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonReaderException.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonConverter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonConverterCollection.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonReader.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonConvert.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonSerializationException.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonSerializer.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/Extensions.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JConstructor.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JContainer.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JEnumerable.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JObject.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JArray.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JTokenReader.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JTokenWriter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JToken.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JProperty.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JTokenType.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Linq/JValue.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/Extensions.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaException.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaModel.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaModelBuilder.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaNodeCollection.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaNode.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaResolver.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaWriter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/UndefinedSchemaIdHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/ValidationEventArgs.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/ValidationEventHandler.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/CamelCasePropertyNamesContractResolver.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/DefaultContractResolver.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/DefaultSerializationBinder.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/ErrorContext.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/IContractResolver.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/IValueProvider.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonArrayContract.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonContract.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonDictionaryContract.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonProperty.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonPropertyCollection.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/MissingMemberHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/NullValueHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/ReferenceLoopHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchema.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaBuilder.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaConstants.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaGenerator.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/IReferenceResolver.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Schema/JsonSchemaType.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonObjectContract.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonSerializerInternalBase.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonSerializerInternalReader.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonSerializerInternalWriter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonSerializerProxy.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonStringContract.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/JsonTypeReflector.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/CachedAttributeGetter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/LateBoundMetadataTypeAttribute.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/ReflectionValueProvider.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/OnErrorAttribute.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/Base64Encoder.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/DynamicProxyMetaObject.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/DynamicUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/DynamicWrapper.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/DynamicReflectionDelegateFactory.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Serialization/ObjectConstructor.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/ILGeneratorExtensions.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/ReflectionDelegateFactory.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/LateBoundReflectionDelegateFactory.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/MethodCall.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/StringReference.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/ThreadSafeStore.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/TypeNameHandling.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/BidirectionalDictionary.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/ConvertUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/CollectionWrapper.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/DateTimeUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/DictionaryWrapper.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/EnumUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/EnumValue.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/EnumValues.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/JavaScriptUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonToken.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/JsonWriter.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/StringBuffer.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/CollectionUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/ListWrapper.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/MathUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/MiscellaneousUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/ReflectionUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/StringUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/TypeExtensions.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/Utilities/ValidationUtils.cs
+../../../external/Newtonsoft.Json/Src/Newtonsoft.Json/WriteState.cs
index 1b530078df56c56cebc665a514372c3279be8a22..869ab38bc95ef97f051374682be282473a69ef47 100644 (file)
@@ -53,7 +53,7 @@ using System.Runtime.InteropServices;
 [assembly: CLSCompliant (true)]
 [assembly: AssemblyDelaySign (true)]
 
-[assembly: AssemblyKeyFile ("../ecma.pub")]
+[assembly: AssemblyKeyFile ("../msfinal.pub")]
 
 [assembly: ComVisible (false)]
 
index f2045607ae66d0607713dfd7ae33ccd1aea794ce..715fa63120bcfc6d2878ed8ec28cb3f35746e2b6 100644 (file)
@@ -6,4 +6,6 @@ LIBRARY = System.Net.Http.dll
 
 LIB_MCS_FLAGS = -r:System.Core.dll -r:System.dll
 
+TEST_MCS_FLAGS = -r:System.dll -r:System.Core.dll
+
 include ../../build/library.make
diff --git a/mcs/class/System.Net.Http/System.Net.Http-net_4_5.csproj b/mcs/class/System.Net.Http/System.Net.Http-net_4_5.csproj
new file mode 100644 (file)
index 0000000..f6c2ac3
--- /dev/null
@@ -0,0 +1,113 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{9862694d-e4fa-418b-8692-a0280feddf36}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <NoWarn>1699</NoWarn>\r
+    <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
+    <NoStdLib>true</NoStdLib>\r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <AssemblyName>System.Net.Http</AssemblyName>\r
+    <FileAlignment>512</FileAlignment>\r
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <Optimize>false</Optimize>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+    <OutputPath>..\lib\net_4_5</OutputPath>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <Optimize>true</Optimize>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+    <OutputPath>..\lib\net_4_5</OutputPath>\r
+  </PropertyGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <ItemGroup>\r
+    <Compile Include="..\..\build\common\Consts.cs" />\r
+    <Compile Include="Assembly\AssemblyInfo.cs" />\r
+    <Compile Include="System.Net.Http\ByteArrayContent.cs" />\r
+    <Compile Include="System.Net.Http\ClientCertificateOption.cs" />\r
+    <Compile Include="System.Net.Http\DelegatingHandler.cs" />\r
+    <Compile Include="System.Net.Http\FormUrlEncodedContent.cs" />\r
+    <Compile Include="System.Net.Http\HttpClient.cs" />\r
+    <Compile Include="System.Net.Http\HttpClientHandler.cs" />\r
+    <Compile Include="System.Net.Http\HttpCompletionOption.cs" />\r
+    <Compile Include="System.Net.Http\HttpContent.cs" />\r
+    <Compile Include="System.Net.Http\HttpMessageHandler.cs" />\r
+    <Compile Include="System.Net.Http\HttpMethod.cs" />\r
+    <Compile Include="System.Net.Http\HttpRequestException.cs" />\r
+    <Compile Include="System.Net.Http\HttpRequestMessage.cs" />\r
+    <Compile Include="System.Net.Http\HttpResponseMessage.cs" />\r
+    <Compile Include="System.Net.Http\MessageProcessingHandler.cs" />\r
+    <Compile Include="System.Net.Http\StreamContent.cs" />\r
+    <Compile Include="System.Net.Http\StringContent.cs" />\r
+    <Compile Include="System.Net.Http.Headers\AuthenticationHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\CacheControlHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\CollectionExtensions.cs" />\r
+    <Compile Include="System.Net.Http.Headers\ContentDispositionHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\ContentRangeHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\EntityTagHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\HashCodeCalculator.cs" />\r
+    <Compile Include="System.Net.Http.Headers\HeaderInfo.cs" />\r
+    <Compile Include="System.Net.Http.Headers\HttpContentHeaders.cs" />\r
+    <Compile Include="System.Net.Http.Headers\HttpHeaderKind.cs" />\r
+    <Compile Include="System.Net.Http.Headers\HttpHeaders.cs" />\r
+    <Compile Include="System.Net.Http.Headers\HttpHeaderValueCollection.cs" />\r
+    <Compile Include="System.Net.Http.Headers\HttpRequestHeaders.cs" />\r
+    <Compile Include="System.Net.Http.Headers\HttpResponseHeaders.cs" />\r
+    <Compile Include="System.Net.Http.Headers\Lexer.cs" />\r
+    <Compile Include="System.Net.Http.Headers\MediaTypeHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\MediaTypeWithQualityHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\NameValueHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\NameValueWithParametersHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\Parser.cs" />\r
+    <Compile Include="System.Net.Http.Headers\ProductHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\ProductInfoHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\QualityValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\RangeConditionHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\RangeHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\RangeItemHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\RetryConditionHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\StringWithQualityHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\TransferCodingHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\TransferCodingWithQualityHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\ViaHeaderValue.cs" />\r
+    <Compile Include="System.Net.Http.Headers\WarningHeaderValue.cs" />\r
+  </ItemGroup>\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+  <PropertyGroup>\r
+    <PreBuildEvent>\r
+    </PreBuildEvent>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Folder Include="Properties\" />\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Reference Include="System.Core.dll" />\r
+    <Reference Include="System">\r
+      <HintPath>..\lib\net_4_5\System.dll</HintPath>\r
+    </Reference>\r
+    <Reference Include="mscorlib">\r
+      <HintPath>..\lib\net_4_5\mscorlib.dll</HintPath>\r
+    </Reference>\r
+  </ItemGroup>\r
+</Project>\r
diff --git a/mcs/class/System.Net.Http/System.Net.Http-net_4_5.sln b/mcs/class/System.Net.Http/System.Net.Http-net_4_5.sln
new file mode 100644 (file)
index 0000000..2e55bf7
--- /dev/null
@@ -0,0 +1,26 @@
+\r
+Microsoft Visual Studio Solution File, Format Version 11.00\r
+# Visual Studio 2010\r
+Project("{9862694d-e4fa-418b-8692-a0280feddf36}") = "System.Net.Http-net_4_5", "System.Net.Http-net_4_5.csproj", "{9862694d-e4fa-418b-8692-a0280feddf36}"\r
+EndProject\r
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "System.Net.Http-tests-net_4_5", "System.Net.Http-tests-net_4_5.csproj", "{155AEF28-C81F-405D-9072-9D52780E3E70}"\r
+EndProject\r
+Global\r
+       GlobalSection(SolutionConfigurationPlatforms) = preSolution\r
+               Debug|Any CPU = Debug|Any CPU\r
+               Release|Any CPU = Release|Any CPU\r
+       EndGlobalSection\r
+       GlobalSection(ProjectConfigurationPlatforms) = postSolution\r
+               {9862694d-e4fa-418b-8692-a0280feddf36}.Debug|Any CPU.ActiveCfg = Debug|Any CPU\r
+               {155AEF28-C81F-405D-9072-9D52780E3E70}.Debug|Any CPU.ActiveCfg = Debug|Any CPU\r
+               {9862694d-e4fa-418b-8692-a0280feddf36}.Debug|Any CPU.Build.0 = Debug|Any CPU\r
+               {155AEF28-C81F-405D-9072-9D52780E3E70}.Debug|Any CPU.Build.0 = Debug|Any CPU\r
+               {9862694d-e4fa-418b-8692-a0280feddf36}.Release|Any CPU.ActiveCfg = Release|Any CPU\r
+               {155AEF28-C81F-405D-9072-9D52780E3E70}.Release|Any CPU.ActiveCfg = Release|Any CPU\r
+               {9862694d-e4fa-418b-8692-a0280feddf36}.Release|Any CPU.Build.0 = Release|Any CPU\r
+               {155AEF28-C81F-405D-9072-9D52780E3E70}.Release|Any CPU.Build.0 = Release|Any CPU\r
+       EndGlobalSection\r
+       GlobalSection(MonoDevelopProperties) = preSolution\r
+               StartupItem = System.Net.Http-net_4_5.csproj\r
+       EndGlobalSection\r
+EndGlobal\r
diff --git a/mcs/class/System.Net.Http/System.Net.Http-tests-net_4_5.csproj b/mcs/class/System.Net.Http/System.Net.Http-tests-net_4_5.csproj
new file mode 100644 (file)
index 0000000..1fc0617
--- /dev/null
@@ -0,0 +1,100 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <NoWarn>1699</NoWarn>\r
+    <OutputPath>.\</OutputPath>\r
+    <NoStdLib>true</NoStdLib>\r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <AssemblyName>System.Net.Http_test_net_4_5</AssemblyName>\r
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>\r
+    <FileAlignment>512</FileAlignment>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <Optimize>false</Optimize>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+    <OutputPath>.</OutputPath>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <Optimize>true</Optimize>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+    <OutputPath>.</OutputPath>\r
+  </PropertyGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <ItemGroup>\r
+    <Compile Include="Test\System.Net.Http\ByteArrayContentTest.cs" />\r
+    <Compile Include="Test\System.Net.Http\FormUrlEncodedContentTest.cs" />\r
+    <Compile Include="Test\System.Net.Http\HttpClientHandlerTest.cs" />\r
+    <Compile Include="Test\System.Net.Http\HttpClientTest.cs" />\r
+    <Compile Include="Test\System.Net.Http\HttpMethodTest.cs" />\r
+    <Compile Include="Test\System.Net.Http\HttpRequestMessageTest.cs" />\r
+    <Compile Include="Test\System.Net.Http\HttpResponseMessageTest.cs" />\r
+    <Compile Include="Test\System.Net.Http\StreamContentTest.cs" />\r
+    <Compile Include="Test\System.Net.Http\StringContentTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\AuthenticationHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\CacheControlHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\ContentDispositionHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\ContentRangeHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\EntityTagHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\HttpHeadersTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\HttpHeaderValueCollection.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\MediaTypeHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\MediaTypeWithQualityHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\NameValueHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\NameValueWithParametersHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\ProductHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\ProductInfoHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\RangeConditionHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\RangeHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\RangeItemHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\RetryConditionHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\StringWithQualityHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\TransferCodingHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\TransferCodingWithQualityHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\ViaHeaderValueTest.cs" />\r
+    <Compile Include="Test\System.Net.Http.Headers\WarningHeaderValueTest.cs" />\r
+  </ItemGroup>\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+  <PropertyGroup>\r
+    <PreBuildEvent>\r
+    </PreBuildEvent>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="nunit.framework" />\r
+    <Reference Include="mscorlib">\r
+    </Reference>\r
+    <Reference Include="System">\r
+    </Reference>\r
+    <Reference Include="System.Core">\r
+    </Reference>\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Folder Include="Properties\" />\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <ProjectReference Include="System.Net.Http-net_4_5.csproj">\r
+      <Project>{155AEF28-C81F-405D-9072-9D52780E3E70}</Project>\r
+      <Name>System.Net.Http-net_4_5</Name>\r
+    </ProjectReference>\r
+  </ItemGroup>\r
+</Project>\r
index a0da37e90e7eef649f72d0e8b0787f865e6a5db8..057bc116fcd353b3db730269d6475e12bd03e617 100644 (file)
@@ -45,6 +45,26 @@ namespace System.Net.Http.Headers
                        return Enumerable.SequenceEqual (first, second);
                }
 
+               public static void SetValue (this List<NameValueHeaderValue> parameters, string key, string value)
+               {
+                       for (int i = 0; i < parameters.Count; ++i) {
+                               var entry = parameters[i];
+                               if (!string.Equals (entry.Name, key, StringComparison.OrdinalIgnoreCase))
+                                       continue;
+
+                               if (value == null) {
+                                       parameters.RemoveAt (i);
+                               } else {
+                                       parameters[i].Value = value;
+                               }
+
+                               return;
+                       }
+
+                       if (!string.IsNullOrEmpty (value))
+                               parameters.Add (new NameValueHeaderValue (key, value));
+               }
+
                public static string ToString<T> (this List<T> list)
                {
                        if (list == null || list.Count == 0)
diff --git a/mcs/class/System.Net.Http/System.Net.Http.Headers/ContentDispositionHeaderValue.cs b/mcs/class/System.Net.Http/System.Net.Http.Headers/ContentDispositionHeaderValue.cs
new file mode 100644 (file)
index 0000000..98225b9
--- /dev/null
@@ -0,0 +1,414 @@
+//
+// ContentDispositionHeaderValue.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.Collections.Generic;
+using System.Text;
+using System.Globalization;
+
+namespace System.Net.Http.Headers
+{
+       public class ContentDispositionHeaderValue : ICloneable
+       {
+               string dispositionType;
+               List<NameValueHeaderValue> parameters;
+
+               private ContentDispositionHeaderValue ()
+               {
+               }
+
+               public ContentDispositionHeaderValue (string dispositionType)
+               {
+                       DispositionType = dispositionType;
+               }
+
+               protected ContentDispositionHeaderValue (ContentDispositionHeaderValue source)
+               {
+                       if (source == null)
+                               throw new ArgumentNullException ("source");
+
+                       dispositionType = source.dispositionType;
+                       if (source.parameters != null) {
+                               foreach (var item in source.parameters)
+                                       Parameters.Add (new NameValueHeaderValue (item));
+                       }
+               }
+
+               public DateTimeOffset? CreationDate {
+                       get {
+                               return GetDateValue ("creation-date");
+                       }
+                       set {
+                               SetDateValue ("creation-date", value);
+                       }
+               }
+               
+               public string DispositionType {
+                       get {
+                               return dispositionType;
+                       }
+                       set {
+                               Parser.Token.Check (value);
+                               dispositionType = value;
+                       }
+               }
+
+               public string FileName {
+                       get {
+                               var value = FindParameter ("filename");
+                               if (value == null)
+                                       return null;
+
+                               return DecodeValue (value, false);
+                       }
+                       set {
+                               if (value != null)
+                                       value = EncodeBase64Value (value);
+
+                               SetValue ("filename", value);
+                       }
+               }
+
+               public string FileNameStar {
+                       get {
+                               var value = FindParameter ("filename*");
+                               if (value == null)
+                                       return null;
+
+                               return DecodeValue (value, true);
+                       }
+                       set {
+                               if (value != null)
+                                       value = EncodeRFC5987 (value);
+
+                               SetValue ("filename*", value);
+                       }
+               }
+
+               public DateTimeOffset? ModificationDate {
+                       get {
+                               return GetDateValue ("modification-date");
+                       }
+                       set {
+                               SetDateValue ("modification-date", value);
+                       }
+               }
+
+               public string Name {
+                       get {
+                               return FindParameter ("name");
+                       }
+                       set {
+                               SetValue ("name", value);
+                       }
+               }
+
+               public ICollection<NameValueHeaderValue> Parameters {
+                       get {
+                               return parameters ?? (parameters = new List<NameValueHeaderValue> ());
+                       }
+               }
+
+               public DateTimeOffset? ReadDate {
+                       get {
+                               return GetDateValue ("read-date");
+                       }
+                       set {
+                               SetDateValue ("read-date", value);
+                       }
+               }
+
+               public long? Size {
+                       get {
+                               var found = FindParameter ("size");
+                               long result;
+                               if (Parser.Long.TryParse (found, out result))
+                                       return result;
+
+                               return null;
+                       }
+                       set {
+                               if (value == null) {
+                                       SetValue ("size", null);
+                                       return;
+                               }
+
+                               if (value < 0)
+                                       throw new ArgumentOutOfRangeException ("value");
+
+                               SetValue ("size", value.Value.ToString (CultureInfo.InvariantCulture));
+                       }
+               }
+
+               object ICloneable.Clone ()
+               {
+                       return new ContentDispositionHeaderValue (this);
+               }
+
+               public override bool Equals (object obj)
+               {
+                       var source = obj as ContentDispositionHeaderValue;
+                       return source != null &&
+                               string.Equals (source.dispositionType, dispositionType, StringComparison.OrdinalIgnoreCase) &&
+                               source.parameters.SequenceEqual (parameters);
+               }
+
+               string FindParameter (string name)
+               {
+                       if (parameters == null)
+                               return null;
+
+                       foreach (var entry in parameters) {
+                               if (string.Equals (entry.Name, name, StringComparison.OrdinalIgnoreCase))
+                                       return entry.Value;
+                       }
+
+                       return null;
+               }
+
+               DateTimeOffset? GetDateValue (string name)
+               {
+                       var value = FindParameter (name);
+                       if (value == null || value == null)
+                               return null;
+
+                       if (value.Length < 3)
+                               return null;
+
+                       if (value[0] == '\"')
+                               value = value.Substring (1, value.Length - 2);
+
+                       DateTimeOffset offset;
+                       if (Lexer.TryGetDateValue (value, out offset))
+                               return offset;
+
+                       return null;
+               }
+
+               static string EncodeBase64Value (string value)
+               {
+                       for (int i = 0; i < value.Length; ++i) {
+                               var ch = value[i];
+                               if (ch > 127) {
+                                       var encoding = Encoding.UTF8;
+                                       return string.Format ("\"=?{0}?B?{1}?=\"",
+                                               encoding.WebName, Convert.ToBase64String (encoding.GetBytes (value)));
+                               }
+                       }
+
+                       if (!Lexer.IsValidToken (value))
+                               return "\"" + value + "\"";
+
+                       return value;
+               }
+
+               static string EncodeRFC5987 (string value)
+               {
+                       var encoding = Encoding.UTF8;
+                       StringBuilder sb = new StringBuilder (value.Length + 11);
+                       sb.Append (encoding.WebName);
+                       sb.Append ('\'');
+                       sb.Append ('\'');
+
+                       for (int i = 0; i < value.Length; ++i) {
+                               var ch = value[i];
+                               if (ch > 127) {
+                                       foreach (var b in encoding.GetBytes (new[] { ch })) {
+                                               sb.Append ('%');
+                                               sb.Append (b.ToString ("X2"));
+                                       }
+
+                                       continue;
+                               }
+
+                               sb.Append (ch);
+                       }
+
+                       return sb.ToString ();
+               }
+
+               static string DecodeValue (string value, bool extendedNotation)
+               {
+                       //
+                       // A short (length <= 78 characters)
+                       // parameter value containing only non-`tspecials' characters SHOULD be
+                       // represented as a single `token'.  A short parameter value containing
+                       // only ASCII characters, but including `tspecials' characters, SHOULD
+                       // be represented as `quoted-string'.  Parameter values longer than 78
+                       // characters, or which contain non-ASCII characters, MUST be encoded as
+                       // specified in [RFC 2184].
+                       //
+                       if (value.Length < 2)
+                               return value;
+
+                       string[] sep;
+                       Encoding encoding;
+
+                       // Quoted string
+                       if (value[0] == '\"') {
+                               //
+                               // Is Base64 encoded ?
+                               // encoded-word := "=?" charset "?" encoding "?" encoded-text "?="
+                               //
+                               sep = value.Split ('?');
+                               if (sep.Length != 5 || sep[0] != "\"=" || sep[4] != "=\"" || (sep[2] != "B" && sep[2] != "b"))
+                                       return value;
+
+                               try {
+                                       encoding = Encoding.GetEncoding (sep[1]);
+                                       return encoding.GetString (Convert.FromBase64String (sep[3]));
+                               } catch {
+                                       return value;
+                               }
+                       }
+
+                       if (!extendedNotation)
+                               return value;
+
+                       //
+                       // RFC 5987: Charset/Language Encoding
+                       //
+                       sep = value.Split ('\'');
+                       if (sep.Length != 3)
+                               return null;
+
+                       try {
+                               encoding = Encoding.GetEncoding (sep[0]);
+                       } catch {
+                               return null;
+                       }
+
+                       // TODO: What to do with sep[1] language
+
+                       value = sep[2];
+
+                       int pct_encoded = value.IndexOf ('%');
+                       if (pct_encoded < 0)
+                               return value;
+
+                       StringBuilder sb = new StringBuilder ();
+                       byte[] buffer = null;
+                       int buffer_pos = 0;
+
+                       for (int i = 0; i < value.Length;) {
+                               var ch = value[i];
+                               if (ch == '%') {
+                                       var unescaped = ch;
+                                       ch = Uri.HexUnescape (value, ref i);
+                                       if (ch != unescaped) {
+                                               if (buffer == null)
+                                                       buffer = new byte[value.Length - i + 1];
+
+                                               buffer[buffer_pos++] = (byte) ch;
+                                               continue;
+                                       }
+                               } else {
+                                       ++i;
+                               }
+
+                               if (buffer_pos != 0) {
+                                       sb.Append (encoding.GetChars (buffer, 0, buffer_pos));
+                                       buffer_pos = 0;
+                               }
+
+                               sb.Append (ch);
+                       }
+
+                       if (buffer_pos != 0) {
+                               sb.Append (encoding.GetChars (buffer, 0, buffer_pos));
+                       }
+
+                       return sb.ToString ();
+               }
+
+               public override int GetHashCode ()
+               {
+                       return dispositionType.ToLowerInvariant ().GetHashCode () ^
+                               HashCodeCalculator.Calculate (parameters);
+               }
+
+               public static ContentDispositionHeaderValue Parse (string input)
+               {
+                       ContentDispositionHeaderValue value;
+                       if (TryParse (input, out value))
+                               return value;
+
+                       throw new FormatException (input);
+               }
+
+               void SetDateValue (string key, DateTimeOffset? value)
+               {
+                       SetValue (key, value == null ? null : ("\"" + value.Value.ToString ("r", CultureInfo.InvariantCulture)) + "\"");
+               }
+
+               void SetValue (string key, string value)
+               {
+                       if (parameters == null)
+                               parameters = new List<NameValueHeaderValue> ();
+
+                       parameters.SetValue (key, value);
+               }
+
+               public override string ToString ()
+               {
+                       return dispositionType + CollectionExtensions.ToString (parameters);
+               }
+
+               public static bool TryParse (string input, out ContentDispositionHeaderValue parsedValue)
+               {
+                       parsedValue = null;
+
+                       var lexer = new Lexer (input);
+                       var t = lexer.Scan ();
+                       if (t.Kind != Token.Type.Token)
+                               return false;
+
+                       List<NameValueHeaderValue> parameters = null;
+                       var type = lexer.GetStringValue (t);
+
+                       t = lexer.Scan ();
+
+                       switch (t.Kind) {
+                       case Token.Type.SeparatorSemicolon:
+                               if (!NameValueHeaderValue.ParseParameters (lexer, out parameters))
+                                       return false;
+                               break;
+                       case Token.Type.End:
+                               break;
+                       default:
+                               return false;
+                       }
+
+                       parsedValue = new ContentDispositionHeaderValue () {
+                               dispositionType = type,
+                               parameters = parameters
+                       };
+
+                       return true;
+               }
+       }
+}
index 49efa5076099a86c374e613839332a696211a49c..57bda06b90c3cf431083d388615753634f1a3866 100644 (file)
@@ -51,6 +51,15 @@ namespace System.Net.Http.Headers
                                return GetValues<string> ("Content-Encoding");
                        }
                }
+               
+               public ContentDispositionHeaderValue ContentDisposition {
+                       get {
+                               return GetValue<ContentDispositionHeaderValue> ("Content-Disposition");
+                       }
+                       set {
+                               AddOrRemove ("Content-Disposition", value);
+                       }
+               }
 
                public ICollection<string> ContentLanguage {
                        get {
@@ -116,7 +125,7 @@ namespace System.Net.Http.Headers
                                return GetValue<DateTimeOffset?> ("Expires");
                        }
                        set {
-                               AddOrRemove ("Expires", value);
+                               AddOrRemove ("Expires", value, Parser.DateTime.ToString);
                        }
                }
 
@@ -125,7 +134,7 @@ namespace System.Net.Http.Headers
                                return GetValue<DateTimeOffset?> ("Last-Modified");
                        }
                        set {
-                               AddOrRemove ("Last-Modified", value);
+                               AddOrRemove ("Last-Modified", value, Parser.DateTime.ToString);
                        }
                }
        }
index db94aaa0b0e208b59f0fb8cc97054654c3917c7e..8f512c6cd33eda0f68afdd8058794cc2be512db8 100644 (file)
@@ -117,7 +117,7 @@ namespace System.Net.Http.Headers
                                return GetValue<DateTimeOffset?> ("Date");
                        }
                        set {
-                               AddOrRemove ("Date", value);
+                               AddOrRemove ("Date", value, Parser.DateTime.ToString);
                        }
                }
 
@@ -180,7 +180,7 @@ namespace System.Net.Http.Headers
                                return GetValue<DateTimeOffset?> ("If-Modified-Since");
                        }
                        set {
-                               AddOrRemove ("If-Modified-Since", value);
+                               AddOrRemove ("If-Modified-Since", value, Parser.DateTime.ToString);
                        }
                }
 
@@ -204,7 +204,7 @@ namespace System.Net.Http.Headers
                                return GetValue<DateTimeOffset?> ("If-Unmodified-Since");
                        }
                        set {
-                               AddOrRemove ("If-Unmodified-Since", value);
+                               AddOrRemove ("If-Unmodified-Since", value, Parser.DateTime.ToString);
                        }
                }
 
index 2e60df36e4b0fcc5858f17ad2c5b609d4d0f2059..388f274e4eee240f683e59e63ba054168b5fb4dc 100644 (file)
@@ -91,7 +91,7 @@ namespace System.Net.Http.Headers
                                return GetValue<DateTimeOffset?> ("Date");
                        }
                        set {
-                               AddOrRemove ("Date", value);
+                               AddOrRemove ("Date", value, Parser.DateTime.ToString);
                        }
                }
 
index 573840427109567e9f2b7985b48faab9b6b2e3a5..51950a7a0abedcf152b10ad7a6f85e4b134946c5 100644 (file)
@@ -78,19 +78,31 @@ namespace System.Net.Http.Headers
 
        class Lexer
        {
+               // any CHAR except CTLs or separators
                static readonly bool[] token_chars = {
-                               false, false, false, false, false, false, false, false, false, false, false, false, false, false,
-                               false, false, false, false, false, false, false, false, false, false, false, false, false, false,
-                               false, false, false, false, false, true, false, true, true, true, true, false, false, false, true,
-                               true, false, true, true, false, true, true, true, true, true, true, true, true, true, true, false,
-                               false, false, false, false, false, false, true, true, true, true, true, true, true, true, true,
-                               true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true,
-                               false, false, false, true, true, true, true, true, true, true, true, true, true, true, true, true,
-                               true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true,
-                               false, true, false
+                       /*0*/   false, false, false, false, false, false, false, false, false, false,
+                       /*10*/  false, false, false, false, false, false, false, false, false, false,
+                       /*20*/  false, false, false, false, false, false, false, false, false, false,
+                       /*30*/  false, false, false, true, false, true, true, true, true, true,
+                       /*40*/  false, false, true, true, false, true, true, false, true, true,
+                       /*50*/  true, true, true, true, true, true, true, true, false, false,
+                       /*60*/  false, false, false, false, false, true, true, true, true, true,
+                       /*70*/  true, true, true, true, true, true, true, true, true, true,
+                       /*80*/  true, true, true, true, true, true, true, true, true, true,
+                       /*90*/  true, false, false, false, true, true, true, true, true, true,
+                       /*100*/ true, true, true, true, true, true, true, true, true, true,
+                       /*110*/ true, true, true, true, true, true, true, true, true, true,
+                       /*120*/ true, true, true, false, true, false
                        };
 
                static readonly int last_token_char = token_chars.Length;
+               static readonly string[] dt_formats = new[] {
+                               "r",
+                               "dddd, dd'-'MMM'-'yy HH:mm:ss 'GMT'",
+                               "ddd MMM d HH:mm:ss yyyy",
+                               "d MMM yy H:m:s",
+                               "ddd, d MMM yyyy H:m:s zzz"
+               };
 
                readonly string s;
                int pos;
@@ -153,10 +165,7 @@ namespace System.Net.Http.Headers
                {
                        const DateTimeStyles DefaultStyles = DateTimeStyles.AssumeUniversal | DateTimeStyles.AllowWhiteSpaces;
 
-                   return
-                               DateTimeOffset.TryParseExact (text, "r", DateTimeFormatInfo.InvariantInfo, DefaultStyles, out value) ||
-                               DateTimeOffset.TryParseExact (text, "dddd, dd'-'MMM'-'yy HH:mm:ss 'GMT'", DateTimeFormatInfo.InvariantInfo, DefaultStyles, out value) ||
-                               DateTimeOffset.TryParseExact (text, "ddd MMM d HH:mm:ss yyyy", DateTimeFormatInfo.InvariantInfo, DefaultStyles, out value);
+                       return DateTimeOffset.TryParseExact (text, dt_formats, DateTimeFormatInfo.InvariantInfo, DefaultStyles, out value);
                }
 
                public bool TryGetDoubleValue (Token token, out double value)
index 2438428cefb19b9ae1b1c2d2d0574020f12c686c..f8d351e243f937b88bf6f3e97da9a49c80833a98 100644 (file)
@@ -72,17 +72,7 @@ namespace System.Net.Http.Headers
                                if (parameters == null)
                                        parameters = new List<NameValueHeaderValue> ();
 
-                               var found = parameters.Find (l => string.Equals (l.Name, "charset", StringComparison.OrdinalIgnoreCase));
-                               if (string.IsNullOrEmpty (value)) {
-                                       if (found != null)
-                                               parameters.Remove (found);
-                               } else {
-                                       if (found != null) {
-                                               found.Value = value;
-                                       } else {
-                                               parameters.Add (new NameValueHeaderValue ("charset", value));
-                                       }
-                               }
+                               parameters.SetValue ("charset", value);
                        }
                }
 
index 114b0679894269431148eff245162bcd51c3b99b..840ffbe3567f34dfcd9823a1eb049297ae7a8a22 100644 (file)
@@ -93,6 +93,8 @@ namespace System.Net.Http.Headers
 
                public static class DateTime
                {
+                       public new static readonly Func<object, string> ToString = l => ((DateTimeOffset) l).ToString ("r", CultureInfo.InvariantCulture);
+                       
                        public static bool TryParse (string input, out DateTimeOffset result)
                        {
                                return Lexer.TryGetDateValue (input, out result);
index 673715e02547d9917aa129e124cb5588016251e4..af946481e10add7b74d8e3b893b4e8715a181b8d 100644 (file)
@@ -57,18 +57,7 @@ namespace System.Net.Http.Headers
                        if (parameters == null)
                                parameters = new List<NameValueHeaderValue> ();
 
-                       var found = parameters.Find (l => string.Equals (l.Name, "q", StringComparison.OrdinalIgnoreCase));
-
-                       if (value.HasValue) {
-                               string svalue = value.Value.ToString (NumberFormatInfo.InvariantInfo);
-
-                               if (found == null)
-                                       parameters.Add (new NameValueHeaderValue (new NameValueHeaderValue ("q", svalue)));
-                               else
-                                       found.Value = svalue;
-                       } else {
-                               parameters.Remove (found);
-                       }
+                       parameters.SetValue ("q", value == null ? null : value.Value.ToString (NumberFormatInfo.InvariantInfo));
                }
        }
 }
index f88d6760d53e8e9205e34c73bd63b6c5436cc5be..01f340fe09692c62cf38f982a24c221ad188e1da 100644 (file)
@@ -2,6 +2,8 @@
 Assembly/AssemblyInfo.cs
 System.Net.Http/ByteArrayContent.cs
 System.Net.Http/ClientCertificateOption.cs
+System.Net.Http/DelegatingHandler.cs
+System.Net.Http/FormUrlEncodedContent.cs
 System.Net.Http/HttpClient.cs
 System.Net.Http/HttpClientHandler.cs
 System.Net.Http/HttpCompletionOption.cs
@@ -11,11 +13,15 @@ System.Net.Http/HttpMethod.cs
 System.Net.Http/HttpRequestException.cs
 System.Net.Http/HttpRequestMessage.cs
 System.Net.Http/HttpResponseMessage.cs
+System.Net.Http/MessageProcessingHandler.cs
+System.Net.Http/MultipartContent.cs
+System.Net.Http/MultipartFormDataContent.cs
 System.Net.Http/StreamContent.cs
 System.Net.Http/StringContent.cs
 System.Net.Http.Headers/AuthenticationHeaderValue.cs
 System.Net.Http.Headers/CacheControlHeaderValue.cs
 System.Net.Http.Headers/CollectionExtensions.cs
+System.Net.Http.Headers/ContentDispositionHeaderValue.cs
 System.Net.Http.Headers/ContentRangeHeaderValue.cs
 System.Net.Http.Headers/EntityTagHeaderValue.cs
 System.Net.Http.Headers/HashCodeCalculator.cs
index 13d5c8de7b99055515b280e9921490c2c79d9c00..ab551ee2735eda53f85a205ac3cd72534495e952 100644 (file)
@@ -58,7 +58,12 @@ namespace System.Net.Http
                        this.count = count;
                }
 
-               protected override Task SerializeToStreamAsync (Stream stream, TransportContext context)
+               protected override Task<Stream> CreateContentReadStreamAsync ()
+               {
+                       return Task.FromResult<Stream> (new MemoryStream (content, offset, count));
+               }
+
+               protected internal override Task SerializeToStreamAsync (Stream stream, TransportContext context)
                {
                        return stream.WriteAsync (content, offset, count);
                }
diff --git a/mcs/class/System.Net.Http/System.Net.Http/DelegatingHandler.cs b/mcs/class/System.Net.Http/System.Net.Http/DelegatingHandler.cs
new file mode 100644 (file)
index 0000000..2458975
--- /dev/null
@@ -0,0 +1,67 @@
+//
+// DelegatingHandler.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2011 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.Threading;
+using System.Threading.Tasks;
+
+namespace System.Net.Http
+{
+       public abstract class DelegatingHandler : HttpMessageHandler
+       {
+               bool disposed;
+               
+               protected DelegatingHandler ()
+               {
+               }
+               
+               protected DelegatingHandler(HttpMessageHandler innerHandler)
+               {
+                       if (innerHandler == null)
+                               throw new ArgumentNullException ("innerHandler");
+                       
+                       InnerHandler = innerHandler;
+               }
+               
+               public HttpMessageHandler InnerHandler { get; set; }
+               
+               protected override void Dispose (bool disposing)
+               {
+                       if (disposing && !disposed) {
+                               disposed = true;
+                               InnerHandler.Dispose ();
+                       }
+                       
+                       base.Dispose (disposing);
+               }
+
+               protected internal override Task<HttpResponseMessage> SendAsync (HttpRequestMessage request, CancellationToken cancellationToken)
+               {
+                       return InnerHandler.SendAsync (request, cancellationToken);
+               }
+       }
+}
diff --git a/mcs/class/System.Net.Http/System.Net.Http/FormUrlEncodedContent.cs b/mcs/class/System.Net.Http/System.Net.Http/FormUrlEncodedContent.cs
new file mode 100644 (file)
index 0000000..967b89f
--- /dev/null
@@ -0,0 +1,89 @@
+//
+// FormUrlEncodedContent.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.Collections.Generic;
+using System.Net.Http.Headers;
+using System.Text;
+
+namespace System.Net.Http
+{
+       public class FormUrlEncodedContent : ByteArrayContent
+       {
+               public FormUrlEncodedContent (IEnumerable<KeyValuePair<string, string>> nameValueCollection)
+                       : base (EncodeContent (nameValueCollection))
+               {
+                       Headers.ContentType = new MediaTypeHeaderValue ("application/x-www-form-urlencoded");
+               }
+
+               static byte[] EncodeContent (IEnumerable<KeyValuePair<string, string>> nameValueCollection)
+               {
+                       if (nameValueCollection == null)
+                               throw new ArgumentNullException ("nameValueCollection");
+
+                       //
+                       // Serialization as application/x-www-form-urlencoded
+                       //
+                       // Element nodes selected for inclusion are encoded as EltName=value{sep}, where = is a literal
+                       // character, {sep} is the separator character from the separator attribute on submission,
+                       // EltName represents the element local name, and value represents the contents of the text node.
+                       //
+                       // The encoding of EltName and value are as follows: space characters are replaced by +, and then
+                       // non-ASCII and reserved characters (as defined by [RFC 2396] as amended by subsequent documents
+                       // in the IETF track) are escaped by replacing the character with one or more octets of the UTF-8
+                       // representation of the character, with each octet in turn replaced by %HH, where HH represents
+                       // the uppercase hexadecimal notation for the octet value and % is a literal character. Line breaks
+                       // are represented as "CR LF" pairs (i.e., %0D%0A).
+                       //
+                       var sb = new List<byte> ();
+                       foreach (var item in nameValueCollection) {
+                               if (sb.Count != 0)
+                                       sb.Add ((byte) '&');
+
+                               var data = SerializeValue (item.Key);
+                               if (data != null)
+                                       sb.AddRange (data);
+                               sb.Add ((byte) '=');
+
+                               data = SerializeValue (item.Value);
+                               if (data != null)
+                                       sb.AddRange (data);
+                       }
+
+                       return sb.ToArray ();
+               }
+
+               static byte[] SerializeValue (string value)
+               {
+                       if (value == null)
+                               return null;
+
+                       value = Uri.EscapeDataString (value).Replace ("%20", "+");
+                       return Encoding.ASCII.GetBytes (value);
+               }
+       }
+}
index 92e22982b87b8fe66ff164e4117fb4738ca23bd1..9a4ac95f9e31387f536615040a0a7ba3f3584cbf 100644 (file)
@@ -29,6 +29,7 @@
 using System.Threading;
 using System.Net.Http.Headers;
 using System.Threading.Tasks;
+using System.IO;
 
 namespace System.Net.Http
 {
@@ -252,10 +253,10 @@ namespace System.Net.Http
                                request.Headers.AddHeaders (headers);
                        }
 
-                       return SendAsyncWorker (request, cancellationToken);
+                       return SendAsyncWorker (request, completionOption, cancellationToken);
                }
 
-               async Task<HttpResponseMessage> SendAsyncWorker (HttpRequestMessage request, CancellationToken cancellationToken)
+               async Task<HttpResponseMessage> SendAsyncWorker (HttpRequestMessage request, HttpCompletionOption completionOption, CancellationToken cancellationToken)
                {
                        try {
                                if (cancellation_token == null)
@@ -264,10 +265,21 @@ namespace System.Net.Http
                                using (var cts = CancellationTokenSource.CreateLinkedTokenSource (cancellation_token.Token, cancellationToken)) {
                                        cts.CancelAfter (timeout);
 
-                                       var response = await handler.SendAsync (request, cts.Token).ConfigureAwait (false);
+                                       var task = handler.SendAsync (request, cts.Token);
+                                       if (task == null)
+                                               throw new InvalidOperationException ("Handler failed to return a value");
+                                       
+                                       var response = await task.ConfigureAwait (false);
                                        if (response == null)
                                                throw new InvalidOperationException ("Handler failed to return a response");
 
+                                       //
+                                       // Read the content when default HttpCompletionOption.ResponseContentRead is set
+                                       //
+                                       if (response.Content != null && (completionOption & HttpCompletionOption.ResponseHeadersRead) == 0) {
+                                               await response.Content.LoadIntoBufferAsync (MaxResponseContentBufferSize).ConfigureAwait (false);
+                                       }
+                                       
                                        return response;
                                }
                        } finally {
@@ -275,5 +287,41 @@ namespace System.Net.Http
                                cancellation_token = null;
                        }
                }
+
+               public async Task<byte[]> GetByteArrayAsync (string requestUri)
+               {
+                       var resp = await GetAsync (requestUri, HttpCompletionOption.ResponseContentRead).ConfigureAwait (false);
+                       return await resp.Content.ReadAsByteArrayAsync ().ConfigureAwait (false);
+               }
+
+               public async Task<byte[]> GetByteArrayAsync (Uri requestUri)
+               {
+                       var resp = await GetAsync (requestUri, HttpCompletionOption.ResponseContentRead).ConfigureAwait (false);
+                       return await resp.Content.ReadAsByteArrayAsync ().ConfigureAwait (false);
+               }
+
+               public async Task<Stream> GetStreamAsync (string requestUri)
+               {
+                       var resp = await GetAsync (requestUri, HttpCompletionOption.ResponseContentRead).ConfigureAwait (false);
+                       return await resp.Content.ReadAsStreamAsync ().ConfigureAwait (false);
+               }
+
+               public async Task<Stream> GetStreamAsync (Uri requestUri)
+               {
+                       var resp = await GetAsync (requestUri, HttpCompletionOption.ResponseContentRead).ConfigureAwait (false);
+                       return await resp.Content.ReadAsStreamAsync ().ConfigureAwait (false);
+               }
+
+               public async Task<string> GetStringAsync (string requestUri)
+               {
+                       var resp = await GetAsync (requestUri, HttpCompletionOption.ResponseContentRead).ConfigureAwait (false);
+                       return await resp.Content.ReadAsStringAsync ().ConfigureAwait (false);
+               }
+
+               public async Task<string> GetStringAsync (Uri requestUri)
+               {
+                       var resp = await GetAsync (requestUri, HttpCompletionOption.ResponseContentRead).ConfigureAwait (false);
+                       return await resp.Content.ReadAsStringAsync ().ConfigureAwait (false);
+               }
        }
 }
index 00c1ff0eb9895f0b7ba39826cbfc4c53ff88b254..718af53401725eced2ea626ccf2752692cd247e3 100644 (file)
@@ -46,6 +46,7 @@ namespace System.Net.Http
                bool useCookies;
                bool useDefaultCredentials;
                bool useProxy;
+               ClientCertificateOption certificate;
 
                public HttpClientHandler ()
                {
@@ -74,6 +75,15 @@ namespace System.Net.Http
                        }
                }
 
+               public ClientCertificateOption ClientCertificateOptions {
+                       get {
+                               return certificate;
+                       }
+                       set {
+                               certificate = value;
+                       }
+               }
+
                public CookieContainer CookieContainer {
                        get {
                                return cookieContainer ?? (cookieContainer = new CookieContainer ());
@@ -130,6 +140,9 @@ namespace System.Net.Http
                                return proxy;
                        }
                        set {
+                               if (!UseProxy)
+                                       throw new InvalidOperationException ();
+
                                proxy = value;
                        }
                }
@@ -187,10 +200,8 @@ namespace System.Net.Http
 
                HttpWebRequest CreateWebRequest (HttpRequestMessage request)
                {
-                       //var factory = Activator.CreateInstance (typeof (IWebRequestCreate).Assembly.GetType ("System.Net.HttpRequestCreator"), true) as IWebRequestCreate;
-                       //var wr = (HttpWebRequest) factory.Create (request.RequestUri);
-
                        var wr = new HttpWebRequest (request.RequestUri);
+                       wr.ThrowOnError = false;
 
                        wr.ConnectionGroupName = "HttpClientHandler";
                        wr.Method = request.Method.Method;
@@ -230,11 +241,10 @@ namespace System.Net.Http
                        var headers = wr.Headers;
                        foreach (var header in request.Headers) {
                                foreach (var value in header.Value) {
-                                       // TODO: Have to call simpler Add
-                                       headers.Add (header.Key, value);
+                                       headers.AddValue (header.Key, value);
                                }
                        }
-
+                       
                        return wr;
                }
 
@@ -264,10 +274,18 @@ namespace System.Net.Http
                        var wrequest = CreateWebRequest (request);
 
                        if (request.Content != null) {
-                               throw new NotImplementedException ();
+                               var headers = wrequest.Headers;
+                               foreach (var header in request.Content.Headers) {
+                                       foreach (var value in header.Value) {
+                                               headers.AddValue (header.Key, value);
+                                       }
+                               }
+                               
+                               var stream = wrequest.GetRequestStream ();
+                               await request.Content.CopyToAsync (stream);
                        }
 
-                       // FIXME: Why GetResponseAsync does not accept cancellationToken
+                       // FIXME: GetResponseAsync does not accept cancellationToken
                        var wresponse = (HttpWebResponse) await wrequest.GetResponseAsync ().ConfigureAwait (false);
                        return CreateResponseMessage (wresponse, request);
                }
index 89979a544b6c4aabdeae81aaed0150019f2e4b32..84d65a637e023e839e96603f65348e870eb85b5e 100644 (file)
@@ -35,7 +35,37 @@ namespace System.Net.Http
 {
        public abstract class HttpContent : IDisposable
        {
-               MemoryStream buffer;
+               sealed class FixedMemoryStream : MemoryStream
+               {
+                       readonly int maxSize;
+                       
+                       public FixedMemoryStream (int maxSize)
+                               : base ()
+                       {
+                               this.maxSize = maxSize;
+                       }
+                       
+                       void CheckOverflow (int count)
+                       {
+                               if (Length + count > maxSize)
+                                       throw new HttpRequestException (string.Format ("Cannot write more bytes to the buffer than the configured maximum buffer size: {0}", maxSize));
+                       }
+                       
+                       public override void WriteByte (byte value)
+                       {
+                               CheckOverflow (1);
+                               base.WriteByte (value);
+                       }
+                       
+                       public override void Write (byte[] buffer, int offset, int count)
+                       {
+                               CheckOverflow (count);
+                               base.Write (buffer, offset, count);
+                       }
+               }
+               
+               FixedMemoryStream buffer;
+               Stream stream;
                bool disposed;
                HttpContentHeaders headers;
 
@@ -58,6 +88,17 @@ namespace System.Net.Http
                        return SerializeToStreamAsync (stream, context);
                }
 
+               protected async virtual Task<Stream> CreateContentReadStreamAsync ()
+               {
+                       await LoadIntoBufferAsync ().ConfigureAwait (false);
+                       return buffer;
+               }
+               
+               static FixedMemoryStream CreateFixedMemoryStream (int maxBufferSize)
+               {
+                       return new FixedMemoryStream (maxBufferSize);
+               }
+
                public void Dispose ()
                {
                        Dispose (true);
@@ -86,10 +127,21 @@ namespace System.Net.Http
                        if (buffer != null)
                                return;
 
-                       buffer = new MemoryStream ();
+                       buffer = CreateFixedMemoryStream (maxBufferSize);
                        await SerializeToStreamAsync (buffer, null).ConfigureAwait (false);
                        buffer.Seek (0, SeekOrigin.Begin);
                }
+               
+               public async Task<Stream> ReadAsStreamAsync ()
+               {
+                       if (disposed)
+                               throw new ObjectDisposedException (GetType ().ToString ());
+
+                       if (stream == null)
+                               stream = await CreateContentReadStreamAsync ().ConfigureAwait (false);
+
+                       return stream;
+               }
 
                public async Task<byte[]> ReadAsByteArrayAsync ()
                {
@@ -99,7 +151,7 @@ namespace System.Net.Http
 
                public async Task<string> ReadAsStringAsync ()
                {
-                       await LoadIntoBufferAsync ();
+                       await LoadIntoBufferAsync ().ConfigureAwait (false);
                        if (buffer.Length == 0)
                                return string.Empty;
 
@@ -113,7 +165,7 @@ namespace System.Net.Http
                        return encoding.GetString (buffer.GetBuffer (), 0, (int) buffer.Length);
                }
 
-               protected abstract Task SerializeToStreamAsync (Stream stream, TransportContext context);
+               protected internal abstract Task SerializeToStreamAsync (Stream stream, TransportContext context);
                protected internal abstract bool TryComputeLength (out long length);
        }
 }
index fd4f7c0d080df3a25d395814dedbb6136f4e4ea0..00bee6f66467405242b6b2cb63c422e7426fd2ea 100644 (file)
 
 using System.Collections.Generic;
 using System.Net.Http.Headers;
+using System.Text;
 
 namespace System.Net.Http
 {
        public class HttpRequestMessage : IDisposable
        {
-               HttpContent content;
                HttpRequestHeaders headers;
                HttpMethod method;
                Version version;
@@ -58,14 +58,7 @@ namespace System.Net.Http
                        RequestUri = requestUri;
                }
 
-               public HttpContent Content {
-                       get {
-                               return content;
-                       }
-                       set {
-                               content = value;
-                       }
-               }
+               public HttpContent Content { get; set; }
 
                public HttpRequestHeaders Headers {
                        get {
@@ -138,5 +131,20 @@ namespace System.Net.Http
                        is_used = true;
                        return false;
                }
+               
+               public override string ToString ()
+               {
+                       var sb = new StringBuilder ();
+                       sb.Append ("Method: ").Append (method);
+                       sb.Append (", RequestUri: '").Append (RequestUri != null ? RequestUri.ToString () : "<null>");
+                       sb.Append ("', Version: ").Append (Version);
+                       sb.Append (", Content: ").Append (Content != null ? Content.ToString () : "<null>");
+                       sb.Append (", Headers:\r\n{\r\n").Append (Headers);
+                       if (Content != null)
+                               sb.Append (Content.Headers);
+                       sb.Append ("}");
+                       
+                       return sb.ToString ();
+               }
        }
 }
index 496f53d3365e494065d5e76878002f07cdfa7298..bf39da68917b6f46e58c0c349099a2d4d8cb5ea4 100644 (file)
@@ -27,6 +27,7 @@
 //
 
 using System.Net.Http.Headers;
+using System.Text;
 
 namespace System.Net.Http
 {
@@ -120,5 +121,21 @@ namespace System.Net.Http
 
                        throw new HttpRequestException (string.Format ("{0} ({1})", (int) statusCode, ReasonPhrase));
                }
+               
+               public override string ToString ()
+               {
+                       var sb = new StringBuilder ();
+                       sb.Append ("StatusCode: ").Append ((int)StatusCode);
+                       sb.Append (", ReasonPhrase: '").Append (ReasonPhrase ?? "<null>");
+                       sb.Append ("', Version: ").Append (Version);
+                       sb.Append (", Content: ").Append (Content != null ? Content.ToString () : "<null>");
+                       sb.Append (", Headers:\r\n{\r\n").Append (Headers);
+                       if (Content != null)
+                               sb.Append (Content.Headers);
+                       
+                       sb.Append ("}");
+                       
+                       return sb.ToString ();
+               }
        }
 }
diff --git a/mcs/class/System.Net.Http/System.Net.Http/MessageProcessingHandler.cs b/mcs/class/System.Net.Http/System.Net.Http/MessageProcessingHandler.cs
new file mode 100644 (file)
index 0000000..3fa9db0
--- /dev/null
@@ -0,0 +1,54 @@
+//
+// MessageProcessingHandler.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2011 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.Threading;
+using System.Threading.Tasks;
+
+namespace System.Net.Http
+{
+       public abstract class MessageProcessingHandler : DelegatingHandler
+       {
+               protected MessageProcessingHandler ()
+               {
+               }
+
+               protected MessageProcessingHandler (HttpMessageHandler innerHandler)
+                       : base (innerHandler)
+               {
+               }
+
+               protected abstract HttpRequestMessage ProcessRequest (HttpRequestMessage request, CancellationToken cancellationToken);
+               protected abstract HttpResponseMessage ProcessResponse (HttpResponseMessage response, CancellationToken cancellationToken);
+               
+               protected internal sealed override async Task<HttpResponseMessage> SendAsync (HttpRequestMessage request, CancellationToken cancellationToken)
+               {
+                       request = ProcessRequest (request, cancellationToken);
+                       return ProcessResponse (await base.SendAsync (request, cancellationToken).ConfigureAwait (false), cancellationToken);
+               }
+       }
+}
diff --git a/mcs/class/System.Net.Http/System.Net.Http/MultipartContent.cs b/mcs/class/System.Net.Http/System.Net.Http/MultipartContent.cs
new file mode 100644 (file)
index 0000000..a607167
--- /dev/null
@@ -0,0 +1,220 @@
+//
+// MultipartContent.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.IO;
+using System.Threading.Tasks;
+using System.Collections;
+using System.Collections.Generic;
+using System.Globalization;
+using System.Net.Http.Headers;
+using System.Linq;
+using System.Text;
+
+namespace System.Net.Http
+{
+       public class MultipartContent : HttpContent, IEnumerable<HttpContent>
+       {
+               List<HttpContent> nested_content;
+               readonly string boundary;
+
+               public MultipartContent ()
+                       : this ("mixed")
+               {
+               }
+
+               public MultipartContent (string subtype)
+                       : this (subtype, Guid.NewGuid ().ToString ("D", CultureInfo.InvariantCulture))
+               {
+               }
+
+               public MultipartContent (string subtype, string boundary)
+               {
+                       if (string.IsNullOrWhiteSpace (subtype))
+                               throw new ArgumentException ("boundary");
+
+                       //
+                       // The only mandatory parameter for the multipart Content-Type is the boundary parameter, which consists
+                       // of 1 to 70 characters from a set of characters known to be very robust through email gateways,
+                       // and NOT ending with white space
+                       //
+                       if (string.IsNullOrWhiteSpace (boundary))
+                               throw new ArgumentException ("boundary");
+
+                       if (boundary.Length > 70)
+                               throw new ArgumentOutOfRangeException ("boundary");
+
+                       if (boundary.Last () == ' ' || !IsValidRFC2049 (boundary))
+                               throw new ArgumentException ("boundary");
+
+                       this.boundary = boundary;
+                       this.nested_content = new List<HttpContent> (2);
+
+                       Headers.ContentType = new MediaTypeHeaderValue ("multipart/" + subtype) {
+                               Parameters = { new NameValueHeaderValue ("boundary", "\"" + boundary + "\"") }
+                       };
+               }
+
+               static bool IsValidRFC2049 (string s)
+               {
+                       foreach (char c in s) {
+                               if ((c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || (c >= '0' && c <= '9'))
+                                       continue;
+
+                               switch (c) {
+                               case '\'': case '(': case ')': case '+': case ',':
+                               case '-': case '.': case '/': case ':': case '=':
+                               case '?':
+                                       continue;
+                               }
+
+                               return false;
+                       }
+
+                       return true;
+               }
+
+               public virtual void Add (HttpContent content)
+               {
+                       if (content == null)
+                               throw new ArgumentNullException ("content");
+
+                       if (nested_content == null)
+                               nested_content = new List<HttpContent> ();
+
+                       nested_content.Add (content);
+               }
+
+               protected override void Dispose (bool disposing)
+               {
+                       if (disposing) {
+                               foreach (var item in nested_content) {
+                                       item.Dispose ();
+                               }
+                               
+                               nested_content = null;
+                       }
+                       
+                       base.Dispose (disposing);
+               }
+
+               protected internal override async Task SerializeToStreamAsync (Stream stream, TransportContext context)
+               {
+                       // RFC 2046
+                       //
+                       // The Content-Type field for multipart entities requires one parameter,
+                       // "boundary". The boundary delimiter line is then defined as a line
+                       // consisting entirely of two hyphen characters ("-", decimal value 45)
+                       // followed by the boundary parameter value from the Content-Type header
+                       // field, optional linear whitespace, and a terminating CRLF.
+                       //
+
+                       byte[] buffer;
+                       var sb = new StringBuilder ();
+                       sb.Append ('-').Append ('-');
+                       sb.Append (boundary);
+                       sb.Append ('\r').Append ('\n');
+
+                       for (int i = 0; i < nested_content.Count; i++) {
+                               var c = nested_content [i];
+                                       
+                               foreach (var h in c.Headers) {
+                                       sb.Append (h.Key);
+                                       sb.Append (':').Append (' ');
+                                       foreach (var v in h.Value) {
+                                               sb.Append (v);
+                                       }
+                                       sb.Append ('\r').Append ('\n');
+                               }
+                               sb.Append ('\r').Append ('\n');
+                                       
+                               buffer = Encoding.ASCII.GetBytes (sb.ToString ());
+                               sb.Clear ();
+                               await stream.WriteAsync (buffer, 0, buffer.Length).ConfigureAwait (false);
+
+                               await c.SerializeToStreamAsync (stream, context).ConfigureAwait (false);
+                                       
+                               if (i != nested_content.Count - 1) {
+                                       sb.Append ('\r').Append ('\n');
+                                       sb.Append ('-').Append ('-');
+                                       sb.Append (boundary);
+                                       sb.Append ('\r').Append ('\n');
+                               }
+                       }
+                       
+                       sb.Append ('\r').Append ('\n');
+                       sb.Append ('-').Append ('-');
+                       sb.Append (boundary);
+                       sb.Append ('-').Append ('-');
+                       sb.Append ('\r').Append ('\n');
+
+                       buffer = Encoding.ASCII.GetBytes (sb.ToString ());
+                       await stream.WriteAsync (buffer, 0, buffer.Length).ConfigureAwait (false);
+               }
+               
+               protected internal override bool TryComputeLength (out long length)
+               {
+                       length = 12 + 2 * boundary.Length;
+                       
+                       for (int i = 0; i < nested_content.Count; i++) {
+                               var c = nested_content [i];
+                               foreach (var h in c.Headers) {
+                                       length += h.Key.Length;
+                                       length += 4;
+                                               
+                                       foreach (var v in h.Value) {
+                                               length += v.Length;
+                                       }
+                               }
+                                       
+                               long l;
+                               if (!c.TryComputeLength (out l))
+                                       return false;
+
+                               length += 2;
+                               length += l;
+                                       
+                               if (i != nested_content.Count - 1) {
+                                       length += 6;
+                                       length += boundary.Length;
+                               }
+                       }
+
+                       return true;
+               }
+
+               public IEnumerator<HttpContent> GetEnumerator ()
+               {
+                       return nested_content.GetEnumerator ();
+               }
+
+               IEnumerator IEnumerable.GetEnumerator ()
+               {
+                       return nested_content.GetEnumerator ();
+               }
+       }
+}
diff --git a/mcs/class/System.Net.Http/System.Net.Http/MultipartFormDataContent.cs b/mcs/class/System.Net.Http/System.Net.Http/MultipartFormDataContent.cs
new file mode 100644 (file)
index 0000000..c700ed4
--- /dev/null
@@ -0,0 +1,87 @@
+//
+// MultipartFormDataContent.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.Net.Http.Headers;
+
+namespace System.Net.Http
+{
+       public class MultipartFormDataContent : MultipartContent
+       {
+               public MultipartFormDataContent ()
+                       : base ("form-data")
+               {
+               }
+
+               public MultipartFormDataContent (string boundary)
+                       : base ("form-data", boundary)
+               {
+               }
+               
+               public override void Add (HttpContent content)
+               {
+                       base.Add (content);
+                       AddContentDisposition (content, null, null);
+               }
+
+               public void Add (HttpContent content, string name)
+               {
+                       base.Add (content);
+                       
+                       if (string.IsNullOrWhiteSpace (name))
+                               throw new ArgumentException ("name");
+                       
+                       AddContentDisposition (content, name, null);
+               }
+               
+               public void Add (HttpContent content, string name, string fileName)
+               {
+                       base.Add (content);
+                       
+                       if (string.IsNullOrWhiteSpace (name))
+                               throw new ArgumentException ("name");
+                       
+                       if (string.IsNullOrWhiteSpace (fileName))
+                               throw new ArgumentException ("fileName");
+                       
+                       AddContentDisposition (content, name, fileName);
+               }
+               
+               void AddContentDisposition (HttpContent content, string name, string fileName)
+               {
+                       var headers = content.Headers;
+                       if (headers.ContentDisposition != null)
+                               return;
+                       
+                       headers.ContentDisposition = new ContentDispositionHeaderValue ("form-data") {
+                               Name = name,
+                               FileName = fileName,
+                               FileNameStar = fileName
+                       };
+               }
+       }
+}
index fd51a9717093492c643a80ba77be1ff7a07cbb1e..5bcb104336f4c45f9fff701463d57feca7fe87df 100644 (file)
@@ -53,6 +53,11 @@ namespace System.Net.Http
                        this.bufferSize = bufferSize;
                }
 
+               protected override Task<Stream> CreateContentReadStreamAsync ()
+               {
+                       return Task.FromResult (content);
+               }
+
                protected override void Dispose (bool disposing)
                {
                        if (disposing) {
@@ -62,7 +67,7 @@ namespace System.Net.Http
                        base.Dispose (disposing);
                }
 
-               protected override Task SerializeToStreamAsync (Stream stream, TransportContext context)
+               protected internal override Task SerializeToStreamAsync (Stream stream, TransportContext context)
                {
                        return content.CopyToAsync (stream, bufferSize);
                }
index b582fa43e6862bd53e2caf160842e31395127f07..e5ce8f75050aa04794f336e16578f3531904236a 100644 (file)
@@ -1,13 +1,17 @@
 System.Net.Http/ByteArrayContentTest.cs
+System.Net.Http/FormUrlEncodedContentTest.cs
 System.Net.Http/HttpClientHandlerTest.cs
 System.Net.Http/HttpClientTest.cs
 System.Net.Http/HttpMethodTest.cs
 System.Net.Http/HttpRequestMessageTest.cs
 System.Net.Http/HttpResponseMessageTest.cs
+System.Net.Http/MultipartContentTest.cs
+System.Net.Http/MultipartFormDataContentTest.cs
 System.Net.Http/StreamContentTest.cs
 System.Net.Http/StringContentTest.cs
 System.Net.Http.Headers/AuthenticationHeaderValueTest.cs
 System.Net.Http.Headers/CacheControlHeaderValueTest.cs
+System.Net.Http.Headers/ContentDispositionHeaderValueTest.cs
 System.Net.Http.Headers/ContentRangeHeaderValueTest.cs
 System.Net.Http.Headers/EntityTagHeaderValueTest.cs
 System.Net.Http.Headers/HttpHeadersTest.cs
diff --git a/mcs/class/System.Net.Http/Test/System.Net.Http.Headers/ContentDispositionHeaderValueTest.cs b/mcs/class/System.Net.Http/Test/System.Net.Http.Headers/ContentDispositionHeaderValueTest.cs
new file mode 100644 (file)
index 0000000..f00b41e
--- /dev/null
@@ -0,0 +1,262 @@
+//
+// ContentDispositionHeaderValueTest.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+using System.Collections;
+using System.Collections.Generic;
+using NUnit.Framework;
+using System.Net.Http.Headers;
+using System.Linq;
+
+namespace MonoTests.System.Net.Http.Headers
+{
+       [TestFixture]
+       public class ContentDispositionHeaderValueTest
+       {
+               [Test]
+               public void Ctor_InvalidArguments ()
+               {
+                       try {
+                               new ContentDispositionHeaderValue (null);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new ContentDispositionHeaderValue ("  ");
+                               Assert.Fail ("#2");
+                       } catch (FormatException) {
+                       }
+               }
+
+               [Test]
+               public void Equals ()
+               {
+                       var value = new ContentDispositionHeaderValue ("x");
+                       Assert.AreEqual (value, new ContentDispositionHeaderValue ("x"), "#1");
+                       Assert.AreNotEqual (value, new ContentDispositionHeaderValue ("y"), "#2");
+
+                       value = new ContentDispositionHeaderValue ("attachment");
+                       value.Parameters.Add (new NameValueHeaderValue ("size", "66"));
+
+                       Assert.AreEqual (value, new ContentDispositionHeaderValue ("attachment") { Size = 66 }, "#3");
+                       Assert.AreNotEqual (value, new ContentDispositionHeaderValue ("attachment"), "#4");
+                       Assert.AreNotEqual (value, new ContentDispositionHeaderValue ("attachment") { FileName="g" }, "#5");
+               }
+
+               [Test]
+               public void Parse ()
+               {
+                       var res = ContentDispositionHeaderValue.Parse ("attachment");
+                       Assert.AreEqual ("attachment", res.DispositionType, "#1");
+                       Assert.AreEqual ("attachment", res.ToString (), "#2");
+
+                       res = ContentDispositionHeaderValue.Parse ("attachmen;filename=foo;size=44;  name=n2; filename*=UTF-8''Na%C3%AFve%20file.txt; creation-date=\"Wed, 02 Oct 2002 15:00:00 +0200\";modification-date=\"Wed, 02 Oct 2002 13:00:00 GMT\";read-date=\"Wed, 02 Oct 2002 15:00:00 +0000\";other=1");
+                       Assert.AreEqual (new DateTimeOffset (2002, 10, 2, 15, 0, 0, TimeSpan.FromHours (2)), res.CreationDate, "#10");
+                       Assert.AreEqual ("attachmen", res.DispositionType, "#11");
+                       Assert.AreEqual ("foo", res.FileName, "#12");
+                       Assert.AreEqual ("Naïve file.txt", res.FileNameStar, "#13");
+                       Assert.AreEqual (new DateTimeOffset (2002, 10, 2, 13, 0, 0, TimeSpan.Zero), res.ModificationDate, "#14");
+                       Assert.AreEqual ("n2", res.Name, "#15");
+                       Assert.AreEqual (8, res.Parameters.Count, "#16");
+                       Assert.AreEqual (new DateTimeOffset (2002, 10, 2, 15, 0, 0, TimeSpan.Zero), res.ReadDate, "#17");
+                       Assert.AreEqual (44, res.Size, "#18");
+                       Assert.AreEqual ("attachmen; filename=foo; size=44; name=n2; filename*=UTF-8''Na%C3%AFve%20file.txt; creation-date=\"Wed, 02 Oct 2002 15:00:00 +0200\"; modification-date=\"Wed, 02 Oct 2002 13:00:00 GMT\"; read-date=\"Wed, 02 Oct 2002 15:00:00 +0000\"; other=1", res.ToString (), "#19");
+
+                       res = ContentDispositionHeaderValue.Parse ("attachment; filename='foo.bar'");
+                       Assert.AreEqual ("attachment", res.DispositionType, "#21");
+                       Assert.AreEqual ("'foo.bar'", res.FileName, "#22");
+                       Assert.AreEqual ("attachment; filename='foo.bar'", res.ToString (), "#23");
+
+                       ContentDispositionHeaderValue.Parse ("aa;size=a4");
+
+                       res = ContentDispositionHeaderValue.Parse ("att;filename=\"=?utf-8?B?xI0=?=\"");
+                       Assert.AreEqual ("č", res.FileName, "#31");
+                       Assert.IsNull (res.FileNameStar, "#32");
+
+                       res = ContentDispositionHeaderValue.Parse ("att;filename=\"=?utf-?B?xI0=?=\"");
+                       Assert.AreEqual ("\"=?utf-?B?xI0=?=\"", res.FileName, "#41");
+
+                       res = ContentDispositionHeaderValue.Parse ("att;filename=\"=?utf-16?b?xI0=?=\"");
+                       Assert.AreEqual ("跄", res.FileName, "#51");
+
+                       res = ContentDispositionHeaderValue.Parse ("att;filename=\"=?utf-8?B?x/I0=?=\"");
+                       Assert.AreEqual ("\"=?utf-8?B?x/I0=?=\"", res.FileName, "#61");
+
+                       res = ContentDispositionHeaderValue.Parse ("att;filename*=utf-8''%C4%8Eas");
+                       Assert.AreEqual ("Ďas", res.FileNameStar, "#71");
+
+                       res = ContentDispositionHeaderValue.Parse ("att;filename*=btf-8''%C4%8E");
+                       Assert.IsNull (res.FileNameStar, "#72");
+
+                       res = ContentDispositionHeaderValue.Parse ("att;filename*=utf-8''%T4%8O%");
+                       Assert.AreEqual ("%T4%8O%", res.FileNameStar, "#73");
+               }
+
+               [Test]
+               public void Parse_Invalid ()
+               {
+                       try {
+                               ContentDispositionHeaderValue.Parse (null);
+                               Assert.Fail ("#1");
+                       } catch (FormatException) {
+                       }
+
+                       try {
+                               ContentDispositionHeaderValue.Parse ("  ");
+                               Assert.Fail ("#2");
+                       } catch (FormatException) {
+                       }
+
+                       try {
+                               ContentDispositionHeaderValue.Parse ("attachment; filename=foo.html ;");
+                               Assert.Fail ("#3");
+                       } catch (FormatException) {
+                       }
+
+                       try {
+                               ContentDispositionHeaderValue.Parse ("attachment; filename=foo bar.html");
+                               Assert.Fail ("#4");
+                       } catch (FormatException) {
+                       }
+
+                       try {
+                               ContentDispositionHeaderValue.Parse ("\"attachment\"");
+                               Assert.Fail ("#5");
+                       } catch (FormatException) {
+                       }
+
+                       try {
+                               ContentDispositionHeaderValue.Parse ("att;filename*=utf-8''%T4%8╗");
+                               Assert.Fail ("#6");
+                       } catch (FormatException) {
+                       }
+               }
+
+               [Test]
+               public void Properties ()
+               {
+                       var value = new ContentDispositionHeaderValue ("ttt");
+                       Assert.IsNull (value.CreationDate, "#1");
+                       Assert.AreEqual ("ttt", value.DispositionType, "#2");
+                       Assert.IsNull (value.FileName, "#3");
+                       Assert.IsNull (value.FileNameStar, "#4");
+                       Assert.IsNull (value.ModificationDate, "#5");
+                       Assert.IsNull (value.Name, "#6");
+                       Assert.AreEqual (0, value.Parameters.Count, "#7");
+                       Assert.IsNull (value.ReadDate, "#8");
+                       Assert.IsNull (value.Size, "#9");
+
+                       value.Parameters.Add (new NameValueHeaderValue ("creation-date", "\"20 Jun 82 11:34:11\""));
+                       value.Parameters.Add (new NameValueHeaderValue ("filename", "g*"));
+                       value.Parameters.Add (new NameValueHeaderValue ("filename*", "ag*"));
+                       value.Parameters.Add (new NameValueHeaderValue ("modification-date", "\"20 Jun 22 4:6:22\""));
+                       value.Parameters.Add (new NameValueHeaderValue ("name", "nnn"));
+                       value.Parameters.Add (new NameValueHeaderValue ("read-date", "\"1 Jun 01 1:1:1\""));
+                       value.Parameters.Add (new NameValueHeaderValue ("size", "5"));
+
+                       Assert.AreEqual (new DateTimeOffset (1982, 6, 20, 11, 34, 11, TimeSpan.Zero), value.CreationDate, "#11");
+                       Assert.AreEqual ("g*", value.FileName, "#12");
+                       Assert.IsNull (value.FileNameStar, "#13");
+                       Assert.AreEqual (new DateTimeOffset (2022, 6, 20, 4, 6, 22, TimeSpan.Zero), value.ModificationDate, "#14");
+                       Assert.AreEqual ("nnn", value.Name, "#15");
+                       Assert.AreEqual (new DateTimeOffset (2001, 6, 1, 1, 1, 1, TimeSpan.Zero), value.ReadDate, "#16");
+                       Assert.AreEqual (5, value.Size, "#17");
+               }
+
+               [Test]
+               public void Properties_FileName ()
+               {
+                       var value = new ContentDispositionHeaderValue ("a");
+
+                       value.FileName = "aa";
+                       Assert.AreEqual ("aa", value.FileName, "#1");
+                       Assert.AreEqual (new NameValueHeaderValue ("filename", "aa"), value.Parameters.First (), "#2");
+
+                       value.FileName = "č";
+                       Assert.AreEqual ("č", value.FileName, "#11");
+                       Assert.AreEqual (new NameValueHeaderValue ("filename", "\"=?utf-8?B?xI0=?=\""), value.Parameters.First (), "#12");
+
+                       value.FileName = "(@)";
+                       Assert.AreEqual ("\"(@)\"", value.FileName, "#21");
+                       Assert.AreEqual (new NameValueHeaderValue ("filename", "\"(@)\""), value.Parameters.First (), "#22");
+               }
+
+               [Test]
+               public void Properties_FileNameStar ()
+               {
+                       var value = new ContentDispositionHeaderValue ("a");
+
+                       value.FileNameStar = "aa";
+                       Assert.AreEqual ("aa", value.FileNameStar, "#1");
+                       Assert.AreEqual (new NameValueHeaderValue ("filename*", "utf-8''aa"), value.Parameters.First (), "#2");
+
+                       value.FileNameStar = "č";
+                       Assert.AreEqual ("č", value.FileNameStar, "#11");
+                       Assert.AreEqual (new NameValueHeaderValue ("filename*", "utf-8''%C4%8D"), value.Parameters.First (), "#12");
+               }
+
+               [Test]
+               public void Properties_ModificationDate ()
+               {
+                       var value = new ContentDispositionHeaderValue ("a");
+
+                       value.ModificationDate = new DateTimeOffset (2010, 12, 30, 22, 34, 2, TimeSpan.Zero); //.FromHours (-3));
+                       Assert.AreEqual (new DateTimeOffset (2010, 12, 30, 22, 34, 2, TimeSpan.Zero), value.ModificationDate, "#1");
+                       Assert.AreEqual (new NameValueHeaderValue ("modification-date", "\"Thu, 30 Dec 2010 22:34:02 GMT\""), value.Parameters.First (), "#2");
+               }
+
+               [Test]
+               public void Properties_Invalid ()
+               {
+                       var value = new ContentDispositionHeaderValue ("a");
+                       try {
+                               value.Size = -9;
+                               Assert.Fail ("#1");
+                       } catch (ArgumentOutOfRangeException) {
+                       }
+               }
+
+               [Test]
+               public void TryParse ()
+               {
+                       ContentDispositionHeaderValue res;
+                       Assert.IsTrue (ContentDispositionHeaderValue.TryParse ("attachment; filename*0*=ISO-8859-15''euro-sign%3d%a4; filename*=ISO-8859-1''currency-sign%3d%a4", out res), "#1");
+                       Assert.AreEqual ("attachment", res.DispositionType, "#2");
+                       Assert.AreEqual ("currency-sign=¤", res.FileNameStar, "#3");
+               }
+
+               [Test]
+               public void TryParse_Invalid ()
+               {
+                       ContentDispositionHeaderValue res;
+                       Assert.IsFalse (ContentDispositionHeaderValue.TryParse ("", out res), "#1");
+                       Assert.IsNull (res, "#2");
+               }
+       }
+}
index 591aaa6c322feee096d75c2ccb661155cd1dbac2..afbf8274b9fca923bb9e1f78817ebf5b20925a39 100644 (file)
@@ -77,10 +77,10 @@ namespace MonoTests.System.Net.Http.Headers
                        Assert.IsNull (res.CharSet, "#1b");
                        Assert.AreEqual ("multipart/b*", res.ToString (), "#1c");
 
-                       res = MediaTypeHeaderValue.Parse ("mu / m; CHarset=jj  ");
+                       res = MediaTypeHeaderValue.Parse ("mu / m; CHarset=jj'  ");
                        Assert.AreEqual ("mu/m", res.MediaType, "#2");
-                       Assert.AreEqual ("jj", res.CharSet, "#2b");
-                       Assert.AreEqual ("mu/m; CHarset=jj", res.ToString (), "#2c");
+                       Assert.AreEqual ("jj'", res.CharSet, "#2b");
+                       Assert.AreEqual ("mu/m; CHarset=jj'", res.ToString (), "#2c");
                }
 
                [Test]
index a831f148bedb3fc75dc6480696b993cc28830643..24101a2ce61a1970fba20c187cb162c5fc6c2e79 100644 (file)
@@ -96,7 +96,7 @@ namespace MonoTests.System.Net.Http
 
                        var dest = new MemoryStream ();
                        var task = sc.CopyToAsync (dest);
-                       task.Wait ();
+                       Assert.IsTrue (task.Wait (500));
                        Assert.AreEqual (2, dest.Length, "#1");
                }
 
@@ -107,7 +107,7 @@ namespace MonoTests.System.Net.Http
 
                        var sc = new ByteArrayContent (b);
                        var t = sc.LoadIntoBufferAsync (400);
-                       t.Wait ();
+                       Assert.IsTrue (t.Wait (500));
                }
 
                [Test]
diff --git a/mcs/class/System.Net.Http/Test/System.Net.Http/FormUrlEncodedContentTest.cs b/mcs/class/System.Net.Http/Test/System.Net.Http/FormUrlEncodedContentTest.cs
new file mode 100644 (file)
index 0000000..dcae90f
--- /dev/null
@@ -0,0 +1,84 @@
+//
+// FormUrlEncodedContentTest.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+using NUnit.Framework;
+using System.Net.Http;
+using System.IO;
+using System.Threading.Tasks;
+using System.Collections.Generic;
+
+namespace MonoTests.System.Net.Http
+{
+       [TestFixture]
+       public class FormUrlEncodedContentTest
+       {
+               [Test]
+               public void Ctor_Invalid ()
+               {
+                       try {
+                               new FormUrlEncodedContent (null);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentNullException) {
+                       }
+               }
+
+               [Test]
+               public void Ctor ()
+               {
+                       var s = new List<KeyValuePair<string, string>> () {
+                               new KeyValuePair<string, string> ("key", "44"),
+                               new KeyValuePair<string, string> ("key 2", "&+/Ž@:=")
+                       };
+
+                       using (var m = new FormUrlEncodedContent (s)) {
+                               Assert.AreEqual ("application/x-www-form-urlencoded", m.Headers.ContentType.MediaType, "#1");
+                               Assert.AreEqual (37, m.Headers.ContentLength, "#2");
+                               Assert.AreEqual ("key=44&key+2=%26%2B%2F%C5%BD%40%3A%3D", m.ReadAsStringAsync ().Result, "#3");
+                       }
+
+                       s = new List<KeyValuePair<string, string>> ();
+                       using (var m = new FormUrlEncodedContent (s)) {
+                               Assert.AreEqual ("application/x-www-form-urlencoded", m.Headers.ContentType.MediaType, "#11");
+                               Assert.AreEqual (0, m.Headers.ContentLength, "#12");
+                               Assert.AreEqual ("", m.ReadAsStringAsync ().Result, "#13");
+                       }
+
+                       s = new List<KeyValuePair<string, string>> () {
+                               new KeyValuePair<string, string> ( "key", ""),
+                               new KeyValuePair<string, string> ( "key+ 2", null)
+                       };
+
+                       using (var m = new FormUrlEncodedContent (s)) {
+                               Assert.AreEqual ("application/x-www-form-urlencoded", m.Headers.ContentType.MediaType, "#21");
+                               Assert.AreEqual (14, m.Headers.ContentLength, "#22");
+                               Assert.AreEqual ("key=&key%2B+2=", m.ReadAsStringAsync ().Result, "#23");
+                       }
+               }
+       }
+}
index e02db43791908b370e40341f76108c842f5d4f8a..fc778fabf5a8b24b632b8209d82fd8d7661ced98 100644 (file)
@@ -38,6 +38,28 @@ namespace MonoTests.System.Net.Http
        [TestFixture]
        public class HttpClientHandlerTest
        {
+               class Proxy : IWebProxy
+               {
+                       public ICredentials Credentials {
+                               get {
+                                       throw new NotImplementedException ();
+                               }
+                               set {
+                                       throw new NotImplementedException ();
+                               }
+                       }
+
+                       public Uri GetProxy (Uri destination)
+                       {
+                               throw new NotImplementedException ();
+                       }
+
+                       public bool IsBypassed (Uri host)
+                       {
+                               throw new NotImplementedException ();
+                       }
+               }
+
                [Test]
                public void Properties_Defaults ()
                {
@@ -57,6 +79,7 @@ namespace MonoTests.System.Net.Http
                        Assert.IsTrue (h.UseCookies, "#12");
                        Assert.IsFalse (h.UseDefaultCredentials, "#13");
                        Assert.IsTrue (h.UseProxy, "#14");
+                       Assert.AreEqual (ClientCertificateOption.Manual, h.ClientCertificateOptions, "#15");
                }
 
                [Test]
@@ -75,6 +98,12 @@ namespace MonoTests.System.Net.Http
                        } catch (ArgumentOutOfRangeException) {
                        }
 
+                       h.UseProxy = false;
+                       try {
+                               h.Proxy = new Proxy ();
+                               Assert.Fail ("#3");
+                       } catch (InvalidOperationException) {
+                       }
                }
        }
 }
index ffcc0d2a46d41df8ac3c4fe8e86fd3b79e8f680b..90c8a2d54f905f2c14337a9abc3a389afeba4910 100644 (file)
@@ -41,7 +41,6 @@ using System.IO;
 namespace MonoTests.System.Net.Http
 {
        [TestFixture]
-//     [Ignore]
        public class HttpClientTest
        {
                class HttpMessageHandlerMock : HttpMessageHandler
@@ -182,7 +181,6 @@ namespace MonoTests.System.Net.Http
                }
 
                [Test]
-               [Ignore]
                public void Send ()
                {
                        var mh = new HttpMessageHandlerMock ();
@@ -222,31 +220,34 @@ namespace MonoTests.System.Net.Http
                }
 
                [Test]
-               [Ignore]
                public void Send_Complete_Default ()
                {
+                       bool? failed = null;
                        var listener = CreateListener (l => {
-                               var request = l.Request;
-
-                               Assert.IsNull (request.AcceptTypes, "#1");
-                               Assert.AreEqual (0, request.ContentLength64, "#2");
-                               Assert.IsNull (request.ContentType, "#3");
-                               Assert.AreEqual (0, request.Cookies.Count, "#4");
-                               Assert.IsFalse (request.HasEntityBody, "#5");
-                               Assert.AreEqual (2, request.Headers.Count, "#6");
-                               Assert.AreEqual ("Keep-Alive", request.Headers["Connection"], "#6a");
-                               Assert.AreEqual (TestHost, request.Headers["Host"], "#6b");
-                               Assert.AreEqual ("GET", request.HttpMethod, "#7");
-                               Assert.IsFalse (request.IsAuthenticated, "#8");
-                               Assert.IsTrue (request.IsLocal, "#9");
-                               Assert.IsFalse (request.IsSecureConnection, "#10");
-                               Assert.IsFalse (request.IsWebSocketRequest, "#11");
-                               Assert.IsTrue (request.KeepAlive, "#12");
-                               Assert.AreEqual (HttpVersion.Version11, request.ProtocolVersion, "#13");
-                               Assert.IsNull (request.ServiceName, "#14");
-                               Assert.IsNull (request.UrlReferrer, "#15");
-                               Assert.IsNull (request.UserAgent, "#16");
-                               Assert.IsNull (request.UserLanguages, "#17");
+                               try {
+                                       var request = l.Request;
+       
+                                       Assert.IsNull (request.AcceptTypes, "#1");
+                                       Assert.AreEqual (0, request.ContentLength64, "#2");
+                                       Assert.IsNull (request.ContentType, "#3");
+                                       Assert.AreEqual (0, request.Cookies.Count, "#4");
+                                       Assert.IsFalse (request.HasEntityBody, "#5");
+                                       Assert.AreEqual (TestHost, request.Headers["Host"], "#6b");
+                                       Assert.AreEqual ("GET", request.HttpMethod, "#7");
+                                       Assert.IsFalse (request.IsAuthenticated, "#8");
+                                       Assert.IsTrue (request.IsLocal, "#9");
+                                       Assert.IsFalse (request.IsSecureConnection, "#10");
+                                       Assert.IsFalse (request.IsWebSocketRequest, "#11");
+                                       Assert.IsTrue (request.KeepAlive, "#12");
+                                       Assert.AreEqual (HttpVersion.Version11, request.ProtocolVersion, "#13");
+                                       Assert.IsNull (request.ServiceName, "#14");
+                                       Assert.IsNull (request.UrlReferrer, "#15");
+                                       Assert.IsNull (request.UserAgent, "#16");
+                                       Assert.IsNull (request.UserLanguages, "#17");
+                                       failed = false;
+                               } catch {
+                                       failed = true;
+                               }
                        });
 
                        try {
@@ -256,6 +257,7 @@ namespace MonoTests.System.Net.Http
 
                                Assert.AreEqual ("", response.Content.ReadAsStringAsync ().Result, "#100");
                                Assert.AreEqual (HttpStatusCode.OK, response.StatusCode, "#101");
+                               Assert.AreEqual (false, failed, "#102");
                        } finally {
                                listener.Close ();
                        }
@@ -264,27 +266,34 @@ namespace MonoTests.System.Net.Http
                [Test]
                public void Send_Complete_Version_1_0 ()
                {
+                       bool? failed = null;
+                       
                        var listener = CreateListener (l => {
-                               var request = l.Request;
-
-                               Assert.IsNull (request.AcceptTypes, "#1");
-                               Assert.AreEqual (0, request.ContentLength64, "#2");
-                               Assert.IsNull (request.ContentType, "#3");
-                               Assert.AreEqual (0, request.Cookies.Count, "#4");
-                               Assert.IsFalse (request.HasEntityBody, "#5");
-                               Assert.AreEqual (1, request.Headers.Count, "#6");
-                               Assert.AreEqual (TestHost, request.Headers["Host"], "#6a");
-                               Assert.AreEqual ("GET", request.HttpMethod, "#7");
-                               Assert.IsFalse (request.IsAuthenticated, "#8");
-                               Assert.IsTrue (request.IsLocal, "#9");
-                               Assert.IsFalse (request.IsSecureConnection, "#10");
-                               Assert.IsFalse (request.IsWebSocketRequest, "#11");
-                               Assert.IsFalse (request.KeepAlive, "#12");
-                               Assert.AreEqual (HttpVersion.Version10, request.ProtocolVersion, "#13");
-                               Assert.IsNull (request.ServiceName, "#14");
-                               Assert.IsNull (request.UrlReferrer, "#15");
-                               Assert.IsNull (request.UserAgent, "#16");
-                               Assert.IsNull (request.UserLanguages, "#17");
+                               try {
+                                       var request = l.Request;
+       
+                                       Assert.IsNull (request.AcceptTypes, "#1");
+                                       Assert.AreEqual (0, request.ContentLength64, "#2");
+                                       Assert.IsNull (request.ContentType, "#3");
+                                       Assert.AreEqual (0, request.Cookies.Count, "#4");
+                                       Assert.IsFalse (request.HasEntityBody, "#5");
+                                       Assert.AreEqual (1, request.Headers.Count, "#6");
+                                       Assert.AreEqual (TestHost, request.Headers["Host"], "#6a");
+                                       Assert.AreEqual ("GET", request.HttpMethod, "#7");
+                                       Assert.IsFalse (request.IsAuthenticated, "#8");
+                                       Assert.IsTrue (request.IsLocal, "#9");
+                                       Assert.IsFalse (request.IsSecureConnection, "#10");
+                                       Assert.IsFalse (request.IsWebSocketRequest, "#11");
+                                       Assert.IsFalse (request.KeepAlive, "#12");
+                                       Assert.AreEqual (HttpVersion.Version10, request.ProtocolVersion, "#13");
+                                       Assert.IsNull (request.ServiceName, "#14");
+                                       Assert.IsNull (request.UrlReferrer, "#15");
+                                       Assert.IsNull (request.UserAgent, "#16");
+                                       Assert.IsNull (request.UserLanguages, "#17");
+                                       failed = false;
+                               } catch {
+                                       failed = true;
+                               }
                        });
 
                        try {
@@ -295,39 +304,46 @@ namespace MonoTests.System.Net.Http
 
                                Assert.AreEqual ("", response.Content.ReadAsStringAsync ().Result, "#100");
                                Assert.AreEqual (HttpStatusCode.OK, response.StatusCode, "#101");
+                               Assert.AreEqual (false, failed, "#102");
                        } finally {
                                listener.Close ();
                        }
                }
 
                [Test]
-               [Ignore]
                public void Send_Complete_ClientHandlerSettings ()
                {
+                       bool? failed = null;
+                       
                        var listener = CreateListener (l => {
                                var request = l.Request;
-
-                               Assert.IsNull (request.AcceptTypes, "#1");
-                               Assert.AreEqual (0, request.ContentLength64, "#2");
-                               Assert.IsNull (request.ContentType, "#3");
-                               Assert.AreEqual (1, request.Cookies.Count, "#4");
-                               Assert.AreEqual (new Cookie ("mycookie", "vv"), request.Cookies[0], "#4a");
-                               Assert.IsFalse (request.HasEntityBody, "#5");
-                               Assert.AreEqual (3, request.Headers.Count, "#6");
-                               Assert.AreEqual (TestHost, request.Headers["Host"], "#6a");
-                               Assert.AreEqual ("gzip", request.Headers["Accept-Encoding"], "#6b");
-                               Assert.AreEqual ("mycookie=vv", request.Headers["Cookie"], "#6c");
-                               Assert.AreEqual ("GET", request.HttpMethod, "#7");
-                               Assert.IsFalse (request.IsAuthenticated, "#8");
-                               Assert.IsTrue (request.IsLocal, "#9");
-                               Assert.IsFalse (request.IsSecureConnection, "#10");
-                               Assert.IsFalse (request.IsWebSocketRequest, "#11");
-                               Assert.IsFalse (request.KeepAlive, "#12");
-                               Assert.AreEqual (HttpVersion.Version10, request.ProtocolVersion, "#13");
-                               Assert.IsNull (request.ServiceName, "#14");
-                               Assert.IsNull (request.UrlReferrer, "#15");
-                               Assert.IsNull (request.UserAgent, "#16");
-                               Assert.IsNull (request.UserLanguages, "#17");
+                               
+                               try {
+                                       Assert.IsNull (request.AcceptTypes, "#1");
+                                       Assert.AreEqual (0, request.ContentLength64, "#2");
+                                       Assert.IsNull (request.ContentType, "#3");
+                                       Assert.AreEqual (1, request.Cookies.Count, "#4");
+                                       Assert.AreEqual (new Cookie ("mycookie", "vv"), request.Cookies[0], "#4a");
+                                       Assert.IsFalse (request.HasEntityBody, "#5");
+                                       Assert.AreEqual (4, request.Headers.Count, "#6");
+                                       Assert.AreEqual (TestHost, request.Headers["Host"], "#6a");
+                                       Assert.AreEqual ("gzip", request.Headers["Accept-Encoding"], "#6b");
+                                       Assert.AreEqual ("mycookie=vv", request.Headers["Cookie"], "#6c");
+                                       Assert.AreEqual ("GET", request.HttpMethod, "#7");
+                                       Assert.IsFalse (request.IsAuthenticated, "#8");
+                                       Assert.IsTrue (request.IsLocal, "#9");
+                                       Assert.IsFalse (request.IsSecureConnection, "#10");
+                                       Assert.IsFalse (request.IsWebSocketRequest, "#11");
+                                       Assert.IsTrue (request.KeepAlive, "#12");
+                                       Assert.AreEqual (HttpVersion.Version10, request.ProtocolVersion, "#13");
+                                       Assert.IsNull (request.ServiceName, "#14");
+                                       Assert.IsNull (request.UrlReferrer, "#15");
+                                       Assert.IsNull (request.UserAgent, "#16");
+                                       Assert.IsNull (request.UserLanguages, "#17");
+                                       failed = false;
+                               } catch {
+                                       failed = true;
+                               }
                        });
 
                        try {
@@ -346,46 +362,54 @@ namespace MonoTests.System.Net.Http
                                var client = new HttpClient (chandler);
                                var request = new HttpRequestMessage (HttpMethod.Get, LocalServer);
                                request.Version = HttpVersion.Version10;
+                               request.Headers.Add ("Keep-Alive", "false");
                                var response = client.SendAsync (request, HttpCompletionOption.ResponseHeadersRead).Result;
 
                                Assert.AreEqual ("", response.Content.ReadAsStringAsync ().Result, "#100");
                                Assert.AreEqual (HttpStatusCode.OK, response.StatusCode, "#101");
+                               Assert.AreEqual (false, failed, "#102");
                        } finally {
+                               listener.Abort ();
                                listener.Close ();
                        }
                }
 
                [Test]
-               [Ignore]
                public void Send_Complete_CustomHeaders ()
                {
+                       bool? failed = null;
+                       
                        var listener = CreateListener (l => {
                                var request = l.Request;
-                               Assert.AreEqual ("vv", request.Headers["aa"], "#1");
-                               Assert.AreEqual (3, request.Headers.Count, "#3");
-
-                               var response = l.Response;
-                               response.Headers.Add ("rsp", "rrr");
-                               response.Headers.Add ("upgrade", "vvvvaa");
-                               response.Headers.Add ("date", "aa");
-                               response.Headers.Add ("cache-control", "audio");
-
-                               response.StatusDescription = "test description";
-                               response.ProtocolVersion = HttpVersion.Version10;
-                               response.SendChunked = true;
-                               response.RedirectLocation = "w3.org";
+                               try {
+                                       Assert.AreEqual ("vv", request.Headers["aa"], "#1");
+       
+                                       var response = l.Response;
+                                       response.Headers.Add ("rsp", "rrr");
+                                       response.Headers.Add ("upgrade", "vvvvaa");
+                                       response.Headers.Add ("Date", "aa");
+                                       response.Headers.Add ("cache-control", "audio");
+       
+                                       response.StatusDescription = "test description";
+                                       response.ProtocolVersion = HttpVersion.Version10;
+                                       response.SendChunked = true;
+                                       response.RedirectLocation = "w3.org";
+                                       
+                                       failed = false;
+                               } catch {
+                                       failed = true;
+                               }
                        });
 
                        try {
                                var client = new HttpClient ();
                                var request = new HttpRequestMessage (HttpMethod.Get, LocalServer);
                                request.Headers.AddWithoutValidation ("aa", "vv");
-//                             request.Headers.Range = new RangeHeaderValue (3, 20);
                                var response = client.SendAsync (request, HttpCompletionOption.ResponseHeadersRead).Result;
 
                                Assert.AreEqual ("", response.Content.ReadAsStringAsync ().Result, "#100");
                                Assert.AreEqual (HttpStatusCode.OK, response.StatusCode, "#101");
-
+                               
                                IEnumerable<string> values;
                                Assert.IsTrue (response.Headers.TryGetValues ("rsp", out values), "#102");
                                Assert.AreEqual ("rrr", values.First (), "#102a");
@@ -395,8 +419,9 @@ namespace MonoTests.System.Net.Http
                                Assert.AreEqual (true, response.Headers.TransferEncodingChunked, "#103b");
 
                                Assert.IsTrue (response.Headers.TryGetValues ("Date", out values), "#104");
-                               Assert.AreEqual (2, values.Count (), "#104b");
-                               Assert.IsNull (response.Headers.Date, "#104c");
+                               Assert.AreEqual (1, values.Count (), "#104b");
+                               // .NET overwrites Date, Mono does not
+                               // Assert.IsNotNull (response.Headers.Date, "#104c");
 
                                Assert.AreEqual (new ProductHeaderValue ("vvvvaa"), response.Headers.Upgrade.First (), "#105");
 
@@ -406,6 +431,83 @@ namespace MonoTests.System.Net.Http
 
                                Assert.AreEqual ("test description", response.ReasonPhrase, "#110");
                                Assert.AreEqual (HttpVersion.Version11, response.Version, "#111");
+                               
+                               Assert.AreEqual (false, failed, "#112");
+                       } finally {
+                               listener.Close ();
+                       }
+               }
+
+               [Test]
+               public void Send_Complete_Content ()
+               {
+                       var listener = CreateListener (l => {
+                               var request = l.Request;
+                               l.Response.OutputStream.WriteByte (55);
+                               l.Response.OutputStream.WriteByte (75);
+                       });
+
+                       try {
+                               var client = new HttpClient ();
+                               var request = new HttpRequestMessage (HttpMethod.Get, LocalServer);
+                               request.Headers.AddWithoutValidation ("aa", "vv");
+                               var response = client.SendAsync (request, HttpCompletionOption.ResponseHeadersRead).Result;
+
+                               Assert.AreEqual ("7K", response.Content.ReadAsStringAsync ().Result, "#100");
+                               Assert.AreEqual (HttpStatusCode.OK, response.StatusCode, "#101");
+
+                               IEnumerable<string> values;
+                               Assert.IsTrue (response.Headers.TryGetValues ("Transfer-Encoding", out values), "#102");
+                               Assert.AreEqual ("chunked", values.First (), "#102a");
+                               Assert.AreEqual (true, response.Headers.TransferEncodingChunked, "#102b");
+                       } finally {
+                               listener.Close ();
+                       }
+               }
+
+               [Test]
+               public void Send_Complete_Content_MaxResponseContentBufferSize ()
+               {
+                       var listener = CreateListener (l => {
+                               var request = l.Request;
+                               var b = new byte[4000];
+                               l.Response.OutputStream.Write (b, 0, b.Length);
+                       });
+
+                       try {
+                               var client = new HttpClient ();
+                               client.MaxResponseContentBufferSize = 1000;
+                               var request = new HttpRequestMessage (HttpMethod.Get, LocalServer);
+                               var response = client.SendAsync (request, HttpCompletionOption.ResponseHeadersRead).Result;
+
+                               Assert.AreEqual (4000, response.Content.ReadAsStringAsync ().Result.Length, "#100");
+                               Assert.AreEqual (HttpStatusCode.OK, response.StatusCode, "#101");
+                       } finally {
+                               listener.Close ();
+                       }
+               }
+
+               [Test]
+               public void Send_Complete_Content_MaxResponseContentBufferSize_Error ()
+               {
+                       var listener = CreateListener (l => {
+                               var request = l.Request;
+                               var b = new byte[4000];
+                               l.Response.OutputStream.Write (b, 0, b.Length);
+                       });
+
+                       try {
+                               var client = new HttpClient ();
+                               client.MaxResponseContentBufferSize = 1000;
+                               var request = new HttpRequestMessage (HttpMethod.Get, LocalServer);
+
+                               try {
+                                       client.SendAsync (request, HttpCompletionOption.ResponseContentRead).Wait ();
+                                       Assert.Fail ("#2");
+                               } catch (AggregateException e) {
+                                       Assert.IsInstanceOfType (typeof (HttpRequestException), e.InnerException, "#3");
+                               }
+
                        } finally {
                                listener.Close ();
                        }
@@ -512,7 +614,6 @@ namespace MonoTests.System.Net.Http
                }
 
                [Test]
-               [Ignore]
                public void Send_InvalidHandler ()
                {
                        var mh = new HttpMessageHandlerMock ();
@@ -527,10 +628,10 @@ namespace MonoTests.System.Net.Http
                        };
 
                        try {
-                               // Broken on .net because of return null
+                               // Broken by design
                                client.SendAsync (request).Wait ();
                                Assert.Fail ("#2");
-                       } catch (InvalidOperationException) {
+                       } catch (Exception) {
                        }
                }
 
index 45a499802547a8e3f5a1a9ba53ed596c97117023..8dacdefb9aaf17a95c65ea14e2e963f6c8adb00f 100644 (file)
@@ -60,6 +60,8 @@ namespace MonoTests.System.Net.Http
                        Assert.IsNotNull (m.Properties, "#4");
                        Assert.IsNull (m.RequestUri, "#5");
                        Assert.AreEqual (new Version (1, 1), m.Version, "#6");
+
+                       Assert.AreEqual ("Method: GET, RequestUri: '<null>', Version: 1.1, Content: <null>, Headers:\r\n{\r\n}", m.ToString (), "#7");
                }
 
                [Test]
@@ -473,6 +475,8 @@ namespace MonoTests.System.Net.Http
                        headers.Clear ();
                        headers.AddWithoutValidation ("Age", "vv");
                        Assert.AreEqual ("vv", headers.GetValues ("Age").First (), "#2");
+
+                       Assert.AreEqual ("Method: GET, RequestUri: '<null>', Version: 1.1, Content: <null>, Headers:\r\n{\r\nAge: vv\r\n}", message.ToString (), "#3");
                }
 
                [Test]
index 8eaf2e97b8bf1f1b4d701ca4dedb3eebbe175f47..a06439308645d92c3f26e49a2b199ff6b1626722 100644 (file)
@@ -62,6 +62,8 @@ namespace MonoTests.System.Net.Http
                        Assert.AreEqual (HttpStatusCode.OK, m.StatusCode, "#6");
                        Assert.AreEqual (new Version (1, 1), m.Version, "#7");
                        Assert.IsNull (m.Headers.CacheControl, "#8");
+
+                       Assert.AreEqual ("StatusCode: 200, ReasonPhrase: 'OK', Version: 1.1, Content: <null>, Headers:\r\n{\r\n}", m.ToString (), "#9");
                }
 
                [Test]
@@ -436,6 +438,8 @@ namespace MonoTests.System.Net.Http
                        headers.Clear ();
                        headers.Connection.Add ("Close");
                        Assert.IsTrue (headers.ConnectionClose.Value, "#4");
+
+                       Assert.AreEqual ("StatusCode: 200, ReasonPhrase: 'OK', Version: 1.1, Content: <null>, Headers:\r\n{\r\nConnection: Close\r\n}", message.ToString (), "#5");
                }
 
                [Test]
diff --git a/mcs/class/System.Net.Http/Test/System.Net.Http/MultipartContentTest.cs b/mcs/class/System.Net.Http/Test/System.Net.Http/MultipartContentTest.cs
new file mode 100644 (file)
index 0000000..177df39
--- /dev/null
@@ -0,0 +1,165 @@
+//
+// MultipartContentTest.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+using NUnit.Framework;
+using System.Net.Http;
+using System.IO;
+using System.Threading.Tasks;
+using System.Text;
+using System.Linq;
+
+namespace MonoTests.System.Net.Http
+{
+       [TestFixture]
+       public class MultipartContentTest
+       {
+               [Test]
+               public void Ctor_Invalid ()
+               {
+                       try {
+                               new MultipartContent (null);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new MultipartContent ("v", null);
+                               Assert.Fail ("#2");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new MultipartContent ("st", "[]");
+                               Assert.Fail ("#3");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new MultipartContent ("st", "1234567890123456789012345678901234567890123456789012345678901234567890X");
+                               Assert.Fail ("#4");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new MultipartContent ("st", "st ");
+                               Assert.Fail ("#5");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new MultipartContent ("st", "@");
+                               Assert.Fail ("#6");
+                       } catch (ArgumentException) {
+                       }
+               }
+
+               [Test]
+               public void Ctor ()
+               {
+                       using (var m = new MultipartContent ("a", "b")) {
+                               m.Headers.Add ("extra", "value");
+                               Assert.AreEqual ("multipart/a", m.Headers.ContentType.MediaType, "#1");
+                               Assert.AreEqual (14, m.Headers.ContentLength, "#2");
+                               Assert.AreEqual ("--b\r\n\r\n--b--\r\n", m.ReadAsStringAsync ().Result, "#3");
+                       }
+
+                       using (var m = new MultipartContent ()) {
+                               Assert.AreEqual ("multipart/mixed", m.Headers.ContentType.MediaType, "#11");
+                               Assert.AreEqual (84, m.Headers.ContentLength, "#12");
+                       }
+
+                       using (var m = new MultipartContent ("ggg")) {
+                               Assert.AreEqual ("multipart/ggg", m.Headers.ContentType.MediaType, "#21");
+                               Assert.AreEqual (84, m.Headers.ContentLength, "#22");
+                       }
+               }
+
+               [Test]
+               public void Add ()
+               {
+                       var m = new MultipartContent ("a", "b");
+
+                       var other = new MultipartContent ("2", "44");
+                       other.Headers.Expires = new DateTimeOffset (2020, 11, 30, 19, 55, 22, TimeSpan.Zero);
+                       m.Add (other);
+
+                       Assert.AreEqual ("multipart/a", m.Headers.ContentType.MediaType, "#1");
+                       Assert.AreEqual (114, m.Headers.ContentLength, "#2");
+                       Assert.AreEqual ("--b\r\nContent-Type: multipart/2; boundary=\"44\"\r\nExpires: Mon, 30 Nov 2020 19:55:22 GMT\r\n\r\n--44\r\n\r\n--44--\r\n\r\n--b--\r\n", m.ReadAsStringAsync ().Result, "#3");
+                       Assert.AreEqual (other, m.First (), "#4");
+               }
+
+               [Test]
+               public void Add_2 ()
+               {
+                       var m = new MultipartContent ("a", "X");
+
+                       var other = new MultipartContent ("2", "2a");
+                       m.Add (other);
+                       var other2 = new MultipartContent ("3", "3a");
+                       other2.Headers.Add ("9", "9n");
+                       m.Add (other2);
+
+                       Assert.AreEqual ("multipart/a", m.Headers.ContentType.MediaType, "#1");
+                       Assert.AreEqual (148, m.Headers.ContentLength, "#2");
+                       Assert.AreEqual ("--X\r\nContent-Type: multipart/2; boundary=\"2a\"\r\n\r\n--2a\r\n\r\n--2a--\r\n\r\n--X\r\nContent-Type: multipart/3; boundary=\"3a\"\r\n9: 9n\r\n\r\n--3a\r\n\r\n--3a--\r\n\r\n--X--\r\n",
+                               m.ReadAsStringAsync ().Result, "#3");
+                       Assert.AreEqual (other, m.First (), "#4");
+               }
+
+               [Test]
+               public void Add_Resursive ()
+               {
+                       var m = new MultipartContent ("1", "1a");
+
+                       var other = new MultipartContent ("2", "2a");
+                       m.Add (other);
+
+                       var other2 = new MultipartContent ("3", "3a");
+                       other.Add (other2);
+
+                       Assert.AreEqual ("multipart/1", m.Headers.ContentType.MediaType, "#1");
+                       Assert.AreEqual (136, m.Headers.ContentLength, "#2");
+                       Assert.AreEqual ("--1a\r\nContent-Type: multipart/2; boundary=\"2a\"\r\n\r\n--2a\r\nContent-Type: multipart/3; boundary=\"3a\"\r\n\r\n--3a\r\n\r\n--3a--\r\n\r\n--2a--\r\n\r\n--1a--\r\n",
+                               m.ReadAsStringAsync ().Result, "#3");
+                       Assert.AreEqual (other, m.First (), "#4");
+               }
+
+               [Test]
+               public void Add_Invalid ()
+               {
+                       var m = new MultipartContent ("a", "b");
+                       try {
+                               m.Add (null);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentNullException) {
+                       }
+               }
+       }
+}
diff --git a/mcs/class/System.Net.Http/Test/System.Net.Http/MultipartFormDataContentTest.cs b/mcs/class/System.Net.Http/Test/System.Net.Http/MultipartFormDataContentTest.cs
new file mode 100644 (file)
index 0000000..2c9826d
--- /dev/null
@@ -0,0 +1,178 @@
+//
+// MultipartFormDataContentTest.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+using NUnit.Framework;
+using System.Net.Http;
+using System.IO;
+using System.Threading.Tasks;
+using System.Text;
+using System.Linq;
+using System.Net.Http.Headers;
+
+namespace MonoTests.System.Net.Http
+{
+       [TestFixture]
+       public class MultipartFormDataContentTest
+       {
+               [Test]
+               public void Ctor_Invalid ()
+               {
+                       try {
+                               new MultipartFormDataContent (null);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new MultipartFormDataContent ("[]");
+                               Assert.Fail ("#2");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new MultipartFormDataContent ("1234567890123456789012345678901234567890123456789012345678901234567890X");
+                               Assert.Fail ("#3");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new MultipartFormDataContent ("st ");
+                               Assert.Fail ("#4");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               new MultipartFormDataContent ("@");
+                               Assert.Fail ("#5");
+                       } catch (ArgumentException) {
+                       }
+               }
+
+               [Test]
+               public void Ctor ()
+               {
+                       using (var m = new MultipartFormDataContent ("b")) {
+                               m.Headers.Add ("extra", "value");
+                               Assert.AreEqual ("multipart/form-data", m.Headers.ContentType.MediaType, "#1");
+                               Assert.IsNull (m.Headers.ContentDisposition, "#2");
+                               Assert.AreEqual (14, m.Headers.ContentLength, "#3");
+                               Assert.AreEqual ("--b\r\n\r\n--b--\r\n", m.ReadAsStringAsync ().Result, "#4");
+                       }
+
+                       using (var m = new MultipartFormDataContent ()) {
+                               Assert.AreEqual ("multipart/form-data", m.Headers.ContentType.MediaType, "#11");
+                               Assert.AreEqual (84, m.Headers.ContentLength, "#12");
+                       }
+
+                       using (var m = new MultipartFormDataContent ("ggg")) {
+                               Assert.AreEqual ("multipart/form-data", m.Headers.ContentType.MediaType, "#21");
+                               Assert.AreEqual (18, m.Headers.ContentLength, "#22");
+                       }
+               }
+
+               [Test]
+               public void Add ()
+               {
+                       var m = new MultipartFormDataContent ("b");
+
+                       var other = new MultipartFormDataContent ("44");
+                       other.Headers.Expires = new DateTimeOffset (2020, 11, 30, 19, 55, 22, TimeSpan.Zero);
+                       m.Add (other);
+
+                       Assert.AreEqual ("multipart/form-data", m.Headers.ContentType.MediaType, "#1");
+                       Assert.AreEqual (154, m.Headers.ContentLength, "#2");
+                       Assert.AreEqual ("--b\r\nContent-Type: multipart/form-data; boundary=\"44\"\r\nExpires: Mon, 30 Nov 2020 19:55:22 GMT\r\nContent-Disposition: form-data\r\n\r\n--44\r\n\r\n--44--\r\n\r\n--b--\r\n", m.ReadAsStringAsync ().Result, "#3");
+                       Assert.AreEqual (other, m.First (), "#4");
+                       Assert.IsNull (m.Headers.ContentDisposition, "#5");
+                       Assert.AreEqual ("form-data", other.Headers.ContentDisposition.ToString (), "#6");
+               }
+
+               [Test]
+               public void Add_2 ()
+               {
+                       var m = new MultipartFormDataContent ("b");
+
+                       var other = new MultipartFormDataContent ("44");
+                       m.Add (other, "name", "fname");
+
+                       Assert.AreEqual ("multipart/form-data", m.Headers.ContentType.MediaType, "#1");
+                       Assert.AreEqual (165, m.Headers.ContentLength, "#2");
+                       Assert.AreEqual ("--b\r\nContent-Type: multipart/form-data; boundary=\"44\"\r\nContent-Disposition: form-data; name=name; filename=fname; filename*=utf-8''fname\r\n\r\n--44\r\n\r\n--44--\r\n\r\n--b--\r\n", m.ReadAsStringAsync ().Result, "#3");
+                       Assert.AreEqual (other, m.First (), "#4");
+                       Assert.IsNull (m.Headers.ContentDisposition, "#5");
+                       Assert.AreEqual ("form-data; name=name; filename=fname; filename*=utf-8''fname", other.Headers.ContentDisposition.ToString (), "#6");
+               }
+
+               [Test]
+               public void Add_3 ()
+               {
+                       var m = new MultipartFormDataContent ("b");
+
+                       var other = new MultipartFormDataContent ("44");
+                       other.Headers.ContentDisposition = new ContentDispositionHeaderValue ("dt");
+                       m.Add (other, "name", "fname");
+
+                       Assert.AreEqual ("multipart/form-data", m.Headers.ContentType.MediaType, "#1");
+                       Assert.AreEqual (107, m.Headers.ContentLength, "#2");
+                       Assert.AreEqual ("--b\r\nContent-Type: multipart/form-data; boundary=\"44\"\r\nContent-Disposition: dt\r\n\r\n--44\r\n\r\n--44--\r\n\r\n--b--\r\n", m.ReadAsStringAsync ().Result, "#3");
+                       Assert.AreEqual (other, m.First (), "#4");
+                       Assert.IsNull (m.Headers.ContentDisposition, "#5");
+                       Assert.AreEqual ("dt", other.Headers.ContentDisposition.ToString (), "#6");
+               }
+
+               [Test]
+               public void Add_Invalid ()
+               {
+                       var m = new MultipartFormDataContent ("a");
+                       try {
+                               m.Add (null);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentNullException) {
+                       }
+
+                       try {
+                               m.Add (new MultipartFormDataContent ("44"), null);
+                               Assert.Fail ("#2");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               m.Add (new MultipartFormDataContent ("44"), "s", null);
+                               Assert.Fail ("#3");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               m.Add (new MultipartFormDataContent ("44"), "s", "   ");
+                               Assert.Fail ("#4");
+                       } catch (ArgumentException) {
+                       }
+               }
+       }
+}
index 86c28ca330ce9d23ee7cd5fc3050cc89bcd471f2..46459f0079aba433a4c726b666c83b61dca9f122 100644 (file)
@@ -299,7 +299,23 @@ namespace MonoTests.System.Net.Http
                        ms.Seek (0, SeekOrigin.Begin);
 
                        var sc = new StreamContent (ms);
-                       sc.LoadIntoBufferAsync (400).Wait ();
+                       Assert.IsTrue (sc.LoadIntoBufferAsync (400).Wait (200));
+               }
+
+               [Test]
+               public void LoadIntoBuffer_BufferOverflow ()
+               {
+                       var ms = new MemoryStream ();
+                       ms.Write (new byte[10000], 0, 10000);
+                       ms.Seek (0, SeekOrigin.Begin);
+
+                       var sc = new StreamContent (ms);
+                       try {
+                               Assert.IsTrue (sc.LoadIntoBufferAsync (50).Wait (200));
+                               Assert.Fail ("#1");
+                       } catch (AggregateException e) {
+                               Assert.IsInstanceOfType (typeof (HttpRequestException), e.InnerException, "#2");
+                       }
                }
 
                [Test]
@@ -332,5 +348,18 @@ namespace MonoTests.System.Net.Http
                        var res = sc.ReadAsStringAsync ().Result;
                        Assert.AreEqual ("M7", res, "#1");
                }
+
+               [Test]
+               public void ReadAsStream ()
+               {
+                       var ms = new MemoryStream ();
+                       ms.WriteByte (77);
+                       ms.WriteByte (55);
+                       ms.Seek (0, SeekOrigin.Begin);
+
+                       var sc = new StreamContent (ms);
+                       var res = sc.ReadAsStreamAsync ().Result;
+                       Assert.AreEqual (77, res.ReadByte (), "#1");
+               }
        }
 }
index 7998429b345e1df82c6028df867780fca73c7d60..c5c9d68ec2d83969923c3fb0384d588dfc972aee 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 12e534fdf4bb2702d2e14d043598e5b5e1f7862c..8b1f4187714cceeddc509dd2f83e3ee8c9498b8e 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 39380261b2692741dd2bf9895c769a94aa74cc5a..48e7040b5cd5652e331f656f0a1777ad6dbc9549 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1aab5ba7eb1677522d7849e98fc4107aae672f0b..d23ba9ebe96ea78205870e99f38689711edd08de 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 10abcab84c144d1a102e444663d0bd9730f7dc76..6a0e72f923b8813b1e64e6d3e05ae7991edd7879 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4c1f083175b0e7db8cfdf2662b1d4dff721c00f1..559a074a3e33c5ff2c3a49eea7d9638bb2ecb14b 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f39e5bbbf136ad8caaa421743e8140587399f76d..c07650d496a01c311190f62f989422247aa3bda6 100644 (file)
@@ -52,7 +52,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7f5a1e2035115b7a62eef0bf5a0ced99ffb299e7..c1945c740a19a64805848ea7dd9fed6a24b8b906 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d78362c61ac87eaf2485c6412f471c9b5113726c..4372b9f0e4dbe092d76d3a05c4eb41f2864a5043 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7ee49703259063fb02e725fdc83cf17fa41c542d..21f1eaf2ade1d311259d5d927311e9b1a377843e 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1ac4c85c0f44484ad9a7cc8419b8b3154789f335..0d660f42a039f411ceb37f79c73b1e7afc3f43e1 100644 (file)
@@ -60,7 +60,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 92c1ba53322f49fcaa195abc2cb0b2068ee8cb80..1eb41bb3f65e6945a3b19f6e449b8c1828eb086c 100644 (file)
@@ -70,7 +70,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 228c697fc957116688cca03951b041fc951ceaad..05a0fd85ef9b01fbf3c3ab413bcf8b0ce2000b91 100644 (file)
@@ -70,7 +70,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9531a679dd18815edc1eefb7a87391477ec6bb06..3da52d51c2281d1806d80dfc36cad19a95bf3826 100644 (file)
@@ -53,7 +53,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index df282eeac24af7c592a23fa805cef76f4b7f9e18..129ca13a7e45ade4f4fdd1453e0c49d5f39aaaa5 100644 (file)
@@ -53,7 +53,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 74c12d97b5785b07436c7eeca5a432e2688df5f8..b249386819e33b46e55185a6515e52ad5d99077a 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ace36aee29ddcce375591c8b6004a540e5f6e92d..fecfdefe277ee5f9b44191a07081f8297c5b51ec 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 38c5020039235c02811cacd120516c64546a6062..baa1195c3521ae67ce1f4a3443e3036803ace66b 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 91c55c78bf0223017ca10729f7127702bce613fe..572a66a3c37acb8027d0b3f6c7a25ccb162ab4c5 100644 (file)
@@ -71,7 +71,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5177100c3053ec4f80d49542222d890f1ea4bed9..3d1ac89d0fa438b15b05ebc576d7d3a42b2811c9 100644 (file)
@@ -71,7 +71,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index cdcc2b1319492eb6f319666e889d3ec0a6ae6e0c..778b8b325b02e35918dbe6f62b3dc2a08565b9a2 100644 (file)
@@ -71,7 +71,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 496b641966540492dc89a83cc44f4d7c02b97862..95afe29b5fb5fc6f5a7f3796f858e6d64efc4004 100644 (file)
@@ -59,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9f7f7231817acaf94971bedbd5f4f8a9128d170e..42adb8001244678a70a7580fd1079131639ff16f 100644 (file)
@@ -59,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4eddc861f50581084279615067e809191143f997..549042fe374901340b38ef78c8be8908eed75004 100644 (file)
@@ -59,7 +59,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9ac98bc071f55164b9fdda83bb006464d2d0adb7..3ad5789b2db793efd83689b172531d4a2fcd0ec3 100644 (file)
@@ -56,7 +56,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 583f0eff185b8a9b7595f089c908083f508356a3..e3eb8d20f80bbdf55bfad9309277ecfe2ae4b183 100644 (file)
@@ -56,7 +56,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8bbb550ab008d262eca1cd3001656866ee21ac9d..44c66b4c0d84a3f576f4486e95fc35aff1e68702 100644 (file)
@@ -56,7 +56,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2066097a33420db777e4e17d65eec57cf7beef20..08d0688e049c75aa105c0e52c765f369585ec4db 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0f1cf4a0b76b61792334ff6ad59702e66f618d39..dca8d274b4daedc27f3c0306d9dd3fd878bf7873 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7b35ed8e6ea60cad0ce64cc6d9e9ecdef1282dc3..f3e3f45714409c3724fd6039a033ff951aafa5c2 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index af95320dc859dfa0b25fbf66e3d2a23bdfef9d48..c3188cef9694c798aa50d033863c0a1b4d882ba4 100644 (file)
@@ -40,6 +40,8 @@
   <ItemGroup>\r
    <Compile Include="Test\System.Runtime.Serialization\Bug666333Test.cs" />
    <Compile Include="Test\System.Runtime.Serialization\Bug675144Test.cs" />
+   <Compile Include="Test\System.Runtime.Serialization\Bug2843Test.cs" />
+   <Compile Include="Test\System.Runtime.Serialization\DataContractSerializerTest_NullableWithDictionary.cs" />
    <Compile Include="Test\System.Runtime.Serialization\Bug695203Test.cs" />
    <Compile Include="Test\System.Runtime.Serialization\DataContractResolverTest.cs" />
    <Compile Include="Test\System.Runtime.Serialization\KnownTypeAttributeTest.cs" />
@@ -72,7 +74,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f33d52e558783451507321d0f3b86aac72c44181..68b963c6fa3f03ce8426e07f6af9bba7d8be6e79 100644 (file)
@@ -40,6 +40,8 @@
   <ItemGroup>\r
    <Compile Include="Test\System.Runtime.Serialization\Bug666333Test.cs" />
    <Compile Include="Test\System.Runtime.Serialization\Bug675144Test.cs" />
+   <Compile Include="Test\System.Runtime.Serialization\Bug2843Test.cs" />
+   <Compile Include="Test\System.Runtime.Serialization\DataContractSerializerTest_NullableWithDictionary.cs" />
    <Compile Include="Test\System.Runtime.Serialization\Bug695203Test.cs" />
    <Compile Include="Test\System.Runtime.Serialization\DataContractResolverTest.cs" />
    <Compile Include="Test\System.Runtime.Serialization\KnownTypeAttributeTest.cs" />
@@ -72,7 +74,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8b9e5ad0d872fcc903f071da0c5c95f32a84b590..c9bdaad40b3a143cc2a0368624ec72993c9ca1d7 100644 (file)
@@ -40,6 +40,8 @@
   <ItemGroup>\r
    <Compile Include="Test\System.Runtime.Serialization\Bug666333Test.cs" />
    <Compile Include="Test\System.Runtime.Serialization\Bug675144Test.cs" />
+   <Compile Include="Test\System.Runtime.Serialization\Bug2843Test.cs" />
+   <Compile Include="Test\System.Runtime.Serialization\DataContractSerializerTest_NullableWithDictionary.cs" />
    <Compile Include="Test\System.Runtime.Serialization\Bug695203Test.cs" />
    <Compile Include="Test\System.Runtime.Serialization\DataContractResolverTest.cs" />
    <Compile Include="Test\System.Runtime.Serialization\KnownTypeAttributeTest.cs" />
@@ -72,7 +74,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e7866df16237f171819e551cbdf5aecb4e870790..45fd1f7091315903859c8d9ca9f7bccc80d15eee 100755 (executable)
 // distribute, sublicense, and/or sell copies of the Software, and to
 // permit persons to whom the Software is furnished to do so, subject to
 // the following conditions:
-// 
+//
 // The above copyright notice and this permission notice shall be
 // included in all copies or substantial portions of the Software.
-// 
+//
 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
 // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
@@ -51,6 +51,7 @@ namespace System.Runtime.Serialization
                StreamingContext context;
                ReadOnlyCollection<Type> returned_known_types;
                KnownTypeCollection known_types;
+               List<Type> specified_known_types;
                IDataContractSurrogate surrogate;
                DataContractResolver resolver, default_resolver;
 
@@ -76,7 +77,7 @@ namespace System.Runtime.Serialization
                        QName qname = known_types.GetQName (type);
 
                        FillDictionaryString (qname.Name, qname.Namespace);
-                       
+
                }
 
                public DataContractSerializer (Type type, string rootName,
@@ -216,11 +217,16 @@ namespace System.Runtime.Serialization
                void PopulateTypes (IEnumerable<Type> knownTypes)
                {
                        if (known_types == null)
-                               known_types= new KnownTypeCollection ();
+                               known_types = new KnownTypeCollection ();
+
+                       if (specified_known_types == null)
+                               specified_known_types = new List<Type> ();
 
                        if (knownTypes != null) {
-                               foreach (Type t in knownTypes)
+                               foreach (Type t in knownTypes) {
                                        known_types.Add (t);
+                                       specified_known_types.Add (t);
+                               }
                        }
 
                        RegisterTypeAsKnown (type);
@@ -288,7 +294,7 @@ namespace System.Runtime.Serialization
                public ReadOnlyCollection<Type> KnownTypes {
                        get {
                                if (returned_known_types == null)
-                                       returned_known_types = new ReadOnlyCollection<Type> (known_types);
+                                       returned_known_types = new ReadOnlyCollection<Type> (specified_known_types);
                                return returned_known_types;
                        }
                }
@@ -365,18 +371,6 @@ namespace System.Runtime.Serialization
                }
 #endif
 
-               private void ReadRootStartElement (XmlReader reader, Type type)
-               {
-                       SerializationMap map =
-                               known_types.FindUserMap (type);
-                       QName name = map != null ? map.XmlName :
-                               KnownTypeCollection.GetPredefinedTypeName (type);
-                       reader.MoveToContent ();
-                       reader.ReadStartElement (name.Name, name.Namespace);
-                       // FIXME: could there be any attributes to handle here?
-                       reader.Read ();
-               }
-
                // SP1
                public override void WriteObject (XmlWriter writer, object graph)
                {
@@ -444,7 +438,7 @@ namespace System.Runtime.Serialization
                        XmlDictionaryWriter writer, object graph)
                {
                        Type rootType = type;
-                       
+
                        if (root_name.Value == "")
                                throw new InvalidDataContractException ("Type '" + type.ToString () +
                                        "' cannot have a DataContract attribute Name set to null or empty string.");
@@ -496,7 +490,7 @@ namespace System.Runtime.Serialization
 
                        /* Different names */
                        known_types.Add (rootType);
-                       
+
                        instName = instName ?? KnownTypeCollection.GetPredefinedTypeName (graph.GetType ());
                        if (instName == QName.Empty)
                                /* Not a primitive type */
@@ -512,7 +506,7 @@ namespace System.Runtime.Serialization
                        writer.WriteEndAttribute ();
 */
                }
-               
+
                bool IsUnknownType (Type type)
                {
                        if (known_types.Contains (type) ||
index 8713ef37fbde6dd676403cbfafc85356d81ce725..946e5aa5af5e7c1c9ebb9b553d69bfd79152ff83 100755 (executable)
 // distribute, sublicense, and/or sell copies of the Software, and to
 // permit persons to whom the Software is furnished to do so, subject to
 // the following conditions:
-// 
+//
 // The above copyright notice and this permission notice shall be
 // included in all copies or substantial portions of the Software.
-// 
+//
 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
 // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
@@ -213,8 +213,6 @@ namespace System.Runtime.Serialization
                                return name;
                        if (type == typeof (DBNull))
                                return dbnull_type;
-                       if (type == typeof (DateTimeOffset))
-                               return date_time_offset_type;
                        return QName.Empty;
                }
 
@@ -241,6 +239,8 @@ namespace System.Runtime.Serialization
                                        return base64_type;
                                if (type == typeof (Uri))
                                        return any_uri_type;
+                               if (type == typeof (DateTimeOffset))
+                                       return date_time_offset_type;
                                return QName.Empty;
                        case TypeCode.Boolean:
                                return bool_type;
@@ -504,12 +504,28 @@ namespace System.Runtime.Serialization
                                base.InsertItem (index - 1, type);
                }
 
+               internal SerializationMap FindUserMap (Type type)
+               {
+                       lock (this) {
+                               for (int i = 0; i < contracts.Count; i++)
+                                       if (type == contracts [i].RuntimeType)
+                                               return contracts [i];
+                               return null;
+                       }
+               }
+
                internal SerializationMap FindUserMap (QName qname)
                {
                        lock (this)
                                return contracts.FirstOrDefault (c => c.XmlName == qname);
                }
 
+               internal SerializationMap FindUserMap (QName qname, Type type)
+               {
+                       lock (this)
+                               return contracts.FirstOrDefault (c => c.XmlName == qname && c.RuntimeType == type);
+               }
+
                internal Type GetSerializedType (Type type)
                {
                        if (IsPrimitiveNotEnum (type))
@@ -518,28 +534,18 @@ namespace System.Runtime.Serialization
                        if (element == null)
                                return type;
                        QName name = GetQName (type);
-                       var map = FindUserMap (name);
+                       var map = FindUserMap (name, type);
                        if (map != null)
                                return map.RuntimeType;
                        return type;
                }
 
-               internal SerializationMap FindUserMap (Type type)
-               {
-                       lock (this) {
-                               for (int i = 0; i < contracts.Count; i++)
-                                       if (type == contracts [i].RuntimeType)
-                                               return contracts [i];
-                               return null;
-                       }
-               }
-
                internal QName GetQName (Type type)
                {
                        SerializationMap map = FindUserMap (type);
                        if (map != null)
                                // already mapped.
-                               return map.XmlName; 
+                               return map.XmlName;
                        return GetStaticQName (type);
                }
 
@@ -556,7 +562,7 @@ namespace System.Runtime.Serialization
                                return qname;
 
                        if (type.GetInterface ("System.Xml.Serialization.IXmlSerializable") != null)
-                               //FIXME: Reusing GetSerializableQName here, since we just 
+                               //FIXME: Reusing GetSerializableQName here, since we just
                                //need name of the type..
                                return GetSerializableQName (type);
 
@@ -596,7 +602,7 @@ namespace System.Runtime.Serialization
                                for (int i = 0; i < args.Length; i++)
                                        name = name.Replace ("{" + i + "}", GetStaticQName (args [i]).Name);
                        }
-                       
+
                        if (ns == null)
                                ns = GetDefaultNamespace (type);
                        return new QName (name, ns);
@@ -627,7 +633,7 @@ namespace System.Runtime.Serialization
 
                internal static string GetDefaultName (Type type)
                {
-                       // FIXME: there could be decent ways to get 
+                       // FIXME: there could be decent ways to get
                        // the same result...
                        string name = type.Namespace == null || type.Namespace.Length == 0 ? type.Name : type.FullName.Substring (type.Namespace.Length + 1).Replace ('+', '.');
                        if (type.IsGenericType) {
@@ -649,7 +655,7 @@ namespace System.Runtime.Serialization
                static QName GetCollectionQName (Type element)
                {
                        QName eqname = GetStaticQName (element);
-                       
+
                        string ns = eqname.Namespace;
                        if (eqname.Namespace == MSSimpleNamespace)
                                //Arrays of Primitive types
@@ -699,7 +705,7 @@ namespace System.Runtime.Serialization
                                return false;
                        if (Type.GetTypeCode (type) != TypeCode.Object) // explicitly primitive
                                return true;
-                       if (type == typeof (Guid) || type == typeof (object) || type == typeof(TimeSpan) || type == typeof(byte[]) || type==typeof(Uri)) // special primitives
+                       if (type == typeof (Guid) || type == typeof (object) || type == typeof(TimeSpan) || type == typeof(byte[]) || type == typeof(Uri) || type == typeof(DateTimeOffset)) // special primitives
                                return true;
 #if !MOONLIGHT
                        // DOM nodes
@@ -794,7 +800,7 @@ namespace System.Runtime.Serialization
 
                        QName qname = GetCollectionContractQName (type);
                        CheckStandardQName (qname);
-                       var map = FindUserMap (qname);
+                       var map = FindUserMap (qname, type);
                        if (map != null) {
                                var cmap = map as CollectionContractTypeMap;
                                if (cmap == null) // The runtime type may still differ (between array and other IList; see bug #670560)
@@ -816,7 +822,7 @@ namespace System.Runtime.Serialization
 
                        QName qname = GetCollectionQName (element);
 
-                       var map = FindUserMap (qname);
+                       var map = FindUserMap (qname, element);
                        if (map != null) {
                                var cmap = map as CollectionTypeMap;
                                if (cmap == null) // The runtime type may still differ (between array and other IList; see bug #670560)
@@ -853,7 +859,7 @@ namespace System.Runtime.Serialization
                        TryRegister (ret.KeyType);
                        TryRegister (ret.ValueType);
 
-                       var map = FindUserMap (ret.XmlName);
+                       var map = FindUserMap (ret.XmlName, type);
                        if (map != null) {
                                var dmap = map as DictionaryTypeMap;
                                if (dmap == null) // The runtime type may still differ (between array and other IList; see bug #670560)
@@ -868,7 +874,7 @@ namespace System.Runtime.Serialization
                {
                        QName qname = GetSerializableQName (type);
 
-                       if (FindUserMap (qname) != null)
+                       if (FindUserMap (qname, type) != null)
                                throw new InvalidOperationException (String.Format ("There is already a registered type for XML name {0}", qname));
 
                        SharedTypeMap ret = new SharedTypeMap (type, qname, this);
@@ -884,7 +890,7 @@ namespace System.Runtime.Serialization
 
                        QName qname = GetSerializableQName (type);
 
-                       if (FindUserMap (qname) != null)
+                       if (FindUserMap (qname, type) != null)
                                throw new InvalidOperationException (String.Format ("There is already a registered type for XML name {0}", qname));
 
                        XmlSerializableMap ret = new XmlSerializableMap (type, qname, this);
@@ -911,7 +917,7 @@ namespace System.Runtime.Serialization
                        if (qname == null)
                                return null;
                        CheckStandardQName (qname);
-                       if (FindUserMap (qname) != null)
+                       if (FindUserMap (qname, type) != null)
                                throw new InvalidOperationException (String.Format ("There is already a registered type for XML name {0}", qname));
 
                        SharedContractMap ret = new SharedContractMap (type, qname, this);
@@ -948,7 +954,7 @@ namespace System.Runtime.Serialization
                        if (qname == null)
                                return null;
 
-                       if (FindUserMap (qname) != null)
+                       if (FindUserMap (qname, type) != null)
                                throw new InvalidOperationException (String.Format ("There is already a registered type for XML name {0}", qname));
 
                        EnumMap ret =
index 88dcd1c063c8cfff7686950f101aa40ca136efc4..351dd5f967aa7bb49ccef81b28743560849fa183 100644 (file)
@@ -200,8 +200,14 @@ namespace System.Runtime.Serialization
 
                object DeserializePrimitive (Type type, XmlReader reader, QName qname)
                {
+                       bool isDateTimeOffset = false;
+                       // Handle DateTimeOffset type and DateTimeOffset?.
+                       if (type == typeof (DateTimeOffset))
+                               isDateTimeOffset = true;
+                       else if(type.IsGenericType && type.GetGenericTypeDefinition () == typeof (Nullable<>)) 
+                               isDateTimeOffset = type.GetGenericArguments () [0] == typeof (DateTimeOffset);  
                        // It is the only exceptional type that does not serialize to string but serializes into complex element.
-                       if (type == typeof (DateTimeOffset)) {
+                       if (isDateTimeOffset) {
                                if (reader.IsEmptyElement) {
                                        reader.Read ();
                                        return default (DateTimeOffset);
index a816839b87c145114026e38b9bfe7056557cabf3..f90ab47e2218a92ad64cc1977f4cd5bcc13bd85f 100644 (file)
@@ -119,8 +119,18 @@ namespace System.Runtime.Serialization
                                        types.Add (actualType);
                                        map = types.FindUserMap (actualType);
                                }
+                               
+                               bool explicityType = false;
+                               if(type != actualType)
+                               {
+                                       // Check if underlying type of Nullable, mismatch the current type.
+                                       if(type.IsGenericType && type.GetGenericTypeDefinition () == typeof (Nullable<>))
+                                               explicityType = (type.GetGenericArguments () [0] != actualType);
+                                       else
+                                               explicityType = true;
+                               }
 
-                               if (actualType != type && (map == null || map.OutputXsiType)) {
+                               if (explicityType && (map == null || map.OutputXsiType)) {
                                        QName qname = resolvedQName ?? types.GetXmlName (actualType);
                                        string name = qname.Name;
                                        string ns = qname.Namespace;
@@ -151,12 +161,14 @@ namespace System.Runtime.Serialization
                        if (label != null)
                                Writer.WriteAttributeString ("z", "Id", KnownTypeCollection.MSSimpleNamespace, label);
 
-//                     writer.WriteStartAttribute ("type", XmlSchema.InstanceNamespace);
-//                     writer.WriteQualifiedName (qname.Name, qname.Namespace);
-//                     writer.WriteEndAttribute ();
-
+                       bool isDateTimeOffset = false;
+                       // Handle DateTimeOffset type and DateTimeOffset?
+                       if (type == typeof (DateTimeOffset))
+                               isDateTimeOffset = true;
+                       else if(type.IsGenericType && type.GetGenericTypeDefinition () == typeof (Nullable<>)) 
+                               isDateTimeOffset = type.GetGenericArguments () [0] == typeof (DateTimeOffset);  
                        // It is the only exceptional type that does not serialize to string but serializes into complex element.
-                       if (type == typeof (DateTimeOffset)) {
+                       if (isDateTimeOffset) {
                                var v = (DateTimeOffset) graph;
                                writer.WriteStartElement ("DateTime", KnownTypeCollection.DefaultClrNamespaceSystem);
                                SerializePrimitive (typeof (DateTime), DateTime.SpecifyKind (v.DateTime.Subtract (v.Offset), DateTimeKind.Utc), KnownTypeCollection.GetPredefinedTypeName (typeof (DateTime)));
index 355102e937a4558b5a4125a47d796107ad62235b..a1091401d54f8438be073e3e4f3db3afe62240ee 100644 (file)
@@ -1,9 +1,11 @@
 System.Runtime.Serialization/Bug666333Test.cs
 System.Runtime.Serialization/Bug675144Test.cs
 System.Runtime.Serialization/Bug2843Test.cs
-System.Runtime.Serialization/DataContractSerializerTest_NullableWithDictionary.cs
+System.Runtime.Serialization/Bug3258Test.cs
 System.Runtime.Serialization/Bug695203Test.cs
 System.Runtime.Serialization/DataContractResolverTest.cs
+System.Runtime.Serialization/DataContractSerializerTest_DuplicateQName.cs
+System.Runtime.Serialization/DataContractSerializerTest_NullableWithDictionary.cs
 System.Runtime.Serialization/KnownTypeAttributeTest.cs
 System.Runtime.Serialization/XmlObjectSerializerTest.cs
 System.Runtime.Serialization/XsdDataContractExporterTest.cs
index 9176fc922c8e18675fae662ee04607fbe4172fd5..41370633b8b56db53f596e98ffb800344d8c8b6d 100644 (file)
@@ -224,7 +224,7 @@ namespace Client2843.EvalServiceReference {
 namespace MonoTests.System.Runtime.Serialization
 {
        [TestFixture]
-       class Bug2843Test
+       public class Bug2843Test
        {
                [Test]
                public void TestNullableEnum()
diff --git a/mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/Bug3258Test.cs b/mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/Bug3258Test.cs
new file mode 100644 (file)
index 0000000..1d9e123
--- /dev/null
@@ -0,0 +1,73 @@
+using System;
+using System.Collections.Generic;
+using System.IO;
+using System.Runtime.Serialization;
+using System.Xml;
+
+using System.Text;
+
+using NUnit.Framework;
+
+namespace MonoTests.System.Runtime.Serialization
+{
+       [TestFixture]
+       public class Bug3258Test
+       {
+               [Test]
+               public void TestSerializeNullDateTimeOffsetNullable ()
+               {
+                        // Create the writer object.
+                       StringBuilder stringBuilder = new StringBuilder ();
+
+                       DateTimeOffset? dto = null;
+
+                       DataContractSerializer ser = new DataContractSerializer (typeof (DateTimeOffset?));
+
+                       using (var xw = XmlDictionaryWriter.CreateDictionaryWriter (XmlWriter.Create (new StringWriter (stringBuilder))))
+                       {
+                               ser.WriteObject (xw, dto);
+                       }
+
+                       string actualXml   = stringBuilder.ToString ();
+                       string expectedXml = "<?xml version=\"1.0\" encoding=\"utf-16\"?><DateTimeOffset i:nil=\"true\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns=\"http://schemas.datacontract.org/2004/07/System\" />";
+                       
+                       Assert.AreEqual (expectedXml, actualXml, "#1 Null DateTimeOffset? serialization error");
+
+                       using (var xr = XmlDictionaryReader.CreateDictionaryReader (XmlReader.Create (new StringReader (actualXml))))
+                       {
+                               DateTimeOffset? actualDto = (DateTimeOffset?)ser.ReadObject (xr, true);
+
+                               Assert.AreEqual (dto, actualDto, "#2 Null DateTimeOffset? deserialization error");
+                               Assert.IsNull (actualDto, "#3 Null DateTimeOffset? deserialization error");
+                       }
+               }
+               
+               [Test]
+               public void TestSerializeDateTimeOffsetNullable ()
+               {
+                        // Create the writer object.
+                       StringBuilder stringBuilder = new StringBuilder ();
+
+                       DateTimeOffset? dto = new DateTimeOffset (2012, 05, 04, 02, 34, 00, new TimeSpan (-2, 0, 0));;
+
+                       DataContractSerializer ser = new DataContractSerializer (typeof (DateTimeOffset?));
+
+                       using (var xw = XmlDictionaryWriter.CreateDictionaryWriter (XmlWriter.Create (new StringWriter (stringBuilder))))
+                       {
+                               ser.WriteObject (xw, dto);
+                       }
+
+                       string actualXml   = stringBuilder.ToString ();
+                       string expectedXml = "<?xml version=\"1.0\" encoding=\"utf-16\"?><DateTimeOffset xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns=\"http://schemas.datacontract.org/2004/07/System\"><DateTime>2012-05-04T04:34:00Z</DateTime><OffsetMinutes>-120</OffsetMinutes></DateTimeOffset>";
+                       
+                       Assert.AreEqual (expectedXml, actualXml, "#1 Nullable DateTimeOffset serialization error");
+
+                       using (var xr = XmlDictionaryReader.CreateDictionaryReader(XmlReader.Create (new StringReader (actualXml))))
+                       {
+                               DateTimeOffset? actualDto = (DateTimeOffset?)ser.ReadObject (xr, true);
+
+                               Assert.AreEqual (dto, actualDto, "#2 Nullable DateTimeOffset deserialization error");
+                       }
+               }
+       }
+}
diff --git a/mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/DataContractSerializerTest_DuplicateQName.cs b/mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/DataContractSerializerTest_DuplicateQName.cs
new file mode 100644 (file)
index 0000000..a753003
--- /dev/null
@@ -0,0 +1,170 @@
+//
+// DataContractSerializerTest_DuplicateQName.cs
+//
+// Author:
+//     David Ferguson <davecferguson@gmail.com>
+//
+// Copyright (C) 2012 Dell AppAssure http://www.appassure.com
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+//
+// This test code contains tests for the DataContractSerializer
+// concerning duplicate Qualified Names for the object graph and known types
+//
+using System;
+using System.IO;
+using System.Runtime.Serialization;
+
+using NUnit.Framework;
+
+namespace MonoTests.System.Runtime.Serialization
+{
+       [TestFixture]
+       public class DataContractSerializerTest_DuplicateQName
+       {
+               [DataContract (Name="name", Namespace="http://somecompany.com/function/api/2010/05")]
+               [Serializable]
+               public class DataContractBase
+               {
+                       public DataContractBase ()
+                       {
+                       }
+
+                       public DataContractBase (string val)
+                       {
+                               BaseValue1 = val;
+                       }
+
+                       [DataMember(Name="baseValue1", Order=1)]
+                       public string BaseValue1 { get; set; }
+
+               }
+
+               [DataContract (Name="name", Namespace="http://somecompany.com/function/api/2010/05")]
+               [Serializable]
+               public class DataContract1 : DataContractBase
+               {
+                       public DataContract1 ()
+                       {
+                       }
+
+                       public DataContract1 (string val) : base (val)
+                       {
+                       }
+               }
+
+               [DataContract(Name = "name", Namespace = "http://somecompany.com/function/api/2010/05")]
+               [Serializable]
+               public class DataContract2
+               {
+                       [DataMember]
+                       public DataContract3 DataContract3 { get; set; }
+               }
+
+               [DataContract(Name = "name", Namespace = "http://somecompany.com/function/api/2010/05")]
+               [Serializable]
+               public class DataContract3
+               {
+
+               }
+
+               [DataContract(Name = "name", Namespace = "http://somecompany.com/function/api/2010/05")]
+               [Serializable]
+               public class DataContract4
+               {
+                       [DataMember(Name = "name")]
+                       public double
+                               Test1;
+               }
+
+               [Test]
+               public void TestMultipleDataContractSameDataContractNameAndNamespace ()
+               {
+                       // DataContract1 derives from DataContractBase and they both have
+                       // the same QName specified in their respective DataContractAttribute.
+                       var serializer = new DataContractSerializer (typeof(DataContract1));
+                       var serializerBase = new DataContractSerializer (typeof(DataContractBase));
+
+                       Assert.IsNotNull (serializer);
+                       Assert.IsNotNull (serializerBase);
+               }
+
+               [Test]
+               public void TestDataContractWithPropertyHavingSameQName ()
+               {
+                       // DataContract2 has a property of DataContract3.  DataContract2 and
+                       // DataContract3 both have the same QName specified in their
+                       // respective DataContractAttribute.  This was causing a failure due
+                       // to the QName being saved in the SerializationMap twice. Bug 4794.
+                       var serializer2 = new DataContractSerializer (typeof(DataContract2));
+                       var d = new DataContract2 ();
+                       var ms = new MemoryStream (2048);
+
+                       Assert.IsNotNull (serializer2, "Failed to create the serializer for DataContract2");
+
+                       serializer2.WriteObject (ms, d);
+                       ms.Position = 0;
+
+                       var d2 = serializer2.ReadObject (ms) as DataContract2;
+
+                       Assert.IsNotNull (d2, "Failed to deserialize the data buffer into a DataContract2");
+               }
+
+               [Test]
+               public void TestDataContractWithPrimitiveHavingSameQName ()
+               {
+                       // This test verifies that a primitive with the same qname as the
+                       // DataContract succeeds in serializing and deserializing
+                       var serializer4 = new DataContractSerializer (typeof(DataContract4));
+
+                       var d = new DataContract4 ();
+                       var ms = new MemoryStream (2048);
+
+                       Assert.IsNotNull (serializer4, "Failed to create the serializer for DataContract4");
+
+                       d.Test1 = 3.1416;
+                       serializer4.WriteObject (ms, d);
+                       ms.Position = 0;
+
+                       var d2 = serializer4.ReadObject (ms) as DataContract4;
+
+                       Assert.IsNotNull (d2, "Failed to deserialize the data buffer into a DataContract4");
+                       Assert.AreEqual (d2.Test1, 3.1416, "Rehydrated Test1 property did not match original");
+                       Assert.AreNotSame (d2, d, "The instances are the same and should not be");
+               }
+
+               [Test]
+               public void TestKnownTypes ()
+               {
+                       // The .NET behavior is that the KnownTypes collection is not populated unless you
+                       // do so through the constructor.  It even ignores attributes on the type indicating
+                       // a known type.
+                       var serializer = new DataContractSerializer (typeof(DataContract1));
+                       var serializerWithKnownType = new DataContractSerializer (
+                               typeof(DataContract2),
+                               new [] { typeof(DataContract3) }
+                       );
+
+                       Assert.AreEqual (serializer.KnownTypes.Count, 0, "Expected an empty known type collection");
+                       Assert.AreEqual (serializerWithKnownType.KnownTypes.Count, 1, "Known count type did not match");
+               }
+       }
+}
\ No newline at end of file
index e8f27d46d14e23b272cb2dd39eb05be7a1b0aa65..86b435c7fe42f7b564d99fd9ce63a6835972f477 100644 (file)
@@ -253,7 +253,7 @@ namespace Client.EvalServiceReference {
 namespace MonoTests.System.Runtime.Serialization
 {
        [TestFixture]
-       class SerializeNullableWithDictionaryTest
+       public class SerializeNullableWithDictionaryTest
        {
 
                [Test]
index 705233649cb0f07380aa6f29139234d6a2c89f5e..b494ff6512b890f9c4f3ab5caca6b5ba61a69848 100755 (executable)
@@ -1539,6 +1539,7 @@ namespace MonoTests.System.Runtime.Serialization
                        var ds = new DataContractSerializer (typeof (DateTimeOffset));
                        var sw = new StringWriter ();
                        string xml = "<DateTimeOffset xmlns:i='http://www.w3.org/2001/XMLSchema-instance' xmlns='http://schemas.datacontract.org/2004/07/System'><DateTime>2011-03-01T02:05:06.078Z</DateTime><OffsetMinutes>120</OffsetMinutes></DateTimeOffset>".Replace ('\'', '"');
+                                               
                        var v = new DateTimeOffset (new DateTime (2011, 3, 1, 4, 5, 6, 78), TimeSpan.FromMinutes (120));
                        using (var xw = XmlWriter.Create (sw, settings)) {
                                ds.WriteObject (xw, v);
@@ -1546,6 +1547,21 @@ namespace MonoTests.System.Runtime.Serialization
                        Assert.AreEqual (xml, sw.ToString (), "#1");
                        Assert.AreEqual (v, ds.ReadObject (XmlReader.Create (new StringReader (sw.ToString ()))), "#2");
                }
+               
+               [Test]
+               public void DateTimeOffsetNullableSerialization ()
+               {
+                       var ds = new DataContractSerializer (typeof (DateTimeOffset?));
+                       var sw = new StringWriter ();
+                       string xml = "<DateTimeOffset xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns=\"http://schemas.datacontract.org/2004/07/System\"><DateTime>2012-05-04T00:34:00Z</DateTime><OffsetMinutes>120</OffsetMinutes></DateTimeOffset>";
+                       
+                       var v = new DateTimeOffset (new DateTime (2012, 05, 04, 02, 34, 0), TimeSpan.FromMinutes (120));
+                       using (var xw = XmlWriter.Create (sw, settings)) {
+                               ds.WriteObject (xw, v);
+                       }
+                       Assert.AreEqual (xml, sw.ToString (), "#1");
+                       Assert.AreEqual (v, ds.ReadObject (XmlReader.Create (new StringReader (sw.ToString ()))), "#2");
+               }
 
                [Test]
                public void XmlDocumentSupport ()
index 3b37219a904666b2c7c6b24c836114d326694e67..11df2ac0e035ee9c92ac277603d7974139d05b9a 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0e2c018fb9abc1a4ee527e00ca05ba4c6233d895..8a19ba33c947b306f5290a20a64385af44f23815 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 95f974bd0a9e68b78b56a8c7568bee988a416662..1685cec140cceb154c0ec23d9ecb95151f9f60f4 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 172112e49eaae110cc6f1a59cb0f535ad02f2461..168c69459d922fb3cbe14453c059c2c49ecf8009 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a0ec48254e4157f656fb781c5896aef76c07b305..db4d4a75b8cbddaad1d8206644a96b819707dd53 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3c5a1834ea901cea54aa7be5e6464afa1ef215dd..256c2541e4c7753b29fdad7f2c783238cd47f089 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1c0fe979dc5436d50a5c79678ea126d4dcf0ce62..9c070efe8f8f280cf9d2b0eaaa75185c831bae84 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c789dec546e4447ca9dd5040fd8852a67c2fec14..56ca91397277cbcf4d9468c84a7121fd909b8a19 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2dd0362b0f5fc33ae885ca890681653ee128a7d8..d7a07f9d29f4b4fbb35f23f7f157b4a3bcb7eec4 100644 (file)
@@ -73,7 +73,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ed648cfc41d111f999b7ac2a989447a81bfef31b..53c1a7f87cfa4d2cee6112e9069e73e88916ef47 100644 (file)
@@ -73,7 +73,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 740997cd9f6f139ccdb69f4fb412fecb796be84f..fd57e400845be7f3fd5eb612d95914171adb4547 100644 (file)
@@ -80,7 +80,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9abc90de15f8467b736b35e6b543381dafd8461d..4b3e696bc0ba1bb1404ade6894246d501b1a495a 100644 (file)
@@ -80,7 +80,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index cb382e59519761084b54c3aee43a2c81da4f6abe..891be5db3ee2b0c44fa287bbad83c4e0e9b6e818 100644 (file)
@@ -228,10 +228,12 @@ namespace System.Runtime.Serialization.Json
                        int exp = 0;
                        if (PeekChar () < 0)
                                throw new ArgumentException ("Invalid JSON numeric literal; incomplete exponent");
-
+                       
+                       bool negexp = false;
                        c = PeekChar ();
                        if (c == '-') {
                                ReadChar ();
+                               negexp = true;
                        }
                        else if (c == '+')
                                ReadChar ();
@@ -246,6 +248,8 @@ namespace System.Runtime.Serialization.Json
                                ReadChar ();
                        }
                        // it is messy to handle exponent, so I just use Decimal.Parse() with assured JSON format.
+                       if (negexp)
+                               return new Decimal ((double) (val + frac) / Math.Pow (10, exp));
                        int [] bits = Decimal.GetBits (val + frac);
                        return new Decimal (bits [0], bits [1], bits [2], negative, (byte) exp);
                }
index 58084224c311b7be148485e2db7e88d41b0d5f6d..804eeebd3206d129561c55e111b520e208be4fb6 100644 (file)
@@ -34,31 +34,31 @@ namespace System.Runtime.Serialization.Json
 {
        public static class JsonReaderWriterFactory
        {
-               public static XmlDictionaryReader CreateJsonReader (byte [] source, XmlDictionaryReaderQuotas quotas)
+               public static XmlDictionaryReader CreateJsonReader (byte [] buffer, XmlDictionaryReaderQuotas quotas)
                {
-                       if (source == null)
-                               throw new ArgumentNullException ("source");
-                       return CreateJsonReader (source, 0, source.Length, quotas);
+                       if (buffer == null)
+                               throw new ArgumentNullException ("buffer");
+                       return CreateJsonReader (buffer, 0, buffer.Length, quotas);
                }
 
-               public static XmlDictionaryReader CreateJsonReader (byte [] source, int offset, int length, XmlDictionaryReaderQuotas quotas)
+               public static XmlDictionaryReader CreateJsonReader (byte [] buffer, int offset, int count, XmlDictionaryReaderQuotas quotas)
                {
-                       return CreateJsonReader (source, offset, length, null, quotas, null);
+                       return CreateJsonReader (buffer, offset, count, null, quotas, null);
                }
 
-               public static XmlDictionaryReader CreateJsonReader (byte [] source, int offset, int length, Encoding encoding, XmlDictionaryReaderQuotas quotas, OnXmlDictionaryReaderClose readerClose)
+               public static XmlDictionaryReader CreateJsonReader (byte [] buffer, int offset, int count, Encoding encoding, XmlDictionaryReaderQuotas quotas, OnXmlDictionaryReaderClose onClose)
                {
-                       return new JsonReader (source, offset, length, encoding, quotas, readerClose);
+                       return new JsonReader (buffer, offset, count, encoding, quotas, onClose);
                }
 
-               public static XmlDictionaryReader CreateJsonReader (Stream source, XmlDictionaryReaderQuotas quotas)
+               public static XmlDictionaryReader CreateJsonReader (Stream stream, XmlDictionaryReaderQuotas quotas)
                {
-                       return CreateJsonReader (source, null, quotas, null);
+                       return CreateJsonReader (stream, null, quotas, null);
                }
 
-               public static XmlDictionaryReader CreateJsonReader (Stream source, Encoding encoding, XmlDictionaryReaderQuotas quotas, OnXmlDictionaryReaderClose readerClose)
+               public static XmlDictionaryReader CreateJsonReader (Stream stream, Encoding encoding, XmlDictionaryReaderQuotas quotas, OnXmlDictionaryReaderClose onClose)
                {
-                       return new JsonReader (source, encoding, quotas, readerClose);
+                       return new JsonReader (stream, encoding, quotas, onClose);
                }
 
                public static XmlDictionaryWriter CreateJsonWriter (Stream stream)
@@ -71,9 +71,9 @@ namespace System.Runtime.Serialization.Json
                        return CreateJsonWriter (stream, encoding, false);
                }
 
-               public static XmlDictionaryWriter CreateJsonWriter (Stream stream, Encoding encoding, bool closeOutput)
+               public static XmlDictionaryWriter CreateJsonWriter (Stream stream, Encoding encoding, bool ownsStream)
                {
-                       return new JsonWriter (stream, encoding, closeOutput);
+                       return new JsonWriter (stream, encoding, ownsStream);
                }
        }
 }
index 887701a3b7596f7ce573f105af6f91c644b13296..d03fad72f1b886b21484c7ba1e52298108a9f6ee 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 018bccfb48c923acd6c0ad983becdbc139c79f6b..8e584af2dad1af867b84f54235c3d9c0fa3d4c03 100644 (file)
@@ -97,7 +97,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7c6e7fd96d0371e765188e2b31295cbbed796adc..5553b522c2503d93c8616f0625fb9b71a2b89b2a 100644 (file)
@@ -97,7 +97,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d3982cd52e34da02f791aed39346a19b47e57a1c..c89474a190012f41df67cb7fef3495563f8c26db 100644 (file)
@@ -86,7 +86,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d744d5a6328cf42517ddc84917bfb9d8b2b894d3..94c060c5e9039617fa09c574f07229f302f29ec2 100644 (file)
@@ -86,7 +86,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 80819a9368fcf58aecfef266da9350c66b0f7ce1..5031b46efa6dd7004158f42cba70a5896b8a2b0f 100644 (file)
@@ -86,7 +86,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c1c0018ceae111d06ed5571ac0de0582669f54c3..9a1d2c5e50206fef8fc85494b592b243176cdee9 100644 (file)
@@ -250,11 +250,17 @@ namespace System
 
                        var us = baseAddress.LocalPath;
                        if (us [us.Length - 1] != '/')
-                               baseAddress = new Uri (baseAddress.GetComponents (UriComponents.SchemeAndServer | UriComponents.Path, UriFormat.Unescaped) + '/' + baseAddress.Query, baseAddress.IsAbsoluteUri ? UriKind.Absolute : UriKind.RelativeOrAbsolute);
+                               baseAddress = new Uri (
+                                       baseAddress.GetComponents (UriComponents.SchemeAndServer | UriComponents.Path, UriFormat.UriEscaped) + '/' + baseAddress.Query,
+                                       baseAddress.IsAbsoluteUri ? UriKind.Absolute : UriKind.RelativeOrAbsolute
+                               );
                        if (IgnoreTrailingSlash) {
                                us = candidate.LocalPath;
                                if (us.Length > 0 && us [us.Length - 1] != '/')
-                                       candidate = new Uri(candidate.GetComponents (UriComponents.SchemeAndServer | UriComponents.Path, UriFormat.Unescaped) + '/' + candidate.Query, candidate.IsAbsoluteUri ? UriKind.Absolute : UriKind.RelativeOrAbsolute);
+                                       candidate = new Uri (
+                                               candidate.GetComponents (UriComponents.SchemeAndServer | UriComponents.Path, UriFormat.UriEscaped) + '/' + candidate.Query,
+                                               candidate.IsAbsoluteUri ? UriKind.Absolute : UriKind.RelativeOrAbsolute
+                                       );
                        }
 
                        int i = 0, c = 0;
@@ -264,7 +270,11 @@ namespace System
                        m.RequestUri = candidate;
                        var vc = m.BoundVariables;
 
-                       string cp = Uri.UnescapeDataString (baseAddress.MakeRelativeUri (new Uri (baseAddress, candidate.GetComponents (UriComponents.PathAndQuery, UriFormat.Unescaped))).ToString ());
+                       string cp = baseAddress.MakeRelativeUri (new Uri (
+                               baseAddress,
+                               candidate.GetComponents (UriComponents.PathAndQuery, UriFormat.UriEscaped)
+                       ))
+                               .ToString ();
                        if (IgnoreTrailingSlash && cp [cp.Length - 1] == '/')
                                cp = cp.Substring (0, cp.Length - 1);
 
@@ -279,7 +289,7 @@ namespace System
 
                        foreach (string name in path) {
                                if (name == wild_path_name) {
-                                       vc [name] = cp.Substring (c); // all remaining paths.
+                                       vc [name] = Uri.UnescapeDataString (cp.Substring (c)); // all remaining paths.
                                        continue;
                                }
                                int n = StringIndexOf (template, '{' + name + '}', i);
@@ -291,10 +301,11 @@ namespace System
                                if (ce < 0)
                                        ce = cp.Length;
                                string value = cp.Substring (c, ce - c);
+                               string unescapedVaule = Uri.UnescapeDataString (value);
                                if (value.Length == 0)
                                        return null; // empty => mismatch
-                               vc [name] = value;
-                               m.RelativePathSegments.Add (value);
+                               vc [name] = unescapedVaule;
+                               m.RelativePathSegments.Add (unescapedVaule);
                                c += value.Length;
                        }
                        int tEnd = template.IndexOf ('?');
index 8455ce59340f4bfe89e540b7f17811b9a3331203..de260c1b1af19156c2f626e5bb89fe300199196f 100644 (file)
@@ -502,5 +502,19 @@ namespace MonoTests.System
                        Assert.IsNotNull (match, "#1");
                        Assert.AreEqual ("something", match.BoundVariables ["path"], "#2");
                }
+
+        [Test]
+        public void EscapedUriCandidate ()
+        {
+            var candidateUri = new Uri (@"https://somehost:12345/path1/path2/path3/endprefix/tpath1/guid1/tpath2/~|~~|~%3F~|~Path{guid2}~|~/tpath3");
+            var matchUri = new Uri (candidateUri.Scheme + "://" + candidateUri.Host + ":" + candidateUri.Port + @"/path1/path2/path3/endprefix");
+            
+            var template = new UriTemplate (@"tpath1/{guid}/tpath2/{encodedGuidString}/tpath3");
+            var match = template.Match (matchUri, candidateUri);
+
+            Assert.IsNotNull (match);
+            Assert.That (match.BoundVariables ["GUID"] == "guid1");
+            Assert.That (match.BoundVariables ["ENCODEDGUIDSTRING"] == "~|~~|~?~|~Path{guid2}~|~");
+        }
        }
 }
index 746487c231c7410c026d6ec8d5c80979246b8cc8..85f8666ad662c6b7bbc8c578ccaf06c163b4abe2 100755 (executable)
@@ -47,6 +47,7 @@ TEST_EXTRA_FILES = \
        Test/Resources/* \
        Test/XmlFiles/* \
        Test/System.ServiceModel.Channels/soap-fault*.xml \
+       Test/System.ServiceModel.Channels/binary-message.raw \
        Test/System.ServiceModel.Description/dump.xml
 
 EXTRA_DISTFILES = $(RESOURCE_FILES) $(TEST_EXTRA_FILES)
index 49bdf7363d390e70343eb1f8d2ea19f0b778024b..53151b9a561e9a879387527e306dc9351c7653e3 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 59834fdd06452d02dcfc89e20008847a467d5604..52c0f7dfc1935ae0f4e899b781d637f38680dda0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0fa326f35df44cb5d5d90ccc531fdb5c617f0150..8feaff9117210b34164a17a856790fb7028b0ee4 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4b82481bcee579363a49c3d7db1548841d0833c0..52bee585d16d73f3eff3cc02a8bf95bc56e7519d 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5a28b12ebefb280cf5e42d42bcfc4a887f22e25c..abb8d9515fb7da1b476b8bbeb1eb4a94c5564f50 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0eab9535f495d669ef09963cdcdea7079918e266..c79832e462920df026df78ea7b9078b2fa422c05 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f24837bf9f09b4f2a923427964cfca8339cacfe0..21ed1e2ec1e8ddc98957b3f7c0f21579dd9c89bf 100644 (file)
@@ -79,7 +79,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1b40f9aae9133e0d3bdc1b6ac00868a88f4ad452..af0d981bd16a62e46dafe3365468860e9cf0c097 100644 (file)
@@ -79,7 +79,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index dee98c50bf5441e82b5084a7cd8de8db33c21bcd..21a6cdc737a54574a2f271a6149b8c0c51d5c0d0 100644 (file)
@@ -79,7 +79,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e9b7004c41abd4db6e7d08e7b7de2db6396a34d5..1600092ae568ba3708d1fadabae5c4a0831817d3 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1572db7eceee5e3404015e8b17114840ec98b665..cc30dfd392f1b2aaa7912496427466c1052ec032 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5875a4e7cbc2bc8edcc3e0212715aaa3a73af7da..017c4265ee060204330117fc3878b0a02dec871f 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3f82d310c84aa7b14526da2bd2e559bf7cbacd9f..a91c8354b32465a709570fc65d0c0bb7e2fc35c8 100644 (file)
@@ -7,3 +7,5 @@ LIBRARY = System.Threading.Tasks.Dataflow.dll
 include ../../build/library.make
 
 LIB_MCS_FLAGS += -r:$(corlib) -r:System.Core.dll -r:System.dll
+
+TEST_MCS_FLAGS = -r:System.Core.dll
index f7053c42dd4529b16f46ce2810895dccd3538175..ca8339c936fecd8f369a2e6a807ecf3686bbf084 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d80879f2ed1c9beb86544b617766d5aba5c64a29..451758474a1025b54074cff085217d51be73c7b2 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_5/System.Threading.Tasks.Dataflow.dll</HintPath>
     </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index dd4e6dc290024915265923ffe18eaac2d6f31280..5a9c3a4fa9145996b8272b4e1998d6dde6c3ec98 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8a310f95bc422e23e0a21328cb3eb0951ce728d4..ed9bc00d54f05bc2e852d49a4b737910adc85df9 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9ee840738f4f68e6a999ab00ccb36f24e1fc7041..3962fea9a5464fd26020ee81ee388b12fd204b57 100644 (file)
@@ -89,7 +89,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 55e9520664de7baf01bf7ed5bc8d7c112518e54f..1e9551f9363cb9d844629a9d0753b78f89d82acb 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 53991a484fbacff669bda96bc995907f8227607a..9c15be90f2f54369669f578a94ae79b79f54c179 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7012428faf2f4011aa078fe159cac6ba604b61a5..e34e7cd04024fd4004a340cd53afbcd213bb55b1 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f5db8177afe61bf4bc19d4de3191d4161b6c3497..292e3c7078799e54ecfaad38d97a3299524b9609 100644 (file)
@@ -76,7 +76,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 0799d0416be96d2e5fb4509f851b2ffa1cb6bca6..8ca447473d609b3cb14f52af18a990b211306ebb 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a536a4a4dcc726f645ccee76bfe6267c255d8395..44311e5960df33bc64584bcf202b2219b967bccf 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d68eeff9b55d7a442bd8e61ebadc40af8c8b2dc8..46566a9468655d2b24829e9da0a3d66d36a4a692 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 85d740a91671c8827eb17b602c97c3ebf5c3d258..13b2b0fdb269684db082526e08fdaa54fe61bc2b 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 588da8b05181da8f1e9d270c99df53b831a98471..6e3361bd613f286bd91808d85a8ec18dc6c45da5 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 013bfc583d811f3b758dac8eb96ca4028b032609..6eae8969564f62ee64c1fd4b3df621de0c5f7bce 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 670400b5ae7a4d72a639bf1dc2b8c1c24c42725b..b24054e8429d51f3163e601db48f9922f6244f61 100644 (file)
@@ -70,7 +70,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 28720394f9d383fd891ad8695ccb8064008bff42..4fab48e98ad24e7f4ec08602f6a7cdd034adce4f 100644 (file)
@@ -70,7 +70,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2f5843ab5a51f39c58ff04e4a1002170e6a1f37d..fed5597fa5041e137b87ceea97e6fe4227f37c35 100644 (file)
@@ -175,7 +175,8 @@ TEST_RESOURCE_FILES = \
 
 NUNIT_RESOURCE_FILES = $(TEST_RESOURCE_FILES)
 
-TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) -r:System.ComponentModel.DataAnnotations.dll -r:System.Configuration.dll $(NUNIT_RESOURCE_FILES:%=/resource:%) -r:SystemWebTestShim.dll
+TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) -r:System.ComponentModel.DataAnnotations.dll -r:System.Configuration.dll \
+       $(NUNIT_RESOURCE_FILES:%=/resource:%) -r:SystemWebTestShim.dll -r:System.Xml.dll
 
 ifeq (4, $(FRAMEWORK_VERSION_MAJOR))
 TEST_MCS_FLAGS += -r:System.Web.ApplicationServices.dll
index a15b5d49a3961fa997f8cdaeae81335210e58e4b..d3236d88fa398a64e4fbc530e4dc701ed6954feb 100644 (file)
@@ -91,7 +91,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c201459daf53e92e2853749dbed9122acc370a7e..4436df79c1c5f3c916681b919c401d679ef3839c 100644 (file)
@@ -91,7 +91,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d1a55b21fe7c01c5cd0ce9d7212083abe04e41ae..b4c8c994659b3b3fa820c2d43766277761cd6c4e 100644 (file)
@@ -91,7 +91,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9866140d2c3aae731dff66b80f673423af215237..2e8df7622f3d8dcca96fedc0dfc7aba2d7de0046 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>SystemWebTestShim.dll</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index 44fdf895dfcbd3cc31c9afda17c15848e47683d2..f1520ade7b72a0e1b39ed365603ddde90918e477 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>SystemWebTestShim.dll</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="System.Web.ApplicationServices.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Web.ApplicationServices.dll</HintPath>
index 9e3a5e7f04488ee34c14e3e380cbdd1b07f9122f..644fa129e36aaa03ca8dad16197f6c63d13cc6bd 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>SystemWebTestShim.dll</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
     <Reference Include="System.Web.ApplicationServices.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Web.ApplicationServices.dll</HintPath>
index 6b1b5f51e7c54199a7b31f851131f9512097f546..039f1d293f96cb6db448e0a57880328b8dadaa0e 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f29e09fcd149ee142c93cd329b28aee8fa3dd152..2a13626150e59d531266252e41a01e209a0c4d68 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d8145c84676469b969df8c0248ceac612b035e99..014233632c64adb03dae56e59e0e1d13cbea355d 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3acb85962f6ac8358f0748283c085eddc29b38e5..83fede20fe0dadbd98b7bb6408c5dbcc04b91186 100644 (file)
@@ -67,7 +67,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4a4daa9f8b6518e98c21a0f0ca3da42f6c3d8586..408e82858d86934fe3cf1529b8f6bba04c9492c4 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 88a17e01f0c863a2818aa2692491a27a51a32b80..8cae01cac7a53f0685f9f1748dfe35a972cf8333 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f7202e13675e0bf965e7eca30a7a2b2622e3ffbc..6f4ed6d6e4fad64d6a70a8af187feb5bc4583ed1 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 76a66935d405ab7588548110b7fbf8743be1ef92..3ec1c00cc9bbc3b162ee3f94c28682d3e7fd47ff 100644 (file)
@@ -136,17 +136,16 @@ namespace System.Web.Handlers
 \r
                        long atime;\r
                        DateTime modifiedSince;\r
-                       bool hasCacheControl = HasCacheControl (request, request.QueryString, out atime);\r
                        bool hasIfModifiedSince = HasIfModifiedSince (context.Request, out modifiedSince);\r
                        \r
-                       if (hasCacheControl || hasIfModifiedSince) {\r
+                       if (hasIfModifiedSince) {\r
                                bool notModified = true;\r
                        \r
                                foreach (CompositeEntry entry in entries) {\r
                                        if (entry == null)\r
                                                continue;\r
                                        if (notModified) {\r
-                                               if ((hasCacheControl && entry.IsModifiedSince (atime)) || (hasIfModifiedSince && entry.IsModifiedSince (modifiedSince)))\r
+                                               if (hasIfModifiedSince && entry.IsModifiedSince (modifiedSince))\r
                                                        notModified = false;\r
                                        }\r
                                }\r
index c80e5a7439a87a234b6afef46cfa6288c2b3d731..51b4c95eb9f99befd0ca354f6785e52b10f914c0 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
diff --git a/mcs/class/System.Web.Http/Makefile b/mcs/class/System.Web.Http/Makefile
new file mode 100644 (file)
index 0000000..488e020
--- /dev/null
@@ -0,0 +1,21 @@
+thisdir = class/System.Web.Http
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Web.Http.dll
+
+System.Web.Http.Properties.CommonWebApiResources.resources: ../../../external/aspnetwebstack/src/Common/CommonWebApiResources.resx
+       $(RESGEN) "$<" "$@"
+       
+System.Web.Http.Properties.SRResources.resources: ../../../external/aspnetwebstack/src/System.Web.Http/Properties/SRResources.resx
+       $(RESGEN) "$<" "$@"
+
+
+LIB_MCS_FLAGS = -r:System.Core.dll -r:System.dll -r:System.Xml.dll -r:System.Net.Http.dll -r:System.ComponentModel.DataAnnotations.dll \
+               -r:System.Net.Http.Formatting.dll -r:System.Runtime.Caching.dll -r:System.Runtime.Serialization.dll -r:System.Data.Linq.dll \
+               -d:ASPNETMVC -keyfile:../winfx.pub -delaysign
+
+include ../../build/library.make
+
+$(the_lib): System.Web.Http.Properties.CommonWebApiResources.resources \
+       System.Web.Http.Properties.SRResources.resources
\ No newline at end of file
diff --git a/mcs/class/System.Web.Http/System.Web.Http-net_4_5.csproj b/mcs/class/System.Web.Http/System.Web.Http-net_4_5.csproj
new file mode 100644 (file)
index 0000000..3b29f0f
--- /dev/null
@@ -0,0 +1,365 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <NoWarn>1699</NoWarn>\r
+    <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
+    <NoStdLib>true</NoStdLib>\r
+    \r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <RootNamespace></RootNamespace>\r
+    <AssemblyName>System.Web.Http</AssemblyName>\r
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>\r
+    <FileAlignment>512</FileAlignment>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>false</Optimize>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETMVC</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>true</Optimize>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETMVC</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <ItemGroup>\r
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\RS.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\AptcaCommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\DictionaryExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\Error.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\HttpMethodHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\PrefixContainer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\TaskHelpers.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\TaskHelpersExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\Common\CommonWebApiResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\AcceptVerbsAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ActionNameAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\AllowAnonymousAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ApiController.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\AuthorizeAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\ApiControllerActionInvoker.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\ApiControllerActionSelector.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\HttpActionBinding.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\HttpActionContext.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\HttpActionContextExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\HttpActionDescriptor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\HttpControllerConfigurationAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\HttpControllerContext.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\HttpControllerDescriptor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\HttpParameterBinding.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\HttpParameterDescriptor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\IActionHttpMethodProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\IActionMethodSelector.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\IActionResultConverter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\IActionValueBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\IHttpActionInvoker.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\IHttpActionSelector.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\IHttpController.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\ReflectedHttpActionDescriptor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\ReflectedHttpParameterDescriptor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\ResponseMessageResultConverter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\ValueResultConverter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Controllers\VoidResultConverter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dependencies\EmptyResolver.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dependencies\IDependencyResolver.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dependencies\IDependencyScope.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Description\ApiDescription.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Description\ApiExplorer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Description\ApiExplorerSettingsAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Description\ApiParameterDescription.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Description\ApiParameterSource.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Description\IApiExplorer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Description\IDocumentationProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\DefaultAssembliesResolver.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\DefaultHttpControllerActivator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\DefaultHttpControllerSelector.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\DefaultHttpControllerTypeResolver.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\ExceptionSurrogate.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\HttpControllerDispatcher.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\HttpControllerTypeCache.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\IAssembliesResolver.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\IHttpControllerActivator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\IHttpControllerSelector.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Dispatcher\IHttpControllerTypeResolver.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\ActionDescriptorFilterProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\ActionFilterAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\AuthorizationFilterAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\ConfigurationFilterProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\ExceptionFilterAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\FilterAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\FilterInfoComparer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\FilterInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\FilterScope.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\HttpActionExecutedContext.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\HttpFilterCollection.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\IActionFilter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\IAuthorizationFilter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\IExceptionFilter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\IFilter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Filters\IFilterProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\FromBodyAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\FromUriAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Hosting\HttpPipelineFactory.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Hosting\HttpPropertyKeys.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpBindNeverAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpBindRequiredAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpConfiguration.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpDeleteAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpGetAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpHeadAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpOptionsAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpPatchAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpPostAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpPutAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpRequestMessageExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpResponseException.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpResponseMessageExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpRouteCollection.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpRouteCollectionExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\HttpServer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\IncludeErrorDetailPolicy.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\CollectionModelBinderUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\DataTypeUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\HttpActionContextExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\HttpParameterBindingExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\MemberInfoExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\ParameterInfoExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\TypeActivator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\TypeDescriptorHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\TypeHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Internal\UriQueryUtility.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Metadata\ModelMetadata.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Metadata\ModelMetadataProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Metadata\Providers\AssociatedMetadataProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Metadata\Providers\CachedDataAnnotationsMetadataAttributes.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Metadata\Providers\CachedDataAnnotationsModelMetadata.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Metadata\Providers\CachedModelMetadata.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Metadata\Providers\DataAnnotationsModelMetadataProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Metadata\Providers\EmptyMetadataProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\ArrayModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\ArrayModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\BinaryDataModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\CollectionModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\CollectionModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\ComplexModelDto.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\ComplexModelDtoModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\ComplexModelDtoModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\ComplexModelDtoResult.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\CompositeModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\CompositeModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\DictionaryModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\DictionaryModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\GenericModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\KeyValuePairModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\KeyValuePairModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\MutableObjectModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\MutableObjectModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\SimpleModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\TypeConverterModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\TypeConverterModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\TypeMatchModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\Binders\TypeMatchModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\CancellationTokenParameterBinding.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\CustomModelBinderAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\DefaultActionValueBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ErrorParameterBinding.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\FormatterParameterBinding.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\FormDataCollectionExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\HttpBindingBehaviorAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\HttpBindingBehavior.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\HttpRequestParameterBinding.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\IModelBinder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\JQueryMVCFormUrlEncodedFormatter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelBinderAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelBinderConfig.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelBinderErrorMessageProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelBinderParameterBinding.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelBinderProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelBindingContext.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelBindingHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelErrorCollection.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelError.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelState.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ModelBinding\ModelStateDictionary.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\NonActionAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Properties\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Properties\SRResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\QueryableAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Query\DynamicQueryable.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Query\ODataQueryDeserializer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Query\ParseException.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Query\QueryComposer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Query\QueryResolver.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Query\QueryValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Query\ServiceQuery.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Query\ServiceQueryPart.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\RouteParameter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\BoundRouteTemplate.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\HttpMethodConstraint.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\HttpParsedRoute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\HttpRoute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\HttpRouteData.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\HttpRouteDirection.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\HttpRouteParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\HttpRouteValueDictionary.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\HttpVirtualPathData.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\IHttpRouteConstraint.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\IHttpRoute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\IHttpRouteData.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\IHttpVirtualPathData.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\MediaTypeFormatterExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\PathContentSegment.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\PathLiteralSubsegment.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\PathParameterSubsegment.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\PathSegment.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\PathSeparatorSegment.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\PathSubsegment.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\UriPathExtensionMapping.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Routing\UrlHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Services\DefaultServices.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ServicesExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\FormattingUtilities.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\IFormatterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\ITraceManager.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\ITraceWriter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\ITraceWriterExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\TraceCategories.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\TraceKind.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\TraceLevel.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\TraceManager.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\TraceRecord.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\ActionFilterAttributeTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\ActionFilterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\ActionValueBinderTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\AuthorizationFilterAttributeTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\AuthorizationFilterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\BufferedMediaTypeFormatterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\ContentNegotiatorTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\ExceptionFilterAttributeTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\ExceptionFilterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\FilterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\FormatterParameterBindingTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\FormUrlEncodedMediaTypeFormatterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\HttpActionBindingTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\HttpActionDescriptorTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\HttpActionInvokerTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\HttpActionSelectorTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\HttpControllerActivatorTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\HttpControllerDescriptorTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\HttpControllerSelectorTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\HttpControllerTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\HttpParameterBindingTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\JsonMediaTypeFormatterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\MediaTypeFormatterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\MessageHandlerTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\RequestMessageHandlerTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Tracing\Tracers\XmlMediaTypeFormatterTracer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\DefaultBodyModelValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\IBodyModelValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\ModelStateFormatterLogger.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\ModelValidatedEventArgs.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\ModelValidatingEventArgs.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\ModelValidationNode.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\ModelValidationRequiredMemberSelector.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\ModelValidationResult.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\ModelValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\ModelValidatorProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\Providers\AssociatedValidatorProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\Providers\DataAnnotationsModelValidatorProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\Providers\DataMemberModelValidatorProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\Providers\RequiredMemberModelValidatorProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\Validators\DataAnnotationsModelValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\Validators\RequiredMemberModelValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\Validation\Validators\ValidatableObjectAdapter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\IEnumerableValueProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\IUriValueProviderFactory.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\IValueProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\Providers\CompositeValueProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\Providers\CompositeValueProviderFactory.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\Providers\ElementalValueProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\Providers\NameValueCollectionValueProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\Providers\QueryStringValueProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\Providers\QueryStringValueProviderFactory.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\Providers\RouteDataValueProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\Providers\RouteDataValueProviderFactory.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\ValueProviderAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\ValueProviderFactory.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Http\ValueProviders\ValueProviderResult.cs" />
+\r
+  </ItemGroup>\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+  <PropertyGroup>\r
+    <PreBuildEvent></PreBuildEvent>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="mscorlib.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>mscorlib.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Net.Http.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Net.Http.dll</HintPath>
+    </Reference>
+    <Reference Include="System.ComponentModel.DataAnnotations.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.ComponentModel.DataAnnotations.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Net.Http.Formatting.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Net.Http.Formatting.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Runtime.Caching.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Runtime.Caching.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Runtime.Serialization.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Runtime.Serialization.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Data.Linq.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Data.Linq.dll</HintPath>
+    </Reference>
+\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Folder Include="Properties\" />\r
+  </ItemGroup>\r
+  \r
+</Project>\r
+
diff --git a/mcs/class/System.Web.Http/System.Web.Http.dll.sources b/mcs/class/System.Web.Http/System.Web.Http.dll.sources
new file mode 100644 (file)
index 0000000..7b85a79
--- /dev/null
@@ -0,0 +1,266 @@
+../../../external/aspnetwebstack/src/CommonAssemblyInfo.cs
+../../../external/aspnetwebstack/src/RS.cs
+../../../external/aspnetwebstack/src/AptcaCommonAssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/Common/DictionaryExtensions.cs
+../../../external/aspnetwebstack/src/Common/Error.cs
+../../../external/aspnetwebstack/src/Common/HttpMethodHelper.cs
+../../../external/aspnetwebstack/src/Common/PrefixContainer.cs
+../../../external/aspnetwebstack/src/Common/TaskHelpers.cs
+../../../external/aspnetwebstack/src/Common/TaskHelpersExtensions.cs
+../../../external/aspnetwebstack/src/Common/CommonWebApiResources.Designer.cs
+
+../../../external/aspnetwebstack/src/System.Web.Http/AcceptVerbsAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ActionNameAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/AllowAnonymousAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ApiController.cs
+../../../external/aspnetwebstack/src/System.Web.Http/AuthorizeAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/ApiControllerActionInvoker.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/ApiControllerActionSelector.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/HttpActionBinding.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/HttpActionContext.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/HttpActionContextExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/HttpActionDescriptor.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/HttpControllerConfigurationAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/HttpControllerContext.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/HttpControllerDescriptor.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/HttpParameterBinding.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/HttpParameterDescriptor.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/IActionHttpMethodProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/IActionMethodSelector.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/IActionResultConverter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/IActionValueBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/IHttpActionInvoker.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/IHttpActionSelector.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/IHttpController.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/ReflectedHttpActionDescriptor.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/ReflectedHttpParameterDescriptor.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/ResponseMessageResultConverter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/ValueResultConverter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Controllers/VoidResultConverter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dependencies/EmptyResolver.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dependencies/IDependencyResolver.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dependencies/IDependencyScope.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Description/ApiDescription.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Description/ApiExplorer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Description/ApiExplorerSettingsAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Description/ApiParameterDescription.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Description/ApiParameterSource.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Description/IApiExplorer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Description/IDocumentationProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/DefaultAssembliesResolver.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/DefaultHttpControllerActivator.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/DefaultHttpControllerSelector.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/DefaultHttpControllerTypeResolver.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/ExceptionSurrogate.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/HttpControllerDispatcher.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/HttpControllerTypeCache.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/IAssembliesResolver.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/IHttpControllerActivator.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/IHttpControllerSelector.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Dispatcher/IHttpControllerTypeResolver.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/ActionDescriptorFilterProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/ActionFilterAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/AuthorizationFilterAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/ConfigurationFilterProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/ExceptionFilterAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/FilterAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/FilterInfoComparer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/FilterInfo.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/FilterScope.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/HttpActionExecutedContext.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/HttpFilterCollection.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/IActionFilter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/IAuthorizationFilter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/IExceptionFilter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/IFilter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Filters/IFilterProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/FromBodyAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/FromUriAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Hosting/HttpPipelineFactory.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Hosting/HttpPropertyKeys.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpBindNeverAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpBindRequiredAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpConfiguration.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpDeleteAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpGetAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpHeadAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpOptionsAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpPatchAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpPostAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpPutAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpRequestMessageExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpResponseException.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpResponseMessageExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpRouteCollection.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpRouteCollectionExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/HttpServer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/IncludeErrorDetailPolicy.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/CollectionModelBinderUtil.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/DataTypeUtil.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/HttpActionContextExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/HttpParameterBindingExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/MemberInfoExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/ParameterInfoExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/TypeActivator.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/TypeDescriptorHelper.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/TypeHelper.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Internal/UriQueryUtility.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Metadata/ModelMetadata.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Metadata/ModelMetadataProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Metadata/Providers/AssociatedMetadataProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Metadata/Providers/CachedDataAnnotationsMetadataAttributes.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Metadata/Providers/CachedDataAnnotationsModelMetadata.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Metadata/Providers/CachedModelMetadata.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Metadata/Providers/DataAnnotationsModelMetadataProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Metadata/Providers/EmptyMetadataProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/ArrayModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/ArrayModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/BinaryDataModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/CollectionModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/CollectionModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/ComplexModelDto.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/ComplexModelDtoModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/ComplexModelDtoModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/ComplexModelDtoResult.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/CompositeModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/CompositeModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/DictionaryModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/DictionaryModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/GenericModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/KeyValuePairModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/KeyValuePairModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/MutableObjectModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/MutableObjectModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/SimpleModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/TypeConverterModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/TypeConverterModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/TypeMatchModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/Binders/TypeMatchModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/CancellationTokenParameterBinding.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/CustomModelBinderAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/DefaultActionValueBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ErrorParameterBinding.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/FormatterParameterBinding.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/FormDataCollectionExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/HttpBindingBehaviorAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/HttpBindingBehavior.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/HttpRequestParameterBinding.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/IModelBinder.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/JQueryMVCFormUrlEncodedFormatter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelBinderAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelBinderConfig.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelBinderErrorMessageProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelBinderParameterBinding.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelBinderProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelBindingContext.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelBindingHelper.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelErrorCollection.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelError.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelState.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ModelBinding/ModelStateDictionary.cs
+../../../external/aspnetwebstack/src/System.Web.Http/NonActionAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Properties/AssemblyInfo.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Properties/SRResources.Designer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/QueryableAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Query/DynamicQueryable.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Query/ODataQueryDeserializer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Query/ParseException.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Query/QueryComposer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Query/QueryResolver.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Query/QueryValidator.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Query/ServiceQuery.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Query/ServiceQueryPart.cs
+../../../external/aspnetwebstack/src/System.Web.Http/RouteParameter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/BoundRouteTemplate.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/HttpMethodConstraint.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/HttpParsedRoute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/HttpRoute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/HttpRouteData.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/HttpRouteDirection.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/HttpRouteParser.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/HttpRouteValueDictionary.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/HttpVirtualPathData.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/IHttpRouteConstraint.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/IHttpRoute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/IHttpRouteData.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/IHttpVirtualPathData.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/MediaTypeFormatterExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/PathContentSegment.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/PathLiteralSubsegment.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/PathParameterSubsegment.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/PathSegment.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/PathSeparatorSegment.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/PathSubsegment.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/UriPathExtensionMapping.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Routing/UrlHelper.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Services/DefaultServices.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ServicesExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/FormattingUtilities.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/IFormatterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/ITraceManager.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/ITraceWriter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/ITraceWriterExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/TraceCategories.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/TraceKind.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/TraceLevel.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/TraceManager.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/TraceRecord.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/ActionFilterAttributeTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/ActionFilterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/ActionValueBinderTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/AuthorizationFilterAttributeTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/AuthorizationFilterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/BufferedMediaTypeFormatterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/ContentNegotiatorTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/ExceptionFilterAttributeTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/ExceptionFilterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/FilterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/FormatterParameterBindingTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/FormUrlEncodedMediaTypeFormatterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/HttpActionBindingTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/HttpActionDescriptorTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/HttpActionInvokerTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/HttpActionSelectorTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/HttpControllerActivatorTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/HttpControllerDescriptorTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/HttpControllerSelectorTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/HttpControllerTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/HttpParameterBindingTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/JsonMediaTypeFormatterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/MediaTypeFormatterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/MessageHandlerTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/RequestMessageHandlerTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Tracing/Tracers/XmlMediaTypeFormatterTracer.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/DefaultBodyModelValidator.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/IBodyModelValidator.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/ModelStateFormatterLogger.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/ModelValidatedEventArgs.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/ModelValidatingEventArgs.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/ModelValidationNode.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/ModelValidationRequiredMemberSelector.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/ModelValidationResult.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/ModelValidator.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/ModelValidatorProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/Providers/AssociatedValidatorProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/Providers/DataAnnotationsModelValidatorProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/Providers/DataMemberModelValidatorProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/Providers/RequiredMemberModelValidatorProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/Validators/DataAnnotationsModelValidator.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/Validators/RequiredMemberModelValidator.cs
+../../../external/aspnetwebstack/src/System.Web.Http/Validation/Validators/ValidatableObjectAdapter.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/IEnumerableValueProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/IUriValueProviderFactory.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/IValueProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/Providers/CompositeValueProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/Providers/CompositeValueProviderFactory.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/Providers/ElementalValueProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/Providers/NameValueCollectionValueProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/Providers/QueryStringValueProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/Providers/QueryStringValueProviderFactory.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/Providers/RouteDataValueProvider.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/Providers/RouteDataValueProviderFactory.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/ValueProviderAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/ValueProviderFactory.cs
+../../../external/aspnetwebstack/src/System.Web.Http/ValueProviders/ValueProviderResult.cs
index f855cb015d150c221642f0eb1ef5d514eca98aeb..ef38048aa6556d111a5b5f17d6b4c50f2ea2289c 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d6663c86549a2a654d80ea81c46c5f9c3eac196c..8b73a95caa1202c354e9bc278ca44a9137137062 100644 (file)
@@ -10,7 +10,6 @@ RESX_DIST =  System.Web.Mvc/Resources/MvcResources.resx
 
 LIB_MCS_FLAGS = \
                /warn:1 \
-               /noconfig \
                /keyfile:../winfx.pub \
                /r:System.dll \
                /r:System.Core.dll \
index 4503aa64ddea1eb13091a85dda55b4c3939b4ac3..572a2e169f040f7522ff0b55e5beb1c6809ff911 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 87e5e78310ff3b69dd58f5067605abd3a35b0aa0..2e743562ac5f1ca2ef0848e358a6782e2cd7fa90 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index be5bcf2a00fd41af61de74893d755a36c585a8f9..6679eb6130c1c3693e94fd0b074c89f1b74eaad3 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
diff --git a/mcs/class/System.Web.Mvc3/GlobalAssemblyInfo.cs b/mcs/class/System.Web.Mvc3/GlobalAssemblyInfo.cs
new file mode 100644 (file)
index 0000000..322630d
--- /dev/null
@@ -0,0 +1,12 @@
+using System.Reflection;
+using System.Resources;
+
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("Microsoft Corporation")]
+[assembly: AssemblyProduct("Microsoft® .NET Framework")]
+[assembly: AssemblyCopyright("© Microsoft Corporation. All rights reserved.")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+[assembly: AssemblyVersion("3.0.0.0")]
+[assembly: AssemblyFileVersion("3.0.20107.0")]
+[assembly: NeutralResourcesLanguage("en-US")]
diff --git a/mcs/class/System.Web.Mvc3/GlobalSuppressions.cs b/mcs/class/System.Web.Mvc3/GlobalSuppressions.cs
new file mode 100644 (file)
index 0000000..f3998e9
--- /dev/null
@@ -0,0 +1,18 @@
+// This file is used by Code Analysis to maintain SuppressMessage 
+// attributes that are applied to this project. 
+// Project-level suppressions either have no target or are given 
+// a specific target and scoped to a namespace, type, member, etc. 
+//
+// To add a suppression to this file, right-click the message in the 
+// Error List, point to "Suppress Message(s)", and click 
+// "In Project Suppression File". 
+// You do not need to add suppressions to this file manually. 
+
+using System.Diagnostics.CodeAnalysis;
+
+[assembly: SuppressMessage("Microsoft.Design", "CA2210:AssembliesShouldHaveValidStrongNames", Justification = "Assembly is delay-signed.")]
+[assembly: SuppressMessage("Microsoft.Design", "CA1020:AvoidNamespacesWithFewTypes", Scope = "namespace", Target = "System.Web.Mvc.Ajax", Justification = "Helpers reside within a separate namespace to support alternate helper classes.")]
+[assembly: SuppressMessage("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes", Scope = "member", Target = "System.Web.Mvc.TempDataDictionary.#System.Collections.Generic.ICollection`1<System.Collections.Generic.KeyValuePair`2<System.String,System.Object>>.Contains(System.Collections.Generic.KeyValuePair`2<System.String,System.Object>)", Justification = "There are no defined scenarios for wanting to derive from this class, but we don't want to prevent it either.")]
+[assembly: SuppressMessage("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes", Scope = "member", Target = "System.Web.Mvc.TempDataDictionary.#System.Collections.Generic.ICollection`1<System.Collections.Generic.KeyValuePair`2<System.String,System.Object>>.CopyTo(System.Collections.Generic.KeyValuePair`2<System.String,System.Object>[],System.Int32)", Justification = "There are no defined scenarios for wanting to derive from this class, but we don't want to prevent it either.")]
+[assembly: SuppressMessage("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes", Scope = "member", Target = "System.Web.Mvc.TempDataDictionary.#System.Collections.Generic.ICollection`1<System.Collections.Generic.KeyValuePair`2<System.String,System.Object>>.IsReadOnly", Justification = "There are no defined scenarios for wanting to derive from this class, but we don't want to prevent it either.")]
+[assembly: SuppressMessage("Microsoft.Naming", "CA1703:ResourceStringsShouldBeSpelledCorrectly", MessageId = "Param", Scope = "resource", Target = "System.Web.Mvc.Resources.MvcResources.resources", Justification = "This is the name that matches ASP.NET")]
diff --git a/mcs/class/System.Web.Mvc3/Makefile b/mcs/class/System.Web.Mvc3/Makefile
new file mode 100644 (file)
index 0000000..f420f12
--- /dev/null
@@ -0,0 +1,41 @@
+thisdir = class/System.Web.Mvc3
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Web.Mvc3.dll
+LIBRARY_NAME = System.Web.Mvc.dll
+LIBRARY_USE_INTERMEDIATE_FILE = yes
+
+RESX_DIST =  Mvc/Resources/MvcResources.resx
+
+LIB_MCS_FLAGS = \
+               /warn:1 \
+               /keyfile:../winfx.pub \
+               /d:MONO \
+               /delaysign \
+               /r:Microsoft.Web.Infrastructure.dll \
+               /r:System.dll \
+               /r:System.Core.dll \
+               /r:System.Configuration.dll \
+               /r:System.Data.dll \
+               /r:System.Xml.dll \
+               /r:System.Web.dll \
+               /r:System.Web.Abstractions.dll \
+               /r:System.Web.Routing.dll \
+               /r:System.Web.Extensions.dll \
+               /r:System.ComponentModel.DataAnnotations.dll \
+               /r:System.Data.Linq.dll \
+               /r:System.Runtime.Caching.dll \
+               /r:System.Web.Razor.dll \
+               /r:System.Web.WebPages.Razor.dll \
+               /r:System.Web.WebPages.dll \
+               $(foreach r, $(RESOURCES), /resource:$(r),System.Web.Mvc.Resources.$(notdir $(r)))
+
+EXTRA_DISTFILES = $(RESX_DIST)
+RESOURCES = $(RESX_DIST:.resx=.resources)
+include ../../build/library.make
+
+$(build_lib): $(RESOURCES)
+
+$(RESOURCES): %.resources: %.resx
+       $(RESGEN) `echo $< | $(PLATFORM_CHANGE_SEPARATOR_CMD)`
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AcceptVerbsAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/AcceptVerbsAttribute.cs
new file mode 100644 (file)
index 0000000..c6516f4
--- /dev/null
@@ -0,0 +1,58 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    [SuppressMessage("Microsoft.Design", "CA1019:DefineAccessorsForAttributeArguments", Justification = "The accessor is exposed as an ICollection<string>.")]
+    [AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public sealed class AcceptVerbsAttribute : ActionMethodSelectorAttribute {
+        public AcceptVerbsAttribute(HttpVerbs verbs)
+            : this(EnumToArray(verbs)) {
+        }
+
+        public AcceptVerbsAttribute(params string[] verbs) {
+            if (verbs == null || verbs.Length == 0) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "verbs");
+            }
+
+            Verbs = new ReadOnlyCollection<string>(verbs);
+        }
+
+        public ICollection<string> Verbs {
+            get;
+            private set;
+        }
+
+        private static void AddEntryToList(HttpVerbs verbs, HttpVerbs match, List<string> verbList, string entryText) {
+            if ((verbs & match) != 0) {
+                verbList.Add(entryText);
+            }
+        }
+
+        internal static string[] EnumToArray(HttpVerbs verbs) {
+            List<string> verbList = new List<string>();
+
+            AddEntryToList(verbs, HttpVerbs.Get, verbList, "GET");
+            AddEntryToList(verbs, HttpVerbs.Post, verbList, "POST");
+            AddEntryToList(verbs, HttpVerbs.Put, verbList, "PUT");
+            AddEntryToList(verbs, HttpVerbs.Delete, verbList, "DELETE");
+            AddEntryToList(verbs, HttpVerbs.Head, verbList, "HEAD");
+
+            return verbList.ToArray();
+        }
+
+        public override bool IsValidForRequest(ControllerContext controllerContext, MethodInfo methodInfo) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            string incomingVerb = controllerContext.HttpContext.Request.GetHttpMethodOverride();
+
+            return Verbs.Contains(incomingVerb, StringComparer.OrdinalIgnoreCase);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionDescriptor.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionDescriptor.cs
new file mode 100644 (file)
index 0000000..9c4155a
--- /dev/null
@@ -0,0 +1,175 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    public abstract class ActionDescriptor : ICustomAttributeProvider, IUniquelyIdentifiable {
+
+        private readonly static ActionMethodDispatcherCache _staticDispatcherCache = new ActionMethodDispatcherCache();
+        private ActionMethodDispatcherCache _instanceDispatcherCache;
+        private readonly Lazy<string> _uniqueId;
+
+        private static readonly ActionSelector[] _emptySelectors = new ActionSelector[0];
+
+        protected ActionDescriptor() {
+            _uniqueId = new Lazy<string>(CreateUniqueId);
+        }
+
+        public abstract string ActionName {
+            get;
+        }
+
+        public abstract ControllerDescriptor ControllerDescriptor {
+            get;
+        }
+
+        internal ActionMethodDispatcherCache DispatcherCache {
+            get {
+                if (_instanceDispatcherCache == null) {
+                    _instanceDispatcherCache = _staticDispatcherCache;
+                }
+                return _instanceDispatcherCache;
+            }
+            set {
+                _instanceDispatcherCache = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Security", "CA2119:SealMethodsThatSatisfyPrivateInterfaces", Justification = "This is overridden elsewhere in System.Web.Mvc")]
+        public virtual string UniqueId {
+            get {
+                return _uniqueId.Value;
+            }
+        }
+
+        private string CreateUniqueId() {
+            return DescriptorUtil.CreateUniqueId(GetType(), ControllerDescriptor, ActionName);
+        }
+
+        public abstract object Execute(ControllerContext controllerContext, IDictionary<string, object> parameters);
+
+        internal static object ExtractParameterFromDictionary(ParameterInfo parameterInfo, IDictionary<string, object> parameters, MethodInfo methodInfo) {
+            object value;
+
+            if (!parameters.TryGetValue(parameterInfo.Name, out value)) {
+                // the key should always be present, even if the parameter value is null
+                string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ReflectedActionDescriptor_ParameterNotInDictionary,
+                    parameterInfo.Name, parameterInfo.ParameterType, methodInfo, methodInfo.DeclaringType);
+                throw new ArgumentException(message, "parameters");
+            }
+
+            if (value == null && !TypeHelpers.TypeAllowsNullValue(parameterInfo.ParameterType)) {
+                // tried to pass a null value for a non-nullable parameter type
+                string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ReflectedActionDescriptor_ParameterCannotBeNull,
+                    parameterInfo.Name, parameterInfo.ParameterType, methodInfo, methodInfo.DeclaringType);
+                throw new ArgumentException(message, "parameters");
+            }
+
+            if (value != null && !parameterInfo.ParameterType.IsInstanceOfType(value)) {
+                // value was supplied but is not of the proper type
+                string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ReflectedActionDescriptor_ParameterValueHasWrongType,
+                    parameterInfo.Name, methodInfo, methodInfo.DeclaringType, value.GetType(), parameterInfo.ParameterType);
+                throw new ArgumentException(message, "parameters");
+            }
+
+            return value;
+        }
+
+        internal static object ExtractParameterOrDefaultFromDictionary(ParameterInfo parameterInfo, IDictionary<string, object> parameters) {
+            Type parameterType = parameterInfo.ParameterType;
+
+            object value;
+            parameters.TryGetValue(parameterInfo.Name, out value);
+
+            // if wrong type, replace with default instance
+            if (parameterType.IsInstanceOfType(value)) {
+                return value;
+            }
+            else {
+                object defaultValue;
+                if (ParameterInfoUtil.TryGetDefaultValue(parameterInfo, out defaultValue)) {
+                    return defaultValue;
+                }
+                else {
+                    return TypeHelpers.GetDefaultValue(parameterType);
+                }
+            }
+        }
+
+        public virtual object[] GetCustomAttributes(bool inherit) {
+            return GetCustomAttributes(typeof(object), inherit);
+        }
+
+        public virtual object[] GetCustomAttributes(Type attributeType, bool inherit) {
+            if (attributeType == null) {
+                throw new ArgumentNullException("attributeType");
+            }
+
+            return (object[])Array.CreateInstance(attributeType, 0);
+        }
+
+        internal virtual IEnumerable<FilterAttribute> GetFilterAttributes(bool useCache) {
+            return GetCustomAttributes(typeof(FilterAttribute), inherit: true).Cast<FilterAttribute>();
+        }
+
+        [EditorBrowsable(EditorBrowsableState.Never)]
+        [Obsolete("Please call System.Web.Mvc.FilterProviders.Providers.GetFilters() now.", true)]
+        public virtual FilterInfo GetFilters() {
+            return new FilterInfo();
+        }
+
+        public abstract ParameterDescriptor[] GetParameters();
+
+        [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate", Justification = "This method may perform non-trivial work.")]
+        public virtual ICollection<ActionSelector> GetSelectors() {
+            return _emptySelectors;
+        }
+
+        public virtual bool IsDefined(Type attributeType, bool inherit) {
+            if (attributeType == null) {
+                throw new ArgumentNullException("attributeType");
+            }
+
+            return false;
+        }
+
+        internal static string VerifyActionMethodIsCallable(MethodInfo methodInfo) {
+            // we can't call static methods
+            if (methodInfo.IsStatic) {
+                return String.Format(CultureInfo.CurrentCulture,
+                                     MvcResources.ReflectedActionDescriptor_CannotCallStaticMethod,
+                                     methodInfo,
+                                     methodInfo.ReflectedType.FullName);
+            }
+
+            // we can't call instance methods where the 'this' parameter is a type other than ControllerBase
+            if (!typeof(ControllerBase).IsAssignableFrom(methodInfo.ReflectedType)) {
+                return String.Format(CultureInfo.CurrentCulture, MvcResources.ReflectedActionDescriptor_CannotCallInstanceMethodOnNonControllerType,
+                    methodInfo, methodInfo.ReflectedType.FullName);
+            }
+
+            // we can't call methods with open generic type parameters
+            if (methodInfo.ContainsGenericParameters) {
+                return String.Format(CultureInfo.CurrentCulture, MvcResources.ReflectedActionDescriptor_CannotCallOpenGenericMethods,
+                    methodInfo, methodInfo.ReflectedType.FullName);
+            }
+
+            // we can't call methods with ref/out parameters
+            ParameterInfo[] parameterInfos = methodInfo.GetParameters();
+            foreach (ParameterInfo parameterInfo in parameterInfos) {
+                if (parameterInfo.IsOut || parameterInfo.ParameterType.IsByRef) {
+                    return String.Format(CultureInfo.CurrentCulture, MvcResources.ReflectedActionDescriptor_CannotCallMethodsWithOutOrRefParameters,
+                        methodInfo, methodInfo.ReflectedType.FullName, parameterInfo);
+                }
+            }
+
+            // we can call this method
+            return null;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionExecutedContext.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionExecutedContext.cs
new file mode 100644 (file)
index 0000000..e8c7d20
--- /dev/null
@@ -0,0 +1,55 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+
+    public class ActionExecutedContext : ControllerContext {
+
+        private ActionResult _result;
+
+        // parameterless constructor used for mocking
+        public ActionExecutedContext() {
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
+        public ActionExecutedContext(ControllerContext controllerContext, ActionDescriptor actionDescriptor, bool canceled, Exception exception)
+            : base(controllerContext) {
+            if (actionDescriptor == null) {
+                throw new ArgumentNullException("actionDescriptor");
+            }
+
+            ActionDescriptor = actionDescriptor;
+            Canceled = canceled;
+            Exception = exception;
+        }
+
+        public virtual ActionDescriptor ActionDescriptor {
+            get;
+            set;
+        }
+
+        public virtual bool Canceled {
+            get;
+            set;
+        }
+
+        public virtual Exception Exception {
+            get;
+            set;
+        }
+
+        public bool ExceptionHandled {
+            get;
+            set;
+        }
+
+        public ActionResult Result {
+            get {
+                return _result ?? EmptyResult.Instance;
+            }
+            set {
+                _result = value;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionExecutingContext.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionExecutingContext.cs
new file mode 100644 (file)
index 0000000..7b507b6
--- /dev/null
@@ -0,0 +1,43 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+
+    public class ActionExecutingContext : ControllerContext {
+
+        // parameterless constructor used for mocking
+        public ActionExecutingContext() {
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
+        public ActionExecutingContext(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary<string, object> actionParameters)
+            : base(controllerContext) {
+            if (actionDescriptor == null) {
+                throw new ArgumentNullException("actionDescriptor");
+            }
+            if (actionParameters == null) {
+                throw new ArgumentNullException("actionParameters");
+            }
+
+            ActionDescriptor = actionDescriptor;
+            ActionParameters = actionParameters;
+        }
+
+        public virtual ActionDescriptor ActionDescriptor {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "The property setter is only here to support mocking this type and should not be called at runtime.")]
+        public virtual IDictionary<string, object> ActionParameters {
+            get;
+            set;
+        }
+
+        public ActionResult Result {
+            get;
+            set;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionFilterAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionFilterAttribute.cs
new file mode 100644 (file)
index 0000000..4b708f9
--- /dev/null
@@ -0,0 +1,22 @@
+namespace System.Web.Mvc {
+    using System;
+
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
+    public abstract class ActionFilterAttribute : FilterAttribute, IActionFilter, IResultFilter {
+
+        // The OnXxx() methods are virtual rather than abstract so that a developer need override
+        // only the ones that interest him.
+
+        public virtual void OnActionExecuting(ActionExecutingContext filterContext) {
+        }
+
+        public virtual void OnActionExecuted(ActionExecutedContext filterContext) {
+        }
+
+        public virtual void OnResultExecuting(ResultExecutingContext filterContext) {
+        }
+
+        public virtual void OnResultExecuted(ResultExecutedContext filterContext) {
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionMethodDispatcher.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionMethodDispatcher.cs
new file mode 100644 (file)
index 0000000..b54bb8a
--- /dev/null
@@ -0,0 +1,74 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq.Expressions;
+    using System.Reflection;
+
+    // The methods in this class don't perform error checking; that is the responsibility of the
+    // caller.
+    internal sealed class ActionMethodDispatcher {
+
+        private delegate object ActionExecutor(ControllerBase controller, object[] parameters);
+        private delegate void VoidActionExecutor(ControllerBase controller, object[] parameters);
+
+        private ActionExecutor _executor;
+
+        public ActionMethodDispatcher(MethodInfo methodInfo) {
+            _executor = GetExecutor(methodInfo);
+            MethodInfo = methodInfo;
+        }
+
+        public MethodInfo MethodInfo {
+            get;
+            private set;
+        }
+
+        public object Execute(ControllerBase controller, object[] parameters) {
+            return _executor(controller, parameters);
+        }
+
+        private static ActionExecutor GetExecutor(MethodInfo methodInfo) {
+            // Parameters to executor
+            ParameterExpression controllerParameter = Expression.Parameter(typeof(ControllerBase), "controller");
+            ParameterExpression parametersParameter = Expression.Parameter(typeof(object[]), "parameters");
+
+            // Build parameter list
+            List<Expression> parameters = new List<Expression>();
+            ParameterInfo[] paramInfos = methodInfo.GetParameters();
+            for (int i = 0; i < paramInfos.Length; i++) {
+                ParameterInfo paramInfo = paramInfos[i];
+                BinaryExpression valueObj = Expression.ArrayIndex(parametersParameter, Expression.Constant(i));
+                UnaryExpression valueCast = Expression.Convert(valueObj, paramInfo.ParameterType);
+
+                // valueCast is "(Ti) parameters[i]"
+                parameters.Add(valueCast);
+            }
+
+            // Call method
+            UnaryExpression instanceCast = (!methodInfo.IsStatic) ? Expression.Convert(controllerParameter, methodInfo.ReflectedType) : null;
+            MethodCallExpression methodCall = methodCall = Expression.Call(instanceCast, methodInfo, parameters);
+
+            // methodCall is "((TController) controller) method((T0) parameters[0], (T1) parameters[1], ...)"
+            // Create function
+            if (methodCall.Type == typeof(void)) {
+                Expression<VoidActionExecutor> lambda = Expression.Lambda<VoidActionExecutor>(methodCall, controllerParameter, parametersParameter);
+                VoidActionExecutor voidExecutor = lambda.Compile();
+                return WrapVoidAction(voidExecutor);
+            }
+            else {
+                // must coerce methodCall to match ActionExecutor signature
+                UnaryExpression castMethodCall = Expression.Convert(methodCall, typeof(object));
+                Expression<ActionExecutor> lambda = Expression.Lambda<ActionExecutor>(castMethodCall, controllerParameter, parametersParameter);
+                return lambda.Compile();
+            }
+        }
+
+        private static ActionExecutor WrapVoidAction(VoidActionExecutor executor) {
+            return delegate(ControllerBase controller, object[] parameters) {
+                executor(controller, parameters);
+                return null;
+            };
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionMethodDispatcherCache.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionMethodDispatcherCache.cs
new file mode 100644 (file)
index 0000000..1846484
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Reflection;
+
+    internal sealed class ActionMethodDispatcherCache : ReaderWriterCache<MethodInfo,ActionMethodDispatcher> {
+
+        public ActionMethodDispatcherCache() {
+        }
+
+        public ActionMethodDispatcher GetDispatcher(MethodInfo methodInfo) {
+            return FetchOrCreateItem(methodInfo, () => new ActionMethodDispatcher(methodInfo));
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionMethodSelector.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionMethodSelector.cs
new file mode 100644 (file)
index 0000000..498327f
--- /dev/null
@@ -0,0 +1,113 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.Linq;
+    using System.Reflection;
+    using System.Text;
+    using System.Web.Mvc.Resources;
+
+    internal sealed class ActionMethodSelector {
+
+        public ActionMethodSelector(Type controllerType) {
+            ControllerType = controllerType;
+            PopulateLookupTables();
+        }
+
+        public Type ControllerType {
+            get;
+            private set;
+        }
+
+        public MethodInfo[] AliasedMethods {
+            get;
+            private set;
+        }
+
+        public ILookup<string, MethodInfo> NonAliasedMethods {
+            get;
+            private set;
+        }
+
+        private AmbiguousMatchException CreateAmbiguousMatchException(List<MethodInfo> ambiguousMethods, string actionName) {
+            StringBuilder exceptionMessageBuilder = new StringBuilder();
+            foreach (MethodInfo methodInfo in ambiguousMethods) {
+                string controllerAction = Convert.ToString(methodInfo, CultureInfo.CurrentCulture);
+                string controllerType = methodInfo.DeclaringType.FullName;
+                exceptionMessageBuilder.AppendLine();
+                exceptionMessageBuilder.AppendFormat(CultureInfo.CurrentCulture, MvcResources.ActionMethodSelector_AmbiguousMatchType, controllerAction, controllerType);
+            }
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ActionMethodSelector_AmbiguousMatch,
+                actionName, ControllerType.Name, exceptionMessageBuilder);
+            return new AmbiguousMatchException(message);
+        }
+
+        public MethodInfo FindActionMethod(ControllerContext controllerContext, string actionName) {
+            List<MethodInfo> methodsMatchingName = GetMatchingAliasedMethods(controllerContext, actionName);
+            methodsMatchingName.AddRange(NonAliasedMethods[actionName]);
+            List<MethodInfo> finalMethods = RunSelectionFilters(controllerContext, methodsMatchingName);
+
+            switch (finalMethods.Count) {
+                case 0:
+                    return null;
+
+                case 1:
+                    return finalMethods[0];
+
+                default:
+                    throw CreateAmbiguousMatchException(finalMethods, actionName);
+            }
+        }
+
+        internal List<MethodInfo> GetMatchingAliasedMethods(ControllerContext controllerContext, string actionName) {
+            // find all aliased methods which are opting in to this request
+            // to opt in, all attributes defined on the method must return true
+
+            var methods = from methodInfo in AliasedMethods
+                          let attrs = ReflectedAttributeCache.GetActionNameSelectorAttributes(methodInfo)
+                          where attrs.All(attr => attr.IsValidName(controllerContext, actionName, methodInfo))
+                          select methodInfo;
+            return methods.ToList();
+        }
+
+        private static bool IsMethodDecoratedWithAliasingAttribute(MethodInfo methodInfo) {
+            return methodInfo.IsDefined(typeof(ActionNameSelectorAttribute), true /* inherit */);
+        }
+
+        private static bool IsValidActionMethod(MethodInfo methodInfo) {
+            return !(methodInfo.IsSpecialName ||
+                     methodInfo.GetBaseDefinition().DeclaringType.IsAssignableFrom(typeof(Controller)));
+        }
+
+        private void PopulateLookupTables() {
+            MethodInfo[] allMethods = ControllerType.GetMethods(BindingFlags.InvokeMethod | BindingFlags.Instance | BindingFlags.Public);
+            MethodInfo[] actionMethods = Array.FindAll(allMethods, IsValidActionMethod);
+
+            AliasedMethods = Array.FindAll(actionMethods, IsMethodDecoratedWithAliasingAttribute);
+            NonAliasedMethods = actionMethods.Except(AliasedMethods).ToLookup(method => method.Name, StringComparer.OrdinalIgnoreCase);
+        }
+
+        private static List<MethodInfo> RunSelectionFilters(ControllerContext controllerContext, List<MethodInfo> methodInfos) {
+            // remove all methods which are opting out of this request
+            // to opt out, at least one attribute defined on the method must return false
+
+            List<MethodInfo> matchesWithSelectionAttributes = new List<MethodInfo>();
+            List<MethodInfo> matchesWithoutSelectionAttributes = new List<MethodInfo>();
+
+            foreach (MethodInfo methodInfo in methodInfos) {
+                ICollection<ActionMethodSelectorAttribute> attrs = ReflectedAttributeCache.GetActionMethodSelectorAttributes(methodInfo);
+                if (attrs.Count == 0) {
+                    matchesWithoutSelectionAttributes.Add(methodInfo);
+                }
+                else if (attrs.All(attr => attr.IsValidForRequest(controllerContext, methodInfo))) {
+                    matchesWithSelectionAttributes.Add(methodInfo);
+                }
+            }
+
+            // if a matching action method had a selection attribute, consider it more specific than a matching action method
+            // without a selection attribute
+            return (matchesWithSelectionAttributes.Count > 0) ? matchesWithSelectionAttributes : matchesWithoutSelectionAttributes;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionMethodSelectorAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionMethodSelectorAttribute.cs
new file mode 100644 (file)
index 0000000..2f171f2
--- /dev/null
@@ -0,0 +1,9 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Reflection;
+
+    [AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public abstract class ActionMethodSelectorAttribute : Attribute {
+        public abstract bool IsValidForRequest(ControllerContext controllerContext, MethodInfo methodInfo);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionNameAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionNameAttribute.cs
new file mode 100644 (file)
index 0000000..06b982d
--- /dev/null
@@ -0,0 +1,27 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    [AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public sealed class ActionNameAttribute : ActionNameSelectorAttribute {
+
+        public ActionNameAttribute(string name) {
+            if (String.IsNullOrEmpty(name)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "name");
+            }
+
+            Name = name;
+        }
+
+        public string Name {
+            get;
+            private set;
+        }
+
+        public override bool IsValidName(ControllerContext controllerContext, string actionName, MethodInfo methodInfo) {
+            return String.Equals(actionName, Name, StringComparison.OrdinalIgnoreCase);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionNameSelectorAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionNameSelectorAttribute.cs
new file mode 100644 (file)
index 0000000..949134e
--- /dev/null
@@ -0,0 +1,9 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Reflection;
+
+    [AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public abstract class ActionNameSelectorAttribute : Attribute {
+        public abstract bool IsValidName(ControllerContext controllerContext, string actionName, MethodInfo methodInfo);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionResult.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionResult.cs
new file mode 100644 (file)
index 0000000..e648246
--- /dev/null
@@ -0,0 +1,9 @@
+namespace System.Web.Mvc {
+
+    public abstract class ActionResult {
+
+        public abstract void ExecuteResult(ControllerContext context);
+
+    }
+
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ActionSelector.cs b/mcs/class/System.Web.Mvc3/Mvc/ActionSelector.cs
new file mode 100644 (file)
index 0000000..1708097
--- /dev/null
@@ -0,0 +1,5 @@
+namespace System.Web.Mvc {
+
+    public delegate bool ActionSelector(ControllerContext controllerContext);
+
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AdditionalMetaDataAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/AdditionalMetaDataAttribute.cs
new file mode 100644 (file)
index 0000000..9b25a76
--- /dev/null
@@ -0,0 +1,41 @@
+namespace System.Web.Mvc {
+    using System;
+
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Interface | AttributeTargets.Property, AllowMultiple = true)]
+    public sealed class AdditionalMetadataAttribute : Attribute, IMetadataAware {
+        private object _typeId = new object();
+
+        public AdditionalMetadataAttribute(string name, object value) {
+            if (name == null) {
+                throw new ArgumentNullException("name");
+            }
+
+            Name = name;
+            Value = value;
+        }
+
+        public override object TypeId {
+            get {
+                return _typeId;
+            }
+        }
+
+        public string Name {
+            get;
+            private set;
+        }
+
+        public object Value {
+            get;
+            private set;
+        }
+
+        public void OnMetadataCreated(ModelMetadata metadata) {
+            if (metadata == null) {
+                throw new ArgumentNullException("metadata");
+            }
+
+            metadata.AdditionalValues[Name] = Value;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Ajax/AjaxExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Ajax/AjaxExtensions.cs
new file mode 100644 (file)
index 0000000..f11e751
--- /dev/null
@@ -0,0 +1,300 @@
+namespace System.Web.Mvc.Ajax {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Web;
+    using System.Web.Mvc;
+    using System.Web.Mvc.Html;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    public static class AjaxExtensions {
+        private const string LinkOnClickFormat = "Sys.Mvc.AsyncHyperlink.handleClick(this, new Sys.UI.DomEvent(event), {0});";
+        private const string FormOnClickValue = "Sys.Mvc.AsyncForm.handleClick(this, new Sys.UI.DomEvent(event));";
+        private const string FormOnSubmitFormat = "Sys.Mvc.AsyncForm.handleSubmit(this, new Sys.UI.DomEvent(event), {0});";
+        private const string _globalizationScript = @"<script type=""text/javascript"" src=""{0}""></script>";
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, AjaxOptions ajaxOptions) {
+            return ActionLink(ajaxHelper, linkText, actionName, (string)null /* controllerName */, ajaxOptions);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, object routeValues, AjaxOptions ajaxOptions) {
+            return ActionLink(ajaxHelper, linkText, actionName, (string)null /* controllerName */, routeValues, ajaxOptions);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, object routeValues, AjaxOptions ajaxOptions, object htmlAttributes) {
+            return ActionLink(ajaxHelper, linkText, actionName, (string)null /* controllerName */, routeValues, ajaxOptions, htmlAttributes);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions) {
+            return ActionLink(ajaxHelper, linkText, actionName, (string)null /* controllerName */, routeValues, ajaxOptions);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            return ActionLink(ajaxHelper, linkText, actionName, (string)null /* controllerName */, routeValues, ajaxOptions, htmlAttributes);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, string controllerName, AjaxOptions ajaxOptions) {
+            return ActionLink(ajaxHelper, linkText, actionName, controllerName, null /* values */, ajaxOptions, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, string controllerName, object routeValues, AjaxOptions ajaxOptions) {
+            return ActionLink(ajaxHelper, linkText, actionName, controllerName, routeValues, ajaxOptions, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, string controllerName, object routeValues, AjaxOptions ajaxOptions, object htmlAttributes) {
+            RouteValueDictionary newValues = new RouteValueDictionary(routeValues);
+            RouteValueDictionary newAttributes = HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes);
+            return ActionLink(ajaxHelper, linkText, actionName, controllerName, newValues, ajaxOptions, newAttributes);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, string controllerName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions) {
+            return ActionLink(ajaxHelper, linkText, actionName, controllerName, routeValues, ajaxOptions, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, string controllerName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            if (String.IsNullOrEmpty(linkText)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "linkText");
+            }
+
+            string targetUrl = UrlHelper.GenerateUrl(null, actionName, controllerName, routeValues, ajaxHelper.RouteCollection, ajaxHelper.ViewContext.RequestContext, true /* includeImplicitMvcValues */);
+
+            return MvcHtmlString.Create(GenerateLink(ajaxHelper, linkText, targetUrl, GetAjaxOptions(ajaxOptions), htmlAttributes));
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, string controllerName, string protocol, string hostName, string fragment, object routeValues, AjaxOptions ajaxOptions, object htmlAttributes) {
+            RouteValueDictionary newValues = new RouteValueDictionary(routeValues);
+            RouteValueDictionary newAttributes = HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes);
+            return ActionLink(ajaxHelper, linkText, actionName, controllerName, protocol, hostName, fragment, newValues, ajaxOptions, newAttributes);
+        }
+
+        public static MvcHtmlString ActionLink(this AjaxHelper ajaxHelper, string linkText, string actionName, string controllerName, string protocol, string hostName, string fragment, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            if (String.IsNullOrEmpty(linkText)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "linkText");
+            }
+
+            string targetUrl = UrlHelper.GenerateUrl(null /* routeName */, actionName, controllerName, protocol, hostName, fragment, routeValues, ajaxHelper.RouteCollection, ajaxHelper.ViewContext.RequestContext, true /* includeImplicitMvcValues */);
+
+            return MvcHtmlString.Create(GenerateLink(ajaxHelper, linkText, targetUrl, ajaxOptions, htmlAttributes));
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, AjaxOptions ajaxOptions) {
+            string formAction = ajaxHelper.ViewContext.HttpContext.Request.RawUrl;
+            return FormHelper(ajaxHelper, formAction, ajaxOptions, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, AjaxOptions ajaxOptions) {
+            return BeginForm(ajaxHelper, actionName, (string)null /* controllerName */, ajaxOptions);
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, object routeValues, AjaxOptions ajaxOptions) {
+            return BeginForm(ajaxHelper, actionName, (string)null /* controllerName */, routeValues, ajaxOptions);
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, object routeValues, AjaxOptions ajaxOptions, object htmlAttributes) {
+            return BeginForm(ajaxHelper, actionName, (string)null /* controllerName */, routeValues, ajaxOptions, htmlAttributes);
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions) {
+            return BeginForm(ajaxHelper, actionName, (string)null /* controllerName */, routeValues, ajaxOptions);
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            return BeginForm(ajaxHelper, actionName, (string)null /* controllerName */, routeValues, ajaxOptions, htmlAttributes);
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, string controllerName, AjaxOptions ajaxOptions) {
+            return BeginForm(ajaxHelper, actionName, controllerName, null /* values */, ajaxOptions, null /* htmlAttributes */);
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, string controllerName, object routeValues, AjaxOptions ajaxOptions) {
+            return BeginForm(ajaxHelper, actionName, controllerName, routeValues, ajaxOptions, null /* htmlAttributes */);
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, string controllerName, object routeValues, AjaxOptions ajaxOptions, object htmlAttributes) {
+            RouteValueDictionary newValues = new RouteValueDictionary(routeValues);
+            RouteValueDictionary newAttributes = HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes);
+            return BeginForm(ajaxHelper, actionName, controllerName, newValues, ajaxOptions, newAttributes);
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, string controllerName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions) {
+            return BeginForm(ajaxHelper, actionName, controllerName, routeValues, ajaxOptions, null /* htmlAttributes */);
+        }
+
+        public static MvcForm BeginForm(this AjaxHelper ajaxHelper, string actionName, string controllerName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            // get target URL
+            string formAction = UrlHelper.GenerateUrl(null, actionName, controllerName, routeValues ?? new RouteValueDictionary(), ajaxHelper.RouteCollection, ajaxHelper.ViewContext.RequestContext, true /* includeImplicitMvcValues */);
+            return FormHelper(ajaxHelper, formAction, ajaxOptions, htmlAttributes);
+        }
+
+        public static MvcForm BeginRouteForm(this AjaxHelper ajaxHelper, string routeName, AjaxOptions ajaxOptions) {
+            return BeginRouteForm(ajaxHelper, routeName, null /* routeValues */, ajaxOptions, null /* htmlAttributes */);
+        }
+
+        public static MvcForm BeginRouteForm(this AjaxHelper ajaxHelper, string routeName, object routeValues, AjaxOptions ajaxOptions) {
+            return BeginRouteForm(ajaxHelper, routeName, (object)routeValues, ajaxOptions, null /* htmlAttributes */);
+        }
+
+        public static MvcForm BeginRouteForm(this AjaxHelper ajaxHelper, string routeName, object routeValues, AjaxOptions ajaxOptions, object htmlAttributes) {
+            RouteValueDictionary newAttributes = HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes);
+            return BeginRouteForm(ajaxHelper, routeName, new RouteValueDictionary(routeValues), ajaxOptions, newAttributes);
+        }
+
+        public static MvcForm BeginRouteForm(this AjaxHelper ajaxHelper, string routeName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions) {
+            return BeginRouteForm(ajaxHelper, routeName, routeValues, ajaxOptions, null /* htmlAttributes */);
+        }
+
+        public static MvcForm BeginRouteForm(this AjaxHelper ajaxHelper, string routeName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            string formAction = UrlHelper.GenerateUrl(routeName, null /* actionName */, null /* controllerName */, routeValues ?? new RouteValueDictionary(), ajaxHelper.RouteCollection, ajaxHelper.ViewContext.RequestContext, false /* includeImplicitMvcValues */);
+            return FormHelper(ajaxHelper, formAction, ajaxOptions, htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Reliability", "CA2000:Dispose objects before losing scope", Justification = "You don't want to dispose of this object unless you intend to write to the response")]
+        private static MvcForm FormHelper(this AjaxHelper ajaxHelper, string formAction, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            TagBuilder builder = new TagBuilder("form");
+            builder.MergeAttributes(htmlAttributes);
+            builder.MergeAttribute("action", formAction);
+            builder.MergeAttribute("method", "post");
+
+            ajaxOptions = GetAjaxOptions(ajaxOptions);
+
+            if (ajaxHelper.ViewContext.UnobtrusiveJavaScriptEnabled) {
+                builder.MergeAttributes(ajaxOptions.ToUnobtrusiveHtmlAttributes());
+            }
+            else {
+                builder.MergeAttribute("onclick", FormOnClickValue);
+                builder.MergeAttribute("onsubmit", GenerateAjaxScript(ajaxOptions, FormOnSubmitFormat));
+            }
+
+            if (ajaxHelper.ViewContext.ClientValidationEnabled) {
+                // forms must have an ID for client validation
+                builder.GenerateId(ajaxHelper.ViewContext.FormIdGenerator());
+            }
+
+            ajaxHelper.ViewContext.Writer.Write(builder.ToString(TagRenderMode.StartTag));
+            MvcForm theForm = new MvcForm(ajaxHelper.ViewContext);
+
+            if (ajaxHelper.ViewContext.ClientValidationEnabled) {
+                ajaxHelper.ViewContext.FormContext.FormId = builder.Attributes["id"];
+            }
+
+            return theForm;
+        }
+
+        public static MvcHtmlString GlobalizationScript(this AjaxHelper ajaxHelper) {
+            return GlobalizationScript(ajaxHelper, CultureInfo.CurrentCulture);
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "ajaxHelper", Justification = "This is an extension method")]
+        public static MvcHtmlString GlobalizationScript(this AjaxHelper ajaxHelper, CultureInfo cultureInfo) {
+            return GlobalizationScriptHelper(AjaxHelper.GlobalizationScriptPath, cultureInfo);
+        }
+
+        private static MvcHtmlString GlobalizationScriptHelper(string scriptPath, CultureInfo cultureInfo) {
+            if (cultureInfo == null) {
+                throw new ArgumentNullException("cultureInfo");
+            }
+
+            string src = VirtualPathUtility.AppendTrailingSlash(scriptPath) + cultureInfo.Name + ".js";
+            string scriptWithCorrectNewLines = _globalizationScript.Replace("\r\n", Environment.NewLine);
+            string formatted = String.Format(CultureInfo.InvariantCulture, scriptWithCorrectNewLines, src);
+
+            return MvcHtmlString.Create(formatted);
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, object routeValues, AjaxOptions ajaxOptions) {
+            return RouteLink(ajaxHelper, linkText, null /* routeName */, new RouteValueDictionary(routeValues), ajaxOptions,
+                             new Dictionary<string, object>());
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, object routeValues, AjaxOptions ajaxOptions, object htmlAttributes) {
+            return RouteLink(ajaxHelper, linkText, null /* routeName */, new RouteValueDictionary(routeValues), ajaxOptions,
+                             HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, RouteValueDictionary routeValues, AjaxOptions ajaxOptions) {
+            return RouteLink(ajaxHelper, linkText, null /* routeName */, routeValues, ajaxOptions,
+                             new Dictionary<string, object>());
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            return RouteLink(ajaxHelper, linkText, null /* routeName */, routeValues, ajaxOptions, htmlAttributes);
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, string routeName, AjaxOptions ajaxOptions) {
+            return RouteLink(ajaxHelper, linkText, routeName, new RouteValueDictionary(), ajaxOptions,
+                             new Dictionary<string, object>());
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, string routeName, AjaxOptions ajaxOptions, object htmlAttributes) {
+            return RouteLink(ajaxHelper, linkText, routeName, new RouteValueDictionary(), ajaxOptions, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, string routeName, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            return RouteLink(ajaxHelper, linkText, routeName, new RouteValueDictionary(), ajaxOptions, htmlAttributes);
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, string routeName, object routeValues, AjaxOptions ajaxOptions) {
+            return RouteLink(ajaxHelper, linkText, routeName, new RouteValueDictionary(routeValues), ajaxOptions,
+                             new Dictionary<string, object>());
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, string routeName, object routeValues, AjaxOptions ajaxOptions, object htmlAttributes) {
+            return RouteLink(ajaxHelper, linkText, routeName, new RouteValueDictionary(routeValues), ajaxOptions,
+                             HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, string routeName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions) {
+            return RouteLink(ajaxHelper, linkText, routeName, routeValues, ajaxOptions, new Dictionary<string, object>());
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, string routeName, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            if (String.IsNullOrEmpty(linkText)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "linkText");
+            }
+
+            string targetUrl = UrlHelper.GenerateUrl(routeName, null /* actionName */, null /* controllerName */, routeValues ?? new RouteValueDictionary(), ajaxHelper.RouteCollection, ajaxHelper.ViewContext.RequestContext, false /* includeImplicitMvcValues */);
+
+            return MvcHtmlString.Create(GenerateLink(ajaxHelper, linkText, targetUrl, GetAjaxOptions(ajaxOptions), htmlAttributes));
+        }
+
+        public static MvcHtmlString RouteLink(this AjaxHelper ajaxHelper, string linkText, string routeName, string protocol, string hostName, string fragment, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            if (String.IsNullOrEmpty(linkText)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "linkText");
+            }
+
+            string targetUrl = UrlHelper.GenerateUrl(routeName, null /* actionName */, null /* controllerName */, protocol, hostName, fragment, routeValues ?? new RouteValueDictionary(), ajaxHelper.RouteCollection, ajaxHelper.ViewContext.RequestContext, false /* includeImplicitMvcValues */);
+
+            return MvcHtmlString.Create(GenerateLink(ajaxHelper, linkText, targetUrl, GetAjaxOptions(ajaxOptions), htmlAttributes));
+        }
+
+        private static string GenerateLink(AjaxHelper ajaxHelper, string linkText, string targetUrl, AjaxOptions ajaxOptions, IDictionary<string, object> htmlAttributes) {
+            TagBuilder tag = new TagBuilder("a") {
+                InnerHtml = HttpUtility.HtmlEncode(linkText)
+            };
+
+            tag.MergeAttributes(htmlAttributes);
+            tag.MergeAttribute("href", targetUrl);
+
+            if (ajaxHelper.ViewContext.UnobtrusiveJavaScriptEnabled) {
+                tag.MergeAttributes(ajaxOptions.ToUnobtrusiveHtmlAttributes());
+            }
+            else {
+                tag.MergeAttribute("onclick", GenerateAjaxScript(ajaxOptions, LinkOnClickFormat));
+            }
+
+            return tag.ToString(TagRenderMode.Normal);
+        }
+
+        private static string GenerateAjaxScript(AjaxOptions ajaxOptions, string scriptFormat) {
+            string optionsString = ajaxOptions.ToJavascriptString();
+            return String.Format(CultureInfo.InvariantCulture, scriptFormat, optionsString);
+        }
+
+        private static AjaxOptions GetAjaxOptions(AjaxOptions ajaxOptions) {
+            return (ajaxOptions != null) ? ajaxOptions : new AjaxOptions();
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Ajax/AjaxOptions.cs b/mcs/class/System.Web.Mvc3/Mvc/Ajax/AjaxOptions.cs
new file mode 100644 (file)
index 0000000..69a817e
--- /dev/null
@@ -0,0 +1,226 @@
+namespace System.Web.Mvc.Ajax {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Text;
+
+    public class AjaxOptions {
+        private string _confirm;
+        private string _httpMethod;
+        private InsertionMode _insertionMode = InsertionMode.Replace;
+        private string _loadingElementId;
+        private string _onBegin;
+        private string _onComplete;
+        private string _onFailure;
+        private string _onSuccess;
+        private string _updateTargetId;
+        private string _url;
+
+        public string Confirm {
+            get {
+                return _confirm ?? String.Empty;
+            }
+            set {
+                _confirm = value;
+            }
+        }
+
+        public string HttpMethod {
+            get {
+                return _httpMethod ?? String.Empty;
+            }
+            set {
+                _httpMethod = value;
+            }
+        }
+
+        public InsertionMode InsertionMode {
+            get {
+                return _insertionMode;
+            }
+            set {
+                switch (value) {
+                    case InsertionMode.Replace:
+                    case InsertionMode.InsertAfter:
+                    case InsertionMode.InsertBefore:
+                        _insertionMode = value;
+                        return;
+
+                    default:
+                        throw new ArgumentOutOfRangeException("value");
+                }
+            }
+        }
+
+        internal string InsertionModeString {
+            get {
+                switch (InsertionMode) {
+                    case InsertionMode.Replace:
+                        return "Sys.Mvc.InsertionMode.replace";
+                    case InsertionMode.InsertBefore:
+                        return "Sys.Mvc.InsertionMode.insertBefore";
+                    case InsertionMode.InsertAfter:
+                        return "Sys.Mvc.InsertionMode.insertAfter";
+                    default:
+                        return ((int)InsertionMode).ToString(CultureInfo.InvariantCulture);
+                }
+            }
+        }
+
+        internal string InsertionModeUnobtrusive {
+            get {
+                switch (InsertionMode) {
+                    case InsertionMode.Replace:
+                        return "replace";
+                    case InsertionMode.InsertBefore:
+                        return "before";
+                    case InsertionMode.InsertAfter:
+                        return "after";
+                    default:
+                        return ((int)InsertionMode).ToString(CultureInfo.InvariantCulture);
+                }
+            }
+        }
+
+        public int LoadingElementDuration {
+            get;
+            set;
+        }
+
+        public string LoadingElementId {
+            get {
+                return _loadingElementId ?? String.Empty;
+            }
+            set {
+                _loadingElementId = value;
+            }
+        }
+
+        public string OnBegin {
+            get {
+                return _onBegin ?? String.Empty;
+            }
+            set {
+                _onBegin = value;
+            }
+        }
+
+        public string OnComplete {
+            get {
+                return _onComplete ?? String.Empty;
+            }
+            set {
+                _onComplete = value;
+            }
+        }
+
+        public string OnFailure {
+            get {
+                return _onFailure ?? String.Empty;
+            }
+            set {
+                _onFailure = value;
+            }
+        }
+
+        public string OnSuccess {
+            get {
+                return _onSuccess ?? String.Empty;
+            }
+            set {
+                _onSuccess = value;
+            }
+        }
+
+        public string UpdateTargetId {
+            get {
+                return _updateTargetId ?? String.Empty;
+            }
+            set {
+                _updateTargetId = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1056:UriPropertiesShouldNotBeStrings", Justification = "This property is used by the optionsBuilder which always accepts a string.")]
+        public string Url {
+            get {
+                return _url ?? String.Empty;
+            }
+            set {
+                _url = value;
+            }
+        }
+
+        internal string ToJavascriptString() {
+            // creates a string of the form { key1: value1, key2 : value2, ... }
+            StringBuilder optionsBuilder = new StringBuilder("{");
+            optionsBuilder.Append(String.Format(CultureInfo.InvariantCulture, " insertionMode: {0},", InsertionModeString));
+            optionsBuilder.Append(PropertyStringIfSpecified("confirm", Confirm));
+            optionsBuilder.Append(PropertyStringIfSpecified("httpMethod", HttpMethod));
+            optionsBuilder.Append(PropertyStringIfSpecified("loadingElementId", LoadingElementId));
+            optionsBuilder.Append(PropertyStringIfSpecified("updateTargetId", UpdateTargetId));
+            optionsBuilder.Append(PropertyStringIfSpecified("url", Url));
+            optionsBuilder.Append(EventStringIfSpecified("onBegin", OnBegin));
+            optionsBuilder.Append(EventStringIfSpecified("onComplete", OnComplete));
+            optionsBuilder.Append(EventStringIfSpecified("onFailure", OnFailure));
+            optionsBuilder.Append(EventStringIfSpecified("onSuccess", OnSuccess));
+            optionsBuilder.Length--;
+            optionsBuilder.Append(" }");
+            return optionsBuilder.ToString();
+        }
+
+        public IDictionary<string, object> ToUnobtrusiveHtmlAttributes() {
+            var result = new Dictionary<string, object> {
+                { "data-ajax", "true" },
+            };
+
+            AddToDictionaryIfSpecified(result, "data-ajax-url", Url);
+            AddToDictionaryIfSpecified(result, "data-ajax-method", HttpMethod);
+            AddToDictionaryIfSpecified(result, "data-ajax-confirm", Confirm);
+
+            AddToDictionaryIfSpecified(result, "data-ajax-begin", OnBegin);
+            AddToDictionaryIfSpecified(result, "data-ajax-complete", OnComplete);
+            AddToDictionaryIfSpecified(result, "data-ajax-failure", OnFailure);
+            AddToDictionaryIfSpecified(result, "data-ajax-success", OnSuccess);
+
+            if (!String.IsNullOrWhiteSpace(LoadingElementId)) {
+                result.Add("data-ajax-loading", "#" + LoadingElementId);
+
+                if (LoadingElementDuration > 0) {
+                    result.Add("data-ajax-loading-duration", LoadingElementDuration);
+                }
+            }
+
+            if (!String.IsNullOrWhiteSpace(UpdateTargetId)) {
+                result.Add("data-ajax-update", "#" + UpdateTargetId);
+                result.Add("data-ajax-mode", InsertionModeUnobtrusive);
+            }
+
+            return result;
+        }
+
+        // Helpers
+
+        private static void AddToDictionaryIfSpecified(IDictionary<string, object> dictionary, string name, string value) {
+            if (!String.IsNullOrWhiteSpace(value)) {
+                dictionary.Add(name, value);
+            }
+        }
+
+        private static string EventStringIfSpecified(string propertyName, string handler) {
+            if (!String.IsNullOrEmpty(handler)) {
+                return String.Format(CultureInfo.InvariantCulture, " {0}: Function.createDelegate(this, {1}),", propertyName, handler.ToString());
+            }
+            return String.Empty;
+        }
+
+        private static string PropertyStringIfSpecified(string propertyName, string propertyValue) {
+            if (!String.IsNullOrEmpty(propertyValue)) {
+                string escapedPropertyValue = propertyValue.Replace("'", @"\'");
+                return String.Format(CultureInfo.InvariantCulture, " {0}: '{1}',", propertyName, escapedPropertyValue);
+            }
+            return String.Empty;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Ajax/InsertionMode.cs b/mcs/class/System.Web.Mvc3/Mvc/Ajax/InsertionMode.cs
new file mode 100644 (file)
index 0000000..4335975
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc.Ajax {
+    public enum InsertionMode {
+        Replace = 0,
+        InsertBefore = 1,
+        InsertAfter = 2
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AjaxHelper.cs b/mcs/class/System.Web.Mvc3/Mvc/AjaxHelper.cs
new file mode 100644 (file)
index 0000000..0908bd3
--- /dev/null
@@ -0,0 +1,76 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Text;
+    using System.Web.Routing;
+    using System.Web.Script.Serialization;
+
+    public class AjaxHelper {
+
+        private static string _globalizationScriptPath;
+
+        public AjaxHelper(ViewContext viewContext, IViewDataContainer viewDataContainer)
+            : this(viewContext, viewDataContainer, RouteTable.Routes) {
+        }
+
+        public AjaxHelper(ViewContext viewContext, IViewDataContainer viewDataContainer, RouteCollection routeCollection) {
+            if (viewContext == null) {
+                throw new ArgumentNullException("viewContext");
+            }
+            if (viewDataContainer == null) {
+                throw new ArgumentNullException("viewDataContainer");
+            }
+            if (routeCollection == null) {
+                throw new ArgumentNullException("routeCollection");
+            }
+            ViewContext = viewContext;
+            ViewDataContainer = viewDataContainer;
+            RouteCollection = routeCollection;
+        }
+
+        public static string GlobalizationScriptPath {
+            get {
+                if (String.IsNullOrEmpty(_globalizationScriptPath)) {
+                    _globalizationScriptPath = "~/Scripts/Globalization";
+                }
+                return _globalizationScriptPath;
+            }
+            set {
+                _globalizationScriptPath = value;
+            }
+        }
+
+        public RouteCollection RouteCollection {
+            get;
+            private set;
+        }
+
+        public ViewContext ViewContext {
+            get;
+            private set;
+        }
+
+        public ViewDataDictionary ViewData {
+            get {
+                return ViewDataContainer.ViewData;
+            }
+        }
+
+        public IViewDataContainer ViewDataContainer {
+            get;
+            private set;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "Instance method for consistency with other helpers.")]
+        public string JavaScriptStringEncode(string message) {
+            if (String.IsNullOrEmpty(message)) {
+                return message;
+            }
+
+            StringBuilder builder = new StringBuilder();
+            JavaScriptSerializer serializer = new JavaScriptSerializer();
+            serializer.Serialize(message, builder);
+            return builder.ToString(1, builder.Length - 2); // remove first + last quote
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AjaxHelper`1.cs b/mcs/class/System.Web.Mvc3/Mvc/AjaxHelper`1.cs
new file mode 100644 (file)
index 0000000..edba2df
--- /dev/null
@@ -0,0 +1,23 @@
+namespace System.Web.Mvc {
+    using System.Web.Routing;
+
+    public class AjaxHelper<TModel> : AjaxHelper {
+        private ViewDataDictionary<TModel> _viewData;
+
+        public AjaxHelper(ViewContext viewContext, IViewDataContainer viewDataContainer)
+            : this(viewContext, viewDataContainer, RouteTable.Routes) {
+        }
+
+        public AjaxHelper(ViewContext viewContext, IViewDataContainer viewDataContainer, RouteCollection routeCollection)
+            : base(viewContext, viewDataContainer, routeCollection) {
+
+            _viewData = new ViewDataDictionary<TModel>(viewDataContainer.ViewData);
+        }
+
+        public new ViewDataDictionary<TModel> ViewData {
+            get {
+                return _viewData;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AjaxRequestExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/AjaxRequestExtensions.cs
new file mode 100644 (file)
index 0000000..8f635c2
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public static class AjaxRequestExtensions {
+
+        public static bool IsAjaxRequest(this HttpRequestBase request) {
+            if (request == null) {
+                throw new ArgumentNullException("request");
+            }
+            
+            return (request["X-Requested-With"] == "XMLHttpRequest") || ((request.Headers != null) && (request.Headers["X-Requested-With"] == "XMLHttpRequest"));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AllowHtmlAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/AllowHtmlAttribute.cs
new file mode 100644 (file)
index 0000000..3d45e64
--- /dev/null
@@ -0,0 +1,19 @@
+namespace System.Web.Mvc {
+    using System;
+
+    // This attribute can be applied to a model property to specify that the particular property to
+    // which it is applied should not go through request validation.
+
+    [AttributeUsage(AttributeTargets.Property, AllowMultiple = false, Inherited = true)]
+    public sealed class AllowHtmlAttribute : Attribute, IMetadataAware {
+
+        public void OnMetadataCreated(ModelMetadata metadata) {
+            if (metadata == null) {
+                throw new ArgumentNullException("metadata");
+            }
+
+            metadata.RequestValidationEnabled = false;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AreaHelpers.cs b/mcs/class/System.Web.Mvc3/Mvc/AreaHelpers.cs
new file mode 100644 (file)
index 0000000..32a20d9
--- /dev/null
@@ -0,0 +1,31 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Web.Routing;
+
+    internal static class AreaHelpers {
+
+        public static string GetAreaName(RouteBase route) {
+            IRouteWithArea routeWithArea = route as IRouteWithArea;
+            if (routeWithArea != null) {
+                return routeWithArea.Area;
+            }
+
+            Route castRoute = route as Route;
+            if (castRoute != null && castRoute.DataTokens != null) {
+                return castRoute.DataTokens["area"] as string;
+            }
+
+            return null;
+        }
+
+        public static string GetAreaName(RouteData routeData) {
+            object area;
+            if (routeData.DataTokens.TryGetValue("area", out area)) {
+                return area as string;
+            }
+
+            return GetAreaName(routeData.Route);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AreaRegistration.cs b/mcs/class/System.Web.Mvc3/Mvc/AreaRegistration.cs
new file mode 100644 (file)
index 0000000..28a8084
--- /dev/null
@@ -0,0 +1,50 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Web.Routing;
+
+    public abstract class AreaRegistration {
+
+        private const string _typeCacheName = "MVC-AreaRegistrationTypeCache.xml";
+
+        public abstract string AreaName {
+            get;
+        }
+
+        internal void CreateContextAndRegister(RouteCollection routes, object state) {
+            AreaRegistrationContext context = new AreaRegistrationContext(AreaName, routes, state);
+
+            string thisNamespace = GetType().Namespace;
+            if (thisNamespace != null) {
+                context.Namespaces.Add(thisNamespace + ".*");
+            }
+
+            RegisterArea(context);
+        }
+
+        private static bool IsAreaRegistrationType(Type type) {
+            return
+                typeof(AreaRegistration).IsAssignableFrom(type) &&
+                type.GetConstructor(Type.EmptyTypes) != null;
+        }
+
+        public static void RegisterAllAreas() {
+            RegisterAllAreas(null);
+        }
+
+        public static void RegisterAllAreas(object state) {
+            RegisterAllAreas(RouteTable.Routes, new BuildManagerWrapper(), state);
+        }
+
+        internal static void RegisterAllAreas(RouteCollection routes, IBuildManager buildManager, object state) {
+            List<Type> areaRegistrationTypes = TypeCacheUtil.GetFilteredTypesFromAssemblies(_typeCacheName, IsAreaRegistrationType, buildManager);
+            foreach (Type areaRegistrationType in areaRegistrationTypes) {
+                AreaRegistration registration = (AreaRegistration)Activator.CreateInstance(areaRegistrationType);
+                registration.CreateContextAndRegister(routes, state);
+            }
+        }
+
+        public abstract void RegisterArea(AreaRegistrationContext context);
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AreaRegistrationContext.cs b/mcs/class/System.Web.Mvc3/Mvc/AreaRegistrationContext.cs
new file mode 100644 (file)
index 0000000..4c0bf02
--- /dev/null
@@ -0,0 +1,93 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq;
+    using System.Web.Routing;
+
+    public class AreaRegistrationContext {
+
+        private readonly HashSet<string> _namespaces = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
+
+        public AreaRegistrationContext(string areaName, RouteCollection routes)
+            : this(areaName, routes, null) {
+        }
+
+        public AreaRegistrationContext(string areaName, RouteCollection routes, object state) {
+            if (String.IsNullOrEmpty(areaName)) {
+                throw Error.ParameterCannotBeNullOrEmpty("areaName");
+            }
+            if (routes == null) {
+                throw new ArgumentNullException("routes");
+            }
+
+            AreaName = areaName;
+            Routes = routes;
+            State = state;
+        }
+
+        public string AreaName {
+            get;
+            private set;
+        }
+
+        public ICollection<string> Namespaces {
+            get {
+                return _namespaces;
+            }
+        }
+
+        public RouteCollection Routes {
+            get;
+            private set;
+        }
+
+        public object State {
+            get;
+            private set;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "1#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public Route MapRoute(string name, string url) {
+            return MapRoute(name, url, (object)null /* defaults */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "1#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public Route MapRoute(string name, string url, object defaults) {
+            return MapRoute(name, url, defaults, (object)null /* constraints */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "1#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public Route MapRoute(string name, string url, object defaults, object constraints) {
+            return MapRoute(name, url, defaults, constraints, null /* namespaces */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "1#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public Route MapRoute(string name, string url, string[] namespaces) {
+            return MapRoute(name, url, (object)null /* defaults */, namespaces);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "1#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public Route MapRoute(string name, string url, object defaults, string[] namespaces) {
+            return MapRoute(name, url, defaults, null /* constraints */, namespaces);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "1#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public Route MapRoute(string name, string url, object defaults, object constraints, string[] namespaces) {
+            if (namespaces == null && Namespaces != null) {
+                namespaces = Namespaces.ToArray();
+            }
+
+            Route route = Routes.MapRoute(name, url, defaults, constraints, namespaces);
+            route.DataTokens["area"] = AreaName;
+
+            // disabling the namespace lookup fallback mechanism keeps this areas from accidentally picking up
+            // controllers belonging to other areas
+            bool useNamespaceFallback = (namespaces == null || namespaces.Length == 0);
+            route.DataTokens["UseNamespaceFallback"] = useNamespaceFallback;
+
+            return route;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AssociatedMetadataProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/AssociatedMetadataProvider.cs
new file mode 100644 (file)
index 0000000..94c09aa
--- /dev/null
@@ -0,0 +1,93 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.ComponentModel.DataAnnotations;
+    using System.Globalization;
+    using System.Linq;
+    using System.Web.Mvc.Resources;
+
+    // This class provides a good implementation of ModelMetadataProvider for people who will be
+    // using traditional classes with properties. It uses the buddy class support from
+    // DataAnnotations, and consolidates the three operations down to a single override
+    // for reading the attribute values and creating the metadata class.
+    public abstract class AssociatedMetadataProvider : ModelMetadataProvider {
+        private static void ApplyMetadataAwareAttributes(IEnumerable<Attribute> attributes, ModelMetadata result) {
+            foreach (IMetadataAware awareAttribute in attributes.OfType<IMetadataAware>()) {
+                awareAttribute.OnMetadataCreated(result);
+            }
+        }
+
+        protected abstract ModelMetadata CreateMetadata(IEnumerable<Attribute> attributes, Type containerType, Func<object> modelAccessor, Type modelType, string propertyName);
+
+        protected virtual IEnumerable<Attribute> FilterAttributes(Type containerType, PropertyDescriptor propertyDescriptor, IEnumerable<Attribute> attributes) {
+            if (typeof(ViewPage).IsAssignableFrom(containerType) || typeof(ViewUserControl).IsAssignableFrom(containerType)) {
+                return attributes.Where(a => !(a is ReadOnlyAttribute));
+            }
+
+            return attributes;
+        }
+
+        public override IEnumerable<ModelMetadata> GetMetadataForProperties(object container, Type containerType) {
+            if (containerType == null) {
+                throw new ArgumentNullException("containerType");
+            }
+
+            return GetMetadataForPropertiesImpl(container, containerType);
+        }
+
+        private IEnumerable<ModelMetadata> GetMetadataForPropertiesImpl(object container, Type containerType) {
+            foreach (PropertyDescriptor property in GetTypeDescriptor(containerType).GetProperties()) {
+                Func<object> modelAccessor = container == null ? null : GetPropertyValueAccessor(container, property);
+                yield return GetMetadataForProperty(modelAccessor, containerType, property);
+            }
+        }
+
+        public override ModelMetadata GetMetadataForProperty(Func<object> modelAccessor, Type containerType, string propertyName) {
+            if (containerType == null) {
+                throw new ArgumentNullException("containerType");
+            }
+            if (String.IsNullOrEmpty(propertyName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "propertyName");
+            }
+
+            ICustomTypeDescriptor typeDescriptor = GetTypeDescriptor(containerType);
+            PropertyDescriptor property = typeDescriptor.GetProperties().Find(propertyName, true);
+            if (property == null) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.Common_PropertyNotFound,
+                        containerType.FullName, propertyName));
+            }
+
+            return GetMetadataForProperty(modelAccessor, containerType, property);
+        }
+
+        protected virtual ModelMetadata GetMetadataForProperty(Func<object> modelAccessor, Type containerType, PropertyDescriptor propertyDescriptor) {
+            IEnumerable<Attribute> attributes = FilterAttributes(containerType, propertyDescriptor, propertyDescriptor.Attributes.Cast<Attribute>());
+            ModelMetadata result = CreateMetadata(attributes, containerType, modelAccessor, propertyDescriptor.PropertyType, propertyDescriptor.Name);
+            ApplyMetadataAwareAttributes(attributes, result);
+            return result;
+        }
+
+        public override ModelMetadata GetMetadataForType(Func<object> modelAccessor, Type modelType) {
+            if (modelType == null) {
+                throw new ArgumentNullException("modelType");
+            }
+
+            IEnumerable<Attribute> attributes = GetTypeDescriptor(modelType).GetAttributes().Cast<Attribute>();
+            ModelMetadata result = CreateMetadata(attributes, null /* containerType */, modelAccessor, modelType, null /* propertyName */);
+            ApplyMetadataAwareAttributes(attributes, result);
+            return result;
+        }
+
+        private static Func<object> GetPropertyValueAccessor(object container, PropertyDescriptor property) {
+            return () => property.GetValue(container);
+        }
+
+        protected virtual ICustomTypeDescriptor GetTypeDescriptor(Type type) {
+            return TypeDescriptorHelper.Get(type);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AssociatedValidatorProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/AssociatedValidatorProvider.cs
new file mode 100644 (file)
index 0000000..a360bd0
--- /dev/null
@@ -0,0 +1,51 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.ComponentModel.DataAnnotations;
+    using System.Globalization;
+    using System.Linq;
+    using System.Web.Mvc.Resources;
+
+    public abstract class AssociatedValidatorProvider : ModelValidatorProvider {
+        protected virtual ICustomTypeDescriptor GetTypeDescriptor(Type type) {
+            return TypeDescriptorHelper.Get(type);
+        }
+
+        public override sealed IEnumerable<ModelValidator> GetValidators(ModelMetadata metadata, ControllerContext context) {
+            if (metadata == null) {
+                throw new ArgumentNullException("metadata");
+            }
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+
+            if (metadata.ContainerType != null && !String.IsNullOrEmpty(metadata.PropertyName)) {
+                return GetValidatorsForProperty(metadata, context);
+            }
+
+            return GetValidatorsForType(metadata, context);
+        }
+
+        protected abstract IEnumerable<ModelValidator> GetValidators(ModelMetadata metadata, ControllerContext context, IEnumerable<Attribute> attributes);
+
+        private IEnumerable<ModelValidator> GetValidatorsForProperty(ModelMetadata metadata, ControllerContext context) {
+            ICustomTypeDescriptor typeDescriptor = GetTypeDescriptor(metadata.ContainerType);
+            PropertyDescriptor property = typeDescriptor.GetProperties().Find(metadata.PropertyName, true);
+            if (property == null) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.Common_PropertyNotFound,
+                        metadata.ContainerType.FullName, metadata.PropertyName),
+                    "metadata");
+            }
+
+            return GetValidators(metadata, context, property.Attributes.OfType<Attribute>());
+        }
+
+        private IEnumerable<ModelValidator> GetValidatorsForType(ModelMetadata metadata, ControllerContext context) {
+            return GetValidators(metadata, context, GetTypeDescriptor(metadata.ModelType).GetAttributes().Cast<Attribute>());
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/ActionDescriptorCreator.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/ActionDescriptorCreator.cs
new file mode 100644 (file)
index 0000000..d746b3f
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc.Async {
+    using System;
+
+    internal delegate ActionDescriptor ActionDescriptorCreator(string actionName, ControllerDescriptor controllerDescriptor);
+
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncActionDescriptor.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncActionDescriptor.cs
new file mode 100644 (file)
index 0000000..fe408cf
--- /dev/null
@@ -0,0 +1,28 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Collections.Generic;
+
+    public abstract class AsyncActionDescriptor : ActionDescriptor {
+
+        public abstract IAsyncResult BeginExecute(ControllerContext controllerContext, IDictionary<string, object> parameters, AsyncCallback callback, object state);
+
+        public abstract object EndExecute(IAsyncResult asyncResult);
+
+        public override object Execute(ControllerContext controllerContext, IDictionary<string, object> parameters) {
+            // execute an asynchronous task synchronously
+            IAsyncResult asyncResult = BeginExecute(controllerContext, parameters, null, null);
+            AsyncUtil.WaitForAsyncResultCompletion(asyncResult, controllerContext.HttpContext.ApplicationInstance); // blocks
+            return EndExecute(asyncResult);
+        }
+
+        internal static AsyncManager GetAsyncManager(ControllerBase controller) {
+            IAsyncManagerContainer helperContainer = controller as IAsyncManagerContainer;
+            if (helperContainer == null) {
+                throw Error.AsyncCommon_ControllerMustImplementIAsyncManagerContainer(controller.GetType());
+            }
+
+            return helperContainer.AsyncManager;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncActionMethodSelector.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncActionMethodSelector.cs
new file mode 100644 (file)
index 0000000..5c05f18
--- /dev/null
@@ -0,0 +1,194 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.Linq;
+    using System.Reflection;
+    using System.Text;
+    using System.Web.Mvc.Resources;
+
+    internal sealed class AsyncActionMethodSelector {
+
+        public AsyncActionMethodSelector(Type controllerType) {
+            ControllerType = controllerType;
+            PopulateLookupTables();
+        }
+
+        public Type ControllerType {
+            get;
+            private set;
+        }
+
+        public MethodInfo[] AliasedMethods {
+            get;
+            private set;
+        }
+
+        public ILookup<string, MethodInfo> NonAliasedMethods {
+            get;
+            private set;
+        }
+
+        private AmbiguousMatchException CreateAmbiguousActionMatchException(IEnumerable<MethodInfo> ambiguousMethods, string actionName) {
+            string ambiguityList = CreateAmbiguousMatchList(ambiguousMethods);
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ActionMethodSelector_AmbiguousMatch,
+                actionName, ControllerType.Name, ambiguityList);
+            return new AmbiguousMatchException(message);
+        }
+
+        private AmbiguousMatchException CreateAmbiguousMethodMatchException(IEnumerable<MethodInfo> ambiguousMethods, string methodName) {
+            string ambiguityList = CreateAmbiguousMatchList(ambiguousMethods);
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.AsyncActionMethodSelector_AmbiguousMethodMatch,
+                methodName, ControllerType.Name, ambiguityList);
+            return new AmbiguousMatchException(message);
+        }
+
+        private static string CreateAmbiguousMatchList(IEnumerable<MethodInfo> ambiguousMethods) {
+            StringBuilder exceptionMessageBuilder = new StringBuilder();
+            foreach (MethodInfo methodInfo in ambiguousMethods) {
+                exceptionMessageBuilder.AppendLine();
+                exceptionMessageBuilder.AppendFormat(CultureInfo.CurrentCulture, MvcResources.ActionMethodSelector_AmbiguousMatchType, methodInfo, methodInfo.DeclaringType.FullName);
+            }
+
+            return exceptionMessageBuilder.ToString();
+        }
+
+        public ActionDescriptorCreator FindAction(ControllerContext controllerContext, string actionName) {
+            List<MethodInfo> methodsMatchingName = GetMatchingAliasedMethods(controllerContext, actionName);
+            methodsMatchingName.AddRange(NonAliasedMethods[actionName]);
+            List<MethodInfo> finalMethods = RunSelectionFilters(controllerContext, methodsMatchingName);
+
+            switch (finalMethods.Count) {
+                case 0:
+                    return null;
+
+                case 1:
+                    MethodInfo entryMethod = finalMethods[0];
+                    return GetActionDescriptorDelegate(entryMethod);
+
+                default:
+                    throw CreateAmbiguousActionMatchException(finalMethods, actionName);
+            }
+        }
+
+        private ActionDescriptorCreator GetActionDescriptorDelegate(MethodInfo entryMethod) {
+            // Is this the FooAsync() / FooCompleted() pattern?
+            if (IsAsyncSuffixedMethod(entryMethod)) {
+                string completionMethodName = entryMethod.Name.Substring(0, entryMethod.Name.Length - "Async".Length) + "Completed";
+                MethodInfo completionMethod = GetMethodByName(completionMethodName);
+                if (completionMethod != null) {
+                    return (actionName, controllerDescriptor) => new ReflectedAsyncActionDescriptor(entryMethod, completionMethod, actionName, controllerDescriptor);
+                }
+                else {
+                    throw Error.AsyncActionMethodSelector_CouldNotFindMethod(completionMethodName, ControllerType);
+                }
+            }
+
+            // Fallback to synchronous method
+            return (actionName, controllerDescriptor) => new ReflectedActionDescriptor(entryMethod, actionName, controllerDescriptor);
+        }
+
+        private static string GetCanonicalMethodName(MethodInfo methodInfo) {
+            string methodName = methodInfo.Name;
+            return (IsAsyncSuffixedMethod(methodInfo))
+                ? methodName.Substring(0, methodName.Length - "Async".Length)
+                : methodName;
+        }
+
+        internal List<MethodInfo> GetMatchingAliasedMethods(ControllerContext controllerContext, string actionName) {
+            // find all aliased methods which are opting in to this request
+            // to opt in, all attributes defined on the method must return true
+
+            var methods = from methodInfo in AliasedMethods
+                          let attrs = ReflectedAttributeCache.GetActionNameSelectorAttributes(methodInfo)
+                          where attrs.All(attr => attr.IsValidName(controllerContext, actionName, methodInfo))
+                          select methodInfo;
+            return methods.ToList();
+        }
+
+        private static bool IsAsyncSuffixedMethod(MethodInfo methodInfo) {
+            return methodInfo.Name.EndsWith("Async", StringComparison.OrdinalIgnoreCase);
+        }
+
+        private static bool IsCompletedSuffixedMethod(MethodInfo methodInfo) {
+            return methodInfo.Name.EndsWith("Completed", StringComparison.OrdinalIgnoreCase);
+        }
+
+        private static bool IsMethodDecoratedWithAliasingAttribute(MethodInfo methodInfo) {
+            return methodInfo.IsDefined(typeof(ActionNameSelectorAttribute), true /* inherit */);
+        }
+
+        private MethodInfo GetMethodByName(string methodName) {
+            List<MethodInfo> methods = (from MethodInfo methodInfo in ControllerType.GetMember(methodName, MemberTypes.Method, BindingFlags.Instance | BindingFlags.Public | BindingFlags.InvokeMethod | BindingFlags.IgnoreCase)
+                                        where IsValidActionMethod(methodInfo, false /* stripInfrastructureMethods */)
+                                        select methodInfo).ToList();
+
+            switch (methods.Count) {
+                case 0:
+                    return null;
+
+                case 1:
+                    return methods[0];
+
+                default:
+                    throw CreateAmbiguousMethodMatchException(methods, methodName);
+            }
+        }
+
+        private static bool IsValidActionMethod(MethodInfo methodInfo) {
+            return IsValidActionMethod(methodInfo, true /* stripInfrastructureMethods */);
+        }
+
+        private static bool IsValidActionMethod(MethodInfo methodInfo, bool stripInfrastructureMethods) {
+            if (methodInfo.IsSpecialName) {
+                // not a normal method, e.g. a constructor or an event
+                return false;
+            }
+
+            if (methodInfo.GetBaseDefinition().DeclaringType.IsAssignableFrom(typeof(AsyncController))) {
+                // is a method on Object, ControllerBase, Controller, or AsyncController
+                return false;
+            };
+
+            if (stripInfrastructureMethods) {
+                if (IsCompletedSuffixedMethod(methodInfo)) {
+                    // do not match FooCompleted() methods, as these are infrastructure methods
+                    return false;
+                }
+            }
+
+            return true;
+        }
+
+        private void PopulateLookupTables() {
+            MethodInfo[] allMethods = ControllerType.GetMethods(BindingFlags.InvokeMethod | BindingFlags.Instance | BindingFlags.Public);
+            MethodInfo[] actionMethods = Array.FindAll(allMethods, IsValidActionMethod);
+
+            AliasedMethods = Array.FindAll(actionMethods, IsMethodDecoratedWithAliasingAttribute);
+            NonAliasedMethods = actionMethods.Except(AliasedMethods).ToLookup(GetCanonicalMethodName, StringComparer.OrdinalIgnoreCase);
+        }
+
+        private static List<MethodInfo> RunSelectionFilters(ControllerContext controllerContext, List<MethodInfo> methodInfos) {
+            // remove all methods which are opting out of this request
+            // to opt out, at least one attribute defined on the method must return false
+
+            List<MethodInfo> matchesWithSelectionAttributes = new List<MethodInfo>();
+            List<MethodInfo> matchesWithoutSelectionAttributes = new List<MethodInfo>();
+
+            foreach (MethodInfo methodInfo in methodInfos) {
+                ICollection<ActionMethodSelectorAttribute> attrs = ReflectedAttributeCache.GetActionMethodSelectorAttributes(methodInfo);
+                if (attrs.Count == 0) {
+                    matchesWithoutSelectionAttributes.Add(methodInfo);
+                }
+                else if (attrs.All(attr => attr.IsValidForRequest(controllerContext, methodInfo))) {
+                    matchesWithSelectionAttributes.Add(methodInfo);
+                }
+            }
+
+            // if a matching action method had a selection attribute, consider it more specific than a matching action method
+            // without a selection attribute
+            return (matchesWithSelectionAttributes.Count > 0) ? matchesWithSelectionAttributes : matchesWithoutSelectionAttributes;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncControllerActionInvoker.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncControllerActionInvoker.cs
new file mode 100644 (file)
index 0000000..fe96d37
--- /dev/null
@@ -0,0 +1,270 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq;
+    using System.Threading;
+
+    public class AsyncControllerActionInvoker : ControllerActionInvoker, IAsyncActionInvoker {
+
+        private static readonly object _invokeActionTag = new object();
+        private static readonly object _invokeActionMethodTag = new object();
+        private static readonly object _invokeActionMethodWithFiltersTag = new object();
+
+        public virtual IAsyncResult BeginInvokeAction(ControllerContext controllerContext, string actionName, AsyncCallback callback, object state) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (String.IsNullOrEmpty(actionName)) {
+                throw Error.ParameterCannotBeNullOrEmpty("actionName");
+            }
+
+            ControllerDescriptor controllerDescriptor = GetControllerDescriptor(controllerContext);
+            ActionDescriptor actionDescriptor = controllerDescriptor.FindAction(controllerContext, actionName);
+            if (actionDescriptor != null) {
+                FilterInfo filterInfo = GetFilters(controllerContext, actionDescriptor);
+                Action continuation = null;
+
+                BeginInvokeDelegate beginDelegate = delegate(AsyncCallback asyncCallback, object asyncState) {
+                    try {
+                        AuthorizationContext authContext = InvokeAuthorizationFilters(controllerContext, filterInfo.AuthorizationFilters, actionDescriptor);
+                        if (authContext.Result != null) {
+                            // the auth filter signaled that we should let it short-circuit the request
+                            continuation = () => InvokeActionResult(controllerContext, authContext.Result);
+                        }
+                        else {
+                            if (controllerContext.Controller.ValidateRequest) {
+                                ValidateRequest(controllerContext);
+                            }
+
+                            IDictionary<string, object> parameters = GetParameterValues(controllerContext, actionDescriptor);
+                            IAsyncResult asyncResult = BeginInvokeActionMethodWithFilters(controllerContext, filterInfo.ActionFilters, actionDescriptor, parameters, asyncCallback, asyncState);
+                            continuation = () => {
+                                ActionExecutedContext postActionContext = EndInvokeActionMethodWithFilters(asyncResult);
+                                InvokeActionResultWithFilters(controllerContext, filterInfo.ResultFilters, postActionContext.Result);
+                            };
+                            return asyncResult;
+                        }
+                    }
+                    catch (ThreadAbortException) {
+                        // This type of exception occurs as a result of Response.Redirect(), but we special-case so that
+                        // the filters don't see this as an error.
+                        throw;
+                    }
+                    catch (Exception ex) {
+                        // something blew up, so execute the exception filters
+                        ExceptionContext exceptionContext = InvokeExceptionFilters(controllerContext, filterInfo.ExceptionFilters, ex);
+                        if (!exceptionContext.ExceptionHandled) {
+                            throw;
+                        }
+
+                        continuation = () => InvokeActionResult(controllerContext, exceptionContext.Result);
+                    }
+
+                    return BeginInvokeAction_MakeSynchronousAsyncResult(asyncCallback, asyncState);
+                };
+
+                EndInvokeDelegate<bool> endDelegate = delegate(IAsyncResult asyncResult) {
+                    try {
+                        continuation();
+                    }
+                    catch (ThreadAbortException) {
+                        // This type of exception occurs as a result of Response.Redirect(), but we special-case so that
+                        // the filters don't see this as an error.
+                        throw;
+                    }
+                    catch (Exception ex) {
+                        // something blew up, so execute the exception filters
+                        ExceptionContext exceptionContext = InvokeExceptionFilters(controllerContext, filterInfo.ExceptionFilters, ex);
+                        if (!exceptionContext.ExceptionHandled) {
+                            throw;
+                        }
+                        InvokeActionResult(controllerContext, exceptionContext.Result);
+                    }
+
+                    return true;
+                };
+
+                return AsyncResultWrapper.Begin(callback, state, beginDelegate, endDelegate, _invokeActionTag);
+            }
+            else {
+                // Notify the controller that no action was found.
+                return BeginInvokeAction_ActionNotFound(callback, state);
+            }
+        }
+
+        private static IAsyncResult BeginInvokeAction_ActionNotFound(AsyncCallback callback, object state) {
+            BeginInvokeDelegate beginDelegate = BeginInvokeAction_MakeSynchronousAsyncResult;
+
+            EndInvokeDelegate<bool> endDelegate = delegate(IAsyncResult asyncResult) {
+                return false;
+            };
+
+            return AsyncResultWrapper.Begin(callback, state, beginDelegate, endDelegate, _invokeActionTag);
+        }
+
+        private static IAsyncResult BeginInvokeAction_MakeSynchronousAsyncResult(AsyncCallback callback, object state) {
+            SimpleAsyncResult asyncResult = new SimpleAsyncResult(state);
+            asyncResult.MarkCompleted(true /* completedSynchronously */, callback);
+            return asyncResult;
+        }
+
+        protected internal virtual IAsyncResult BeginInvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary<string, object> parameters, AsyncCallback callback, object state) {
+            AsyncActionDescriptor asyncActionDescriptor = actionDescriptor as AsyncActionDescriptor;
+            if (asyncActionDescriptor != null) {
+                return BeginInvokeAsynchronousActionMethod(controllerContext, asyncActionDescriptor, parameters, callback, state);
+            }
+            else {
+                return BeginInvokeSynchronousActionMethod(controllerContext, actionDescriptor, parameters, callback, state);
+            }
+        }
+
+        protected internal virtual IAsyncResult BeginInvokeActionMethodWithFilters(ControllerContext controllerContext, IList<IActionFilter> filters, ActionDescriptor actionDescriptor, IDictionary<string, object> parameters, AsyncCallback callback, object state) {
+            Func<ActionExecutedContext> endContinuation = null;
+
+            BeginInvokeDelegate beginDelegate = delegate(AsyncCallback asyncCallback, object asyncState) {
+                ActionExecutingContext preContext = new ActionExecutingContext(controllerContext, actionDescriptor, parameters);
+                IAsyncResult innerAsyncResult = null;
+
+                Func<Func<ActionExecutedContext>> beginContinuation = () => {
+                    innerAsyncResult = BeginInvokeActionMethod(controllerContext, actionDescriptor, parameters, asyncCallback, asyncState);
+                    return () =>
+                        new ActionExecutedContext(controllerContext, actionDescriptor, false /* canceled */, null /* exception */) {
+                            Result = EndInvokeActionMethod(innerAsyncResult)
+                        };
+                };
+
+                // need to reverse the filter list because the continuations are built up backward
+                Func<Func<ActionExecutedContext>> thunk = filters.Reverse().Aggregate(beginContinuation,
+                    (next, filter) => () => InvokeActionMethodFilterAsynchronously(filter, preContext, next));
+                endContinuation = thunk();
+
+                if (innerAsyncResult != null) {
+                    // we're just waiting for the inner result to complete
+                    return innerAsyncResult;
+                }
+                else {
+                    // something was short-circuited and the action was not called, so this was a synchronous operation
+                    SimpleAsyncResult newAsyncResult = new SimpleAsyncResult(asyncState);
+                    newAsyncResult.MarkCompleted(true /* completedSynchronously */, asyncCallback);
+                    return newAsyncResult;
+                }
+            };
+
+            EndInvokeDelegate<ActionExecutedContext> endDelegate = delegate(IAsyncResult asyncResult) {
+                return endContinuation();
+            };
+
+            return AsyncResultWrapper.Begin(callback, state, beginDelegate, endDelegate, _invokeActionMethodWithFiltersTag);
+        }
+
+        private IAsyncResult BeginInvokeAsynchronousActionMethod(ControllerContext controllerContext, AsyncActionDescriptor actionDescriptor, IDictionary<string, object> parameters, AsyncCallback callback, object state) {
+            BeginInvokeDelegate beginDelegate = delegate(AsyncCallback asyncCallback, object asyncState) {
+                return actionDescriptor.BeginExecute(controllerContext, parameters, asyncCallback, asyncState);
+            };
+
+            EndInvokeDelegate<ActionResult> endDelegate = delegate(IAsyncResult asyncResult) {
+                object returnValue = actionDescriptor.EndExecute(asyncResult);
+                ActionResult result = CreateActionResult(controllerContext, actionDescriptor, returnValue);
+                return result;
+            };
+
+            return AsyncResultWrapper.Begin(callback, state, beginDelegate, endDelegate, _invokeActionMethodTag);
+        }
+
+        private IAsyncResult BeginInvokeSynchronousActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary<string, object> parameters, AsyncCallback callback, object state) {
+            return AsyncResultWrapper.BeginSynchronous(callback, state,
+                () => InvokeSynchronousActionMethod(controllerContext, actionDescriptor, parameters),
+                _invokeActionMethodTag);
+        }
+
+        public virtual bool EndInvokeAction(IAsyncResult asyncResult) {
+            return AsyncResultWrapper.End<bool>(asyncResult, _invokeActionTag);
+        }
+
+        protected internal virtual ActionResult EndInvokeActionMethod(IAsyncResult asyncResult) {
+            return AsyncResultWrapper.End<ActionResult>(asyncResult, _invokeActionMethodTag);
+        }
+
+        protected internal virtual ActionExecutedContext EndInvokeActionMethodWithFilters(IAsyncResult asyncResult) {
+            return AsyncResultWrapper.End<ActionExecutedContext>(asyncResult, _invokeActionMethodWithFiltersTag);
+        }
+
+        protected override ControllerDescriptor GetControllerDescriptor(ControllerContext controllerContext) {
+            Type controllerType = controllerContext.Controller.GetType();
+            ControllerDescriptor controllerDescriptor = DescriptorCache.GetDescriptor(controllerType, () => new ReflectedAsyncControllerDescriptor(controllerType));
+            return controllerDescriptor;
+        }
+
+        internal static Func<ActionExecutedContext> InvokeActionMethodFilterAsynchronously(IActionFilter filter, ActionExecutingContext preContext, Func<Func<ActionExecutedContext>> nextInChain) {
+            filter.OnActionExecuting(preContext);
+            if (preContext.Result != null) {
+                ActionExecutedContext shortCircuitedPostContext = new ActionExecutedContext(preContext, preContext.ActionDescriptor, true /* canceled */, null /* exception */) {
+                    Result = preContext.Result
+                };
+                return () => shortCircuitedPostContext;
+            }
+
+            // There is a nested try / catch block here that contains much the same logic as the outer block.
+            // Since an exception can occur on either side of the asynchronous invocation, we need guards on
+            // on both sides. In the code below, the second side is represented by the nested delegate. This
+            // is really just a parallel of the synchronous ControllerActionInvoker.InvokeActionMethodFilter()
+            // method.
+
+            try {
+                Func<ActionExecutedContext> continuation = nextInChain();
+
+                // add our own continuation, then return the new function
+                return () => {
+                    ActionExecutedContext postContext;
+                    bool wasError = true;
+
+                    try {
+                        postContext = continuation();
+                        wasError = false;
+                    }
+                    catch (ThreadAbortException) {
+                        // This type of exception occurs as a result of Response.Redirect(), but we special-case so that
+                        // the filters don't see this as an error.
+                        postContext = new ActionExecutedContext(preContext, preContext.ActionDescriptor, false /* canceled */, null /* exception */);
+                        filter.OnActionExecuted(postContext);
+                        throw;
+                    }
+                    catch (Exception ex) {
+                        postContext = new ActionExecutedContext(preContext, preContext.ActionDescriptor, false /* canceled */, ex);
+                        filter.OnActionExecuted(postContext);
+                        if (!postContext.ExceptionHandled) {
+                            throw;
+                        }
+                    }
+                    if (!wasError) {
+                        filter.OnActionExecuted(postContext);
+                    }
+
+                    return postContext;
+                };
+            }
+            catch (ThreadAbortException) {
+                // This type of exception occurs as a result of Response.Redirect(), but we special-case so that
+                // the filters don't see this as an error.
+                ActionExecutedContext postContext = new ActionExecutedContext(preContext, preContext.ActionDescriptor, false /* canceled */, null /* exception */);
+                filter.OnActionExecuted(postContext);
+                throw;
+            }
+            catch (Exception ex) {
+                ActionExecutedContext postContext = new ActionExecutedContext(preContext, preContext.ActionDescriptor, false /* canceled */, ex);
+                filter.OnActionExecuted(postContext);
+                if (postContext.ExceptionHandled) {
+                    return () => postContext;
+                }
+                else {
+                    throw;
+                }
+            }
+        }
+
+        private ActionResult InvokeSynchronousActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary<string, object> parameters) {
+            return base.InvokeActionMethod(controllerContext, actionDescriptor, parameters);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncManager.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncManager.cs
new file mode 100644 (file)
index 0000000..ba2c1f0
--- /dev/null
@@ -0,0 +1,67 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Collections.Generic;
+    using System.Threading;
+
+    public class AsyncManager {
+
+        private readonly SynchronizationContext _syncContext;
+
+        // default timeout is 45 sec
+        // from: http://msdn.microsoft.com/en-us/library/system.web.ui.page.asynctimeout.aspx
+        private int _timeout = 45 * 1000;
+
+        public AsyncManager()
+            : this(null /* syncContext */) {
+        }
+
+        public AsyncManager(SynchronizationContext syncContext) {
+            _syncContext = syncContext ?? SynchronizationContextUtil.GetSynchronizationContext();
+
+            OutstandingOperations = new OperationCounter();
+            OutstandingOperations.Completed += delegate { Finish(); };
+
+            Parameters = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
+        }
+
+        public OperationCounter OutstandingOperations {
+            get;
+            private set;
+        }
+
+        public IDictionary<string, object> Parameters {
+            get;
+            private set;
+        }
+
+        public event EventHandler Finished;
+
+        // the developer may call this function to signal that all operations are complete instead of
+        // waiting for the operation counter to reach zero
+        public virtual void Finish() {
+            EventHandler handler = Finished;
+            if (handler != null) {
+                handler(this, EventArgs.Empty);
+            }
+        }
+
+        // executes a callback in the current synchronization context, which gives access to HttpContext and related items
+        public virtual void Sync(Action action) {
+            _syncContext.Sync(action);
+        }
+
+        // measured in milliseconds, Timeout.Infinite means 'no timeout'
+        public int Timeout {
+            get {
+                return _timeout;
+            }
+            set {
+                if (value < -1) {
+                    throw Error.AsyncCommon_InvalidTimeout("value");
+                }
+                _timeout = value;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncResultWrapper.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncResultWrapper.cs
new file mode 100644 (file)
index 0000000..c8e108b
--- /dev/null
@@ -0,0 +1,256 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Threading;
+
+    // This class is used for the following pattern:
+
+    // public IAsyncResult BeginInner(..., callback, state);
+    // public TInnerResult EndInner(asyncResult);
+    // public IAsyncResult BeginOuter(..., callback, state);
+    // public TOuterResult EndOuter(asyncResult);
+
+    // That is, Begin/EndOuter() wrap Begin/EndInner(), potentially with pre- and post-processing.
+
+    internal static class AsyncResultWrapper {
+
+        // helper methods
+
+        private static Func<AsyncVoid> MakeVoidDelegate(Action action) {
+            return () =>
+            {
+                action();
+                return default(AsyncVoid);
+            };
+        }
+
+        private static EndInvokeDelegate<AsyncVoid> MakeVoidDelegate(EndInvokeDelegate endDelegate) {
+            return ar =>
+            {
+                endDelegate(ar);
+                return default(AsyncVoid);
+            };
+        }
+
+        // kicks off an asynchronous operation
+
+        public static IAsyncResult Begin<TResult>(AsyncCallback callback, object state, BeginInvokeDelegate beginDelegate, EndInvokeDelegate<TResult> endDelegate) {
+            return Begin<TResult>(callback, state, beginDelegate, endDelegate, null /* tag */);
+        }
+
+        public static IAsyncResult Begin<TResult>(AsyncCallback callback, object state, BeginInvokeDelegate beginDelegate, EndInvokeDelegate<TResult> endDelegate, object tag) {
+            return Begin<TResult>(callback, state, beginDelegate, endDelegate, tag, Timeout.Infinite);
+        }
+
+        public static IAsyncResult Begin<TResult>(AsyncCallback callback, object state, BeginInvokeDelegate beginDelegate, EndInvokeDelegate<TResult> endDelegate, object tag, int timeout) {
+            WrappedAsyncResult<TResult> asyncResult = new WrappedAsyncResult<TResult>(beginDelegate, endDelegate, tag);
+            asyncResult.Begin(callback, state, timeout);
+            return asyncResult;
+        }
+
+        public static IAsyncResult Begin(AsyncCallback callback, object state, BeginInvokeDelegate beginDelegate, EndInvokeDelegate endDelegate) {
+            return Begin(callback, state, beginDelegate, endDelegate, null /* tag */);
+        }
+
+        public static IAsyncResult Begin(AsyncCallback callback, object state, BeginInvokeDelegate beginDelegate, EndInvokeDelegate endDelegate, object tag) {
+            return Begin(callback, state, beginDelegate, endDelegate, tag, Timeout.Infinite);
+        }
+
+        public static IAsyncResult Begin(AsyncCallback callback, object state, BeginInvokeDelegate beginDelegate, EndInvokeDelegate endDelegate, object tag, int timeout) {
+            return Begin<AsyncVoid>(callback, state, beginDelegate, MakeVoidDelegate(endDelegate), tag, timeout);
+        }
+
+        // wraps a synchronous operation in an asynchronous wrapper, but still completes synchronously
+
+        public static IAsyncResult BeginSynchronous<TResult>(AsyncCallback callback, object state, Func<TResult> func) {
+            return BeginSynchronous<TResult>(callback, state, func, null /* tag */);
+        }
+
+        public static IAsyncResult BeginSynchronous<TResult>(AsyncCallback callback, object state, Func<TResult> func, object tag) {
+            // Begin() doesn't perform any work on its own and returns immediately.
+            BeginInvokeDelegate beginDelegate = (asyncCallback, asyncState) =>
+            {
+                SimpleAsyncResult innerAsyncResult = new SimpleAsyncResult(asyncState);
+                innerAsyncResult.MarkCompleted(true /* completedSynchronously */, asyncCallback);
+                return innerAsyncResult;
+            };
+
+            // The End() method blocks.
+            EndInvokeDelegate<TResult> endDelegate = _ =>
+            {
+                return func();
+            };
+
+            WrappedAsyncResult<TResult> asyncResult = new WrappedAsyncResult<TResult>(beginDelegate, endDelegate, tag);
+            asyncResult.Begin(callback, state, Timeout.Infinite);
+            return asyncResult;
+        }
+
+        public static IAsyncResult BeginSynchronous(AsyncCallback callback, object state, Action action) {
+            return BeginSynchronous(callback, state, action, null /* tag */);
+        }
+
+        public static IAsyncResult BeginSynchronous(AsyncCallback callback, object state, Action action, object tag) {
+            return BeginSynchronous<AsyncVoid>(callback, state, MakeVoidDelegate(action), tag);
+        }
+
+        // completes an asynchronous operation
+
+        public static TResult End<TResult>(IAsyncResult asyncResult) {
+            return End<TResult>(asyncResult, null /* tag */);
+        }
+
+        public static TResult End<TResult>(IAsyncResult asyncResult, object tag) {
+            return WrappedAsyncResult<TResult>.Cast(asyncResult, tag).End();
+        }
+
+        public static void End(IAsyncResult asyncResult) {
+            End(asyncResult, null /* tag */);
+        }
+
+        public static void End(IAsyncResult asyncResult, object tag) {
+            End<AsyncVoid>(asyncResult, tag);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1001:TypesThatOwnDisposableFieldsShouldBeDisposable", Justification = "The Timer will be disposed of either when it fires or when the operation completes successfully.")]
+        private sealed class WrappedAsyncResult<TResult> : IAsyncResult {
+
+            private readonly BeginInvokeDelegate _beginDelegate;
+            private readonly object _beginDelegateLockObj = new object();
+            private readonly EndInvokeDelegate<TResult> _endDelegate;
+            private readonly SingleEntryGate _endExecutedGate = new SingleEntryGate(); // prevent End() from being called twice
+            private readonly SingleEntryGate _handleCallbackGate = new SingleEntryGate(); // prevent callback from being handled multiple times
+            private IAsyncResult _innerAsyncResult;
+            private AsyncCallback _originalCallback;
+            private readonly object _tag; // prevent an instance of this type from being passed to the wrong End() method
+            private volatile bool _timedOut;
+            private Timer _timer;
+
+            public WrappedAsyncResult(BeginInvokeDelegate beginDelegate, EndInvokeDelegate<TResult> endDelegate, object tag) {
+                _beginDelegate = beginDelegate;
+                _endDelegate = endDelegate;
+                _tag = tag;
+            }
+
+            public object AsyncState {
+                get {
+                    return _innerAsyncResult.AsyncState;
+                }
+            }
+
+            public WaitHandle AsyncWaitHandle {
+                get {
+                    return _innerAsyncResult.AsyncWaitHandle;
+                }
+            }
+
+            public bool CompletedSynchronously {
+                get {
+                    return _innerAsyncResult.CompletedSynchronously;
+                }
+            }
+
+            public bool IsCompleted {
+                get {
+                    return _innerAsyncResult.IsCompleted;
+                }
+            }
+
+            // kicks off the process, instantiates a timer if requested
+            public void Begin(AsyncCallback callback, object state, int timeout) {
+                _originalCallback = callback;
+                bool completedSynchronously;
+
+                // Force the target Begin() operation to complete before the callback can continue,
+                // since the target operation might perform post-processing of the data.
+                lock (_beginDelegateLockObj) {
+                    _innerAsyncResult = _beginDelegate(HandleAsynchronousCompletion, state);
+
+                    completedSynchronously = _innerAsyncResult.CompletedSynchronously;
+                    if (!completedSynchronously) {
+                        if (timeout > Timeout.Infinite) {
+                            CreateTimer(timeout);
+                        }
+                    }
+                }
+
+                if (completedSynchronously) {
+                    if (callback != null) {
+                        callback(this);
+                    }
+                }
+            }
+
+            public static WrappedAsyncResult<TResult> Cast(IAsyncResult asyncResult, object tag) {
+                if (asyncResult == null) {
+                    throw new ArgumentNullException("asyncResult");
+                }
+
+                WrappedAsyncResult<TResult> castResult = asyncResult as WrappedAsyncResult<TResult>;
+                if (castResult != null && Object.Equals(castResult._tag, tag)) {
+                    return castResult;
+                }
+                else {
+                    throw Error.AsyncCommon_InvalidAsyncResult("asyncResult");
+                }
+            }
+
+            private void CreateTimer(int timeout) {
+                // this method should be called within a lock(_beginDelegateLockObj)
+                _timer = new Timer(HandleTimeout, null, timeout, Timeout.Infinite /* disable periodic signaling */);
+            }
+
+            public TResult End() {
+                if (!_endExecutedGate.TryEnter()) {
+                    throw Error.AsyncCommon_AsyncResultAlreadyConsumed();
+                }
+
+                if (_timedOut) {
+                    throw new TimeoutException();
+                }
+                WaitForBeginToCompleteAndDestroyTimer();
+
+                return _endDelegate(_innerAsyncResult);
+            }
+
+            private void ExecuteAsynchronousCallback(bool timedOut) {
+                WaitForBeginToCompleteAndDestroyTimer();
+
+                if (_handleCallbackGate.TryEnter()) {
+                    _timedOut = timedOut;
+                    if (_originalCallback != null) {
+                        _originalCallback(this);
+                    }
+                }
+            }
+
+            private void HandleAsynchronousCompletion(IAsyncResult asyncResult) {
+                if (asyncResult.CompletedSynchronously) {
+                    // If the operation completed synchronously, the WrappedAsyncResult.Begin() method will handle it.
+                    return;
+                }
+
+                ExecuteAsynchronousCallback(false /* timedOut */);
+            }
+
+            private void HandleTimeout(object state) {
+                ExecuteAsynchronousCallback(true /* timedOut */);
+            }
+
+            private void WaitForBeginToCompleteAndDestroyTimer() {
+                lock (_beginDelegateLockObj) {
+                    // Wait for the target Begin() method to complete, as it might be performing
+                    // post-processing. This also forces a memory barrier, so _innerAsyncResult
+                    // is guaranteed to be non-null at this point.
+
+                    if (_timer != null) {
+                        _timer.Dispose();
+                    }
+                    _timer = null;
+                }
+            }
+
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncUtil.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncUtil.cs
new file mode 100644 (file)
index 0000000..3984cdf
--- /dev/null
@@ -0,0 +1,63 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Threading;
+
+    internal static class AsyncUtil {
+
+        public static void WaitForAsyncResultCompletion(IAsyncResult asyncResult, HttpApplication app) {
+            // based on HttpServerUtility.ExecuteInternal()
+
+            if (!asyncResult.IsCompleted) {
+                // suspend app lock while waiting, else might deadlock
+                bool needToRelock = false;
+
+                try {
+                    // .NET 2.0+ will not allow a ThreadAbortException to be thrown while a
+                    // thread is inside a finally block, so this pattern ensures that the
+                    // value of 'needToRelock' is correct.
+                    try { }
+                    finally {
+                        Monitor.Exit(app);
+                        needToRelock = true;
+                    }
+
+                    WaitHandle waitHandle = asyncResult.AsyncWaitHandle;
+
+                    if (waitHandle != null) {
+                        waitHandle.WaitOne();
+                    }
+                    else {
+                        while (!asyncResult.IsCompleted) {
+                            Thread.Sleep(1);
+                        }
+                    }
+                }
+                finally {
+                    if (needToRelock) {
+                        Monitor.Enter(app);
+                    }
+                }
+            }
+        }
+
+        public static AsyncCallback WrapCallbackForSynchronizedExecution(AsyncCallback callback, SynchronizationContext syncContext) {
+            if (callback == null || syncContext == null) {
+                return callback;
+            }
+
+            AsyncCallback newCallback = delegate(IAsyncResult asyncResult) {
+                if (asyncResult.CompletedSynchronously) {
+                    callback(asyncResult);
+                }
+                else {
+                    // Only take the application lock if this request completed asynchronously,
+                    // else we might end up in a deadlock situation.
+                    syncContext.Sync(() => callback(asyncResult));
+                }
+            };
+
+            return newCallback;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncVoid.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/AsyncVoid.cs
new file mode 100644 (file)
index 0000000..feaf6a5
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc.Async {
+    using System;
+
+    // Dummy type used for passing something resembling 'void' to the async delegate functions
+    internal struct AsyncVoid {
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/BeginInvokeDelegate.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/BeginInvokeDelegate.cs
new file mode 100644 (file)
index 0000000..a3d8a42
--- /dev/null
@@ -0,0 +1,5 @@
+namespace System.Web.Mvc.Async {
+    using System;
+
+    internal delegate IAsyncResult BeginInvokeDelegate(AsyncCallback callback, object state);
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/EndInvokeDelegate.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/EndInvokeDelegate.cs
new file mode 100644 (file)
index 0000000..edff357
--- /dev/null
@@ -0,0 +1,5 @@
+namespace System.Web.Mvc.Async {
+    using System;
+
+    internal delegate void EndInvokeDelegate(IAsyncResult asyncResult);
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/EndInvokeDelegate`1.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/EndInvokeDelegate`1.cs
new file mode 100644 (file)
index 0000000..6ec804d
--- /dev/null
@@ -0,0 +1,5 @@
+namespace System.Web.Mvc.Async {
+    using System;
+
+    internal delegate TResult EndInvokeDelegate<TResult>(IAsyncResult asyncResult);
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/IAsyncActionInvoker.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/IAsyncActionInvoker.cs
new file mode 100644 (file)
index 0000000..cafed24
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc.Async {
+    using System;
+
+    public interface IAsyncActionInvoker : IActionInvoker {
+        IAsyncResult BeginInvokeAction(ControllerContext controllerContext, string actionName, AsyncCallback callback, object state);
+        bool EndInvokeAction(IAsyncResult asyncResult);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/IAsyncController.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/IAsyncController.cs
new file mode 100644 (file)
index 0000000..35ad868
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc.Async {
+    using System.Web.Routing;
+
+    public interface IAsyncController : IController {
+        IAsyncResult BeginExecute(RequestContext requestContext, AsyncCallback callback, object state);
+        void EndExecute(IAsyncResult asyncResult);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/IAsyncManagerContainer.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/IAsyncManagerContainer.cs
new file mode 100644 (file)
index 0000000..4547f32
--- /dev/null
@@ -0,0 +1,10 @@
+namespace System.Web.Mvc.Async {
+
+    public interface IAsyncManagerContainer {
+
+        AsyncManager AsyncManager {
+            get;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/OperationCounter.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/OperationCounter.cs
new file mode 100644 (file)
index 0000000..5c8e5e5
--- /dev/null
@@ -0,0 +1,50 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Threading;
+
+    public sealed class OperationCounter {
+
+        private int _count;
+
+        public int Count {
+            get {
+                return Thread.VolatileRead(ref _count);
+            }
+        }
+
+        public event EventHandler Completed;
+
+        private int AddAndExecuteCallbackIfCompleted(int value) {
+            int newCount = Interlocked.Add(ref _count, value);
+            if (newCount == 0) {
+                OnCompleted();
+            }
+
+            return newCount;
+        }
+
+        public int Decrement() {
+            return AddAndExecuteCallbackIfCompleted(-1);
+        }
+
+        public int Decrement(int value) {
+            return AddAndExecuteCallbackIfCompleted(-value);
+        }
+
+        public int Increment() {
+            return AddAndExecuteCallbackIfCompleted(1);
+        }
+
+        public int Increment(int value) {
+            return AddAndExecuteCallbackIfCompleted(value);
+        }
+
+        private void OnCompleted() {
+            EventHandler handler = Completed;
+            if (handler != null) {
+                handler(this, EventArgs.Empty);
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/ReflectedAsyncActionDescriptor.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/ReflectedAsyncActionDescriptor.cs
new file mode 100644 (file)
index 0000000..2523cac
--- /dev/null
@@ -0,0 +1,185 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq;
+    using System.Reflection;
+    using System.Threading;
+
+    public class ReflectedAsyncActionDescriptor : AsyncActionDescriptor {
+
+        private readonly object _executeTag = new object();
+
+        private readonly string _actionName;
+        private readonly ControllerDescriptor _controllerDescriptor;
+        private ParameterDescriptor[] _parametersCache;
+        private readonly Lazy<string> _uniqueId;
+
+        public ReflectedAsyncActionDescriptor(MethodInfo asyncMethodInfo, MethodInfo completedMethodInfo, string actionName, ControllerDescriptor controllerDescriptor)
+            : this(asyncMethodInfo, completedMethodInfo, actionName, controllerDescriptor, true /* validateMethods */) {
+        }
+
+        internal ReflectedAsyncActionDescriptor(MethodInfo asyncMethodInfo, MethodInfo completedMethodInfo, string actionName, ControllerDescriptor controllerDescriptor, bool validateMethods) {
+            if (asyncMethodInfo == null) {
+                throw new ArgumentNullException("asyncMethodInfo");
+            }
+            if (completedMethodInfo == null) {
+                throw new ArgumentNullException("completedMethodInfo");
+            }
+            if (String.IsNullOrEmpty(actionName)) {
+                throw Error.ParameterCannotBeNullOrEmpty("actionName");
+            }
+            if (controllerDescriptor == null) {
+                throw new ArgumentNullException("controllerDescriptor");
+            }
+
+            if (validateMethods) {
+                string asyncFailedMessage = VerifyActionMethodIsCallable(asyncMethodInfo);
+                if (asyncFailedMessage != null) {
+                    throw new ArgumentException(asyncFailedMessage, "asyncMethodInfo");
+                }
+
+                string completedFailedMessage = VerifyActionMethodIsCallable(completedMethodInfo);
+                if (completedFailedMessage != null) {
+                    throw new ArgumentException(completedFailedMessage, "completedMethodInfo");
+                }
+            }
+
+            AsyncMethodInfo = asyncMethodInfo;
+            CompletedMethodInfo = completedMethodInfo;
+            _actionName = actionName;
+            _controllerDescriptor = controllerDescriptor;
+            _uniqueId = new Lazy<string>(CreateUniqueId);
+        }
+
+        public override string ActionName {
+            get {
+                return _actionName;
+            }
+        }
+
+        public MethodInfo AsyncMethodInfo {
+            get;
+            private set;
+        }
+
+        public MethodInfo CompletedMethodInfo {
+            get;
+            private set;
+        }
+
+        public override ControllerDescriptor ControllerDescriptor {
+            get {
+                return _controllerDescriptor;
+            }
+        }
+
+        public override string UniqueId {
+            get {
+                return _uniqueId.Value;
+            }
+        }
+
+        public override IAsyncResult BeginExecute(ControllerContext controllerContext, IDictionary<string, object> parameters, AsyncCallback callback, object state) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (parameters == null) {
+                throw new ArgumentNullException("parameters");
+            }
+
+            AsyncManager asyncManager = GetAsyncManager(controllerContext.Controller);
+
+            BeginInvokeDelegate beginDelegate = delegate(AsyncCallback asyncCallback, object asyncState) {
+                // call the XxxAsync() method
+                ParameterInfo[] parameterInfos = AsyncMethodInfo.GetParameters();
+                var rawParameterValues = from parameterInfo in parameterInfos
+                                         select ExtractParameterFromDictionary(parameterInfo, parameters, AsyncMethodInfo);
+                object[] parametersArray = rawParameterValues.ToArray();
+
+                TriggerListener listener = new TriggerListener();
+                SimpleAsyncResult asyncResult = new SimpleAsyncResult(asyncState);
+
+                // hook the Finished event to notify us upon completion
+                Trigger finishTrigger = listener.CreateTrigger();
+                asyncManager.Finished += delegate { finishTrigger.Fire(); };
+                asyncManager.OutstandingOperations.Increment();
+
+                // to simplify the logic, force the rest of the pipeline to execute in an asynchronous callback
+                listener.SetContinuation(() => ThreadPool.QueueUserWorkItem(_ => asyncResult.MarkCompleted(false /* completedSynchronously */, asyncCallback)));
+
+                // the inner operation might complete synchronously, so all setup work has to be done before this point
+                ActionMethodDispatcher dispatcher = DispatcherCache.GetDispatcher(AsyncMethodInfo);
+                dispatcher.Execute(controllerContext.Controller, parametersArray); // ignore return value from this method
+
+                // now that the XxxAsync() method has completed, kick off any pending operations
+                asyncManager.OutstandingOperations.Decrement();
+                listener.Activate();
+                return asyncResult;
+            };
+
+            EndInvokeDelegate<object> endDelegate = delegate(IAsyncResult asyncResult) {
+                // call the XxxCompleted() method
+                ParameterInfo[] completionParametersInfos = CompletedMethodInfo.GetParameters();
+                var rawCompletionParameterValues = from parameterInfo in completionParametersInfos
+                                                   select ExtractParameterOrDefaultFromDictionary(parameterInfo, asyncManager.Parameters);
+                object[] completionParametersArray = rawCompletionParameterValues.ToArray();
+
+                ActionMethodDispatcher dispatcher = DispatcherCache.GetDispatcher(CompletedMethodInfo);
+                object actionReturnValue = dispatcher.Execute(controllerContext.Controller, completionParametersArray);
+                return actionReturnValue;
+            };
+
+            return AsyncResultWrapper.Begin(callback, state, beginDelegate, endDelegate, _executeTag, asyncManager.Timeout);
+        }
+
+        private string CreateUniqueId() {
+            return base.UniqueId + DescriptorUtil.CreateUniqueId(AsyncMethodInfo, CompletedMethodInfo);
+        }
+
+        public override object EndExecute(IAsyncResult asyncResult) {
+            return AsyncResultWrapper.End<object>(asyncResult, _executeTag);
+        }
+
+        public override object[] GetCustomAttributes(bool inherit) {
+            return AsyncMethodInfo.GetCustomAttributes(inherit);
+        }
+
+        public override object[] GetCustomAttributes(Type attributeType, bool inherit) {
+            return AsyncMethodInfo.GetCustomAttributes(attributeType, inherit);
+        }
+
+        internal override IEnumerable<FilterAttribute> GetFilterAttributes(bool useCache) {
+            if (useCache && GetType() == typeof(ReflectedAsyncActionDescriptor)) {
+                // Do not look at cache in types derived from this type because they might incorrectly implement GetCustomAttributes
+                return ReflectedAttributeCache.GetMethodFilterAttributes(AsyncMethodInfo);
+            }
+            return base.GetFilterAttributes(useCache);
+        }
+
+        public override ParameterDescriptor[] GetParameters() {
+            ParameterDescriptor[] parameters = LazilyFetchParametersCollection();
+
+            // need to clone array so that user modifications aren't accidentally stored
+            return (ParameterDescriptor[])parameters.Clone();
+        }
+
+        public override ICollection<ActionSelector> GetSelectors() {
+            // By default, we only look at filters on the XxxAsync() method.
+
+            ActionMethodSelectorAttribute[] attrs = (ActionMethodSelectorAttribute[])AsyncMethodInfo.GetCustomAttributes(typeof(ActionMethodSelectorAttribute), true /* inherit */);
+            ActionSelector[] selectors = Array.ConvertAll(attrs, attr => (ActionSelector)(controllerContext => attr.IsValidForRequest(controllerContext, AsyncMethodInfo)));
+            return selectors;
+        }
+
+        public override bool IsDefined(Type attributeType, bool inherit) {
+            return AsyncMethodInfo.IsDefined(attributeType, inherit);
+        }
+
+        private ParameterDescriptor[] LazilyFetchParametersCollection() {
+            return DescriptorUtil.LazilyFetchOrCreateDescriptors<ParameterInfo, ParameterDescriptor>(
+                ref _parametersCache /* cacheLocation */,
+                AsyncMethodInfo.GetParameters /* initializer */,
+                parameterInfo => new ReflectedParameterDescriptor(parameterInfo, this) /* converter */);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/ReflectedAsyncControllerDescriptor.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/ReflectedAsyncControllerDescriptor.cs
new file mode 100644 (file)
index 0000000..e1b6ef0
--- /dev/null
@@ -0,0 +1,69 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Collections.Generic;
+
+    public class ReflectedAsyncControllerDescriptor : ControllerDescriptor {
+
+        private static readonly ActionDescriptor[] _emptyCanonicalActions = new ActionDescriptor[0];
+
+        private readonly Type _controllerType;
+        private readonly AsyncActionMethodSelector _selector;
+
+        public ReflectedAsyncControllerDescriptor(Type controllerType) {
+            if (controllerType == null) {
+                throw new ArgumentNullException("controllerType");
+            }
+
+            _controllerType = controllerType;
+            _selector = new AsyncActionMethodSelector(_controllerType);
+        }
+
+        public sealed override Type ControllerType {
+            get {
+                return _controllerType;
+            }
+        }
+
+        public override ActionDescriptor FindAction(ControllerContext controllerContext, string actionName) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (String.IsNullOrEmpty(actionName)) {
+                throw Error.ParameterCannotBeNullOrEmpty("actionName");
+            }
+
+            ActionDescriptorCreator creator = _selector.FindAction(controllerContext, actionName);
+            if (creator == null) {
+                return null;
+            }
+
+            return creator(actionName, this);
+        }
+
+        public override ActionDescriptor[] GetCanonicalActions() {
+            // everything is looked up dymanically, so there are no 'canonical' actions
+            return _emptyCanonicalActions;
+        }
+
+        public override object[] GetCustomAttributes(bool inherit) {
+            return ControllerType.GetCustomAttributes(inherit);
+        }
+
+        public override object[] GetCustomAttributes(Type attributeType, bool inherit) {
+            return ControllerType.GetCustomAttributes(attributeType, inherit);
+        }
+
+        internal override IEnumerable<FilterAttribute> GetFilterAttributes(bool useCache) {
+            if (useCache && GetType() == typeof(ReflectedAsyncControllerDescriptor)) {
+                // Do not look at cache in types derived from this type because they might incorrectly implement GetCustomAttributes
+                return ReflectedAttributeCache.GetTypeFilterAttributes(ControllerType);
+            }
+            return base.GetFilterAttributes(useCache);
+        }
+
+        public override bool IsDefined(Type attributeType, bool inherit) {
+            return ControllerType.IsDefined(attributeType, inherit);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/SimpleAsyncResult.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/SimpleAsyncResult.cs
new file mode 100644 (file)
index 0000000..fb001d4
--- /dev/null
@@ -0,0 +1,55 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Threading;
+
+    internal sealed class SimpleAsyncResult : IAsyncResult {
+
+        private readonly object _asyncState;
+        private bool _completedSynchronously;
+        private volatile bool _isCompleted;
+
+        public SimpleAsyncResult(object asyncState) {
+            _asyncState = asyncState;
+        }
+
+        public object AsyncState {
+            get {
+                return _asyncState;
+            }
+        }
+
+        // ASP.NET IAsyncResult objects should never expose a WaitHandle due to potential deadlocking
+        public WaitHandle AsyncWaitHandle {
+            get {
+                return null;
+            }
+        }
+
+        public bool CompletedSynchronously {
+            get {
+                return _completedSynchronously;
+            }
+        }
+
+        public bool IsCompleted {
+            get {
+                return _isCompleted;
+            }
+        }
+
+        // Proper order of execution:
+        // 1. Set the CompletedSynchronously property to the correct value
+        // 2. Set the IsCompleted flag
+        // 3. Execute the callback
+        // 4. Signal the WaitHandle (which we don't have)
+        public void MarkCompleted(bool completedSynchronously, AsyncCallback callback) {
+            _completedSynchronously = completedSynchronously;
+            _isCompleted = true;
+
+            if (callback != null) {
+                callback(this);
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/SingleEntryGate.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/SingleEntryGate.cs
new file mode 100644 (file)
index 0000000..3a887c5
--- /dev/null
@@ -0,0 +1,20 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Threading;
+
+    // used to synchronize access to a single-use consumable resource
+    internal sealed class SingleEntryGate {
+
+        private const int NOT_ENTERED = 0;
+        private const int ENTERED = 1;
+
+        private int _status;
+
+        // returns true if this is the first call to TryEnter(), false otherwise
+        public bool TryEnter() {
+            int oldStatus = Interlocked.Exchange(ref _status, ENTERED);
+            return (oldStatus == NOT_ENTERED);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/SynchronizationContextUtil.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/SynchronizationContextUtil.cs
new file mode 100644 (file)
index 0000000..219da92
--- /dev/null
@@ -0,0 +1,47 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Threading;
+
+    internal static class SynchronizationContextUtil {
+
+        public static SynchronizationContext GetSynchronizationContext() {
+            // In a runtime environment, SynchronizationContext.Current will be set to an instance
+            // of AspNetSynchronizationContext. In a unit test environment, the Current property
+            // won't be set and we have to create one on the fly.
+            return SynchronizationContext.Current ?? new SynchronizationContext();
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1031:DoNotCatchGeneralExceptionTypes", Justification = "The exception is swallowed and immediately re-thrown")]
+        public static T Sync<T>(this SynchronizationContext syncContext, Func<T> func) {
+            T theValue = default(T);
+            Exception thrownException = null;
+
+            syncContext.Send(o =>
+            {
+                try {
+                    theValue = func();
+                }
+                catch (Exception ex) {
+                    // by default, the AspNetSynchronizationContext type will swallow thrown exceptions,
+                    // so we need to save and propagate them
+                    thrownException = ex;
+                }
+            }, null);
+
+            if (thrownException != null) {
+                throw Error.SynchronizationContextUtil_ExceptionThrown(thrownException);
+            }
+            return theValue;
+        }
+
+        public static void Sync(this SynchronizationContext syncContext, Action action) {
+            Sync<AsyncVoid>(syncContext, () =>
+            {
+                action();
+                return default(AsyncVoid);
+            });
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/SynchronousOperationException.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/SynchronousOperationException.cs
new file mode 100644 (file)
index 0000000..ac590ed
--- /dev/null
@@ -0,0 +1,27 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Runtime.Serialization;
+
+    // This exception type is thrown by the SynchronizationContextUtil helper class since the AspNetSynchronizationContext
+    // type swallows exceptions. The inner exception contains the data the user cares about.
+
+    [Serializable]
+    public sealed class SynchronousOperationException : HttpException {
+
+        public SynchronousOperationException() {
+        }
+
+        private SynchronousOperationException(SerializationInfo info, StreamingContext context)
+            : base(info, context) {
+        }
+
+        public SynchronousOperationException(string message)
+            : base(message) {
+        }
+
+        public SynchronousOperationException(string message, Exception innerException)
+            : base(message, innerException) {
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/Trigger.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/Trigger.cs
new file mode 100644 (file)
index 0000000..6c5b6e1
--- /dev/null
@@ -0,0 +1,21 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Runtime.Serialization;
+
+    // Provides a trigger for the TriggerListener class.
+
+    internal sealed class Trigger {
+
+        private readonly Action _fireAction;
+
+        // Constructor should only be called by TriggerListener.
+        internal Trigger(Action fireAction) {
+            _fireAction = fireAction;
+        }
+
+        public void Fire() {
+            _fireAction();
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Async/TriggerListener.cs b/mcs/class/System.Web.Mvc3/Mvc/Async/TriggerListener.cs
new file mode 100644 (file)
index 0000000..9f1c624
--- /dev/null
@@ -0,0 +1,56 @@
+namespace System.Web.Mvc.Async {
+    using System;
+    using System.Threading;
+
+    // This class is used to wait for triggers and a continuation. When the continuation has been provded
+    // and all triggers have been fired, the continuation is called. Similar to WaitHandle.WaitAll().
+    // New instances of this type are initially in the inactive state; activation is enabled by a call
+    // to Activate().
+
+    // This class is thread-safe.
+
+    internal sealed class TriggerListener {
+
+        private readonly Trigger _activateTrigger;
+        private volatile Action _continuation;
+        private readonly SingleEntryGate _continuationFiredGate = new SingleEntryGate();
+        private int _outstandingTriggers;
+        private readonly Trigger _setContinuationTrigger;
+
+        public TriggerListener() {
+            _activateTrigger = CreateTrigger();
+            _setContinuationTrigger = CreateTrigger();
+        }
+
+        public void Activate() {
+            _activateTrigger.Fire();
+        }
+
+        public Trigger CreateTrigger() {
+            Interlocked.Increment(ref _outstandingTriggers);
+
+            SingleEntryGate triggerFiredGate = new SingleEntryGate();
+            return new Trigger(() => {
+                if (triggerFiredGate.TryEnter()) {
+                    HandleTriggerFired();
+                }
+            });
+        }
+
+        private void HandleTriggerFired() {
+            if (Interlocked.Decrement(ref _outstandingTriggers) == 0) {
+                if (_continuationFiredGate.TryEnter()) {
+                    _continuation();
+                }
+            }
+        }
+
+        public void SetContinuation(Action continuation) {
+            if (continuation != null) {
+                _continuation = continuation;
+                _setContinuationTrigger.Fire();
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AsyncController.cs b/mcs/class/System.Web.Mvc3/Mvc/AsyncController.cs
new file mode 100644 (file)
index 0000000..00e5a8b
--- /dev/null
@@ -0,0 +1,99 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Web.Mvc.Async;
+    using System.Web.Routing;
+
+    public abstract class AsyncController : Controller, IAsyncManagerContainer, IAsyncController {
+
+        private static readonly object _executeTag = new object();
+        private static readonly object _executeCoreTag = new object();
+
+        private readonly AsyncManager _asyncManager = new AsyncManager();
+
+        public AsyncManager AsyncManager {
+            get {
+                return _asyncManager;
+            }
+        }
+
+        protected virtual IAsyncResult BeginExecute(RequestContext requestContext, AsyncCallback callback, object state) {
+            if (requestContext == null) {
+                throw new ArgumentNullException("requestContext");
+            }
+
+            VerifyExecuteCalledOnce();
+            Initialize(requestContext);
+            return AsyncResultWrapper.Begin(callback, state, BeginExecuteCore, EndExecuteCore, _executeTag);
+        }
+
+        protected virtual IAsyncResult BeginExecuteCore(AsyncCallback callback, object state) {
+            // If code in this method needs to be updated, please also check the ExecuteCore() method
+            // of Controller to see if that code also must be updated.
+
+            PossiblyLoadTempData();
+            try {
+                string actionName = RouteData.GetRequiredString("action");
+                IActionInvoker invoker = ActionInvoker;
+                IAsyncActionInvoker asyncInvoker = invoker as IAsyncActionInvoker;
+                if (asyncInvoker != null) {
+                    // asynchronous invocation
+                    BeginInvokeDelegate beginDelegate = delegate(AsyncCallback asyncCallback, object asyncState) {
+                        return asyncInvoker.BeginInvokeAction(ControllerContext, actionName, asyncCallback, asyncState);
+                    };
+
+                    EndInvokeDelegate endDelegate = delegate(IAsyncResult asyncResult) {
+                        if (!asyncInvoker.EndInvokeAction(asyncResult)) {
+                            HandleUnknownAction(actionName);
+                        }
+                    };
+
+                    return AsyncResultWrapper.Begin(callback, state, beginDelegate, endDelegate, _executeCoreTag);
+                }
+                else {
+                    // synchronous invocation
+                    Action action = () => {
+                        if (!invoker.InvokeAction(ControllerContext, actionName)) {
+                            HandleUnknownAction(actionName);
+                        }
+                    };
+                    return AsyncResultWrapper.BeginSynchronous(callback, state, action, _executeCoreTag);
+                }
+            }
+            catch {
+                PossiblySaveTempData();
+                throw;
+            }
+        }
+
+        protected override IActionInvoker CreateActionInvoker() {
+            return new AsyncControllerActionInvoker();
+        }
+
+        protected virtual void EndExecute(IAsyncResult asyncResult) {
+            AsyncResultWrapper.End(asyncResult, _executeTag);
+        }
+
+        protected virtual void EndExecuteCore(IAsyncResult asyncResult) {
+            // If code in this method needs to be updated, please also check the ExecuteCore() method
+            // of Controller to see if that code also must be updated.
+
+            try {
+                AsyncResultWrapper.End(asyncResult, _executeCoreTag);
+            }
+            finally {
+                PossiblySaveTempData();
+            }
+        }
+
+        #region IAsyncController Members
+        IAsyncResult IAsyncController.BeginExecute(RequestContext requestContext, AsyncCallback callback, object state) {
+            return BeginExecute(requestContext, callback, state);
+        }
+
+        void IAsyncController.EndExecute(IAsyncResult asyncResult) {
+            EndExecute(asyncResult);
+        }
+        #endregion
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AsyncTimeoutAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/AsyncTimeoutAttribute.cs
new file mode 100644 (file)
index 0000000..0ab19ca
--- /dev/null
@@ -0,0 +1,40 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web.Mvc.Async;
+
+    [SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes", Justification = "Unsealed so that subclassed types can set properties in the default constructor.")]
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
+    public class AsyncTimeoutAttribute : ActionFilterAttribute {
+
+        // duration is specified in milliseconds
+        public AsyncTimeoutAttribute(int duration) {
+            if (duration < -1) {
+                throw Error.AsyncCommon_InvalidTimeout("duration");
+            }
+
+            Duration = duration;
+        }
+
+        public int Duration {
+            get;
+            private set;
+        }
+
+        public override void OnActionExecuting(ActionExecutingContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            IAsyncManagerContainer container = filterContext.Controller as IAsyncManagerContainer;
+            if (container == null) {
+                throw Error.AsyncCommon_ControllerMustImplementIAsyncManagerContainer(filterContext.Controller.GetType());
+            }
+
+            container.AsyncManager.Timeout = Duration;
+
+            base.OnActionExecuting(filterContext);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AuthorizationContext.cs b/mcs/class/System.Web.Mvc3/Mvc/AuthorizationContext.cs
new file mode 100644 (file)
index 0000000..8c72e72
--- /dev/null
@@ -0,0 +1,37 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+
+    public class AuthorizationContext : ControllerContext {
+
+        // parameterless constructor used for mocking
+        public AuthorizationContext() {
+        }
+
+        [Obsolete("The recommended alternative is the constructor AuthorizationContext(ControllerContext controllerContext, ActionDescriptor actionDescriptor).")]
+        public AuthorizationContext(ControllerContext controllerContext)
+            : base(controllerContext) {
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
+        public AuthorizationContext(ControllerContext controllerContext, ActionDescriptor actionDescriptor)
+            : base(controllerContext) {
+            if (actionDescriptor == null) {
+                throw new ArgumentNullException("actionDescriptor");
+            }
+
+            ActionDescriptor = actionDescriptor;
+        }
+
+        public virtual ActionDescriptor ActionDescriptor {
+            get;
+            set;
+        }
+
+        public ActionResult Result {
+            get;
+            set;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/AuthorizeAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/AuthorizeAttribute.cs
new file mode 100644 (file)
index 0000000..1a3cbf9
--- /dev/null
@@ -0,0 +1,131 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq;
+    using System.Security.Principal;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+
+    [SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes", Justification = "Unsealed so that subclassed types can set properties in the default constructor or override our behavior.")]
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = true)]
+    public class AuthorizeAttribute : FilterAttribute, IAuthorizationFilter {
+
+        private readonly object _typeId = new object();
+
+        private string _roles;
+        private string[] _rolesSplit = new string[0];
+        private string _users;
+        private string[] _usersSplit = new string[0];
+
+        public string Roles {
+            get {
+                return _roles ?? String.Empty;
+            }
+            set {
+                _roles = value;
+                _rolesSplit = SplitString(value);
+            }
+        }
+
+        public override object TypeId {
+            get {
+                return _typeId;
+            }
+        }
+
+        public string Users {
+            get {
+                return _users ?? String.Empty;
+            }
+            set {
+                _users = value;
+                _usersSplit = SplitString(value);
+            }
+        }
+
+        // This method must be thread-safe since it is called by the thread-safe OnCacheAuthorization() method.
+        protected virtual bool AuthorizeCore(HttpContextBase httpContext) {
+            if (httpContext == null) {
+                throw new ArgumentNullException("httpContext");
+            }
+
+            IPrincipal user = httpContext.User;
+            if (!user.Identity.IsAuthenticated) {
+                return false;
+            }
+
+            if (_usersSplit.Length > 0 && !_usersSplit.Contains(user.Identity.Name, StringComparer.OrdinalIgnoreCase)) {
+                return false;
+            }
+
+            if (_rolesSplit.Length > 0 && !_rolesSplit.Any(user.IsInRole)) {
+                return false;
+            }
+
+            return true;
+        }
+
+        private void CacheValidateHandler(HttpContext context, object data, ref HttpValidationStatus validationStatus) {
+            validationStatus = OnCacheAuthorization(new HttpContextWrapper(context));
+        }
+
+        public virtual void OnAuthorization(AuthorizationContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            if (OutputCacheAttribute.IsChildActionCacheActive(filterContext)) {
+                // If a child action cache block is active, we need to fail immediately, even if authorization
+                // would have succeeded. The reason is that there's no way to hook a callback to rerun
+                // authorization before the fragment is served from the cache, so we can't guarantee that this
+                // filter will be re-run on subsequent requests.
+                throw new InvalidOperationException(MvcResources.AuthorizeAttribute_CannotUseWithinChildActionCache);
+            }
+
+            if (AuthorizeCore(filterContext.HttpContext)) {
+                // ** IMPORTANT **
+                // Since we're performing authorization at the action level, the authorization code runs
+                // after the output caching module. In the worst case this could allow an authorized user
+                // to cause the page to be cached, then an unauthorized user would later be served the
+                // cached page. We work around this by telling proxies not to cache the sensitive page,
+                // then we hook our custom authorization code into the caching mechanism so that we have
+                // the final say on whether a page should be served from the cache.
+
+                HttpCachePolicyBase cachePolicy = filterContext.HttpContext.Response.Cache;
+                cachePolicy.SetProxyMaxAge(new TimeSpan(0));
+                cachePolicy.AddValidationCallback(CacheValidateHandler, null /* data */);
+            }
+            else {
+                HandleUnauthorizedRequest(filterContext);
+            }
+        }
+
+        protected virtual void HandleUnauthorizedRequest(AuthorizationContext filterContext) {
+            // Returns HTTP 401 - see comment in HttpUnauthorizedResult.cs.
+            filterContext.Result = new HttpUnauthorizedResult();
+        }
+
+        // This method must be thread-safe since it is called by the caching module.
+        protected virtual HttpValidationStatus OnCacheAuthorization(HttpContextBase httpContext) {
+            if (httpContext == null) {
+                throw new ArgumentNullException("httpContext");
+            }
+
+            bool isAuthorized = AuthorizeCore(httpContext);
+            return (isAuthorized) ? HttpValidationStatus.Valid : HttpValidationStatus.IgnoreThisRequest;
+        }
+
+        internal static string[] SplitString(string original) {
+            if (String.IsNullOrEmpty(original)) {
+                return new string[0];
+            }
+
+            var split = from piece in original.Split(',')
+                        let trimmed = piece.Trim()
+                        where !String.IsNullOrEmpty(trimmed)
+                        select trimmed;
+            return split.ToArray();
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/BindAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/BindAttribute.cs
new file mode 100644 (file)
index 0000000..2273cb0
--- /dev/null
@@ -0,0 +1,51 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Linq;
+
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Parameter, AllowMultiple = false, Inherited = true)]
+    public sealed class BindAttribute : Attribute {
+
+        private string _exclude;
+        private string[] _excludeSplit = new string[0];
+        private string _include;
+        private string[] _includeSplit = new string[0];
+
+        public string Exclude {
+            get {
+                return _exclude ?? String.Empty;
+            }
+            set {
+                _exclude = value;
+                _excludeSplit = AuthorizeAttribute.SplitString(value);
+            }
+        }
+
+        public string Include {
+            get {
+                return _include ?? String.Empty;
+            }
+            set {
+                _include = value;
+                _includeSplit = AuthorizeAttribute.SplitString(value);
+            }
+        }
+
+        public string Prefix {
+            get;
+            set;
+        }
+
+        internal static bool IsPropertyAllowed(string propertyName, string[] includeProperties, string[] excludeProperties) {
+            // We allow a property to be bound if its both in the include list AND not in the exclude list.
+            // An empty include list implies all properties are allowed.
+            // An empty exclude list implies no properties are disallowed.
+            bool includeProperty = (includeProperties == null) || (includeProperties.Length == 0) || includeProperties.Contains(propertyName, StringComparer.OrdinalIgnoreCase);
+            bool excludeProperty = (excludeProperties != null) && excludeProperties.Contains(propertyName, StringComparer.OrdinalIgnoreCase);
+            return includeProperty && !excludeProperty;
+        }
+
+        public bool IsPropertyAllowed(string propertyName) {
+            return IsPropertyAllowed(propertyName, _includeSplit, _excludeSplit);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/BuildManagerCompiledView.cs b/mcs/class/System.Web.Mvc3/Mvc/BuildManagerCompiledView.cs
new file mode 100644 (file)
index 0000000..a61e6c8
--- /dev/null
@@ -0,0 +1,78 @@
+namespace System.Web.Mvc {
+    using System.Globalization;
+    using System.IO;
+    using System.Web.Mvc.Resources;
+
+    public abstract class BuildManagerCompiledView : IView {
+        internal IViewPageActivator _viewPageActivator;
+        private IBuildManager _buildManager;
+        private ControllerContext _controllerContext;
+
+        protected BuildManagerCompiledView(ControllerContext controllerContext, string viewPath)
+            : this(controllerContext, viewPath, null) {
+        }
+
+        protected BuildManagerCompiledView(ControllerContext controllerContext, string viewPath, IViewPageActivator viewPageActivator) 
+            :this(controllerContext, viewPath, viewPageActivator, null){
+        }
+
+        internal BuildManagerCompiledView(ControllerContext controllerContext, string viewPath, IViewPageActivator viewPageActivator, IDependencyResolver dependencyResolver){
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (String.IsNullOrEmpty(viewPath)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "viewPath");
+            }
+
+            _controllerContext = controllerContext;
+
+            ViewPath = viewPath;
+
+            _viewPageActivator = viewPageActivator ?? new BuildManagerViewEngine.DefaultViewPageActivator(dependencyResolver);
+        }
+
+        internal IBuildManager BuildManager {
+            get {
+                if (_buildManager == null) {
+                    _buildManager = new BuildManagerWrapper();
+                }
+                return _buildManager;
+            }
+            set {
+                _buildManager = value;
+            }
+        }
+
+        public string ViewPath {
+            get;
+            protected set;
+        }
+
+        public void Render(ViewContext viewContext, TextWriter writer) {
+            if (viewContext == null) {
+                throw new ArgumentNullException("viewContext");
+            }
+
+            object instance = null;
+
+            Type type = BuildManager.GetCompiledType(ViewPath);
+            if (type != null) {
+                instance = _viewPageActivator.Create(_controllerContext, type);
+            }
+
+            if (instance == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.CshtmlView_ViewCouldNotBeCreated,
+                        ViewPath
+                    )
+                );
+            }
+
+            RenderView(viewContext, writer, instance);
+        }
+
+        protected abstract void RenderView(ViewContext viewContext, TextWriter writer, object instance);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/BuildManagerViewEngine.cs b/mcs/class/System.Web.Mvc3/Mvc/BuildManagerViewEngine.cs
new file mode 100644 (file)
index 0000000..eb9b8c9
--- /dev/null
@@ -0,0 +1,76 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public abstract class BuildManagerViewEngine : VirtualPathProviderViewEngine {
+        private IBuildManager _buildManager;
+        private IViewPageActivator _viewPageActivator;
+        private IResolver<IViewPageActivator> _activatorResolver;
+
+        protected BuildManagerViewEngine()
+            : this(null, null, null) {
+        }
+
+        protected BuildManagerViewEngine(IViewPageActivator viewPageActivator)
+            : this(viewPageActivator, null, null) {
+        }
+
+        internal BuildManagerViewEngine(IViewPageActivator viewPageActivator, IResolver<IViewPageActivator> activatorResolver, IDependencyResolver dependencyResolver) {
+            if (viewPageActivator != null) {
+                _viewPageActivator = viewPageActivator;
+            }
+            else {
+                _activatorResolver = activatorResolver ?? new SingleServiceResolver<IViewPageActivator>(
+                    () => null,
+                    new DefaultViewPageActivator(dependencyResolver),
+                    "BuildManagerViewEngine constructor"
+                );
+            }
+        }
+
+        internal IBuildManager BuildManager {
+            get {
+                if (_buildManager == null)
+                    _buildManager = new BuildManagerWrapper();
+                return _buildManager;
+            }
+            set {
+                _buildManager = value;
+            }
+        }
+
+        protected override bool FileExists(ControllerContext controllerContext, string virtualPath) {
+            return BuildManager.FileExists(virtualPath);
+        }
+
+        protected IViewPageActivator ViewPageActivator {
+            get {
+                if (_viewPageActivator != null) {
+                    return _viewPageActivator;
+                }
+                _viewPageActivator = _activatorResolver.Current;
+                return _viewPageActivator;
+            }
+        }
+
+        internal class DefaultViewPageActivator : IViewPageActivator {
+            Func<IDependencyResolver> _resolverThunk;
+
+            public DefaultViewPageActivator()
+                : this(null) {
+            }
+
+            public DefaultViewPageActivator(IDependencyResolver resolver) {
+                if (resolver == null) {
+                    _resolverThunk = () => DependencyResolver.Current;
+                }
+                else {
+                    _resolverThunk = () => resolver;
+                }
+            }
+
+            public object Create(ControllerContext controllerContext, Type type) {
+                return _resolverThunk().GetService(type) ?? Activator.CreateInstance(type);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/BuildManagerWrapper.cs b/mcs/class/System.Web.Mvc3/Mvc/BuildManagerWrapper.cs
new file mode 100644 (file)
index 0000000..c76621a
--- /dev/null
@@ -0,0 +1,27 @@
+namespace System.Web.Mvc {
+    using System.Collections;
+    using System.IO;
+    using System.Web.Compilation;
+
+    internal sealed class BuildManagerWrapper : IBuildManager {
+        bool IBuildManager.FileExists(string virtualPath) {
+            return BuildManager.GetObjectFactory(virtualPath, false) != null;
+        }
+
+        Type IBuildManager.GetCompiledType(string virtualPath) {
+            return BuildManager.GetCompiledType(virtualPath);
+        }
+
+        ICollection IBuildManager.GetReferencedAssemblies() {
+            return BuildManager.GetReferencedAssemblies();
+        }
+
+        Stream IBuildManager.ReadCachedFile(string fileName) {
+            return BuildManager.ReadCachedFile(fileName);
+        }
+
+        Stream IBuildManager.CreateCachedFile(string fileName) {
+            return BuildManager.CreateCachedFile(fileName);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ByteArrayModelBinder.cs b/mcs/class/System.Web.Mvc3/Mvc/ByteArrayModelBinder.cs
new file mode 100644 (file)
index 0000000..e9ea70a
--- /dev/null
@@ -0,0 +1,31 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public class ByteArrayModelBinder : IModelBinder {
+        public virtual object BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            if (bindingContext == null) {
+                throw new ArgumentNullException("bindingContext");
+            }
+
+            ValueProviderResult valueResult = bindingContext.ValueProvider.GetValue(bindingContext.ModelName);
+
+            // case 1: there was no <input ... /> element containing this data
+            if (valueResult == null) {
+                return null;
+            }
+
+            string value = valueResult.AttemptedValue;
+
+            // case 2: there was an <input ... /> element but it was left blank
+            if (String.IsNullOrEmpty(value)) {
+                return null;
+            }
+
+            // Future proofing. If the byte array is actually an instance of System.Data.Linq.Binary
+            // then we need to remove these quotes put in place by the ToString() method.
+            string realValue = value.Replace("\"", String.Empty);
+            return Convert.FromBase64String(realValue);
+        }
+    }
+
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ChildActionOnlyAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/ChildActionOnlyAttribute.cs
new file mode 100644 (file)
index 0000000..509004b
--- /dev/null
@@ -0,0 +1,18 @@
+namespace System.Web.Mvc {
+    using System;
+
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public sealed class ChildActionOnlyAttribute : FilterAttribute, IAuthorizationFilter {
+
+        public void OnAuthorization(AuthorizationContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            if (!filterContext.IsChildAction) {
+                throw Error.ChildActionOnlyAttribute_MustBeInChildRequest(filterContext.ActionDescriptor);
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ChildActionValueProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/ChildActionValueProvider.cs
new file mode 100644 (file)
index 0000000..fe8bb95
--- /dev/null
@@ -0,0 +1,35 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Globalization;
+
+    public sealed class ChildActionValueProvider : DictionaryValueProvider<object> {
+
+        public ChildActionValueProvider(ControllerContext controllerContext)
+            : base(controllerContext.RouteData.Values, CultureInfo.InvariantCulture) {
+        }
+
+        private static string _childActionValuesKey = Guid.NewGuid().ToString();
+
+        internal static string ChildActionValuesKey {
+            get {
+                return _childActionValuesKey;
+            }
+        }
+
+        public override ValueProviderResult GetValue(string key) {
+            if (key == null) {
+                throw new ArgumentNullException("key");
+            }
+
+            ValueProviderResult explicitValues = base.GetValue(ChildActionValuesKey);
+            if (explicitValues != null) {
+                DictionaryValueProvider<object> rawExplicitValues = explicitValues.RawValue as DictionaryValueProvider<object>;
+                if (rawExplicitValues != null) {
+                    return rawExplicitValues.GetValue(key);
+                }
+            }
+
+            return null;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ChildActionValueProviderFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/ChildActionValueProviderFactory.cs
new file mode 100644 (file)
index 0000000..6a56f2f
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public sealed class ChildActionValueProviderFactory: ValueProviderFactory {
+
+        public override IValueProvider GetValueProvider(ControllerContext controllerContext) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            return new ChildActionValueProvider(controllerContext);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ClientDataTypeModelValidatorProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/ClientDataTypeModelValidatorProvider.cs
new file mode 100644 (file)
index 0000000..1a40dfe
--- /dev/null
@@ -0,0 +1,67 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.Linq;
+    using System.Web.Mvc.Resources;
+
+    public class ClientDataTypeModelValidatorProvider : ModelValidatorProvider {
+
+        private static readonly HashSet<Type> _numericTypes = new HashSet<Type>(new Type[] {
+            typeof(byte), typeof(sbyte),
+            typeof(short), typeof(ushort),
+            typeof(int), typeof(uint),
+            typeof(long), typeof(ulong),
+            typeof(float), typeof(double), typeof(decimal)
+        });
+
+        public override IEnumerable<ModelValidator> GetValidators(ModelMetadata metadata, ControllerContext context) {
+            if (metadata == null) {
+                throw new ArgumentNullException("metadata");
+            }
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+
+            return GetValidatorsImpl(metadata, context);
+        }
+
+        private static IEnumerable<ModelValidator> GetValidatorsImpl(ModelMetadata metadata, ControllerContext context) {
+            Type type = metadata.ModelType;
+            if (IsNumericType(type)) {
+                yield return new NumericModelValidator(metadata, context);
+            }
+        }
+
+        private static bool IsNumericType(Type type) {
+            Type underlyingType = Nullable.GetUnderlyingType(type); // strip off the Nullable<>
+            return _numericTypes.Contains(underlyingType ?? type);
+        }
+
+        internal sealed class NumericModelValidator : ModelValidator {
+            public NumericModelValidator(ModelMetadata metadata, ControllerContext controllerContext)
+                : base(metadata, controllerContext) {
+            }
+
+            public override IEnumerable<ModelClientValidationRule> GetClientValidationRules() {
+                ModelClientValidationRule rule = new ModelClientValidationRule() {
+                    ValidationType = "number",
+                    ErrorMessage = MakeErrorString(Metadata.GetDisplayName())
+                };
+
+                return new ModelClientValidationRule[] { rule };
+            }
+
+            private static string MakeErrorString(string displayName) {
+                // use CurrentCulture since this message is intended for the site visitor
+                return String.Format(CultureInfo.CurrentCulture, MvcResources.ClientDataTypeModelValidatorProvider_FieldMustBeNumeric, displayName);
+            }
+
+            public override IEnumerable<ModelValidationResult> Validate(object container) {
+                // this is not a server-side validator
+                return Enumerable.Empty<ModelValidationResult>();
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/CompareAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/CompareAttribute.cs
new file mode 100644 (file)
index 0000000..ae5f63b
--- /dev/null
@@ -0,0 +1,52 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel.DataAnnotations;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    [AttributeUsage(AttributeTargets.Property)]
+    [SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes", Justification = "This attribute is designed to be a base class for other attributes.")]
+    public class CompareAttribute : ValidationAttribute, IClientValidatable {
+
+        public CompareAttribute(string otherProperty)
+            : base(MvcResources.CompareAttribute_MustMatch) {
+            if (otherProperty == null) {
+                throw new ArgumentNullException("otherProperty");
+            }
+            OtherProperty = otherProperty;
+        }
+
+        public string OtherProperty { get; private set; }
+
+        public override string FormatErrorMessage(string name) {
+            return String.Format(CultureInfo.CurrentCulture, ErrorMessageString, name, OtherProperty);
+        }
+
+        protected override ValidationResult IsValid(object value, ValidationContext validationContext) {
+            PropertyInfo otherPropertyInfo = validationContext.ObjectType.GetProperty(OtherProperty);
+            if (otherPropertyInfo == null) {
+                return new ValidationResult(String.Format(CultureInfo.CurrentCulture, MvcResources.CompareAttribute_UnknownProperty, OtherProperty));
+            }
+
+            object otherPropertyValue = otherPropertyInfo.GetValue(validationContext.ObjectInstance, null);
+            if (!Equals(value, otherPropertyValue)) {
+                return new ValidationResult(FormatErrorMessage(validationContext.DisplayName));
+            }
+            return null;
+        }
+
+        public static string FormatPropertyForClientValidation(string property) {
+            if (property == null) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "property");
+            }
+            return "*." + property;
+        }
+
+        public IEnumerable<ModelClientValidationRule> GetClientValidationRules(ModelMetadata metadata, ControllerContext context) {
+            yield return new ModelClientValidationEqualToRule(FormatErrorMessage(metadata.GetDisplayName()), FormatPropertyForClientValidation(OtherProperty));
+        }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ContentResult.cs b/mcs/class/System.Web.Mvc3/Mvc/ContentResult.cs
new file mode 100644 (file)
index 0000000..7cdce03
--- /dev/null
@@ -0,0 +1,41 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Text;
+    using System.Web;
+
+    public class ContentResult : ActionResult {
+
+        public string Content {
+            get;
+            set;
+        }
+
+        public Encoding ContentEncoding {
+            get;
+            set;
+        }
+
+        public string ContentType {
+            get;
+            set;
+        }
+
+        public override void ExecuteResult(ControllerContext context) {
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+
+            HttpResponseBase response = context.HttpContext.Response;
+
+            if (!String.IsNullOrEmpty(ContentType)) {
+                response.ContentType = ContentType;
+            }
+            if (ContentEncoding != null) {
+                response.ContentEncoding = ContentEncoding;
+            }
+            if (Content != null) {
+                response.Write(Content);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Controller.cs b/mcs/class/System.Web.Mvc3/Mvc/Controller.cs
new file mode 100644 (file)
index 0000000..3370cae
--- /dev/null
@@ -0,0 +1,645 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.IO;
+    using System.Security.Principal;
+    using System.Text;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    public abstract class Controller : ControllerBase, IActionFilter, IAuthorizationFilter, IDisposable, IExceptionFilter, IResultFilter {
+
+        private IActionInvoker _actionInvoker;
+        private ModelBinderDictionary _binders;
+        private RouteCollection _routeCollection;
+        private ITempDataProvider _tempDataProvider;
+
+        public IActionInvoker ActionInvoker {
+            get {
+                if (_actionInvoker == null) {
+                    _actionInvoker = CreateActionInvoker();
+                }
+                return _actionInvoker;
+            }
+            set {
+                _actionInvoker = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "Property is settable so that the dictionary can be provided for unit testing purposes.")]
+        protected internal ModelBinderDictionary Binders {
+            get {
+                if (_binders == null) {
+                    _binders = ModelBinders.Binders;
+                }
+                return _binders;
+            }
+            set {
+                _binders = value;
+            }
+        }
+
+        public HttpContextBase HttpContext {
+            get {
+                return ControllerContext == null ? null : ControllerContext.HttpContext;
+            }
+        }
+
+        public ModelStateDictionary ModelState {
+            get {
+                return ViewData.ModelState;
+            }
+        }
+
+        public HttpRequestBase Request {
+            get {
+                return HttpContext == null ? null : HttpContext.Request;
+            }
+        }
+
+        public HttpResponseBase Response {
+            get {
+                return HttpContext == null ? null : HttpContext.Response;
+            }
+        }
+
+        internal RouteCollection RouteCollection {
+            get {
+                if (_routeCollection == null) {
+                    _routeCollection = RouteTable.Routes;
+                }
+                return _routeCollection;
+            }
+            set {
+                _routeCollection = value;
+            }
+        }
+
+        public RouteData RouteData {
+            get {
+                return ControllerContext == null ? null : ControllerContext.RouteData;
+            }
+        }
+
+        public HttpServerUtilityBase Server {
+            get {
+                return HttpContext == null ? null : HttpContext.Server;
+            }
+        }
+
+        public HttpSessionStateBase Session {
+            get {
+                return HttpContext == null ? null : HttpContext.Session;
+            }
+        }
+
+        public ITempDataProvider TempDataProvider {
+            get {
+                if (_tempDataProvider == null) {
+                    _tempDataProvider = CreateTempDataProvider();
+                }
+                return _tempDataProvider;
+            }
+            set {
+                _tempDataProvider = value;
+            }
+        }
+
+        public UrlHelper Url {
+            get;
+            set;
+        }
+
+        public IPrincipal User {
+            get {
+                return HttpContext == null ? null : HttpContext.User;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1719:ParameterNamesShouldNotMatchMemberNames", MessageId = "0#", Justification = "'Content' refers to ContentResult type; 'content' refers to ContentResult.Content property.")]
+        protected internal ContentResult Content(string content) {
+            return Content(content, null /* contentType */);
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1719:ParameterNamesShouldNotMatchMemberNames", MessageId = "0#", Justification = "'Content' refers to ContentResult type; 'content' refers to ContentResult.Content property.")]
+        protected internal ContentResult Content(string content, string contentType) {
+            return Content(content, contentType, null /* contentEncoding */);
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1719:ParameterNamesShouldNotMatchMemberNames", MessageId = "0#", Justification = "'Content' refers to ContentResult type; 'content' refers to ContentResult.Content property.")]
+        protected internal virtual ContentResult Content(string content, string contentType, Encoding contentEncoding) {
+            return new ContentResult {
+                Content = content,
+                ContentType = contentType,
+                ContentEncoding = contentEncoding
+            };
+        }
+
+        protected virtual IActionInvoker CreateActionInvoker() {
+            return new ControllerActionInvoker();
+        }
+
+        protected virtual ITempDataProvider CreateTempDataProvider() {
+            return new SessionStateTempDataProvider();
+        }
+
+        // The default invoker will never match methods defined on the Controller type, so
+        // the Dispose() method is not web-callable.  However, in general, since implicitly-
+        // implemented interface methods are public, they are web-callable unless decorated with
+        // [NonAction].
+        public void Dispose() {
+            Dispose(true /* disposing */);
+            GC.SuppressFinalize(this);
+        }
+
+        protected virtual void Dispose(bool disposing) {
+        }
+
+        protected override void ExecuteCore() {
+            // If code in this method needs to be updated, please also check the BeginExecuteCore() and
+            // EndExecuteCore() methods of AsyncController to see if that code also must be updated.
+
+            PossiblyLoadTempData();
+            try {
+                string actionName = RouteData.GetRequiredString("action");
+                if (!ActionInvoker.InvokeAction(ControllerContext, actionName)) {
+                    HandleUnknownAction(actionName);
+                }
+            }
+            finally {
+                PossiblySaveTempData();
+            }
+        }
+
+        protected internal FileContentResult File(byte[] fileContents, string contentType) {
+            return File(fileContents, contentType, null /* fileDownloadName */);
+        }
+
+        protected internal virtual FileContentResult File(byte[] fileContents, string contentType, string fileDownloadName) {
+            return new FileContentResult(fileContents, contentType) { FileDownloadName = fileDownloadName };
+        }
+
+        protected internal FileStreamResult File(Stream fileStream, string contentType) {
+            return File(fileStream, contentType, null /* fileDownloadName */);
+        }
+
+        protected internal virtual FileStreamResult File(Stream fileStream, string contentType, string fileDownloadName) {
+            return new FileStreamResult(fileStream, contentType) { FileDownloadName = fileDownloadName };
+        }
+
+        protected internal FilePathResult File(string fileName, string contentType) {
+            return File(fileName, contentType, null /* fileDownloadName */);
+        }
+
+        protected internal virtual FilePathResult File(string fileName, string contentType, string fileDownloadName) {
+            return new FilePathResult(fileName, contentType) { FileDownloadName = fileDownloadName };
+        }
+
+        protected virtual void HandleUnknownAction(string actionName) {
+            throw new HttpException(404, String.Format(CultureInfo.CurrentCulture,
+                MvcResources.Controller_UnknownAction, actionName, GetType().FullName));
+        }
+
+        protected internal HttpNotFoundResult HttpNotFound() {
+            return HttpNotFound(null);
+        }
+
+        protected internal virtual HttpNotFoundResult HttpNotFound(string statusDescription) {
+            return new HttpNotFoundResult(statusDescription);
+        }
+
+        protected internal virtual JavaScriptResult JavaScript(string script) {
+            return new JavaScriptResult { Script = script };
+        }
+
+        protected internal JsonResult Json(object data) {
+            return Json(data, null /* contentType */, null /* contentEncoding */, JsonRequestBehavior.DenyGet);
+        }
+
+        protected internal JsonResult Json(object data, string contentType) {
+            return Json(data, contentType, null /* contentEncoding */, JsonRequestBehavior.DenyGet);
+        }
+
+        protected internal virtual JsonResult Json(object data, string contentType, Encoding contentEncoding) {
+            return Json(data, contentType, contentEncoding, JsonRequestBehavior.DenyGet);
+        }
+
+        protected internal JsonResult Json(object data, JsonRequestBehavior behavior) {
+            return Json(data, null /* contentType */, null /* contentEncoding */, behavior);
+        }
+
+        protected internal JsonResult Json(object data, string contentType, JsonRequestBehavior behavior) {
+            return Json(data, contentType, null /* contentEncoding */, behavior);
+        }
+
+        protected internal virtual JsonResult Json(object data, string contentType, Encoding contentEncoding, JsonRequestBehavior behavior) {
+            return new JsonResult {
+                Data = data,
+                ContentType = contentType,
+                ContentEncoding = contentEncoding,
+                JsonRequestBehavior = behavior
+            };
+        }
+
+        protected override void Initialize(RequestContext requestContext) {
+            base.Initialize(requestContext);
+            Url = new UrlHelper(requestContext);
+        }
+
+        protected virtual void OnActionExecuting(ActionExecutingContext filterContext) {
+        }
+
+        protected virtual void OnActionExecuted(ActionExecutedContext filterContext) {
+        }
+
+        protected virtual void OnAuthorization(AuthorizationContext filterContext) {
+        }
+
+        protected virtual void OnException(ExceptionContext filterContext) {
+        }
+
+        protected virtual void OnResultExecuted(ResultExecutedContext filterContext) {
+        }
+
+        protected virtual void OnResultExecuting(ResultExecutingContext filterContext) {
+        }
+
+        protected internal PartialViewResult PartialView() {
+            return PartialView(null /* viewName */, null /* model */);
+        }
+
+        protected internal PartialViewResult PartialView(object model) {
+            return PartialView(null /* viewName */, model);
+        }
+
+        protected internal PartialViewResult PartialView(string viewName) {
+            return PartialView(viewName, null /* model */);
+        }
+
+        protected internal virtual PartialViewResult PartialView(string viewName, object model) {
+            if (model != null) {
+                ViewData.Model = model;
+            }
+
+            return new PartialViewResult {
+                ViewName = viewName,
+                ViewData = ViewData,
+                TempData = TempData
+            };
+        }
+
+        internal void PossiblyLoadTempData() {
+            if (!ControllerContext.IsChildAction) {
+                TempData.Load(ControllerContext, TempDataProvider);
+            }
+        }
+
+        internal void PossiblySaveTempData() {
+            if (!ControllerContext.IsChildAction) {
+                TempData.Save(ControllerContext, TempDataProvider);
+            }
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "0#", Justification = "Response.Redirect() takes its URI as a string parameter.")]
+        protected internal virtual RedirectResult Redirect(string url) {
+            if (String.IsNullOrEmpty(url)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "url");
+            }
+
+            return new RedirectResult(url);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "0#", Justification = "Response.RedirectPermanent() takes its URI as a string parameter.")]
+        protected internal virtual RedirectResult RedirectPermanent(string url) {
+            if (String.IsNullOrEmpty(url)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "url");
+            }
+
+            return new RedirectResult(url, permanent: true);
+        }
+
+        protected internal RedirectToRouteResult RedirectToAction(string actionName) {
+            return RedirectToAction(actionName, (RouteValueDictionary)null);
+        }
+
+        protected internal RedirectToRouteResult RedirectToAction(string actionName, object routeValues) {
+            return RedirectToAction(actionName, new RouteValueDictionary(routeValues));
+        }
+
+        protected internal RedirectToRouteResult RedirectToAction(string actionName, RouteValueDictionary routeValues) {
+            return RedirectToAction(actionName, null /* controllerName */, routeValues);
+        }
+
+        protected internal RedirectToRouteResult RedirectToAction(string actionName, string controllerName) {
+            return RedirectToAction(actionName, controllerName, (RouteValueDictionary)null);
+        }
+
+        protected internal RedirectToRouteResult RedirectToAction(string actionName, string controllerName, object routeValues) {
+            return RedirectToAction(actionName, controllerName, new RouteValueDictionary(routeValues));
+        }
+
+        protected internal virtual RedirectToRouteResult RedirectToAction(string actionName, string controllerName, RouteValueDictionary routeValues) {
+            RouteValueDictionary mergedRouteValues;
+
+            if (RouteData == null) {
+                mergedRouteValues = RouteValuesHelpers.MergeRouteValues(actionName, controllerName, null, routeValues, includeImplicitMvcValues: true);
+            }
+            else {
+                mergedRouteValues = RouteValuesHelpers.MergeRouteValues(actionName, controllerName, RouteData.Values, routeValues, includeImplicitMvcValues: true);
+            }
+
+            return new RedirectToRouteResult(mergedRouteValues);
+        }
+
+        protected internal RedirectToRouteResult RedirectToActionPermanent(string actionName) {
+            return RedirectToActionPermanent(actionName, (RouteValueDictionary)null);
+        }
+
+        protected internal RedirectToRouteResult RedirectToActionPermanent(string actionName, object routeValues) {
+            return RedirectToActionPermanent(actionName, new RouteValueDictionary(routeValues));
+        }
+
+        protected internal RedirectToRouteResult RedirectToActionPermanent(string actionName, RouteValueDictionary routeValues) {
+            return RedirectToActionPermanent(actionName, null /* controllerName */, routeValues);
+        }
+
+        protected internal RedirectToRouteResult RedirectToActionPermanent(string actionName, string controllerName) {
+            return RedirectToActionPermanent(actionName, controllerName, (RouteValueDictionary)null);
+        }
+
+        protected internal RedirectToRouteResult RedirectToActionPermanent(string actionName, string controllerName, object routeValues) {
+            return RedirectToActionPermanent(actionName, controllerName, new RouteValueDictionary(routeValues));
+        }
+
+        protected internal virtual RedirectToRouteResult RedirectToActionPermanent(string actionName, string controllerName, RouteValueDictionary routeValues) {
+            RouteValueDictionary implicitRouteValues = (RouteData != null) ? RouteData.Values : null;
+
+            RouteValueDictionary mergedRouteValues =
+                RouteValuesHelpers.MergeRouteValues(actionName, controllerName, implicitRouteValues, routeValues, includeImplicitMvcValues: true);
+
+            return new RedirectToRouteResult(null, mergedRouteValues, permanent: true);
+        }
+
+        protected internal RedirectToRouteResult RedirectToRoute(object routeValues) {
+            return RedirectToRoute(new RouteValueDictionary(routeValues));
+        }
+
+        protected internal RedirectToRouteResult RedirectToRoute(RouteValueDictionary routeValues) {
+            return RedirectToRoute(null /* routeName */, routeValues);
+        }
+
+        protected internal RedirectToRouteResult RedirectToRoute(string routeName) {
+            return RedirectToRoute(routeName, (RouteValueDictionary)null);
+        }
+
+        protected internal RedirectToRouteResult RedirectToRoute(string routeName, object routeValues) {
+            return RedirectToRoute(routeName, new RouteValueDictionary(routeValues));
+        }
+
+        protected internal virtual RedirectToRouteResult RedirectToRoute(string routeName, RouteValueDictionary routeValues) {
+            return new RedirectToRouteResult(routeName, RouteValuesHelpers.GetRouteValues(routeValues));
+        }
+
+        protected internal RedirectToRouteResult RedirectToRoutePermanent(object routeValues) {
+            return RedirectToRoutePermanent(new RouteValueDictionary(routeValues));
+        }
+
+        protected internal RedirectToRouteResult RedirectToRoutePermanent(RouteValueDictionary routeValues) {
+            return RedirectToRoutePermanent(null /* routeName */, routeValues);
+        }
+
+        protected internal RedirectToRouteResult RedirectToRoutePermanent(string routeName) {
+            return RedirectToRoutePermanent(routeName, (RouteValueDictionary)null);
+        }
+
+        protected internal RedirectToRouteResult RedirectToRoutePermanent(string routeName, object routeValues) {
+            return RedirectToRoutePermanent(routeName, new RouteValueDictionary(routeValues));
+        }
+
+        protected internal virtual RedirectToRouteResult RedirectToRoutePermanent(string routeName, RouteValueDictionary routeValues) {
+            return new RedirectToRouteResult(routeName, RouteValuesHelpers.GetRouteValues(routeValues), permanent: true);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model) where TModel : class {
+            return TryUpdateModel(model, null, null, null, ValueProvider);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model, string prefix) where TModel : class {
+            return TryUpdateModel(model, prefix, null, null, ValueProvider);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model, string[] includeProperties) where TModel : class {
+            return TryUpdateModel(model, null, includeProperties, null, ValueProvider);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model, string prefix, string[] includeProperties) where TModel : class {
+            return TryUpdateModel(model, prefix, includeProperties, null, ValueProvider);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model, string prefix, string[] includeProperties, string[] excludeProperties) where TModel : class {
+            return TryUpdateModel(model, prefix, includeProperties, excludeProperties, ValueProvider);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model, IValueProvider valueProvider) where TModel : class {
+            return TryUpdateModel(model, null, null, null, valueProvider);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model, string prefix, IValueProvider valueProvider) where TModel : class {
+            return TryUpdateModel(model, prefix, null, null, valueProvider);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model, string[] includeProperties, IValueProvider valueProvider) where TModel : class {
+            return TryUpdateModel(model, null, includeProperties, null, valueProvider);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model, string prefix, string[] includeProperties, IValueProvider valueProvider) where TModel : class {
+            return TryUpdateModel(model, prefix, includeProperties, null, valueProvider);
+        }
+
+        protected internal bool TryUpdateModel<TModel>(TModel model, string prefix, string[] includeProperties, string[] excludeProperties, IValueProvider valueProvider) where TModel : class {
+            if (model == null) {
+                throw new ArgumentNullException("model");
+            }
+            if (valueProvider == null) {
+                throw new ArgumentNullException("valueProvider");
+            }
+
+            Predicate<string> propertyFilter = propertyName => BindAttribute.IsPropertyAllowed(propertyName, includeProperties, excludeProperties);
+            IModelBinder binder = Binders.GetBinder(typeof(TModel));
+
+            ModelBindingContext bindingContext = new ModelBindingContext() {
+                ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(() => model, typeof(TModel)),
+                ModelName = prefix,
+                ModelState = ModelState,
+                PropertyFilter = propertyFilter,
+                ValueProvider = valueProvider
+            };
+            binder.BindModel(ControllerContext, bindingContext);
+            return ModelState.IsValid;
+        }
+
+        protected internal bool TryValidateModel(object model) {
+            return TryValidateModel(model, null /* prefix */);
+        }
+
+        protected internal bool TryValidateModel(object model, string prefix) {
+            if (model == null) {
+                throw new ArgumentNullException("model");
+            }
+
+            ModelMetadata metadata = ModelMetadataProviders.Current.GetMetadataForType(() => model, model.GetType());
+
+            foreach (ModelValidationResult validationResult in ModelValidator.GetModelValidator(metadata, ControllerContext).Validate(null)) {
+                ModelState.AddModelError(DefaultModelBinder.CreateSubPropertyName(prefix, validationResult.MemberName), validationResult.Message);
+            }
+
+            return ModelState.IsValid;
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model) where TModel : class {
+            UpdateModel(model, null, null, null, ValueProvider);
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model, string prefix) where TModel : class {
+            UpdateModel(model, prefix, null, null, ValueProvider);
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model, string[] includeProperties) where TModel : class {
+            UpdateModel(model, null, includeProperties, null, ValueProvider);
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model, string prefix, string[] includeProperties) where TModel : class {
+            UpdateModel(model, prefix, includeProperties, null, ValueProvider);
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model, string prefix, string[] includeProperties, string[] excludeProperties) where TModel : class {
+            UpdateModel(model, prefix, includeProperties, excludeProperties, ValueProvider);
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model, IValueProvider valueProvider) where TModel : class {
+            UpdateModel(model, null, null, null, valueProvider);
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model, string prefix, IValueProvider valueProvider) where TModel : class {
+            UpdateModel(model, prefix, null, null, valueProvider);
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model, string[] includeProperties, IValueProvider valueProvider) where TModel : class {
+            UpdateModel(model, null, includeProperties, null, valueProvider);
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model, string prefix, string[] includeProperties, IValueProvider valueProvider) where TModel : class {
+            UpdateModel(model, prefix, includeProperties, null, valueProvider);
+        }
+
+        protected internal void UpdateModel<TModel>(TModel model, string prefix, string[] includeProperties, string[] excludeProperties, IValueProvider valueProvider) where TModel : class {
+            bool success = TryUpdateModel(model, prefix, includeProperties, excludeProperties, valueProvider);
+            if (!success) {
+                string message = String.Format(CultureInfo.CurrentCulture, MvcResources.Controller_UpdateModel_UpdateUnsuccessful,
+                    typeof(TModel).FullName);
+                throw new InvalidOperationException(message);
+            }
+        }
+
+        protected internal void ValidateModel(object model) {
+            ValidateModel(model, null /* prefix */);
+        }
+
+        protected internal void ValidateModel(object model, string prefix) {
+            if (!TryValidateModel(model, prefix)) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.Controller_Validate_ValidationFailed,
+                        model.GetType().FullName
+                    )
+                );
+            }
+        }
+
+        protected internal ViewResult View() {
+            return View(null /* viewName */, null /* masterName */, null /* model */);
+        }
+
+        protected internal ViewResult View(object model) {
+            return View(null /* viewName */, null /* masterName */, model);
+        }
+
+        protected internal ViewResult View(string viewName) {
+            return View(viewName, null /* masterName */, null /* model */);
+        }
+
+        protected internal ViewResult View(string viewName, string masterName) {
+            return View(viewName, masterName, null /* model */);
+        }
+
+        protected internal ViewResult View(string viewName, object model) {
+            return View(viewName, null /* masterName */, model);
+        }
+
+        protected internal virtual ViewResult View(string viewName, string masterName, object model) {
+            if (model != null) {
+                ViewData.Model = model;
+            }
+
+            return new ViewResult {
+                ViewName = viewName,
+                MasterName = masterName,
+                ViewData = ViewData,
+                TempData = TempData
+            };
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1719:ParameterNamesShouldNotMatchMemberNames", MessageId = "0#", Justification = "The method name 'View' is a convenient shorthand for 'CreateViewResult'.")]
+        protected internal ViewResult View(IView view) {
+            return View(view, null /* model */);
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1719:ParameterNamesShouldNotMatchMemberNames", MessageId = "0#", Justification = "The method name 'View' is a convenient shorthand for 'CreateViewResult'.")]
+        protected internal virtual ViewResult View(IView view, object model) {
+            if (model != null) {
+                ViewData.Model = model;
+            }
+
+            return new ViewResult {
+                View = view,
+                ViewData = ViewData,
+                TempData = TempData
+            };
+        }
+
+        #region IActionFilter Members
+        void IActionFilter.OnActionExecuting(ActionExecutingContext filterContext) {
+            OnActionExecuting(filterContext);
+        }
+
+        void IActionFilter.OnActionExecuted(ActionExecutedContext filterContext) {
+            OnActionExecuted(filterContext);
+        }
+        #endregion
+
+        #region IAuthorizationFilter Members
+        void IAuthorizationFilter.OnAuthorization(AuthorizationContext filterContext) {
+            OnAuthorization(filterContext);
+        }
+        #endregion
+
+        #region IExceptionFilter Members
+        void IExceptionFilter.OnException(ExceptionContext filterContext) {
+            OnException(filterContext);
+        }
+        #endregion
+
+        #region IResultFilter Members
+        void IResultFilter.OnResultExecuting(ResultExecutingContext filterContext) {
+            OnResultExecuting(filterContext);
+        }
+
+        void IResultFilter.OnResultExecuted(ResultExecutedContext filterContext) {
+            OnResultExecuted(filterContext);
+        }
+        #endregion
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ControllerActionInvoker.cs b/mcs/class/System.Web.Mvc3/Mvc/ControllerActionInvoker.cs
new file mode 100644 (file)
index 0000000..f1eb3e7
--- /dev/null
@@ -0,0 +1,313 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq;
+    using System.Threading;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+    using Microsoft.Web.Infrastructure.DynamicValidationHelper;
+
+    public class ControllerActionInvoker : IActionInvoker {
+
+        private readonly static ControllerDescriptorCache _staticDescriptorCache = new ControllerDescriptorCache();
+
+        private ModelBinderDictionary _binders;
+        private Func<ControllerContext, ActionDescriptor, IEnumerable<Filter>> _getFiltersThunk = (cc, ad) => FilterProviders.Providers.GetFilters(cc, ad);
+        private ControllerDescriptorCache _instanceDescriptorCache;
+
+        public ControllerActionInvoker() {
+        }
+
+        internal ControllerActionInvoker(params object[] filters)
+            :this() {
+            if (filters != null) {
+                _getFiltersThunk = (cc, ad) => filters.Select(f => new Filter(f, FilterScope.Action, null));
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "Property is settable so that the dictionary can be provided for unit testing purposes.")]
+        protected internal ModelBinderDictionary Binders {
+            get {
+                if (_binders == null) {
+                    _binders = ModelBinders.Binders;
+                }
+                return _binders;
+            }
+            set {
+                _binders = value;
+            }
+        }
+
+        internal ControllerDescriptorCache DescriptorCache {
+            get {
+                if (_instanceDescriptorCache == null) {
+                    _instanceDescriptorCache = _staticDescriptorCache;
+                }
+                return _instanceDescriptorCache;
+            }
+            set {
+                _instanceDescriptorCache = value;
+            }
+        }
+
+        protected virtual ActionResult CreateActionResult(ControllerContext controllerContext, ActionDescriptor actionDescriptor, object actionReturnValue) {
+            if (actionReturnValue == null) {
+                return new EmptyResult();
+            }
+
+            ActionResult actionResult = (actionReturnValue as ActionResult) ??
+                new ContentResult { Content = Convert.ToString(actionReturnValue, CultureInfo.InvariantCulture) };
+            return actionResult;
+        }
+
+        protected virtual ControllerDescriptor GetControllerDescriptor(ControllerContext controllerContext) {
+            Type controllerType = controllerContext.Controller.GetType();
+            ControllerDescriptor controllerDescriptor = DescriptorCache.GetDescriptor(controllerType, () => new ReflectedControllerDescriptor(controllerType));
+            return controllerDescriptor;
+        }
+
+        protected virtual ActionDescriptor FindAction(ControllerContext controllerContext, ControllerDescriptor controllerDescriptor, string actionName) {
+            ActionDescriptor actionDescriptor = controllerDescriptor.FindAction(controllerContext, actionName);
+            return actionDescriptor;
+        }
+
+        protected virtual FilterInfo GetFilters(ControllerContext controllerContext, ActionDescriptor actionDescriptor) {
+            return new FilterInfo(_getFiltersThunk(controllerContext, actionDescriptor));
+        }
+
+        private IModelBinder GetModelBinder(ParameterDescriptor parameterDescriptor) {
+            // look on the parameter itself, then look in the global table
+            return parameterDescriptor.BindingInfo.Binder ?? Binders.GetBinder(parameterDescriptor.ParameterType);
+        }
+
+        protected virtual object GetParameterValue(ControllerContext controllerContext, ParameterDescriptor parameterDescriptor) {
+            // collect all of the necessary binding properties
+            Type parameterType = parameterDescriptor.ParameterType;
+            IModelBinder binder = GetModelBinder(parameterDescriptor);
+            IValueProvider valueProvider = controllerContext.Controller.ValueProvider;
+            string parameterName = parameterDescriptor.BindingInfo.Prefix ?? parameterDescriptor.ParameterName;
+            Predicate<string> propertyFilter = GetPropertyFilter(parameterDescriptor);
+
+            // finally, call into the binder
+            ModelBindingContext bindingContext = new ModelBindingContext() {
+                FallbackToEmptyPrefix = (parameterDescriptor.BindingInfo.Prefix == null), // only fall back if prefix not specified
+                ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(null, parameterType),
+                ModelName = parameterName,
+                ModelState = controllerContext.Controller.ViewData.ModelState,
+                PropertyFilter = propertyFilter,
+                ValueProvider = valueProvider
+            };
+
+            object result = binder.BindModel(controllerContext, bindingContext);
+            return result ?? parameterDescriptor.DefaultValue;
+        }
+
+        protected virtual IDictionary<string, object> GetParameterValues(ControllerContext controllerContext, ActionDescriptor actionDescriptor) {
+            Dictionary<string, object> parametersDict = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
+            ParameterDescriptor[] parameterDescriptors = actionDescriptor.GetParameters();
+
+            foreach (ParameterDescriptor parameterDescriptor in parameterDescriptors) {
+                parametersDict[parameterDescriptor.ParameterName] = GetParameterValue(controllerContext, parameterDescriptor);
+            }
+            return parametersDict;
+        }
+
+        private static Predicate<string> GetPropertyFilter(ParameterDescriptor parameterDescriptor) {
+            ParameterBindingInfo bindingInfo = parameterDescriptor.BindingInfo;
+            return propertyName => BindAttribute.IsPropertyAllowed(propertyName, bindingInfo.Include.ToArray(), bindingInfo.Exclude.ToArray());
+        }
+
+        public virtual bool InvokeAction(ControllerContext controllerContext, string actionName) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (String.IsNullOrEmpty(actionName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "actionName");
+            }
+
+            ControllerDescriptor controllerDescriptor = GetControllerDescriptor(controllerContext);
+            ActionDescriptor actionDescriptor = FindAction(controllerContext, controllerDescriptor, actionName);
+            if (actionDescriptor != null) {
+                FilterInfo filterInfo = GetFilters(controllerContext, actionDescriptor);
+
+                try {
+                    AuthorizationContext authContext = InvokeAuthorizationFilters(controllerContext, filterInfo.AuthorizationFilters, actionDescriptor);
+                    if (authContext.Result != null) {
+                        // the auth filter signaled that we should let it short-circuit the request
+                        InvokeActionResult(controllerContext, authContext.Result);
+                    }
+                    else {
+                        if (controllerContext.Controller.ValidateRequest) {
+                            ValidateRequest(controllerContext);
+                        }
+
+                        IDictionary<string, object> parameters = GetParameterValues(controllerContext, actionDescriptor);
+                        ActionExecutedContext postActionContext = InvokeActionMethodWithFilters(controllerContext, filterInfo.ActionFilters, actionDescriptor, parameters);
+                        InvokeActionResultWithFilters(controllerContext, filterInfo.ResultFilters, postActionContext.Result);
+                    }
+                }
+                catch (ThreadAbortException) {
+                    // This type of exception occurs as a result of Response.Redirect(), but we special-case so that
+                    // the filters don't see this as an error.
+                    throw;
+                }
+                catch (Exception ex) {
+                    // something blew up, so execute the exception filters
+                    ExceptionContext exceptionContext = InvokeExceptionFilters(controllerContext, filterInfo.ExceptionFilters, ex);
+                    if (!exceptionContext.ExceptionHandled) {
+                        throw;
+                    }
+                    InvokeActionResult(controllerContext, exceptionContext.Result);
+                }
+
+                return true;
+            }
+
+            // notify controller that no method matched
+            return false;
+        }
+
+        protected virtual ActionResult InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary<string, object> parameters) {
+            object returnValue = actionDescriptor.Execute(controllerContext, parameters);
+            ActionResult result = CreateActionResult(controllerContext, actionDescriptor, returnValue);
+            return result;
+        }
+
+        internal static ActionExecutedContext InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func<ActionExecutedContext> continuation) {
+            filter.OnActionExecuting(preContext);
+            if (preContext.Result != null) {
+                return new ActionExecutedContext(preContext, preContext.ActionDescriptor, true /* canceled */, null /* exception */) {
+                    Result = preContext.Result
+                };
+            }
+
+            bool wasError = false;
+            ActionExecutedContext postContext = null;
+            try {
+                postContext = continuation();
+            }
+            catch (ThreadAbortException) {
+                // This type of exception occurs as a result of Response.Redirect(), but we special-case so that
+                // the filters don't see this as an error.
+                postContext = new ActionExecutedContext(preContext, preContext.ActionDescriptor, false /* canceled */, null /* exception */);
+                filter.OnActionExecuted(postContext);
+                throw;
+            }
+            catch (Exception ex) {
+                wasError = true;
+                postContext = new ActionExecutedContext(preContext, preContext.ActionDescriptor, false /* canceled */, ex);
+                filter.OnActionExecuted(postContext);
+                if (!postContext.ExceptionHandled) {
+                    throw;
+                }
+            }
+            if (!wasError) {
+                filter.OnActionExecuted(postContext);
+            }
+            return postContext;
+        }
+
+        protected virtual ActionExecutedContext InvokeActionMethodWithFilters(ControllerContext controllerContext, IList<IActionFilter> filters, ActionDescriptor actionDescriptor, IDictionary<string, object> parameters) {
+            ActionExecutingContext preContext = new ActionExecutingContext(controllerContext, actionDescriptor, parameters);
+            Func<ActionExecutedContext> continuation = () =>
+                new ActionExecutedContext(controllerContext, actionDescriptor, false /* canceled */, null /* exception */) {
+                    Result = InvokeActionMethod(controllerContext, actionDescriptor, parameters)
+                };
+
+            // need to reverse the filter list because the continuations are built up backward
+            Func<ActionExecutedContext> thunk = filters.Reverse().Aggregate(continuation,
+                (next, filter) => () => InvokeActionMethodFilter(filter, preContext, next));
+            return thunk();
+        }
+
+        protected virtual void InvokeActionResult(ControllerContext controllerContext, ActionResult actionResult) {
+            actionResult.ExecuteResult(controllerContext);
+        }
+
+        internal static ResultExecutedContext InvokeActionResultFilter(IResultFilter filter, ResultExecutingContext preContext, Func<ResultExecutedContext> continuation) {
+            filter.OnResultExecuting(preContext);
+            if (preContext.Cancel) {
+                return new ResultExecutedContext(preContext, preContext.Result, true /* canceled */, null /* exception */);
+            }
+
+            bool wasError = false;
+            ResultExecutedContext postContext = null;
+            try {
+                postContext = continuation();
+            }
+            catch (ThreadAbortException) {
+                // This type of exception occurs as a result of Response.Redirect(), but we special-case so that
+                // the filters don't see this as an error.
+                postContext = new ResultExecutedContext(preContext, preContext.Result, false /* canceled */, null /* exception */);
+                filter.OnResultExecuted(postContext);
+                throw;
+            }
+            catch (Exception ex) {
+                wasError = true;
+                postContext = new ResultExecutedContext(preContext, preContext.Result, false /* canceled */, ex);
+                filter.OnResultExecuted(postContext);
+                if (!postContext.ExceptionHandled) {
+                    throw;
+                }
+            }
+            if (!wasError) {
+                filter.OnResultExecuted(postContext);
+            }
+            return postContext;
+        }
+
+        protected virtual ResultExecutedContext InvokeActionResultWithFilters(ControllerContext controllerContext, IList<IResultFilter> filters, ActionResult actionResult) {
+            ResultExecutingContext preContext = new ResultExecutingContext(controllerContext, actionResult);
+            Func<ResultExecutedContext> continuation = delegate {
+                InvokeActionResult(controllerContext, actionResult);
+                return new ResultExecutedContext(controllerContext, actionResult, false /* canceled */, null /* exception */);
+            };
+
+            // need to reverse the filter list because the continuations are built up backward
+            Func<ResultExecutedContext> thunk = filters.Reverse().Aggregate(continuation,
+                (next, filter) => () => InvokeActionResultFilter(filter, preContext, next));
+            return thunk();
+        }
+
+        protected virtual AuthorizationContext InvokeAuthorizationFilters(ControllerContext controllerContext, IList<IAuthorizationFilter> filters, ActionDescriptor actionDescriptor) {
+            AuthorizationContext context = new AuthorizationContext(controllerContext, actionDescriptor);
+            foreach (IAuthorizationFilter filter in filters) {
+                filter.OnAuthorization(context);
+                // short-circuit evaluation
+                if (context.Result != null) {
+                    break;
+                }
+            }
+
+            return context;
+        }
+
+        protected virtual ExceptionContext InvokeExceptionFilters(ControllerContext controllerContext, IList<IExceptionFilter> filters, Exception exception) {
+            ExceptionContext context = new ExceptionContext(controllerContext, exception);
+            foreach (IExceptionFilter filter in filters.Reverse()) {
+                filter.OnException(context);
+            }
+
+            return context;
+        }
+
+        internal static void ValidateRequest(ControllerContext controllerContext) {
+            if (controllerContext.IsChildAction) {
+                return;
+            }
+
+            // DevDiv 214040: Enable Request Validation by default for all controller requests
+            // 
+            // Earlier versions of this method dereferenced Request.RawUrl to force validation of
+            // that field. This was necessary for Routing before ASP.NET v4, which read the incoming
+            // path from RawUrl. Request validation has been moved earlier in the pipeline by default and
+            // routing no longer consumes this property, so we don't have to either.
+
+            ValidationUtility.EnableDynamicValidation(HttpContext.Current);
+            controllerContext.HttpContext.Request.ValidateInput();
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ControllerBase.cs b/mcs/class/System.Web.Mvc3/Mvc/ControllerBase.cs
new file mode 100644 (file)
index 0000000..509da4f
--- /dev/null
@@ -0,0 +1,120 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Web.Mvc.Async;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+    using System.Web.WebPages;
+    using System.Web.WebPages.Scope;
+
+    public abstract class ControllerBase : IController {
+
+        private readonly SingleEntryGate _executeWasCalledGate = new SingleEntryGate();
+
+        private DynamicViewDataDictionary _dynamicViewDataDictionary;
+        private TempDataDictionary _tempDataDictionary;
+        private bool _validateRequest = true;
+        private IValueProvider _valueProvider;
+        private ViewDataDictionary _viewDataDictionary;
+
+        public ControllerContext ControllerContext {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This property is settable so that unit tests can provide mock implementations.")]
+        public TempDataDictionary TempData {
+            get {
+                if (ControllerContext != null && ControllerContext.IsChildAction) {
+                    return ControllerContext.ParentActionViewContext.TempData;
+                }
+                if (_tempDataDictionary == null) {
+                    _tempDataDictionary = new TempDataDictionary();
+                }
+                return _tempDataDictionary;
+            }
+            set {
+                _tempDataDictionary = value;
+            }
+        }
+
+        public bool ValidateRequest {
+            get {
+                return _validateRequest;
+            }
+            set {
+                _validateRequest = value;
+            }
+        }
+
+        public IValueProvider ValueProvider {
+            get {
+                if (_valueProvider == null) {
+                    _valueProvider = ValueProviderFactories.Factories.GetValueProvider(ControllerContext);
+                }
+                return _valueProvider;
+            }
+            set {
+                _valueProvider = value;
+            }
+        }
+
+        public dynamic ViewBag {
+            get {
+                if (_dynamicViewDataDictionary == null) {
+                    _dynamicViewDataDictionary = new DynamicViewDataDictionary(() => ViewData);
+                }
+                return _dynamicViewDataDictionary;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This property is settable so that unit tests can provide mock implementations.")]
+        public ViewDataDictionary ViewData {
+            get {
+                if (_viewDataDictionary == null) {
+                    _viewDataDictionary = new ViewDataDictionary();
+                }
+                return _viewDataDictionary;
+            }
+            set {
+                _viewDataDictionary = value;
+            }
+        }
+
+        protected virtual void Execute(RequestContext requestContext) {
+            if (requestContext == null) {
+                throw new ArgumentNullException("requestContext");
+            }
+            if (requestContext.HttpContext == null) {
+                throw new ArgumentException(MvcResources.ControllerBase_CannotExecuteWithNullHttpContext, "requestContext");
+            }
+
+            VerifyExecuteCalledOnce();
+            Initialize(requestContext);
+
+            using (ScopeStorage.CreateTransientScope()) {
+                ExecuteCore();
+            }
+        }
+
+        protected abstract void ExecuteCore();
+
+        protected virtual void Initialize(RequestContext requestContext) {
+            ControllerContext = new ControllerContext(requestContext, this);
+        }
+
+        internal void VerifyExecuteCalledOnce() {
+            if (!_executeWasCalledGate.TryEnter()) {
+                string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ControllerBase_CannotHandleMultipleRequests, GetType());
+                throw new InvalidOperationException(message);
+            }
+        }
+
+        #region IController Members
+        void IController.Execute(RequestContext requestContext) {
+            Execute(requestContext);
+        }
+        #endregion
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ControllerBuilder.cs b/mcs/class/System.Web.Mvc3/Mvc/ControllerBuilder.cs
new file mode 100644 (file)
index 0000000..1df29c3
--- /dev/null
@@ -0,0 +1,81 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Web.Mvc.Resources;
+
+    public class ControllerBuilder {
+
+        private Func<IControllerFactory> _factoryThunk = () => null;
+        private static ControllerBuilder _instance = new ControllerBuilder();
+        private HashSet<string> _namespaces = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
+        private IResolver<IControllerFactory> _serviceResolver;
+
+        public ControllerBuilder()
+            : this(null) {
+        }
+
+        internal ControllerBuilder(IResolver<IControllerFactory> serviceResolver) {
+            _serviceResolver = serviceResolver ?? new SingleServiceResolver<IControllerFactory>(
+                () => _factoryThunk(),
+                 new DefaultControllerFactory { ControllerBuilder = this },
+                "ControllerBuilder.GetControllerFactory"
+            );
+        }
+
+        public static ControllerBuilder Current {
+            get {
+                return _instance;
+            }
+        }
+
+        public HashSet<string> DefaultNamespaces {
+            get {
+                return _namespaces;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate", Justification = "Calling method multiple times might return different objects.")]
+        public IControllerFactory GetControllerFactory() {
+            return _serviceResolver.Current;
+        }
+
+        public void SetControllerFactory(IControllerFactory controllerFactory) {
+            if (controllerFactory == null) {
+                throw new ArgumentNullException("controllerFactory");
+            }
+
+            _factoryThunk = () => controllerFactory;
+        }
+
+        public void SetControllerFactory(Type controllerFactoryType) {
+            if (controllerFactoryType == null) {
+                throw new ArgumentNullException("controllerFactoryType");
+            }
+            if (!typeof(IControllerFactory).IsAssignableFrom(controllerFactoryType)) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.ControllerBuilder_MissingIControllerFactory,
+                        controllerFactoryType),
+                    "controllerFactoryType");
+            }
+
+            _factoryThunk = delegate() {
+                try {
+                    return (IControllerFactory)Activator.CreateInstance(controllerFactoryType);
+                }
+                catch (Exception ex) {
+                    throw new InvalidOperationException(
+                        String.Format(
+                            CultureInfo.CurrentCulture,
+                            MvcResources.ControllerBuilder_ErrorCreatingControllerFactory,
+                            controllerFactoryType),
+                        ex);
+                }
+            };
+        }
+    }
+}
+
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ControllerContext.cs b/mcs/class/System.Web.Mvc3/Mvc/ControllerContext.cs
new file mode 100644 (file)
index 0000000..756a4be
--- /dev/null
@@ -0,0 +1,120 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web;
+    using System.Web.Routing;
+    using System.Web.Mvc.Html;
+
+    // Though many of the properties on ControllerContext and its subclassed types are virtual, there are still sealed
+    // properties (like ControllerContext.RequestContext, ActionExecutingContext.Result, etc.). If these properties
+    // were virtual, a mocking framework might override them with incorrect behavior (property getters would return
+    // null, property setters would be no-ops). By sealing these properties, we are forcing them to have the default
+    // "get or store a value" semantics that they were intended to have.
+
+    public class ControllerContext {
+
+        private HttpContextBase _httpContext;
+        private RequestContext _requestContext;
+        private RouteData _routeData;
+
+        internal const string PARENT_ACTION_VIEWCONTEXT = "ParentActionViewContext";
+
+        // parameterless constructor used for mocking
+        public ControllerContext() {
+        }
+
+        // copy constructor - allows for subclassed types to take an existing ControllerContext as a parameter
+        // and we'll automatically set the appropriate properties
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
+        protected ControllerContext(ControllerContext controllerContext) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            Controller = controllerContext.Controller;
+            RequestContext = controllerContext.RequestContext;
+        }
+
+        public ControllerContext(HttpContextBase httpContext, RouteData routeData, ControllerBase controller)
+            : this(new RequestContext(httpContext, routeData), controller) {
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
+        public ControllerContext(RequestContext requestContext, ControllerBase controller) {
+            if (requestContext == null) {
+                throw new ArgumentNullException("requestContext");
+            }
+            if (controller == null) {
+                throw new ArgumentNullException("controller");
+            }
+
+            RequestContext = requestContext;
+            Controller = controller;
+        }
+
+        public virtual ControllerBase Controller {
+            get;
+            set;
+        }
+
+        public virtual HttpContextBase HttpContext {
+            get {
+                if (_httpContext == null) {
+                    _httpContext = (_requestContext != null) ? _requestContext.HttpContext : new EmptyHttpContext();
+                }
+                return _httpContext;
+            }
+            set {
+                _httpContext = value;
+            }
+        }
+
+        public virtual bool IsChildAction {
+            get {
+                RouteData routeData = RouteData;
+                if (routeData == null) {
+                    return false;
+                }
+                return routeData.DataTokens.ContainsKey(PARENT_ACTION_VIEWCONTEXT);
+            }
+        }
+
+        public ViewContext ParentActionViewContext {
+            get {
+                return RouteData.DataTokens[PARENT_ACTION_VIEWCONTEXT] as ViewContext;
+            }
+        }
+
+        public RequestContext RequestContext {
+            get {
+                if (_requestContext == null) {
+                    // still need explicit calls to constructors since the property getters are virtual and might return null
+                    HttpContextBase httpContext = HttpContext ?? new EmptyHttpContext();
+                    RouteData routeData = RouteData ?? new RouteData();
+
+                    _requestContext = new RequestContext(httpContext, routeData);
+                }
+                return _requestContext;
+            }
+            set {
+                _requestContext = value;
+            }
+        }
+
+        public virtual RouteData RouteData {
+            get {
+                if (_routeData == null) {
+                    _routeData = (_requestContext != null) ? _requestContext.RouteData : new RouteData();
+                }
+                return _routeData;
+            }
+            set {
+                _routeData = value;
+            }
+        }
+
+        private sealed class EmptyHttpContext : HttpContextBase {
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ControllerDescriptor.cs b/mcs/class/System.Web.Mvc3/Mvc/ControllerDescriptor.cs
new file mode 100644 (file)
index 0000000..121b36a
--- /dev/null
@@ -0,0 +1,71 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq;
+    using System.Reflection;
+
+    public abstract class ControllerDescriptor : ICustomAttributeProvider, IUniquelyIdentifiable {
+
+        private readonly Lazy<string> _uniqueId;
+
+        protected ControllerDescriptor() {
+            _uniqueId = new Lazy<string>(CreateUniqueId);
+        }
+
+        public virtual string ControllerName {
+            get {
+                string typeName = ControllerType.Name;
+                if (typeName.EndsWith("Controller", StringComparison.OrdinalIgnoreCase)) {
+                    return typeName.Substring(0, typeName.Length - "Controller".Length);
+                }
+
+                return typeName;
+            }
+        }
+
+        public abstract Type ControllerType {
+            get;
+        }
+
+        [SuppressMessage("Microsoft.Security", "CA2119:SealMethodsThatSatisfyPrivateInterfaces", Justification = "This is overridden elsewhere in System.Web.Mvc")]
+        public virtual string UniqueId {
+            get {
+                return _uniqueId.Value;
+            }
+        }
+
+        private string CreateUniqueId() {
+            return DescriptorUtil.CreateUniqueId(GetType(), ControllerName, ControllerType);
+        }
+
+        public abstract ActionDescriptor FindAction(ControllerContext controllerContext, string actionName);
+
+        public abstract ActionDescriptor[] GetCanonicalActions();
+
+        public virtual object[] GetCustomAttributes(bool inherit) {
+            return GetCustomAttributes(typeof(object), inherit);
+        }
+
+        public virtual object[] GetCustomAttributes(Type attributeType, bool inherit) {
+            if (attributeType == null) {
+                throw new ArgumentNullException("attributeType");
+            }
+
+            return (object[])Array.CreateInstance(attributeType, 0);
+        }
+
+        internal virtual IEnumerable<FilterAttribute> GetFilterAttributes(bool useCache) {
+            return GetCustomAttributes(typeof(FilterAttribute), inherit: true).Cast<FilterAttribute>();
+        }
+
+        public virtual bool IsDefined(Type attributeType, bool inherit) {
+            if (attributeType == null) {
+                throw new ArgumentNullException("attributeType");
+            }
+
+            return false;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ControllerDescriptorCache.cs b/mcs/class/System.Web.Mvc3/Mvc/ControllerDescriptorCache.cs
new file mode 100644 (file)
index 0000000..01c91ba
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System;
+
+    internal sealed class ControllerDescriptorCache : ReaderWriterCache<Type, ControllerDescriptor> {
+
+        public ControllerDescriptorCache() {
+        }
+
+        public ControllerDescriptor GetDescriptor(Type controllerType, Func<ControllerDescriptor> creator) {
+            return FetchOrCreateItem(controllerType, creator);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ControllerInstanceFilterProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/ControllerInstanceFilterProvider.cs
new file mode 100644 (file)
index 0000000..207375c
--- /dev/null
@@ -0,0 +1,12 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+
+    public class ControllerInstanceFilterProvider : IFilterProvider {
+        public IEnumerable<Filter> GetFilters(ControllerContext controllerContext, ActionDescriptor actionDescriptor) {
+            if (controllerContext.Controller != null) {
+                // Use FilterScope.First and Order of Int32.MinValue to ensure controller instance methods always run first
+                yield return new Filter(controllerContext.Controller, FilterScope.First, Int32.MinValue);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ControllerTypeCache.cs b/mcs/class/System.Web.Mvc3/Mvc/ControllerTypeCache.cs
new file mode 100644 (file)
index 0000000..ba76e65
--- /dev/null
@@ -0,0 +1,115 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Linq;
+    using System.Reflection;
+
+    internal sealed class ControllerTypeCache {
+
+        private const string _typeCacheName = "MVC-ControllerTypeCache.xml";
+
+        private Dictionary<string, ILookup<string, Type>> _cache;
+        private object _lockObj = new object();
+
+        internal int Count {
+            get {
+                int count = 0;
+                foreach (var lookup in _cache.Values) {
+                    foreach (var grouping in lookup) {
+                        count += grouping.Count();
+                    }
+                }
+                return count;
+            }
+        }
+
+        public void EnsureInitialized(IBuildManager buildManager) {
+            if (_cache == null) {
+                lock (_lockObj) {
+                    if (_cache == null) {
+                        List<Type> controllerTypes = TypeCacheUtil.GetFilteredTypesFromAssemblies(_typeCacheName, IsControllerType, buildManager);
+                        var groupedByName = controllerTypes.GroupBy(
+                            t => t.Name.Substring(0, t.Name.Length - "Controller".Length),
+                            StringComparer.OrdinalIgnoreCase);
+                        _cache = groupedByName.ToDictionary(
+                            g => g.Key,
+                            g => g.ToLookup(t => t.Namespace ?? String.Empty, StringComparer.OrdinalIgnoreCase),
+                            StringComparer.OrdinalIgnoreCase);
+                    }
+                }
+            }
+        }
+
+        public ICollection<Type> GetControllerTypes(string controllerName, HashSet<string> namespaces) {
+            HashSet<Type> matchingTypes = new HashSet<Type>();
+
+            ILookup<string, Type> nsLookup;
+            if (_cache.TryGetValue(controllerName, out nsLookup)) {
+                // this friendly name was located in the cache, now cycle through namespaces
+                if (namespaces != null) {
+                    foreach (string requestedNamespace in namespaces) {
+                        foreach (var targetNamespaceGrouping in nsLookup) {
+                            if (IsNamespaceMatch(requestedNamespace, targetNamespaceGrouping.Key)) {
+                                matchingTypes.UnionWith(targetNamespaceGrouping);
+                            }
+                        }
+                    }
+                }
+                else {
+                    // if the namespaces parameter is null, search *every* namespace
+                    foreach (var nsGroup in nsLookup) {
+                        matchingTypes.UnionWith(nsGroup);
+                    }
+                }
+            }
+
+            return matchingTypes;
+        }
+
+        internal static bool IsControllerType(Type t) {
+            return
+                t != null &&
+                t.IsPublic &&
+                t.Name.EndsWith("Controller", StringComparison.OrdinalIgnoreCase) &&
+                !t.IsAbstract &&
+                typeof(IController).IsAssignableFrom(t);
+        }
+
+        internal static bool IsNamespaceMatch(string requestedNamespace, string targetNamespace) {
+            // degenerate cases
+            if (requestedNamespace == null) {
+                return false;
+            }
+            else if (requestedNamespace.Length == 0) {
+                return true;
+            }
+
+            if (!requestedNamespace.EndsWith(".*", StringComparison.OrdinalIgnoreCase)) {
+                // looking for exact namespace match
+                return String.Equals(requestedNamespace, targetNamespace, StringComparison.OrdinalIgnoreCase);
+            }
+            else {
+                // looking for exact or sub-namespace match
+                requestedNamespace = requestedNamespace.Substring(0, requestedNamespace.Length - ".*".Length);
+                if (!targetNamespace.StartsWith(requestedNamespace, StringComparison.OrdinalIgnoreCase)) {
+                    return false;
+                }
+
+                if (requestedNamespace.Length == targetNamespace.Length) {
+                    // exact match
+                    return true;
+                }
+                else if (targetNamespace[requestedNamespace.Length] == '.') {
+                    // good prefix match, e.g. requestedNamespace = "Foo.Bar" and targetNamespace = "Foo.Bar.Baz"
+                    return true;
+                }
+                else {
+                    // bad prefix match, e.g. requestedNamespace = "Foo.Bar" and targetNamespace = "Foo.Bar2"
+                    return false;
+                }
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/CustomModelBinderAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/CustomModelBinderAttribute.cs
new file mode 100644 (file)
index 0000000..b0feb7e
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+
+    [AttributeUsage(ValidTargets, AllowMultiple = false, Inherited = false)]
+    public abstract class CustomModelBinderAttribute : Attribute {
+
+        internal const AttributeTargets ValidTargets = AttributeTargets.Class | AttributeTargets.Enum | AttributeTargets.Interface | AttributeTargets.Parameter | AttributeTargets.Struct;
+
+        [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate", Justification = "This method can potentially perform a non-trivial amount of work.")]
+        public abstract IModelBinder GetBinder();
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelMetadata.cs b/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelMetadata.cs
new file mode 100644 (file)
index 0000000..b171f6b
--- /dev/null
@@ -0,0 +1,51 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.ComponentModel.DataAnnotations;
+    using System.Globalization;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    public class DataAnnotationsModelMetadata : ModelMetadata {
+        private DisplayColumnAttribute _displayColumnAttribute;
+
+        public DataAnnotationsModelMetadata(DataAnnotationsModelMetadataProvider provider, Type containerType,
+                                            Func<object> modelAccessor, Type modelType, string propertyName,
+                                            DisplayColumnAttribute displayColumnAttribute)
+            : base(provider, containerType, modelAccessor, modelType, propertyName) {
+            _displayColumnAttribute = displayColumnAttribute;
+        }
+
+        protected override string GetSimpleDisplayText() {
+            if (Model != null) {
+                if (_displayColumnAttribute != null && !String.IsNullOrEmpty(_displayColumnAttribute.DisplayColumn)) {
+                    PropertyInfo displayColumnProperty = ModelType.GetProperty(_displayColumnAttribute.DisplayColumn, BindingFlags.Public | BindingFlags.IgnoreCase | BindingFlags.Instance);
+                    ValidateDisplayColumnAttribute(_displayColumnAttribute, displayColumnProperty, ModelType);
+
+                    object simpleDisplayTextValue = displayColumnProperty.GetValue(Model, new object[0]);
+                    if (simpleDisplayTextValue != null) {
+                        return simpleDisplayTextValue.ToString();
+                    }
+                }
+            }
+
+            return base.GetSimpleDisplayText();
+        }
+
+        private static void ValidateDisplayColumnAttribute(DisplayColumnAttribute displayColumnAttribute, PropertyInfo displayColumnProperty, Type modelType) {
+            if (displayColumnProperty == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.DataAnnotationsModelMetadataProvider_UnknownProperty,
+                        modelType.FullName, displayColumnAttribute.DisplayColumn));
+            }
+            if (displayColumnProperty.GetGetMethod() == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.DataAnnotationsModelMetadataProvider_UnreadableProperty,
+                        modelType.FullName, displayColumnAttribute.DisplayColumn));
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelMetadataProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelMetadataProvider.cs
new file mode 100644 (file)
index 0000000..9f849ee
--- /dev/null
@@ -0,0 +1,98 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.ComponentModel.DataAnnotations;
+    using System.Linq;
+
+    public class DataAnnotationsModelMetadataProvider : AssociatedMetadataProvider {
+
+        protected override ModelMetadata CreateMetadata(IEnumerable<Attribute> attributes, Type containerType, Func<object> modelAccessor, Type modelType, string propertyName) {
+            List<Attribute> attributeList = new List<Attribute>(attributes);
+            DisplayColumnAttribute displayColumnAttribute = attributeList.OfType<DisplayColumnAttribute>().FirstOrDefault();
+            DataAnnotationsModelMetadata result = new DataAnnotationsModelMetadata(this, containerType, modelAccessor, modelType, propertyName, displayColumnAttribute);
+
+            // Do [HiddenInput] before [UIHint], so you can override the template hint
+            HiddenInputAttribute hiddenInputAttribute = attributeList.OfType<HiddenInputAttribute>().FirstOrDefault();
+            if (hiddenInputAttribute != null) {
+                result.TemplateHint = "HiddenInput";
+                result.HideSurroundingHtml = !hiddenInputAttribute.DisplayValue;
+            }
+
+            // We prefer [UIHint("...", PresentationLayer = "MVC")] but will fall back to [UIHint("...")]
+            IEnumerable<UIHintAttribute> uiHintAttributes = attributeList.OfType<UIHintAttribute>();
+            UIHintAttribute uiHintAttribute = uiHintAttributes.FirstOrDefault(a => String.Equals(a.PresentationLayer, "MVC", StringComparison.OrdinalIgnoreCase))
+                                           ?? uiHintAttributes.FirstOrDefault(a => String.IsNullOrEmpty(a.PresentationLayer));
+            if (uiHintAttribute != null) {
+                result.TemplateHint = uiHintAttribute.UIHint;
+            }
+
+            DataTypeAttribute dataTypeAttribute = attributeList.OfType<DataTypeAttribute>().FirstOrDefault();
+            if (dataTypeAttribute != null) {
+                result.DataTypeName = dataTypeAttribute.ToDataTypeName();
+            }
+
+            EditableAttribute editable = attributes.OfType<EditableAttribute>().FirstOrDefault();
+            if (editable != null) {
+                result.IsReadOnly = !editable.AllowEdit;
+            }
+            else {
+                ReadOnlyAttribute readOnlyAttribute = attributeList.OfType<ReadOnlyAttribute>().FirstOrDefault();
+                if (readOnlyAttribute != null) {
+                    result.IsReadOnly = readOnlyAttribute.IsReadOnly;
+                }
+            }
+
+            DisplayFormatAttribute displayFormatAttribute = attributeList.OfType<DisplayFormatAttribute>().FirstOrDefault();
+            if (displayFormatAttribute == null && dataTypeAttribute != null) {
+                displayFormatAttribute = dataTypeAttribute.DisplayFormat;
+            }
+            if (displayFormatAttribute != null) {
+                result.NullDisplayText = displayFormatAttribute.NullDisplayText;
+                result.DisplayFormatString = displayFormatAttribute.DataFormatString;
+                result.ConvertEmptyStringToNull = displayFormatAttribute.ConvertEmptyStringToNull;
+
+                if (displayFormatAttribute.ApplyFormatInEditMode) {
+                    result.EditFormatString = displayFormatAttribute.DataFormatString;
+                }
+
+                if (!displayFormatAttribute.HtmlEncode && String.IsNullOrWhiteSpace(result.DataTypeName)) {
+                    result.DataTypeName = DataTypeUtil.HtmlTypeName;
+                }
+            }
+
+            ScaffoldColumnAttribute scaffoldColumnAttribute = attributeList.OfType<ScaffoldColumnAttribute>().FirstOrDefault();
+            if (scaffoldColumnAttribute != null) {
+                result.ShowForDisplay = result.ShowForEdit = scaffoldColumnAttribute.Scaffold;
+            }
+
+            DisplayAttribute display = attributes.OfType<DisplayAttribute>().FirstOrDefault();
+            string name = null;
+            if (display != null) {
+                result.Description = display.GetDescription();
+                result.ShortDisplayName = display.GetShortName();
+                result.Watermark = display.GetPrompt();
+                result.Order = display.GetOrder() ?? ModelMetadata.DefaultOrder;
+
+                name = display.GetName();
+            }
+
+            if (name != null) {
+                result.DisplayName = name;
+            }
+            else {
+                DisplayNameAttribute displayNameAttribute = attributeList.OfType<DisplayNameAttribute>().FirstOrDefault();
+                if (displayNameAttribute != null) {
+                    result.DisplayName = displayNameAttribute.DisplayName;
+                }
+            }
+
+            RequiredAttribute requiredAttribute = attributeList.OfType<RequiredAttribute>().FirstOrDefault();
+            if (requiredAttribute != null) {
+                result.IsRequired = true;
+            }
+
+            return result;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelValidator.cs b/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelValidator.cs
new file mode 100644 (file)
index 0000000..296f7f4
--- /dev/null
@@ -0,0 +1,61 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel.DataAnnotations;
+    using System.Linq;
+
+    public class DataAnnotationsModelValidator : ModelValidator {
+        public DataAnnotationsModelValidator(ModelMetadata metadata, ControllerContext context, ValidationAttribute attribute)
+            : base(metadata, context) {
+
+            if (attribute == null) {
+                throw new ArgumentNullException("attribute");
+            }
+
+            Attribute = attribute;
+        }
+
+        protected internal ValidationAttribute Attribute { get; private set; }
+
+        protected internal string ErrorMessage {
+            get {
+                return Attribute.FormatErrorMessage(Metadata.GetDisplayName());
+            }
+        }
+
+        public override bool IsRequired {
+            get {
+                return Attribute is RequiredAttribute;
+            }
+        }
+
+        internal static ModelValidator Create(ModelMetadata metadata, ControllerContext context, ValidationAttribute attribute) {
+            return new DataAnnotationsModelValidator(metadata, context, attribute);
+        }
+
+        public override IEnumerable<ModelClientValidationRule> GetClientValidationRules() {
+            IEnumerable<ModelClientValidationRule> results = base.GetClientValidationRules();
+
+            IClientValidatable clientValidatable = Attribute as IClientValidatable;
+            if (clientValidatable != null) {
+                results = results.Concat(clientValidatable.GetClientValidationRules(Metadata, ControllerContext));
+            }
+
+            return results;
+        }
+
+        public override IEnumerable<ModelValidationResult> Validate(object container) {
+            // Per the WCF RIA Services team, instance can never be null (if you have
+            // no parent, you pass yourself for the "instance" parameter).
+            ValidationContext context = new ValidationContext(container ?? Metadata.Model, null, null);
+            context.DisplayName = Metadata.GetDisplayName();
+
+            ValidationResult result = Attribute.GetValidationResult(Metadata.Model, context);
+            if (result != ValidationResult.Success) {
+                yield return new ModelValidationResult {
+                    Message = result.ErrorMessage
+                };
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelValidatorProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelValidatorProvider.cs
new file mode 100644 (file)
index 0000000..6a5c579
--- /dev/null
@@ -0,0 +1,342 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel.DataAnnotations;
+    using System.Globalization;
+    using System.Linq;
+    using System.Reflection;
+    using System.Threading;
+    using System.Web.Mvc.Resources;
+
+    // A factory for validators based on ValidationAttribute
+    public delegate ModelValidator DataAnnotationsModelValidationFactory(ModelMetadata metadata, ControllerContext context, ValidationAttribute attribute);
+
+    // A factory for validators based on IValidatableObject
+    public delegate ModelValidator DataAnnotationsValidatableObjectAdapterFactory(ModelMetadata metadata, ControllerContext context);
+
+    /// <summary>
+    /// An implementation of <see cref="ModelValidatorProvider"/> which providers validators
+    /// for attributes which derive from <see cref="ValidationAttribute"/>. It also provides
+    /// a validator for types which implement <see cref="IValidatableObject"/>. To support
+    /// client side validation, you can either register adapters through the static methods
+    /// on this class, or by having your validation attributes implement
+    /// <see cref="IClientValidatable"/>. The logic to support IClientValidatable
+    /// is implemented in <see cref="DataAnnotationsModelValidator"/>.
+    /// </summary>
+    public class DataAnnotationsModelValidatorProvider : AssociatedValidatorProvider {
+        private static bool _addImplicitRequiredAttributeForValueTypes = true;
+        private static ReaderWriterLockSlim _adaptersLock = new ReaderWriterLockSlim();
+
+        // Factories for validation attributes
+
+        internal static DataAnnotationsModelValidationFactory DefaultAttributeFactory =
+            (metadata, context, attribute) => new DataAnnotationsModelValidator(metadata, context, attribute);
+
+        internal static Dictionary<Type, DataAnnotationsModelValidationFactory> AttributeFactories = new Dictionary<Type, DataAnnotationsModelValidationFactory>() {
+            {
+                typeof(RangeAttribute),
+                (metadata, context, attribute) => new RangeAttributeAdapter(metadata, context, (RangeAttribute)attribute)
+            },
+            {
+                typeof(RegularExpressionAttribute),
+                (metadata, context, attribute) => new RegularExpressionAttributeAdapter(metadata, context, (RegularExpressionAttribute)attribute)
+            },
+            {
+                typeof(RequiredAttribute),
+                (metadata, context, attribute) => new RequiredAttributeAdapter(metadata, context, (RequiredAttribute)attribute)
+            },
+            {
+                typeof(StringLengthAttribute),
+                (metadata, context, attribute) => new StringLengthAttributeAdapter(metadata, context, (StringLengthAttribute)attribute)
+            },
+        };
+
+        // Factories for IValidatableObject models
+
+        internal static DataAnnotationsValidatableObjectAdapterFactory DefaultValidatableFactory =
+            (metadata, context) => new ValidatableObjectAdapter(metadata, context);
+
+        internal static Dictionary<Type, DataAnnotationsValidatableObjectAdapterFactory> ValidatableFactories = new Dictionary<Type, DataAnnotationsValidatableObjectAdapterFactory>();
+
+        public static bool AddImplicitRequiredAttributeForValueTypes {
+            get {
+                return _addImplicitRequiredAttributeForValueTypes;
+            }
+            set {
+                _addImplicitRequiredAttributeForValueTypes = value;
+            }
+        }
+
+        protected override IEnumerable<ModelValidator> GetValidators(ModelMetadata metadata, ControllerContext context, IEnumerable<Attribute> attributes) {
+            _adaptersLock.EnterReadLock();
+
+            try {
+                List<ModelValidator> results = new List<ModelValidator>();
+
+                // Add an implied [Required] attribute for any non-nullable value type,
+                // unless they've configured us not to do that.
+                if (AddImplicitRequiredAttributeForValueTypes &&
+                        metadata.IsRequired &&
+                        !attributes.Any(a => a is RequiredAttribute)) {
+                    attributes = attributes.Concat(new[] { new RequiredAttribute() });
+                }
+
+                // Produce a validator for each validation attribute we find
+                foreach (ValidationAttribute attribute in attributes.OfType<ValidationAttribute>()) {
+                    DataAnnotationsModelValidationFactory factory;
+                    if (!AttributeFactories.TryGetValue(attribute.GetType(), out factory)) {
+                        factory = DefaultAttributeFactory;
+                    }
+                    results.Add(factory(metadata, context, attribute));
+                }
+
+                // Produce a validator if the type supports IValidatableObject
+                if (typeof(IValidatableObject).IsAssignableFrom(metadata.ModelType)) {
+                    DataAnnotationsValidatableObjectAdapterFactory factory;
+                    if (!ValidatableFactories.TryGetValue(metadata.ModelType, out factory)) {
+                        factory = DefaultValidatableFactory;
+                    }
+                    results.Add(factory(metadata, context));
+                }
+
+                return results;
+            }
+            finally {
+                _adaptersLock.ExitReadLock();
+            }
+        }
+
+        #region Validation attribute adapter registration
+
+        public static void RegisterAdapter(Type attributeType, Type adapterType) {
+            ValidateAttributeType(attributeType);
+            ValidateAttributeAdapterType(adapterType);
+            ConstructorInfo constructor = GetAttributeAdapterConstructor(attributeType, adapterType);
+
+            _adaptersLock.EnterWriteLock();
+
+            try {
+                AttributeFactories[attributeType] = (metadata, context, attribute) => (ModelValidator)constructor.Invoke(new object[] { metadata, context, attribute });
+            }
+            finally {
+                _adaptersLock.ExitWriteLock();
+            }
+        }
+
+        public static void RegisterAdapterFactory(Type attributeType, DataAnnotationsModelValidationFactory factory) {
+            ValidateAttributeType(attributeType);
+            ValidateAttributeFactory(factory);
+
+            _adaptersLock.EnterWriteLock();
+
+            try {
+                AttributeFactories[attributeType] = factory;
+            }
+            finally {
+                _adaptersLock.ExitWriteLock();
+            }
+        }
+
+        public static void RegisterDefaultAdapter(Type adapterType) {
+            ValidateAttributeAdapterType(adapterType);
+            ConstructorInfo constructor = GetAttributeAdapterConstructor(typeof(ValidationAttribute), adapterType);
+
+            DefaultAttributeFactory = (metadata, context, attribute) => (ModelValidator)constructor.Invoke(new object[] { metadata, context, attribute });
+        }
+
+        public static void RegisterDefaultAdapterFactory(DataAnnotationsModelValidationFactory factory) {
+            ValidateAttributeFactory(factory);
+
+            DefaultAttributeFactory = factory;
+        }
+
+        // Helpers 
+
+        private static ConstructorInfo GetAttributeAdapterConstructor(Type attributeType, Type adapterType) {
+            ConstructorInfo constructor = adapterType.GetConstructor(new[] { typeof(ModelMetadata), typeof(ControllerContext), attributeType });
+            if (constructor == null) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.DataAnnotationsModelValidatorProvider_ConstructorRequirements,
+                        adapterType.FullName,
+                        typeof(ModelMetadata).FullName,
+                        typeof(ControllerContext).FullName,
+                        attributeType.FullName
+                    ),
+                    "adapterType"
+                );
+            }
+
+            return constructor;
+        }
+
+        private static void ValidateAttributeAdapterType(Type adapterType) {
+            if (adapterType == null) {
+                throw new ArgumentNullException("adapterType");
+            }
+            if (!typeof(ModelValidator).IsAssignableFrom(adapterType)) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.Common_TypeMustDriveFromType,
+                        adapterType.FullName,
+                        typeof(ModelValidator).FullName
+                    ),
+                    "adapterType"
+                );
+            }
+        }
+
+        private static void ValidateAttributeType(Type attributeType) {
+            if (attributeType == null) {
+                throw new ArgumentNullException("attributeType");
+            }
+            if (!typeof(ValidationAttribute).IsAssignableFrom(attributeType)) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.Common_TypeMustDriveFromType,
+                        attributeType.FullName,
+                        typeof(ValidationAttribute).FullName
+                    ),
+                    "attributeType");
+            }
+        }
+
+        private static void ValidateAttributeFactory(DataAnnotationsModelValidationFactory factory) {
+            if (factory == null) {
+                throw new ArgumentNullException("factory");
+            }
+        }
+
+        #endregion
+
+        #region IValidatableObject adapter registration
+
+        /// <summary>
+        /// Registers an adapter type for the given <see cref="modelType"/>, which must
+        /// implement <see cref="IValidatableObject"/>. The adapter type must derive from
+        /// <see cref="ModelValidator"/> and it must contain a public constructor
+        /// which takes two parameters of types <see cref="ModelMetadata"/> and
+        /// <see cref="ControllerContext"/>.
+        /// </summary>
+        public static void RegisterValidatableObjectAdapter(Type modelType, Type adapterType) {
+            ValidateValidatableModelType(modelType);
+            ValidateValidatableAdapterType(adapterType);
+            ConstructorInfo constructor = GetValidatableAdapterConstructor(adapterType);
+
+            _adaptersLock.EnterWriteLock();
+
+            try {
+                ValidatableFactories[modelType] = (metadata, context) => (ModelValidator)constructor.Invoke(new object[] { metadata, context });
+            }
+            finally {
+                _adaptersLock.ExitWriteLock();
+            }
+        }
+
+        /// <summary>
+        /// Registers an adapter factory for the given <see cref="modelType"/>, which must
+        /// implement <see cref="IValidatableObject"/>.
+        /// </summary>
+        public static void RegisterValidatableObjectAdapterFactory(Type modelType, DataAnnotationsValidatableObjectAdapterFactory factory) {
+            ValidateValidatableModelType(modelType);
+            ValidateValidatableFactory(factory);
+
+            _adaptersLock.EnterWriteLock();
+
+            try {
+                ValidatableFactories[modelType] = factory;
+            }
+            finally {
+                _adaptersLock.ExitWriteLock();
+            }
+        }
+
+        /// <summary>
+        /// Registers the default adapter type for objects which implement
+        /// <see cref="IValidatableObject"/>. The adapter type must derive from
+        /// <see cref="ModelValidator"/> and it must contain a public constructor
+        /// which takes two parameters of types <see cref="ModelMetadata"/> and
+        /// <see cref="ControllerContext"/>.
+        /// </summary>
+        public static void RegisterDefaultValidatableObjectAdapter(Type adapterType) {
+            ValidateValidatableAdapterType(adapterType);
+            ConstructorInfo constructor = GetValidatableAdapterConstructor(adapterType);
+
+            DefaultValidatableFactory = (metadata, context) => (ModelValidator)constructor.Invoke(new object[] { metadata, context });
+        }
+
+        /// <summary>
+        /// Registers the default adapter factory for objects which implement
+        /// <see cref="IValidatableObject"/>.
+        /// </summary>
+        public static void RegisterDefaultValidatableObjectAdapterFactory(DataAnnotationsValidatableObjectAdapterFactory factory) {
+            ValidateValidatableFactory(factory);
+
+            DefaultValidatableFactory = factory;
+        }
+
+        // Helpers 
+
+        private static ConstructorInfo GetValidatableAdapterConstructor(Type adapterType) {
+            ConstructorInfo constructor = adapterType.GetConstructor(new[] { typeof(ModelMetadata), typeof(ControllerContext) });
+            if (constructor == null) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.DataAnnotationsModelValidatorProvider_ValidatableConstructorRequirements,
+                        adapterType.FullName,
+                        typeof(ModelMetadata).FullName,
+                        typeof(ControllerContext).FullName
+                    ),
+                    "adapterType"
+                );
+            }
+
+            return constructor;
+        }
+
+        private static void ValidateValidatableAdapterType(Type adapterType) {
+            if (adapterType == null) {
+                throw new ArgumentNullException("adapterType");
+            }
+            if (!typeof(ModelValidator).IsAssignableFrom(adapterType)) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.Common_TypeMustDriveFromType,
+                        adapterType.FullName,
+                        typeof(ModelValidator).FullName
+                    ),
+                    "adapterType");
+            }
+        }
+
+        private static void ValidateValidatableModelType(Type modelType) {
+            if (modelType == null) {
+                throw new ArgumentNullException("modelType");
+            }
+            if (!typeof(IValidatableObject).IsAssignableFrom(modelType)) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.Common_TypeMustDriveFromType,
+                        modelType.FullName,
+                        typeof(IValidatableObject).FullName
+                    ),
+                    "modelType"
+                );
+            }
+        }
+
+        private static void ValidateValidatableFactory(DataAnnotationsValidatableObjectAdapterFactory factory) {
+            if (factory == null) {
+                throw new ArgumentNullException("factory");
+            }
+        }
+
+        #endregion
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelValidator`1.cs b/mcs/class/System.Web.Mvc3/Mvc/DataAnnotationsModelValidator`1.cs
new file mode 100644 (file)
index 0000000..b29def9
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System.ComponentModel.DataAnnotations;
+
+    public class DataAnnotationsModelValidator<TAttribute> : DataAnnotationsModelValidator where TAttribute : ValidationAttribute {
+        public DataAnnotationsModelValidator(ModelMetadata metadata, ControllerContext context, TAttribute attribute)
+            : base(metadata, context, attribute) { }
+
+        protected new TAttribute Attribute {
+            get {
+                return (TAttribute)base.Attribute;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DataErrorInfoModelValidatorProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/DataErrorInfoModelValidatorProvider.cs
new file mode 100644 (file)
index 0000000..6ef1026
--- /dev/null
@@ -0,0 +1,75 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.Linq;
+
+    public class DataErrorInfoModelValidatorProvider : ModelValidatorProvider {
+
+        public override IEnumerable<ModelValidator> GetValidators(ModelMetadata metadata, ControllerContext context) {
+            if (metadata == null) {
+                throw new ArgumentNullException("metadata");
+            }
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+
+            return GetValidatorsImpl(metadata, context);
+        }
+
+        private static IEnumerable<ModelValidator> GetValidatorsImpl(ModelMetadata metadata, ControllerContext context) {
+            // If the metadata describes a model that implements IDataErrorInfo, we should call its
+            // Error property at the appropriate time.
+            if (TypeImplementsIDataErrorInfo(metadata.ModelType)) {
+                yield return new DataErrorInfoClassModelValidator(metadata, context);
+            }
+
+            // If the metadata describes a property of a container that implements IDataErrorInfo,
+            // we should call its Item indexer at the appropriate time.
+            if (TypeImplementsIDataErrorInfo(metadata.ContainerType)) {
+                yield return new DataErrorInfoPropertyModelValidator(metadata, context);
+            }
+        }
+
+        private static bool TypeImplementsIDataErrorInfo(Type type) {
+            return typeof(IDataErrorInfo).IsAssignableFrom(type);
+        }
+
+        internal sealed class DataErrorInfoClassModelValidator : ModelValidator {
+            public DataErrorInfoClassModelValidator(ModelMetadata metadata, ControllerContext controllerContext)
+                : base(metadata, controllerContext) {
+            }
+            public override IEnumerable<ModelValidationResult> Validate(object container) {
+                IDataErrorInfo castModel = Metadata.Model as IDataErrorInfo;
+                if (castModel != null) {
+                    string errorMessage = castModel.Error;
+                    if (!String.IsNullOrEmpty(errorMessage)) {
+                        return new ModelValidationResult[] {
+                            new ModelValidationResult() { Message = errorMessage }
+                        };
+                    }
+                }
+                return Enumerable.Empty<ModelValidationResult>();
+            }
+        }
+
+        internal sealed class DataErrorInfoPropertyModelValidator : ModelValidator {
+            public DataErrorInfoPropertyModelValidator(ModelMetadata metadata, ControllerContext controllerContext)
+                : base(metadata, controllerContext) {
+            }
+            public override IEnumerable<ModelValidationResult> Validate(object container) {
+                IDataErrorInfo castContainer = container as IDataErrorInfo;
+                if (castContainer != null && !String.Equals(Metadata.PropertyName, "error", StringComparison.OrdinalIgnoreCase)) {
+                    string errorMessage = castContainer[Metadata.PropertyName];
+                    if (!String.IsNullOrEmpty(errorMessage)) {
+                        return new ModelValidationResult[] {
+                            new ModelValidationResult() { Message = errorMessage }
+                        };
+                    }
+                }
+                return Enumerable.Empty<ModelValidationResult>();
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DataTypeUtil.cs b/mcs/class/System.Web.Mvc3/Mvc/DataTypeUtil.cs
new file mode 100644 (file)
index 0000000..181b036
--- /dev/null
@@ -0,0 +1,64 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.ComponentModel.DataAnnotations;
+
+    internal static class DataTypeUtil {
+        internal static readonly string CurrencyTypeName = DataType.Currency.ToString();
+        internal static readonly string DateTypeName = DataType.Date.ToString();
+        internal static readonly string DateTimeTypeName = DataType.DateTime.ToString();
+        internal static readonly string DurationTypeName = DataType.Duration.ToString();
+        internal static readonly string EmailAddressTypeName = DataType.EmailAddress.ToString();
+        internal static readonly string HtmlTypeName = DataType.Html.ToString();
+        internal static readonly string ImageUrlTypeName = DataType.ImageUrl.ToString();
+        internal static readonly string MultiLineTextTypeName = DataType.MultilineText.ToString();
+        internal static readonly string PasswordTypeName = DataType.Password.ToString();
+        internal static readonly string PhoneNumberTypeName = DataType.PhoneNumber.ToString();
+        internal static readonly string TextTypeName = DataType.Text.ToString();
+        internal static readonly string TimeTypeName = DataType.Time.ToString();
+        internal static readonly string UrlTypeName = DataType.Url.ToString();
+
+        // This is a faster version of GetDataTypeName(). It internally calls ToString() on the enum
+        // value, which can be quite slow because of value verification.
+        internal static string ToDataTypeName(this DataTypeAttribute attribute, Func<DataTypeAttribute, Boolean> isDataType = null) {
+            if (isDataType == null) {
+                isDataType = t => t.GetType().Equals(typeof(DataTypeAttribute));
+            }
+
+            // GetDataTypeName is virtual, so this is only safe if they haven't derived from DataTypeAttribute.
+            // However, if they derive from DataTypeAttribute, they can help their own perf by overriding GetDataTypeName
+            // and returning an appropriate string without invoking the ToString() on the enum.
+            if (isDataType(attribute)) {
+                switch (attribute.DataType) {
+                    case DataType.Currency:
+                        return CurrencyTypeName;
+                    case DataType.Date:
+                        return DateTypeName;
+                    case DataType.DateTime:
+                        return DateTimeTypeName;
+                    case DataType.Duration:
+                        return DurationTypeName;
+                    case DataType.EmailAddress:
+                        return EmailAddressTypeName;
+                    case DataType.Html:
+                        return HtmlTypeName;
+                    case DataType.ImageUrl:
+                        return ImageUrlTypeName;
+                    case DataType.MultilineText:
+                        return MultiLineTextTypeName;
+                    case DataType.Password:
+                        return PasswordTypeName;
+                    case DataType.PhoneNumber:
+                        return PhoneNumberTypeName;
+                    case DataType.Text:
+                        return TextTypeName;
+                    case DataType.Time:
+                        return TimeTypeName;
+                    case DataType.Url:
+                        return UrlTypeName;
+                }
+            }
+
+            return attribute.GetDataTypeName();
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DefaultControllerFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/DefaultControllerFactory.cs
new file mode 100644 (file)
index 0000000..e91c9eb
--- /dev/null
@@ -0,0 +1,260 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Concurrent;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.Linq;
+    using System.Text;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+    using System.Web.SessionState;
+
+    public class DefaultControllerFactory : IControllerFactory {
+        private IBuildManager _buildManager;
+        private IResolver<IControllerActivator> _activatorResolver;
+        private IControllerActivator _controllerActivator;
+        private ControllerBuilder _controllerBuilder;
+        private ControllerTypeCache _instanceControllerTypeCache;
+        private static readonly ConcurrentDictionary<Type, SessionStateBehavior> _sessionStateCache = new ConcurrentDictionary<Type, SessionStateBehavior>();
+        private static ControllerTypeCache _staticControllerTypeCache = new ControllerTypeCache();
+
+        public DefaultControllerFactory()
+            : this(null, null, null) {
+        }
+
+        public DefaultControllerFactory(IControllerActivator controllerActivator)
+            : this(controllerActivator, null, null) {
+        }
+
+        internal DefaultControllerFactory(IControllerActivator controllerActivator, IResolver<IControllerActivator> activatorResolver, IDependencyResolver dependencyResolver) {
+            if (controllerActivator != null) {
+                _controllerActivator = controllerActivator;
+            }
+            else {
+                _activatorResolver = activatorResolver ?? new SingleServiceResolver<IControllerActivator>(
+                    () => null,
+                    new DefaultControllerActivator(dependencyResolver),
+                    "DefaultControllerFactory contstructor"
+                );
+            }
+        }
+
+        private IControllerActivator ControllerActivator {
+            get {
+                if (_controllerActivator != null) {
+                    return _controllerActivator;
+                }
+                _controllerActivator = _activatorResolver.Current;
+                return _controllerActivator;
+            }
+        }
+
+        internal IBuildManager BuildManager {
+            get {
+                if (_buildManager == null) {
+                    _buildManager = new BuildManagerWrapper();
+                }
+                return _buildManager;
+            }
+            set {
+                _buildManager = value;
+            }
+        }
+
+        internal ControllerBuilder ControllerBuilder {
+            get {
+                return _controllerBuilder ?? ControllerBuilder.Current;
+            }
+            set {
+                _controllerBuilder = value;
+            }
+        }
+
+        internal ControllerTypeCache ControllerTypeCache {
+            get {
+                return _instanceControllerTypeCache ?? _staticControllerTypeCache;
+            }
+            set {
+                _instanceControllerTypeCache = value;
+            }
+        }
+
+        internal static InvalidOperationException CreateAmbiguousControllerException(RouteBase route, string controllerName, ICollection<Type> matchingTypes) {
+            // we need to generate an exception containing all the controller types
+            StringBuilder typeList = new StringBuilder();
+            foreach (Type matchedType in matchingTypes) {
+                typeList.AppendLine();
+                typeList.Append(matchedType.FullName);
+            }
+
+            string errorText;
+            Route castRoute = route as Route;
+            if (castRoute != null) {
+                errorText = String.Format(CultureInfo.CurrentCulture, MvcResources.DefaultControllerFactory_ControllerNameAmbiguous_WithRouteUrl,
+                    controllerName, castRoute.Url, typeList);
+            }
+            else {
+                errorText = String.Format(CultureInfo.CurrentCulture, MvcResources.DefaultControllerFactory_ControllerNameAmbiguous_WithoutRouteUrl,
+                    controllerName, typeList);
+            }
+
+            return new InvalidOperationException(errorText);
+        }
+
+        public virtual IController CreateController(RequestContext requestContext, string controllerName) {
+            if (requestContext == null) {
+                throw new ArgumentNullException("requestContext");
+            }
+            if (String.IsNullOrEmpty(controllerName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "controllerName");
+            }
+            Type controllerType = GetControllerType(requestContext, controllerName);
+            IController controller = GetControllerInstance(requestContext, controllerType);
+            return controller;
+        }
+
+        protected internal virtual IController GetControllerInstance(RequestContext requestContext, Type controllerType) {
+            if (controllerType == null) {
+                throw new HttpException(404,
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.DefaultControllerFactory_NoControllerFound,
+                        requestContext.HttpContext.Request.Path));
+            }
+            if (!typeof(IController).IsAssignableFrom(controllerType)) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.DefaultControllerFactory_TypeDoesNotSubclassControllerBase,
+                        controllerType),
+                    "controllerType");
+            }
+            return ControllerActivator.Create(requestContext, controllerType);
+        }
+
+        protected internal virtual SessionStateBehavior GetControllerSessionBehavior(RequestContext requestContext, Type controllerType) {
+            if (controllerType == null) {
+                return SessionStateBehavior.Default;
+            }
+
+            return _sessionStateCache.GetOrAdd(
+                controllerType,
+                type =>
+                {
+                    var attr = type.GetCustomAttributes(typeof(SessionStateAttribute), inherit: true)
+                                   .OfType<SessionStateAttribute>()
+                                   .FirstOrDefault();
+
+                    return (attr != null) ? attr.Behavior : SessionStateBehavior.Default;
+                }
+            );
+        }
+
+        protected internal virtual Type GetControllerType(RequestContext requestContext, string controllerName) {
+            if (String.IsNullOrEmpty(controllerName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "controllerName");
+            }
+
+            // first search in the current route's namespace collection
+            object routeNamespacesObj;
+            Type match;
+            if (requestContext != null && requestContext.RouteData.DataTokens.TryGetValue("Namespaces", out routeNamespacesObj)) {
+                IEnumerable<string> routeNamespaces = routeNamespacesObj as IEnumerable<string>;
+                if (routeNamespaces != null && routeNamespaces.Any()) {
+                    HashSet<string> nsHash = new HashSet<string>(routeNamespaces, StringComparer.OrdinalIgnoreCase);
+                    match = GetControllerTypeWithinNamespaces(requestContext.RouteData.Route, controllerName, nsHash);
+
+                    // the UseNamespaceFallback key might not exist, in which case its value is implicitly "true"
+                    if (match != null || false.Equals(requestContext.RouteData.DataTokens["UseNamespaceFallback"])) {
+                        // got a match or the route requested we stop looking
+                        return match;
+                    }
+                }
+            }
+
+            // then search in the application's default namespace collection
+            if (ControllerBuilder.DefaultNamespaces.Count > 0) {
+                HashSet<string> nsDefaults = new HashSet<string>(ControllerBuilder.DefaultNamespaces, StringComparer.OrdinalIgnoreCase);
+                match = GetControllerTypeWithinNamespaces(requestContext.RouteData.Route, controllerName, nsDefaults);
+                if (match != null) {
+                    return match;
+                }
+            }
+
+            // if all else fails, search every namespace
+            return GetControllerTypeWithinNamespaces(requestContext.RouteData.Route, controllerName, null /* namespaces */);
+        }
+
+        private Type GetControllerTypeWithinNamespaces(RouteBase route, string controllerName, HashSet<string> namespaces) {
+            // Once the master list of controllers has been created we can quickly index into it
+            ControllerTypeCache.EnsureInitialized(BuildManager);
+
+            ICollection<Type> matchingTypes = ControllerTypeCache.GetControllerTypes(controllerName, namespaces);
+            switch (matchingTypes.Count) {
+                case 0:
+                    // no matching types
+                    return null;
+
+                case 1:
+                    // single matching type
+                    return matchingTypes.First();
+
+                default:
+                    // multiple matching types
+                    throw CreateAmbiguousControllerException(route, controllerName, matchingTypes);
+            }
+        }
+
+        public virtual void ReleaseController(IController controller) {
+            IDisposable disposable = controller as IDisposable;
+            if (disposable != null) {
+                disposable.Dispose();
+            }
+        }
+
+        SessionStateBehavior IControllerFactory.GetControllerSessionBehavior(RequestContext requestContext, string controllerName) {
+            if (requestContext == null) {
+                throw new ArgumentNullException("requestContext");
+            }
+            if (String.IsNullOrEmpty(controllerName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "controllerName");
+            }
+
+            Type controllerType = GetControllerType(requestContext, controllerName);
+            return GetControllerSessionBehavior(requestContext, controllerType);
+        }
+
+        private class DefaultControllerActivator : IControllerActivator {
+            Func<IDependencyResolver> _resolverThunk;
+
+            public DefaultControllerActivator()
+                : this(null) {
+            }
+
+            public DefaultControllerActivator(IDependencyResolver resolver) {
+                if (resolver == null) {
+                    _resolverThunk = () => DependencyResolver.Current;
+                }
+                else {
+                    _resolverThunk = () => resolver;
+                }
+            }
+
+            public IController Create(RequestContext requestContext, Type controllerType) {
+                try {
+                    return (IController)(_resolverThunk().GetService(controllerType) ?? Activator.CreateInstance(controllerType));
+                }
+                catch (Exception ex) {
+                    throw new InvalidOperationException(
+                        String.Format(
+                            CultureInfo.CurrentCulture,
+                            MvcResources.DefaultControllerFactory_ErrorCreatingController,
+                            controllerType),
+                        ex);
+                }
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DefaultModelBinder.cs b/mcs/class/System.Web.Mvc3/Mvc/DefaultModelBinder.cs
new file mode 100644 (file)
index 0000000..065e3ad
--- /dev/null
@@ -0,0 +1,706 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq;
+    using System.Reflection;
+    using System.Runtime.CompilerServices;
+    using System.Web.Mvc.Resources;
+
+    public class DefaultModelBinder : IModelBinder {
+
+        private ModelBinderDictionary _binders;
+        private static string _resourceClassKey;
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "Property is settable so that the dictionary can be provided for unit testing purposes.")]
+        protected internal ModelBinderDictionary Binders {
+            get {
+                if (_binders == null) {
+                    _binders = ModelBinders.Binders;
+                }
+                return _binders;
+            }
+            set {
+                _binders = value;
+            }
+        }
+
+        public static string ResourceClassKey {
+            get {
+                return _resourceClassKey ?? String.Empty;
+            }
+            set {
+                _resourceClassKey = value;
+            }
+        }
+
+        private static void AddValueRequiredMessageToModelState(ControllerContext controllerContext, ModelStateDictionary modelState, string modelStateKey, Type elementType, object value) {
+            if (value == null && !TypeHelpers.TypeAllowsNullValue(elementType) && modelState.IsValidField(modelStateKey)) {
+                modelState.AddModelError(modelStateKey, GetValueRequiredResource(controllerContext));
+            }
+        }
+
+        internal void BindComplexElementalModel(ControllerContext controllerContext, ModelBindingContext bindingContext, object model) {
+            // need to replace the property filter + model object and create an inner binding context
+            ModelBindingContext newBindingContext = CreateComplexElementalModelBindingContext(controllerContext, bindingContext, model);
+
+            // validation
+            if (OnModelUpdating(controllerContext, newBindingContext)) {
+                BindProperties(controllerContext, newBindingContext);
+                OnModelUpdated(controllerContext, newBindingContext);
+            }
+        }
+
+        internal object BindComplexModel(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            object model = bindingContext.Model;
+            Type modelType = bindingContext.ModelType;
+
+            // if we're being asked to create an array, create a list instead, then coerce to an array after the list is created
+            if (model == null && modelType.IsArray) {
+                Type elementType = modelType.GetElementType();
+                Type listType = typeof(List<>).MakeGenericType(elementType);
+                object collection = CreateModel(controllerContext, bindingContext, listType);
+
+                ModelBindingContext arrayBindingContext = new ModelBindingContext() {
+                    ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(() => collection, listType),
+                    ModelName = bindingContext.ModelName,
+                    ModelState = bindingContext.ModelState,
+                    PropertyFilter = bindingContext.PropertyFilter,
+                    ValueProvider = bindingContext.ValueProvider
+                };
+                IList list = (IList)UpdateCollection(controllerContext, arrayBindingContext, elementType);
+
+                if (list == null) {
+                    return null;
+                }
+
+                Array array = Array.CreateInstance(elementType, list.Count);
+                list.CopyTo(array, 0);
+                return array;
+            }
+
+            if (model == null) {
+                model = CreateModel(controllerContext, bindingContext, modelType);
+            }
+
+            // special-case IDictionary<,> and ICollection<>
+            Type dictionaryType = TypeHelpers.ExtractGenericInterface(modelType, typeof(IDictionary<,>));
+            if (dictionaryType != null) {
+                Type[] genericArguments = dictionaryType.GetGenericArguments();
+                Type keyType = genericArguments[0];
+                Type valueType = genericArguments[1];
+
+                ModelBindingContext dictionaryBindingContext = new ModelBindingContext() {
+                    ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(() => model, modelType),
+                    ModelName = bindingContext.ModelName,
+                    ModelState = bindingContext.ModelState,
+                    PropertyFilter = bindingContext.PropertyFilter,
+                    ValueProvider = bindingContext.ValueProvider
+                };
+                object dictionary = UpdateDictionary(controllerContext, dictionaryBindingContext, keyType, valueType);
+                return dictionary;
+            }
+
+            Type enumerableType = TypeHelpers.ExtractGenericInterface(modelType, typeof(IEnumerable<>));
+            if (enumerableType != null) {
+                Type elementType = enumerableType.GetGenericArguments()[0];
+
+                Type collectionType = typeof(ICollection<>).MakeGenericType(elementType);
+                if (collectionType.IsInstanceOfType(model)) {
+                    ModelBindingContext collectionBindingContext = new ModelBindingContext() {
+                        ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(() => model, modelType),
+                        ModelName = bindingContext.ModelName,
+                        ModelState = bindingContext.ModelState,
+                        PropertyFilter = bindingContext.PropertyFilter,
+                        ValueProvider = bindingContext.ValueProvider
+                    };
+                    object collection = UpdateCollection(controllerContext, collectionBindingContext, elementType);
+                    return collection;
+                }
+            }
+
+            // otherwise, just update the properties on the complex type
+            BindComplexElementalModel(controllerContext, bindingContext, model);
+            return model;
+        }
+
+        public virtual object BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            if (bindingContext == null) {
+                throw new ArgumentNullException("bindingContext");
+            }
+
+            bool performedFallback = false;
+
+            if (!String.IsNullOrEmpty(bindingContext.ModelName) && !bindingContext.ValueProvider.ContainsPrefix(bindingContext.ModelName)) {
+                // We couldn't find any entry that began with the prefix. If this is the top-level element, fall back
+                // to the empty prefix.
+                if (bindingContext.FallbackToEmptyPrefix) {
+                    bindingContext = new ModelBindingContext() {
+                        ModelMetadata = bindingContext.ModelMetadata,
+                        ModelState = bindingContext.ModelState,
+                        PropertyFilter = bindingContext.PropertyFilter,
+                        ValueProvider = bindingContext.ValueProvider
+                    };
+                    performedFallback = true;
+                }
+                else {
+                    return null;
+                }
+            }
+
+            // Simple model = int, string, etc.; determined by calling TypeConverter.CanConvertFrom(typeof(string))
+            // or by seeing if a value in the request exactly matches the name of the model we're binding.
+            // Complex type = everything else.
+            if (!performedFallback) {
+                bool performRequestValidation = ShouldPerformRequestValidation(controllerContext, bindingContext);
+                ValueProviderResult vpResult = bindingContext.UnvalidatedValueProvider.GetValue(bindingContext.ModelName, skipValidation: !performRequestValidation);
+                if (vpResult != null) {
+                    return BindSimpleModel(controllerContext, bindingContext, vpResult);
+                }
+            }
+            if (!bindingContext.ModelMetadata.IsComplexType) {
+                return null;
+            }
+
+            return BindComplexModel(controllerContext, bindingContext);
+        }
+
+        private void BindProperties(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            IEnumerable<PropertyDescriptor> properties = GetFilteredModelProperties(controllerContext, bindingContext);
+            foreach (PropertyDescriptor property in properties) {
+                BindProperty(controllerContext, bindingContext, property);
+            }
+        }
+
+        protected virtual void BindProperty(ControllerContext controllerContext, ModelBindingContext bindingContext, PropertyDescriptor propertyDescriptor) {
+            // need to skip properties that aren't part of the request, else we might hit a StackOverflowException
+            string fullPropertyKey = CreateSubPropertyName(bindingContext.ModelName, propertyDescriptor.Name);
+            if (!bindingContext.ValueProvider.ContainsPrefix(fullPropertyKey)) {
+                return;
+            }
+
+            // call into the property's model binder
+            IModelBinder propertyBinder = Binders.GetBinder(propertyDescriptor.PropertyType);
+            object originalPropertyValue = propertyDescriptor.GetValue(bindingContext.Model);
+            ModelMetadata propertyMetadata = bindingContext.PropertyMetadata[propertyDescriptor.Name];
+            propertyMetadata.Model = originalPropertyValue;
+            ModelBindingContext innerBindingContext = new ModelBindingContext() {
+                ModelMetadata = propertyMetadata,
+                ModelName = fullPropertyKey,
+                ModelState = bindingContext.ModelState,
+                ValueProvider = bindingContext.ValueProvider
+            };
+            object newPropertyValue = GetPropertyValue(controllerContext, innerBindingContext, propertyDescriptor, propertyBinder);
+            propertyMetadata.Model = newPropertyValue;
+
+            // validation
+            ModelState modelState = bindingContext.ModelState[fullPropertyKey];
+            if (modelState == null || modelState.Errors.Count == 0) {
+                if (OnPropertyValidating(controllerContext, bindingContext, propertyDescriptor, newPropertyValue)) {
+                    SetProperty(controllerContext, bindingContext, propertyDescriptor, newPropertyValue);
+                    OnPropertyValidated(controllerContext, bindingContext, propertyDescriptor, newPropertyValue);
+                }
+            }
+            else {
+                SetProperty(controllerContext, bindingContext, propertyDescriptor, newPropertyValue);
+
+                // Convert FormatExceptions (type conversion failures) into InvalidValue messages
+                foreach (ModelError error in modelState.Errors.Where(err => String.IsNullOrEmpty(err.ErrorMessage) && err.Exception != null).ToList()) {
+                    for (Exception exception = error.Exception; exception != null; exception = exception.InnerException) {
+                        if (exception is FormatException) {
+                            string displayName = propertyMetadata.GetDisplayName();
+                            string errorMessageTemplate = GetValueInvalidResource(controllerContext);
+                            string errorMessage = String.Format(CultureInfo.CurrentCulture, errorMessageTemplate, modelState.Value.AttemptedValue, displayName);
+                            modelState.Errors.Remove(error);
+                            modelState.Errors.Add(errorMessage);
+                            break;
+                        }
+                    }
+                }
+            }
+        }
+
+        internal object BindSimpleModel(ControllerContext controllerContext, ModelBindingContext bindingContext, ValueProviderResult valueProviderResult) {
+            bindingContext.ModelState.SetModelValue(bindingContext.ModelName, valueProviderResult);
+
+            // if the value provider returns an instance of the requested data type, we can just short-circuit
+            // the evaluation and return that instance
+            if (bindingContext.ModelType.IsInstanceOfType(valueProviderResult.RawValue)) {
+                return valueProviderResult.RawValue;
+            }
+
+            // since a string is an IEnumerable<char>, we want it to skip the two checks immediately following
+            if (bindingContext.ModelType != typeof(string)) {
+
+                // conversion results in 3 cases, as below
+                if (bindingContext.ModelType.IsArray) {
+                    // case 1: user asked for an array
+                    // ValueProviderResult.ConvertTo() understands array types, so pass in the array type directly
+                    object modelArray = ConvertProviderResult(bindingContext.ModelState, bindingContext.ModelName, valueProviderResult, bindingContext.ModelType);
+                    return modelArray;
+                }
+
+                Type enumerableType = TypeHelpers.ExtractGenericInterface(bindingContext.ModelType, typeof(IEnumerable<>));
+                if (enumerableType != null) {
+                    // case 2: user asked for a collection rather than an array
+                    // need to call ConvertTo() on the array type, then copy the array to the collection
+                    object modelCollection = CreateModel(controllerContext, bindingContext, bindingContext.ModelType);
+                    Type elementType = enumerableType.GetGenericArguments()[0];
+                    Type arrayType = elementType.MakeArrayType();
+                    object modelArray = ConvertProviderResult(bindingContext.ModelState, bindingContext.ModelName, valueProviderResult, arrayType);
+
+                    Type collectionType = typeof(ICollection<>).MakeGenericType(elementType);
+                    if (collectionType.IsInstanceOfType(modelCollection)) {
+                        CollectionHelpers.ReplaceCollection(elementType, modelCollection, modelArray);
+                    }
+                    return modelCollection;
+                }
+            }
+
+            // case 3: user asked for an individual element
+            object model = ConvertProviderResult(bindingContext.ModelState, bindingContext.ModelName, valueProviderResult, bindingContext.ModelType);
+            return model;
+        }
+
+        private static bool CanUpdateReadonlyTypedReference(Type type) {
+            // value types aren't strictly immutable, but because they have copy-by-value semantics
+            // we can't update a value type that is marked readonly
+            if (type.IsValueType) {
+                return false;
+            }
+
+            // arrays are mutable, but because we can't change their length we shouldn't try
+            // to update an array that is referenced readonly
+            if (type.IsArray) {
+                return false;
+            }
+
+            // special-case known common immutable types
+            if (type == typeof(string)) {
+                return false;
+            }
+
+            return true;
+        }
+
+        [SuppressMessage("Microsoft.Globalization", "CA1304:SpecifyCultureInfo", MessageId = "System.Web.Mvc.ValueProviderResult.ConvertTo(System.Type)", Justification = "The target object should make the correct culture determination, not this method.")]
+        [SuppressMessage("Microsoft.Design", "CA1031:DoNotCatchGeneralExceptionTypes", Justification = "We're recording this exception so that we can act on it later.")]
+        private static object ConvertProviderResult(ModelStateDictionary modelState, string modelStateKey, ValueProviderResult valueProviderResult, Type destinationType) {
+            try {
+                object convertedValue = valueProviderResult.ConvertTo(destinationType);
+                return convertedValue;
+            }
+            catch (Exception ex) {
+                modelState.AddModelError(modelStateKey, ex);
+                return null;
+            }
+        }
+
+        internal ModelBindingContext CreateComplexElementalModelBindingContext(ControllerContext controllerContext, ModelBindingContext bindingContext, object model) {
+            BindAttribute bindAttr = (BindAttribute)GetTypeDescriptor(controllerContext, bindingContext).GetAttributes()[typeof(BindAttribute)];
+            Predicate<string> newPropertyFilter = (bindAttr != null)
+                ? propertyName => bindAttr.IsPropertyAllowed(propertyName) && bindingContext.PropertyFilter(propertyName)
+                : bindingContext.PropertyFilter;
+
+            ModelBindingContext newBindingContext = new ModelBindingContext() {
+                ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(() => model, bindingContext.ModelType),
+                ModelName = bindingContext.ModelName,
+                ModelState = bindingContext.ModelState,
+                PropertyFilter = newPropertyFilter,
+                ValueProvider = bindingContext.ValueProvider
+            };
+
+            return newBindingContext;
+        }
+
+        protected virtual object CreateModel(ControllerContext controllerContext, ModelBindingContext bindingContext, Type modelType) {
+            Type typeToCreate = modelType;
+
+            // we can understand some collection interfaces, e.g. IList<>, IDictionary<,>
+            if (modelType.IsGenericType) {
+                Type genericTypeDefinition = modelType.GetGenericTypeDefinition();
+                if (genericTypeDefinition == typeof(IDictionary<,>)) {
+                    typeToCreate = typeof(Dictionary<,>).MakeGenericType(modelType.GetGenericArguments());
+                }
+                else if (genericTypeDefinition == typeof(IEnumerable<>) || genericTypeDefinition == typeof(ICollection<>) || genericTypeDefinition == typeof(IList<>)) {
+                    typeToCreate = typeof(List<>).MakeGenericType(modelType.GetGenericArguments());
+                }
+            }
+
+            // fallback to the type's default constructor
+            return Activator.CreateInstance(typeToCreate);
+        }
+
+        protected static string CreateSubIndexName(string prefix, int index) {
+            return String.Format(CultureInfo.InvariantCulture, "{0}[{1}]", prefix, index);
+        }
+
+        protected static string CreateSubIndexName(string prefix, string index) {
+            return String.Format(CultureInfo.InvariantCulture, "{0}[{1}]", prefix, index);
+        }
+
+        protected internal static string CreateSubPropertyName(string prefix, string propertyName) {
+            if (String.IsNullOrEmpty(prefix)) {
+                return propertyName;
+            }
+            else if (String.IsNullOrEmpty(propertyName)) {
+                return prefix;
+            }
+            else {
+                return prefix + "." + propertyName;
+            }
+        }
+
+        protected IEnumerable<PropertyDescriptor> GetFilteredModelProperties(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            PropertyDescriptorCollection properties = GetModelProperties(controllerContext, bindingContext);
+            Predicate<string> propertyFilter = bindingContext.PropertyFilter;
+
+            return from PropertyDescriptor property in properties
+                   where ShouldUpdateProperty(property, propertyFilter)
+                   select property;
+        }
+
+        [SuppressMessage("Microsoft.Globalization", "CA1304:SpecifyCultureInfo", MessageId = "System.Web.Mvc.ValueProviderResult.ConvertTo(System.Type)", Justification = "ValueProviderResult already handles culture conversion appropriately.")]
+        private static void GetIndexes(ModelBindingContext bindingContext, out bool stopOnIndexNotFound, out IEnumerable<string> indexes) {
+            string indexKey = CreateSubPropertyName(bindingContext.ModelName, "index");
+            ValueProviderResult vpResult = bindingContext.ValueProvider.GetValue(indexKey);
+
+            if (vpResult != null) {
+                string[] indexesArray = vpResult.ConvertTo(typeof(string[])) as string[];
+                if (indexesArray != null) {
+                    stopOnIndexNotFound = false;
+                    indexes = indexesArray;
+                    return;
+                }
+            }
+
+            // just use a simple zero-based system
+            stopOnIndexNotFound = true;
+            indexes = GetZeroBasedIndexes();
+        }
+
+        protected virtual PropertyDescriptorCollection GetModelProperties(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            return GetTypeDescriptor(controllerContext, bindingContext).GetProperties();
+        }
+
+        protected virtual object GetPropertyValue(ControllerContext controllerContext, ModelBindingContext bindingContext, PropertyDescriptor propertyDescriptor, IModelBinder propertyBinder) {
+            object value = propertyBinder.BindModel(controllerContext, bindingContext);
+
+            if (bindingContext.ModelMetadata.ConvertEmptyStringToNull && Object.Equals(value, String.Empty)) {
+                return null;
+            }
+
+            return value;
+        }
+
+        protected virtual ICustomTypeDescriptor GetTypeDescriptor(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            return TypeDescriptorHelper.Get(bindingContext.ModelType);
+        }
+
+        // If the user specified a ResourceClassKey try to load the resource they specified.
+        // If the class key is invalid, an exception will be thrown.
+        // If the class key is valid but the resource is not found, it returns null, in which
+        // case it will fall back to the MVC default error message.
+        private static string GetUserResourceString(ControllerContext controllerContext, string resourceName) {
+            string result = null;
+
+            if (!String.IsNullOrEmpty(ResourceClassKey) && (controllerContext != null) && (controllerContext.HttpContext != null)) {
+                result = controllerContext.HttpContext.GetGlobalResourceObject(ResourceClassKey, resourceName, CultureInfo.CurrentUICulture) as string;
+            }
+
+            return result;
+        }
+
+        private static string GetValueInvalidResource(ControllerContext controllerContext) {
+            return GetUserResourceString(controllerContext, "PropertyValueInvalid") ?? MvcResources.DefaultModelBinder_ValueInvalid;
+        }
+
+        private static string GetValueRequiredResource(ControllerContext controllerContext) {
+            return GetUserResourceString(controllerContext, "PropertyValueRequired") ?? MvcResources.DefaultModelBinder_ValueRequired;
+        }
+
+        private static IEnumerable<string> GetZeroBasedIndexes() {
+            for (int i = 0; ; i++) {
+                yield return i.ToString(CultureInfo.InvariantCulture);
+            }
+        }
+
+        protected static bool IsModelValid(ModelBindingContext bindingContext) {
+            if (bindingContext == null) {
+                throw new ArgumentNullException("bindingContext");
+            }
+            if (String.IsNullOrEmpty(bindingContext.ModelName)) {
+                return bindingContext.ModelState.IsValid;
+            }
+            return bindingContext.ModelState.IsValidField(bindingContext.ModelName);
+        }
+
+        protected virtual void OnModelUpdated(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            Dictionary<string, bool> startedValid = new Dictionary<string, bool>(StringComparer.OrdinalIgnoreCase);
+
+            foreach (ModelValidationResult validationResult in ModelValidator.GetModelValidator(bindingContext.ModelMetadata, controllerContext).Validate(null)) {
+                string subPropertyName = CreateSubPropertyName(bindingContext.ModelName, validationResult.MemberName);
+
+                if (!startedValid.ContainsKey(subPropertyName)) {
+                    startedValid[subPropertyName] = bindingContext.ModelState.IsValidField(subPropertyName);
+                }
+
+                if (startedValid[subPropertyName]) {
+                    bindingContext.ModelState.AddModelError(subPropertyName, validationResult.Message);
+                }
+            }
+        }
+
+        protected virtual bool OnModelUpdating(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            // default implementation does nothing
+            return true;
+        }
+
+        protected virtual void OnPropertyValidated(ControllerContext controllerContext, ModelBindingContext bindingContext, PropertyDescriptor propertyDescriptor, object value) {
+            // default implementation does nothing
+        }
+
+        protected virtual bool OnPropertyValidating(ControllerContext controllerContext, ModelBindingContext bindingContext, PropertyDescriptor propertyDescriptor, object value) {
+            // default implementation does nothing
+            return true;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1031:DoNotCatchGeneralExceptionTypes", Justification = "We're recording this exception so that we can act on it later.")]
+        protected virtual void SetProperty(ControllerContext controllerContext, ModelBindingContext bindingContext, PropertyDescriptor propertyDescriptor, object value) {
+
+            ModelMetadata propertyMetadata = bindingContext.PropertyMetadata[propertyDescriptor.Name];
+            propertyMetadata.Model = value;
+            string modelStateKey = CreateSubPropertyName(bindingContext.ModelName, propertyMetadata.PropertyName);
+
+            // If the value is null, and the validation system can find a Required validator for
+            // us, we'd prefer to run it before we attempt to set the value; otherwise, property
+            // setters which throw on null (f.e., Entity Framework properties which are backed by
+            // non-nullable strings in the DB) will get their error message in ahead of us.
+            //
+            // We are effectively using the special validator -- Required -- as a helper to the
+            // binding system, which is why this code is here instead of in the Validating/Validated
+            // methods, which are really the old-school validation hooks.
+            if (value == null && bindingContext.ModelState.IsValidField(modelStateKey)) {
+                ModelValidator requiredValidator = ModelValidatorProviders.Providers.GetValidators(propertyMetadata, controllerContext).Where(v => v.IsRequired).FirstOrDefault();
+                if (requiredValidator != null) {
+                    foreach (ModelValidationResult validationResult in requiredValidator.Validate(bindingContext.Model)) {
+                        bindingContext.ModelState.AddModelError(modelStateKey, validationResult.Message);
+                    }
+                }
+            }
+
+            bool isNullValueOnNonNullableType =
+                value == null &&
+                !TypeHelpers.TypeAllowsNullValue(propertyDescriptor.PropertyType);
+
+            // Try to set a value into the property unless we know it will fail (read-only
+            // properties and null values with non-nullable types)
+            if (!propertyDescriptor.IsReadOnly && !isNullValueOnNonNullableType) {
+                try {
+                    propertyDescriptor.SetValue(bindingContext.Model, value);
+                }
+                catch (Exception ex) {
+                    // Only add if we're not already invalid
+                    if (bindingContext.ModelState.IsValidField(modelStateKey)) {
+                        bindingContext.ModelState.AddModelError(modelStateKey, ex);
+                    }
+                }
+            }
+
+            // Last chance for an error on null values with non-nullable types, we'll use
+            // the default "A value is required." message.
+            if (isNullValueOnNonNullableType && bindingContext.ModelState.IsValidField(modelStateKey)) {
+                bindingContext.ModelState.AddModelError(modelStateKey, GetValueRequiredResource(controllerContext));
+            }
+        }
+
+        private static bool ShouldPerformRequestValidation(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            if (controllerContext == null || controllerContext.Controller == null || bindingContext == null || bindingContext.ModelMetadata == null) {
+                // To make unit testing easier, if the caller hasn't specified enough contextual information we just default
+                // to always pulling the data from a collection that goes through request validation.
+                return true;
+            }
+
+            // We should perform request validation only if both the controller and the model ask for it. This is the
+            // default behavior for both. If either the controller (via [ValidateInput(false)]) or the model (via [AllowHtml])
+            // opts out, we don't validate.
+            return (controllerContext.Controller.ValidateRequest && bindingContext.ModelMetadata.RequestValidationEnabled);
+        }
+
+        private static bool ShouldUpdateProperty(PropertyDescriptor property, Predicate<string> propertyFilter) {
+            if (property.IsReadOnly && !CanUpdateReadonlyTypedReference(property.PropertyType)) {
+                return false;
+            }
+
+            // if this property is rejected by the filter, move on
+            if (!propertyFilter(property.Name)) {
+                return false;
+            }
+
+            // otherwise, allow
+            return true;
+        }
+
+        internal object UpdateCollection(ControllerContext controllerContext, ModelBindingContext bindingContext, Type elementType) {
+            bool stopOnIndexNotFound;
+            IEnumerable<string> indexes;
+            GetIndexes(bindingContext, out stopOnIndexNotFound, out indexes);
+            IModelBinder elementBinder = Binders.GetBinder(elementType);
+
+            // build up a list of items from the request
+            List<object> modelList = new List<object>();
+            foreach (string currentIndex in indexes) {
+                string subIndexKey = CreateSubIndexName(bindingContext.ModelName, currentIndex);
+                if (!bindingContext.ValueProvider.ContainsPrefix(subIndexKey)) {
+                    if (stopOnIndexNotFound) {
+                        // we ran out of elements to pull
+                        break;
+                    }
+                    else {
+                        continue;
+                    }
+                }
+
+                ModelBindingContext innerContext = new ModelBindingContext() {
+                    ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(null, elementType),
+                    ModelName = subIndexKey,
+                    ModelState = bindingContext.ModelState,
+                    PropertyFilter = bindingContext.PropertyFilter,
+                    ValueProvider = bindingContext.ValueProvider
+                };
+                object thisElement = elementBinder.BindModel(controllerContext, innerContext);
+
+                // we need to merge model errors up
+                AddValueRequiredMessageToModelState(controllerContext, bindingContext.ModelState, subIndexKey, elementType, thisElement);
+                modelList.Add(thisElement);
+            }
+
+            // if there weren't any elements at all in the request, just return
+            if (modelList.Count == 0) {
+                return null;
+            }
+
+            // replace the original collection
+            object collection = bindingContext.Model;
+            CollectionHelpers.ReplaceCollection(elementType, collection, modelList);
+            return collection;
+        }
+
+        internal object UpdateDictionary(ControllerContext controllerContext, ModelBindingContext bindingContext, Type keyType, Type valueType) {
+            bool stopOnIndexNotFound;
+            IEnumerable<string> indexes;
+            GetIndexes(bindingContext, out stopOnIndexNotFound, out indexes);
+
+            IModelBinder keyBinder = Binders.GetBinder(keyType);
+            IModelBinder valueBinder = Binders.GetBinder(valueType);
+
+            // build up a list of items from the request
+            List<KeyValuePair<object, object>> modelList = new List<KeyValuePair<object, object>>();
+            foreach (string currentIndex in indexes) {
+                string subIndexKey = CreateSubIndexName(bindingContext.ModelName, currentIndex);
+                string keyFieldKey = CreateSubPropertyName(subIndexKey, "key");
+                string valueFieldKey = CreateSubPropertyName(subIndexKey, "value");
+
+                if (!(bindingContext.ValueProvider.ContainsPrefix(keyFieldKey) && bindingContext.ValueProvider.ContainsPrefix(valueFieldKey))) {
+                    if (stopOnIndexNotFound) {
+                        // we ran out of elements to pull
+                        break;
+                    }
+                    else {
+                        continue;
+                    }
+                }
+
+                // bind the key
+                ModelBindingContext keyBindingContext = new ModelBindingContext() {
+                    ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(null, keyType),
+                    ModelName = keyFieldKey,
+                    ModelState = bindingContext.ModelState,
+                    ValueProvider = bindingContext.ValueProvider
+                };
+                object thisKey = keyBinder.BindModel(controllerContext, keyBindingContext);
+
+                // we need to merge model errors up
+                AddValueRequiredMessageToModelState(controllerContext, bindingContext.ModelState, keyFieldKey, keyType, thisKey);
+                if (!keyType.IsInstanceOfType(thisKey)) {
+                    // we can't add an invalid key, so just move on
+                    continue;
+                }
+
+                // bind the value
+                ModelBindingContext valueBindingContext = new ModelBindingContext() {
+                    ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(null, valueType),
+                    ModelName = valueFieldKey,
+                    ModelState = bindingContext.ModelState,
+                    PropertyFilter = bindingContext.PropertyFilter,
+                    ValueProvider = bindingContext.ValueProvider
+                };
+                object thisValue = valueBinder.BindModel(controllerContext, valueBindingContext);
+
+                // we need to merge model errors up
+                AddValueRequiredMessageToModelState(controllerContext, bindingContext.ModelState, valueFieldKey, valueType, thisValue);
+                KeyValuePair<object, object> kvp = new KeyValuePair<object, object>(thisKey, thisValue);
+                modelList.Add(kvp);
+            }
+
+            // if there weren't any elements at all in the request, just return
+            if (modelList.Count == 0) {
+                return null;
+            }
+
+            // replace the original collection
+            object dictionary = bindingContext.Model;
+            CollectionHelpers.ReplaceDictionary(keyType, valueType, dictionary, modelList);
+            return dictionary;
+        }
+
+        // This helper type is used because we're working with strongly-typed collections, but we don't know the Ts
+        // ahead of time. By using the generic methods below, we can consolidate the collection-specific code in a
+        // single helper type rather than having reflection-based calls spread throughout the DefaultModelBinder type.
+        // There is a single point of entry to each of the methods below, so they're fairly simple to maintain.
+
+        private static class CollectionHelpers {
+
+            private static readonly MethodInfo _replaceCollectionMethod = typeof(CollectionHelpers).GetMethod("ReplaceCollectionImpl", BindingFlags.Static | BindingFlags.NonPublic);
+            private static readonly MethodInfo _replaceDictionaryMethod = typeof(CollectionHelpers).GetMethod("ReplaceDictionaryImpl", BindingFlags.Static | BindingFlags.NonPublic);
+
+            [MethodImpl(MethodImplOptions.NoInlining | MethodImplOptions.NoOptimization)]
+            public static void ReplaceCollection(Type collectionType, object collection, object newContents) {
+                MethodInfo targetMethod = _replaceCollectionMethod.MakeGenericMethod(collectionType);
+                targetMethod.Invoke(null, new object[] { collection, newContents });
+            }
+
+            private static void ReplaceCollectionImpl<T>(ICollection<T> collection, IEnumerable newContents) {
+                collection.Clear();
+                if (newContents != null) {
+                    foreach (object item in newContents) {
+                        // if the item was not a T, some conversion failed. the error message will be propagated,
+                        // but in the meanwhile we need to make a placeholder element in the array.
+                        T castItem = (item is T) ? (T)item : default(T);
+                        collection.Add(castItem);
+                    }
+                }
+            }
+
+            [MethodImpl(MethodImplOptions.NoInlining | MethodImplOptions.NoOptimization)]
+            public static void ReplaceDictionary(Type keyType, Type valueType, object dictionary, object newContents) {
+                MethodInfo targetMethod = _replaceDictionaryMethod.MakeGenericMethod(keyType, valueType);
+                targetMethod.Invoke(null, new object[] { dictionary, newContents });
+            }
+
+            private static void ReplaceDictionaryImpl<TKey, TValue>(IDictionary<TKey, TValue> dictionary, IEnumerable<KeyValuePair<object, object>> newContents) {
+                dictionary.Clear();
+                foreach (KeyValuePair<object, object> item in newContents) {
+                    // if the item was not a T, some conversion failed. the error message will be propagated,
+                    // but in the meanwhile we need to make a placeholder element in the dictionary.
+                    TKey castKey = (TKey)item.Key; // this cast shouldn't fail
+                    TValue castValue = (item.Value is TValue) ? (TValue)item.Value : default(TValue);
+                    dictionary[castKey] = castValue;
+                }
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DefaultViewLocationCache.cs b/mcs/class/System.Web.Mvc3/Mvc/DefaultViewLocationCache.cs
new file mode 100644 (file)
index 0000000..2f1232a
--- /dev/null
@@ -0,0 +1,45 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web.Caching;
+    using System.Web.Mvc.Resources;
+
+    public class DefaultViewLocationCache : IViewLocationCache {
+        private static readonly TimeSpan _defaultTimeSpan = new TimeSpan(0, 15, 0);
+
+        public DefaultViewLocationCache()
+            : this(_defaultTimeSpan) {
+        }
+
+        public DefaultViewLocationCache(TimeSpan timeSpan) {
+            if (timeSpan.Ticks < 0) {
+                throw new InvalidOperationException(MvcResources.DefaultViewLocationCache_NegativeTimeSpan);
+            }
+            TimeSpan = timeSpan;
+        }
+
+        [SuppressMessage("Microsoft.Security", "CA2104:DoNotDeclareReadOnlyMutableReferenceTypes", Justification = "The reference type is immutable. ")]
+        public static readonly IViewLocationCache Null = new NullViewLocationCache();
+
+        public TimeSpan TimeSpan {
+            get;
+            private set;
+        }
+
+        #region IViewLocationCache Members
+        public string GetViewLocation(HttpContextBase httpContext, string key) {
+            if (httpContext == null) {
+                throw new ArgumentNullException("httpContext");
+            }
+            return (string)httpContext.Cache[key];
+        }
+
+        public void InsertViewLocation(HttpContextBase httpContext, string key, string virtualPath) {
+            if (httpContext == null) {
+                throw new ArgumentNullException("httpContext");
+            }
+            httpContext.Cache.Insert(key, virtualPath, null /* dependencies */, Cache.NoAbsoluteExpiration, TimeSpan);
+        }
+        #endregion
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DependencyResolver.cs b/mcs/class/System.Web.Mvc3/Mvc/DependencyResolver.cs
new file mode 100644 (file)
index 0000000..f61ccf8
--- /dev/null
@@ -0,0 +1,134 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    public class DependencyResolver {
+        // Static accessors
+
+        private static DependencyResolver _instance = new DependencyResolver();
+
+        public static IDependencyResolver Current {
+            get {
+                return _instance.InnerCurrent;
+            }
+        }
+
+        public static void SetResolver(IDependencyResolver resolver) {
+            _instance.InnerSetResolver(resolver);
+        }
+
+        public static void SetResolver(object commonServiceLocator) {
+            _instance.InnerSetResolver(commonServiceLocator);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types.")]
+        public static void SetResolver(Func<Type, object> getService, Func<Type, IEnumerable<object>> getServices) {
+            _instance.InnerSetResolver(getService, getServices);
+        }
+
+        // Instance implementation (for testing purposes)
+
+        private IDependencyResolver _current = new DefaultDependencyResolver();
+
+        public IDependencyResolver InnerCurrent {
+            get {
+                return _current;
+            }
+        }
+
+        public void InnerSetResolver(IDependencyResolver resolver) {
+            if (resolver == null) {
+                throw new ArgumentNullException("resolver");
+            }
+
+            _current = resolver;
+        }
+
+        public void InnerSetResolver(object commonServiceLocator) {
+            if (commonServiceLocator == null) {
+                throw new ArgumentNullException("commonServiceLocator");
+            }
+
+            Type locatorType = commonServiceLocator.GetType();
+            MethodInfo getInstance = locatorType.GetMethod("GetInstance", new[] { typeof(Type) });
+            MethodInfo getInstances = locatorType.GetMethod("GetAllInstances", new[] { typeof(Type) });
+
+            if (getInstance == null ||
+                getInstance.ReturnType != typeof(object) ||
+                getInstances == null ||
+                getInstances.ReturnType != typeof(IEnumerable<object>)) {
+                throw new ArgumentException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.DependencyResolver_DoesNotImplementICommonServiceLocator,
+                        locatorType.FullName
+                    ),
+                    "commonServiceLocator"
+                );
+            }
+
+            var getService = (Func<Type, object>)Delegate.CreateDelegate(typeof(Func<Type, object>), commonServiceLocator, getInstance);
+            var getServices = (Func<Type, IEnumerable<object>>)Delegate.CreateDelegate(typeof(Func<Type, IEnumerable<object>>), commonServiceLocator, getInstances);
+
+            _current = new DelegateBasedDependencyResolver(getService, getServices);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types.")]
+        public void InnerSetResolver(Func<Type, object> getService, Func<Type, IEnumerable<object>> getServices) {
+            if (getService == null) {
+                throw new ArgumentNullException("getService");
+            }
+            if (getServices == null) {
+                throw new ArgumentNullException("getServices");
+            }
+
+            _current = new DelegateBasedDependencyResolver(getService, getServices);
+        }
+
+        // Helper classes
+
+        private class DelegateBasedDependencyResolver : IDependencyResolver {
+            Func<Type, object> _getService;
+            Func<Type, IEnumerable<object>> _getServices;
+
+            public DelegateBasedDependencyResolver(Func<Type, object> getService, Func<Type, IEnumerable<object>> getServices) {
+                _getService = getService;
+                _getServices = getServices;
+            }
+
+            [SuppressMessage("Microsoft.Design", "CA1031:DoNotCatchGeneralExceptionTypes", Justification = "This method might throw exceptions whose type we cannot strongly link against; namely, ActivationException from common service locator")]
+            public object GetService(Type type) {
+                try {
+                    return _getService.Invoke(type);
+                }
+                catch {
+                    return null;
+                }
+            }
+
+            public IEnumerable<object> GetServices(Type type) {
+                return _getServices(type);
+            }
+        }
+
+        private class DefaultDependencyResolver : IDependencyResolver {
+            [SuppressMessage("Microsoft.Design", "CA1031:DoNotCatchGeneralExceptionTypes", Justification = "This method might throw exceptions whose type we cannot strongly link against; namely, ActivationException from common service locator")]
+            public object GetService(Type serviceType) {
+                try {
+                    return Activator.CreateInstance(serviceType);
+                }
+                catch {
+                    return null;
+                }
+            }
+
+            public IEnumerable<object> GetServices(Type serviceType) {
+                return Enumerable.Empty<object>();
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DependencyResolverExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/DependencyResolverExtensions.cs
new file mode 100644 (file)
index 0000000..deaec59
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Linq;
+    using System.Runtime.Serialization;
+
+    public static class DependencyResolverExtensions {
+        public static TService GetService<TService>(this IDependencyResolver resolver) {
+            return (TService)resolver.GetService(typeof(TService));
+        }
+
+        public static IEnumerable<TService> GetServices<TService>(this IDependencyResolver resolver) {
+            return resolver.GetServices(typeof(TService)).Cast<TService>();
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DescriptorUtil.cs b/mcs/class/System.Web.Mvc3/Mvc/DescriptorUtil.cs
new file mode 100644 (file)
index 0000000..e005c45
--- /dev/null
@@ -0,0 +1,65 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.Linq;
+    using System.Reflection;
+    using System.Text;
+    using System.Threading;
+
+    internal static class DescriptorUtil {
+
+        private static void AppendPartToUniqueIdBuilder(StringBuilder builder, object part) {
+            if (part == null) {
+                builder.Append("[-1]");
+            }
+            else {
+                string partString = Convert.ToString(part, CultureInfo.InvariantCulture);
+                builder.AppendFormat("[{0}]{1}", partString.Length, partString);
+            }
+        }
+
+        public static string CreateUniqueId(params object[] parts) {
+            return CreateUniqueId((IEnumerable<object>)parts);
+        }
+
+        public static string CreateUniqueId(IEnumerable<object> parts) {
+            // returns a unique string made up of the pieces passed in
+            StringBuilder builder = new StringBuilder();
+            foreach (object part in parts) {
+                // We can special-case certain part types
+
+                MemberInfo memberInfo = part as MemberInfo;
+                if (memberInfo != null) {
+                    AppendPartToUniqueIdBuilder(builder, memberInfo.Module.ModuleVersionId);
+                    AppendPartToUniqueIdBuilder(builder, memberInfo.MetadataToken);
+                    continue;
+                }
+
+                IUniquelyIdentifiable uniquelyIdentifiable = part as IUniquelyIdentifiable;
+                if (uniquelyIdentifiable != null) {
+                    AppendPartToUniqueIdBuilder(builder, uniquelyIdentifiable.UniqueId);
+                    continue;
+                }
+
+                AppendPartToUniqueIdBuilder(builder, part);
+            }
+
+            return builder.ToString();
+        }
+
+        public static TDescriptor[] LazilyFetchOrCreateDescriptors<TReflection, TDescriptor>(ref TDescriptor[] cacheLocation, Func<TReflection[]> initializer, Func<TReflection, TDescriptor> converter) {
+            // did we already calculate this once?
+            TDescriptor[] existingCache = Interlocked.CompareExchange(ref cacheLocation, null, null);
+            if (existingCache != null) {
+                return existingCache;
+            }
+
+            TReflection[] memberInfos = initializer();
+            TDescriptor[] descriptors = memberInfos.Select(converter).Where(descriptor => descriptor != null).ToArray();
+            TDescriptor[] updatedCache = Interlocked.CompareExchange(ref cacheLocation, descriptors, null);
+            return updatedCache ?? descriptors;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DictionaryHelpers.cs b/mcs/class/System.Web.Mvc3/Mvc/DictionaryHelpers.cs
new file mode 100644 (file)
index 0000000..67dadac
--- /dev/null
@@ -0,0 +1,40 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq;
+
+    internal static class DictionaryHelpers {
+
+        public static IEnumerable<KeyValuePair<string, TValue>> FindKeysWithPrefix<TValue>(IDictionary<string, TValue> dictionary, string prefix) {
+            TValue exactMatchValue;
+            if (dictionary.TryGetValue(prefix, out exactMatchValue)) {
+                yield return new KeyValuePair<string, TValue>(prefix, exactMatchValue);
+            }
+
+            foreach (var entry in dictionary) {
+                string key = entry.Key;
+
+                if (key.Length <= prefix.Length) {
+                    continue;
+                }
+
+                if (!key.StartsWith(prefix, StringComparison.OrdinalIgnoreCase)) {
+                    continue;
+                }
+
+                char charAfterPrefix = key[prefix.Length];
+                switch (charAfterPrefix) {
+                    case '[':
+                    case '.':
+                        yield return entry;
+                        break;
+                }
+            }
+        }
+
+        public static bool DoesAnyKeyHavePrefix<TValue>(IDictionary<string, TValue> dictionary, string prefix) {
+            return FindKeysWithPrefix(dictionary, prefix).Any();
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DictionaryValueProvider`1.cs b/mcs/class/System.Web.Mvc3/Mvc/DictionaryValueProvider`1.cs
new file mode 100644 (file)
index 0000000..eed1a1c
--- /dev/null
@@ -0,0 +1,52 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Globalization;
+
+    public class DictionaryValueProvider<TValue> : IValueProvider {
+
+        private readonly HashSet<string> _prefixes = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
+        private readonly Dictionary<string, ValueProviderResult> _values = new Dictionary<string, ValueProviderResult>(StringComparer.OrdinalIgnoreCase);
+
+        public DictionaryValueProvider(IDictionary<string, TValue> dictionary, CultureInfo culture) {
+            if (dictionary == null) {
+                throw new ArgumentNullException("dictionary");
+            }
+
+            AddValues(dictionary, culture);
+        }
+
+        private void AddValues(IDictionary<string, TValue> dictionary, CultureInfo culture) {
+            if (dictionary.Count > 0) {
+                _prefixes.Add("");
+            }
+
+            foreach (var entry in dictionary) {
+                _prefixes.UnionWith(ValueProviderUtil.GetPrefixes(entry.Key));
+
+                object rawValue = entry.Value;
+                string attemptedValue = Convert.ToString(rawValue, culture);
+                _values[entry.Key] = new ValueProviderResult(rawValue, attemptedValue, culture);
+            }
+        }
+
+        public virtual bool ContainsPrefix(string prefix) {
+            if (prefix == null) {
+                throw new ArgumentNullException("prefix");
+            }
+
+            return _prefixes.Contains(prefix);
+        }
+
+        public virtual ValueProviderResult GetValue(string key) {
+            if (key == null) {
+                throw new ArgumentNullException("key");
+            }
+
+            ValueProviderResult vpResult;
+            _values.TryGetValue(key, out vpResult);
+            return vpResult;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/DynamicViewDataDictionary.cs b/mcs/class/System.Web.Mvc3/Mvc/DynamicViewDataDictionary.cs
new file mode 100644 (file)
index 0000000..2844e74
--- /dev/null
@@ -0,0 +1,39 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Diagnostics;
+    using System.Dynamic;
+
+    internal sealed class DynamicViewDataDictionary : DynamicObject {
+        private readonly Func<ViewDataDictionary> _viewDataThunk;
+
+        public DynamicViewDataDictionary(Func<ViewDataDictionary> viewDataThunk) {
+            _viewDataThunk = viewDataThunk;
+        }
+
+        private ViewDataDictionary ViewData {
+            get {
+                ViewDataDictionary viewData = _viewDataThunk();
+                Debug.Assert(viewData != null);
+                return viewData;
+            }
+        }
+
+        // Implementing this function improves the debugging experience as it provides the debugger with the list of all
+        // the properties currently defined on the object
+        public override IEnumerable<string> GetDynamicMemberNames() {
+            return ViewData.Keys;
+        }
+
+        public override bool TryGetMember(GetMemberBinder binder, out object result) {
+            result = ViewData[binder.Name];
+            // since ViewDataDictionary always returns a result even if the key does not exist, always return true
+            return true;
+        }
+
+        public override bool TrySetMember(SetMemberBinder binder, object value) {
+            ViewData[binder.Name] = value;
+            // you can always set a key in the dictionary so return true
+            return true;
+        }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/EmptyModelMetadataProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/EmptyModelMetadataProvider.cs
new file mode 100644 (file)
index 0000000..dfb9a08
--- /dev/null
@@ -0,0 +1,11 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Reflection;
+
+    public class EmptyModelMetadataProvider : AssociatedMetadataProvider {
+        protected override ModelMetadata CreateMetadata(IEnumerable<Attribute> attributes, Type containerType, Func<object> modelAccessor, Type modelType, string propertyName) {
+            return new ModelMetadata(this, containerType, modelAccessor, modelType, propertyName);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/EmptyModelValidatorProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/EmptyModelValidatorProvider.cs
new file mode 100644 (file)
index 0000000..2221881
--- /dev/null
@@ -0,0 +1,10 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Linq;
+
+    public class EmptyModelValidatorProvider : ModelValidatorProvider {
+        public override IEnumerable<ModelValidator> GetValidators(ModelMetadata metadata, ControllerContext context) {
+            return Enumerable.Empty<ModelValidator>();
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/EmptyResult.cs b/mcs/class/System.Web.Mvc3/Mvc/EmptyResult.cs
new file mode 100644 (file)
index 0000000..8438282
--- /dev/null
@@ -0,0 +1,17 @@
+namespace System.Web.Mvc {
+
+    // represents a result that doesn't do anything, like a controller action returning null
+    public class EmptyResult : ActionResult {
+
+        private static readonly EmptyResult _singleton = new EmptyResult();
+
+        internal static EmptyResult Instance {
+            get {
+                return _singleton;
+            }
+        }
+
+        public override void ExecuteResult(ControllerContext context) {
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Error.cs b/mcs/class/System.Web.Mvc3/Mvc/Error.cs
new file mode 100644 (file)
index 0000000..642b0e3
--- /dev/null
@@ -0,0 +1,72 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Globalization;
+    using System.Web.Mvc.Async;
+    using System.Web.Mvc.Resources;
+
+    internal static class Error {
+
+        public static InvalidOperationException AsyncActionMethodSelector_CouldNotFindMethod(string methodName, Type controllerType) {
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.AsyncActionMethodSelector_CouldNotFindMethod,
+                methodName, controllerType);
+            return new InvalidOperationException(message);
+        }
+
+        public static InvalidOperationException AsyncCommon_AsyncResultAlreadyConsumed() {
+            return new InvalidOperationException(MvcResources.AsyncCommon_AsyncResultAlreadyConsumed);
+        }
+
+        public static InvalidOperationException AsyncCommon_ControllerMustImplementIAsyncManagerContainer(Type actualControllerType) {
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.AsyncCommon_ControllerMustImplementIAsyncManagerContainer,
+                actualControllerType);
+            return new InvalidOperationException(message);
+        }
+
+        public static ArgumentException AsyncCommon_InvalidAsyncResult(string parameterName) {
+            return new ArgumentException(MvcResources.AsyncCommon_InvalidAsyncResult, parameterName);
+        }
+
+        public static ArgumentOutOfRangeException AsyncCommon_InvalidTimeout(string parameterName) {
+            return new ArgumentOutOfRangeException(parameterName, MvcResources.AsyncCommon_InvalidTimeout);
+        }
+
+        public static InvalidOperationException ReflectedAsyncActionDescriptor_CannotExecuteSynchronously(string actionName) {
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ReflectedAsyncActionDescriptor_CannotExecuteSynchronously,
+                actionName);
+            return new InvalidOperationException(message);
+        }
+
+        public static InvalidOperationException ChildActionOnlyAttribute_MustBeInChildRequest(ActionDescriptor actionDescriptor) {
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ChildActionOnlyAttribute_MustBeInChildRequest,
+                actionDescriptor.ActionName);
+            return new InvalidOperationException(message);
+        }
+
+        public static ArgumentException ParameterCannotBeNullOrEmpty(string parameterName) {
+            return new ArgumentException(MvcResources.Common_NullOrEmpty, parameterName);
+        }
+
+        public static InvalidOperationException PropertyCannotBeNullOrEmpty(string propertyName) {
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.Common_PropertyCannotBeNullOrEmpty,
+                propertyName);
+            return new InvalidOperationException(message);
+        }
+
+        public static SynchronousOperationException SynchronizationContextUtil_ExceptionThrown(Exception innerException) {
+            return new SynchronousOperationException(MvcResources.SynchronizationContextUtil_ExceptionThrown, innerException);
+        }
+
+        public static InvalidOperationException ViewDataDictionary_WrongTModelType(Type valueType, Type modelType) {
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ViewDataDictionary_WrongTModelType,
+                valueType, modelType);
+            return new InvalidOperationException(message);
+        }
+
+        public static InvalidOperationException ViewDataDictionary_ModelCannotBeNull(Type modelType) {
+            string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ViewDataDictionary_ModelCannotBeNull,
+                modelType);
+            return new InvalidOperationException(message);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExceptionContext.cs b/mcs/class/System.Web.Mvc3/Mvc/ExceptionContext.cs
new file mode 100644 (file)
index 0000000..7fd58ce
--- /dev/null
@@ -0,0 +1,43 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+
+    public class ExceptionContext : ControllerContext {
+
+        private ActionResult _result;
+
+        // parameterless constructor used for mocking
+        public ExceptionContext() {
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
+        public ExceptionContext(ControllerContext controllerContext, Exception exception)
+            : base(controllerContext) {
+            if (exception == null) {
+                throw new ArgumentNullException("exception");
+            }
+
+            Exception = exception;
+        }
+
+        public virtual Exception Exception {
+            get;
+            set;
+        }
+
+        public bool ExceptionHandled {
+            get;
+            set;
+        }
+
+        public ActionResult Result {
+            get {
+                return _result ?? EmptyResult.Instance;
+            }
+            set {
+                _result = value;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionHelper.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionHelper.cs
new file mode 100644 (file)
index 0000000..3cf5255
--- /dev/null
@@ -0,0 +1,119 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.Linq;
+    using System.Linq.Expressions;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    public static class ExpressionHelper {
+        public static string GetExpressionText(string expression) {
+            return
+                String.Equals(expression, "model", StringComparison.OrdinalIgnoreCase)
+                    ? String.Empty    // If it's exactly "model", then give them an empty string, to replicate the lambda behavior
+                    : expression;
+        }
+
+        public static string GetExpressionText(LambdaExpression expression) {
+            // Split apart the expression string for property/field accessors to create its name
+            Stack<string> nameParts = new Stack<string>();
+            Expression part = expression.Body;
+
+            while (part != null) {
+                if (part.NodeType == ExpressionType.Call) {
+                    MethodCallExpression methodExpression = (MethodCallExpression)part;
+
+                    if (!IsSingleArgumentIndexer(methodExpression)) {
+                        break;
+                    }
+
+                    nameParts.Push(
+                        GetIndexerInvocation(
+                            methodExpression.Arguments.Single(),
+                            expression.Parameters.ToArray()
+                        )
+                    );
+
+                    part = methodExpression.Object;
+                }
+                else if (part.NodeType == ExpressionType.ArrayIndex) {
+                    BinaryExpression binaryExpression = (BinaryExpression)part;
+
+                    nameParts.Push(
+                        GetIndexerInvocation(
+                            binaryExpression.Right,
+                            expression.Parameters.ToArray()
+                        )
+                    );
+
+                    part = binaryExpression.Left;
+                }
+                else if (part.NodeType == ExpressionType.MemberAccess) {
+                    MemberExpression memberExpressionPart = (MemberExpression)part;
+                    nameParts.Push("." + memberExpressionPart.Member.Name);
+                    part = memberExpressionPart.Expression;
+                }
+                else if (part.NodeType == ExpressionType.Parameter) {
+                    // Dev10 Bug #907611
+                    // When the expression is parameter based (m => m.Something...), we'll push an empty
+                    // string onto the stack and stop evaluating. The extra empty string makes sure that
+                    // we don't accidentally cut off too much of m => m.Model.
+                    nameParts.Push(String.Empty);
+                    part = null;
+                }
+                else {
+                    break;
+                }
+            }
+
+            // If it starts with "model", then strip that away
+            if (nameParts.Count > 0 && String.Equals(nameParts.Peek(), ".model", StringComparison.OrdinalIgnoreCase)) {
+                nameParts.Pop();
+            }
+
+            if (nameParts.Count > 0) {
+                return nameParts.Aggregate((left, right) => left + right).TrimStart('.');
+            }
+
+            return String.Empty;
+        }
+
+        private static string GetIndexerInvocation(Expression expression, ParameterExpression[] parameters) {
+            Expression converted = Expression.Convert(expression, typeof(object));
+            ParameterExpression fakeParameter = Expression.Parameter(typeof(object), null);
+            Expression<Func<object, object>> lambda = Expression.Lambda<Func<object, object>>(converted, fakeParameter);
+            Func<object, object> func;
+
+            try {
+                func = ExpressionUtil.CachedExpressionCompiler.Process(lambda);
+            }
+            catch (InvalidOperationException ex) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.ExpressionHelper_InvalidIndexerExpression,
+                        expression,
+                        parameters[0].Name
+                    ),
+                    ex
+                );
+            }
+
+            return "[" + Convert.ToString(func(null), CultureInfo.InvariantCulture) + "]";
+        }
+
+        internal static bool IsSingleArgumentIndexer(Expression expression) {
+            MethodCallExpression methodExpression = expression as MethodCallExpression;
+            if (methodExpression == null || methodExpression.Arguments.Count != 1) {
+                return false;
+            }
+
+            return methodExpression.Method
+                                   .DeclaringType
+                                   .GetDefaultMembers()
+                                   .OfType<PropertyInfo>()
+                                   .Any(p => p.GetGetMethod() == methodExpression.Method);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/BinaryExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/BinaryExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..1b44e7e
--- /dev/null
@@ -0,0 +1,40 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+    using System.Reflection;
+
+    // BinaryExpression fingerprint class
+    // Useful for things like array[index]
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class BinaryExpressionFingerprint : ExpressionFingerprint {
+
+        public BinaryExpressionFingerprint(ExpressionType nodeType, Type type, MethodInfo method)
+            : base(nodeType, type) {
+
+            // Other properties on BinaryExpression (like IsLifted / IsLiftedToNull) are simply derived
+            // from Type and NodeType, so they're not necessary for inclusion in the fingerprint.
+
+            Method = method;
+        }
+
+        // http://msdn.microsoft.com/en-us/library/system.linq.expressions.binaryexpression.method.aspx
+        public MethodInfo Method { get; private set; }
+
+        public override bool Equals(object obj) {
+            BinaryExpressionFingerprint other = obj as BinaryExpressionFingerprint;
+            return (other != null)
+                && Equals(this.Method, other.Method)
+                && this.Equals(other);
+        }
+
+        internal override void AddToHashCodeCombiner(HashCodeCombiner combiner) {
+            combiner.AddObject(Method);
+            base.AddToHashCodeCombiner(combiner);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/CachedExpressionCompiler.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/CachedExpressionCompiler.cs
new file mode 100644 (file)
index 0000000..58a62cd
--- /dev/null
@@ -0,0 +1,126 @@
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Collections.Concurrent;
+    using System.Collections.Generic;
+    using System.Linq.Expressions;
+    using System.Reflection;
+
+    internal static class CachedExpressionCompiler {
+
+        // This is the entry point to the cached expression compilation system. The system
+        // will try to turn the expression into an actual delegate as quickly as possible,
+        // relying on cache lookups and other techniques to save time if appropriate.
+        // If the provided expression is particularly obscure and the system doesn't know
+        // how to handle it, we'll just compile the expression as normal.
+        public static Func<TModel, TValue> Process<TModel, TValue>(Expression<Func<TModel, TValue>> lambdaExpression) {
+            return Compiler<TModel, TValue>.Compile(lambdaExpression);
+        }
+
+        private static class Compiler<TIn, TOut> {
+            private static Func<TIn, TOut> _identityFunc;
+
+            private static readonly ConcurrentDictionary<MemberInfo, Func<TIn, TOut>> _simpleMemberAccessDict =
+                new ConcurrentDictionary<MemberInfo, Func<TIn, TOut>>();
+
+            private static readonly ConcurrentDictionary<MemberInfo, Func<object, TOut>> _constMemberAccessDict =
+                new ConcurrentDictionary<MemberInfo, Func<object, TOut>>();
+
+            private static readonly ConcurrentDictionary<ExpressionFingerprintChain, Hoisted<TIn, TOut>> _fingerprintedCache =
+                new ConcurrentDictionary<ExpressionFingerprintChain, Hoisted<TIn, TOut>>();
+
+            public static Func<TIn, TOut> Compile(Expression<Func<TIn, TOut>> expr) {
+                return CompileFromIdentityFunc(expr)
+                    ?? CompileFromConstLookup(expr)
+                    ?? CompileFromMemberAccess(expr)
+                    ?? CompileFromFingerprint(expr)
+                    ?? CompileSlow(expr);
+            }
+
+            private static Func<TIn, TOut> CompileFromConstLookup(Expression<Func<TIn, TOut>> expr) {
+                ConstantExpression constExpr = expr.Body as ConstantExpression;
+                if (constExpr != null) {
+                    // model => {const}
+
+                    TOut constantValue = (TOut)constExpr.Value;
+                    return _ => constantValue;
+                }
+
+                return null;
+            }
+
+            private static Func<TIn, TOut> CompileFromIdentityFunc(Expression<Func<TIn, TOut>> expr) {
+                if (expr.Body == expr.Parameters[0]) {
+                    // model => model
+
+                    // don't need to lock, as all identity funcs are identical
+                    if (_identityFunc == null) {
+                        _identityFunc = expr.Compile();
+                    }
+
+                    return _identityFunc;
+                }
+
+                return null;
+            }
+
+            private static Func<TIn, TOut> CompileFromFingerprint(Expression<Func<TIn, TOut>> expr) {
+                List<object> capturedConstants;
+                ExpressionFingerprintChain fingerprint = FingerprintingExpressionVisitor.GetFingerprintChain(expr, out capturedConstants);
+
+                if (fingerprint != null) {
+                    var del = _fingerprintedCache.GetOrAdd(fingerprint, _ => {
+                        // Fingerprinting succeeded, but there was a cache miss. Rewrite the expression
+                        // and add the rewritten expression to the cache.
+
+                        var hoistedExpr = HoistingExpressionVisitor<TIn, TOut>.Hoist(expr);
+                        return hoistedExpr.Compile();
+                    });
+                    return model => del(model, capturedConstants);
+                }
+
+                // couldn't be fingerprinted
+                return null;
+            }
+
+            private static Func<TIn, TOut> CompileFromMemberAccess(Expression<Func<TIn, TOut>> expr) {
+                // Performance tests show that on the x64 platform, special-casing static member and
+                // captured local variable accesses is faster than letting the fingerprinting system
+                // handle them. On the x86 platform, the fingerprinting system is faster, but only
+                // by around one microsecond, so it's not worth it to complicate the logic here with
+                // an architecture check.
+
+                MemberExpression memberExpr = expr.Body as MemberExpression;
+                if (memberExpr != null) {
+                    if (memberExpr.Expression == expr.Parameters[0] || memberExpr.Expression == null) {
+                        // model => model.Member or model => StaticMember
+                        return _simpleMemberAccessDict.GetOrAdd(memberExpr.Member, _ => expr.Compile());
+                    }
+
+                    ConstantExpression constExpr = memberExpr.Expression as ConstantExpression;
+                    if (constExpr != null) {
+                        // model => {const}.Member (captured local variable)
+                        var del = _constMemberAccessDict.GetOrAdd(memberExpr.Member, _ => {
+                            // rewrite as capturedLocal => ((TDeclaringType)capturedLocal).Member
+                            var constParamExpr = Expression.Parameter(typeof(object), "capturedLocal");
+                            var constCastExpr = Expression.Convert(constParamExpr, memberExpr.Member.DeclaringType);
+                            var newMemberAccessExpr = memberExpr.Update(constCastExpr);
+                            var newLambdaExpr = Expression.Lambda<Func<object, TOut>>(newMemberAccessExpr, constParamExpr);
+                            return newLambdaExpr.Compile();
+                        });
+
+                        object capturedLocal = constExpr.Value;
+                        return _ => del(capturedLocal);
+                    }
+                }
+
+                return null;
+            }
+
+            private static Func<TIn, TOut> CompileSlow(Expression<Func<TIn, TOut>> expr) {
+                // fallback compilation system - just compile the expression directly
+                return expr.Compile();
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ConditionalExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ConditionalExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..ae0b52f
--- /dev/null
@@ -0,0 +1,28 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+
+    // ConditionalExpression fingerprint class
+    // Expression of form (test) ? ifTrue : ifFalse
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class ConditionalExpressionFingerprint : ExpressionFingerprint {
+
+        public ConditionalExpressionFingerprint(ExpressionType nodeType, Type type)
+            : base(nodeType, type) {
+
+            // There are no properties on ConditionalExpression that are worth including in
+            // the fingerprint.
+        }
+
+        public override bool Equals(object obj) {
+            ConditionalExpressionFingerprint other = obj as ConditionalExpressionFingerprint;
+            return (other != null)
+                && this.Equals(other);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ConstantExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ConstantExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..61d9714
--- /dev/null
@@ -0,0 +1,32 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+
+    // ConstantExpression fingerprint class
+    //
+    // A ConstantExpression might represent a captured local variable, so we can't compile
+    // the value directly into the cached function. Instead, a placeholder is generated
+    // and the value is hoisted into a local variables array. This placeholder can then
+    // be compiled and cached, and the array lookup happens at runtime.
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class ConstantExpressionFingerprint : ExpressionFingerprint {
+
+        public ConstantExpressionFingerprint(ExpressionType nodeType, Type type)
+            : base(nodeType, type) {
+
+            // There are no properties on ConstantExpression that are worth including in
+            // the fingerprint.
+        }
+
+        public override bool Equals(object obj) {
+            ConstantExpressionFingerprint other = obj as ConstantExpressionFingerprint;
+            return (other != null)
+                && this.Equals(other);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/DefaultExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/DefaultExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..abf0ed3
--- /dev/null
@@ -0,0 +1,28 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+
+    // DefaultExpression fingerprint class
+    // Expression of form default(T)
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class DefaultExpressionFingerprint : ExpressionFingerprint {
+
+        public DefaultExpressionFingerprint(ExpressionType nodeType, Type type)
+            : base(nodeType, type) {
+
+            // There are no properties on DefaultExpression that are worth including in
+            // the fingerprint.
+        }
+
+        public override bool Equals(object obj) {
+            DefaultExpressionFingerprint other = obj as DefaultExpressionFingerprint;
+            return (other != null)
+                && this.Equals(other);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..135caf9
--- /dev/null
@@ -0,0 +1,43 @@
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Linq.Expressions;
+
+    // Serves as the base class for all expression fingerprints. Provides a default implementation
+    // of GetHashCode().
+
+    internal abstract class ExpressionFingerprint {
+
+        protected ExpressionFingerprint(ExpressionType nodeType, Type type) {
+            NodeType = nodeType;
+            Type = type;
+        }
+
+        // the type of expression node, e.g. OP_ADD, MEMBER_ACCESS, etc.
+        public ExpressionType NodeType { get; private set; }
+
+        // the CLR type resulting from this expression, e.g. int, string, etc.
+        public Type Type { get; private set; }
+
+        internal virtual void AddToHashCodeCombiner(HashCodeCombiner combiner) {
+            combiner.AddInt32((int)NodeType);
+            combiner.AddObject(Type);
+        }
+
+        protected bool Equals(ExpressionFingerprint other) {
+            return (other != null)
+                && (this.NodeType == other.NodeType)
+                && Equals(this.Type, other.Type);
+        }
+
+        public override bool Equals(object obj) {
+            return Equals(obj as ExpressionFingerprint);
+        }
+
+        public override int GetHashCode() {
+            HashCodeCombiner combiner = new HashCodeCombiner();
+            AddToHashCodeCombiner(combiner);
+            return combiner.CombinedHash;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ExpressionFingerprintChain.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ExpressionFingerprintChain.cs
new file mode 100644 (file)
index 0000000..2fc0ffa
--- /dev/null
@@ -0,0 +1,79 @@
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Collections.Generic;
+
+    // Expression fingerprint chain class
+    // Contains information used for generalizing, comparing, and recreating Expression instances
+    //
+    // Since Expression objects are immutable and are recreated for every invocation of an expression
+    // helper method, they can't be compared directly. Fingerprinting Expression objects allows
+    // information about them to be abstracted away, and the fingerprints can be directly compared.
+    // Consider the process of fingerprinting that all values (parameters, constants, etc.) are hoisted
+    // and replaced with dummies. What remains can be decomposed into a sequence of operations on specific
+    // types and specific inputs.
+    //
+    // Some sample fingerprints chains:
+    //
+    // 2 + 4 -> OP_ADD, CONST:int, NULL, CONST:int
+    // 2 + 8 -> OP_ADD, CONST:int, NULL, CONST:int
+    // 2.0 + 4.0 -> OP_ADD, CONST:double, NULL, CONST:double
+    //
+    // 2 + 4 and 2 + 8 have the same fingerprint, but 2.0 + 4.0 has a different fingerprint since its
+    // underlying types differ. Note that this looks a bit like prefix notation and is a side effect
+    // of how the ExpressionVisitor class recurses into expressions. (Occasionally there will be a NULL
+    // in the fingerprint chain, which depending on context can denote a static member, a null Conversion
+    // in a BinaryExpression, and so forth.)
+    //
+    // "Hello " + "world" -> OP_ADD, CONST:string, NULL, CONST:string
+    // "Hello " + {model} -> OP_ADD, CONST:string, NULL, PARAM_0:string
+    //
+    // These string concatenations have different fingerprints since the inputs are provided differently:
+    // one is a constant, the other is a parameter.
+    //
+    // ({model} ?? "sample").Length -> MEMBER_ACCESS(String.Length), OP_COALESCE, PARAM_0:string, NULL, CONST:string
+    // ({model} ?? "other sample").Length -> MEMBER_ACCESS(String.Length), OP_COALESCE, PARAM_0:string, NULL, CONST:string
+    //
+    // These expressions have the same fingerprint since all constants of the same underlying type are
+    // treated equally.
+    //
+    // It's also important that the fingerprints don't reference the actual Expression objects that were
+    // used to generate them, as the fingerprints will be cached, and caching a fingerprint that references
+    // an Expression will root the Expression (and any objects it references).
+
+    internal sealed class ExpressionFingerprintChain : IEquatable<ExpressionFingerprintChain> {
+
+        public readonly List<ExpressionFingerprint> Elements = new List<ExpressionFingerprint>();
+
+        public bool Equals(ExpressionFingerprintChain other) {
+            // Two chains are considered equal if two elements appearing in the same index in
+            // each chain are equal (value equality, not referential equality).
+
+            if (other == null) {
+                return false;
+            }
+
+            if (this.Elements.Count != other.Elements.Count) {
+                return false;
+            }
+
+            for (int i = 0; i < this.Elements.Count; i++) {
+                if (!Object.Equals(this.Elements[i], other.Elements[i])) {
+                    return false;
+                }
+            }
+
+            return true;
+        }
+
+        public override bool Equals(object obj) {
+            return Equals(obj as ExpressionFingerprintChain);
+        }
+
+        public override int GetHashCode() {
+            HashCodeCombiner combiner = new HashCodeCombiner();
+            Elements.ForEach(combiner.AddFingerprint);
+            return combiner.CombinedHash;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/FingerprintingExpressionVisitor.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/FingerprintingExpressionVisitor.cs
new file mode 100644 (file)
index 0000000..daadb68
--- /dev/null
@@ -0,0 +1,220 @@
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq.Expressions;
+
+    // This is a visitor which produces a fingerprint of an expression. It doesn't
+    // rewrite the expression in a form which can be compiled and cached.
+
+    internal sealed class FingerprintingExpressionVisitor : ExpressionVisitor {
+
+        private readonly List<object> _seenConstants = new List<object>();
+        private readonly List<ParameterExpression> _seenParameters = new List<ParameterExpression>();
+        private readonly ExpressionFingerprintChain _currentChain = new ExpressionFingerprintChain();
+        private bool _gaveUp;
+
+        private FingerprintingExpressionVisitor() { }
+
+        private T GiveUp<T>(T node) {
+            // We don't understand this node, so just quit.
+
+            _gaveUp = true;
+            return node;
+        }
+
+        // Returns the fingerprint chain + captured constants list for this expression, or null
+        // if the expression couldn't be fingerprinted.
+        public static ExpressionFingerprintChain GetFingerprintChain(Expression expr, out List<object> capturedConstants) {
+            FingerprintingExpressionVisitor visitor = new FingerprintingExpressionVisitor();
+            visitor.Visit(expr);
+
+            if (visitor._gaveUp) {
+                capturedConstants = null;
+                return null;
+            }
+            else {
+                capturedConstants = visitor._seenConstants;
+                return visitor._currentChain;
+            }
+        }
+
+        public override Expression Visit(Expression node) {
+            if (node == null) {
+                _currentChain.Elements.Add(null);
+                return null;
+            }
+            else {
+                return base.Visit(node);
+            }
+        }
+
+        protected override Expression VisitBinary(BinaryExpression node) {
+            if (_gaveUp) { return node; }
+            _currentChain.Elements.Add(new BinaryExpressionFingerprint(node.NodeType, node.Type, node.Method));
+            return base.VisitBinary(node);
+        }
+
+        protected override Expression VisitBlock(BlockExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override CatchBlock VisitCatchBlock(CatchBlock node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitConditional(ConditionalExpression node) {
+            if (_gaveUp) { return node; }
+            _currentChain.Elements.Add(new ConditionalExpressionFingerprint(node.NodeType, node.Type));
+            return base.VisitConditional(node);
+        }
+
+        protected override Expression VisitConstant(ConstantExpression node) {
+            if (_gaveUp) { return node; }
+
+            _seenConstants.Add(node.Value);
+            _currentChain.Elements.Add(new ConstantExpressionFingerprint(node.NodeType, node.Type));
+            return base.VisitConstant(node);
+        }
+
+        protected override Expression VisitDebugInfo(DebugInfoExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitDefault(DefaultExpression node) {
+            if (_gaveUp) { return node; }
+            _currentChain.Elements.Add(new DefaultExpressionFingerprint(node.NodeType, node.Type));
+            return base.VisitDefault(node);
+        }
+
+        protected override Expression VisitDynamic(DynamicExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override ElementInit VisitElementInit(ElementInit node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitExtension(Expression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitGoto(GotoExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitIndex(IndexExpression node) {
+            if (_gaveUp) { return node; }
+            _currentChain.Elements.Add(new IndexExpressionFingerprint(node.NodeType, node.Type, node.Indexer));
+            return base.VisitIndex(node);
+        }
+
+        protected override Expression VisitInvocation(InvocationExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitLabel(LabelExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override LabelTarget VisitLabelTarget(LabelTarget node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitLambda<T>(Expression<T> node) {
+            if (_gaveUp) { return node; }
+            _currentChain.Elements.Add(new LambdaExpressionFingerprint(node.NodeType, node.Type));
+            return base.VisitLambda<T>(node);
+        }
+
+        protected override Expression VisitListInit(ListInitExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitLoop(LoopExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitMember(MemberExpression node) {
+            if (_gaveUp) { return node; }
+            _currentChain.Elements.Add(new MemberExpressionFingerprint(node.NodeType, node.Type, node.Member));
+            return base.VisitMember(node);
+        }
+
+        protected override MemberAssignment VisitMemberAssignment(MemberAssignment node) {
+            return GiveUp(node);
+        }
+
+        protected override MemberBinding VisitMemberBinding(MemberBinding node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitMemberInit(MemberInitExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override MemberListBinding VisitMemberListBinding(MemberListBinding node) {
+            return GiveUp(node);
+        }
+
+        protected override MemberMemberBinding VisitMemberMemberBinding(MemberMemberBinding node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitMethodCall(MethodCallExpression node) {
+            if (_gaveUp) { return node; }
+            _currentChain.Elements.Add(new MethodCallExpressionFingerprint(node.NodeType, node.Type, node.Method));
+            return base.VisitMethodCall(node);
+        }
+
+        protected override Expression VisitNew(NewExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitNewArray(NewArrayExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitParameter(ParameterExpression node) {
+            if (_gaveUp) { return node; }
+
+            int parameterIndex = _seenParameters.IndexOf(node);
+            if (parameterIndex < 0) {
+                // first time seeing this parameter
+                parameterIndex = _seenParameters.Count;
+                _seenParameters.Add(node);
+            }
+
+            _currentChain.Elements.Add(new ParameterExpressionFingerprint(node.NodeType, node.Type, parameterIndex));
+            return base.VisitParameter(node);
+        }
+
+        protected override Expression VisitRuntimeVariables(RuntimeVariablesExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitSwitch(SwitchExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override SwitchCase VisitSwitchCase(SwitchCase node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitTry(TryExpression node) {
+            return GiveUp(node);
+        }
+
+        protected override Expression VisitTypeBinary(TypeBinaryExpression node) {
+            if (_gaveUp) { return node; }
+            _currentChain.Elements.Add(new TypeBinaryExpressionFingerprint(node.NodeType, node.Type, node.TypeOperand));
+            return base.VisitTypeBinary(node);
+        }
+
+        protected override Expression VisitUnary(UnaryExpression node) {
+            if (_gaveUp) { return node; }
+            _currentChain.Elements.Add(new UnaryExpressionFingerprint(node.NodeType, node.Type, node.Method));
+            return base.VisitUnary(node);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/HashCodeCombiner.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/HashCodeCombiner.cs
new file mode 100644 (file)
index 0000000..d981e0c
--- /dev/null
@@ -0,0 +1,49 @@
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Collections;
+
+    // based on System.Web.Util.HashCodeCombiner
+    internal class HashCodeCombiner {
+
+        private long _combinedHash64 = 0x1505L;
+
+        public void AddFingerprint(ExpressionFingerprint fingerprint) {
+            if (fingerprint != null) {
+                fingerprint.AddToHashCodeCombiner(this);
+            }
+            else {
+                AddInt32(0);
+            }
+        }
+
+        public void AddEnumerable(IEnumerable e) {
+            if (e == null) {
+                AddInt32(0);
+            }
+            else {
+                int count = 0;
+                foreach (object o in e) {
+                    AddObject(o);
+                    count++;
+                }
+                AddInt32(count);
+            }
+        }
+
+        public void AddInt32(int i) {
+            _combinedHash64 = ((_combinedHash64 << 5) + _combinedHash64) ^ i;
+        }
+
+        public void AddObject(object o) {
+            int oHashCode = (o != null) ? o.GetHashCode() : 0;
+            AddInt32(oHashCode);
+        }
+
+        public int CombinedHash {
+            get {
+                return _combinedHash64.GetHashCode();
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/Hoisted`2.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/Hoisted`2.cs
new file mode 100644 (file)
index 0000000..2862fd0
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Collections.Generic;
+
+    internal delegate TValue Hoisted<TModel, TValue>(TModel model, List<object> capturedConstants);
+
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/HoistingExpressionVisitor.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/HoistingExpressionVisitor.cs
new file mode 100644 (file)
index 0000000..3388957
--- /dev/null
@@ -0,0 +1,32 @@
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq.Expressions;
+
+    // This is a visitor which rewrites constant expressions as parameter lookups. It's meant
+    // to produce an expression which can be cached safely.
+
+    internal sealed class HoistingExpressionVisitor<TIn, TOut> : ExpressionVisitor {
+
+        private static readonly ParameterExpression _hoistedConstantsParamExpr = Expression.Parameter(typeof(List<object>), "hoistedConstants");
+        private int _numConstantsProcessed;
+
+        // factory will create instance
+        private HoistingExpressionVisitor() { }
+
+        public static Expression<Hoisted<TIn, TOut>> Hoist(Expression<Func<TIn, TOut>> expr) {
+            // rewrite Expression<Func<TIn, TOut>> as Expression<Hoisted<TIn, TOut>>
+
+            var visitor = new HoistingExpressionVisitor<TIn, TOut>();
+            var rewrittenBodyExpr = visitor.Visit(expr.Body);
+            var rewrittenLambdaExpr = Expression.Lambda<Hoisted<TIn, TOut>>(rewrittenBodyExpr, expr.Parameters[0], _hoistedConstantsParamExpr);
+            return rewrittenLambdaExpr;
+        }
+
+        protected override Expression VisitConstant(ConstantExpression node) {
+            // rewrite the constant expression as (TConst)hoistedConstants[i];
+            return Expression.Convert(Expression.Property(_hoistedConstantsParamExpr, "Item", Expression.Constant(_numConstantsProcessed++)), node.Type);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/IndexExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/IndexExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..fbd524f
--- /dev/null
@@ -0,0 +1,40 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+    using System.Reflection;
+
+    // IndexExpression fingerprint class
+    // Represents certain forms of array access or indexer property access
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class IndexExpressionFingerprint : ExpressionFingerprint {
+
+        public IndexExpressionFingerprint(ExpressionType nodeType, Type type, PropertyInfo indexer)
+            : base(nodeType, type) {
+
+            // Other properties on IndexExpression (like the argument count) are simply derived
+            // from Type and Indexer, so they're not necessary for inclusion in the fingerprint.
+
+            Indexer = indexer;
+        }
+
+        // http://msdn.microsoft.com/en-us/library/system.linq.expressions.indexexpression.indexer.aspx
+        public PropertyInfo Indexer { get; private set; }
+
+        public override bool Equals(object obj) {
+            IndexExpressionFingerprint other = obj as IndexExpressionFingerprint;
+            return (other != null)
+                && Equals(this.Indexer, other.Indexer)
+                && this.Equals(other);
+        }
+
+        internal override void AddToHashCodeCombiner(HashCodeCombiner combiner) {
+            combiner.AddObject(Indexer);
+            base.AddToHashCodeCombiner(combiner);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/LambdaExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/LambdaExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..d8e9e38
--- /dev/null
@@ -0,0 +1,28 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+
+    // LambdaExpression fingerprint class
+    // Represents a lambda expression (root element in Expression<T>)
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class LambdaExpressionFingerprint : ExpressionFingerprint {
+
+        public LambdaExpressionFingerprint(ExpressionType nodeType, Type type)
+            : base(nodeType, type) {
+
+            // There are no properties on LambdaExpression that are worth including in
+            // the fingerprint.
+        }
+
+        public override bool Equals(object obj) {
+            LambdaExpressionFingerprint other = obj as LambdaExpressionFingerprint;
+            return (other != null)
+                && this.Equals(other);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/MemberExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/MemberExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..6143a5c
--- /dev/null
@@ -0,0 +1,37 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+    using System.Reflection;
+
+    // MemberExpression fingerprint class
+    // Expression of form xxx.FieldOrProperty
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class MemberExpressionFingerprint : ExpressionFingerprint {
+
+        public MemberExpressionFingerprint(ExpressionType nodeType, Type type, MemberInfo member)
+            : base(nodeType, type) {
+
+            Member = member;
+        }
+
+        // http://msdn.microsoft.com/en-us/library/system.linq.expressions.memberexpression.member.aspx
+        public MemberInfo Member { get; private set; }
+
+        public override bool Equals(object obj) {
+            MemberExpressionFingerprint other = obj as MemberExpressionFingerprint;
+            return (other != null)
+                && Equals(this.Member, other.Member)
+                && this.Equals(other);
+        }
+
+        internal override void AddToHashCodeCombiner(HashCodeCombiner combiner) {
+            combiner.AddObject(Member);
+            base.AddToHashCodeCombiner(combiner);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/MethodCallExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/MethodCallExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..4689121
--- /dev/null
@@ -0,0 +1,40 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+    using System.Reflection;
+
+    // MethodCallExpression fingerprint class
+    // Expression of form xxx.Foo(...), xxx[...] (get_Item()), etc.
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class MethodCallExpressionFingerprint : ExpressionFingerprint {
+
+        public MethodCallExpressionFingerprint(ExpressionType nodeType, Type type, MethodInfo method)
+            : base(nodeType, type) {
+
+            // Other properties on MethodCallExpression (like the argument count) are simply derived
+            // from Type and Indexer, so they're not necessary for inclusion in the fingerprint.
+
+            Method = method;
+        }
+
+        // http://msdn.microsoft.com/en-us/library/system.linq.expressions.methodcallexpression.method.aspx
+        public MethodInfo Method { get; private set; }
+
+        public override bool Equals(object obj) {
+            MethodCallExpressionFingerprint other = obj as MethodCallExpressionFingerprint;
+            return (other != null)
+                && Equals(this.Method, other.Method)
+                && this.Equals(other);
+        }
+
+        internal override void AddToHashCodeCombiner(HashCodeCombiner combiner) {
+            combiner.AddObject(Method);
+            base.AddToHashCodeCombiner(combiner);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ParameterExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/ParameterExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..9121bce
--- /dev/null
@@ -0,0 +1,36 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+
+    // ParameterExpression fingerprint class
+    // Can represent the model parameter or an inner parameter in an open lambda expression
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class ParameterExpressionFingerprint : ExpressionFingerprint {
+
+        public ParameterExpressionFingerprint(ExpressionType nodeType, Type type, int parameterIndex)
+            : base(nodeType, type) {
+
+            ParameterIndex = parameterIndex;
+        }
+
+        // Parameter position within the overall expression, used to maintain alpha equivalence.
+        public int ParameterIndex { get; private set; }
+
+        public override bool Equals(object obj) {
+            ParameterExpressionFingerprint other = obj as ParameterExpressionFingerprint;
+            return (other != null)
+                && (this.ParameterIndex == other.ParameterIndex)
+                && this.Equals(other);
+        }
+
+        internal override void AddToHashCodeCombiner(HashCodeCombiner combiner) {
+            combiner.AddInt32(ParameterIndex);
+            base.AddToHashCodeCombiner(combiner);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/TypeBinaryExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/TypeBinaryExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..e8b78c4
--- /dev/null
@@ -0,0 +1,36 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+
+    // TypeBinary fingerprint class
+    // Expression of form "obj is T"
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class TypeBinaryExpressionFingerprint : ExpressionFingerprint {
+
+        public TypeBinaryExpressionFingerprint(ExpressionType nodeType, Type type, Type typeOperand)
+            : base(nodeType, type) {
+
+            TypeOperand = typeOperand;
+        }
+
+        // http://msdn.microsoft.com/en-us/library/system.linq.expressions.typebinaryexpression.typeoperand.aspx
+        public Type TypeOperand { get; private set; }
+
+        public override bool Equals(object obj) {
+            TypeBinaryExpressionFingerprint other = obj as TypeBinaryExpressionFingerprint;
+            return (other != null)
+                && Equals(this.TypeOperand, other.TypeOperand)
+                && this.Equals(other);
+        }
+
+        internal override void AddToHashCodeCombiner(HashCodeCombiner combiner) {
+            combiner.AddObject(TypeOperand);
+            base.AddToHashCodeCombiner(combiner);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/UnaryExpressionFingerprint.cs b/mcs/class/System.Web.Mvc3/Mvc/ExpressionUtil/UnaryExpressionFingerprint.cs
new file mode 100644 (file)
index 0000000..d920987
--- /dev/null
@@ -0,0 +1,40 @@
+#pragma warning disable 659 // overrides AddToHashCodeCombiner instead
+
+namespace System.Web.Mvc.ExpressionUtil {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+    using System.Reflection;
+
+    // UnaryExpression fingerprint class
+    // The most common appearance of a UnaryExpression is a cast or other conversion operator
+
+    [SuppressMessage("Microsoft.Usage", "CA2218:OverrideGetHashCodeOnOverridingEquals", Justification = "Overrides AddToHashCodeCombiner() instead.")]
+    internal sealed class UnaryExpressionFingerprint : ExpressionFingerprint {
+
+        public UnaryExpressionFingerprint(ExpressionType nodeType, Type type, MethodInfo method)
+            : base(nodeType, type) {
+
+            // Other properties on UnaryExpression (like IsLifted / IsLiftedToNull) are simply derived
+            // from Type and NodeType, so they're not necessary for inclusion in the fingerprint.
+
+            Method = method;
+        }
+
+        // http://msdn.microsoft.com/en-us/library/system.linq.expressions.unaryexpression.method.aspx
+        public MethodInfo Method { get; private set; }
+
+        public override bool Equals(object obj) {
+            UnaryExpressionFingerprint other = obj as UnaryExpressionFingerprint;
+            return (other != null)
+                && Equals(this.Method, other.Method)
+                && this.Equals(other);
+        }
+
+        internal override void AddToHashCodeCombiner(HashCodeCombiner combiner) {
+            combiner.AddObject(Method);
+            base.AddToHashCodeCombiner(combiner);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FieldValidationMetadata.cs b/mcs/class/System.Web.Mvc3/Mvc/FieldValidationMetadata.cs
new file mode 100644 (file)
index 0000000..c0a512e
--- /dev/null
@@ -0,0 +1,37 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+
+    public class FieldValidationMetadata {
+
+        private string _fieldName;
+        private readonly Collection<ModelClientValidationRule> _validationRules = new Collection<ModelClientValidationRule>();
+
+        public string FieldName {
+            get {
+                return _fieldName ?? String.Empty;
+            }
+            set {
+                _fieldName = value;
+            }
+        }
+
+        public bool ReplaceValidationMessageContents {
+            get;
+            set;
+        }
+
+        public string ValidationMessageId {
+            get;
+            set;
+        }
+
+        public ICollection<ModelClientValidationRule> ValidationRules {
+            get {
+                return _validationRules;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FileContentResult.cs b/mcs/class/System.Web.Mvc3/Mvc/FileContentResult.cs
new file mode 100644 (file)
index 0000000..b23921f
--- /dev/null
@@ -0,0 +1,28 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web;
+
+    public class FileContentResult : FileResult {
+
+        public FileContentResult(byte[] fileContents, string contentType)
+            : base(contentType) {
+            if (fileContents == null) {
+                throw new ArgumentNullException("fileContents");
+            }
+
+            FileContents = fileContents;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1819:PropertiesShouldNotReturnArrays", Justification = "There's no reason to tamper-proof this array since it's supplied to the type's constructor.")]
+        public byte[] FileContents {
+            get;
+            private set;
+        }
+
+        protected override void WriteFile(HttpResponseBase response) {
+            response.OutputStream.Write(FileContents, 0, FileContents.Length);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FilePathResult.cs b/mcs/class/System.Web.Mvc3/Mvc/FilePathResult.cs
new file mode 100644 (file)
index 0000000..e9bc66e
--- /dev/null
@@ -0,0 +1,27 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+
+    public class FilePathResult : FileResult {
+
+        public FilePathResult(string fileName, string contentType)
+            : base(contentType) {
+            if (String.IsNullOrEmpty(fileName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "fileName");
+            }
+
+            FileName = fileName;
+        }
+
+        public string FileName {
+            get;
+            private set;
+        }
+
+        protected override void WriteFile(HttpResponseBase response) {
+            response.TransmitFile(FileName);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FileResult.cs b/mcs/class/System.Web.Mvc3/Mvc/FileResult.cs
new file mode 100644 (file)
index 0000000..a44f6c3
--- /dev/null
@@ -0,0 +1,131 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Net.Mime;
+    using System.Text;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+
+    public abstract class FileResult : ActionResult {
+
+        protected FileResult(string contentType) {
+            if (String.IsNullOrEmpty(contentType)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "contentType");
+            }
+
+            ContentType = contentType;
+        }
+
+        private string _fileDownloadName;
+
+        public string ContentType {
+            get;
+            private set;
+        }
+
+        public string FileDownloadName {
+            get {
+                return _fileDownloadName ?? String.Empty;
+            }
+            set {
+                _fileDownloadName = value;
+            }
+        }
+
+        public override void ExecuteResult(ControllerContext context) {
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+
+            HttpResponseBase response = context.HttpContext.Response;
+            response.ContentType = ContentType;
+
+            if (!String.IsNullOrEmpty(FileDownloadName)) {
+                // From RFC 2183, Sec. 2.3:
+                // The sender may want to suggest a filename to be used if the entity is
+                // detached and stored in a separate file. If the receiving MUA writes
+                // the entity to a file, the suggested filename should be used as a
+                // basis for the actual filename, where possible.
+                string headerValue = ContentDispositionUtil.GetHeaderValue(FileDownloadName);
+                context.HttpContext.Response.AddHeader("Content-Disposition", headerValue);
+            }
+
+            WriteFile(response);
+        }
+
+        protected abstract void WriteFile(HttpResponseBase response);
+
+        private static class ContentDispositionUtil {
+            private const string _hexDigits = "0123456789ABCDEF";
+
+            private static void AddByteToStringBuilder(byte b, StringBuilder builder) {
+                builder.Append('%');
+
+                int i = b;
+                AddHexDigitToStringBuilder(i >> 4, builder);
+                AddHexDigitToStringBuilder(i % 16, builder);
+            }
+
+            private static void AddHexDigitToStringBuilder(int digit, StringBuilder builder) {
+                builder.Append(_hexDigits[digit]);
+            }
+
+            private static string CreateRfc2231HeaderValue(string filename) {
+                StringBuilder builder = new StringBuilder("attachment; filename*=UTF-8''");
+
+                byte[] filenameBytes = Encoding.UTF8.GetBytes(filename);
+                foreach (byte b in filenameBytes) {
+                    if (IsByteValidHeaderValueCharacter(b)) {
+                        builder.Append((char)b);
+                    }
+                    else {
+                        AddByteToStringBuilder(b, builder);
+                    }
+                }
+
+                return builder.ToString();
+            }
+
+            public static string GetHeaderValue(string fileName) {
+                try {
+                    // first, try using the .NET built-in generator
+                    ContentDisposition disposition = new ContentDisposition() { FileName = fileName };
+                    return disposition.ToString();
+                }
+                catch (FormatException) {
+                    // otherwise, fall back to RFC 2231 extensions generator
+                    return CreateRfc2231HeaderValue(fileName);
+                }
+            }
+
+            // Application of RFC 2231 Encoding to Hypertext Transfer Protocol (HTTP) Header Fields, sec. 3.2
+            // http://greenbytes.de/tech/webdav/draft-reschke-rfc2231-in-http-latest.html
+            private static bool IsByteValidHeaderValueCharacter(byte b) {
+                if ((byte)'0' <= b && b <= (byte)'9') {
+                    return true; // is digit
+                }
+                if ((byte)'a' <= b && b <= (byte)'z') {
+                    return true; // lowercase letter
+                }
+                if ((byte)'A' <= b && b <= (byte)'Z') {
+                    return true; // uppercase letter
+                }
+
+                switch (b) {
+                    case (byte)'-':
+                    case (byte)'.':
+                    case (byte)'_':
+                    case (byte)'~':
+                    case (byte)':':
+                    case (byte)'!':
+                    case (byte)'$':
+                    case (byte)'&':
+                    case (byte)'+':
+                        return true;
+                }
+
+                return false;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FileStreamResult.cs b/mcs/class/System.Web.Mvc3/Mvc/FileStreamResult.cs
new file mode 100644 (file)
index 0000000..992de30
--- /dev/null
@@ -0,0 +1,44 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.IO;
+    using System.Web;
+
+    public class FileStreamResult : FileResult {
+
+        // default buffer size as defined in BufferedStream type
+        private const int _bufferSize = 0x1000;
+
+        public FileStreamResult(Stream fileStream, string contentType)
+            : base(contentType) {
+            if (fileStream == null) {
+                throw new ArgumentNullException("fileStream");
+            }
+
+            FileStream = fileStream;
+        }
+
+        public Stream FileStream {
+            get;
+            private set;
+        }
+
+        protected override void WriteFile(HttpResponseBase response) {
+            // grab chunks of data and write to the output stream
+            Stream outputStream = response.OutputStream;
+            using (FileStream) {
+                byte[] buffer = new byte[_bufferSize];
+
+                while (true) {
+                    int bytesRead = FileStream.Read(buffer, 0, _bufferSize);
+                    if (bytesRead == 0) {
+                        // no more data
+                        break;
+                    }
+
+                    outputStream.Write(buffer, 0, bytesRead);
+                }
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Filter.cs b/mcs/class/System.Web.Mvc3/Mvc/Filter.cs
new file mode 100644 (file)
index 0000000..1d239bc
--- /dev/null
@@ -0,0 +1,39 @@
+namespace System.Web.Mvc {
+    using System.Diagnostics.CodeAnalysis;
+
+    public class Filter {
+        public const int DefaultOrder = -1;
+
+        public Filter(object instance, FilterScope scope, int? order) {
+            if (instance == null) {
+                throw new ArgumentNullException("instance");
+            }
+
+            if (order == null) {
+                IMvcFilter mvcFilter = instance as IMvcFilter;
+                if (mvcFilter != null) {
+                    order = mvcFilter.Order;
+                }
+            }
+
+            Instance = instance;
+            Order = order ?? DefaultOrder;
+            Scope = scope;
+        }
+
+        public object Instance {
+            get;
+            protected set;
+        }
+
+        public int Order {
+            get;
+            protected set;
+        }
+
+        public FilterScope Scope {
+            get;
+            protected set;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FilterAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/FilterAttribute.cs
new file mode 100644 (file)
index 0000000..3c210c0
--- /dev/null
@@ -0,0 +1,40 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Concurrent;
+    using System.Linq;
+    using System.Web.Mvc.Resources;
+
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
+    public abstract class FilterAttribute : Attribute, IMvcFilter {
+        private readonly static ConcurrentDictionary<Type, bool> _multiuseAttributeCache = new ConcurrentDictionary<Type, bool>();
+        private int _order = Filter.DefaultOrder;
+
+        private static bool AllowsMultiple(Type attributeType) {
+            return _multiuseAttributeCache.GetOrAdd(
+                attributeType,
+                type => type.GetCustomAttributes(typeof(AttributeUsageAttribute), true)
+                            .Cast<AttributeUsageAttribute>()
+                            .First()
+                            .AllowMultiple
+            );
+        }
+
+        public bool AllowMultiple {
+            get {
+                return AllowsMultiple(GetType());
+            }
+        }
+
+        public int Order {
+            get {
+                return _order;
+            }
+            set {
+                if (value < Filter.DefaultOrder) {
+                    throw new ArgumentOutOfRangeException("value", MvcResources.FilterAttribute_OrderOutOfRange);
+                }
+                _order = value;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FilterAttributeFilterProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/FilterAttributeFilterProvider.cs
new file mode 100644 (file)
index 0000000..7c76121
--- /dev/null
@@ -0,0 +1,40 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq;
+    using System.Web.Mvc.Async;
+
+    public class FilterAttributeFilterProvider : IFilterProvider {
+        private readonly bool _cacheAttributeInstances;
+
+        public FilterAttributeFilterProvider()
+            : this(true) {
+        }
+
+        public FilterAttributeFilterProvider(bool cacheAttributeInstances) {
+            _cacheAttributeInstances = cacheAttributeInstances;
+        }
+
+        protected virtual IEnumerable<FilterAttribute> GetActionAttributes(ControllerContext controllerContext, ActionDescriptor actionDescriptor) {
+            return actionDescriptor.GetFilterAttributes(_cacheAttributeInstances);
+        }
+
+        protected virtual IEnumerable<FilterAttribute> GetControllerAttributes(ControllerContext controllerContext, ActionDescriptor actionDescriptor) {
+            return actionDescriptor.ControllerDescriptor.GetFilterAttributes(_cacheAttributeInstances);
+        }
+
+        public virtual IEnumerable<Filter> GetFilters(ControllerContext controllerContext, ActionDescriptor actionDescriptor) {
+            ControllerBase controller = controllerContext.Controller;
+            if (controller == null) {
+                return Enumerable.Empty<Filter>();
+            }
+
+            var typeFilters = GetControllerAttributes(controllerContext, actionDescriptor)
+                             .Select(attr => new Filter(attr, FilterScope.Controller, null));
+            var methodFilters = GetActionAttributes(controllerContext, actionDescriptor)
+                               .Select(attr => new Filter(attr, FilterScope.Action, null));
+
+            return typeFilters.Concat(methodFilters).ToList();
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FilterInfo.cs b/mcs/class/System.Web.Mvc3/Mvc/FilterInfo.cs
new file mode 100644 (file)
index 0000000..90297d7
--- /dev/null
@@ -0,0 +1,48 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Linq;
+
+    public class FilterInfo {
+        private List<IActionFilter> _actionFilters = new List<IActionFilter>();
+        private List<IAuthorizationFilter> _authorizationFilters = new List<IAuthorizationFilter>();
+        private List<IExceptionFilter> _exceptionFilters = new List<IExceptionFilter>();
+        private List<IResultFilter> _resultFilters = new List<IResultFilter>();
+
+        public FilterInfo() {
+        }
+
+        public FilterInfo(IEnumerable<Filter> filters) {
+            // evaluate the 'filters' enumerable only once since the operation can be quite expensive
+            var filterInstances = filters.Select(f => f.Instance).ToList();
+
+            _actionFilters.AddRange(filterInstances.OfType<IActionFilter>());
+            _authorizationFilters.AddRange(filterInstances.OfType<IAuthorizationFilter>());
+            _exceptionFilters.AddRange(filterInstances.OfType<IExceptionFilter>());
+            _resultFilters.AddRange(filterInstances.OfType<IResultFilter>());
+        }
+
+        public IList<IActionFilter> ActionFilters {
+            get {
+                return _actionFilters;
+            }
+        }
+
+        public IList<IAuthorizationFilter> AuthorizationFilters {
+            get {
+                return _authorizationFilters;
+            }
+        }
+
+        public IList<IExceptionFilter> ExceptionFilters {
+            get {
+                return _exceptionFilters;
+            }
+        }
+
+        public IList<IResultFilter> ResultFilters {
+            get {
+                return _resultFilters;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FilterProviderCollection.cs b/mcs/class/System.Web.Mvc3/Mvc/FilterProviderCollection.cs
new file mode 100644 (file)
index 0000000..aa71434
--- /dev/null
@@ -0,0 +1,107 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+    using System.Linq;
+
+    public class FilterProviderCollection : Collection<IFilterProvider> {
+
+        private static FilterComparer _filterComparer = new FilterComparer();
+        private IResolver<IEnumerable<IFilterProvider>> _serviceResolver;
+
+        public FilterProviderCollection() {
+            _serviceResolver = new MultiServiceResolver<IFilterProvider>(() => Items);
+        }
+
+        public FilterProviderCollection(IList<IFilterProvider> providers)
+            : base(providers) {
+            _serviceResolver = new MultiServiceResolver<IFilterProvider>(() => Items);
+        }
+
+        internal FilterProviderCollection(IResolver<IEnumerable<IFilterProvider>> serviceResolver, params IFilterProvider[] providers)
+            : base(providers) {
+            _serviceResolver = serviceResolver ?? new MultiServiceResolver<IFilterProvider>(
+                    () => Items
+                    );
+        }
+
+        private IEnumerable<IFilterProvider> CombinedItems {
+            get {
+                return _serviceResolver.Current;
+            }
+        }
+
+        private static bool AllowMultiple(object filterInstance) {
+            IMvcFilter mvcFilter = filterInstance as IMvcFilter;
+            if (mvcFilter == null) {
+                return true;
+            }
+
+            return mvcFilter.AllowMultiple;
+        }
+
+        public IEnumerable<Filter> GetFilters(ControllerContext controllerContext, ActionDescriptor actionDescriptor) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (actionDescriptor == null) {
+                throw new ArgumentNullException("actionDescriptor");
+            }
+
+            IEnumerable<Filter> combinedFilters =
+                CombinedItems.SelectMany(fp => fp.GetFilters(controllerContext, actionDescriptor))
+                             .OrderBy(filter => filter, _filterComparer);
+
+            // Remove duplicates from the back forward
+            return RemoveDuplicates(combinedFilters.Reverse()).Reverse();
+        }
+
+        private IEnumerable<Filter> RemoveDuplicates(IEnumerable<Filter> filters) {
+            HashSet<Type> visitedTypes = new HashSet<Type>();
+
+            foreach (Filter filter in filters) {
+                object filterInstance = filter.Instance;
+                Type filterInstanceType = filterInstance.GetType();
+
+                if (!visitedTypes.Contains(filterInstanceType) || AllowMultiple(filterInstance)) {
+                    yield return filter;
+                    visitedTypes.Add(filterInstanceType);
+                }
+            }
+        }
+
+        private class FilterComparer : IComparer<Filter> {
+            public int Compare(Filter x, Filter y) {
+                // Nulls always have to be less than non-nulls
+                if (x == null && y == null) {
+                    return 0;
+                }
+                if (x == null) {
+                    return -1;
+                }
+                if (y == null) {
+                    return 1;
+                }
+
+                // Sort first by order...
+
+                if (x.Order < y.Order) {
+                    return -1;
+                }
+                if (x.Order > y.Order) {
+                    return 1;
+                }
+
+                // ...then by scope
+
+                if (x.Scope < y.Scope) {
+                    return -1;
+                }
+                if (x.Scope > y.Scope) {
+                    return 1;
+                }
+
+                return 0;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FilterProviders.cs b/mcs/class/System.Web.Mvc3/Mvc/FilterProviders.cs
new file mode 100644 (file)
index 0000000..09f2b5e
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    public static class FilterProviders {
+        static FilterProviders() {
+            Providers = new FilterProviderCollection();
+            Providers.Add(GlobalFilters.Filters);
+            Providers.Add(new FilterAttributeFilterProvider());
+            Providers.Add(new ControllerInstanceFilterProvider());
+        }
+
+        public static FilterProviderCollection Providers {
+            get;
+            private set;
+        }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FilterScope.cs b/mcs/class/System.Web.Mvc3/Mvc/FilterScope.cs
new file mode 100644 (file)
index 0000000..3be5da3
--- /dev/null
@@ -0,0 +1,9 @@
+namespace System.Web.Mvc {
+    public enum FilterScope {
+        First = 0,
+        Global = 10,
+        Controller = 20,
+        Action = 30,
+        Last = 100,
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FormCollection.cs b/mcs/class/System.Web.Mvc3/Mvc/FormCollection.cs
new file mode 100644 (file)
index 0000000..279e564
--- /dev/null
@@ -0,0 +1,81 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Specialized;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Web.Helpers;
+
+    [SuppressMessage("Microsoft.Usage", "CA2237:MarkISerializableTypesWithSerializable", Justification = "It is not anticipated that users will need to serialize this type.")]
+    [SuppressMessage("Microsoft.Design", "CA1035:ICollectionImplementationsHaveStronglyTypedMembers", Justification = "It is not anticipated that users will call FormCollection.CopyTo().")]
+    [FormCollectionBinder]
+    public sealed class FormCollection : NameValueCollection, IValueProvider {
+
+        public FormCollection() {
+        }
+
+        public FormCollection(NameValueCollection collection) {
+            if (collection == null) {
+                throw new ArgumentNullException("collection");
+            }
+
+            Add(collection);
+        }
+
+        internal FormCollection(ControllerBase controller, Func<NameValueCollection> validatedValuesThunk, Func<NameValueCollection> unvalidatedValuesThunk) {
+            Add(controller == null || controller.ValidateRequest ? validatedValuesThunk() : unvalidatedValuesThunk());
+        }
+
+        public ValueProviderResult GetValue(string name) {
+            if (name == null) {
+                throw new ArgumentNullException("name");
+            }
+
+            string[] rawValue = GetValues(name);
+            if (rawValue == null) {
+                return null;
+            }
+
+            string attemptedValue = this[name];
+            return new ValueProviderResult(rawValue, attemptedValue, CultureInfo.CurrentCulture);
+        }
+
+        public IValueProvider ToValueProvider() {
+            return this;
+        }
+
+        #region IValueProvider Members
+        bool IValueProvider.ContainsPrefix(string prefix) {
+            return ValueProviderUtil.CollectionContainsPrefix(AllKeys, prefix);
+        }
+
+        ValueProviderResult IValueProvider.GetValue(string key) {
+            return GetValue(key);
+        }
+        #endregion
+
+        private sealed class FormCollectionBinderAttribute : CustomModelBinderAttribute {
+
+            // since the FormCollectionModelBinder.BindModel() method is thread-safe, we only need to keep
+            // a single instance of the binder around
+            private static readonly FormCollectionModelBinder _binder = new FormCollectionModelBinder();
+
+            public override IModelBinder GetBinder() {
+                return _binder;
+            }
+
+            // this class is used for generating a FormCollection object
+            private sealed class FormCollectionModelBinder : IModelBinder {
+                public object BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+                    if (controllerContext == null) {
+                        throw new ArgumentNullException("controllerContext");
+                    }
+
+                    return new FormCollection(controllerContext.Controller,
+                                              () => controllerContext.HttpContext.Request.Form,
+                                              () => controllerContext.HttpContext.Request.Unvalidated().Form);
+                }
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FormContext.cs b/mcs/class/System.Web.Mvc3/Mvc/FormContext.cs
new file mode 100644 (file)
index 0000000..40f69ff
--- /dev/null
@@ -0,0 +1,80 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web.Script.Serialization;
+
+    public class FormContext {
+
+        private readonly Dictionary<string, FieldValidationMetadata> _fieldValidators = new Dictionary<string, FieldValidationMetadata>();
+        private readonly Dictionary<string, bool> _renderedFields = new Dictionary<string, bool>();
+
+        public IDictionary<string, FieldValidationMetadata> FieldValidators {
+            get {
+                return _fieldValidators;
+            }
+        }
+
+        public string FormId {
+            get;
+            set;
+        }
+
+        public bool ReplaceValidationSummary {
+            get;
+            set;
+        }
+
+        public string ValidationSummaryId {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate", Justification = "Performs a potentially time-consuming conversion.")]
+        public string GetJsonValidationMetadata() {
+            JavaScriptSerializer serializer = new JavaScriptSerializer();
+
+            SortedDictionary<string, object> dict = new SortedDictionary<string, object>() {
+                { "Fields", FieldValidators.Values },
+                { "FormId", FormId }
+            };
+            if (!String.IsNullOrEmpty(ValidationSummaryId)) {
+                dict["ValidationSummaryId"] = ValidationSummaryId;
+            }
+            dict["ReplaceValidationSummary"] = ReplaceValidationSummary;
+
+            return serializer.Serialize(dict);
+        }
+
+        public FieldValidationMetadata GetValidationMetadataForField(string fieldName) {
+            return GetValidationMetadataForField(fieldName, false /* createIfNotFound */);
+        }
+
+        public FieldValidationMetadata GetValidationMetadataForField(string fieldName, bool createIfNotFound) {
+            if (String.IsNullOrEmpty(fieldName)) {
+                throw Error.ParameterCannotBeNullOrEmpty("fieldName");
+            }
+
+            FieldValidationMetadata metadata;
+            if (!FieldValidators.TryGetValue(fieldName, out metadata)) {
+                if (createIfNotFound) {
+                    metadata = new FieldValidationMetadata() {
+                        FieldName = fieldName
+                    };
+                    FieldValidators[fieldName] = metadata;
+                }
+            }
+            return metadata;
+        }
+
+        public bool RenderedField(string fieldName) {
+            bool result;
+            _renderedFields.TryGetValue(fieldName, out result);
+            return result;
+        }
+
+        public void RenderedField(string fieldName, bool value) {
+            _renderedFields[fieldName] = value;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FormMethod.cs b/mcs/class/System.Web.Mvc3/Mvc/FormMethod.cs
new file mode 100644 (file)
index 0000000..ce94870
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+    public enum FormMethod {
+        Get,
+        Post
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FormValueProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/FormValueProvider.cs
new file mode 100644 (file)
index 0000000..8da0f67
--- /dev/null
@@ -0,0 +1,18 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Globalization;
+    using System.Web.Helpers;
+
+    public sealed class FormValueProvider : NameValueCollectionValueProvider {
+
+        public FormValueProvider(ControllerContext controllerContext)
+            : this(controllerContext, new UnvalidatedRequestValuesWrapper(controllerContext.HttpContext.Request.Unvalidated())) {
+        }
+
+        // For unit testing
+        internal FormValueProvider(ControllerContext controllerContext, IUnvalidatedRequestValues unvalidatedValues)
+            : base(controllerContext.HttpContext.Request.Form, unvalidatedValues.Form, CultureInfo.CurrentCulture) {
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/FormValueProviderFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/FormValueProviderFactory.cs
new file mode 100644 (file)
index 0000000..7ce0e7c
--- /dev/null
@@ -0,0 +1,28 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Specialized;
+    using System.Web.Helpers;
+
+    public sealed class FormValueProviderFactory : ValueProviderFactory {
+
+        private readonly UnvalidatedRequestValuesAccessor _unvalidatedValuesAccessor;
+
+        public FormValueProviderFactory()
+            : this(null) {
+        }
+
+        // For unit testing
+        internal FormValueProviderFactory(UnvalidatedRequestValuesAccessor unvalidatedValuesAccessor) {
+            _unvalidatedValuesAccessor = unvalidatedValuesAccessor ?? (cc => new UnvalidatedRequestValuesWrapper(cc.HttpContext.Request.Unvalidated()));
+        }
+
+        public override IValueProvider GetValueProvider(ControllerContext controllerContext) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            return new FormValueProvider(controllerContext, _unvalidatedValuesAccessor(controllerContext));
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/GlobalFilterCollection.cs b/mcs/class/System.Web.Mvc3/Mvc/GlobalFilterCollection.cs
new file mode 100644 (file)
index 0000000..de65aaa
--- /dev/null
@@ -0,0 +1,52 @@
+namespace System.Web.Mvc {
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq;
+
+    public sealed class GlobalFilterCollection : IEnumerable<Filter>, IFilterProvider {
+        private List<Filter> _filters = new List<Filter>();
+
+        public int Count {
+            get {
+                return _filters.Count;
+            }
+        }
+
+        public void Add(object filter) {
+            AddInternal(filter, order: null);
+        }
+
+        public void Add(object filter, int order) {
+            AddInternal(filter, order);
+        }
+
+        private void AddInternal(object filter, int? order) {
+            _filters.Add(new Filter(filter, FilterScope.Global, order));
+        }
+
+        public void Clear() {
+            _filters.Clear();
+        }
+
+        public bool Contains(object filter) {
+            return _filters.Any(f => f.Instance == filter);
+        }
+
+        public IEnumerator<Filter> GetEnumerator() {
+            return _filters.GetEnumerator();
+        }
+
+        IEnumerator IEnumerable.GetEnumerator() {
+            return _filters.GetEnumerator();
+        }
+
+        IEnumerable<Filter> IFilterProvider.GetFilters(ControllerContext controllerContext, ActionDescriptor actionDescriptor) {
+            return this;
+        }
+
+        public void Remove(object filter) {
+            _filters.RemoveAll(f => f.Instance == filter);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/GlobalFilters.cs b/mcs/class/System.Web.Mvc3/Mvc/GlobalFilters.cs
new file mode 100644 (file)
index 0000000..abe40f2
--- /dev/null
@@ -0,0 +1,12 @@
+namespace System.Web.Mvc {
+    public static class GlobalFilters {
+        static GlobalFilters() {
+            Filters = new GlobalFilterCollection();
+        }
+
+        public static GlobalFilterCollection Filters {
+            get;
+            private set;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HandleErrorAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/HandleErrorAttribute.cs
new file mode 100644 (file)
index 0000000..a20e27b
--- /dev/null
@@ -0,0 +1,106 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+
+    [SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes", Justification = "This attribute is AllowMultiple = true and users might want to override behavior.")]
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = true)]
+    public class HandleErrorAttribute : FilterAttribute, IExceptionFilter {
+
+        private const string _defaultView = "Error";
+
+        private readonly object _typeId = new object();
+
+        private Type _exceptionType = typeof(Exception);
+        private string _master;
+        private string _view;
+
+        public Type ExceptionType {
+            get {
+                return _exceptionType;
+            }
+            set {
+                if (value == null) {
+                    throw new ArgumentNullException("value");
+                }
+                if (!typeof(Exception).IsAssignableFrom(value)) {
+                    throw new ArgumentException(String.Format(CultureInfo.CurrentCulture,
+                        MvcResources.ExceptionViewAttribute_NonExceptionType, value.FullName));
+                }
+
+                _exceptionType = value;
+            }
+        }
+
+        public string Master {
+            get {
+                return _master ?? String.Empty;
+            }
+            set {
+                _master = value;
+            }
+        }
+
+        public override object TypeId {
+            get {
+                return _typeId;
+            }
+        }
+
+        public string View {
+            get {
+                return (!String.IsNullOrEmpty(_view)) ? _view : _defaultView;
+            }
+            set {
+                _view = value;
+            }
+        }
+
+        public virtual void OnException(ExceptionContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+            if (filterContext.IsChildAction) {
+                return;
+            }
+
+            // If custom errors are disabled, we need to let the normal ASP.NET exception handler
+            // execute so that the user can see useful debugging information.
+            if (filterContext.ExceptionHandled || !filterContext.HttpContext.IsCustomErrorEnabled) {
+                return;
+            }
+
+            Exception exception = filterContext.Exception;
+
+            // If this is not an HTTP 500 (for example, if somebody throws an HTTP 404 from an action method),
+            // ignore it.
+            if (new HttpException(null, exception).GetHttpCode() != 500) {
+                return;
+            }
+
+            if (!ExceptionType.IsInstanceOfType(exception)) {
+                return;
+            }
+
+            string controllerName = (string)filterContext.RouteData.Values["controller"];
+            string actionName = (string)filterContext.RouteData.Values["action"];
+            HandleErrorInfo model = new HandleErrorInfo(filterContext.Exception, controllerName, actionName);
+            filterContext.Result = new ViewResult {
+                ViewName = View,
+                MasterName = Master,
+                ViewData = new ViewDataDictionary<HandleErrorInfo>(model),
+                TempData = filterContext.Controller.TempData
+            };
+            filterContext.ExceptionHandled = true;
+            filterContext.HttpContext.Response.Clear();
+            filterContext.HttpContext.Response.StatusCode = 500;
+
+            // Certain versions of IIS will sometimes use their own error page when
+            // they detect a server error. Setting this property indicates that we
+            // want it to try to render ASP.NET MVC's error page instead.
+            filterContext.HttpContext.Response.TrySkipIisCustomErrors = true;
+        }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HandleErrorInfo.cs b/mcs/class/System.Web.Mvc3/Mvc/HandleErrorInfo.cs
new file mode 100644 (file)
index 0000000..b765cbe
--- /dev/null
@@ -0,0 +1,39 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Web.Mvc.Resources;
+
+    public class HandleErrorInfo {
+
+        public HandleErrorInfo(Exception exception, string controllerName, string actionName) {
+            if (exception == null) {
+                throw new ArgumentNullException("exception");
+            }
+            if (String.IsNullOrEmpty(controllerName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "controllerName");
+            }
+            if (string.IsNullOrEmpty(actionName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "actionName");
+            }
+
+            Exception = exception;
+            ControllerName = controllerName;
+            ActionName = actionName;
+        }
+
+        public string ActionName {
+            get;
+            private set;
+        }
+
+        public string ControllerName {
+            get;
+            private set;
+        }
+
+        public Exception Exception {
+            get;
+            private set;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HiddenInputAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/HiddenInputAttribute.cs
new file mode 100644 (file)
index 0000000..ed8e0b9
--- /dev/null
@@ -0,0 +1,12 @@
+namespace System.Web.Mvc {
+    using System;
+
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Property, AllowMultiple = false, Inherited = true)]
+    public sealed class HiddenInputAttribute : Attribute {
+        public HiddenInputAttribute() {
+            DisplayValue = true;
+        }
+
+        public bool DisplayValue { get; set; }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/ChildActionExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/ChildActionExtensions.cs
new file mode 100644 (file)
index 0000000..c77224c
--- /dev/null
@@ -0,0 +1,149 @@
+namespace System.Web.Mvc.Html {
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.IO;
+    using System.Linq;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    public static class ChildActionExtensions {
+
+        // Action
+
+        public static MvcHtmlString Action(this HtmlHelper htmlHelper, string actionName) {
+            return Action(htmlHelper, actionName, null /* controllerName */, null /* routeValues */);
+        }
+
+        public static MvcHtmlString Action(this HtmlHelper htmlHelper, string actionName, object routeValues) {
+            return Action(htmlHelper, actionName, null /* controllerName */, new RouteValueDictionary(routeValues));
+        }
+
+        public static MvcHtmlString Action(this HtmlHelper htmlHelper, string actionName, RouteValueDictionary routeValues) {
+            return Action(htmlHelper, actionName, null /* controllerName */, routeValues);
+        }
+
+        public static MvcHtmlString Action(this HtmlHelper htmlHelper, string actionName, string controllerName) {
+            return Action(htmlHelper, actionName, controllerName, null /* routeValues */);
+        }
+
+        public static MvcHtmlString Action(this HtmlHelper htmlHelper, string actionName, string controllerName, object routeValues) {
+            return Action(htmlHelper, actionName, controllerName, new RouteValueDictionary(routeValues));
+        }
+
+        public static MvcHtmlString Action(this HtmlHelper htmlHelper, string actionName, string controllerName, RouteValueDictionary routeValues) {
+            using (StringWriter writer = new StringWriter(CultureInfo.CurrentCulture)) {
+                ActionHelper(htmlHelper, actionName, controllerName, routeValues, writer);
+                return MvcHtmlString.Create(writer.ToString());
+            }
+        }
+
+        // RenderAction
+
+        public static void RenderAction(this HtmlHelper htmlHelper, string actionName) {
+            RenderAction(htmlHelper, actionName, null /* controllerName */, null /* routeValues */);
+        }
+
+        public static void RenderAction(this HtmlHelper htmlHelper, string actionName, object routeValues) {
+            RenderAction(htmlHelper, actionName, null /* controllerName */, new RouteValueDictionary(routeValues));
+        }
+
+        public static void RenderAction(this HtmlHelper htmlHelper, string actionName, RouteValueDictionary routeValues) {
+            RenderAction(htmlHelper, actionName, null /* controllerName */, routeValues);
+        }
+
+        public static void RenderAction(this HtmlHelper htmlHelper, string actionName, string controllerName) {
+            RenderAction(htmlHelper, actionName, controllerName, null /* routeValues */);
+        }
+
+        public static void RenderAction(this HtmlHelper htmlHelper, string actionName, string controllerName, object routeValues) {
+            RenderAction(htmlHelper, actionName, controllerName, new RouteValueDictionary(routeValues));
+        }
+
+        public static void RenderAction(this HtmlHelper htmlHelper, string actionName, string controllerName, RouteValueDictionary routeValues) {
+            ActionHelper(htmlHelper, actionName, controllerName, routeValues, htmlHelper.ViewContext.Writer);
+        }
+
+        // Helpers
+
+        internal static void ActionHelper(HtmlHelper htmlHelper, string actionName, string controllerName, RouteValueDictionary routeValues, TextWriter textWriter) {
+            if (htmlHelper == null) {
+                throw new ArgumentNullException("htmlHelper");
+            }
+            if (String.IsNullOrEmpty(actionName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "actionName");
+            }
+
+            RouteValueDictionary additionalRouteValues = routeValues;
+            routeValues = MergeDictionaries(routeValues, htmlHelper.ViewContext.RouteData.Values);
+                     
+            routeValues["action"] = actionName;
+            if (!String.IsNullOrEmpty(controllerName)) {
+                routeValues["controller"] = controllerName;
+            }
+
+            bool usingAreas;
+            VirtualPathData vpd = htmlHelper.RouteCollection.GetVirtualPathForArea(htmlHelper.ViewContext.RequestContext, null /* name */, routeValues, out usingAreas);
+            if (vpd == null) {
+                throw new InvalidOperationException(MvcResources.Common_NoRouteMatched);
+            }
+   
+            if (usingAreas) {
+                routeValues.Remove("area");
+                if (additionalRouteValues != null) {
+                    additionalRouteValues.Remove("area");
+                }
+            }
+
+            if (additionalRouteValues != null) {
+                routeValues[ChildActionValueProvider.ChildActionValuesKey] = new DictionaryValueProvider<object>(additionalRouteValues, CultureInfo.InvariantCulture);
+            }
+
+            RouteData routeData = CreateRouteData(vpd.Route, routeValues, vpd.DataTokens, htmlHelper.ViewContext);
+            HttpContextBase httpContext = htmlHelper.ViewContext.HttpContext;
+            RequestContext requestContext = new RequestContext(httpContext, routeData);
+            ChildActionMvcHandler handler = new ChildActionMvcHandler(requestContext);
+            httpContext.Server.Execute(HttpHandlerUtil.WrapForServerExecute(handler), textWriter, true /* preserveForm */);
+        }
+
+        private static RouteData CreateRouteData(RouteBase route, RouteValueDictionary routeValues, RouteValueDictionary dataTokens, ViewContext parentViewContext) {
+            RouteData routeData = new RouteData();
+
+            foreach (KeyValuePair<string, object> kvp in routeValues) {
+                routeData.Values.Add(kvp.Key, kvp.Value);
+            }
+
+            foreach (KeyValuePair<string, object> kvp in dataTokens) {
+                routeData.DataTokens.Add(kvp.Key, kvp.Value);
+            }
+
+            routeData.Route = route;
+            routeData.DataTokens[ControllerContext.PARENT_ACTION_VIEWCONTEXT] = parentViewContext;
+            return routeData;
+        }
+
+        private static RouteValueDictionary MergeDictionaries(params RouteValueDictionary[] dictionaries) {
+            // Merge existing route values with the user provided values
+            var result = new RouteValueDictionary();
+
+            foreach (RouteValueDictionary dictionary in dictionaries.Where(d => d != null)) {
+                foreach (KeyValuePair<string, object> kvp in dictionary) {
+                    if (!result.ContainsKey(kvp.Key)) {
+                        result.Add(kvp.Key, kvp.Value);
+                    }
+                }
+            }
+
+            return result;
+        }
+
+        internal class ChildActionMvcHandler : MvcHandler {
+            public ChildActionMvcHandler(RequestContext context)
+                : base(context) {
+            }
+
+            protected internal override void AddVersionHeader(HttpContextBase httpContext) {
+                // No version header for child actions
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/DefaultDisplayTemplates.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/DefaultDisplayTemplates.cs
new file mode 100644 (file)
index 0000000..5a24792
--- /dev/null
@@ -0,0 +1,194 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Data;
+    using System.Globalization;
+    using System.Linq;
+    using System.Text;
+    using System.Web.Mvc.Resources;
+    using System.Web.UI.WebControls;
+
+    internal static class DefaultDisplayTemplates {
+        internal static string BooleanTemplate(HtmlHelper html) {
+            bool? value = null;
+            if (html.ViewContext.ViewData.Model != null) {
+                value = Convert.ToBoolean(html.ViewContext.ViewData.Model, CultureInfo.InvariantCulture);
+            }
+
+            return html.ViewContext.ViewData.ModelMetadata.IsNullableValueType
+                        ? BooleanTemplateDropDownList(value)
+                        : BooleanTemplateCheckbox(value ?? false);
+        }
+
+        private static string BooleanTemplateCheckbox(bool value) {
+            TagBuilder inputTag = new TagBuilder("input");
+            inputTag.AddCssClass("check-box");
+            inputTag.Attributes["disabled"] = "disabled";
+            inputTag.Attributes["type"] = "checkbox";
+            if (value) {
+                inputTag.Attributes["checked"] = "checked";
+            }
+
+            return inputTag.ToString(TagRenderMode.SelfClosing);
+        }
+
+        private static string BooleanTemplateDropDownList(bool? value) {
+            StringBuilder builder = new StringBuilder();
+
+            TagBuilder selectTag = new TagBuilder("select");
+            selectTag.AddCssClass("list-box");
+            selectTag.AddCssClass("tri-state");
+            selectTag.Attributes["disabled"] = "disabled";
+            builder.Append(selectTag.ToString(TagRenderMode.StartTag));
+
+            foreach (SelectListItem item in DefaultEditorTemplates.TriStateValues(value)) {
+                builder.Append(SelectExtensions.ListItemToOption(item));
+            }
+
+            builder.Append(selectTag.ToString(TagRenderMode.EndTag));
+            return builder.ToString();
+        }
+
+        internal static string CollectionTemplate(HtmlHelper html) {
+            return CollectionTemplate(html, TemplateHelpers.TemplateHelper);
+        }
+
+        internal static string CollectionTemplate(HtmlHelper html, TemplateHelpers.TemplateHelperDelegate templateHelper) {
+            object model = html.ViewContext.ViewData.ModelMetadata.Model;
+            if (model == null) {
+                return String.Empty;
+            }
+
+            IEnumerable collection = model as IEnumerable;
+            if (collection == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.Templates_TypeMustImplementIEnumerable,
+                        model.GetType().FullName
+                    )
+                );
+            }
+
+            Type typeInCollection = typeof(string);
+            Type genericEnumerableType = TypeHelpers.ExtractGenericInterface(collection.GetType(), typeof(IEnumerable<>));
+            if (genericEnumerableType != null) {
+                typeInCollection = genericEnumerableType.GetGenericArguments()[0];
+            }
+            bool typeInCollectionIsNullableValueType = TypeHelpers.IsNullableValueType(typeInCollection);
+
+            string oldPrefix = html.ViewContext.ViewData.TemplateInfo.HtmlFieldPrefix;
+
+            try {
+                html.ViewContext.ViewData.TemplateInfo.HtmlFieldPrefix = String.Empty;
+
+                string fieldNameBase = oldPrefix;
+                StringBuilder result = new StringBuilder();
+                int index = 0;
+
+                foreach (object item in collection) {
+                    Type itemType = typeInCollection;
+                    if (item != null && !typeInCollectionIsNullableValueType) {
+                        itemType = item.GetType();
+                    }
+                    ModelMetadata metadata = ModelMetadataProviders.Current.GetMetadataForType(() => item, itemType);
+                    string fieldName = String.Format(CultureInfo.InvariantCulture, "{0}[{1}]", fieldNameBase, index++);
+                    string output = templateHelper(html, metadata, fieldName, null /* templateName */, DataBoundControlMode.ReadOnly, null /* additionalViewData */);
+                    result.Append(output);
+                }
+
+                return result.ToString();
+            }
+            finally {
+                html.ViewContext.ViewData.TemplateInfo.HtmlFieldPrefix = oldPrefix;
+            }
+        }
+
+        internal static string DecimalTemplate(HtmlHelper html) {
+            if (html.ViewContext.ViewData.TemplateInfo.FormattedModelValue == html.ViewContext.ViewData.ModelMetadata.Model) {
+                html.ViewContext.ViewData.TemplateInfo.FormattedModelValue = String.Format(CultureInfo.CurrentCulture, "{0:0.00}", html.ViewContext.ViewData.ModelMetadata.Model);
+            }
+
+            return StringTemplate(html);
+        }
+
+        internal static string EmailAddressTemplate(HtmlHelper html) {
+            return String.Format(CultureInfo.InvariantCulture,
+                                 "<a href=\"mailto:{0}\">{1}</a>",
+                                 html.AttributeEncode(html.ViewContext.ViewData.Model),
+                                 html.Encode(html.ViewContext.ViewData.TemplateInfo.FormattedModelValue));
+        }
+
+        internal static string HiddenInputTemplate(HtmlHelper html) {
+            if (html.ViewContext.ViewData.ModelMetadata.HideSurroundingHtml) {
+                return String.Empty;
+            }
+            return StringTemplate(html);
+        }
+
+        internal static string HtmlTemplate(HtmlHelper html) {
+            return html.ViewContext.ViewData.TemplateInfo.FormattedModelValue.ToString();
+        }
+
+        internal static string ObjectTemplate(HtmlHelper html) {
+            return ObjectTemplate(html, TemplateHelpers.TemplateHelper);
+        }
+
+        internal static string ObjectTemplate(HtmlHelper html, TemplateHelpers.TemplateHelperDelegate templateHelper) {
+            ViewDataDictionary viewData = html.ViewContext.ViewData;
+            TemplateInfo templateInfo = viewData.TemplateInfo;
+            ModelMetadata modelMetadata = viewData.ModelMetadata;
+            StringBuilder builder = new StringBuilder();
+
+            if (modelMetadata.Model == null) {    // DDB #225237
+                return modelMetadata.NullDisplayText;
+            }
+
+            if (templateInfo.TemplateDepth > 1) {    // DDB #224751
+                return modelMetadata.SimpleDisplayText;
+            }
+
+            foreach (ModelMetadata propertyMetadata in modelMetadata.Properties.Where(pm => ShouldShow(pm, templateInfo))) {
+                if (!propertyMetadata.HideSurroundingHtml) {
+                    string label = propertyMetadata.GetDisplayName();
+                    if (!String.IsNullOrEmpty(label)) {
+                        builder.AppendFormat(CultureInfo.InvariantCulture, "<div class=\"display-label\">{0}</div>", label);
+                        builder.AppendLine();
+                    }
+
+                    builder.Append("<div class=\"display-field\">");
+                }
+
+                builder.Append(templateHelper(html, propertyMetadata, propertyMetadata.PropertyName, null /* templateName */, DataBoundControlMode.ReadOnly, null /* additionalViewData */));
+
+                if (!propertyMetadata.HideSurroundingHtml) {
+                    builder.AppendLine("</div>");
+                }
+            }
+
+            return builder.ToString();
+        }
+
+        private static bool ShouldShow(ModelMetadata metadata, TemplateInfo templateInfo) {
+            return
+                metadata.ShowForDisplay
+#if !MONO
+                && metadata.ModelType != typeof(EntityState)
+#endif
+                && !metadata.IsComplexType
+                && !templateInfo.Visited(metadata);
+        }
+
+        internal static string StringTemplate(HtmlHelper html) {
+            return html.Encode(html.ViewContext.ViewData.TemplateInfo.FormattedModelValue);
+        }
+
+        internal static string UrlTemplate(HtmlHelper html) {
+            return String.Format(CultureInfo.InvariantCulture,
+                                 "<a href=\"{0}\">{1}</a>",
+                                 html.AttributeEncode(html.ViewContext.ViewData.Model),
+                                 html.Encode(html.ViewContext.ViewData.TemplateInfo.FormattedModelValue));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/DefaultEditorTemplates.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/DefaultEditorTemplates.cs
new file mode 100644 (file)
index 0000000..2db72c9
--- /dev/null
@@ -0,0 +1,203 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Data;
+    using System.Data.Linq;
+    using System.Globalization;
+    using System.Linq;
+    using System.Text;
+    using System.Web.Mvc.Resources;
+    using System.Web.UI.WebControls;
+
+    internal static class DefaultEditorTemplates {
+        internal static string BooleanTemplate(HtmlHelper html) {
+            bool? value = null;
+            if (html.ViewContext.ViewData.Model != null) {
+                value = Convert.ToBoolean(html.ViewContext.ViewData.Model, CultureInfo.InvariantCulture);
+            }
+
+            return html.ViewContext.ViewData.ModelMetadata.IsNullableValueType
+                        ? BooleanTemplateDropDownList(html, value)
+                        : BooleanTemplateCheckbox(html, value ?? false);
+        }
+
+        private static string BooleanTemplateCheckbox(HtmlHelper html, bool value) {
+            return html.CheckBox(String.Empty, value, CreateHtmlAttributes("check-box")).ToHtmlString();
+        }
+
+        private static string BooleanTemplateDropDownList(HtmlHelper html, bool? value) {
+            return html.DropDownList(String.Empty, TriStateValues(value), CreateHtmlAttributes("list-box tri-state")).ToHtmlString();
+
+        }
+
+        internal static string CollectionTemplate(HtmlHelper html) {
+            return CollectionTemplate(html, TemplateHelpers.TemplateHelper);
+        }
+
+        internal static string CollectionTemplate(HtmlHelper html, TemplateHelpers.TemplateHelperDelegate templateHelper) {
+            object model = html.ViewContext.ViewData.ModelMetadata.Model;
+            if (model == null) {
+                return String.Empty;
+            }
+
+            IEnumerable collection = model as IEnumerable;
+            if (collection == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.Templates_TypeMustImplementIEnumerable,
+                        model.GetType().FullName
+                    )
+                );
+            }
+
+            Type typeInCollection = typeof(string);
+            Type genericEnumerableType = TypeHelpers.ExtractGenericInterface(collection.GetType(), typeof(IEnumerable<>));
+            if (genericEnumerableType != null) {
+                typeInCollection = genericEnumerableType.GetGenericArguments()[0];
+            }
+            bool typeInCollectionIsNullableValueType = TypeHelpers.IsNullableValueType(typeInCollection);
+
+            string oldPrefix = html.ViewContext.ViewData.TemplateInfo.HtmlFieldPrefix;
+
+            try {
+                html.ViewContext.ViewData.TemplateInfo.HtmlFieldPrefix = String.Empty;
+
+                string fieldNameBase = oldPrefix;
+                StringBuilder result = new StringBuilder();
+                int index = 0;
+
+                foreach (object item in collection) {
+                    Type itemType = typeInCollection;
+                    if (item != null && !typeInCollectionIsNullableValueType) {
+                        itemType = item.GetType();
+                    }
+                    ModelMetadata metadata = ModelMetadataProviders.Current.GetMetadataForType(() => item, itemType);
+                    string fieldName = String.Format(CultureInfo.InvariantCulture, "{0}[{1}]", fieldNameBase, index++);
+                    string output = templateHelper(html, metadata, fieldName, null /* templateName */, DataBoundControlMode.Edit, null /* additionalViewData */);
+                    result.Append(output);
+                }
+
+                return result.ToString();
+            }
+            finally {
+                html.ViewContext.ViewData.TemplateInfo.HtmlFieldPrefix = oldPrefix;
+            }
+        }
+
+        internal static string DecimalTemplate(HtmlHelper html) {
+            if (html.ViewContext.ViewData.TemplateInfo.FormattedModelValue == html.ViewContext.ViewData.ModelMetadata.Model) {
+                html.ViewContext.ViewData.TemplateInfo.FormattedModelValue = String.Format(CultureInfo.CurrentCulture, "{0:0.00}", html.ViewContext.ViewData.ModelMetadata.Model);
+            }
+
+            return StringTemplate(html);
+        }
+
+        internal static string HiddenInputTemplate(HtmlHelper html) {
+            string result;
+
+            if (html.ViewContext.ViewData.ModelMetadata.HideSurroundingHtml) {
+                result = String.Empty;
+            }
+            else {
+                result = DefaultDisplayTemplates.StringTemplate(html);
+            }
+
+            object model = html.ViewContext.ViewData.Model;
+
+            Binary modelAsBinary = model as Binary;
+            if (modelAsBinary != null) {
+                model = Convert.ToBase64String(modelAsBinary.ToArray());
+            }
+            else {
+                byte[] modelAsByteArray = model as byte[];
+                if (modelAsByteArray != null) {
+                    model = Convert.ToBase64String(modelAsByteArray);
+                }
+            }
+
+            result += html.Hidden(String.Empty, model).ToHtmlString();
+            return result;
+        }
+
+        internal static string MultilineTextTemplate(HtmlHelper html) {
+            return html.TextArea(String.Empty,
+                                 html.ViewContext.ViewData.TemplateInfo.FormattedModelValue.ToString(),
+                                 0 /* rows */, 0 /* columns */,
+                                 CreateHtmlAttributes("text-box multi-line")).ToHtmlString();
+        }
+
+        private static IDictionary<string, object> CreateHtmlAttributes(string className) {
+            return new Dictionary<string, object>() {
+                { "class", className }
+            };
+        }
+
+        internal static string ObjectTemplate(HtmlHelper html) {
+            return ObjectTemplate(html, TemplateHelpers.TemplateHelper);
+        }
+
+        internal static string ObjectTemplate(HtmlHelper html, TemplateHelpers.TemplateHelperDelegate templateHelper) {
+            ViewDataDictionary viewData = html.ViewContext.ViewData;
+            TemplateInfo templateInfo = viewData.TemplateInfo;
+            ModelMetadata modelMetadata = viewData.ModelMetadata;
+            StringBuilder builder = new StringBuilder();
+
+            if (templateInfo.TemplateDepth > 1) {    // DDB #224751
+                return modelMetadata.Model == null ? modelMetadata.NullDisplayText : modelMetadata.SimpleDisplayText;
+            }
+
+            foreach (ModelMetadata propertyMetadata in modelMetadata.Properties.Where(pm => ShouldShow(pm, templateInfo))) {
+                if (!propertyMetadata.HideSurroundingHtml) {
+                    string label = LabelExtensions.LabelHelper(html, propertyMetadata, propertyMetadata.PropertyName).ToHtmlString();
+                    if (!String.IsNullOrEmpty(label)) {
+                        builder.AppendFormat(CultureInfo.InvariantCulture, "<div class=\"editor-label\">{0}</div>\r\n", label);
+                    }
+
+                    builder.Append("<div class=\"editor-field\">");
+                }
+
+                builder.Append(templateHelper(html, propertyMetadata, propertyMetadata.PropertyName, null /* templateName */, DataBoundControlMode.Edit, null /* additionalViewData */));
+
+                if (!propertyMetadata.HideSurroundingHtml) {
+                    builder.Append(" ");
+                    builder.Append(html.ValidationMessage(propertyMetadata.PropertyName));
+                    builder.Append("</div>\r\n");
+                }
+            }
+
+            return builder.ToString();
+        }
+
+        internal static string PasswordTemplate(HtmlHelper html) {
+            return html.Password(String.Empty,
+                                 html.ViewContext.ViewData.TemplateInfo.FormattedModelValue,
+                                 CreateHtmlAttributes("text-box single-line password")).ToHtmlString();
+        }
+
+        private static bool ShouldShow(ModelMetadata metadata, TemplateInfo templateInfo) {
+            return
+                metadata.ShowForEdit
+#if !MONO
+                && metadata.ModelType != typeof(EntityState)
+#endif
+                && !metadata.IsComplexType
+                && !templateInfo.Visited(metadata);
+        }
+
+        internal static string StringTemplate(HtmlHelper html) {
+            return html.TextBox(String.Empty,
+                                html.ViewContext.ViewData.TemplateInfo.FormattedModelValue,
+                                CreateHtmlAttributes("text-box single-line")).ToHtmlString();
+        }
+
+        internal static List<SelectListItem> TriStateValues(bool? value) {
+            return new List<SelectListItem> {
+                new SelectListItem { Text = MvcResources.Common_TriState_NotSet, Value = String.Empty, Selected = !value.HasValue },
+                new SelectListItem { Text = MvcResources.Common_TriState_True, Value = "true", Selected = value.HasValue && value.Value },
+                new SelectListItem { Text = MvcResources.Common_TriState_False, Value = "false", Selected = value.HasValue && !value.Value },
+            };
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/DisplayExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/DisplayExtensions.cs
new file mode 100644 (file)
index 0000000..73312e9
--- /dev/null
@@ -0,0 +1,85 @@
+namespace System.Web.Mvc.Html {
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+    using System.Web.UI.WebControls;
+
+    public static class DisplayExtensions {
+        public static MvcHtmlString Display(this HtmlHelper html, string expression) {
+            return TemplateHelpers.Template(html, expression, null /* templateName */, null /* htmlFieldName */, DataBoundControlMode.ReadOnly, null /* additionalViewData */);
+        }
+
+        public static MvcHtmlString Display(this HtmlHelper html, string expression, object additionalViewData) {
+            return TemplateHelpers.Template(html, expression, null /* templateName */, null /* htmlFieldName */, DataBoundControlMode.ReadOnly, additionalViewData);
+        }
+
+        public static MvcHtmlString Display(this HtmlHelper html, string expression, string templateName) {
+            return TemplateHelpers.Template(html, expression, templateName, null /* htmlFieldName */, DataBoundControlMode.ReadOnly, null /* additionalViewData */);
+        }
+
+        public static MvcHtmlString Display(this HtmlHelper html, string expression, string templateName, object additionalViewData) {
+            return TemplateHelpers.Template(html, expression, templateName, null /* htmlFieldName */, DataBoundControlMode.ReadOnly, additionalViewData);
+        }
+
+        public static MvcHtmlString Display(this HtmlHelper html, string expression, string templateName, string htmlFieldName) {
+            return TemplateHelpers.Template(html, expression, templateName, htmlFieldName, DataBoundControlMode.ReadOnly, null /* additionalViewData */);
+        }
+
+        public static MvcHtmlString Display(this HtmlHelper html, string expression, string templateName, string htmlFieldName, object additionalViewData) {
+            return TemplateHelpers.Template(html, expression, templateName, htmlFieldName, DataBoundControlMode.ReadOnly, additionalViewData);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DisplayFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression) {
+            return TemplateHelpers.TemplateFor(html, expression, null /* templateName */, null /* htmlFieldName */, DataBoundControlMode.ReadOnly, null /* additionalViewData */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DisplayFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, object additionalViewData) {
+            return TemplateHelpers.TemplateFor(html, expression, null /* templateName */, null /* htmlFieldName */, DataBoundControlMode.ReadOnly, additionalViewData);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DisplayFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, string templateName) {
+            return TemplateHelpers.TemplateFor(html, expression, templateName, null /* htmlFieldName */, DataBoundControlMode.ReadOnly, null /* additionalViewData */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DisplayFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, string templateName, object additionalViewData) {
+            return TemplateHelpers.TemplateFor(html, expression, templateName, null /* htmlFieldName */, DataBoundControlMode.ReadOnly, additionalViewData);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DisplayFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, string templateName, string htmlFieldName) {
+            return TemplateHelpers.TemplateFor(html, expression, templateName, htmlFieldName, DataBoundControlMode.ReadOnly, null /* additionalViewData */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DisplayFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, string templateName, string htmlFieldName, object additionalViewData) {
+            return TemplateHelpers.TemplateFor(html, expression, templateName, htmlFieldName, DataBoundControlMode.ReadOnly, additionalViewData);
+        }
+
+        public static MvcHtmlString DisplayForModel(this HtmlHelper html) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, String.Empty, null /* templateName */, DataBoundControlMode.ReadOnly, null /* additionalViewData */));
+        }
+
+        public static MvcHtmlString DisplayForModel(this HtmlHelper html, object additionalViewData) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, String.Empty, null /* templateName */, DataBoundControlMode.ReadOnly, additionalViewData));
+        }
+
+        public static MvcHtmlString DisplayForModel(this HtmlHelper html, string templateName) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, String.Empty, templateName, DataBoundControlMode.ReadOnly, null /* additionalViewData */));
+        }
+
+        public static MvcHtmlString DisplayForModel(this HtmlHelper html, string templateName, object additionalViewData) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, String.Empty, templateName, DataBoundControlMode.ReadOnly, additionalViewData));
+        }
+
+        public static MvcHtmlString DisplayForModel(this HtmlHelper html, string templateName, string htmlFieldName) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, htmlFieldName, templateName, DataBoundControlMode.ReadOnly, null /* additionalViewData */));
+        }
+
+        public static MvcHtmlString DisplayForModel(this HtmlHelper html, string templateName, string htmlFieldName, object additionalViewData) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, htmlFieldName, templateName, DataBoundControlMode.ReadOnly, additionalViewData));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/DisplayTextExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/DisplayTextExtensions.cs
new file mode 100644 (file)
index 0000000..9d31896
--- /dev/null
@@ -0,0 +1,20 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+
+    public static class DisplayTextExtensions {
+        public static MvcHtmlString DisplayText(this HtmlHelper html, string name) {
+            return DisplayTextHelper(ModelMetadata.FromStringExpression(name, html.ViewContext.ViewData));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DisplayTextFor<TModel, TResult>(this HtmlHelper<TModel> html, Expression<Func<TModel, TResult>> expression) {
+            return DisplayTextHelper(ModelMetadata.FromLambdaExpression(expression, html.ViewData));
+        }
+
+        private static MvcHtmlString DisplayTextHelper(ModelMetadata metadata) {
+            return MvcHtmlString.Create(metadata.SimpleDisplayText);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/EditorExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/EditorExtensions.cs
new file mode 100644 (file)
index 0000000..d3f4354
--- /dev/null
@@ -0,0 +1,86 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq.Expressions;
+    using System.Web.UI.WebControls;
+
+    public static class EditorExtensions {
+        public static MvcHtmlString Editor(this HtmlHelper html, string expression) {
+            return TemplateHelpers.Template(html, expression, null /* templateName */, null /* htmlFieldName */, DataBoundControlMode.Edit, null /* additionalViewData */);
+        }
+
+        public static MvcHtmlString Editor(this HtmlHelper html, string expression, object additionalViewData) {
+            return TemplateHelpers.Template(html, expression, null /* templateName */, null /* htmlFieldName */, DataBoundControlMode.Edit, additionalViewData);
+        }
+
+        public static MvcHtmlString Editor(this HtmlHelper html, string expression, string templateName) {
+            return TemplateHelpers.Template(html, expression, templateName, null /* htmlFieldName */, DataBoundControlMode.Edit, null /* additionalViewData */);
+        }
+
+        public static MvcHtmlString Editor(this HtmlHelper html, string expression, string templateName, object additionalViewData) {
+            return TemplateHelpers.Template(html, expression, templateName, null /* htmlFieldName */, DataBoundControlMode.Edit, additionalViewData);
+        }
+
+        public static MvcHtmlString Editor(this HtmlHelper html, string expression, string templateName, string htmlFieldName) {
+            return TemplateHelpers.Template(html, expression, templateName, htmlFieldName, DataBoundControlMode.Edit, null /* additionalViewData */);
+        }
+
+        public static MvcHtmlString Editor(this HtmlHelper html, string expression, string templateName, string htmlFieldName, object additionalViewData) {
+            return TemplateHelpers.Template(html, expression, templateName, htmlFieldName, DataBoundControlMode.Edit, additionalViewData);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString EditorFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression) {
+            return TemplateHelpers.TemplateFor(html, expression, null /* templateName */, null /* htmlFieldName */, DataBoundControlMode.Edit, null /* additionalViewData */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString EditorFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, object additionalViewData) {
+            return TemplateHelpers.TemplateFor(html, expression, null /* templateName */, null /* htmlFieldName */, DataBoundControlMode.Edit, additionalViewData);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString EditorFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, string templateName) {
+            return TemplateHelpers.TemplateFor(html, expression, templateName, null /* htmlFieldName */, DataBoundControlMode.Edit, null /* additionalViewData */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString EditorFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, string templateName, object additionalViewData) {
+            return TemplateHelpers.TemplateFor(html, expression, templateName, null /* htmlFieldName */, DataBoundControlMode.Edit, additionalViewData);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString EditorFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, string templateName, string htmlFieldName) {
+            return TemplateHelpers.TemplateFor(html, expression, templateName, htmlFieldName, DataBoundControlMode.Edit, null /* additionalViewData */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString EditorFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, string templateName, string htmlFieldName, object additionalViewData) {
+            return TemplateHelpers.TemplateFor(html, expression, templateName, htmlFieldName, DataBoundControlMode.Edit, additionalViewData);
+        }
+
+        public static MvcHtmlString EditorForModel(this HtmlHelper html) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, String.Empty, null /* templateName */, DataBoundControlMode.Edit, null /* additionalViewData */));
+        }
+
+        public static MvcHtmlString EditorForModel(this HtmlHelper html, object additionalViewData) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, String.Empty, null /* templateName */, DataBoundControlMode.Edit, additionalViewData));
+        }
+
+        public static MvcHtmlString EditorForModel(this HtmlHelper html, string templateName) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, String.Empty, templateName, DataBoundControlMode.Edit, null /* additionalViewData */));
+        }
+
+        public static MvcHtmlString EditorForModel(this HtmlHelper html, string templateName, object additionalViewData) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, String.Empty, templateName, DataBoundControlMode.Edit, additionalViewData));
+        }
+
+        public static MvcHtmlString EditorForModel(this HtmlHelper html, string templateName, string htmlFieldName) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, htmlFieldName, templateName, DataBoundControlMode.Edit, null /* additionalViewData */));
+        }
+
+        public static MvcHtmlString EditorForModel(this HtmlHelper html, string templateName, string htmlFieldName, object additionalViewData) {
+            return MvcHtmlString.Create(TemplateHelpers.TemplateHelper(html, html.ViewData.ModelMetadata, htmlFieldName, templateName, DataBoundControlMode.Edit, additionalViewData));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/FormExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/FormExtensions.cs
new file mode 100644 (file)
index 0000000..5bd7791
--- /dev/null
@@ -0,0 +1,143 @@
+namespace System.Web.Mvc.Html {
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web.Routing;
+
+    public static class FormExtensions {
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper) {
+            // generates <form action="{current url}" method="post">...</form>
+            string formAction = htmlHelper.ViewContext.HttpContext.Request.RawUrl;
+            return FormHelper(htmlHelper, formAction, FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, object routeValues) {
+            return BeginForm(htmlHelper, null, null, new RouteValueDictionary(routeValues), FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, RouteValueDictionary routeValues) {
+            return BeginForm(htmlHelper, null, null, routeValues, FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName) {
+            return BeginForm(htmlHelper, actionName, controllerName, new RouteValueDictionary(), FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName, object routeValues) {
+            return BeginForm(htmlHelper, actionName, controllerName, new RouteValueDictionary(routeValues), FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName, RouteValueDictionary routeValues) {
+            return BeginForm(htmlHelper, actionName, controllerName, routeValues, FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName, FormMethod method) {
+            return BeginForm(htmlHelper, actionName, controllerName, new RouteValueDictionary(), method, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName, object routeValues, FormMethod method) {
+            return BeginForm(htmlHelper, actionName, controllerName, new RouteValueDictionary(routeValues), method, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName, RouteValueDictionary routeValues, FormMethod method) {
+            return BeginForm(htmlHelper, actionName, controllerName, routeValues, method, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName, FormMethod method, object htmlAttributes) {
+            return BeginForm(htmlHelper, actionName, controllerName, new RouteValueDictionary(), method, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName, FormMethod method, IDictionary<string, object> htmlAttributes) {
+            return BeginForm(htmlHelper, actionName, controllerName, new RouteValueDictionary(), method, htmlAttributes);
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName, object routeValues, FormMethod method, object htmlAttributes) {
+            return BeginForm(htmlHelper, actionName, controllerName, new RouteValueDictionary(routeValues), method, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcForm BeginForm(this HtmlHelper htmlHelper, string actionName, string controllerName, RouteValueDictionary routeValues, FormMethod method, IDictionary<string, object> htmlAttributes) {
+            string formAction = UrlHelper.GenerateUrl(null /* routeName */, actionName, controllerName, routeValues, htmlHelper.RouteCollection, htmlHelper.ViewContext.RequestContext, true /* includeImplicitMvcValues */);
+            return FormHelper(htmlHelper, formAction, method, htmlAttributes);
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, object routeValues) {
+            return BeginRouteForm(htmlHelper, null /* routeName */, new RouteValueDictionary(routeValues), FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, RouteValueDictionary routeValues) {
+            return BeginRouteForm(htmlHelper, null /* routeName */, routeValues, FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName) {
+            return BeginRouteForm(htmlHelper, routeName, new RouteValueDictionary(), FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName, object routeValues) {
+            return BeginRouteForm(htmlHelper, routeName, new RouteValueDictionary(routeValues), FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName, RouteValueDictionary routeValues) {
+            return BeginRouteForm(htmlHelper, routeName, routeValues, FormMethod.Post, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName, FormMethod method) {
+            return BeginRouteForm(htmlHelper, routeName, new RouteValueDictionary(), method, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName, object routeValues, FormMethod method) {
+            return BeginRouteForm(htmlHelper, routeName, new RouteValueDictionary(routeValues), method, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName, RouteValueDictionary routeValues, FormMethod method) {
+            return BeginRouteForm(htmlHelper, routeName, routeValues, method, new RouteValueDictionary());
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName, FormMethod method, object htmlAttributes) {
+            return BeginRouteForm(htmlHelper, routeName, new RouteValueDictionary(), method, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName, FormMethod method, IDictionary<string, object> htmlAttributes) {
+            return BeginRouteForm(htmlHelper, routeName, new RouteValueDictionary(), method, htmlAttributes);
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName, object routeValues, FormMethod method, object htmlAttributes) {
+            return BeginRouteForm(htmlHelper, routeName, new RouteValueDictionary(routeValues), method, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcForm BeginRouteForm(this HtmlHelper htmlHelper, string routeName, RouteValueDictionary routeValues, FormMethod method, IDictionary<string, object> htmlAttributes) {
+            string formAction = UrlHelper.GenerateUrl(routeName, null, null, routeValues, htmlHelper.RouteCollection, htmlHelper.ViewContext.RequestContext, false /* includeImplicitMvcValues */);
+            return FormHelper(htmlHelper, formAction, method, htmlAttributes);
+        }
+
+        public static void EndForm(this HtmlHelper htmlHelper) {
+            htmlHelper.ViewContext.Writer.Write("</form>");
+            htmlHelper.ViewContext.OutputClientValidation();
+        }
+
+        [SuppressMessage("Microsoft.Reliability", "CA2000:Dispose objects before losing scope", Justification = "Because disposing the object would write to the response stream, you don't want to prematurely dispose of this object.")]
+        private static MvcForm FormHelper(this HtmlHelper htmlHelper, string formAction, FormMethod method, IDictionary<string, object> htmlAttributes) {
+            TagBuilder tagBuilder = new TagBuilder("form");
+            tagBuilder.MergeAttributes(htmlAttributes);
+            // action is implicitly generated, so htmlAttributes take precedence.
+            tagBuilder.MergeAttribute("action", formAction);
+            // method is an explicit parameter, so it takes precedence over the htmlAttributes.
+            tagBuilder.MergeAttribute("method", HtmlHelper.GetFormMethodString(method), true);
+
+            bool traditionalJavascriptEnabled = htmlHelper.ViewContext.ClientValidationEnabled
+                                            && !htmlHelper.ViewContext.UnobtrusiveJavaScriptEnabled;
+
+            if (traditionalJavascriptEnabled) {
+                // forms must have an ID for client validation
+                tagBuilder.GenerateId(htmlHelper.ViewContext.FormIdGenerator());
+            }
+
+            htmlHelper.ViewContext.Writer.Write(tagBuilder.ToString(TagRenderMode.StartTag));
+            MvcForm theForm = new MvcForm(htmlHelper.ViewContext);
+
+            if (traditionalJavascriptEnabled) {
+                htmlHelper.ViewContext.FormContext.FormId = tagBuilder.Attributes["id"];
+            }
+
+            return theForm;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/InputExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/InputExtensions.cs
new file mode 100644 (file)
index 0000000..7c7aa6b
--- /dev/null
@@ -0,0 +1,396 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Collections.Generic;
+    using System.Data.Linq;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq.Expressions;
+    using System.Text;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    public static class InputExtensions {
+        // CheckBox
+
+        public static MvcHtmlString CheckBox(this HtmlHelper htmlHelper, string name) {
+            return CheckBox(htmlHelper, name, (object)null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString CheckBox(this HtmlHelper htmlHelper, string name, bool isChecked) {
+            return CheckBox(htmlHelper, name, isChecked, (object)null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString CheckBox(this HtmlHelper htmlHelper, string name, bool isChecked, object htmlAttributes) {
+            return CheckBox(htmlHelper, name, isChecked, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString CheckBox(this HtmlHelper htmlHelper, string name, object htmlAttributes) {
+            return CheckBox(htmlHelper, name, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString CheckBox(this HtmlHelper htmlHelper, string name, IDictionary<string, object> htmlAttributes) {
+            return CheckBoxHelper(htmlHelper, null, name, null /* isChecked */, htmlAttributes);
+        }
+
+        public static MvcHtmlString CheckBox(this HtmlHelper htmlHelper, string name, bool isChecked, IDictionary<string, object> htmlAttributes) {
+            return CheckBoxHelper(htmlHelper, null, name, isChecked, htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString CheckBoxFor<TModel>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, bool>> expression) {
+            return CheckBoxFor(htmlHelper, expression, null /* htmlAttributes */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString CheckBoxFor<TModel>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, bool>> expression, object htmlAttributes) {
+            return CheckBoxFor(htmlHelper, expression, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString CheckBoxFor<TModel>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, bool>> expression, IDictionary<string, object> htmlAttributes) {
+            if (expression == null) {
+                throw new ArgumentNullException("expression");
+            }
+
+            ModelMetadata metadata = ModelMetadata.FromLambdaExpression(expression, htmlHelper.ViewData);
+            bool? isChecked = null;
+            if (metadata.Model != null) {
+                bool modelChecked;
+                if (Boolean.TryParse(metadata.Model.ToString(), out modelChecked)) {
+                    isChecked = modelChecked;
+                }
+            }
+
+            return CheckBoxHelper(htmlHelper, metadata, ExpressionHelper.GetExpressionText(expression), isChecked, htmlAttributes);
+        }
+
+        private static MvcHtmlString CheckBoxHelper(HtmlHelper htmlHelper, ModelMetadata metadata, string name, bool? isChecked, IDictionary<string, object> htmlAttributes) {
+            RouteValueDictionary attributes = ToRouteValueDictionary(htmlAttributes);
+
+            bool explicitValue = isChecked.HasValue;
+            if (explicitValue) {
+                attributes.Remove("checked");    // Explicit value must override dictionary
+            }
+
+            return InputHelper(htmlHelper, InputType.CheckBox, metadata, name, "true", !explicitValue /* useViewData */, isChecked ?? false, true /* setId */, false /* isExplicitValue */, attributes);
+        }
+
+        // Hidden
+
+        public static MvcHtmlString Hidden(this HtmlHelper htmlHelper, string name) {
+            return Hidden(htmlHelper, name, null /* value */, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString Hidden(this HtmlHelper htmlHelper, string name, object value) {
+            return Hidden(htmlHelper, name, value, null /* hmtlAttributes */);
+        }
+
+        public static MvcHtmlString Hidden(this HtmlHelper htmlHelper, string name, object value, object htmlAttributes) {
+            return Hidden(htmlHelper, name, value, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString Hidden(this HtmlHelper htmlHelper, string name, object value, IDictionary<string, object> htmlAttributes) {
+            return HiddenHelper(htmlHelper,
+                                null,
+                                value,
+                                value == null /* useViewData */,
+                                name,
+                                htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString HiddenFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression) {
+            return HiddenFor(htmlHelper, expression, (IDictionary<string, object>)null);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString HiddenFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, object htmlAttributes) {
+            return HiddenFor(htmlHelper, expression, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString HiddenFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IDictionary<string, object> htmlAttributes) {
+            ModelMetadata metadata = ModelMetadata.FromLambdaExpression(expression, htmlHelper.ViewData);
+            return HiddenHelper(htmlHelper,
+                                metadata,
+                                metadata.Model,
+                                false,
+                                ExpressionHelper.GetExpressionText(expression),
+                                htmlAttributes);
+        }
+
+        private static MvcHtmlString HiddenHelper(HtmlHelper htmlHelper, ModelMetadata metadata, object value, bool useViewData, string expression, IDictionary<string, object> htmlAttributes) {
+            Binary binaryValue = value as Binary;
+            if (binaryValue != null) {
+                value = binaryValue.ToArray();
+            }
+
+            byte[] byteArrayValue = value as byte[];
+            if (byteArrayValue != null) {
+                value = Convert.ToBase64String(byteArrayValue);
+            }
+
+            return InputHelper(htmlHelper, InputType.Hidden, metadata, expression, value, useViewData, false /* isChecked */, true /* setId */, true /* isExplicitValue */, htmlAttributes);
+        }
+
+        // Password
+
+        public static MvcHtmlString Password(this HtmlHelper htmlHelper, string name) {
+            return Password(htmlHelper, name, null /* value */);
+        }
+
+        public static MvcHtmlString Password(this HtmlHelper htmlHelper, string name, object value) {
+            return Password(htmlHelper, name, value, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString Password(this HtmlHelper htmlHelper, string name, object value, object htmlAttributes) {
+            return Password(htmlHelper, name, value, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString Password(this HtmlHelper htmlHelper, string name, object value, IDictionary<string, object> htmlAttributes) {
+            return PasswordHelper(htmlHelper, null /* metadata */, name, value, htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString PasswordFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression) {
+            return PasswordFor(htmlHelper, expression, null /* htmlAttributes */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString PasswordFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, object htmlAttributes) {
+            return PasswordFor(htmlHelper, expression, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1011:ConsiderPassingBaseTypesAsParameters", Justification = "Users cannot use anonymous methods with the LambdaExpression type")]
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString PasswordFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IDictionary<string, object> htmlAttributes) {
+            if (expression == null) {
+                throw new ArgumentNullException("expression");
+            }
+
+            return PasswordHelper(htmlHelper,
+                                  ModelMetadata.FromLambdaExpression(expression, htmlHelper.ViewData),
+                                  ExpressionHelper.GetExpressionText(expression),
+                                  null /* value */,
+                                  htmlAttributes);
+        }
+
+        private static MvcHtmlString PasswordHelper(HtmlHelper htmlHelper, ModelMetadata metadata, string name, object value, IDictionary<string, object> htmlAttributes) {
+            return InputHelper(htmlHelper, InputType.Password, metadata, name, value, false /* useViewData */, false /* isChecked */, true /* setId */, true /* isExplicitValue */, htmlAttributes);
+        }
+
+        // RadioButton
+
+        public static MvcHtmlString RadioButton(this HtmlHelper htmlHelper, string name, object value) {
+            return RadioButton(htmlHelper, name, value, (object)null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString RadioButton(this HtmlHelper htmlHelper, string name, object value, object htmlAttributes) {
+            return RadioButton(htmlHelper, name, value, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString RadioButton(this HtmlHelper htmlHelper, string name, object value, IDictionary<string, object> htmlAttributes) {
+            // Determine whether or not to render the checked attribute based on the contents of ViewData.
+            string valueString = Convert.ToString(value, CultureInfo.CurrentCulture);
+            bool isChecked = (!String.IsNullOrEmpty(name)) && (String.Equals(htmlHelper.EvalString(name), valueString, StringComparison.OrdinalIgnoreCase));
+            // checked attributes is implicit, so we need to ensure that the dictionary takes precedence.
+            RouteValueDictionary attributes = ToRouteValueDictionary(htmlAttributes);
+            if (attributes.ContainsKey("checked")) {
+                return InputHelper(htmlHelper, InputType.Radio, null, name, value, false, false, true, true /* isExplicitValue */, attributes);
+            }
+
+            return RadioButton(htmlHelper, name, value, isChecked, htmlAttributes);
+        }
+
+        public static MvcHtmlString RadioButton(this HtmlHelper htmlHelper, string name, object value, bool isChecked) {
+            return RadioButton(htmlHelper, name, value, isChecked, (object)null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString RadioButton(this HtmlHelper htmlHelper, string name, object value, bool isChecked, object htmlAttributes) {
+            return RadioButton(htmlHelper, name, value, isChecked, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString RadioButton(this HtmlHelper htmlHelper, string name, object value, bool isChecked, IDictionary<string, object> htmlAttributes) {
+            if (value == null) {
+                throw new ArgumentNullException("value");
+            }
+            // checked attribute is an explicit parameter so it takes precedence.
+            RouteValueDictionary attributes = ToRouteValueDictionary(htmlAttributes);
+            attributes.Remove("checked");
+            return InputHelper(htmlHelper, InputType.Radio, null, name, value, false, isChecked, true, true /* isExplicitValue */, attributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString RadioButtonFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, object value) {
+            return RadioButtonFor(htmlHelper, expression, value, null /* htmlAttributes */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString RadioButtonFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, object value, object htmlAttributes) {
+            return RadioButtonFor(htmlHelper, expression, value, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString RadioButtonFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, object value, IDictionary<string, object> htmlAttributes) {
+            ModelMetadata metadata = ModelMetadata.FromLambdaExpression(expression, htmlHelper.ViewData);
+            return RadioButtonHelper(htmlHelper,
+                                     metadata,
+                                     metadata.Model,
+                                     ExpressionHelper.GetExpressionText(expression),
+                                     value,
+                                     null /* isChecked */,
+                                     htmlAttributes);
+        }
+
+        private static MvcHtmlString RadioButtonHelper(HtmlHelper htmlHelper, ModelMetadata metadata, object model, string name, object value, bool? isChecked, IDictionary<string, object> htmlAttributes) {
+            if (value == null) {
+                throw new ArgumentNullException("value");
+            }
+
+            RouteValueDictionary attributes = ToRouteValueDictionary(htmlAttributes);
+
+            bool explicitValue = isChecked.HasValue;
+            if (explicitValue) {
+                attributes.Remove("checked");    // Explicit value must override dictionary
+            }
+            else {
+                string valueString = Convert.ToString(value, CultureInfo.CurrentCulture);
+                isChecked = model != null &&
+                            !String.IsNullOrEmpty(name) &&
+                            String.Equals(model.ToString(), valueString, StringComparison.OrdinalIgnoreCase);
+            }
+
+            return InputHelper(htmlHelper, InputType.Radio, metadata, name, value, false /* useViewData */, isChecked ?? false, true /* setId */, true /* isExplicitValue */, attributes);
+        }
+
+        // TextBox
+
+        public static MvcHtmlString TextBox(this HtmlHelper htmlHelper, string name) {
+            return TextBox(htmlHelper, name, null /* value */);
+        }
+
+        public static MvcHtmlString TextBox(this HtmlHelper htmlHelper, string name, object value) {
+            return TextBox(htmlHelper, name, value, (object)null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString TextBox(this HtmlHelper htmlHelper, string name, object value, object htmlAttributes) {
+            return TextBox(htmlHelper, name, value, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString TextBox(this HtmlHelper htmlHelper, string name, object value, IDictionary<string, object> htmlAttributes) {
+            return InputHelper(htmlHelper, InputType.Text, null, name, value, (value == null) /* useViewData */, false /* isChecked */, true /* setId */, true /* isExplicitValue */, htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString TextBoxFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression) {
+            return htmlHelper.TextBoxFor(expression, (IDictionary<string, object>)null);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString TextBoxFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, object htmlAttributes) {
+            return htmlHelper.TextBoxFor(expression, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString TextBoxFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IDictionary<string, object> htmlAttributes) {
+            ModelMetadata metadata = ModelMetadata.FromLambdaExpression(expression, htmlHelper.ViewData);
+            return TextBoxHelper(htmlHelper,
+                                 metadata,
+                                 metadata.Model,
+                                 ExpressionHelper.GetExpressionText(expression),
+                                 htmlAttributes);
+        }
+
+        private static MvcHtmlString TextBoxHelper(this HtmlHelper htmlHelper, ModelMetadata metadata, object model, string expression, IDictionary<string, object> htmlAttributes) {
+            return InputHelper(htmlHelper, InputType.Text, metadata, expression, model, false /* useViewData */, false /* isChecked */, true /* setId */, true /* isExplicitValue */, htmlAttributes);
+        }
+
+        // Helper methods
+
+        private static MvcHtmlString InputHelper(HtmlHelper htmlHelper, InputType inputType, ModelMetadata metadata, string name, object value, bool useViewData, bool isChecked, bool setId, bool isExplicitValue, IDictionary<string, object> htmlAttributes) {
+            string fullName = htmlHelper.ViewContext.ViewData.TemplateInfo.GetFullHtmlFieldName(name);
+            if (String.IsNullOrEmpty(fullName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "name");
+            }
+
+            TagBuilder tagBuilder = new TagBuilder("input");
+            tagBuilder.MergeAttributes(htmlAttributes);
+            tagBuilder.MergeAttribute("type", HtmlHelper.GetInputTypeString(inputType));
+            tagBuilder.MergeAttribute("name", fullName, true);
+
+            string valueParameter = Convert.ToString(value, CultureInfo.CurrentCulture);
+            bool usedModelState = false;
+
+            switch (inputType) {
+                case InputType.CheckBox:
+                    bool? modelStateWasChecked = htmlHelper.GetModelStateValue(fullName, typeof(bool)) as bool?;
+                    if (modelStateWasChecked.HasValue) {
+                        isChecked = modelStateWasChecked.Value;
+                        usedModelState = true;
+                    }
+                    goto case InputType.Radio;
+                case InputType.Radio:
+                    if (!usedModelState) {
+                        string modelStateValue = htmlHelper.GetModelStateValue(fullName, typeof(string)) as string;
+                        if (modelStateValue != null) {
+                            isChecked = String.Equals(modelStateValue, valueParameter, StringComparison.Ordinal);
+                            usedModelState = true;
+                        }
+                    }
+                    if (!usedModelState && useViewData) {
+                        isChecked = htmlHelper.EvalBoolean(fullName);
+                    }
+                    if (isChecked) {
+                        tagBuilder.MergeAttribute("checked", "checked");
+                    }
+                    tagBuilder.MergeAttribute("value", valueParameter, isExplicitValue);
+                    break;
+                case InputType.Password:
+                    if (value != null) {
+                        tagBuilder.MergeAttribute("value", valueParameter, isExplicitValue);
+                    }
+                    break;
+                default:
+                    string attemptedValue = (string)htmlHelper.GetModelStateValue(fullName, typeof(string));
+                    tagBuilder.MergeAttribute("value", attemptedValue ?? ((useViewData) ? htmlHelper.EvalString(fullName) : valueParameter), isExplicitValue);
+                    break;
+            }
+
+            if (setId) {
+                tagBuilder.GenerateId(fullName);
+            }
+
+            // If there are any errors for a named field, we add the css attribute.
+            ModelState modelState;
+            if (htmlHelper.ViewData.ModelState.TryGetValue(fullName, out modelState)) {
+                if (modelState.Errors.Count > 0) {
+                    tagBuilder.AddCssClass(HtmlHelper.ValidationInputCssClassName);
+                }
+            }
+
+            tagBuilder.MergeAttributes(htmlHelper.GetUnobtrusiveValidationAttributes(name, metadata));
+
+            if (inputType == InputType.CheckBox) {
+                // Render an additional <input type="hidden".../> for checkboxes. This
+                // addresses scenarios where unchecked checkboxes are not sent in the request.
+                // Sending a hidden input makes it possible to know that the checkbox was present
+                // on the page when the request was submitted.
+                StringBuilder inputItemBuilder = new StringBuilder();
+                inputItemBuilder.Append(tagBuilder.ToString(TagRenderMode.SelfClosing));
+
+                TagBuilder hiddenInput = new TagBuilder("input");
+                hiddenInput.MergeAttribute("type", HtmlHelper.GetInputTypeString(InputType.Hidden));
+                hiddenInput.MergeAttribute("name", fullName);
+                hiddenInput.MergeAttribute("value", "false");
+                inputItemBuilder.Append(hiddenInput.ToString(TagRenderMode.SelfClosing));
+                return MvcHtmlString.Create(inputItemBuilder.ToString());
+            }
+
+            return tagBuilder.ToMvcHtmlString(TagRenderMode.SelfClosing);
+        }
+
+        private static RouteValueDictionary ToRouteValueDictionary(IDictionary<string, object> dictionary) {
+            return dictionary == null ? new RouteValueDictionary() : new RouteValueDictionary(dictionary);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/LabelExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/LabelExtensions.cs
new file mode 100644 (file)
index 0000000..95dc3c5
--- /dev/null
@@ -0,0 +1,54 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq;
+    using System.Linq.Expressions;
+
+    public static class LabelExtensions {
+        public static MvcHtmlString Label(this HtmlHelper html, string expression) {
+            return Label(html,
+                         expression,
+                         null);
+        }
+
+        public static MvcHtmlString Label(this HtmlHelper html, string expression, string labelText) {
+            return LabelHelper(html,
+                               ModelMetadata.FromStringExpression(expression, html.ViewData),
+                               expression,
+                               labelText);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString LabelFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression) {
+            return LabelFor<TModel, TValue>(html, expression, null);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString LabelFor<TModel, TValue>(this HtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression, string labelText) {
+            return LabelHelper(html,
+                               ModelMetadata.FromLambdaExpression(expression, html.ViewData),
+                               ExpressionHelper.GetExpressionText(expression),
+                               labelText);
+        }
+
+        public static MvcHtmlString LabelForModel(this HtmlHelper html) {
+            return LabelForModel(html, null);
+        }
+
+        public static MvcHtmlString LabelForModel(this HtmlHelper html, string labelText) {
+            return LabelHelper(html, html.ViewData.ModelMetadata, String.Empty, labelText);
+        }
+
+        internal static MvcHtmlString LabelHelper(HtmlHelper html, ModelMetadata metadata, string htmlFieldName, string labelText = null) {
+            string resolvedLabelText = labelText ?? metadata.DisplayName ?? metadata.PropertyName ?? htmlFieldName.Split('.').Last();
+            if (String.IsNullOrEmpty(resolvedLabelText)) {
+                return MvcHtmlString.Empty;
+            }
+
+            TagBuilder tag = new TagBuilder("label");
+            tag.Attributes.Add("for", TagBuilder.CreateSanitizedId(html.ViewContext.ViewData.TemplateInfo.GetFullHtmlFieldName(htmlFieldName)));
+            tag.SetInnerText(resolvedLabelText);
+            return tag.ToMvcHtmlString(TagRenderMode.Normal);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/LinkExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/LinkExtensions.cs
new file mode 100644 (file)
index 0000000..42bfb00
--- /dev/null
@@ -0,0 +1,104 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Collections.Generic;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    public static class LinkExtensions {
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName) {
+            return ActionLink(htmlHelper, linkText, actionName, null /* controllerName */, new RouteValueDictionary(), new RouteValueDictionary());
+        }
+
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName, object routeValues) {
+            return ActionLink(htmlHelper, linkText, actionName, null /* controllerName */, new RouteValueDictionary(routeValues), new RouteValueDictionary());
+        }
+
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName, object routeValues, object htmlAttributes) {
+            return ActionLink(htmlHelper, linkText, actionName, null /* controllerName */, new RouteValueDictionary(routeValues), HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName, RouteValueDictionary routeValues) {
+            return ActionLink(htmlHelper, linkText, actionName, null /* controllerName */, routeValues, new RouteValueDictionary());
+        }
+
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            return ActionLink(htmlHelper, linkText, actionName, null /* controllerName */, routeValues, htmlAttributes);
+        }
+
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName, string controllerName) {
+            return ActionLink(htmlHelper, linkText, actionName, controllerName, new RouteValueDictionary(), new RouteValueDictionary());
+        }
+
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName, string controllerName, object routeValues, object htmlAttributes) {
+            return ActionLink(htmlHelper, linkText, actionName, controllerName, new RouteValueDictionary(routeValues), HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName, string controllerName, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            if (String.IsNullOrEmpty(linkText)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "linkText");
+            }
+            return MvcHtmlString.Create(HtmlHelper.GenerateLink(htmlHelper.ViewContext.RequestContext, htmlHelper.RouteCollection, linkText, null/* routeName */, actionName, controllerName, routeValues, htmlAttributes));
+        }
+
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName, string controllerName, string protocol, string hostName, string fragment, object routeValues, object htmlAttributes) {
+            return ActionLink(htmlHelper, linkText, actionName, controllerName, protocol, hostName, fragment, new RouteValueDictionary(routeValues), HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString ActionLink(this HtmlHelper htmlHelper, string linkText, string actionName, string controllerName, string protocol, string hostName, string fragment, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            if (String.IsNullOrEmpty(linkText)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "linkText");
+            }
+            return MvcHtmlString.Create(HtmlHelper.GenerateLink(htmlHelper.ViewContext.RequestContext, htmlHelper.RouteCollection, linkText, null /* routeName */, actionName, controllerName, protocol, hostName, fragment, routeValues, htmlAttributes));
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, object routeValues) {
+            return RouteLink(htmlHelper, linkText, new RouteValueDictionary(routeValues));
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, RouteValueDictionary routeValues) {
+            return RouteLink(htmlHelper, linkText, routeValues, new RouteValueDictionary());
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, string routeName) {
+            return RouteLink(htmlHelper, linkText, routeName, (object)null /* routeValues */ );
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, string routeName, object routeValues) {
+            return RouteLink(htmlHelper, linkText, routeName, new RouteValueDictionary(routeValues));
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, string routeName, RouteValueDictionary routeValues) {
+            return RouteLink(htmlHelper, linkText, routeName, routeValues, new RouteValueDictionary());
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, object routeValues, object htmlAttributes) {
+            return RouteLink(htmlHelper, linkText, new RouteValueDictionary(routeValues), HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            return RouteLink(htmlHelper, linkText, null /* routeName */, routeValues, htmlAttributes);
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, string routeName, object routeValues, object htmlAttributes) {
+            return RouteLink(htmlHelper, linkText, routeName, new RouteValueDictionary(routeValues), HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, string routeName, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            if (String.IsNullOrEmpty(linkText)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "linkText");
+            }
+            return MvcHtmlString.Create(HtmlHelper.GenerateRouteLink(htmlHelper.ViewContext.RequestContext, htmlHelper.RouteCollection, linkText, routeName, routeValues, htmlAttributes));
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, string routeName, string protocol, string hostName, string fragment, object routeValues, object htmlAttributes) {
+            return RouteLink(htmlHelper, linkText, routeName, protocol, hostName, fragment, new RouteValueDictionary(routeValues), HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString RouteLink(this HtmlHelper htmlHelper, string linkText, string routeName, string protocol, string hostName, string fragment, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            if (String.IsNullOrEmpty(linkText)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "linkText");
+            }
+            return MvcHtmlString.Create(HtmlHelper.GenerateRouteLink(htmlHelper.ViewContext.RequestContext, htmlHelper.RouteCollection, linkText, routeName, protocol, hostName, fragment, routeValues, htmlAttributes));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/MvcForm.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/MvcForm.cs
new file mode 100644 (file)
index 0000000..0059904
--- /dev/null
@@ -0,0 +1,57 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.IO;
+
+    public class MvcForm : IDisposable {
+
+        private bool _disposed;
+        private readonly FormContext _originalFormContext;
+        private readonly ViewContext _viewContext;
+        private readonly TextWriter _writer;
+
+        [Obsolete("The recommended alternative is the constructor MvcForm(ViewContext viewContext).", true /* error */)]
+        public MvcForm(HttpResponseBase httpResponse) {
+            if (httpResponse == null) {
+                throw new ArgumentNullException("httpResponse");
+            }
+
+            _writer = httpResponse.Output;
+        }
+
+        public MvcForm(ViewContext viewContext) {
+            if (viewContext == null) {
+                throw new ArgumentNullException("viewContext");
+            }
+
+            _viewContext = viewContext;
+            _writer = viewContext.Writer;
+
+            // push the new FormContext
+            _originalFormContext = viewContext.FormContext;
+            viewContext.FormContext = new FormContext();
+        }
+
+        public void Dispose() {
+            Dispose(true /* disposing */);
+            GC.SuppressFinalize(this);
+        }
+
+        protected virtual void Dispose(bool disposing) {
+            if (!_disposed) {
+                _disposed = true;
+                _writer.Write("</form>");
+
+                // output client validation and restore the original form context
+                if (_viewContext != null) {
+                    _viewContext.OutputClientValidation();
+                    _viewContext.FormContext = _originalFormContext;
+                }
+            }
+        }
+
+        public void EndForm() {
+            Dispose(true);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/PartialExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/PartialExtensions.cs
new file mode 100644 (file)
index 0000000..36d5d5a
--- /dev/null
@@ -0,0 +1,25 @@
+namespace System.Web.Mvc.Html {
+    using System.Globalization;
+    using System.IO;
+
+    public static class PartialExtensions {
+        public static MvcHtmlString Partial(this HtmlHelper htmlHelper, string partialViewName) {
+            return Partial(htmlHelper, partialViewName, null /* model */, htmlHelper.ViewData);
+        }
+
+        public static MvcHtmlString Partial(this HtmlHelper htmlHelper, string partialViewName, ViewDataDictionary viewData) {
+            return Partial(htmlHelper, partialViewName, null /* model */, viewData);
+        }
+
+        public static MvcHtmlString Partial(this HtmlHelper htmlHelper, string partialViewName, object model) {
+            return Partial(htmlHelper, partialViewName, model, htmlHelper.ViewData);
+        }
+
+        public static MvcHtmlString Partial(this HtmlHelper htmlHelper, string partialViewName, object model, ViewDataDictionary viewData) {
+            using (StringWriter writer = new StringWriter(CultureInfo.CurrentCulture)) {
+                htmlHelper.RenderPartialInternal(partialViewName, viewData, model, writer, ViewEngines.Engines);
+                return MvcHtmlString.Create(writer.ToString());
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/RenderPartialExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/RenderPartialExtensions.cs
new file mode 100644 (file)
index 0000000..e0149f8
--- /dev/null
@@ -0,0 +1,23 @@
+namespace System.Web.Mvc.Html {
+    public static class RenderPartialExtensions {
+        // Renders the partial view with the parent's view data and model
+        public static void RenderPartial(this HtmlHelper htmlHelper, string partialViewName) {
+            htmlHelper.RenderPartialInternal(partialViewName, htmlHelper.ViewData, null /* model */, htmlHelper.ViewContext.Writer, ViewEngines.Engines);
+        }
+
+        // Renders the partial view with the given view data and, implicitly, the given view data's model
+        public static void RenderPartial(this HtmlHelper htmlHelper, string partialViewName, ViewDataDictionary viewData) {
+            htmlHelper.RenderPartialInternal(partialViewName, viewData, null /* model */, htmlHelper.ViewContext.Writer, ViewEngines.Engines);
+        }
+
+        // Renders the partial view with an empty view data and the given model
+        public static void RenderPartial(this HtmlHelper htmlHelper, string partialViewName, object model) {
+            htmlHelper.RenderPartialInternal(partialViewName, htmlHelper.ViewData, model, htmlHelper.ViewContext.Writer, ViewEngines.Engines);
+        }
+
+        // Renders the partial view with a copy of the given view data plus the given model
+        public static void RenderPartial(this HtmlHelper htmlHelper, string partialViewName, object model, ViewDataDictionary viewData) {
+            htmlHelper.RenderPartialInternal(partialViewName, viewData, model, htmlHelper.ViewContext.Writer, ViewEngines.Engines);
+        }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/SelectExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/SelectExtensions.cs
new file mode 100644 (file)
index 0000000..0b460bb
--- /dev/null
@@ -0,0 +1,245 @@
+namespace System.Web.Mvc.Html {
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq;
+    using System.Linq.Expressions;
+    using System.Text;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+
+    public static class SelectExtensions {
+
+        // DropDownList
+
+        public static MvcHtmlString DropDownList(this HtmlHelper htmlHelper, string name) {
+            return DropDownList(htmlHelper, name, null /* selectList */, null /* optionLabel */, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString DropDownList(this HtmlHelper htmlHelper, string name, string optionLabel) {
+            return DropDownList(htmlHelper, name, null /* selectList */, optionLabel, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString DropDownList(this HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList) {
+            return DropDownList(htmlHelper, name, selectList, null /* optionLabel */, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString DropDownList(this HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList, object htmlAttributes) {
+            return DropDownList(htmlHelper, name, selectList, null /* optionLabel */, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString DropDownList(this HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList, IDictionary<string, object> htmlAttributes) {
+            return DropDownList(htmlHelper, name, selectList, null /* optionLabel */, htmlAttributes);
+        }
+
+        public static MvcHtmlString DropDownList(this HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList, string optionLabel) {
+            return DropDownList(htmlHelper, name, selectList, optionLabel, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString DropDownList(this HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList, string optionLabel, object htmlAttributes) {
+            return DropDownList(htmlHelper, name, selectList, optionLabel, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString DropDownList(this HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList, string optionLabel, IDictionary<string, object> htmlAttributes) {
+            return DropDownListHelper(htmlHelper, name, selectList, optionLabel, htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DropDownListFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IEnumerable<SelectListItem> selectList) {
+            return DropDownListFor(htmlHelper, expression, selectList, null /* optionLabel */, null /* htmlAttributes */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DropDownListFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IEnumerable<SelectListItem> selectList, object htmlAttributes) {
+            return DropDownListFor(htmlHelper, expression, selectList, null /* optionLabel */, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DropDownListFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IEnumerable<SelectListItem> selectList, IDictionary<string, object> htmlAttributes) {
+            return DropDownListFor(htmlHelper, expression, selectList, null /* optionLabel */, htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DropDownListFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IEnumerable<SelectListItem> selectList, string optionLabel) {
+            return DropDownListFor(htmlHelper, expression, selectList, optionLabel, null /* htmlAttributes */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DropDownListFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IEnumerable<SelectListItem> selectList, string optionLabel, object htmlAttributes) {
+            return DropDownListFor(htmlHelper, expression, selectList, optionLabel, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1011:ConsiderPassingBaseTypesAsParameters", Justification = "Users cannot use anonymous methods with the LambdaExpression type")]
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString DropDownListFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IEnumerable<SelectListItem> selectList, string optionLabel, IDictionary<string, object> htmlAttributes) {
+            if (expression == null) {
+                throw new ArgumentNullException("expression");
+            }
+
+            return DropDownListHelper(htmlHelper, ExpressionHelper.GetExpressionText(expression), selectList, optionLabel, htmlAttributes);
+        }
+
+        private static MvcHtmlString DropDownListHelper(HtmlHelper htmlHelper, string expression, IEnumerable<SelectListItem> selectList, string optionLabel, IDictionary<string, object> htmlAttributes) {
+            return SelectInternal(htmlHelper, optionLabel, expression, selectList, false /* allowMultiple */, htmlAttributes);
+        }
+
+        // ListBox
+
+        public static MvcHtmlString ListBox(this HtmlHelper htmlHelper, string name) {
+            return ListBox(htmlHelper, name, null /* selectList */, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString ListBox(this HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList) {
+            return ListBox(htmlHelper, name, selectList, (IDictionary<string, object>)null);
+        }
+
+        public static MvcHtmlString ListBox(this HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList, object htmlAttributes) {
+            return ListBox(htmlHelper, name, selectList, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString ListBox(this HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList, IDictionary<string, object> htmlAttributes) {
+            return ListBoxHelper(htmlHelper, name, selectList, htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString ListBoxFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IEnumerable<SelectListItem> selectList) {
+            return ListBoxFor(htmlHelper, expression, selectList, null /* htmlAttributes */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString ListBoxFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IEnumerable<SelectListItem> selectList, object htmlAttributes) {
+            return ListBoxFor(htmlHelper, expression, selectList, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1011:ConsiderPassingBaseTypesAsParameters", Justification = "Users cannot use anonymous methods with the LambdaExpression type")]
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString ListBoxFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IEnumerable<SelectListItem> selectList, IDictionary<string, object> htmlAttributes) {
+            if (expression == null) {
+                throw new ArgumentNullException("expression");
+            }
+
+            return ListBoxHelper(htmlHelper,
+                                 ExpressionHelper.GetExpressionText(expression),
+                                 selectList,
+                                 htmlAttributes);
+        }
+
+        private static MvcHtmlString ListBoxHelper(HtmlHelper htmlHelper, string name, IEnumerable<SelectListItem> selectList, IDictionary<string, object> htmlAttributes) {
+            return SelectInternal(htmlHelper, null /* optionLabel */, name, selectList, true /* allowMultiple */, htmlAttributes);
+        }
+
+        // Helper methods
+
+        private static IEnumerable<SelectListItem> GetSelectData(this HtmlHelper htmlHelper, string name) {
+            object o = null;
+            if (htmlHelper.ViewData != null) {
+                o = htmlHelper.ViewData.Eval(name);
+            }
+            if (o == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.HtmlHelper_MissingSelectData,
+                        name,
+                        "IEnumerable<SelectListItem>"));
+            }
+            IEnumerable<SelectListItem> selectList = o as IEnumerable<SelectListItem>;
+            if (selectList == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.HtmlHelper_WrongSelectDataType,
+                        name,
+                        o.GetType().FullName,
+                        "IEnumerable<SelectListItem>"));
+            }
+            return selectList;
+        }
+
+        internal static string ListItemToOption(SelectListItem item) {
+            TagBuilder builder = new TagBuilder("option") {
+                InnerHtml = HttpUtility.HtmlEncode(item.Text)
+            };
+            if (item.Value != null) {
+                builder.Attributes["value"] = item.Value;
+            }
+            if (item.Selected) {
+                builder.Attributes["selected"] = "selected";
+            }
+            return builder.ToString(TagRenderMode.Normal);
+        }
+
+        private static MvcHtmlString SelectInternal(this HtmlHelper htmlHelper, string optionLabel, string name, IEnumerable<SelectListItem> selectList, bool allowMultiple, IDictionary<string, object> htmlAttributes) {
+            string fullName = htmlHelper.ViewContext.ViewData.TemplateInfo.GetFullHtmlFieldName(name);
+            if (String.IsNullOrEmpty(fullName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "name");
+            }
+
+            bool usedViewData = false;
+
+            // If we got a null selectList, try to use ViewData to get the list of items.
+            if (selectList == null) {
+                selectList = htmlHelper.GetSelectData(fullName);
+                usedViewData = true;
+            }
+
+            object defaultValue = (allowMultiple) ? htmlHelper.GetModelStateValue(fullName, typeof(string[])) : htmlHelper.GetModelStateValue(fullName, typeof(string));
+
+            // If we haven't already used ViewData to get the entire list of items then we need to
+            // use the ViewData-supplied value before using the parameter-supplied value.
+            if (!usedViewData) {
+                if (defaultValue == null) {
+                    defaultValue = htmlHelper.ViewData.Eval(fullName);
+                }
+            }
+
+            if (defaultValue != null) {
+                IEnumerable defaultValues = (allowMultiple) ? defaultValue as IEnumerable : new[] { defaultValue };
+                IEnumerable<string> values = from object value in defaultValues select Convert.ToString(value, CultureInfo.CurrentCulture);
+                HashSet<string> selectedValues = new HashSet<string>(values, StringComparer.OrdinalIgnoreCase);
+                List<SelectListItem> newSelectList = new List<SelectListItem>();
+
+                foreach (SelectListItem item in selectList) {
+                    item.Selected = (item.Value != null) ? selectedValues.Contains(item.Value) : selectedValues.Contains(item.Text);
+                    newSelectList.Add(item);
+                }
+                selectList = newSelectList;
+            }
+
+            // Convert each ListItem to an <option> tag
+            StringBuilder listItemBuilder = new StringBuilder();
+
+            // Make optionLabel the first item that gets rendered.
+            if (optionLabel != null) {
+                listItemBuilder.AppendLine(ListItemToOption(new SelectListItem() { Text = optionLabel, Value = String.Empty, Selected = false }));
+            }
+
+            foreach (SelectListItem item in selectList) {
+                listItemBuilder.AppendLine(ListItemToOption(item));
+            }
+
+            TagBuilder tagBuilder = new TagBuilder("select") {
+                InnerHtml = listItemBuilder.ToString()
+            };
+            tagBuilder.MergeAttributes(htmlAttributes);
+            tagBuilder.MergeAttribute("name", fullName, true /* replaceExisting */);
+            tagBuilder.GenerateId(fullName);
+            if (allowMultiple) {
+                tagBuilder.MergeAttribute("multiple", "multiple");
+            }
+
+            // If there are any errors for a named field, we add the css attribute.
+            ModelState modelState;
+            if (htmlHelper.ViewData.ModelState.TryGetValue(fullName, out modelState)) {
+                if (modelState.Errors.Count > 0) {
+                    tagBuilder.AddCssClass(HtmlHelper.ValidationInputCssClassName);
+                }
+            }
+
+            tagBuilder.MergeAttributes(htmlHelper.GetUnobtrusiveValidationAttributes(name));
+
+            return tagBuilder.ToMvcHtmlString(TagRenderMode.Normal);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/TemplateHelpers.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/TemplateHelpers.cs
new file mode 100644 (file)
index 0000000..0ae3379
--- /dev/null
@@ -0,0 +1,283 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.IO;
+    using System.Linq;
+    using System.Linq.Expressions;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+    using System.Web.UI.WebControls;
+
+    internal static class TemplateHelpers {
+        static readonly Dictionary<DataBoundControlMode, string> modeViewPaths =
+            new Dictionary<DataBoundControlMode, string> {
+                { DataBoundControlMode.ReadOnly, "DisplayTemplates" },
+                { DataBoundControlMode.Edit,     "EditorTemplates" }
+            };
+
+        static readonly Dictionary<string, Func<HtmlHelper, string>> defaultDisplayActions =
+            new Dictionary<string, Func<HtmlHelper, string>>(StringComparer.OrdinalIgnoreCase) {
+                { "EmailAddress",       DefaultDisplayTemplates.EmailAddressTemplate },
+                { "HiddenInput",        DefaultDisplayTemplates.HiddenInputTemplate },
+                { "Html",               DefaultDisplayTemplates.HtmlTemplate },
+                { "Text",               DefaultDisplayTemplates.StringTemplate },
+                { "Url",                DefaultDisplayTemplates.UrlTemplate },
+                { "Collection",         DefaultDisplayTemplates.CollectionTemplate },
+                { typeof(bool).Name,    DefaultDisplayTemplates.BooleanTemplate },
+                { typeof(decimal).Name, DefaultDisplayTemplates.DecimalTemplate },
+                { typeof(string).Name,  DefaultDisplayTemplates.StringTemplate },
+                { typeof(object).Name,  DefaultDisplayTemplates.ObjectTemplate },
+            };
+
+        static readonly Dictionary<string, Func<HtmlHelper, string>> defaultEditorActions =
+            new Dictionary<string, Func<HtmlHelper, string>>(StringComparer.OrdinalIgnoreCase) {
+                { "HiddenInput",        DefaultEditorTemplates.HiddenInputTemplate },
+                { "MultilineText",      DefaultEditorTemplates.MultilineTextTemplate },
+                { "Password",           DefaultEditorTemplates.PasswordTemplate },
+                { "Text",               DefaultEditorTemplates.StringTemplate },
+                { "Collection",         DefaultEditorTemplates.CollectionTemplate },
+                { typeof(bool).Name,    DefaultEditorTemplates.BooleanTemplate },
+                { typeof(decimal).Name, DefaultEditorTemplates.DecimalTemplate },
+                { typeof(string).Name,  DefaultEditorTemplates.StringTemplate },
+                { typeof(object).Name,  DefaultEditorTemplates.ObjectTemplate },
+            };
+
+        internal static string cacheItemId = Guid.NewGuid().ToString();
+
+        internal delegate string ExecuteTemplateDelegate(HtmlHelper html, ViewDataDictionary viewData, string templateName, DataBoundControlMode mode, GetViewNamesDelegate getViewNames, GetDefaultActionsDelegate getDefaultActions);
+
+        internal static string ExecuteTemplate(HtmlHelper html, ViewDataDictionary viewData, string templateName, DataBoundControlMode mode, GetViewNamesDelegate getViewNames, GetDefaultActionsDelegate getDefaultActions) {
+            Dictionary<string, ActionCacheItem> actionCache = GetActionCache(html);
+            Dictionary<string, Func<HtmlHelper, string>> defaultActions = getDefaultActions(mode);
+            string modeViewPath = modeViewPaths[mode];
+
+            foreach (string viewName in getViewNames(viewData.ModelMetadata, templateName, viewData.ModelMetadata.TemplateHint, viewData.ModelMetadata.DataTypeName)) {
+                string fullViewName = modeViewPath + "/" + viewName;
+                ActionCacheItem cacheItem;
+
+                if (actionCache.TryGetValue(fullViewName, out cacheItem)) {
+                    if (cacheItem != null) {
+                        return cacheItem.Execute(html, viewData);
+                    }
+                }
+                else {
+                    ViewEngineResult viewEngineResult = ViewEngines.Engines.FindPartialView(html.ViewContext, fullViewName);
+                    if (viewEngineResult.View != null) {
+                        actionCache[fullViewName] = new ActionCacheViewItem { ViewName = fullViewName };
+
+                        using (StringWriter writer = new StringWriter(CultureInfo.InvariantCulture)) {
+                            viewEngineResult.View.Render(new ViewContext(html.ViewContext, viewEngineResult.View, viewData, html.ViewContext.TempData, writer), writer);
+                            return writer.ToString();
+                        }
+                    }
+
+                    Func<HtmlHelper, string> defaultAction;
+                    if (defaultActions.TryGetValue(viewName, out defaultAction)) {
+                        actionCache[fullViewName] = new ActionCacheCodeItem { Action = defaultAction };
+                        return defaultAction(MakeHtmlHelper(html, viewData));
+                    }
+
+                    actionCache[fullViewName] = null;
+                }
+            }
+
+            throw new InvalidOperationException(
+                String.Format(
+                    CultureInfo.CurrentCulture,
+                    MvcResources.TemplateHelpers_NoTemplate,
+                    viewData.ModelMetadata.RealModelType.FullName
+                )
+            );
+        }
+
+        internal static Dictionary<string, ActionCacheItem> GetActionCache(HtmlHelper html) {
+            HttpContextBase context = html.ViewContext.HttpContext;
+            Dictionary<string, ActionCacheItem> result;
+
+            if (!context.Items.Contains(cacheItemId)) {
+                result = new Dictionary<string, ActionCacheItem>();
+                context.Items[cacheItemId] = result;
+            }
+            else {
+                result = (Dictionary<string, ActionCacheItem>)context.Items[cacheItemId];
+            }
+
+            return result;
+        }
+
+        internal delegate Dictionary<string, Func<HtmlHelper, string>> GetDefaultActionsDelegate(DataBoundControlMode mode);
+
+        internal static Dictionary<string, Func<HtmlHelper, string>> GetDefaultActions(DataBoundControlMode mode) {
+            return mode == DataBoundControlMode.ReadOnly ? defaultDisplayActions : defaultEditorActions;
+        }
+
+        internal delegate IEnumerable<string> GetViewNamesDelegate(ModelMetadata metadata, params string[] templateHints);
+
+        internal static IEnumerable<string> GetViewNames(ModelMetadata metadata, params string[] templateHints) {
+            foreach (string templateHint in templateHints.Where(s => !String.IsNullOrEmpty(s))) {
+                yield return templateHint;
+            }
+
+            // We don't want to search for Nullable<T>, we want to search for T (which should handle both T and Nullable<T>)
+            Type fieldType = Nullable.GetUnderlyingType(metadata.RealModelType) ?? metadata.RealModelType;
+
+            // TODO: Make better string names for generic types
+            yield return fieldType.Name;
+
+            if (!metadata.IsComplexType) {
+                yield return "String";
+            }
+            else if (fieldType.IsInterface) {
+                if (typeof(IEnumerable).IsAssignableFrom(fieldType)) {
+                    yield return "Collection";
+                }
+
+                yield return "Object";
+            }
+            else {
+                bool isEnumerable = typeof(IEnumerable).IsAssignableFrom(fieldType);
+
+                while (true) {
+                    fieldType = fieldType.BaseType;
+                    if (fieldType == null)
+                        break;
+
+                    if (isEnumerable && fieldType == typeof(Object)) {
+                        yield return "Collection";
+                    }
+
+                    yield return fieldType.Name;
+                }
+            }
+        }
+
+        internal static MvcHtmlString Template(HtmlHelper html, string expression, string templateName, string htmlFieldName, DataBoundControlMode mode, object additionalViewData) {
+            return MvcHtmlString.Create(Template(html, expression, templateName, htmlFieldName, mode, additionalViewData, TemplateHelper));
+        }
+
+        // Unit testing version
+        internal static string Template(HtmlHelper html, string expression, string templateName, string htmlFieldName,
+                                        DataBoundControlMode mode, object additionalViewData, TemplateHelperDelegate templateHelper) {
+            return templateHelper(html,
+                                  ModelMetadata.FromStringExpression(expression, html.ViewData),
+                                  htmlFieldName ?? ExpressionHelper.GetExpressionText(expression),
+                                  templateName,
+                                  mode,
+                                  additionalViewData);
+        }
+
+        internal static MvcHtmlString TemplateFor<TContainer, TValue>(this HtmlHelper<TContainer> html, Expression<Func<TContainer, TValue>> expression,
+                                                                      string templateName, string htmlFieldName, DataBoundControlMode mode,
+                                                                      object additionalViewData) {
+            return MvcHtmlString.Create(TemplateFor(html, expression, templateName, htmlFieldName, mode, additionalViewData, TemplateHelper));
+        }
+
+        // Unit testing version
+        internal static string TemplateFor<TContainer, TValue>(this HtmlHelper<TContainer> html, Expression<Func<TContainer, TValue>> expression,
+                                                               string templateName, string htmlFieldName, DataBoundControlMode mode,
+                                                               object additionalViewData, TemplateHelperDelegate templateHelper) {
+            return templateHelper(html,
+                                  ModelMetadata.FromLambdaExpression(expression, html.ViewData),
+                                  htmlFieldName ?? ExpressionHelper.GetExpressionText(expression),
+                                  templateName,
+                                  mode,
+                                  additionalViewData);
+        }
+
+        internal delegate string TemplateHelperDelegate(HtmlHelper html, ModelMetadata metadata, string htmlFieldName, string templateName, DataBoundControlMode mode, object additionalViewData);
+
+        internal static string TemplateHelper(HtmlHelper html, ModelMetadata metadata, string htmlFieldName, string templateName, DataBoundControlMode mode, object additionalViewData) {
+            return TemplateHelper(html, metadata, htmlFieldName, templateName, mode, additionalViewData, ExecuteTemplate);
+        }
+
+        internal static string TemplateHelper(HtmlHelper html, ModelMetadata metadata, string htmlFieldName, string templateName, DataBoundControlMode mode, object additionalViewData, ExecuteTemplateDelegate executeTemplate) {
+            // TODO: Convert Editor into Display if model.IsReadOnly is true? Need to be careful about this because
+            // the Model property on the ViewPage/ViewUserControl is get-only, so the type descriptor automatically
+            // decorates it with a [ReadOnly] attribute...
+
+            if (metadata.ConvertEmptyStringToNull && String.Empty.Equals(metadata.Model)) {
+                metadata.Model = null;
+            }
+
+            object formattedModelValue = metadata.Model;
+            if (metadata.Model == null && mode == DataBoundControlMode.ReadOnly) {
+                formattedModelValue = metadata.NullDisplayText;
+            }
+
+            string formatString = mode == DataBoundControlMode.ReadOnly ? metadata.DisplayFormatString : metadata.EditFormatString;
+            if (metadata.Model != null && !String.IsNullOrEmpty(formatString)) {
+                formattedModelValue = String.Format(CultureInfo.CurrentCulture, formatString, metadata.Model);
+            }
+
+            // Normally this shouldn't happen, unless someone writes their own custom Object templates which
+            // don't check to make sure that the object hasn't already been displayed
+            object visitedObjectsKey = metadata.Model ?? metadata.RealModelType;
+            if (html.ViewDataContainer.ViewData.TemplateInfo.VisitedObjects.Contains(visitedObjectsKey)) {    // DDB #224750
+                return String.Empty;
+            }
+
+            ViewDataDictionary viewData = new ViewDataDictionary(html.ViewDataContainer.ViewData) {
+                Model = metadata.Model,
+                ModelMetadata = metadata,
+                TemplateInfo = new TemplateInfo {
+                    FormattedModelValue = formattedModelValue,
+                    HtmlFieldPrefix = html.ViewContext.ViewData.TemplateInfo.GetFullHtmlFieldName(htmlFieldName),
+                    VisitedObjects = new HashSet<object>(html.ViewContext.ViewData.TemplateInfo.VisitedObjects),    // DDB #224750
+                }
+            };
+
+            if (additionalViewData != null) {
+                foreach (KeyValuePair<string, object> kvp in new RouteValueDictionary(additionalViewData)) {
+                    viewData[kvp.Key] = kvp.Value;
+                }
+            }
+
+            viewData.TemplateInfo.VisitedObjects.Add(visitedObjectsKey);    // DDB #224750
+
+            return executeTemplate(html, viewData, templateName, mode, GetViewNames, GetDefaultActions);
+        }
+
+        // Helpers
+
+        private static HtmlHelper MakeHtmlHelper(HtmlHelper html, ViewDataDictionary viewData) {
+            return new HtmlHelper(
+                new ViewContext(html.ViewContext, html.ViewContext.View, viewData, html.ViewContext.TempData, html.ViewContext.Writer),
+                new ViewDataContainer(viewData)
+            );
+        }
+
+        internal abstract class ActionCacheItem {
+            public abstract string Execute(HtmlHelper html, ViewDataDictionary viewData);
+        }
+
+        internal class ActionCacheCodeItem : ActionCacheItem {
+            public Func<HtmlHelper, string> Action { get; set; }
+
+            public override string Execute(HtmlHelper html, ViewDataDictionary viewData) {
+                return Action(MakeHtmlHelper(html, viewData));
+            }
+        }
+
+        internal class ActionCacheViewItem : ActionCacheItem {
+            public string ViewName { get; set; }
+
+            public override string Execute(HtmlHelper html, ViewDataDictionary viewData) {
+                ViewEngineResult viewEngineResult = ViewEngines.Engines.FindPartialView(html.ViewContext, ViewName);
+                using (StringWriter writer = new StringWriter(CultureInfo.InvariantCulture)) {
+                    viewEngineResult.View.Render(new ViewContext(html.ViewContext, viewEngineResult.View, viewData, html.ViewContext.TempData, writer), writer);
+                    return writer.ToString();
+                }
+            }
+        }
+
+        private class ViewDataContainer : IViewDataContainer {
+            public ViewDataContainer(ViewDataDictionary viewData) {
+                ViewData = viewData;
+            }
+
+            public ViewDataDictionary ViewData { get; set; }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/TextAreaExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/TextAreaExtensions.cs
new file mode 100644 (file)
index 0000000..5dbbd38
--- /dev/null
@@ -0,0 +1,161 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq.Expressions;
+    using System.Web.Mvc.Resources;
+
+    public static class TextAreaExtensions {
+        // These values are similar to the defaults used by WebForms
+        // when using <asp:TextBox TextMode="MultiLine"> without specifying
+        // the Rows and Columns attributes.
+        private const int TextAreaRows = 2;
+        private const int TextAreaColumns = 20;
+        private static Dictionary<string, object> implicitRowsAndColumns = new Dictionary<string, object> {
+            { "rows", TextAreaRows.ToString(CultureInfo.InvariantCulture) },
+            { "cols", TextAreaColumns.ToString(CultureInfo.InvariantCulture) },
+        };
+
+        private static Dictionary<string, object> GetRowsAndColumnsDictionary(int rows, int columns) {
+            if (rows < 0) {
+                throw new ArgumentOutOfRangeException("rows", MvcResources.HtmlHelper_TextAreaParameterOutOfRange);
+            }
+            if (columns < 0) {
+                throw new ArgumentOutOfRangeException("columns", MvcResources.HtmlHelper_TextAreaParameterOutOfRange);
+            }
+
+            Dictionary<string, object> result = new Dictionary<string, object>();
+            if (rows > 0) {
+                result.Add("rows", rows.ToString(CultureInfo.InvariantCulture));
+            }
+            if (columns > 0) {
+                result.Add("cols", columns.ToString(CultureInfo.InvariantCulture));
+            }
+
+            return result;
+        }
+
+        public static MvcHtmlString TextArea(this HtmlHelper htmlHelper, string name) {
+            return TextArea(htmlHelper, name, null /* value */, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString TextArea(this HtmlHelper htmlHelper, string name, object htmlAttributes) {
+            return TextArea(htmlHelper, name, null /* value */, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString TextArea(this HtmlHelper htmlHelper, string name, IDictionary<string, object> htmlAttributes) {
+            return TextArea(htmlHelper, name, null /* value */, htmlAttributes);
+        }
+
+        public static MvcHtmlString TextArea(this HtmlHelper htmlHelper, string name, string value) {
+            return TextArea(htmlHelper, name, value, null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString TextArea(this HtmlHelper htmlHelper, string name, string value, object htmlAttributes) {
+            return TextArea(htmlHelper, name, value, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString TextArea(this HtmlHelper htmlHelper, string name, string value, IDictionary<string, object> htmlAttributes) {
+            ModelMetadata metadata = ModelMetadata.FromStringExpression(name, htmlHelper.ViewContext.ViewData);
+            if (value != null) {
+                metadata.Model = value;
+            }
+
+            return TextAreaHelper(htmlHelper, metadata, name, implicitRowsAndColumns, htmlAttributes);
+        }
+
+        public static MvcHtmlString TextArea(this HtmlHelper htmlHelper, string name, string value, int rows, int columns, object htmlAttributes) {
+            return TextArea(htmlHelper, name, value, rows, columns, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString TextArea(this HtmlHelper htmlHelper, string name, string value, int rows, int columns, IDictionary<string, object> htmlAttributes) {
+            ModelMetadata metadata = ModelMetadata.FromStringExpression(name, htmlHelper.ViewContext.ViewData);
+            if (value != null) {
+                metadata.Model = value;
+            }
+
+            return TextAreaHelper(htmlHelper, metadata, name, GetRowsAndColumnsDictionary(rows, columns), htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString TextAreaFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression) {
+            return TextAreaFor(htmlHelper, expression, (IDictionary<string, object>)null);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString TextAreaFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, object htmlAttributes) {
+            return TextAreaFor(htmlHelper, expression, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString TextAreaFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, IDictionary<string, object> htmlAttributes) {
+            if (expression == null) {
+                throw new ArgumentNullException("expression");
+            }
+
+            return TextAreaHelper(htmlHelper,
+                                  ModelMetadata.FromLambdaExpression(expression, htmlHelper.ViewData),
+                                  ExpressionHelper.GetExpressionText(expression),
+                                  implicitRowsAndColumns,
+                                  htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString TextAreaFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, int rows, int columns, object htmlAttributes) {
+            return TextAreaFor(htmlHelper, expression, rows, columns, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString TextAreaFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, int rows, int columns, IDictionary<string, object> htmlAttributes) {
+            if (expression == null) {
+                throw new ArgumentNullException("expression");
+            }
+
+            return TextAreaHelper(htmlHelper,
+                                  ModelMetadata.FromLambdaExpression(expression, htmlHelper.ViewData),
+                                  ExpressionHelper.GetExpressionText(expression),
+                                  GetRowsAndColumnsDictionary(rows, columns),
+                                  htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2208:InstantiateArgumentExceptionsCorrectly", Justification = "If this fails, it is because the string-based version had an empty 'name' parameter")]
+        private static MvcHtmlString TextAreaHelper(HtmlHelper htmlHelper, ModelMetadata modelMetadata, string name, IDictionary<string, object> rowsAndColumns, IDictionary<string, object> htmlAttributes) {
+            string fullName = htmlHelper.ViewContext.ViewData.TemplateInfo.GetFullHtmlFieldName(name);
+            if (String.IsNullOrEmpty(fullName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "name");
+            }
+
+            TagBuilder tagBuilder = new TagBuilder("textarea");
+            tagBuilder.GenerateId(fullName);
+            tagBuilder.MergeAttributes(htmlAttributes, true);
+            tagBuilder.MergeAttributes(rowsAndColumns, rowsAndColumns != implicitRowsAndColumns);  // Only force explicit rows/cols
+            tagBuilder.MergeAttribute("name", fullName, true);
+
+            // If there are any errors for a named field, we add the CSS attribute.
+            ModelState modelState;
+            if (htmlHelper.ViewData.ModelState.TryGetValue(fullName, out modelState) && modelState.Errors.Count > 0) {
+                tagBuilder.AddCssClass(HtmlHelper.ValidationInputCssClassName);
+            }
+
+            tagBuilder.MergeAttributes(htmlHelper.GetUnobtrusiveValidationAttributes(name));
+
+            string value;
+            if (modelState != null && modelState.Value != null) {
+                value = modelState.Value.AttemptedValue;
+            }
+            else if (modelMetadata.Model != null) {
+                value = modelMetadata.Model.ToString();
+            }
+            else {
+                value = String.Empty;
+            }
+
+            // The first newline is always trimmed when a TextArea is rendered, so we add an extra one
+            // in case the value being rendered is something like "\r\nHello".
+            tagBuilder.SetInnerText(Environment.NewLine + value);
+
+            return tagBuilder.ToMvcHtmlString(TagRenderMode.Normal);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Html/ValidationExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/Html/ValidationExtensions.cs
new file mode 100644 (file)
index 0000000..a8b1cb9
--- /dev/null
@@ -0,0 +1,314 @@
+namespace System.Web.Mvc.Html {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq;
+    using System.Linq.Expressions;
+    using System.Text;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    public static class ValidationExtensions {
+
+        private const string _hiddenListItem = @"<li style=""display:none""></li>";
+        private static string _resourceClassKey;
+
+        public static string ResourceClassKey {
+            get {
+                return _resourceClassKey ?? String.Empty;
+            }
+            set {
+                _resourceClassKey = value;
+            }
+        }
+
+        private static FieldValidationMetadata ApplyFieldValidationMetadata(HtmlHelper htmlHelper, ModelMetadata modelMetadata, string modelName) {
+            FormContext formContext = htmlHelper.ViewContext.FormContext;
+            FieldValidationMetadata fieldMetadata = formContext.GetValidationMetadataForField(modelName, true /* createIfNotFound */);
+
+            // write rules to context object
+            IEnumerable<ModelValidator> validators = ModelValidatorProviders.Providers.GetValidators(modelMetadata, htmlHelper.ViewContext);
+            foreach (ModelClientValidationRule rule in validators.SelectMany(v => v.GetClientValidationRules())) {
+                fieldMetadata.ValidationRules.Add(rule);
+            }
+
+            return fieldMetadata;
+        }
+
+        private static string GetInvalidPropertyValueResource(HttpContextBase httpContext) {
+            string resourceValue = null;
+            if (!String.IsNullOrEmpty(ResourceClassKey) && (httpContext != null)) {
+                // If the user specified a ResourceClassKey try to load the resource they specified.
+                // If the class key is invalid, an exception will be thrown.
+                // If the class key is valid but the resource is not found, it returns null, in which
+                // case it will fall back to the MVC default error message.
+                resourceValue = httpContext.GetGlobalResourceObject(ResourceClassKey, "InvalidPropertyValue", CultureInfo.CurrentUICulture) as string;
+            }
+            return resourceValue ?? MvcResources.Common_ValueNotValidForProperty;
+        }
+
+        private static string GetUserErrorMessageOrDefault(HttpContextBase httpContext, ModelError error, ModelState modelState) {
+            if (!String.IsNullOrEmpty(error.ErrorMessage)) {
+                return error.ErrorMessage;
+            }
+            if (modelState == null) {
+                return null;
+            }
+
+            string attemptedValue = (modelState.Value != null) ? modelState.Value.AttemptedValue : null;
+            return String.Format(CultureInfo.CurrentCulture, GetInvalidPropertyValueResource(httpContext), attemptedValue);
+        }
+
+        // Validate
+
+        public static void Validate(this HtmlHelper htmlHelper, string modelName) {
+            if (modelName == null) {
+                throw new ArgumentNullException("modelName");
+            }
+
+            ValidateHelper(htmlHelper,
+                ModelMetadata.FromStringExpression(modelName, htmlHelper.ViewContext.ViewData),
+                modelName);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static void ValidateFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression) {
+            ValidateHelper(htmlHelper,
+                ModelMetadata.FromLambdaExpression(expression, htmlHelper.ViewData),
+                ExpressionHelper.GetExpressionText(expression));
+        }
+
+        private static void ValidateHelper(HtmlHelper htmlHelper, ModelMetadata modelMetadata, string expression) {
+            FormContext formContext = htmlHelper.ViewContext.GetFormContextForClientValidation();
+            if (formContext == null || htmlHelper.ViewContext.UnobtrusiveJavaScriptEnabled) {
+                return; // nothing to do
+            }
+
+            string modelName = htmlHelper.ViewContext.ViewData.TemplateInfo.GetFullHtmlFieldName(expression);
+            ApplyFieldValidationMetadata(htmlHelper, modelMetadata, modelName);
+        }
+
+        // ValidationMessage
+
+        public static MvcHtmlString ValidationMessage(this HtmlHelper htmlHelper, string modelName) {
+            return ValidationMessage(htmlHelper, modelName, null /* validationMessage */, new RouteValueDictionary());
+        }
+
+        public static MvcHtmlString ValidationMessage(this HtmlHelper htmlHelper, string modelName, object htmlAttributes) {
+            return ValidationMessage(htmlHelper, modelName, null /* validationMessage */, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1719:ParameterNamesShouldNotMatchMemberNames", Justification = "'validationMessage' refers to the message that will be rendered by the ValidationMessage helper.")]
+        public static MvcHtmlString ValidationMessage(this HtmlHelper htmlHelper, string modelName, string validationMessage) {
+            return ValidationMessage(htmlHelper, modelName, validationMessage, new RouteValueDictionary());
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1719:ParameterNamesShouldNotMatchMemberNames", Justification = "'validationMessage' refers to the message that will be rendered by the ValidationMessage helper.")]
+        public static MvcHtmlString ValidationMessage(this HtmlHelper htmlHelper, string modelName, string validationMessage, object htmlAttributes) {
+            return ValidationMessage(htmlHelper, modelName, validationMessage, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString ValidationMessage(this HtmlHelper htmlHelper, string modelName, IDictionary<string, object> htmlAttributes) {
+            return ValidationMessage(htmlHelper, modelName, null /* validationMessage */, htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1719:ParameterNamesShouldNotMatchMemberNames", Justification = "'validationMessage' refers to the message that will be rendered by the ValidationMessage helper.")]
+        public static MvcHtmlString ValidationMessage(this HtmlHelper htmlHelper, string modelName, string validationMessage, IDictionary<string, object> htmlAttributes) {
+            if (modelName == null) {
+                throw new ArgumentNullException("modelName");
+            }
+
+            return ValidationMessageHelper(htmlHelper,
+                                           ModelMetadata.FromStringExpression(modelName, htmlHelper.ViewContext.ViewData),
+                                           modelName,
+                                           validationMessage,
+                                           htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString ValidationMessageFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression) {
+            return ValidationMessageFor(htmlHelper, expression, null /* validationMessage */, new RouteValueDictionary());
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString ValidationMessageFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, string validationMessage) {
+            return ValidationMessageFor(htmlHelper, expression, validationMessage, new RouteValueDictionary());
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString ValidationMessageFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, string validationMessage, object htmlAttributes) {
+            return ValidationMessageFor(htmlHelper, expression, validationMessage, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static MvcHtmlString ValidationMessageFor<TModel, TProperty>(this HtmlHelper<TModel> htmlHelper, Expression<Func<TModel, TProperty>> expression, string validationMessage, IDictionary<string, object> htmlAttributes) {
+            return ValidationMessageHelper(htmlHelper,
+                                           ModelMetadata.FromLambdaExpression(expression, htmlHelper.ViewData),
+                                           ExpressionHelper.GetExpressionText(expression),
+                                           validationMessage,
+                                           htmlAttributes);
+        }
+
+        [SuppressMessage("Microsoft.Globalization", "CA1308:NormalizeStringsToUppercase", Justification = "Normalization to lowercase is a common requirement for JavaScript and HTML values")]
+        private static MvcHtmlString ValidationMessageHelper(this HtmlHelper htmlHelper, ModelMetadata modelMetadata, string expression, string validationMessage, IDictionary<string, object> htmlAttributes) {
+            string modelName = htmlHelper.ViewContext.ViewData.TemplateInfo.GetFullHtmlFieldName(expression);
+            FormContext formContext = htmlHelper.ViewContext.GetFormContextForClientValidation();
+
+            if (!htmlHelper.ViewData.ModelState.ContainsKey(modelName) && formContext == null) {
+                return null;
+            }
+
+            ModelState modelState = htmlHelper.ViewData.ModelState[modelName];
+            ModelErrorCollection modelErrors = (modelState == null) ? null : modelState.Errors;
+            ModelError modelError = (((modelErrors == null) || (modelErrors.Count == 0)) ? null : modelErrors.FirstOrDefault(m => !String.IsNullOrEmpty(m.ErrorMessage)) ?? modelErrors[0]);
+
+            if (modelError == null && formContext == null) {
+                return null;
+            }
+
+            TagBuilder builder = new TagBuilder("span");
+            builder.MergeAttributes(htmlAttributes);
+            builder.AddCssClass((modelError != null) ? HtmlHelper.ValidationMessageCssClassName : HtmlHelper.ValidationMessageValidCssClassName);
+
+            if (!String.IsNullOrEmpty(validationMessage)) {
+                builder.SetInnerText(validationMessage);
+            }
+            else if (modelError != null) {
+                builder.SetInnerText(GetUserErrorMessageOrDefault(htmlHelper.ViewContext.HttpContext, modelError, modelState));
+            }
+
+            if (formContext != null) {
+                bool replaceValidationMessageContents = String.IsNullOrEmpty(validationMessage);
+
+                if (htmlHelper.ViewContext.UnobtrusiveJavaScriptEnabled) {
+                    builder.MergeAttribute("data-valmsg-for", modelName);
+                    builder.MergeAttribute("data-valmsg-replace", replaceValidationMessageContents.ToString().ToLowerInvariant());
+                }
+                else {
+                    FieldValidationMetadata fieldMetadata = ApplyFieldValidationMetadata(htmlHelper, modelMetadata, modelName);
+                    // rules will already have been written to the metadata object
+                    fieldMetadata.ReplaceValidationMessageContents = replaceValidationMessageContents; // only replace contents if no explicit message was specified
+
+                    // client validation always requires an ID
+                    builder.GenerateId(modelName + "_validationMessage");
+                    fieldMetadata.ValidationMessageId = builder.Attributes["id"];
+                }
+            }
+
+            return builder.ToMvcHtmlString(TagRenderMode.Normal);
+        }
+
+        // ValidationSummary
+
+        public static MvcHtmlString ValidationSummary(this HtmlHelper htmlHelper) {
+            return ValidationSummary(htmlHelper, false /* excludePropertyErrors */ );
+        }
+
+        public static MvcHtmlString ValidationSummary(this HtmlHelper htmlHelper, bool excludePropertyErrors) {
+            return ValidationSummary(htmlHelper, excludePropertyErrors, null /* message */);
+        }
+
+        public static MvcHtmlString ValidationSummary(this HtmlHelper htmlHelper, string message) {
+            return ValidationSummary(htmlHelper, false /* excludePropertyErrors */, message, (object)null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString ValidationSummary(this HtmlHelper htmlHelper, bool excludePropertyErrors, string message) {
+            return ValidationSummary(htmlHelper, excludePropertyErrors, message, (object)null /* htmlAttributes */);
+        }
+
+        public static MvcHtmlString ValidationSummary(this HtmlHelper htmlHelper, string message, object htmlAttributes) {
+            return ValidationSummary(htmlHelper, false /* excludePropertyErrors */, message, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString ValidationSummary(this HtmlHelper htmlHelper, bool excludePropertyErrors, string message, object htmlAttributes) {
+            return ValidationSummary(htmlHelper, excludePropertyErrors, message, HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes));
+        }
+
+        public static MvcHtmlString ValidationSummary(this HtmlHelper htmlHelper, string message, IDictionary<string, object> htmlAttributes) {
+            return ValidationSummary(htmlHelper, false /* excludePropertyErrors */, message, htmlAttributes);
+        }
+
+        public static MvcHtmlString ValidationSummary(this HtmlHelper htmlHelper, bool excludePropertyErrors, string message, IDictionary<string, object> htmlAttributes) {
+            if (htmlHelper == null) {
+                throw new ArgumentNullException("htmlHelper");
+            }
+
+            FormContext formContext = htmlHelper.ViewContext.GetFormContextForClientValidation();
+            if (htmlHelper.ViewData.ModelState.IsValid) {
+                if (formContext == null) {  // No client side validation
+                    return null;
+                }
+                // TODO: This isn't really about unobtrusive; can we fix up non-unobtrusive to get rid of this, too?
+                if (htmlHelper.ViewContext.UnobtrusiveJavaScriptEnabled && excludePropertyErrors) {  // No client-side updates
+                    return null;
+                }
+            }
+
+            string messageSpan;
+            if (!String.IsNullOrEmpty(message)) {
+                TagBuilder spanTag = new TagBuilder("span");
+                spanTag.SetInnerText(message);
+                messageSpan = spanTag.ToString(TagRenderMode.Normal) + Environment.NewLine;
+            }
+            else {
+                messageSpan = null;
+            }
+
+            StringBuilder htmlSummary = new StringBuilder();
+            TagBuilder unorderedList = new TagBuilder("ul");
+
+            IEnumerable<ModelState> modelStates = null;
+            if (excludePropertyErrors) {
+                ModelState ms;
+                htmlHelper.ViewData.ModelState.TryGetValue(htmlHelper.ViewData.TemplateInfo.HtmlFieldPrefix, out ms);
+                if (ms != null) {
+                    modelStates = new ModelState[] { ms };
+                }
+            }
+            else {
+                modelStates = htmlHelper.ViewData.ModelState.Values;
+            }
+
+            if (modelStates != null) {
+                foreach (ModelState modelState in modelStates) {
+                    foreach (ModelError modelError in modelState.Errors) {
+                        string errorText = GetUserErrorMessageOrDefault(htmlHelper.ViewContext.HttpContext, modelError, null /* modelState */);
+                        if (!String.IsNullOrEmpty(errorText)) {
+                            TagBuilder listItem = new TagBuilder("li");
+                            listItem.SetInnerText(errorText);
+                            htmlSummary.AppendLine(listItem.ToString(TagRenderMode.Normal));
+                        }
+                    }
+                }
+            }
+
+            if (htmlSummary.Length == 0) {
+                htmlSummary.AppendLine(_hiddenListItem);
+            }
+
+            unorderedList.InnerHtml = htmlSummary.ToString();
+
+            TagBuilder divBuilder = new TagBuilder("div");
+            divBuilder.MergeAttributes(htmlAttributes);
+            divBuilder.AddCssClass((htmlHelper.ViewData.ModelState.IsValid) ? HtmlHelper.ValidationSummaryValidCssClassName : HtmlHelper.ValidationSummaryCssClassName);
+            divBuilder.InnerHtml = messageSpan + unorderedList.ToString(TagRenderMode.Normal);
+
+            if (formContext != null) {
+                if (htmlHelper.ViewContext.UnobtrusiveJavaScriptEnabled) {
+                    if (!excludePropertyErrors) {  // Only put errors in the validation summary if they're supposed to be included there
+                        divBuilder.MergeAttribute("data-valmsg-summary", "true");
+                    }
+                }
+                else {
+                    // client val summaries need an ID
+                    divBuilder.GenerateId("validationSummary");
+                    formContext.ValidationSummaryId = divBuilder.Attributes["id"];
+                    formContext.ReplaceValidationSummary = !excludePropertyErrors;
+                }
+            }
+            return divBuilder.ToMvcHtmlString(TagRenderMode.Normal);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HtmlHelper.cs b/mcs/class/System.Web.Mvc3/Mvc/HtmlHelper.cs
new file mode 100644 (file)
index 0000000..a3b0726
--- /dev/null
@@ -0,0 +1,451 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.IO;
+    using System.Linq;
+    using System.Text;
+    using System.Web;
+    using System.Web.Helpers;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    public class HtmlHelper {
+        public static readonly string ValidationInputCssClassName = "input-validation-error";
+        public static readonly string ValidationInputValidCssClassName = "input-validation-valid";
+        public static readonly string ValidationMessageCssClassName = "field-validation-error";
+        public static readonly string ValidationMessageValidCssClassName = "field-validation-valid";
+        public static readonly string ValidationSummaryCssClassName = "validation-summary-errors";
+        public static readonly string ValidationSummaryValidCssClassName = "validation-summary-valid";
+
+        public HtmlHelper(ViewContext viewContext, IViewDataContainer viewDataContainer)
+            : this(viewContext, viewDataContainer, RouteTable.Routes) {
+        }
+
+        public HtmlHelper(ViewContext viewContext, IViewDataContainer viewDataContainer, RouteCollection routeCollection) {
+            if (viewContext == null) {
+                throw new ArgumentNullException("viewContext");
+            }
+            if (viewDataContainer == null) {
+                throw new ArgumentNullException("viewDataContainer");
+            }
+            if (routeCollection == null) {
+                throw new ArgumentNullException("routeCollection");
+            }
+
+            ViewContext = viewContext;
+            ViewDataContainer = viewDataContainer;
+            RouteCollection = routeCollection;
+            ClientValidationRuleFactory = (name, metadata) => ModelValidatorProviders.Providers.GetValidators(metadata ?? ModelMetadata.FromStringExpression(name, ViewData), ViewContext).SelectMany(v => v.GetClientValidationRules());
+        }
+
+        public static bool ClientValidationEnabled {
+            get {
+                return ViewContext.GetClientValidationEnabled();
+            }
+            set {
+                ViewContext.SetClientValidationEnabled(value);
+            }
+        }
+
+        public static string IdAttributeDotReplacement {
+            get {
+                return System.Web.WebPages.Html.HtmlHelper.IdAttributeDotReplacement;
+            }
+            set {
+                System.Web.WebPages.Html.HtmlHelper.IdAttributeDotReplacement = value;
+            }
+        }
+
+        internal Func<string, ModelMetadata, IEnumerable<ModelClientValidationRule>> ClientValidationRuleFactory {
+            get;
+            set;
+        }
+
+        public RouteCollection RouteCollection {
+            get;
+            private set;
+        }
+
+        public static bool UnobtrusiveJavaScriptEnabled {
+            get {
+                return ViewContext.GetUnobtrusiveJavaScriptEnabled();
+            }
+            set {
+                ViewContext.SetUnobtrusiveJavaScriptEnabled(value);
+            }
+        }
+
+        public ViewContext ViewContext {
+            get;
+            private set;
+        }
+
+        public ViewDataDictionary ViewData {
+            get {
+                return ViewDataContainer.ViewData;
+            }
+        }
+
+        public IViewDataContainer ViewDataContainer {
+            get;
+            private set;
+        }
+
+        public static RouteValueDictionary AnonymousObjectToHtmlAttributes(object htmlAttributes) {
+            RouteValueDictionary result = new RouteValueDictionary();
+
+            if (htmlAttributes != null) {
+                foreach (PropertyDescriptor property in TypeDescriptor.GetProperties(htmlAttributes)) {
+                    result.Add(property.Name.Replace('_', '-'), property.GetValue(htmlAttributes));
+                }
+            }
+
+            return result;
+        }
+
+        public MvcHtmlString AntiForgeryToken() {
+            return AntiForgeryToken(salt: null);
+        }
+
+        public MvcHtmlString AntiForgeryToken(string salt) {
+            return AntiForgeryToken(salt, domain: null, path: null);
+        }
+
+        public MvcHtmlString AntiForgeryToken(string salt, string domain, string path) {
+            //Disabled to compile MVC3 with the newer System.Web.WebPages helpers
+            //return new MvcHtmlString(AntiForgery.GetHtml(ViewContext.HttpContext, salt, domain, path).ToString());
+            return new MvcHtmlString(AntiForgery.GetHtml().ToString());
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "For consistency, all helpers are instance methods.")]
+        public string AttributeEncode(string value) {
+            return (!String.IsNullOrEmpty(value)) ? HttpUtility.HtmlAttributeEncode(value) : String.Empty;
+        }
+
+        public string AttributeEncode(object value) {
+            return AttributeEncode(Convert.ToString(value, CultureInfo.InvariantCulture));
+        }
+
+        public void EnableClientValidation() {
+            EnableClientValidation(enabled: true);
+        }
+
+        public void EnableClientValidation(bool enabled) {
+            ViewContext.ClientValidationEnabled = enabled;
+        }
+
+        public void EnableUnobtrusiveJavaScript() {
+            EnableUnobtrusiveJavaScript(enabled: true);
+        }
+
+        public void EnableUnobtrusiveJavaScript(bool enabled) {
+            ViewContext.UnobtrusiveJavaScriptEnabled = enabled;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "For consistency, all helpers are instance methods.")]
+        public string Encode(string value) {
+            return (!String.IsNullOrEmpty(value)) ? HttpUtility.HtmlEncode(value) : String.Empty;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "For consistency, all helpers are instance methods.")]
+        public string Encode(object value) {
+            return value != null ? HttpUtility.HtmlEncode(value) : String.Empty;
+        }
+
+        internal string EvalString(string key) {
+            return Convert.ToString(ViewData.Eval(key), CultureInfo.CurrentCulture);
+        }
+
+        internal bool EvalBoolean(string key) {
+            return Convert.ToBoolean(ViewData.Eval(key), CultureInfo.InvariantCulture);
+        }
+
+        internal static IView FindPartialView(ViewContext viewContext, string partialViewName, ViewEngineCollection viewEngineCollection) {
+            ViewEngineResult result = viewEngineCollection.FindPartialView(viewContext, partialViewName);
+            if (result.View != null) {
+                return result.View;
+            }
+
+            StringBuilder locationsText = new StringBuilder();
+            foreach (string location in result.SearchedLocations) {
+                locationsText.AppendLine();
+                locationsText.Append(location);
+            }
+
+            throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture,
+                MvcResources.Common_PartialViewNotFound, partialViewName, locationsText));
+        }
+
+        public static string GenerateIdFromName(string name) {
+            return GenerateIdFromName(name, IdAttributeDotReplacement);
+        }
+
+        public static string GenerateIdFromName(string name, string idAttributeDotReplacement) {
+            if (name == null) {
+                throw new ArgumentNullException("name");
+            }
+
+            if (idAttributeDotReplacement == null) {
+                throw new ArgumentNullException("idAttributeDotReplacement");
+            }
+
+            // TagBuilder.CreateSanitizedId returns null for empty strings, return String.Empty instead to avoid breaking change
+            if (name.Length == 0) {
+                return String.Empty;
+            }
+
+            return TagBuilder.CreateSanitizedId(name, idAttributeDotReplacement);
+        }
+
+        public static string GenerateLink(RequestContext requestContext, RouteCollection routeCollection, string linkText, string routeName, string actionName, string controllerName, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            return GenerateLink(requestContext, routeCollection, linkText, routeName, actionName, controllerName, null/* protocol */, null/* hostName */, null/* fragment */, routeValues, htmlAttributes);
+        }
+
+        public static string GenerateLink(RequestContext requestContext, RouteCollection routeCollection, string linkText, string routeName, string actionName, string controllerName, string protocol, string hostName, string fragment, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            return GenerateLinkInternal(requestContext, routeCollection, linkText, routeName, actionName, controllerName, protocol, hostName, fragment, routeValues, htmlAttributes, true /* includeImplicitMvcValues */);
+        }
+
+        private static string GenerateLinkInternal(RequestContext requestContext, RouteCollection routeCollection, string linkText, string routeName, string actionName, string controllerName, string protocol, string hostName, string fragment, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes, bool includeImplicitMvcValues) {
+            string url = UrlHelper.GenerateUrl(routeName, actionName, controllerName, protocol, hostName, fragment, routeValues, routeCollection, requestContext, includeImplicitMvcValues);
+            TagBuilder tagBuilder = new TagBuilder("a") {
+                InnerHtml = (!String.IsNullOrEmpty(linkText)) ? HttpUtility.HtmlEncode(linkText) : String.Empty
+            };
+            tagBuilder.MergeAttributes(htmlAttributes);
+            tagBuilder.MergeAttribute("href", url);
+            return tagBuilder.ToString(TagRenderMode.Normal);
+        }
+
+        public static string GenerateRouteLink(RequestContext requestContext, RouteCollection routeCollection, string linkText, string routeName, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            return GenerateRouteLink(requestContext, routeCollection, linkText, routeName, null/* protocol */, null/* hostName */, null/* fragment */, routeValues, htmlAttributes);
+        }
+
+        public static string GenerateRouteLink(RequestContext requestContext, RouteCollection routeCollection, string linkText, string routeName, string protocol, string hostName, string fragment, RouteValueDictionary routeValues, IDictionary<string, object> htmlAttributes) {
+            return GenerateLinkInternal(requestContext, routeCollection, linkText, routeName, null /* actionName */, null /* controllerName */, protocol, hostName, fragment, routeValues, htmlAttributes, false /* includeImplicitMvcValues */);
+        }
+
+        public static string GetFormMethodString(FormMethod method) {
+            switch (method) {
+                case FormMethod.Get:
+                    return "get";
+                case FormMethod.Post:
+                    return "post";
+                default:
+                    return "post";
+            }
+        }
+
+        public static string GetInputTypeString(InputType inputType) {
+            switch (inputType) {
+                case InputType.CheckBox:
+                    return "checkbox";
+                case InputType.Hidden:
+                    return "hidden";
+                case InputType.Password:
+                    return "password";
+                case InputType.Radio:
+                    return "radio";
+                case InputType.Text:
+                    return "text";
+                default:
+                    return "text";
+            }
+        }
+
+        internal object GetModelStateValue(string key, Type destinationType) {
+            ModelState modelState;
+            if (ViewData.ModelState.TryGetValue(key, out modelState)) {
+                if (modelState.Value != null) {
+                    return modelState.Value.ConvertTo(destinationType, null /* culture */);
+                }
+            }
+            return null;
+        }
+
+        public IDictionary<string, object> GetUnobtrusiveValidationAttributes(string name) {
+            return GetUnobtrusiveValidationAttributes(name, metadata: null);
+        }
+
+        // Only render attributes if unobtrusive client-side validation is enabled, and then only if we've
+        // never rendered validation for a field with this name in this form. Also, if there's no form context,
+        // then we can't render the attributes (we'd have no <form> to attach them to).
+        public IDictionary<string, object> GetUnobtrusiveValidationAttributes(string name, ModelMetadata metadata) {
+            Dictionary<string, object> results = new Dictionary<string, object>();
+
+            // The ordering of these 3 checks (and the early exits) is for performance reasons.
+            if (!ViewContext.UnobtrusiveJavaScriptEnabled) {
+                return results;
+            }
+
+            FormContext formContext = ViewContext.GetFormContextForClientValidation();
+            if (formContext == null) {
+                return results;
+            }
+
+            string fullName = ViewData.TemplateInfo.GetFullHtmlFieldName(name);
+            if (formContext.RenderedField(fullName)) {
+                return results;
+            }
+
+            formContext.RenderedField(fullName, true);
+
+            IEnumerable<ModelClientValidationRule> clientRules = ClientValidationRuleFactory(name, metadata);
+            bool renderedRules = false;
+
+            foreach (ModelClientValidationRule rule in clientRules) {
+                renderedRules = true;
+                string ruleName = "data-val-" + rule.ValidationType;
+
+                ValidateUnobtrusiveValidationRule(rule, results, ruleName);
+
+                results.Add(ruleName, HttpUtility.HtmlEncode(rule.ErrorMessage ?? String.Empty));
+                ruleName += "-";
+
+                foreach (var kvp in rule.ValidationParameters) {
+                    results.Add(ruleName + kvp.Key, kvp.Value ?? String.Empty);
+                }
+            }
+
+            if (renderedRules) {
+                results.Add("data-val", "true");
+            }
+
+            return results;
+        }
+
+        public MvcHtmlString HttpMethodOverride(HttpVerbs httpVerb) {
+            string httpMethod;
+            switch (httpVerb) {
+                case HttpVerbs.Delete:
+                    httpMethod = "DELETE";
+                    break;
+                case HttpVerbs.Head:
+                    httpMethod = "HEAD";
+                    break;
+                case HttpVerbs.Put:
+                    httpMethod = "PUT";
+                    break;
+                default:
+                    throw new ArgumentException(MvcResources.HtmlHelper_InvalidHttpVerb, "httpVerb");
+            }
+
+            return HttpMethodOverride(httpMethod);
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "For consistency, all helpers are instance methods.")]
+        public MvcHtmlString HttpMethodOverride(string httpMethod) {
+            if (String.IsNullOrEmpty(httpMethod)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "httpMethod");
+            }
+            if (String.Equals(httpMethod, "GET", StringComparison.OrdinalIgnoreCase) ||
+                String.Equals(httpMethod, "POST", StringComparison.OrdinalIgnoreCase)) {
+                throw new ArgumentException(MvcResources.HtmlHelper_InvalidHttpMethod, "httpMethod");
+            }
+
+            TagBuilder tagBuilder = new TagBuilder("input");
+            tagBuilder.Attributes["type"] = "hidden";
+            tagBuilder.Attributes["name"] = HttpRequestExtensions.XHttpMethodOverrideKey;
+            tagBuilder.Attributes["value"] = httpMethod;
+
+            return tagBuilder.ToMvcHtmlString(TagRenderMode.SelfClosing);
+        }
+
+        /// <summary>
+        /// Wraps HTML markup in an IHtmlString, which will enable HTML markup to be
+        /// rendered to the output without getting HTML encoded.
+        /// </summary>
+        /// <param name="value">HTML markup string.</param>
+        /// <returns>An IHtmlString that represents HTML markup.</returns>
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "For consistency, all helpers are instance methods.")]
+        public IHtmlString Raw(string value) {
+            return new HtmlString(value);
+        }
+
+        internal virtual void RenderPartialInternal(string partialViewName, ViewDataDictionary viewData, object model, TextWriter writer, ViewEngineCollection viewEngineCollection) {
+            if (String.IsNullOrEmpty(partialViewName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "partialViewName");
+            }
+
+            ViewDataDictionary newViewData = null;
+
+            if (model == null) {
+                if (viewData == null) {
+                    newViewData = new ViewDataDictionary(ViewData);
+                }
+                else {
+                    newViewData = new ViewDataDictionary(viewData);
+                }
+            }
+            else {
+                if (viewData == null) {
+                    newViewData = new ViewDataDictionary(model);
+                }
+                else {
+                    newViewData = new ViewDataDictionary(viewData) { Model = model };
+                }
+            }
+
+            ViewContext newViewContext = new ViewContext(ViewContext, ViewContext.View, newViewData, ViewContext.TempData, writer);
+            IView view = FindPartialView(newViewContext, partialViewName, viewEngineCollection);
+            view.Render(newViewContext, writer);
+        }
+
+        private static void ValidateUnobtrusiveValidationRule(ModelClientValidationRule rule, Dictionary<string, object> resultsDictionary, string dictionaryKey) {
+            if (String.IsNullOrWhiteSpace(rule.ValidationType)) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.HtmlHelper_ValidationTypeCannotBeEmpty,
+                        rule.GetType().FullName
+                    )
+                );
+            }
+
+            if (resultsDictionary.ContainsKey(dictionaryKey)) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.HtmlHelper_ValidationTypeMustBeUnique,
+                        rule.ValidationType
+                    )
+                );
+            }
+
+            if (rule.ValidationType.Any(c => !Char.IsLower(c))) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.HtmlHelper_ValidationTypeMustBeLegal,
+                        rule.ValidationType,
+                        rule.GetType().FullName
+                    )
+                );
+            }
+
+            foreach (var key in rule.ValidationParameters.Keys) {
+                if (String.IsNullOrWhiteSpace(key)) {
+                    throw new InvalidOperationException(
+                        String.Format(
+                            CultureInfo.CurrentCulture,
+                            MvcResources.HtmlHelper_ValidationParameterCannotBeEmpty,
+                            rule.GetType().FullName
+                        )
+                    );
+                }
+
+                if (!Char.IsLower(key.First()) || key.Any(c => !Char.IsLower(c) && !Char.IsDigit(c))) {
+                    throw new InvalidOperationException(
+                        String.Format(
+                            CultureInfo.CurrentCulture,
+                            MvcResources.HtmlHelper_ValidationParameterMustBeLegal,
+                            key,
+                            rule.GetType().FullName
+                        )
+                    );
+                }
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HtmlHelper`1.cs b/mcs/class/System.Web.Mvc3/Mvc/HtmlHelper`1.cs
new file mode 100644 (file)
index 0000000..c4886d7
--- /dev/null
@@ -0,0 +1,23 @@
+namespace System.Web.Mvc {
+    using System.Web.Routing;
+
+    public class HtmlHelper<TModel> : HtmlHelper {
+        private ViewDataDictionary<TModel> _viewData;
+
+        public HtmlHelper(ViewContext viewContext, IViewDataContainer viewDataContainer)
+            : this(viewContext, viewDataContainer, RouteTable.Routes) {
+        }
+
+        public HtmlHelper(ViewContext viewContext, IViewDataContainer viewDataContainer, RouteCollection routeCollection)
+            : base(viewContext, viewDataContainer, routeCollection) {
+
+            _viewData = new ViewDataDictionary<TModel>(viewDataContainer.ViewData);
+        }
+
+        public new ViewDataDictionary<TModel> ViewData {
+            get {
+                return _viewData;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpDeleteAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpDeleteAttribute.cs
new file mode 100644 (file)
index 0000000..5f770da
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Reflection;
+    using System.Web;
+
+    [AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public sealed class HttpDeleteAttribute : ActionMethodSelectorAttribute {
+
+        private static readonly AcceptVerbsAttribute _innerAttribute = new AcceptVerbsAttribute(HttpVerbs.Delete);
+
+        public override bool IsValidForRequest(ControllerContext controllerContext, MethodInfo methodInfo) {
+            return _innerAttribute.IsValidForRequest(controllerContext, methodInfo);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpFileCollectionValueProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpFileCollectionValueProvider.cs
new file mode 100644 (file)
index 0000000..214e65c
--- /dev/null
@@ -0,0 +1,40 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.Linq;
+
+    public sealed class HttpFileCollectionValueProvider : DictionaryValueProvider<HttpPostedFileBase[]> {
+
+        private static readonly Dictionary<string, HttpPostedFileBase[]> _emptyDictionary = new Dictionary<string, HttpPostedFileBase[]>();
+
+        public HttpFileCollectionValueProvider(ControllerContext controllerContext)
+            : base(GetHttpPostedFileDictionary(controllerContext), CultureInfo.InvariantCulture) {
+        }
+
+        private static Dictionary<string, HttpPostedFileBase[]> GetHttpPostedFileDictionary(ControllerContext controllerContext) {
+            HttpFileCollectionBase files = controllerContext.HttpContext.Request.Files;
+
+            // fast-track common case of no files
+            if (files.Count == 0) {
+                return _emptyDictionary;
+            }
+
+            // build up the 1:many file mapping
+            List<KeyValuePair<string, HttpPostedFileBase>> mapping = new List<KeyValuePair<string, HttpPostedFileBase>>();
+            string[] allKeys = files.AllKeys;
+            for (int i = 0; i < files.Count; i++) {
+                string key = allKeys[i];
+                if (key != null) {
+                    HttpPostedFileBase file = HttpPostedFileBaseModelBinder.ChooseFileOrNull(files[i]);
+                    mapping.Add(new KeyValuePair<string, HttpPostedFileBase>(key, file));
+                }
+            }
+
+            // turn the mapping into a 1:many dictionary
+            var grouped = mapping.GroupBy(el => el.Key, el => el.Value, StringComparer.OrdinalIgnoreCase);
+            return grouped.ToDictionary(g => g.Key, g => g.ToArray(), StringComparer.OrdinalIgnoreCase);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpFileCollectionValueProviderFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpFileCollectionValueProviderFactory.cs
new file mode 100644 (file)
index 0000000..370933f
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public sealed class HttpFileCollectionValueProviderFactory : ValueProviderFactory {
+
+        public override IValueProvider GetValueProvider(ControllerContext controllerContext) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            return new HttpFileCollectionValueProvider(controllerContext);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpGetAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpGetAttribute.cs
new file mode 100644 (file)
index 0000000..edcd2aa
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Reflection;
+    using System.Web;
+
+    [AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public sealed class HttpGetAttribute : ActionMethodSelectorAttribute {
+
+        private static readonly AcceptVerbsAttribute _innerAttribute = new AcceptVerbsAttribute(HttpVerbs.Get);
+
+        public override bool IsValidForRequest(ControllerContext controllerContext, MethodInfo methodInfo) {
+            return _innerAttribute.IsValidForRequest(controllerContext, methodInfo);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpHandlerUtil.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpHandlerUtil.cs
new file mode 100644 (file)
index 0000000..83fad89
--- /dev/null
@@ -0,0 +1,77 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+    using System.Web.UI;
+
+    internal static class HttpHandlerUtil {
+
+        // Since Server.Execute() doesn't propagate HttpExceptions where the status code is
+        // anything other than 500, we need to wrap these exceptions ourselves.
+        [SuppressMessage("Microsoft.Reliability", "CA2000:Dispose objects before losing scope", Justification = "The Dispose on Page doesn't do anything by default, and we control both of these internal types.")]
+        public static IHttpHandler WrapForServerExecute(IHttpHandler httpHandler) {
+            IHttpAsyncHandler asyncHandler = httpHandler as IHttpAsyncHandler;
+            return (asyncHandler != null) ? new ServerExecuteHttpHandlerAsyncWrapper(asyncHandler) : new ServerExecuteHttpHandlerWrapper(httpHandler);
+        }
+
+        // Server.Execute() requires that the provided IHttpHandler subclass Page.
+        internal class ServerExecuteHttpHandlerWrapper : Page {
+            private readonly IHttpHandler _httpHandler;
+
+            public ServerExecuteHttpHandlerWrapper(IHttpHandler httpHandler) {
+                _httpHandler = httpHandler;
+            }
+
+            internal IHttpHandler InnerHandler {
+                get {
+                    return _httpHandler;
+                }
+            }
+
+            public override void ProcessRequest(HttpContext context) {
+                Wrap(() => _httpHandler.ProcessRequest(context));
+            }
+
+            protected static void Wrap(Action action) {
+                Wrap(delegate {
+                    action();
+                    return (object)null;
+                });
+            }
+
+            protected static TResult Wrap<TResult>(Func<TResult> func) {
+                try {
+                    return func();
+                }
+                catch (HttpException he) {
+                    if (he.GetHttpCode() == 500) {
+                        throw; // doesn't need to be wrapped
+                    }
+                    else {
+                        HttpException newHe = new HttpException(500, MvcResources.ViewPageHttpHandlerWrapper_ExceptionOccurred, he);
+                        throw newHe;
+                    }
+                }
+            }
+        }
+
+        private sealed class ServerExecuteHttpHandlerAsyncWrapper : ServerExecuteHttpHandlerWrapper, IHttpAsyncHandler {
+            private readonly IHttpAsyncHandler _httpHandler;
+
+            public ServerExecuteHttpHandlerAsyncWrapper(IHttpAsyncHandler httpHandler)
+                : base(httpHandler) {
+                _httpHandler = httpHandler;
+            }
+
+            public IAsyncResult BeginProcessRequest(HttpContext context, AsyncCallback cb, object extraData) {
+                return Wrap(() => _httpHandler.BeginProcessRequest(context, cb, extraData));
+            }
+
+            public void EndProcessRequest(IAsyncResult result) {
+                Wrap(() => _httpHandler.EndProcessRequest(result));
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpNotFoundResult.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpNotFoundResult.cs
new file mode 100644 (file)
index 0000000..0ac8b67
--- /dev/null
@@ -0,0 +1,16 @@
+namespace System.Web.Mvc {
+
+    public class HttpNotFoundResult : HttpStatusCodeResult {
+
+        // HTTP 404 is the status code for Not Found
+        private const int NotFoundCode = 404;
+
+        public HttpNotFoundResult()
+            : this(null) {
+        }
+
+        public HttpNotFoundResult(string statusDescription)
+            : base(NotFoundCode, statusDescription) {
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpPostAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpPostAttribute.cs
new file mode 100644 (file)
index 0000000..2ce720a
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Reflection;
+    using System.Web;
+
+    [AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public sealed class HttpPostAttribute : ActionMethodSelectorAttribute {
+
+        private static readonly AcceptVerbsAttribute _innerAttribute = new AcceptVerbsAttribute(HttpVerbs.Post);
+
+        public override bool IsValidForRequest(ControllerContext controllerContext, MethodInfo methodInfo) {
+            return _innerAttribute.IsValidForRequest(controllerContext, methodInfo);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpPostedFileBaseModelBinder.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpPostedFileBaseModelBinder.cs
new file mode 100644 (file)
index 0000000..0778e53
--- /dev/null
@@ -0,0 +1,36 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Web;
+
+    public class HttpPostedFileBaseModelBinder : IModelBinder {
+
+        public object BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (bindingContext == null) {
+                throw new ArgumentNullException("bindingContext");
+            }
+
+            HttpPostedFileBase theFile = controllerContext.HttpContext.Request.Files[bindingContext.ModelName];
+            return ChooseFileOrNull(theFile);
+        }
+
+        // helper that returns the original file if there was content uploaded, null if empty
+        internal static HttpPostedFileBase ChooseFileOrNull(HttpPostedFileBase rawFile) {
+            // case 1: there was no <input type="file" ... /> element in the post
+            if (rawFile == null) {
+                return null;
+            }
+
+            // case 2: there was an <input type="file" ... /> element in the post, but it was left blank
+            if (rawFile.ContentLength == 0 && String.IsNullOrEmpty(rawFile.FileName)) {
+                return null;
+            }
+
+            // case 3: the file was posted
+            return rawFile;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpPutAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpPutAttribute.cs
new file mode 100644 (file)
index 0000000..821b5d6
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Reflection;
+    using System.Web;
+
+    [AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public sealed class HttpPutAttribute : ActionMethodSelectorAttribute {
+
+        private static readonly AcceptVerbsAttribute _innerAttribute = new AcceptVerbsAttribute(HttpVerbs.Put);
+
+        public override bool IsValidForRequest(ControllerContext controllerContext, MethodInfo methodInfo) {
+            return _innerAttribute.IsValidForRequest(controllerContext, methodInfo);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpRequestExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpRequestExtensions.cs
new file mode 100644 (file)
index 0000000..a6ec856
--- /dev/null
@@ -0,0 +1,44 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public static class HttpRequestExtensions {
+        internal const string XHttpMethodOverrideKey = "X-HTTP-Method-Override";
+
+        public static string GetHttpMethodOverride(this HttpRequestBase request) {
+            if (request == null) {
+                throw new ArgumentNullException("request");
+            }
+
+            string incomingVerb = request.HttpMethod;
+
+            if (!String.Equals(incomingVerb, "POST", StringComparison.OrdinalIgnoreCase)) {
+                return incomingVerb;
+            }
+
+            string verbOverride = null;
+            string headerOverrideValue = request.Headers[XHttpMethodOverrideKey];
+            if (!String.IsNullOrEmpty(headerOverrideValue)) {
+                verbOverride = headerOverrideValue;
+            }
+            else {
+                string formOverrideValue = request.Form[XHttpMethodOverrideKey];
+                if (!String.IsNullOrEmpty(formOverrideValue)) {
+                    verbOverride = formOverrideValue;
+                }
+                else {
+                    string queryStringOverrideValue = request.QueryString[XHttpMethodOverrideKey];
+                    if (!String.IsNullOrEmpty(queryStringOverrideValue)) {
+                        verbOverride = queryStringOverrideValue;
+                    }
+                }
+            }
+            if (verbOverride != null) {
+                if (!String.Equals(verbOverride, "GET", StringComparison.OrdinalIgnoreCase) &&
+                    !String.Equals(verbOverride, "POST", StringComparison.OrdinalIgnoreCase)) {
+                    incomingVerb = verbOverride;
+                }
+            }
+            return incomingVerb;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpStatusCodeResult.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpStatusCodeResult.cs
new file mode 100644 (file)
index 0000000..d71b400
--- /dev/null
@@ -0,0 +1,34 @@
+namespace System.Web.Mvc {
+
+    public class HttpStatusCodeResult : ActionResult {
+        public HttpStatusCodeResult(int statusCode)
+            : this(statusCode, null) {
+        }
+
+        public HttpStatusCodeResult(int statusCode, string statusDescription) {
+            StatusCode = statusCode;
+            StatusDescription = statusDescription;
+        }
+
+        public int StatusCode {
+            get;
+            private set;
+        }
+
+        public string StatusDescription {
+            get;
+            private set;
+        }
+
+        public override void ExecuteResult(ControllerContext context) {
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+
+            context.HttpContext.Response.StatusCode = StatusCode;
+            if (StatusDescription != null) {
+                context.HttpContext.Response.StatusDescription = StatusDescription;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpUnauthorizedResult.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpUnauthorizedResult.cs
new file mode 100644 (file)
index 0000000..2e5e6aa
--- /dev/null
@@ -0,0 +1,19 @@
+namespace System.Web.Mvc {
+
+    public class HttpUnauthorizedResult : HttpStatusCodeResult {
+
+        // HTTP 401 is the status code for unauthorized access. Other code might
+        // intercept this and perform some special logic. For example, the
+        // FormsAuthenticationModule looks for 401 responses and instead redirects
+        // the user to the login page.
+        private const int UnauthorizedCode = 401;
+
+        public HttpUnauthorizedResult()
+            : this(null) {
+        }
+
+        public HttpUnauthorizedResult(string statusDescription)
+            : base(UnauthorizedCode, statusDescription) {
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/HttpVerbs.cs b/mcs/class/System.Web.Mvc3/Mvc/HttpVerbs.cs
new file mode 100644 (file)
index 0000000..f616348
--- /dev/null
@@ -0,0 +1,12 @@
+namespace System.Web.Mvc {
+    using System;
+
+    [Flags]
+    public enum HttpVerbs {
+        Get = 1 << 0,
+        Post = 1 << 1,
+        Put = 1 << 2,
+        Delete = 1 << 3,
+        Head = 1 << 4
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IActionFilter.cs b/mcs/class/System.Web.Mvc3/Mvc/IActionFilter.cs
new file mode 100644 (file)
index 0000000..fd0dd75
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc {
+
+    public interface IActionFilter {
+        void OnActionExecuting(ActionExecutingContext filterContext);
+        void OnActionExecuted(ActionExecutedContext filterContext);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IActionInvoker.cs b/mcs/class/System.Web.Mvc3/Mvc/IActionInvoker.cs
new file mode 100644 (file)
index 0000000..c6cff02
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+
+    public interface IActionInvoker {
+        bool InvokeAction(ControllerContext controllerContext, string actionName);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IAuthorizationFilter.cs b/mcs/class/System.Web.Mvc3/Mvc/IAuthorizationFilter.cs
new file mode 100644 (file)
index 0000000..2207633
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+
+    public interface IAuthorizationFilter {
+        void OnAuthorization(AuthorizationContext filterContext);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IBuildManager.cs b/mcs/class/System.Web.Mvc3/Mvc/IBuildManager.cs
new file mode 100644 (file)
index 0000000..c753a5b
--- /dev/null
@@ -0,0 +1,12 @@
+namespace System.Web.Mvc {
+    using System.Collections;
+    using System.IO;
+
+    internal interface IBuildManager {
+        bool FileExists(string virtualPath);
+        Type GetCompiledType(string virtualPath);
+        ICollection GetReferencedAssemblies();
+        Stream ReadCachedFile(string fileName);
+        Stream CreateCachedFile(string fileName);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IClientValidatable.cs b/mcs/class/System.Web.Mvc3/Mvc/IClientValidatable.cs
new file mode 100644 (file)
index 0000000..d8e8e41
--- /dev/null
@@ -0,0 +1,17 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+
+    // The purpose of this interface is to make something as supporting client-side
+    // validation, which could be discovered at runtime by whatever validation
+    // framework you're using. Because this interface is designed to be independent
+    // of underlying implementation details, where you apply this interface will
+    // depend on your specific validation framework.
+    //
+    // For DataAnnotations, you'll apply this interface to your validation attribute
+    // (the class which derives from ValidationAttribute). When you've implemented
+    // this interface, it will alleviate the need of writing a validator and registering
+    // it with the DataAnnotationsModelValidatorProvider.
+    public interface IClientValidatable {
+        IEnumerable<ModelClientValidationRule> GetClientValidationRules(ModelMetadata metadata, ControllerContext context);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IController.cs b/mcs/class/System.Web.Mvc3/Mvc/IController.cs
new file mode 100644 (file)
index 0000000..221b433
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc {
+    using System.Web.Routing;
+
+    public interface IController {
+        void Execute(RequestContext requestContext);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IControllerActivator.cs b/mcs/class/System.Web.Mvc3/Mvc/IControllerActivator.cs
new file mode 100644 (file)
index 0000000..3d99ef9
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc {
+    using System.Web.Routing;
+
+    public interface IControllerActivator {
+        IController Create(RequestContext requestContext, Type controllerType);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IControllerFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/IControllerFactory.cs
new file mode 100644 (file)
index 0000000..94f3d95
--- /dev/null
@@ -0,0 +1,10 @@
+namespace System.Web.Mvc {
+    using System.Web.Routing;
+    using System.Web.SessionState;
+
+    public interface IControllerFactory {
+        IController CreateController(RequestContext requestContext, string controllerName);
+        SessionStateBehavior GetControllerSessionBehavior(RequestContext requestContext, string controllerName);
+        void ReleaseController(IController controller);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IDependencyResolver.cs b/mcs/class/System.Web.Mvc3/Mvc/IDependencyResolver.cs
new file mode 100644 (file)
index 0000000..326c4d9
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+
+    public interface IDependencyResolver {
+        object GetService(Type serviceType);
+        IEnumerable<object> GetServices(Type serviceType);
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IExceptionFilter.cs b/mcs/class/System.Web.Mvc3/Mvc/IExceptionFilter.cs
new file mode 100644 (file)
index 0000000..20d4344
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+
+    public interface IExceptionFilter {
+        void OnException(ExceptionContext filterContext);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IFilterProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/IFilterProvider.cs
new file mode 100644 (file)
index 0000000..63723ed
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+
+    public interface IFilterProvider {
+        IEnumerable<Filter> GetFilters(ControllerContext controllerContext, ActionDescriptor actionDescriptor);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IMetadataAware.cs b/mcs/class/System.Web.Mvc3/Mvc/IMetadataAware.cs
new file mode 100644 (file)
index 0000000..a2cacb4
--- /dev/null
@@ -0,0 +1,10 @@
+namespace System.Web.Mvc {
+    // This interface is implemented by attributes which wish to contribute to the
+    // ModelMetadata creation process without needing to write a custom metadata
+    // provider. It is consumed by AssociatedMetadataProvider, so this behavior is
+    // automatically inherited by all classes which derive from it (notably, the
+    // DataAnnotationsModelMetadataProvider).
+    public interface IMetadataAware {
+        void OnMetadataCreated(ModelMetadata metadata);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IModelBinder.cs b/mcs/class/System.Web.Mvc3/Mvc/IModelBinder.cs
new file mode 100644 (file)
index 0000000..1e1dde0
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+
+    public interface IModelBinder {
+        object BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IModelBinderProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/IModelBinderProvider.cs
new file mode 100644 (file)
index 0000000..6820263
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+
+    public interface IModelBinderProvider {
+        IModelBinder GetBinder(Type modelType);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IMvcControlBuilder.cs b/mcs/class/System.Web.Mvc3/Mvc/IMvcControlBuilder.cs
new file mode 100644 (file)
index 0000000..5211b0f
--- /dev/null
@@ -0,0 +1,5 @@
+namespace System.Web.Mvc {
+    internal interface IMvcControlBuilder {
+        string Inherits { set; }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IMvcFilter.cs b/mcs/class/System.Web.Mvc3/Mvc/IMvcFilter.cs
new file mode 100644 (file)
index 0000000..c69955d
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+    public interface IMvcFilter {
+        bool AllowMultiple { get; }
+        int Order { get; }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IResolver.cs b/mcs/class/System.Web.Mvc3/Mvc/IResolver.cs
new file mode 100644 (file)
index 0000000..dfa0271
--- /dev/null
@@ -0,0 +1,5 @@
+namespace System.Web.Mvc {
+    internal interface IResolver<T> {
+        T Current { get; }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IResultFilter.cs b/mcs/class/System.Web.Mvc3/Mvc/IResultFilter.cs
new file mode 100644 (file)
index 0000000..73a5f0b
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc {
+
+    public interface IResultFilter {
+        void OnResultExecuting(ResultExecutingContext filterContext);
+        void OnResultExecuted(ResultExecutedContext filterContext);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IRouteWithArea.cs b/mcs/class/System.Web.Mvc3/Mvc/IRouteWithArea.cs
new file mode 100644 (file)
index 0000000..8128a3a
--- /dev/null
@@ -0,0 +1,9 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public interface IRouteWithArea {
+
+        string Area { get; }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ITempDataProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/ITempDataProvider.cs
new file mode 100644 (file)
index 0000000..4b3e52d
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+
+    public interface ITempDataProvider {
+        IDictionary<string, object> LoadTempData(ControllerContext controllerContext);
+        void SaveTempData(ControllerContext controllerContext, IDictionary<string, object> values);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IUniquelyIdentifiable.cs b/mcs/class/System.Web.Mvc3/Mvc/IUniquelyIdentifiable.cs
new file mode 100644 (file)
index 0000000..5f32338
--- /dev/null
@@ -0,0 +1,5 @@
+namespace System.Web.Mvc {
+    internal interface IUniquelyIdentifiable {
+        string UniqueId { get; }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IUnvalidatedRequestValues.cs b/mcs/class/System.Web.Mvc3/Mvc/IUnvalidatedRequestValues.cs
new file mode 100644 (file)
index 0000000..8cf2781
--- /dev/null
@@ -0,0 +1,13 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Specialized;
+    using System.Web;
+
+    // Used for mocking the UnvalidatedRequestValues type in System.Web.WebPages
+
+    internal interface IUnvalidatedRequestValues {
+        NameValueCollection Form { get; }
+        NameValueCollection QueryString { get; }
+        string this[string key] { get; }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IUnvalidatedValueProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/IUnvalidatedValueProvider.cs
new file mode 100644 (file)
index 0000000..129a3a1
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc {
+    using System;
+
+    // Represents a special IValueProvider that has the ability to skip request validation.
+    public interface IUnvalidatedValueProvider : IValueProvider {
+        ValueProviderResult GetValue(string key, bool skipValidation);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IValueProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/IValueProvider.cs
new file mode 100644 (file)
index 0000000..c4dec89
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public interface IValueProvider {
+        bool ContainsPrefix(string prefix);
+        ValueProviderResult GetValue(string key);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IView.cs b/mcs/class/System.Web.Mvc3/Mvc/IView.cs
new file mode 100644 (file)
index 0000000..af41043
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc {
+    using System.IO;
+
+    public interface IView {
+        void Render(ViewContext viewContext, TextWriter writer);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IViewDataContainer.cs b/mcs/class/System.Web.Mvc3/Mvc/IViewDataContainer.cs
new file mode 100644 (file)
index 0000000..a179a75
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc {
+    using System.Diagnostics.CodeAnalysis;
+
+    public interface IViewDataContainer {
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This is the mechanism by which the ViewPage / ViewUserControl get their ViewDataDictionary objects.")]
+        ViewDataDictionary ViewData { get; set; }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IViewEngine.cs b/mcs/class/System.Web.Mvc3/Mvc/IViewEngine.cs
new file mode 100644 (file)
index 0000000..ee5c992
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc {
+
+    public interface IViewEngine {
+        ViewEngineResult FindPartialView(ControllerContext controllerContext, string partialViewName, bool useCache);
+        ViewEngineResult FindView(ControllerContext controllerContext, string viewName, string masterName, bool useCache);
+        void ReleaseView(ControllerContext controllerContext, IView view);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IViewLocationCache.cs b/mcs/class/System.Web.Mvc3/Mvc/IViewLocationCache.cs
new file mode 100644 (file)
index 0000000..ca62b47
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc {
+    using System.Web;
+
+    public interface IViewLocationCache {
+        string GetViewLocation(HttpContextBase httpContext, string key);
+        void InsertViewLocation(HttpContextBase httpContext, string key, string virtualPath);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IViewPageActivator.cs b/mcs/class/System.Web.Mvc3/Mvc/IViewPageActivator.cs
new file mode 100644 (file)
index 0000000..9f8bd9f
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+
+    public interface IViewPageActivator {
+        object Create(ControllerContext controllerContext, Type type);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/IViewStartPageChild.cs b/mcs/class/System.Web.Mvc3/Mvc/IViewStartPageChild.cs
new file mode 100644 (file)
index 0000000..2cfedc5
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc {
+
+    internal interface IViewStartPageChild {
+        HtmlHelper<object> Html { get; }
+        UrlHelper Url { get; }
+        ViewContext ViewContext { get; }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/InputType.cs b/mcs/class/System.Web.Mvc3/Mvc/InputType.cs
new file mode 100644 (file)
index 0000000..eb14a1b
--- /dev/null
@@ -0,0 +1,9 @@
+namespace System.Web.Mvc {
+    public enum InputType {
+        CheckBox,
+        Hidden,
+        Password,
+        Radio,
+        Text
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/JavaScriptResult.cs b/mcs/class/System.Web.Mvc3/Mvc/JavaScriptResult.cs
new file mode 100644 (file)
index 0000000..b3e7d54
--- /dev/null
@@ -0,0 +1,24 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public class JavaScriptResult : ActionResult {
+
+        public string Script {
+            get;
+            set;
+        }
+
+        public override void ExecuteResult(ControllerContext context) {
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+
+            HttpResponseBase response = context.HttpContext.Response;
+            response.ContentType = "application/x-javascript";
+
+            if (Script != null) {
+                response.Write(Script);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/JsonRequestBehavior.cs b/mcs/class/System.Web.Mvc3/Mvc/JsonRequestBehavior.cs
new file mode 100644 (file)
index 0000000..e040dbb
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+    public enum JsonRequestBehavior {
+        AllowGet,
+        DenyGet,
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/JsonResult.cs b/mcs/class/System.Web.Mvc3/Mvc/JsonResult.cs
new file mode 100644 (file)
index 0000000..b5b8f61
--- /dev/null
@@ -0,0 +1,60 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Text;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+    using System.Web.Script.Serialization;
+
+    public class JsonResult : ActionResult {
+
+        public JsonResult() {
+            JsonRequestBehavior = JsonRequestBehavior.DenyGet;
+        }
+
+        public Encoding ContentEncoding {
+            get;
+            set;
+        }
+
+        public string ContentType {
+            get;
+            set;
+        }
+
+        public object Data {
+            get;
+            set;
+        }
+
+        public JsonRequestBehavior JsonRequestBehavior {
+            get;
+            set;
+        }
+
+        public override void ExecuteResult(ControllerContext context) {
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+            if (JsonRequestBehavior == JsonRequestBehavior.DenyGet &&
+                String.Equals(context.HttpContext.Request.HttpMethod, "GET", StringComparison.OrdinalIgnoreCase)) {
+                throw new InvalidOperationException(MvcResources.JsonRequest_GetNotAllowed);
+            }
+
+            HttpResponseBase response = context.HttpContext.Response;
+
+            if (!String.IsNullOrEmpty(ContentType)) {
+                response.ContentType = ContentType;
+            }
+            else {
+                response.ContentType = "application/json";
+            }
+            if (ContentEncoding != null) {
+                response.ContentEncoding = ContentEncoding;
+            }
+            if (Data != null) {
+                JavaScriptSerializer serializer = new JavaScriptSerializer();
+                response.Write(serializer.Serialize(Data));
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/JsonValueProviderFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/JsonValueProviderFactory.cs
new file mode 100644 (file)
index 0000000..f3e6056
--- /dev/null
@@ -0,0 +1,73 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.IO;
+    using System.Web.Script.Serialization;
+
+    public sealed class JsonValueProviderFactory : ValueProviderFactory {
+
+        private static void AddToBackingStore(Dictionary<string, object> backingStore, string prefix, object value) {
+            IDictionary<string, object> d = value as IDictionary<string, object>;
+            if (d != null) {
+                foreach (KeyValuePair<string, object> entry in d) {
+                    AddToBackingStore(backingStore, MakePropertyKey(prefix, entry.Key), entry.Value);
+                }
+                return;
+            }
+
+            IList l = value as IList;
+            if (l != null) {
+                for (int i = 0; i < l.Count; i++) {
+                    AddToBackingStore(backingStore, MakeArrayKey(prefix, i), l[i]);
+                }
+                return;
+            }
+
+            // primitive
+            backingStore[prefix] = value;
+        }
+
+        private static object GetDeserializedObject(ControllerContext controllerContext) {
+            if (!controllerContext.HttpContext.Request.ContentType.StartsWith("application/json", StringComparison.OrdinalIgnoreCase)) {
+                // not JSON request
+                return null;
+            }
+
+            StreamReader reader = new StreamReader(controllerContext.HttpContext.Request.InputStream);
+            string bodyText = reader.ReadToEnd();
+            if (String.IsNullOrEmpty(bodyText)) {
+                // no JSON data
+                return null;
+            }
+
+            JavaScriptSerializer serializer = new JavaScriptSerializer();
+            object jsonData = serializer.DeserializeObject(bodyText);
+            return jsonData;
+        }
+
+        public override IValueProvider GetValueProvider(ControllerContext controllerContext) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            object jsonData = GetDeserializedObject(controllerContext);
+            if (jsonData == null) {
+                return null;
+            }
+
+            Dictionary<string, object> backingStore = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
+            AddToBackingStore(backingStore, String.Empty, jsonData);
+            return new DictionaryValueProvider<object>(backingStore, CultureInfo.CurrentCulture);
+        }
+
+        private static string MakeArrayKey(string prefix, int index) {
+            return prefix + "[" + index.ToString(CultureInfo.InvariantCulture) + "]";
+        }
+
+        private static string MakePropertyKey(string prefix, string propertyName) {
+            return (String.IsNullOrEmpty(prefix)) ? propertyName : prefix + "." + propertyName;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/LinqBinaryModelBinder.cs b/mcs/class/System.Web.Mvc3/Mvc/LinqBinaryModelBinder.cs
new file mode 100644 (file)
index 0000000..9c5aef0
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System.Data.Linq;
+
+    public class LinqBinaryModelBinder : ByteArrayModelBinder {
+        public override object BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext) {
+            byte[] byteValue = (byte[])base.BindModel(controllerContext, bindingContext);
+            if (byteValue == null) {
+                return null;
+            }
+
+            return new Binary(byteValue);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelBinderAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelBinderAttribute.cs
new file mode 100644 (file)
index 0000000..b466c55
--- /dev/null
@@ -0,0 +1,42 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Globalization;
+    using System.Web.Mvc.Resources;
+
+    [AttributeUsage(ValidTargets, AllowMultiple = false, Inherited = false)]
+    public sealed class ModelBinderAttribute : CustomModelBinderAttribute {
+
+        public ModelBinderAttribute(Type binderType) {
+            if (binderType == null) {
+                throw new ArgumentNullException("binderType");
+            }
+            if (!typeof(IModelBinder).IsAssignableFrom(binderType)) {
+                string message = String.Format(CultureInfo.CurrentCulture,
+                    MvcResources.ModelBinderAttribute_TypeNotIModelBinder, binderType.FullName);
+                throw new ArgumentException(message, "binderType");
+            }
+
+            BinderType = binderType;
+        }
+
+        public Type BinderType {
+            get;
+            private set;
+        }
+
+        public override IModelBinder GetBinder() {
+            try {
+                return (IModelBinder)Activator.CreateInstance(BinderType);
+            }
+            catch (Exception ex) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.ModelBinderAttribute_ErrorCreatingModelBinder,
+                        BinderType.FullName),
+                    ex);
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelBinderDictionary.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelBinderDictionary.cs
new file mode 100644 (file)
index 0000000..900569f
--- /dev/null
@@ -0,0 +1,152 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.Web.Mvc.Resources;
+
+    public class ModelBinderDictionary : IDictionary<Type, IModelBinder> {
+
+        private IModelBinder _defaultBinder;
+        private readonly Dictionary<Type, IModelBinder> _innerDictionary = new Dictionary<Type, IModelBinder>();
+        private ModelBinderProviderCollection _modelBinderProviders;
+
+        public ModelBinderDictionary()
+            : this(ModelBinderProviders.BinderProviders) {
+        }
+
+        internal ModelBinderDictionary(ModelBinderProviderCollection modelBinderProviders) {
+            _modelBinderProviders = modelBinderProviders;
+        }
+
+        public int Count {
+            get {
+                return _innerDictionary.Count;
+            }
+        }
+
+        public IModelBinder DefaultBinder {
+            get {
+                if (_defaultBinder == null) {
+                    _defaultBinder = new DefaultModelBinder();
+                }
+                return _defaultBinder;
+            }
+            set {
+                _defaultBinder = value;
+            }
+        }
+
+        public bool IsReadOnly {
+            get {
+                return ((IDictionary<Type, IModelBinder>)_innerDictionary).IsReadOnly;
+            }
+        }
+
+        public ICollection<Type> Keys {
+            get {
+                return _innerDictionary.Keys;
+            }
+        }
+
+        public IModelBinder this[Type key] {
+            get {
+
+                IModelBinder binder;
+                _innerDictionary.TryGetValue(key, out binder);
+                return binder;
+            }
+            set {
+                _innerDictionary[key] = value;
+            }
+        }
+
+        public ICollection<IModelBinder> Values {
+            get {
+                return _innerDictionary.Values;
+            }
+        }
+
+        public void Add(KeyValuePair<Type, IModelBinder> item) {
+            ((IDictionary<Type, IModelBinder>)_innerDictionary).Add(item);
+        }
+
+        public void Add(Type key, IModelBinder value) {
+            _innerDictionary.Add(key, value);
+        }
+
+        public void Clear() {
+            _innerDictionary.Clear();
+        }
+
+        public bool Contains(KeyValuePair<Type, IModelBinder> item) {
+            return ((IDictionary<Type, IModelBinder>)_innerDictionary).Contains(item);
+        }
+
+        public bool ContainsKey(Type key) {
+            return _innerDictionary.ContainsKey(key);
+        }
+
+        public void CopyTo(KeyValuePair<Type, IModelBinder>[] array, int arrayIndex) {
+            ((IDictionary<Type, IModelBinder>)_innerDictionary).CopyTo(array, arrayIndex);
+        }
+
+        public IModelBinder GetBinder(Type modelType) {
+            return GetBinder(modelType, true /* fallbackToDefault */);
+        }
+
+        public virtual IModelBinder GetBinder(Type modelType, bool fallbackToDefault) {
+            if (modelType == null) {
+                throw new ArgumentNullException("modelType");
+            }
+
+            return GetBinder(modelType, (fallbackToDefault) ? DefaultBinder : null);
+        }
+
+        private IModelBinder GetBinder(Type modelType, IModelBinder fallbackBinder) {
+
+            // Try to look up a binder for this type. We use this order of precedence:
+            // 1. Binder returned from provider
+            // 2. Binder registered in the global table
+            // 3. Binder attribute defined on the type
+            // 4. Supplied fallback binder
+
+            IModelBinder binder = _modelBinderProviders.GetBinder(modelType);
+            if (binder != null) {
+                return binder;
+            }
+
+            if (_innerDictionary.TryGetValue(modelType, out binder)) {
+                return binder;
+            }
+
+            binder = ModelBinders.GetBinderFromAttributes(modelType,
+                () => String.Format(CultureInfo.CurrentCulture, MvcResources.ModelBinderDictionary_MultipleAttributes, modelType.FullName));
+
+            return binder ?? fallbackBinder;
+        }
+
+        public IEnumerator<KeyValuePair<Type, IModelBinder>> GetEnumerator() {
+            return _innerDictionary.GetEnumerator();
+        }
+
+        public bool Remove(KeyValuePair<Type, IModelBinder> item) {
+            return ((IDictionary<Type, IModelBinder>)_innerDictionary).Remove(item);
+        }
+
+        public bool Remove(Type key) {
+            return _innerDictionary.Remove(key);
+        }
+
+        public bool TryGetValue(Type key, out IModelBinder value) {
+            return _innerDictionary.TryGetValue(key, out value);
+        }
+
+        #region IEnumerable Members
+        IEnumerator IEnumerable.GetEnumerator() {
+            return ((IEnumerable)_innerDictionary).GetEnumerator();
+        }
+        #endregion
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelBinderProviderCollection.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelBinderProviderCollection.cs
new file mode 100644 (file)
index 0000000..9b6cb77
--- /dev/null
@@ -0,0 +1,58 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+    using System.Linq;
+
+    public class ModelBinderProviderCollection : Collection<IModelBinderProvider> {
+
+        private IResolver<IEnumerable<IModelBinderProvider>> _serviceResolver;
+
+        public ModelBinderProviderCollection() {
+            _serviceResolver = new MultiServiceResolver<IModelBinderProvider>(() => Items);
+        }
+
+        public ModelBinderProviderCollection(IList<IModelBinderProvider> list)
+            : base(list) {
+            _serviceResolver = new MultiServiceResolver<IModelBinderProvider>(() => Items);
+        }
+
+        internal ModelBinderProviderCollection(IResolver<IEnumerable<IModelBinderProvider>> resolver, params IModelBinderProvider[] providers)
+            : base(providers) {
+            _serviceResolver = resolver ?? new MultiServiceResolver<IModelBinderProvider>(() => Items);
+        }
+
+        private IEnumerable<IModelBinderProvider> CombinedItems {
+            get {
+                return _serviceResolver.Current;
+            }
+        }
+
+        protected override void InsertItem(int index, IModelBinderProvider item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.InsertItem(index, item);
+        }
+
+        protected override void SetItem(int index, IModelBinderProvider item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.SetItem(index, item);
+        }
+
+        public IModelBinder GetBinder(Type modelType) {
+
+            if (modelType == null) {
+                throw new ArgumentNullException("modelType");
+            }
+
+            var modelBinders = from providers in CombinedItems
+                               let modelBinder = providers.GetBinder(modelType)
+                               where modelBinder != null
+                               select modelBinder;
+
+            return modelBinders.FirstOrDefault();
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelBinderProviders.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelBinderProviders.cs
new file mode 100644 (file)
index 0000000..238cd95
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+
+    public static class ModelBinderProviders {
+
+        private readonly static ModelBinderProviderCollection _binderProviders = new ModelBinderProviderCollection {
+        };
+
+        public static ModelBinderProviderCollection BinderProviders {
+            get {
+                return _binderProviders;
+            }
+        }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelBinders.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelBinders.cs
new file mode 100644 (file)
index 0000000..43549a1
--- /dev/null
@@ -0,0 +1,65 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.ComponentModel;
+    using System.Data.Linq;
+    using System.Linq;
+    using System.Reflection;
+    using System.Web;
+
+    public static class ModelBinders {
+
+        private static readonly ModelBinderDictionary _binders = CreateDefaultBinderDictionary();
+
+        public static ModelBinderDictionary Binders {
+            get {
+                return _binders;
+            }
+        }
+
+        internal static IModelBinder GetBinderFromAttributes(Type type, Func<string> errorMessageAccessor) {
+            AttributeCollection allAttrs = TypeDescriptorHelper.Get(type).GetAttributes();
+            CustomModelBinderAttribute[] filteredAttrs = allAttrs.OfType<CustomModelBinderAttribute>().ToArray();
+            return GetBinderFromAttributesImpl(filteredAttrs, errorMessageAccessor);
+        }
+
+        internal static IModelBinder GetBinderFromAttributes(ICustomAttributeProvider element, Func<string> errorMessageAccessor) {
+            CustomModelBinderAttribute[] attrs = (CustomModelBinderAttribute[])element.GetCustomAttributes(typeof(CustomModelBinderAttribute), true /* inherit */);
+            return GetBinderFromAttributesImpl(attrs, errorMessageAccessor);
+        }
+
+        private static IModelBinder GetBinderFromAttributesImpl(CustomModelBinderAttribute[] attrs, Func<string> errorMessageAccessor) {
+            // this method is used to get a custom binder based on the attributes of the element passed to it.
+            // it will return null if a binder cannot be detected based on the attributes alone.
+
+            if (attrs == null) {
+                return null;
+            }
+
+            switch (attrs.Length) {
+                case 0:
+                    return null;
+
+                case 1:
+                    IModelBinder binder = attrs[0].GetBinder();
+                    return binder;
+
+                default:
+                    string errorMessage = errorMessageAccessor();
+                    throw new InvalidOperationException(errorMessage);
+            }
+        }
+
+        private static ModelBinderDictionary CreateDefaultBinderDictionary() {
+            // We can't add a binder to the HttpPostedFileBase type as an attribute, so we'll just
+            // prepopulate the dictionary as a convenience to users.
+
+            ModelBinderDictionary binders = new ModelBinderDictionary() {
+                { typeof(HttpPostedFileBase), new HttpPostedFileBaseModelBinder() },
+                { typeof(byte[]), new ByteArrayModelBinder() },
+                { typeof(Binary), new LinqBinaryModelBinder() }
+            };
+            return binders;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelBindingContext.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelBindingContext.cs
new file mode 100644 (file)
index 0000000..1c75181
--- /dev/null
@@ -0,0 +1,141 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq;
+    using System.Web.Mvc.Resources;
+
+    public class ModelBindingContext {
+
+        private static readonly Predicate<string> _defaultPropertyFilter = _ => true;
+
+        private string _modelName;
+        private ModelStateDictionary _modelState;
+        private Predicate<string> _propertyFilter;
+        private Dictionary<string, ModelMetadata> _propertyMetadata;
+
+        public ModelBindingContext()
+            : this(null) {
+        }
+
+        // copies certain values that won't change between parent and child objects,
+        // e.g. ValueProvider, ModelState
+        public ModelBindingContext(ModelBindingContext bindingContext) {
+            if (bindingContext != null) {
+                ModelState = bindingContext.ModelState;
+                ValueProvider = bindingContext.ValueProvider;
+            }
+        }
+
+        public bool FallbackToEmptyPrefix {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "value", Justification = "Cannot remove setter as that's a breaking change")]
+        public object Model {
+            get {
+                return ModelMetadata.Model;
+            }
+            set {
+                throw new InvalidOperationException(MvcResources.ModelMetadata_PropertyNotSettable);
+            }
+        }
+
+        public ModelMetadata ModelMetadata {
+            get;
+            set;
+        }
+
+        public string ModelName {
+            get {
+                if (_modelName == null) {
+                    _modelName = String.Empty;
+                }
+                return _modelName;
+            }
+            set {
+                _modelName = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "The containing type is mutable.")]
+        public ModelStateDictionary ModelState {
+            get {
+                if (_modelState == null) {
+                    _modelState = new ModelStateDictionary();
+                }
+                return _modelState;
+            }
+            set {
+                _modelState = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "value", Justification = "Cannot remove setter as that's a breaking change")]
+        public Type ModelType {
+            get {
+                return ModelMetadata.ModelType;
+            }
+            set {
+                throw new InvalidOperationException(MvcResources.ModelMetadata_PropertyNotSettable);
+            }
+        }
+
+        public Predicate<string> PropertyFilter {
+            get {
+                if (_propertyFilter == null) {
+                    _propertyFilter = _defaultPropertyFilter;
+                }
+                return _propertyFilter;
+            }
+            set {
+                _propertyFilter = value;
+            }
+        }
+
+        public IDictionary<string, ModelMetadata> PropertyMetadata {
+            get {
+                if (_propertyMetadata == null) {
+                    _propertyMetadata = ModelMetadata.Properties.ToDictionary(m => m.PropertyName, StringComparer.OrdinalIgnoreCase);
+                }
+
+                return _propertyMetadata;
+            }
+        }
+
+        public IValueProvider ValueProvider {
+            get;
+            set;
+        }
+
+        internal IUnvalidatedValueProvider UnvalidatedValueProvider {
+            get {
+                return (ValueProvider as IUnvalidatedValueProvider) ?? new UnvalidatedValueProviderWrapper(ValueProvider);
+            }
+        }
+
+        // Used to wrap an IValueProvider in an IUnvalidatedValueProvider
+        private sealed class UnvalidatedValueProviderWrapper : IValueProvider, IUnvalidatedValueProvider {
+            private readonly IValueProvider _backingProvider;
+
+            public UnvalidatedValueProviderWrapper(IValueProvider backingProvider) {
+                _backingProvider = backingProvider;
+            }
+
+            public ValueProviderResult GetValue(string key, bool skipValidation) {
+                // 'skipValidation' isn't understood by the backing provider and can be ignored
+                return GetValue(key);
+            }
+
+            public bool ContainsPrefix(string prefix) {
+                return _backingProvider.ContainsPrefix(prefix);
+            }
+
+            public ValueProviderResult GetValue(string key) {
+                return _backingProvider.GetValue(key);
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationEqualToRule.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationEqualToRule.cs
new file mode 100644 (file)
index 0000000..5dc365c
--- /dev/null
@@ -0,0 +1,9 @@
+namespace System.Web.Mvc {
+    public class ModelClientValidationEqualToRule: ModelClientValidationRule {
+        public ModelClientValidationEqualToRule(string errorMessage, object other){
+            ErrorMessage = errorMessage;
+            ValidationType = "equalto";
+            ValidationParameters["other"] = other;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRangeRule.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRangeRule.cs
new file mode 100644 (file)
index 0000000..647e21f
--- /dev/null
@@ -0,0 +1,10 @@
+namespace System.Web.Mvc {
+    public class ModelClientValidationRangeRule : ModelClientValidationRule {
+        public ModelClientValidationRangeRule(string errorMessage, object minValue, object maxValue) {
+            ErrorMessage = errorMessage;
+            ValidationType = "range";
+            ValidationParameters["min"] = minValue;
+            ValidationParameters["max"] = maxValue;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRegexRule.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRegexRule.cs
new file mode 100644 (file)
index 0000000..8efbfe1
--- /dev/null
@@ -0,0 +1,9 @@
+namespace System.Web.Mvc {
+    public class ModelClientValidationRegexRule : ModelClientValidationRule {
+        public ModelClientValidationRegexRule(string errorMessage, string pattern) {
+            ErrorMessage = errorMessage;
+            ValidationType = "regex";
+            ValidationParameters.Add("pattern", pattern);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRemoteRule.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRemoteRule.cs
new file mode 100644 (file)
index 0000000..e292e62
--- /dev/null
@@ -0,0 +1,19 @@
+namespace System.Web.Mvc {
+    using System.Diagnostics.CodeAnalysis;
+
+    public class ModelClientValidationRemoteRule : ModelClientValidationRule {
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", Justification = "The value is a not a regular URL since it may contain ~/ ASP.NET-specific characters")]
+        public ModelClientValidationRemoteRule(string errorMessage, string url, string httpMethod, string additionalFields) {
+            ErrorMessage = errorMessage;
+            ValidationType = "remote";
+            ValidationParameters["url"] = url;
+
+            if (!string.IsNullOrEmpty(httpMethod)) {
+                ValidationParameters["type"] = httpMethod;
+            }
+
+            ValidationParameters["additionalfields"] = additionalFields;
+        }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRequiredRule.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRequiredRule.cs
new file mode 100644 (file)
index 0000000..0df7ea0
--- /dev/null
@@ -0,0 +1,8 @@
+namespace System.Web.Mvc {
+    public class ModelClientValidationRequiredRule : ModelClientValidationRule {
+        public ModelClientValidationRequiredRule(string errorMessage) {
+            ErrorMessage = errorMessage;
+            ValidationType = "required";
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRule.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationRule.cs
new file mode 100644 (file)
index 0000000..a3dfbd4
--- /dev/null
@@ -0,0 +1,31 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+
+    public class ModelClientValidationRule {
+
+        private readonly Dictionary<string, object> _validationParameters = new Dictionary<string, object>();
+        private string _validationType;
+
+        public string ErrorMessage {
+            get;
+            set;
+        }
+
+        public IDictionary<string, object> ValidationParameters {
+            get {
+                return _validationParameters;
+            }
+        }
+
+        public string ValidationType {
+            get {
+                return _validationType ?? String.Empty;
+            }
+            set {
+                _validationType = value;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationStringLengthRule.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelClientValidationStringLengthRule.cs
new file mode 100644 (file)
index 0000000..d521fc8
--- /dev/null
@@ -0,0 +1,16 @@
+namespace System.Web.Mvc {
+    public class ModelClientValidationStringLengthRule : ModelClientValidationRule {
+        public ModelClientValidationStringLengthRule(string errorMessage, int minimumLength, int maximumLength) {
+            ErrorMessage = errorMessage;
+            ValidationType = "length";
+
+            if (minimumLength != 0) {
+                ValidationParameters["min"] = minimumLength;
+            }
+
+            if (maximumLength != Int32.MaxValue) {
+                ValidationParameters["max"] = maximumLength;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelError.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelError.cs
new file mode 100644 (file)
index 0000000..c5f7666
--- /dev/null
@@ -0,0 +1,34 @@
+namespace System.Web.Mvc {
+    using System;
+
+    [Serializable]
+    public class ModelError {
+
+        public ModelError(Exception exception)
+            : this(exception, null /* errorMessage */) {
+        }
+
+        public ModelError(Exception exception, string errorMessage)
+            : this(errorMessage) {
+            if (exception == null) {
+                throw new ArgumentNullException("exception");
+            }
+
+            Exception = exception;
+        }
+
+        public ModelError(string errorMessage) {
+            ErrorMessage = errorMessage ?? String.Empty;
+        }
+
+        public Exception Exception {
+            get;
+            private set;
+        }
+
+        public string ErrorMessage {
+            get;
+            private set;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelErrorCollection.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelErrorCollection.cs
new file mode 100644 (file)
index 0000000..e431a09
--- /dev/null
@@ -0,0 +1,16 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.ObjectModel;
+
+    [Serializable]
+    public class ModelErrorCollection : Collection<ModelError> {
+
+        public void Add(Exception exception) {
+            Add(new ModelError(exception));
+        }
+
+        public void Add(string errorMessage) {
+            Add(new ModelError(errorMessage));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelMetadata.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelMetadata.cs
new file mode 100644 (file)
index 0000000..5faa387
--- /dev/null
@@ -0,0 +1,401 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq;
+    using System.Linq.Expressions;
+    using System.Reflection;
+    using System.Web.Mvc.ExpressionUtil;
+    using System.Web.Mvc.Resources;
+
+    public class ModelMetadata {
+        public const int DefaultOrder = 10000;
+
+        // Explicit backing store for the things we want initialized by default, so don't have to call
+        // the protected virtual setters of an auto-generated property
+        private Dictionary<string, object> _additionalValues = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
+        private readonly Type _containerType;
+        private bool _convertEmptyStringToNull = true;
+        private bool _isRequired;
+        private object _model;
+        private Func<object> _modelAccessor;
+        private readonly Type _modelType;
+        private int _order = DefaultOrder;
+        private IEnumerable<ModelMetadata> _properties;
+        private readonly string _propertyName;
+        private Type _realModelType;
+        private bool _requestValidationEnabled = true;
+        private bool _showForDisplay = true;
+        private bool _showForEdit = true;
+        private string _simpleDisplayText;
+
+        public ModelMetadata(ModelMetadataProvider provider, Type containerType, Func<object> modelAccessor, Type modelType, string propertyName) {
+            if (provider == null) {
+                throw new ArgumentNullException("provider");
+            }
+            if (modelType == null) {
+                throw new ArgumentNullException("modelType");
+            }
+
+            Provider = provider;
+
+            _containerType = containerType;
+            _isRequired = !TypeHelpers.TypeAllowsNullValue(modelType);
+            _modelAccessor = modelAccessor;
+            _modelType = modelType;
+            _propertyName = propertyName;
+        }
+
+        public virtual Dictionary<string, object> AdditionalValues {
+            get {
+                return _additionalValues;
+            }
+        }
+
+        public Type ContainerType {
+            get {
+                return _containerType;
+            }
+        }
+
+        public virtual bool ConvertEmptyStringToNull {
+            get {
+                return _convertEmptyStringToNull;
+            }
+            set {
+                _convertEmptyStringToNull = value;
+            }
+        }
+
+        public virtual string DataTypeName {
+            get;
+            set;
+        }
+
+        public virtual string Description {
+            get;
+            set;
+        }
+
+        public virtual string DisplayFormatString {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1721:PropertyNamesShouldNotMatchGetMethods", Justification = "The method is a delegating helper to choose among multiple property values")]
+        public virtual string DisplayName {
+            get;
+            set;
+        }
+
+        public virtual string EditFormatString {
+            get;
+            set;
+        }
+
+        public virtual bool HideSurroundingHtml {
+            get;
+            set;
+        }
+
+        public virtual bool IsComplexType {
+            get {
+                return !(TypeDescriptor.GetConverter(ModelType).CanConvertFrom(typeof(string)));
+            }
+        }
+
+        public bool IsNullableValueType {
+            get {
+                return TypeHelpers.IsNullableValueType(ModelType);
+            }
+        }
+
+        public virtual bool IsReadOnly {
+            get;
+            set;
+        }
+
+        public virtual bool IsRequired {
+            get {
+                return _isRequired;
+            }
+            set {
+                _isRequired = value;
+            }
+        }
+
+        public object Model {
+            get {
+                if (_modelAccessor != null) {
+                    _model = _modelAccessor();
+                    _modelAccessor = null;
+                }
+                return _model;
+            }
+            set {
+                _model = value;
+                _modelAccessor = null;
+                _properties = null;
+                _realModelType = null;
+            }
+        }
+
+        public Type ModelType {
+            get {
+                return _modelType;
+            }
+        }
+
+        public virtual string NullDisplayText {
+            get;
+            set;
+        }
+
+        public virtual int Order {
+            get {
+                return _order;
+            }
+            set {
+                _order = value;
+            }
+        }
+
+        public virtual IEnumerable<ModelMetadata> Properties {
+            get {
+                if (_properties == null) {
+                    _properties = Provider.GetMetadataForProperties(Model, RealModelType).OrderBy(m => m.Order);
+                }
+                return _properties;
+            }
+        }
+
+        public string PropertyName {
+            get {
+                return _propertyName;
+            }
+        }
+
+        protected ModelMetadataProvider Provider {
+            get;
+            set;
+        }
+
+        internal Type RealModelType {
+            get {
+                if (_realModelType == null) {
+                    _realModelType = ModelType;
+
+                    // Don't call GetType() if the model is Nullable<T>, because it will
+                    // turn Nullable<T> into T for non-null values
+                    if (Model != null && !TypeHelpers.IsNullableValueType(ModelType)) {
+                        _realModelType = Model.GetType();
+                    }
+                }
+
+                return _realModelType;
+            }
+        }
+
+        public virtual bool RequestValidationEnabled {
+            get {
+                return _requestValidationEnabled;
+            }
+            set {
+                _requestValidationEnabled = value;
+            }
+        }
+
+        public virtual string ShortDisplayName {
+            get;
+            set;
+        }
+
+        public virtual bool ShowForDisplay {
+            get {
+                return _showForDisplay;
+            }
+            set {
+                _showForDisplay = value;
+            }
+        }
+
+        public virtual bool ShowForEdit {
+            get {
+                return _showForEdit;
+            }
+            set {
+                _showForEdit = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1721:PropertyNamesShouldNotMatchGetMethods", Justification = "This property delegates to the method when the user has not yet set a simple display text value.")]
+        public virtual string SimpleDisplayText {
+            get {
+                if (_simpleDisplayText == null) {
+                    _simpleDisplayText = GetSimpleDisplayText();
+                }
+                return _simpleDisplayText;
+            }
+            set {
+                _simpleDisplayText = value;
+            }
+        }
+
+        public virtual string TemplateHint {
+            get;
+            set;
+        }
+
+        public virtual string Watermark {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures", Justification = "This is an appropriate nesting of generic types")]
+        public static ModelMetadata FromLambdaExpression<TParameter, TValue>(Expression<Func<TParameter, TValue>> expression,
+                                                                             ViewDataDictionary<TParameter> viewData) {
+            if (expression == null) {
+                throw new ArgumentNullException("expression");
+            }
+            if (viewData == null) {
+                throw new ArgumentNullException("viewData");
+            }
+
+            string propertyName = null;
+            Type containerType = null;
+            bool legalExpression = false;
+
+            // Need to verify the expression is valid; it needs to at least end in something
+            // that we can convert to a meaningful string for model binding purposes
+
+            switch (expression.Body.NodeType) {
+                // ArrayIndex always means a single-dimensional indexer; multi-dimensional indexer is a method call to Get()
+                case ExpressionType.ArrayIndex:
+                    legalExpression = true;
+                    break;
+
+                // Only legal method call is a single argument indexer/DefaultMember call
+                case ExpressionType.Call:
+                    legalExpression = ExpressionHelper.IsSingleArgumentIndexer(expression.Body);
+                    break;
+
+                // Property/field access is always legal
+                case ExpressionType.MemberAccess:
+                    MemberExpression memberExpression = (MemberExpression)expression.Body;
+                    propertyName = memberExpression.Member is PropertyInfo ? memberExpression.Member.Name : null;
+                    containerType = memberExpression.Expression.Type;
+                    legalExpression = true;
+                    break;
+
+                // Parameter expression means "model => model", so we delegate to FromModel
+                case ExpressionType.Parameter:
+                    return FromModel(viewData);
+            }
+
+            if (!legalExpression) {
+                throw new InvalidOperationException(MvcResources.TemplateHelpers_TemplateLimitations);
+            }
+
+            TParameter container = viewData.Model;
+            Func<object> modelAccessor = () => {
+                try {
+                    return CachedExpressionCompiler.Process(expression)(container);
+                }
+                catch (NullReferenceException) {
+                    return null;
+                }
+            };
+
+            return GetMetadataFromProvider(modelAccessor, typeof(TValue), propertyName, containerType);
+        }
+
+        private static ModelMetadata FromModel(ViewDataDictionary viewData) {
+            return viewData.ModelMetadata ?? GetMetadataFromProvider(null, typeof(string), null, null);
+        }
+
+        public static ModelMetadata FromStringExpression(string expression, ViewDataDictionary viewData) {
+            if (expression == null) {
+                throw new ArgumentNullException("expression");
+            }
+            if (viewData == null) {
+                throw new ArgumentNullException("viewData");
+            }
+            if (expression.Length == 0) {    // Empty string really means "model metadata for the current model"
+                return FromModel(viewData);
+            }
+
+            ViewDataInfo vdi = viewData.GetViewDataInfo(expression);
+            Type containerType = null;
+            Type modelType = null;
+            Func<object> modelAccessor = null;
+            string propertyName = null;
+
+            if (vdi != null) {
+                if (vdi.Container != null) {
+                    containerType = vdi.Container.GetType();
+                }
+
+                modelAccessor = () => vdi.Value;
+
+                if (vdi.PropertyDescriptor != null) {
+                    propertyName = vdi.PropertyDescriptor.Name;
+                    modelType = vdi.PropertyDescriptor.PropertyType;
+                }
+                else if (vdi.Value != null) {  // We only need to delay accessing properties (for LINQ to SQL)
+                    modelType = vdi.Value.GetType();
+                }
+            }
+            //  Try getting a property from ModelMetadata if we couldn't find an answer in ViewData
+            else if (viewData.ModelMetadata != null) {
+                ModelMetadata propertyMetadata = viewData.ModelMetadata.Properties.Where(p => p.PropertyName == expression).FirstOrDefault();
+                if (propertyMetadata != null) {
+                    return propertyMetadata;
+                }
+            }
+
+
+            return GetMetadataFromProvider(modelAccessor, modelType ?? typeof(string), propertyName, containerType);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate", Justification = "The method is a delegating helper to choose among multiple property values")]
+        public string GetDisplayName() {
+            return DisplayName ?? PropertyName ?? ModelType.Name;
+        }
+
+        private static ModelMetadata GetMetadataFromProvider(Func<object> modelAccessor, Type modelType, string propertyName, Type containerType) {
+            if (containerType != null && !String.IsNullOrEmpty(propertyName)) {
+                return ModelMetadataProviders.Current.GetMetadataForProperty(modelAccessor, containerType, propertyName);
+            }
+            return ModelMetadataProviders.Current.GetMetadataForType(modelAccessor, modelType);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate", Justification = "This method is used to resolve the simple display text when it was not explicitly set through other means.")]
+        protected virtual string GetSimpleDisplayText() {
+            if (Model == null) {
+                return NullDisplayText;
+            }
+
+            string toStringResult = Convert.ToString(Model, CultureInfo.CurrentCulture);
+            if (!toStringResult.Equals(Model.GetType().FullName, StringComparison.Ordinal)) {
+                return toStringResult;
+            }
+
+            ModelMetadata firstProperty = Properties.FirstOrDefault();
+            if (firstProperty == null) {
+                return String.Empty;
+            }
+
+            if (firstProperty.Model == null) {
+                return firstProperty.NullDisplayText;
+            }
+
+            return Convert.ToString(firstProperty.Model, CultureInfo.CurrentCulture);
+        }
+
+        public virtual IEnumerable<ModelValidator> GetValidators(ControllerContext context) {
+            return ModelValidatorProviders.Providers.GetValidators(this, context);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelMetadataProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelMetadataProvider.cs
new file mode 100644 (file)
index 0000000..6e2cfb1
--- /dev/null
@@ -0,0 +1,11 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+
+    public abstract class ModelMetadataProvider {
+        public abstract IEnumerable<ModelMetadata> GetMetadataForProperties(object container, Type containerType);
+
+        public abstract ModelMetadata GetMetadataForProperty(Func<object> modelAccessor, Type containerType, string propertyName);
+
+        public abstract ModelMetadata GetMetadataForType(Func<object> modelAccessor, Type modelType);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelMetadataProviders.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelMetadataProviders.cs
new file mode 100644 (file)
index 0000000..5d0df02
--- /dev/null
@@ -0,0 +1,33 @@
+namespace System.Web.Mvc {
+    public class ModelMetadataProviders {
+        private ModelMetadataProvider _currentProvider;
+        private static ModelMetadataProviders _instance = new ModelMetadataProviders();
+        private IResolver<ModelMetadataProvider> _resolver;
+
+        internal ModelMetadataProviders(IResolver<ModelMetadataProvider> resolver = null) {
+            _resolver = resolver ?? new SingleServiceResolver<ModelMetadataProvider>(
+                () => _currentProvider,
+                new DataAnnotationsModelMetadataProvider(),
+                "ModelMetadataProviders.Current"
+            );
+        }
+
+        public static ModelMetadataProvider Current {
+            get {
+                return _instance.CurrentInternal;
+            }
+            set {
+                _instance.CurrentInternal = value;
+            }
+        }
+
+        internal ModelMetadataProvider CurrentInternal {
+            get {
+                return _resolver.Current;
+            }
+            set {
+                _currentProvider = value ?? new EmptyModelMetadataProvider();
+            }
+        }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelState.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelState.cs
new file mode 100644 (file)
index 0000000..6c4c234
--- /dev/null
@@ -0,0 +1,19 @@
+namespace System.Web.Mvc {
+
+    [Serializable]
+    public class ModelState {
+
+        private ModelErrorCollection _errors = new ModelErrorCollection();
+
+        public ValueProviderResult Value {
+            get;
+            set;
+        }
+
+        public ModelErrorCollection Errors {
+            get {
+                return _errors;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelStateDictionary.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelStateDictionary.cs
new file mode 100644 (file)
index 0000000..8a0a2ca
--- /dev/null
@@ -0,0 +1,158 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Linq;
+
+    [Serializable]
+    public class ModelStateDictionary : IDictionary<string, ModelState> {
+
+        private readonly Dictionary<string, ModelState> _innerDictionary = new Dictionary<string, ModelState>(StringComparer.OrdinalIgnoreCase);
+
+        public ModelStateDictionary() {
+        }
+
+        public ModelStateDictionary(ModelStateDictionary dictionary) {
+            if (dictionary == null) {
+                throw new ArgumentNullException("dictionary");
+            }
+
+            foreach (var entry in dictionary) {
+                _innerDictionary.Add(entry.Key, entry.Value);
+            }
+        }
+
+        public int Count {
+            get {
+                return _innerDictionary.Count;
+            }
+        }
+
+        public bool IsReadOnly {
+            get {
+                return ((IDictionary<string, ModelState>)_innerDictionary).IsReadOnly;
+            }
+        }
+
+        public bool IsValid {
+            get {
+                return Values.All(modelState => modelState.Errors.Count == 0);
+            }
+        }
+
+        public ICollection<string> Keys {
+            get {
+                return _innerDictionary.Keys;
+            }
+        }
+
+        public ModelState this[string key] {
+            get {
+                ModelState value;
+                _innerDictionary.TryGetValue(key, out value);
+                return value;
+            }
+            set {
+                _innerDictionary[key] = value;
+            }
+        }
+
+        public ICollection<ModelState> Values {
+            get {
+                return _innerDictionary.Values;
+            }
+        }
+
+        public void Add(KeyValuePair<string, ModelState> item) {
+            ((IDictionary<string, ModelState>)_innerDictionary).Add(item);
+        }
+
+        public void Add(string key, ModelState value) {
+            _innerDictionary.Add(key, value);
+        }
+
+        public void AddModelError(string key, Exception exception) {
+            GetModelStateForKey(key).Errors.Add(exception);
+        }
+
+        public void AddModelError(string key, string errorMessage) {
+            GetModelStateForKey(key).Errors.Add(errorMessage);
+        }
+
+        public void Clear() {
+            _innerDictionary.Clear();
+        }
+
+        public bool Contains(KeyValuePair<string, ModelState> item) {
+            return ((IDictionary<string, ModelState>)_innerDictionary).Contains(item);
+        }
+
+        public bool ContainsKey(string key) {
+            return _innerDictionary.ContainsKey(key);
+        }
+
+        public void CopyTo(KeyValuePair<string, ModelState>[] array, int arrayIndex) {
+            ((IDictionary<string, ModelState>)_innerDictionary).CopyTo(array, arrayIndex);
+        }
+
+        public IEnumerator<KeyValuePair<string, ModelState>> GetEnumerator() {
+            return _innerDictionary.GetEnumerator();
+        }
+
+        private ModelState GetModelStateForKey(string key) {
+            if (key == null) {
+                throw new ArgumentNullException("key");
+            }
+
+            ModelState modelState;
+            if (!TryGetValue(key, out modelState)) {
+                modelState = new ModelState();
+                this[key] = modelState;
+            }
+
+            return modelState;
+        }
+
+        public bool IsValidField(string key) {
+            if (key == null) {
+                throw new ArgumentNullException("key");
+            }
+
+            // if the key is not found in the dictionary, we just say that it's valid (since there are no errors)
+            return DictionaryHelpers.FindKeysWithPrefix(this, key).All(entry => entry.Value.Errors.Count == 0);
+        }
+
+        public void Merge(ModelStateDictionary dictionary) {
+            if (dictionary == null) {
+                return;
+            }
+
+            foreach (var entry in dictionary) {
+                this[entry.Key] = entry.Value;
+            }
+        }
+
+        public bool Remove(KeyValuePair<string, ModelState> item) {
+            return ((IDictionary<string, ModelState>)_innerDictionary).Remove(item);
+        }
+
+        public bool Remove(string key) {
+            return _innerDictionary.Remove(key);
+        }
+
+        public void SetModelValue(string key, ValueProviderResult value) {
+            GetModelStateForKey(key).Value = value;
+        }
+
+        public bool TryGetValue(string key, out ModelState value) {
+            return _innerDictionary.TryGetValue(key, out value);
+        }
+
+        #region IEnumerable Members
+        IEnumerator IEnumerable.GetEnumerator() {
+            return ((IEnumerable)_innerDictionary).GetEnumerator();
+        }
+        #endregion
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelValidationResult.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelValidationResult.cs
new file mode 100644 (file)
index 0000000..255acc0
--- /dev/null
@@ -0,0 +1,28 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public class ModelValidationResult {
+
+        private string _memberName;
+        private string _message;
+
+        public string MemberName {
+            get {
+                return _memberName ?? String.Empty;
+            }
+            set {
+                _memberName = value;
+            }
+        }
+
+        public string Message {
+            get {
+                return _message ?? String.Empty;
+            }
+            set {
+                _message = value;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelValidator.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelValidator.cs
new file mode 100644 (file)
index 0000000..9ced7cd
--- /dev/null
@@ -0,0 +1,71 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq;
+
+    public abstract class ModelValidator {
+        protected ModelValidator(ModelMetadata metadata, ControllerContext controllerContext) {
+            if (metadata == null) {
+                throw new ArgumentNullException("metadata");
+            }
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            Metadata = metadata;
+            ControllerContext = controllerContext;
+        }
+
+        protected internal ControllerContext ControllerContext { get; private set; }
+
+        public virtual bool IsRequired {
+            get {
+                return false;
+            }
+        }
+
+        protected internal ModelMetadata Metadata { get; private set; }
+
+        [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate", Justification = "This method may perform non-trivial work.")]
+        public virtual IEnumerable<ModelClientValidationRule> GetClientValidationRules() {
+            return Enumerable.Empty<ModelClientValidationRule>();
+        }
+
+        public static ModelValidator GetModelValidator(ModelMetadata metadata, ControllerContext context) {
+            return new CompositeModelValidator(metadata, context);
+        }
+
+        public abstract IEnumerable<ModelValidationResult> Validate(object container);
+
+        private class CompositeModelValidator : ModelValidator {
+            public CompositeModelValidator(ModelMetadata metadata, ControllerContext controllerContext)
+                : base(metadata, controllerContext) {
+            }
+
+            public override IEnumerable<ModelValidationResult> Validate(object container) {
+                bool propertiesValid = true;
+
+                foreach (ModelMetadata propertyMetadata in Metadata.Properties) {
+                    foreach (ModelValidator propertyValidator in propertyMetadata.GetValidators(ControllerContext)) {
+                        foreach (ModelValidationResult propertyResult in propertyValidator.Validate(Metadata.Model)) {
+                            propertiesValid = false;
+                            yield return new ModelValidationResult {
+                                MemberName = DefaultModelBinder.CreateSubPropertyName(propertyMetadata.PropertyName, propertyResult.MemberName),
+                                Message = propertyResult.Message
+                            };
+                        }
+                    }
+                }
+
+                if (propertiesValid) {
+                    foreach (ModelValidator typeValidator in Metadata.GetValidators(ControllerContext)) {
+                        foreach (ModelValidationResult typeResult in typeValidator.Validate(container)) {
+                            yield return typeResult;
+                        }
+                    }
+                }
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelValidatorProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelValidatorProvider.cs
new file mode 100644 (file)
index 0000000..452de72
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+
+    public abstract class ModelValidatorProvider {
+        public abstract IEnumerable<ModelValidator> GetValidators(ModelMetadata metadata, ControllerContext context);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelValidatorProviderCollection.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelValidatorProviderCollection.cs
new file mode 100644 (file)
index 0000000..ea016f9
--- /dev/null
@@ -0,0 +1,51 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+    using System.Linq;
+
+    public class ModelValidatorProviderCollection : Collection<ModelValidatorProvider> {
+        private IResolver<IEnumerable<ModelValidatorProvider>> _serviceResolver;
+
+        public ModelValidatorProviderCollection() {
+            _serviceResolver = new MultiServiceResolver<ModelValidatorProvider>(() => Items);
+        }
+
+        public ModelValidatorProviderCollection(IList<ModelValidatorProvider> list)
+            : base(list) {
+            _serviceResolver = new MultiServiceResolver<ModelValidatorProvider>(() => Items);
+        }
+
+        internal ModelValidatorProviderCollection(IResolver<IEnumerable<ModelValidatorProvider>> serviceResolver, params ModelValidatorProvider[] validatorProvidors)
+            : base(validatorProvidors) {
+            _serviceResolver = serviceResolver ??  new MultiServiceResolver<ModelValidatorProvider>(
+                ()=>Items
+                );
+        }
+
+        private IEnumerable<ModelValidatorProvider> CombinedItems {
+            get {
+                return _serviceResolver.Current;
+            }
+        }
+
+        protected override void InsertItem(int index, ModelValidatorProvider item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.InsertItem(index, item);
+        }
+
+        protected override void SetItem(int index, ModelValidatorProvider item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.SetItem(index, item);
+        }
+
+        public IEnumerable<ModelValidator> GetValidators(ModelMetadata metadata, ControllerContext context) {
+            return CombinedItems.SelectMany(provider => provider.GetValidators(metadata, context));
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ModelValidatorProviders.cs b/mcs/class/System.Web.Mvc3/Mvc/ModelValidatorProviders.cs
new file mode 100644 (file)
index 0000000..e973af9
--- /dev/null
@@ -0,0 +1,17 @@
+namespace System.Web.Mvc {
+    public static class ModelValidatorProviders {
+
+        private static readonly ModelValidatorProviderCollection _providers = new ModelValidatorProviderCollection() {
+            new DataAnnotationsModelValidatorProvider(),
+            new DataErrorInfoModelValidatorProvider(),
+            new ClientDataTypeModelValidatorProvider()
+        };
+
+        public static ModelValidatorProviderCollection Providers {
+            get {
+                return _providers;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/MultiSelectList.cs b/mcs/class/System.Web.Mvc3/Mvc/MultiSelectList.cs
new file mode 100644 (file)
index 0000000..5ea1a1f
--- /dev/null
@@ -0,0 +1,111 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq;
+    using System.Web.UI;
+
+    [SuppressMessage("Microsoft.Naming", "CA1710:IdentifiersShouldHaveCorrectSuffix")]
+    [SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Multi", Justification = "Common shorthand for 'multiple'.")]
+    public class MultiSelectList : IEnumerable<SelectListItem> {
+
+        public MultiSelectList(IEnumerable items)
+            : this(items, null /* selectedValues */) {
+        }
+
+        public MultiSelectList(IEnumerable items, IEnumerable selectedValues)
+            : this(items, null /* dataValuefield */, null /* dataTextField */, selectedValues) {
+        }
+
+        public MultiSelectList(IEnumerable items, string dataValueField, string dataTextField)
+            : this(items, dataValueField, dataTextField, null /* selectedValues */) {
+        }
+
+        public MultiSelectList(IEnumerable items, string dataValueField, string dataTextField, IEnumerable selectedValues) {
+            if (items == null) {
+                throw new ArgumentNullException("items");
+            }
+
+            Items = items;
+            DataValueField = dataValueField;
+            DataTextField = dataTextField;
+            SelectedValues = selectedValues;
+        }
+
+        public string DataTextField {
+            get;
+            private set;
+        }
+
+        public string DataValueField {
+            get;
+            private set;
+        }
+
+        public IEnumerable Items {
+            get;
+            private set;
+        }
+
+        public IEnumerable SelectedValues {
+            get;
+            private set;
+        }
+
+        public virtual IEnumerator<SelectListItem> GetEnumerator() {
+            return GetListItems().GetEnumerator();
+        }
+
+        internal IList<SelectListItem> GetListItems() {
+            return (!String.IsNullOrEmpty(DataValueField)) ?
+                GetListItemsWithValueField() :
+                GetListItemsWithoutValueField();
+        }
+
+        private IList<SelectListItem> GetListItemsWithValueField() {
+            HashSet<string> selectedValues = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
+            if (SelectedValues != null) {
+                selectedValues.UnionWith(from object value in SelectedValues select Convert.ToString(value, CultureInfo.CurrentCulture));
+            }
+
+            var listItems = from object item in Items
+                            let value = Eval(item, DataValueField)
+                            select new SelectListItem {
+                                Value = value,
+                                Text = Eval(item, DataTextField),
+                                Selected = selectedValues.Contains(value)
+                            };
+            return listItems.ToList();
+        }
+
+        private IList<SelectListItem> GetListItemsWithoutValueField() {
+            HashSet<object> selectedValues = new HashSet<object>();
+            if (SelectedValues != null) {
+                selectedValues.UnionWith(SelectedValues.Cast<object>());
+            }
+
+            var listItems = from object item in Items
+                            select new SelectListItem {
+                                Text = Eval(item, DataTextField),
+                                Selected = selectedValues.Contains(item)
+                            };
+            return listItems.ToList();
+        }
+
+        private static string Eval(object container, string expression) {
+            object value = container;
+            if (!String.IsNullOrEmpty(expression)) {
+                value = DataBinder.Eval(container, expression);
+            }
+            return Convert.ToString(value, CultureInfo.CurrentCulture);
+        }
+
+        #region IEnumerable Members
+        IEnumerator IEnumerable.GetEnumerator() {
+            return GetEnumerator();
+        }
+        #endregion
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/MultiServiceResolver.cs b/mcs/class/System.Web.Mvc3/Mvc/MultiServiceResolver.cs
new file mode 100644 (file)
index 0000000..5a56a1f
--- /dev/null
@@ -0,0 +1,41 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq;
+
+    internal class MultiServiceResolver<TService> : IResolver<IEnumerable<TService>> where TService : class {
+        private IEnumerable<TService> _itemsFromService;
+        private Func<IEnumerable<TService>> _itemsThunk;
+        private Func<IDependencyResolver> _resolverThunk;
+
+        public MultiServiceResolver(Func<IEnumerable<TService>> itemsThunk) {
+            if (itemsThunk == null) {
+                throw new ArgumentNullException("itemsThunk");
+            }
+
+            _itemsThunk = itemsThunk;
+            _resolverThunk = () => DependencyResolver.Current;
+        }
+
+        internal MultiServiceResolver(Func<IEnumerable<TService>> itemsThunk, IDependencyResolver resolver)
+            : this(itemsThunk) {
+            if (resolver != null) {
+                _resolverThunk = () => resolver;
+            }
+        }
+
+        public IEnumerable<TService> Current {
+            get {
+                if (_itemsFromService == null) {
+                    lock (_itemsThunk) {
+                        if (_itemsFromService == null) {
+                            _itemsFromService = _resolverThunk().GetServices<TService>();
+                        }
+                    }
+                }
+                return _itemsFromService.Concat(_itemsThunk());
+            }
+        }
+    }
+}
+
diff --git a/mcs/class/System.Web.Mvc3/Mvc/MvcFilter.cs b/mcs/class/System.Web.Mvc3/Mvc/MvcFilter.cs
new file mode 100644 (file)
index 0000000..b7fa042
--- /dev/null
@@ -0,0 +1,21 @@
+namespace System.Web.Mvc {
+    public abstract class MvcFilter : IMvcFilter {
+        protected MvcFilter() {
+        }
+
+        protected MvcFilter(bool allowMultiple, int order) {
+            AllowMultiple = allowMultiple;
+            Order = order;
+        }
+
+        public bool AllowMultiple {
+            get;
+            private set;
+        }
+
+        public int Order {
+            get;
+            private set;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/MvcHandler.cs b/mcs/class/System.Web.Mvc3/Mvc/MvcHandler.cs
new file mode 100644 (file)
index 0000000..cefac02
--- /dev/null
@@ -0,0 +1,212 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Globalization;
+    using System.Linq;
+    using System.Reflection;
+    using System.Threading;
+    using System.Web;
+    using System.Web.Mvc.Async;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+    using System.Web.SessionState;
+    using Microsoft.Web.Infrastructure.DynamicValidationHelper;
+
+    public class MvcHandler : IHttpAsyncHandler, IHttpHandler, IRequiresSessionState {
+        private static readonly object _processRequestTag = new object();
+        private ControllerBuilder _controllerBuilder;
+
+        internal static readonly string MvcVersion = GetMvcVersionString();
+        public static readonly string MvcVersionHeaderName = "X-AspNetMvc-Version";
+
+        public MvcHandler(RequestContext requestContext) {
+            if (requestContext == null) {
+                throw new ArgumentNullException("requestContext");
+            }
+
+            RequestContext = requestContext;
+        }
+
+        internal ControllerBuilder ControllerBuilder {
+            get {
+                if (_controllerBuilder == null) {
+                    _controllerBuilder = ControllerBuilder.Current;
+                }
+                return _controllerBuilder;
+            }
+            set {
+                _controllerBuilder = value;
+            }
+        }
+
+        public static bool DisableMvcResponseHeader {
+            get;
+            set;
+        }
+
+        protected virtual bool IsReusable {
+            get {
+                return false;
+            }
+        }
+
+        public RequestContext RequestContext {
+            get;
+            private set;
+        }
+
+        protected internal virtual void AddVersionHeader(HttpContextBase httpContext) {
+            if (!DisableMvcResponseHeader) {
+                httpContext.Response.AppendHeader(MvcVersionHeaderName, MvcVersion);
+            }
+        }
+
+        protected virtual IAsyncResult BeginProcessRequest(HttpContext httpContext, AsyncCallback callback, object state) {
+            HttpContextBase iHttpContext = new HttpContextWrapper(httpContext);
+            return BeginProcessRequest(iHttpContext, callback, state);
+        }
+
+        protected internal virtual IAsyncResult BeginProcessRequest(HttpContextBase httpContext, AsyncCallback callback, object state) {
+            return SecurityUtil.ProcessInApplicationTrust(() => {
+                IController controller;
+                IControllerFactory factory;
+                ProcessRequestInit(httpContext, out controller, out factory);
+
+                IAsyncController asyncController = controller as IAsyncController;
+                if (asyncController != null) {
+                    // asynchronous controller
+                    BeginInvokeDelegate beginDelegate = delegate(AsyncCallback asyncCallback, object asyncState) {
+                        try {
+                            return asyncController.BeginExecute(RequestContext, asyncCallback, asyncState);
+                        }
+                        catch {
+                            factory.ReleaseController(asyncController);
+                            throw;
+                        }
+                    };
+
+                    EndInvokeDelegate endDelegate = delegate(IAsyncResult asyncResult) {
+                        try {
+                            asyncController.EndExecute(asyncResult);
+                        }
+                        finally {
+                            factory.ReleaseController(asyncController);
+                        }
+                    };
+
+                    SynchronizationContext syncContext = SynchronizationContextUtil.GetSynchronizationContext();
+                    AsyncCallback newCallback = AsyncUtil.WrapCallbackForSynchronizedExecution(callback, syncContext);
+                    return AsyncResultWrapper.Begin(newCallback, state, beginDelegate, endDelegate, _processRequestTag);
+                }
+                else {
+                    // synchronous controller
+                    Action action = delegate {
+                        try {
+                            controller.Execute(RequestContext);
+                        }
+                        finally {
+                            factory.ReleaseController(controller);
+                        }
+                    };
+
+                    return AsyncResultWrapper.BeginSynchronous(callback, state, action, _processRequestTag);
+                }
+            });
+        }
+
+        protected internal virtual void EndProcessRequest(IAsyncResult asyncResult) {
+            SecurityUtil.ProcessInApplicationTrust(() => {
+                AsyncResultWrapper.End(asyncResult, _processRequestTag);
+            });
+        }
+
+        private static string GetMvcVersionString() {
+            // DevDiv 216459:
+            // This code originally used Assembly.GetName(), but that requires FileIOPermission, which isn't granted in
+            // medium trust. However, Assembly.FullName *is* accessible in medium trust.
+            return new AssemblyName(typeof(MvcHandler).Assembly.FullName).Version.ToString(2);
+        }
+
+        protected virtual void ProcessRequest(HttpContext httpContext) {
+            HttpContextBase iHttpContext = new HttpContextWrapper(httpContext);
+            ProcessRequest(iHttpContext);
+        }
+
+        protected internal virtual void ProcessRequest(HttpContextBase httpContext) {
+            SecurityUtil.ProcessInApplicationTrust(() => {
+                IController controller;
+                IControllerFactory factory;
+                ProcessRequestInit(httpContext, out controller, out factory);
+
+                try {
+                    controller.Execute(RequestContext);
+                }
+                finally {
+                    factory.ReleaseController(controller);
+                }
+            });
+        }
+
+        private void ProcessRequestInit(HttpContextBase httpContext, out IController controller, out IControllerFactory factory) {
+            // If request validation has already been enabled, make it lazy. This allows attributes like [HttpPost] (which looks
+            // at Request.Form) to work correctly without triggering full validation.
+            bool? isRequestValidationEnabled = ValidationUtility.IsValidationEnabled(HttpContext.Current);
+            if (isRequestValidationEnabled == true) {
+                ValidationUtility.EnableDynamicValidation(HttpContext.Current);
+            }
+
+            AddVersionHeader(httpContext);
+            RemoveOptionalRoutingParameters();
+
+            // Get the controller type
+            string controllerName = RequestContext.RouteData.GetRequiredString("controller");
+
+            // Instantiate the controller and call Execute
+            factory = ControllerBuilder.GetControllerFactory();
+            controller = factory.CreateController(RequestContext, controllerName);
+            if (controller == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.ControllerBuilder_FactoryReturnedNull,
+                        factory.GetType(),
+                        controllerName));
+            }
+        }
+
+        private void RemoveOptionalRoutingParameters() {
+            RouteValueDictionary rvd = RequestContext.RouteData.Values;
+
+            // Get all keys for which the corresponding value is 'Optional'.
+            // ToArray() necessary so that we don't manipulate the dictionary while enumerating.
+            string[] matchingKeys = (from entry in rvd
+                                     where entry.Value == UrlParameter.Optional
+                                     select entry.Key).ToArray();
+
+            foreach (string key in matchingKeys) {
+                rvd.Remove(key);
+            }
+        }
+
+        #region IHttpHandler Members
+        bool IHttpHandler.IsReusable {
+            get {
+                return IsReusable;
+            }
+        }
+
+        void IHttpHandler.ProcessRequest(HttpContext httpContext) {
+            ProcessRequest(httpContext);
+        }
+        #endregion
+
+        #region IHttpAsyncHandler Members
+        IAsyncResult IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, object extraData) {
+            return BeginProcessRequest(context, cb, extraData);
+        }
+
+        void IHttpAsyncHandler.EndProcessRequest(IAsyncResult result) {
+            EndProcessRequest(result);
+        }
+        #endregion
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/MvcHtmlString.cs b/mcs/class/System.Web.Mvc3/Mvc/MvcHtmlString.cs
new file mode 100644 (file)
index 0000000..675c2e3
--- /dev/null
@@ -0,0 +1,25 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web;
+
+    public sealed class MvcHtmlString : HtmlString {
+        private readonly string _value;
+
+        public MvcHtmlString(string value)
+            : base(value ?? String.Empty) {
+            _value = value ?? String.Empty;
+        }
+
+        [SuppressMessage("Microsoft.Security", "CA2104:DoNotDeclareReadOnlyMutableReferenceTypes", Justification = "MvcHtmlString is immutable")]
+        public static readonly MvcHtmlString Empty = Create(String.Empty);
+
+        public static MvcHtmlString Create(string value) {
+            return new MvcHtmlString(value);
+        }
+
+        public static bool IsNullOrEmpty(MvcHtmlString value) {
+            return (value == null || value._value.Length == 0);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/MvcHttpHandler.cs b/mcs/class/System.Web.Mvc3/Mvc/MvcHttpHandler.cs
new file mode 100644 (file)
index 0000000..c8e2faa
--- /dev/null
@@ -0,0 +1,89 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Web;
+    using System.Web.Mvc.Async;
+    using System.Web.Routing;
+    using System.Web.SessionState;
+
+    public class MvcHttpHandler : UrlRoutingHandler, IHttpAsyncHandler, IRequiresSessionState {
+
+        private static readonly object _processRequestTag = new object();
+
+        protected virtual IAsyncResult BeginProcessRequest(HttpContext httpContext, AsyncCallback callback, object state) {
+            HttpContextBase iHttpContext = new HttpContextWrapper(httpContext);
+            return BeginProcessRequest(iHttpContext, callback, state);
+        }
+
+        protected internal virtual IAsyncResult BeginProcessRequest(HttpContextBase httpContext, AsyncCallback callback, object state) {
+            IHttpHandler httpHandler = GetHttpHandler(httpContext);
+            IHttpAsyncHandler httpAsyncHandler = httpHandler as IHttpAsyncHandler;
+
+            if (httpAsyncHandler != null) {
+                // asynchronous handler
+                BeginInvokeDelegate beginDelegate = delegate(AsyncCallback asyncCallback, object asyncState) {
+                    return httpAsyncHandler.BeginProcessRequest(HttpContext.Current, asyncCallback, asyncState);
+                };
+                EndInvokeDelegate endDelegate = delegate(IAsyncResult asyncResult) {
+                    httpAsyncHandler.EndProcessRequest(asyncResult);
+                };
+                return AsyncResultWrapper.Begin(callback, state, beginDelegate, endDelegate, _processRequestTag);
+            }
+            else {
+                // synchronous handler
+                Action action = delegate {
+                    httpHandler.ProcessRequest(HttpContext.Current);
+                };
+                return AsyncResultWrapper.BeginSynchronous(callback, state, action, _processRequestTag);
+            }
+        }
+
+        protected internal virtual void EndProcessRequest(IAsyncResult asyncResult) {
+            AsyncResultWrapper.End(asyncResult, _processRequestTag);
+        }
+
+        private static IHttpHandler GetHttpHandler(HttpContextBase httpContext) {
+            DummyHttpHandler dummyHandler = new DummyHttpHandler();
+            dummyHandler.PublicProcessRequest(httpContext);
+            return dummyHandler.HttpHandler;
+        }
+
+        // synchronous code
+        protected override void VerifyAndProcessRequest(IHttpHandler httpHandler, HttpContextBase httpContext) {
+            if (httpHandler == null) {
+                throw new ArgumentNullException("httpHandler");
+            }
+
+            httpHandler.ProcessRequest(HttpContext.Current);
+        }
+
+        #region IHttpAsyncHandler Members
+        IAsyncResult IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, object extraData) {
+            return BeginProcessRequest(context, cb, extraData);
+        }
+
+        void IHttpAsyncHandler.EndProcessRequest(IAsyncResult result) {
+            EndProcessRequest(result);
+        }
+        #endregion
+
+        // Since UrlRoutingHandler.ProcessRequest() does the heavy lifting of looking at the RouteCollection for
+        // a matching route, we need to call into it. However, that method is also responsible for kicking off
+        // the synchronous request, and we can't allow it to do that. The purpose of this dummy class is to run
+        // only the lookup portion of UrlRoutingHandler.ProcessRequest(), then intercept the handler it returns
+        // and execute it asynchronously.
+
+        private sealed class DummyHttpHandler : UrlRoutingHandler {
+            public IHttpHandler HttpHandler;
+
+            public void PublicProcessRequest(HttpContextBase httpContext) {
+                ProcessRequest(httpContext);
+            }
+
+            protected override void VerifyAndProcessRequest(IHttpHandler httpHandler, HttpContextBase httpContext) {
+                // don't process the request, just store a reference to it
+                HttpHandler = httpHandler;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/MvcRouteHandler.cs b/mcs/class/System.Web.Mvc3/Mvc/MvcRouteHandler.cs
new file mode 100644 (file)
index 0000000..17633de
--- /dev/null
@@ -0,0 +1,32 @@
+namespace System.Web.Mvc {
+    using System.Web.Routing;
+    using System.Web.SessionState;
+
+    public class MvcRouteHandler : IRouteHandler {
+        private IControllerFactory _controllerFactory;
+
+        public MvcRouteHandler() {
+        }
+
+        public MvcRouteHandler(IControllerFactory controllerFactory) {
+            _controllerFactory = controllerFactory;
+        }
+
+        protected virtual IHttpHandler GetHttpHandler(RequestContext requestContext) {
+            requestContext.HttpContext.SetSessionStateBehavior(GetSessionStateBehavior(requestContext));
+            return new MvcHandler(requestContext);
+        }
+
+        protected virtual SessionStateBehavior GetSessionStateBehavior(RequestContext requestContext) {
+            string controllerName = (string)requestContext.RouteData.Values["controller"];
+            IControllerFactory controllerFactory = _controllerFactory ?? ControllerBuilder.Current.GetControllerFactory();
+            return controllerFactory.GetControllerSessionBehavior(requestContext, controllerName);
+        }
+
+        #region IRouteHandler Members
+        IHttpHandler IRouteHandler.GetHttpHandler(RequestContext requestContext) {
+            return GetHttpHandler(requestContext);
+        }
+        #endregion
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/MvcWebRazorHostFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/MvcWebRazorHostFactory.cs
new file mode 100644 (file)
index 0000000..d10bfbf
--- /dev/null
@@ -0,0 +1,17 @@
+namespace System.Web.Mvc {
+    using System.Web.Mvc.Razor;
+    using System.Web.WebPages.Razor;
+
+    public class MvcWebRazorHostFactory : WebRazorHostFactory {
+
+        public override WebPageRazorHost CreateHost(string virtualPath, string physicalPath) {
+            WebPageRazorHost host = base.CreateHost(virtualPath, physicalPath);
+
+            if(!host.IsSpecialPage) {
+                return new MvcWebPageRazorHost(virtualPath, physicalPath);
+            }
+
+            return host;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/NameValueCollectionExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/NameValueCollectionExtensions.cs
new file mode 100644 (file)
index 0000000..d76eaf9
--- /dev/null
@@ -0,0 +1,27 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Collections.Specialized;
+
+    public static class NameValueCollectionExtensions {
+
+        public static void CopyTo(this NameValueCollection collection, IDictionary<string, object> destination) {
+            CopyTo(collection, destination, false /* replaceEntries */);
+        }
+
+        public static void CopyTo(this NameValueCollection collection, IDictionary<string, object> destination, bool replaceEntries) {
+            if (collection == null) {
+                throw new ArgumentNullException("collection");
+            }
+            if (destination == null) {
+                throw new ArgumentNullException("destination");
+            }
+
+            foreach (string key in collection.Keys) {
+                if (replaceEntries || !destination.ContainsKey(key)) {
+                    destination[key] = collection[key];
+                }
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/NameValueCollectionValueProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/NameValueCollectionValueProvider.cs
new file mode 100644 (file)
index 0000000..207f819
--- /dev/null
@@ -0,0 +1,97 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Collections.Specialized;
+    using System.Globalization;
+    using System.Threading;
+
+    public class NameValueCollectionValueProvider : IValueProvider, IUnvalidatedValueProvider {
+
+        private readonly HashSet<string> _prefixes = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
+        private readonly Dictionary<string, ValueProviderResultPlaceholder> _values = new Dictionary<string, ValueProviderResultPlaceholder>(StringComparer.OrdinalIgnoreCase);
+
+        public NameValueCollectionValueProvider(NameValueCollection collection, CultureInfo culture)
+            : this(collection, null /* unvalidatedCollection */, culture) {
+        }
+
+        public NameValueCollectionValueProvider(NameValueCollection collection, NameValueCollection unvalidatedCollection, CultureInfo culture) {
+            if (collection == null) {
+                throw new ArgumentNullException("collection");
+            }
+
+            AddValues(collection, unvalidatedCollection ?? collection, culture);
+        }
+
+        private void AddValues(NameValueCollection validatedCollection, NameValueCollection unvalidatedCollection, CultureInfo culture) {
+            // Need to read keys from the unvalidated collection, as M.W.I's granular request validation is a bit touchy
+            // and validated entries at the time the key or value is looked at. For example, GetKey() will throw if the
+            // value fails request validation, even though the value's not being looked at (M.W.I can't tell the difference).
+
+            if (unvalidatedCollection.Count > 0) {
+                _prefixes.Add("");
+            }
+
+            foreach (string key in unvalidatedCollection) {
+                if (key != null) {
+                    _prefixes.UnionWith(ValueProviderUtil.GetPrefixes(key));
+
+                    // need to look up values lazily, as eagerly looking at the collection might trigger validation
+                    _values[key] = new ValueProviderResultPlaceholder(key, validatedCollection, unvalidatedCollection, culture);
+                }
+            }
+        }
+
+        public virtual bool ContainsPrefix(string prefix) {
+            if (prefix == null) {
+                throw new ArgumentNullException("prefix");
+            }
+
+            return _prefixes.Contains(prefix);
+        }
+
+        public virtual ValueProviderResult GetValue(string key) {
+            return GetValue(key, skipValidation: false);
+        }
+
+        public virtual ValueProviderResult GetValue(string key, bool skipValidation) {
+            if (key == null) {
+                throw new ArgumentNullException("key");
+            }
+
+            ValueProviderResultPlaceholder placeholder;
+            _values.TryGetValue(key, out placeholder);
+            if (placeholder == null) {
+                return null;
+            }
+            else {
+                return (skipValidation) ? placeholder.UnvalidatedResult : placeholder.ValidatedResult;
+            }
+        }
+
+        // Placeholder that can store a validated (in relation to request validation) or unvalidated
+        // ValueProviderResult for a given key.
+        private sealed class ValueProviderResultPlaceholder {
+            private readonly Lazy<ValueProviderResult> _validatedResultPlaceholder;
+            private readonly Lazy<ValueProviderResult> _unvalidatedResultPlaceholder;
+
+            public ValueProviderResultPlaceholder(string key, NameValueCollection validatedCollection, NameValueCollection unvalidatedCollection, CultureInfo culture) {
+                _validatedResultPlaceholder = new Lazy<ValueProviderResult>(() => GetResultFromCollection(key, validatedCollection, culture), LazyThreadSafetyMode.None);
+                _unvalidatedResultPlaceholder = new Lazy<ValueProviderResult>(() => GetResultFromCollection(key, unvalidatedCollection, culture), LazyThreadSafetyMode.None);
+            }
+
+            private static ValueProviderResult GetResultFromCollection(string key, NameValueCollection collection, CultureInfo culture) {
+                string[] rawValue = collection.GetValues(key);
+                string attemptedValue = collection[key];
+                return new ValueProviderResult(rawValue, attemptedValue, culture);
+            }
+
+            public ValueProviderResult ValidatedResult {
+                get { return _validatedResultPlaceholder.Value; }
+            }
+
+            public ValueProviderResult UnvalidatedResult {
+                get { return _unvalidatedResultPlaceholder.Value; }
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/NoAsyncTimeoutAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/NoAsyncTimeoutAttribute.cs
new file mode 100644 (file)
index 0000000..6ca0639
--- /dev/null
@@ -0,0 +1,12 @@
+namespace System.Web.Mvc {
+    using System.Threading;
+
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
+    public sealed class NoAsyncTimeoutAttribute : AsyncTimeoutAttribute {
+
+        public NoAsyncTimeoutAttribute()
+            : base(Timeout.Infinite) {
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/NonActionAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/NonActionAttribute.cs
new file mode 100644 (file)
index 0000000..412b228
--- /dev/null
@@ -0,0 +1,10 @@
+namespace System.Web.Mvc {
+    using System.Reflection;
+
+    [AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public sealed class NonActionAttribute : ActionMethodSelectorAttribute {
+        public override bool IsValidForRequest(ControllerContext controllerContext, MethodInfo methodInfo) {
+            return false;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/NullViewLocationCache.cs b/mcs/class/System.Web.Mvc3/Mvc/NullViewLocationCache.cs
new file mode 100644 (file)
index 0000000..003b21f
--- /dev/null
@@ -0,0 +1,18 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq;
+    using System.Text;
+
+    internal sealed class NullViewLocationCache : IViewLocationCache {
+
+        #region IViewLocationCache Members
+        public string GetViewLocation(HttpContextBase httpContext, string key) {
+            return null;
+        }
+
+        public void InsertViewLocation(HttpContextBase httpContext, string key, string virtualPath) {
+        }
+        #endregion
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/OutputCacheAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/OutputCacheAttribute.cs
new file mode 100644 (file)
index 0000000..685b3ec
--- /dev/null
@@ -0,0 +1,337 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.IO;
+    using System.Linq;
+    using System.Runtime.Caching;
+    using System.Security.Cryptography;
+    using System.Text;
+    using System.Web;
+    using System.Web.Mvc.Resources;
+    using System.Web.UI;
+
+    [SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes", Justification = "Unsealed so that subclassed types can set properties in the default constructor.")]
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
+    public class OutputCacheAttribute : ActionFilterAttribute, IExceptionFilter {
+
+        private OutputCacheParameters _cacheSettings = new OutputCacheParameters { VaryByParam = "*" };
+        private const string _cacheKeyPrefix = "_MvcChildActionCache_";
+        private static ObjectCache _childActionCache;
+        private Func<ObjectCache> _childActionCacheThunk = () => ChildActionCache;
+        private static object _childActionFilterFinishCallbackKey = new object();
+        private bool _locationWasSet;
+        private bool _noStoreWasSet;
+
+        public OutputCacheAttribute() {
+        }
+
+        internal OutputCacheAttribute(ObjectCache childActionCache) {
+            _childActionCacheThunk = () => childActionCache;
+        }
+
+        public string CacheProfile {
+            get {
+                return _cacheSettings.CacheProfile ?? String.Empty;
+            }
+            set {
+                _cacheSettings.CacheProfile = value;
+            }
+        }
+
+        internal OutputCacheParameters CacheSettings {
+            get {
+                return _cacheSettings;
+            }
+        }
+
+        public static ObjectCache ChildActionCache {
+            get {
+                return _childActionCache ?? MemoryCache.Default;
+            }
+            set {
+                _childActionCache = value;
+            }
+        }
+
+        private ObjectCache ChildActionCacheInternal {
+            get {
+                return _childActionCacheThunk();
+            }
+        }
+
+        public int Duration {
+            get {
+                return _cacheSettings.Duration;
+            }
+            set {
+                _cacheSettings.Duration = value;
+            }
+        }
+
+        public OutputCacheLocation Location {
+            get {
+                return _cacheSettings.Location;
+            }
+            set {
+                _cacheSettings.Location = value;
+                _locationWasSet = true;
+            }
+        }
+
+        public bool NoStore {
+            get {
+                return _cacheSettings.NoStore;
+            }
+            set {
+                _cacheSettings.NoStore = value;
+                _noStoreWasSet = true;
+            }
+        }
+
+        public string SqlDependency {
+            get {
+                return _cacheSettings.SqlDependency ?? String.Empty;
+            }
+            set {
+                _cacheSettings.SqlDependency = value;
+            }
+        }
+
+        public string VaryByContentEncoding {
+            get {
+                return _cacheSettings.VaryByContentEncoding ?? String.Empty;
+            }
+            set {
+                _cacheSettings.VaryByContentEncoding = value;
+            }
+        }
+
+        public string VaryByCustom {
+            get {
+                return _cacheSettings.VaryByCustom ?? String.Empty;
+            }
+            set {
+                _cacheSettings.VaryByCustom = value;
+            }
+        }
+
+        public string VaryByHeader {
+            get {
+                return _cacheSettings.VaryByHeader ?? String.Empty;
+            }
+            set {
+                _cacheSettings.VaryByHeader = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Param", Justification = "Matches the @ OutputCache page directive.")]
+        public string VaryByParam {
+            get {
+                return _cacheSettings.VaryByParam ?? String.Empty;
+            }
+            set {
+                _cacheSettings.VaryByParam = value;
+            }
+        }
+
+        private static void ClearChildActionFilterFinishCallback(ControllerContext controllerContext) {
+            controllerContext.HttpContext.Items.Remove(_childActionFilterFinishCallbackKey);
+        }
+
+        private static void CompleteChildAction(ControllerContext filterContext, bool wasException) {
+            Action<bool> callback = GetChildActionFilterFinishCallback(filterContext);
+
+            if (callback != null) {
+                ClearChildActionFilterFinishCallback(filterContext);
+                callback(wasException);
+            }
+        }
+
+        private static Action<bool> GetChildActionFilterFinishCallback(ControllerContext controllerContext) {
+            return controllerContext.HttpContext.Items[_childActionFilterFinishCallbackKey] as Action<bool>;
+        }
+
+        internal string GetChildActionUniqueId(ActionExecutingContext filterContext) {
+            StringBuilder uniqueIdBuilder = new StringBuilder();
+
+            // Start with a prefix, presuming that we share the cache with other users
+            uniqueIdBuilder.Append(_cacheKeyPrefix);
+
+            // Unique ID of the action description
+            uniqueIdBuilder.Append(filterContext.ActionDescriptor.UniqueId);
+
+            // Unique ID from the VaryByCustom settings, if any
+            uniqueIdBuilder.Append(DescriptorUtil.CreateUniqueId(VaryByCustom));
+            if (!String.IsNullOrEmpty(VaryByCustom)) {
+                string varyByCustomResult = filterContext.HttpContext.ApplicationInstance.GetVaryByCustomString(HttpContext.Current, VaryByCustom);
+                uniqueIdBuilder.Append(varyByCustomResult);
+            }
+
+            // Unique ID from the VaryByParam settings, if any
+            uniqueIdBuilder.Append(GetUniqueIdFromActionParameters(filterContext, SplitVaryByParam(VaryByParam)));
+
+            // The key is typically too long to be useful, so we use a cryptographic hash
+            // as the actual key (better randomization and key distribution, so small vary
+            // values will generate dramtically different keys).
+            using (SHA256 sha = SHA256.Create()) {
+                return Convert.ToBase64String(sha.ComputeHash(Encoding.UTF8.GetBytes(uniqueIdBuilder.ToString())));
+            }
+        }
+
+        private static string GetUniqueIdFromActionParameters(ActionExecutingContext filterContext, IEnumerable<string> keys) {
+            // Generate a unique ID of normalized key names + key values
+            var keyValues = new Dictionary<string, object>(filterContext.ActionParameters, StringComparer.OrdinalIgnoreCase);
+            keys = (keys ?? keyValues.Keys).Select(key => key.ToUpperInvariant())
+                                           .OrderBy(key => key, StringComparer.Ordinal);
+
+            return DescriptorUtil.CreateUniqueId(keys.Concat(keys.Select(key => keyValues.ContainsKey(key) ? keyValues[key] : null)));
+        }
+
+        public static bool IsChildActionCacheActive(ControllerContext controllerContext) {
+            return GetChildActionFilterFinishCallback(controllerContext) != null;
+        }
+
+        public override void OnActionExecuted(ActionExecutedContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            // Complete the request if the child action threw an exception
+            if (filterContext.IsChildAction && filterContext.Exception != null) {
+                CompleteChildAction(filterContext, wasException: true);
+            }
+        }
+
+        public override void OnActionExecuting(ActionExecutingContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            if (filterContext.IsChildAction) {
+                ValidateChildActionConfiguration();
+
+                // Already actively being captured? (i.e., cached child action inside of cached child action)
+                // Realistically, this needs write substitution to do properly (including things like authentication)
+                if (GetChildActionFilterFinishCallback(filterContext) != null) {
+                    throw new InvalidOperationException(MvcResources.OutputCacheAttribute_CannotNestChildCache);
+                }
+
+                // Already cached?
+                string uniqueId = GetChildActionUniqueId(filterContext);
+                string cachedValue = ChildActionCacheInternal.Get(uniqueId) as string;
+                if (cachedValue != null) {
+                    filterContext.Result = new ContentResult() { Content = cachedValue };
+                    return;
+                }
+
+                // Swap in a new TextWriter so we can capture the output
+                StringWriter cachingWriter = new StringWriter(CultureInfo.InvariantCulture);
+                TextWriter originalWriter = filterContext.HttpContext.Response.Output;
+                filterContext.HttpContext.Response.Output = cachingWriter;
+
+                // Set a finish callback to clean up
+                SetChildActionFilterFinishCallback(filterContext, wasException => {
+                    // Restore original writer
+                    filterContext.HttpContext.Response.Output = originalWriter;
+
+                    // Grab output and write it
+                    string capturedText = cachingWriter.ToString();
+                    filterContext.HttpContext.Response.Write(capturedText);
+
+                    // Only cache output if this wasn't an error
+                    if (!wasException) {
+                        ChildActionCacheInternal.Add(uniqueId, capturedText, DateTimeOffset.UtcNow.AddSeconds(Duration));
+                    }
+                });
+            }
+        }
+
+        public void OnException(ExceptionContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            if (filterContext.IsChildAction) {
+                CompleteChildAction(filterContext, wasException: true);
+            }
+        }
+
+        public override void OnResultExecuting(ResultExecutingContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            if (!filterContext.IsChildAction) {
+                // we need to call ProcessRequest() since there's no other way to set the Page.Response intrinsic
+                using (OutputCachedPage page = new OutputCachedPage(_cacheSettings)) {
+                    page.ProcessRequest(HttpContext.Current);
+                }
+            }
+        }
+
+        public override void OnResultExecuted(ResultExecutedContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            if (filterContext.IsChildAction) {
+                CompleteChildAction(filterContext, wasException: filterContext.Exception != null);
+            }
+        }
+
+        private static void SetChildActionFilterFinishCallback(ControllerContext controllerContext, Action<bool> callback) {
+            controllerContext.HttpContext.Items[_childActionFilterFinishCallbackKey] = callback;
+        }
+
+        private static IEnumerable<string> SplitVaryByParam(string varyByParam) {
+            if (String.Equals(varyByParam, "none", StringComparison.OrdinalIgnoreCase)) {  // Vary by nothing
+                return Enumerable.Empty<string>();
+            }
+
+            if (String.Equals(varyByParam, "*", StringComparison.OrdinalIgnoreCase)) {  // Vary by everything
+                return null;
+            }
+
+            return from part in varyByParam.Split(';')  // Vary by specific parameters
+                   let trimmed = part.Trim()
+                   where !String.IsNullOrEmpty(trimmed)
+                   select trimmed;
+        }
+
+        private void ValidateChildActionConfiguration() {
+            if (Duration <= 0) {
+                throw new InvalidOperationException(MvcResources.OutputCacheAttribute_InvalidDuration);
+            }
+
+            if (String.IsNullOrWhiteSpace(VaryByParam)) {
+                throw new InvalidOperationException(MvcResources.OutputCacheAttribute_InvalidVaryByParam);
+            }
+
+            if (!String.IsNullOrWhiteSpace(CacheProfile) ||
+                !String.IsNullOrWhiteSpace(SqlDependency) ||
+                !String.IsNullOrWhiteSpace(VaryByContentEncoding) ||
+                !String.IsNullOrWhiteSpace(VaryByHeader) ||
+                _locationWasSet || _noStoreWasSet) {
+                throw new InvalidOperationException(MvcResources.OutputCacheAttribute_ChildAction_UnsupportedSetting);
+            }
+        }
+
+        private sealed class OutputCachedPage : Page {
+            private OutputCacheParameters _cacheSettings;
+
+            public OutputCachedPage(OutputCacheParameters cacheSettings) {
+                // Tracing requires Page IDs to be unique.
+                ID = Guid.NewGuid().ToString();
+                _cacheSettings = cacheSettings;
+            }
+
+            protected override void FrameworkInitialize() {
+                // when you put the <%@ OutputCache %> directive on a page, the generated code calls InitOutputCache() from here
+                base.FrameworkInitialize();
+                InitOutputCache(_cacheSettings);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ParameterBindingInfo.cs b/mcs/class/System.Web.Mvc3/Mvc/ParameterBindingInfo.cs
new file mode 100644 (file)
index 0000000..33518d2
--- /dev/null
@@ -0,0 +1,31 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+
+    public abstract class ParameterBindingInfo {
+
+        public virtual IModelBinder Binder {
+            get {
+                return null;
+            }
+        }
+
+        public virtual ICollection<string> Exclude {
+            get {
+                return new string[0];
+            }
+        }
+
+        public virtual ICollection<string> Include {
+            get {
+                return new string[0];
+            }
+        }
+
+        public virtual string Prefix {
+            get {
+                return null;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ParameterDescriptor.cs b/mcs/class/System.Web.Mvc3/Mvc/ParameterDescriptor.cs
new file mode 100644 (file)
index 0000000..50fe4c6
--- /dev/null
@@ -0,0 +1,57 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Reflection;
+
+    public abstract class ParameterDescriptor : ICustomAttributeProvider {
+
+        private static readonly EmptyParameterBindingInfo _emptyBindingInfo = new EmptyParameterBindingInfo();
+
+        public abstract ActionDescriptor ActionDescriptor {
+            get;
+        }
+
+        public virtual ParameterBindingInfo BindingInfo {
+            get {
+                return _emptyBindingInfo;
+            }
+        }
+
+        public virtual object DefaultValue {
+            get {
+                return null;
+            }
+        }
+
+        public abstract string ParameterName {
+            get;
+        }
+
+        public abstract Type ParameterType {
+            get;
+        }
+
+        public virtual object[] GetCustomAttributes(bool inherit) {
+            return GetCustomAttributes(typeof(object), inherit);
+        }
+
+        public virtual object[] GetCustomAttributes(Type attributeType, bool inherit) {
+            if (attributeType == null) {
+                throw new ArgumentNullException("attributeType");
+            }
+
+            return (object[])Array.CreateInstance(attributeType, 0);
+        }
+
+        public virtual bool IsDefined(Type attributeType, bool inherit) {
+            if (attributeType == null) {
+                throw new ArgumentNullException("attributeType");
+            }
+
+            return false;
+        }
+
+        private sealed class EmptyParameterBindingInfo : ParameterBindingInfo {
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ParameterInfoUtil.cs b/mcs/class/System.Web.Mvc3/Mvc/ParameterInfoUtil.cs
new file mode 100644 (file)
index 0000000..b10adba
--- /dev/null
@@ -0,0 +1,30 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.ComponentModel;
+    using System.Reflection;
+
+    internal static class ParameterInfoUtil {
+
+        public static bool TryGetDefaultValue(ParameterInfo parameterInfo, out object value) {
+            // this will get the default value as seen by the VB / C# compilers
+            // if no value was baked in, RawDefaultValue returns DBNull.Value
+            object defaultValue = parameterInfo.DefaultValue;
+            if (defaultValue != DBNull.Value) {
+                value = defaultValue;
+                return true;
+            }
+
+            // if the compiler did not bake in a default value, check the [DefaultValue] attribute
+            DefaultValueAttribute[] attrs = (DefaultValueAttribute[])parameterInfo.GetCustomAttributes(typeof(DefaultValueAttribute), false);
+            if (attrs == null || attrs.Length == 0) {
+                value = default(object);
+                return false;
+            }
+            else {
+                value = attrs[0].Value;
+                return true;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/PartialViewResult.cs b/mcs/class/System.Web.Mvc3/Mvc/PartialViewResult.cs
new file mode 100644 (file)
index 0000000..3e8f93b
--- /dev/null
@@ -0,0 +1,25 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Globalization;
+    using System.Text;
+    using System.Web.Mvc.Resources;
+
+    public class PartialViewResult : ViewResultBase {
+
+        protected override ViewEngineResult FindView(ControllerContext context) {
+            ViewEngineResult result = ViewEngineCollection.FindPartialView(context, ViewName);
+            if (result.View != null) {
+                return result;
+            }
+
+            // we need to generate an exception containing all the locations we searched
+            StringBuilder locationsText = new StringBuilder();
+            foreach (string location in result.SearchedLocations) {
+                locationsText.AppendLine();
+                locationsText.Append(location);
+            }
+            throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture,
+                MvcResources.Common_PartialViewNotFound, ViewName, locationsText));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/PathHelpers.cs b/mcs/class/System.Web.Mvc3/Mvc/PathHelpers.cs
new file mode 100644 (file)
index 0000000..a2645e8
--- /dev/null
@@ -0,0 +1,84 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Specialized;
+    using System.Web;
+
+    internal static class PathHelpers {
+
+        private readonly static UrlRewriterHelper _urlRewriterHelper = new UrlRewriterHelper();
+
+        // this method can accept an app-relative path or an absolute path for contentPath
+        public static string GenerateClientUrl(HttpContextBase httpContext, string contentPath) {
+            if (String.IsNullOrEmpty(contentPath)) {
+                return contentPath;
+            }
+
+            // many of the methods we call internally can't handle query strings properly, so just strip it out for
+            // the time being
+            string query;
+            contentPath = StripQuery(contentPath, out query);
+
+            return GenerateClientUrlInternal(httpContext, contentPath) + query;
+        }
+
+        private static string GenerateClientUrlInternal(HttpContextBase httpContext, string contentPath) {
+            if (String.IsNullOrEmpty(contentPath)) {
+                return contentPath;
+            }
+
+            // can't call VirtualPathUtility.IsAppRelative since it throws on some inputs
+            bool isAppRelative = contentPath[0] == '~';
+            if (isAppRelative) {
+                string absoluteContentPath = VirtualPathUtility.ToAbsolute(contentPath, httpContext.Request.ApplicationPath);
+                string modifiedAbsoluteContentPath = httpContext.Response.ApplyAppPathModifier(absoluteContentPath);
+                return GenerateClientUrlInternal(httpContext, modifiedAbsoluteContentPath);
+            }
+
+            // we only want to manipulate the path if URL rewriting is active for this request, else we risk breaking the generated URL
+            bool wasRequestRewritten = _urlRewriterHelper.WasRequestRewritten(httpContext);
+            if (!wasRequestRewritten) {
+                return contentPath;
+            }
+
+            // Since the rawUrl represents what the user sees in his browser, it is what we want to use as the base
+            // of our absolute paths. For example, consider mysite.example.com/foo, which is internally
+            // rewritten to content.example.com/mysite/foo. When we want to generate a link to ~/bar, we want to
+            // base it from / instead of /foo, otherwise the user ends up seeing mysite.example.com/foo/bar,
+            // which is incorrect.
+            string relativeUrlToDestination = MakeRelative(httpContext.Request.Path, contentPath);
+            string absoluteUrlToDestination = MakeAbsolute(httpContext.Request.RawUrl, relativeUrlToDestination);
+            return absoluteUrlToDestination;
+        }
+
+        public static string MakeAbsolute(string basePath, string relativePath) {
+            // The Combine() method can't handle query strings on the base path, so we trim it off.
+            string query;
+            basePath = StripQuery(basePath, out query);
+            return VirtualPathUtility.Combine(basePath, relativePath);
+        }
+
+        public static string MakeRelative(string fromPath, string toPath) {
+            string relativeUrl = VirtualPathUtility.MakeRelative(fromPath, toPath);
+            if (String.IsNullOrEmpty(relativeUrl) || relativeUrl[0] == '?') {
+                // Sometimes VirtualPathUtility.MakeRelative() will return an empty string when it meant to return '.',
+                // but links to {empty string} are browser dependent. We replace it with an explicit path to force
+                // consistency across browsers.
+                relativeUrl = "./" + relativeUrl;
+            }
+            return relativeUrl;
+        }
+
+        private static string StripQuery(string path, out string query) {
+            int queryIndex = path.IndexOf('?');
+            if (queryIndex >= 0) {
+                query = path.Substring(queryIndex);
+                return path.Substring(0, queryIndex);
+            }
+            else {
+                query = null;
+                return path;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/PreApplicationStartCode.cs b/mcs/class/System.Web.Mvc3/Mvc/PreApplicationStartCode.cs
new file mode 100644 (file)
index 0000000..d5b9df8
--- /dev/null
@@ -0,0 +1,22 @@
+namespace System.Web.Mvc {
+    using System.ComponentModel;
+    using System.Web.WebPages.Scope;
+
+    [EditorBrowsable(EditorBrowsableState.Never)]
+    public static class PreApplicationStartCode {
+        private static bool _startWasCalled;
+
+        public static void Start() {
+            // Guard against multiple calls. All Start calls are made on same thread, so no lock needed here
+            if (_startWasCalled) {
+                return;
+            }
+            _startWasCalled = true;
+
+            System.Web.WebPages.Razor.PreApplicationStartCode.Start();
+            System.Web.WebPages.PreApplicationStartCode.Start();
+
+            ViewContext.GlobalScopeThunk = () => ScopeStorage.CurrentScope;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/QueryStringValueProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/QueryStringValueProvider.cs
new file mode 100644 (file)
index 0000000..1c70edf
--- /dev/null
@@ -0,0 +1,21 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Specialized;
+    using System.Globalization;
+    using System.Web.Helpers;
+
+    public sealed class QueryStringValueProvider : NameValueCollectionValueProvider {
+
+        // QueryString should use the invariant culture since it's part of the URL, and the URL should be
+        // interpreted in a uniform fashion regardless of the origin of a particular request.
+        public QueryStringValueProvider(ControllerContext controllerContext)
+            : this(controllerContext, new UnvalidatedRequestValuesWrapper(controllerContext.HttpContext.Request.Unvalidated())) {
+        }
+
+        // For unit testing
+        internal QueryStringValueProvider(ControllerContext controllerContext, IUnvalidatedRequestValues unvalidatedValues)
+            : base(controllerContext.HttpContext.Request.QueryString, unvalidatedValues.QueryString, CultureInfo.InvariantCulture) {
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/QueryStringValueProviderFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/QueryStringValueProviderFactory.cs
new file mode 100644 (file)
index 0000000..8e9cc10
--- /dev/null
@@ -0,0 +1,28 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Specialized;
+    using System.Web.Helpers;
+
+    public sealed class QueryStringValueProviderFactory : ValueProviderFactory {
+
+        private readonly UnvalidatedRequestValuesAccessor _unvalidatedValuesAccessor;
+
+        public QueryStringValueProviderFactory()
+            : this(null) {
+        }
+
+        // For unit testing
+        internal QueryStringValueProviderFactory(UnvalidatedRequestValuesAccessor unvalidatedValuesAccessor) {
+            _unvalidatedValuesAccessor = unvalidatedValuesAccessor ?? (cc => new UnvalidatedRequestValuesWrapper(cc.HttpContext.Request.Unvalidated()));
+        }
+
+        public override IValueProvider GetValueProvider(ControllerContext controllerContext) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            return new QueryStringValueProvider(controllerContext, _unvalidatedValuesAccessor(controllerContext));
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RangeAttributeAdapter.cs b/mcs/class/System.Web.Mvc3/Mvc/RangeAttributeAdapter.cs
new file mode 100644 (file)
index 0000000..3aa86af
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.ComponentModel.DataAnnotations;
+
+    public class RangeAttributeAdapter : DataAnnotationsModelValidator<RangeAttribute> {
+        public RangeAttributeAdapter(ModelMetadata metadata, ControllerContext context, RangeAttribute attribute)
+            : base(metadata, context, attribute) {
+        }
+
+        public override IEnumerable<ModelClientValidationRule> GetClientValidationRules() {
+            string errorMessage = ErrorMessage; // Per Dev10 Bug #923283, need to make sure ErrorMessage is called before Minimum/Maximum
+            return new[] { new ModelClientValidationRangeRule(errorMessage, Attribute.Minimum, Attribute.Maximum) };
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Razor/ModelSpan.cs b/mcs/class/System.Web.Mvc3/Mvc/Razor/ModelSpan.cs
new file mode 100644 (file)
index 0000000..ed02ea7
--- /dev/null
@@ -0,0 +1,34 @@
+namespace System.Web.Mvc.Razor {
+    using System.Web.Razor.Parser;
+    using System.Web.Razor.Parser.SyntaxTree;
+    using System.Web.Razor.Text;
+
+    public class ModelSpan : CodeSpan {
+        public ModelSpan(SourceLocation start, string content, string modelTypeName)
+            : base(start, content) {
+            this.ModelTypeName = modelTypeName;
+        }
+
+        internal ModelSpan(ParserContext context, string modelTypeName)
+            : this(context.CurrentSpanStart, context.ContentBuffer.ToString(), modelTypeName) {
+        }
+
+        public string ModelTypeName {
+            get;
+            private set;
+        }
+
+        public override int GetHashCode() {
+            return base.GetHashCode() ^ (ModelTypeName ?? String.Empty).GetHashCode();
+        }
+
+        public override bool Equals(object obj) {
+            ModelSpan span = obj as ModelSpan;
+            return span != null && Equals(span);
+        }
+
+        private bool Equals(ModelSpan span) {
+            return base.Equals(span) && String.Equals(ModelTypeName, span.ModelTypeName, StringComparison.Ordinal);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcCSharpRazorCodeGenerator.cs b/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcCSharpRazorCodeGenerator.cs
new file mode 100644 (file)
index 0000000..b09a95a
--- /dev/null
@@ -0,0 +1,30 @@
+using System.CodeDom;
+using System.Web.Razor;
+using System.Web.Razor.Generator;
+
+namespace System.Web.Mvc.Razor
+{
+    internal class MvcCSharpRazorCodeGenerator : CSharpRazorCodeGenerator
+    {
+        private const string DefaultModelTypeName = "dynamic";
+
+        public MvcCSharpRazorCodeGenerator(string className, string rootNamespaceName, string sourceFileName, RazorEngineHost host)
+            : base(className, rootNamespaceName, sourceFileName, host)
+        {
+            var mvcHost = host as MvcWebPageRazorHost;
+            if (mvcHost != null && !mvcHost.IsSpecialPage)
+            {
+                // set the default model type to "dynamic" (Dev10 bug 935656)
+                // don't set it for "special" pages (such as "_viewStart.cshtml")
+                SetBaseType(DefaultModelTypeName);
+            }
+        }
+
+        private void SetBaseType(string modelTypeName)
+        {
+            var baseType = new CodeTypeReference(Context.Host.DefaultBaseClass + "<" + modelTypeName + ">");
+            Context.GeneratedClass.BaseTypes.Clear();
+            Context.GeneratedClass.BaseTypes.Add(baseType);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcCSharpRazorCodeParser.cs b/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcCSharpRazorCodeParser.cs
new file mode 100644 (file)
index 0000000..95f53b7
--- /dev/null
@@ -0,0 +1,68 @@
+using System.Globalization;
+using System.Web.Mvc.Resources;
+using System.Web.Razor.Generator;
+using System.Web.Razor.Parser;
+using System.Web.Razor.Text;
+
+namespace System.Web.Mvc.Razor
+{
+    public class MvcCSharpRazorCodeParser : CSharpCodeParser
+    {
+        private const string ModelKeyword = "model";
+        private const string GenericTypeFormatString = "{0}<{1}>";
+        private SourceLocation? _endInheritsLocation;
+        private bool _modelStatementFound;
+
+        public MvcCSharpRazorCodeParser()
+        {
+            MapDirectives(ModelDirective, ModelKeyword);
+        }
+
+        protected override void InheritsDirective()
+        {
+            // Verify we're on the right keyword and accept
+            AssertDirective(SyntaxConstants.CSharp.InheritsKeyword);
+            AcceptAndMoveNext();
+            _endInheritsLocation = CurrentLocation;
+
+            InheritsDirectiveCore();
+            CheckForInheritsAndModelStatements();
+        }
+
+        private void CheckForInheritsAndModelStatements()
+        {
+            if (_modelStatementFound && _endInheritsLocation.HasValue)
+            {
+                Context.OnError(_endInheritsLocation.Value, String.Format(CultureInfo.CurrentCulture, MvcResources.MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword, ModelKeyword));
+            }
+        }
+
+        protected virtual void ModelDirective()
+        {
+            // Verify we're on the right keyword and accept
+            AssertDirective(ModelKeyword);
+            AcceptAndMoveNext();
+
+            SourceLocation endModelLocation = CurrentLocation;
+
+            BaseTypeDirective(
+                String.Format(CultureInfo.CurrentCulture,
+                              MvcResources.MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName, ModelKeyword),
+                CreateModelCodeGenerator);
+
+            if (_modelStatementFound)
+            {
+                Context.OnError(endModelLocation, String.Format(CultureInfo.CurrentCulture, MvcResources.MvcRazorCodeParser_OnlyOneModelStatementIsAllowed, ModelKeyword));
+            }
+
+            _modelStatementFound = true;
+
+            CheckForInheritsAndModelStatements();
+        }
+
+        private SpanCodeGenerator CreateModelCodeGenerator(string model)
+        {
+            return new SetModelTypeCodeGenerator(model, GenericTypeFormatString);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcVBRazorCodeGenerator.cs b/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcVBRazorCodeGenerator.cs
new file mode 100644 (file)
index 0000000..13c5c5a
--- /dev/null
@@ -0,0 +1,28 @@
+namespace System.Web.Mvc.Razor {
+    using System.CodeDom;
+    using System.Web.Razor;
+    using System.Web.Razor.Generator;
+    using System.Web.Razor.Parser.SyntaxTree;
+
+    public class MvcVBRazorCodeGenerator : VBRazorCodeGenerator {
+        public MvcVBRazorCodeGenerator(string className, string rootNamespaceName, string sourceFileName, RazorEngineHost host)
+            : base(className, rootNamespaceName, sourceFileName, host) {
+        }
+
+        protected override bool TryVisitSpecialSpan(Span span) {
+            return TryVisit<ModelSpan>(span, VisitModelSpan);
+        }
+
+        private void VisitModelSpan(ModelSpan span) {
+            string modelName = span.ModelTypeName;
+            var baseType = new CodeTypeReference(Host.DefaultBaseClass + "(Of " + modelName + ")");
+
+            GeneratedClass.BaseTypes.Clear();
+            GeneratedClass.BaseTypes.Add(baseType);
+
+            if (DesignTimeMode) {
+                WriteHelperVariable(span.Content, "__modelHelper");
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcVBRazorCodeParser.cs b/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcVBRazorCodeParser.cs
new file mode 100644 (file)
index 0000000..9ac6889
--- /dev/null
@@ -0,0 +1,93 @@
+using System.Globalization;
+using System.Linq;
+using System.Web.Mvc.Resources;
+using System.Web.Razor.Generator;
+using System.Web.Razor.Parser;
+using System.Web.Razor.Parser.SyntaxTree;
+using System.Web.Razor.Text;
+using System.Web.Razor.Tokenizer.Symbols;
+
+namespace System.Web.Mvc.Razor
+{
+    public class MvcVBRazorCodeParser : VBCodeParser
+    {
+        internal const string ModelTypeKeyword = "ModelType";
+        private const string GenericTypeFormatString = "{0}(Of {1})";
+        private SourceLocation? _endInheritsLocation;
+        private bool _modelStatementFound;
+
+        public MvcVBRazorCodeParser()
+        {
+            MapDirective(ModelTypeKeyword, ModelTypeDirective);
+        }
+
+        protected override bool InheritsStatement()
+        {
+            // Verify we're on the right keyword and accept
+            Assert(VBKeyword.Inherits);
+            VBSymbol inherits = CurrentSymbol;
+            NextToken();
+            _endInheritsLocation = CurrentLocation;
+            PutCurrentBack();
+            PutBack(inherits);
+            EnsureCurrent();
+
+            bool result = base.InheritsStatement();
+            CheckForInheritsAndModelStatements();
+            return result;
+        }
+
+        private void CheckForInheritsAndModelStatements()
+        {
+            if (_modelStatementFound && _endInheritsLocation.HasValue)
+            {
+                Context.OnError(_endInheritsLocation.Value, String.Format(CultureInfo.CurrentCulture, MvcResources.MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword, ModelTypeKeyword));
+            }
+        }
+
+        protected virtual bool ModelTypeDirective()
+        {
+            AssertDirective(ModelTypeKeyword);
+
+            Span.CodeGenerator = SpanCodeGenerator.Null;
+            Context.CurrentBlock.Type = BlockType.Directive;
+
+            AcceptAndMoveNext();
+            SourceLocation endModelLocation = CurrentLocation;
+
+            if (At(VBSymbolType.WhiteSpace))
+            {
+                Span.EditHandler.AcceptedCharacters = AcceptedCharacters.None;
+            }
+
+            AcceptWhile(VBSymbolType.WhiteSpace);
+            Output(SpanKind.MetaCode);
+
+            if (_modelStatementFound)
+            {
+                Context.OnError(endModelLocation, String.Format(CultureInfo.CurrentCulture, MvcResources.MvcRazorCodeParser_OnlyOneModelStatementIsAllowed, ModelTypeKeyword));
+            }
+            _modelStatementFound = true;
+
+            if (EndOfFile || At(VBSymbolType.WhiteSpace) || At(VBSymbolType.NewLine))
+            {
+                Context.OnError(endModelLocation, MvcResources.MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName, ModelTypeKeyword);
+            }
+
+            // Just accept to a newline
+            AcceptUntil(VBSymbolType.NewLine);
+            if (!Context.DesignTimeMode)
+            {
+                // We want the newline to be treated as code, but it causes issues at design-time.
+                Optional(VBSymbolType.NewLine);
+            }
+
+            string baseType = String.Concat(Span.Symbols.Select(s => s.Content)).Trim();
+            Span.CodeGenerator = new SetModelTypeCodeGenerator(baseType, GenericTypeFormatString);
+
+            CheckForInheritsAndModelStatements();
+            Output(SpanKind.Code);
+            return false;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcWebPageRazorHost.cs b/mcs/class/System.Web.Mvc3/Mvc/Razor/MvcWebPageRazorHost.cs
new file mode 100644 (file)
index 0000000..69f058f
--- /dev/null
@@ -0,0 +1,64 @@
+using System.Diagnostics;
+using System.Diagnostics.CodeAnalysis;
+using System.Web.Razor.Generator;
+using System.Web.Razor.Parser;
+using System.Web.WebPages.Razor;
+
+namespace System.Web.Mvc.Razor
+{
+    [SuppressMessage("Microsoft.Naming", "CA1702:CompoundWordsShouldBeCasedCorrectly", MessageId = "WebPage", Justification = "The class name is derived from the name of the base type")]
+    public class MvcWebPageRazorHost : WebPageRazorHost
+    {
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The NamespaceImports property should not be virtual. This is a temporary fix.")]
+        public MvcWebPageRazorHost(string virtualPath, string physicalPath)
+            : base(virtualPath, physicalPath)
+        {
+            RegisterSpecialFile(RazorViewEngine.ViewStartFileName, typeof(ViewStartPage));
+
+            DefaultPageBaseClass = typeof(WebViewPage).FullName;
+
+            // REVIEW get rid of the namespace import to not force additional references in default MVC projects
+            GetRidOfNamespace("System.Web.WebPages.Html");
+        }
+
+        public override RazorCodeGenerator DecorateCodeGenerator(RazorCodeGenerator incomingCodeGenerator)
+        {
+            if (incomingCodeGenerator is CSharpRazorCodeGenerator)
+            {
+                return new MvcCSharpRazorCodeGenerator(incomingCodeGenerator.ClassName,
+                                                       incomingCodeGenerator.RootNamespaceName,
+                                                       incomingCodeGenerator.SourceFileName,
+                                                       incomingCodeGenerator.Host);
+            }
+            else
+            {
+                return base.DecorateCodeGenerator(incomingCodeGenerator);
+            }
+        }
+
+        public override ParserBase DecorateCodeParser(ParserBase incomingCodeParser)
+        {
+            if (incomingCodeParser is CSharpCodeParser)
+            {
+                return new MvcCSharpRazorCodeParser();
+            }
+            else if (incomingCodeParser is VBCodeParser)
+            {
+                return new MvcVBRazorCodeParser();
+            }
+            else
+            {
+                return base.DecorateCodeParser(incomingCodeParser);
+            }
+        }
+
+        private void GetRidOfNamespace(string ns)
+        {
+            Debug.Assert(NamespaceImports.Contains(ns), ns + " is not a default namespace anymore");
+            if (NamespaceImports.Contains(ns))
+            {
+                NamespaceImports.Remove(ns);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Razor/SetModelTypeCodeGenerator.cs b/mcs/class/System.Web.Mvc3/Mvc/Razor/SetModelTypeCodeGenerator.cs
new file mode 100644 (file)
index 0000000..e8640b2
--- /dev/null
@@ -0,0 +1,47 @@
+using System.Globalization;
+using System.Web.Mvc.ExpressionUtil;
+using System.Web.Razor.Generator;
+
+namespace System.Web.Mvc.Razor
+{
+    internal class SetModelTypeCodeGenerator : SetBaseTypeCodeGenerator
+    {
+        private string _genericTypeFormat;
+
+        public SetModelTypeCodeGenerator(string modelType, string genericTypeFormat)
+            : base(modelType)
+        {
+            _genericTypeFormat = genericTypeFormat;
+        }
+
+        protected override string ResolveType(CodeGeneratorContext context, string baseType)
+        {
+            return String.Format(
+                CultureInfo.InvariantCulture,
+                _genericTypeFormat,
+                context.Host.DefaultBaseClass,
+                baseType);
+        }
+
+        public override bool Equals(object obj)
+        {
+            SetModelTypeCodeGenerator other = obj as SetModelTypeCodeGenerator;
+            return other != null &&
+                   base.Equals(obj) &&
+                   String.Equals(_genericTypeFormat, other._genericTypeFormat, StringComparison.Ordinal);
+        }
+
+        public override int GetHashCode()
+        {
+            var combiner = new HashCodeCombiner();
+            combiner.AddInt32(base.GetHashCode());
+            combiner.AddObject(_genericTypeFormat);
+            return combiner.CombinedHash;
+        }
+
+        public override string ToString()
+        {
+            return "Model:" + BaseType;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Razor/StartPageLookupDelegate.cs b/mcs/class/System.Web.Mvc3/Mvc/Razor/StartPageLookupDelegate.cs
new file mode 100644 (file)
index 0000000..0719761
--- /dev/null
@@ -0,0 +1,7 @@
+using System.Collections.Generic;
+using System.Web.WebPages;
+
+namespace System.Web.Mvc.Razor
+{
+    internal delegate WebPageRenderingBase StartPageLookupDelegate(WebPageRenderingBase page, string fileName, IEnumerable<string> supportedExtensions);
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RazorView.cs b/mcs/class/System.Web.Mvc3/Mvc/RazorView.cs
new file mode 100644 (file)
index 0000000..49e5b9d
--- /dev/null
@@ -0,0 +1,73 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Globalization;
+    using System.IO;
+    using System.Linq;
+    using System.Web.Mvc.Razor;
+    using System.Web.Mvc.Resources;
+    using System.Web.WebPages;
+
+    public class RazorView : BuildManagerCompiledView {
+
+        public RazorView(ControllerContext controllerContext, string viewPath, string layoutPath, bool runViewStartPages, IEnumerable<string> viewStartFileExtensions)
+            : this(controllerContext, viewPath, layoutPath, runViewStartPages, viewStartFileExtensions, null) {
+        }
+
+        public RazorView(ControllerContext controllerContext, string viewPath, string layoutPath, bool runViewStartPages, IEnumerable<string> viewStartFileExtensions, IViewPageActivator viewPageActivator)
+            : base(controllerContext, viewPath, viewPageActivator) {
+            LayoutPath = layoutPath ?? String.Empty;
+            RunViewStartPages = runViewStartPages;
+            StartPageLookup = StartPage.GetStartPage;
+            ViewStartFileExtensions = viewStartFileExtensions ?? Enumerable.Empty<string>();
+        }
+
+        public string LayoutPath {
+            get;
+            private set;
+        }
+
+        public bool RunViewStartPages {
+            get;
+            private set;
+        }
+
+        internal StartPageLookupDelegate StartPageLookup {
+            get;
+            set;
+        }
+
+        public IEnumerable<string> ViewStartFileExtensions {
+            get;
+            private set;
+        }
+
+        protected override void RenderView(ViewContext viewContext, TextWriter writer, object instance) {
+            if (writer == null) {
+                throw new ArgumentNullException("writer");
+            }
+
+            WebViewPage webViewPage = instance as WebViewPage;
+            if (webViewPage == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.CshtmlView_WrongViewBase,
+                        ViewPath));
+            }
+
+            // An overriden master layout might have been specified when the ViewActionResult got returned.
+            // We need to hold on to it so that we can set it on the inner page once it has executed.
+            webViewPage.OverridenLayoutPath = LayoutPath;
+            webViewPage.VirtualPath = ViewPath;
+            webViewPage.ViewContext = viewContext;
+            webViewPage.ViewData = viewContext.ViewData;
+
+            webViewPage.InitHelpers();
+            WebPageRenderingBase startPage = null;
+            if (RunViewStartPages) {
+                startPage = StartPageLookup(webViewPage, RazorViewEngine.ViewStartFileName, ViewStartFileExtensions);
+            }
+            webViewPage.ExecutePageHierarchy(new WebPageContext(context: viewContext.HttpContext, page: null, model: null), writer, startPage);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RazorViewEngine.cs b/mcs/class/System.Web.Mvc3/Mvc/RazorViewEngine.cs
new file mode 100644 (file)
index 0000000..72c85e2
--- /dev/null
@@ -0,0 +1,68 @@
+namespace System.Web.Mvc {
+    using System.Diagnostics.CodeAnalysis;
+
+    public class RazorViewEngine : BuildManagerViewEngine {
+        internal static readonly string ViewStartFileName = "_ViewStart";
+
+        public RazorViewEngine()
+            : this(null) {
+        }
+
+        public RazorViewEngine(IViewPageActivator viewPageActivator)
+            : base(viewPageActivator) {
+            AreaViewLocationFormats = new[] {
+                "~/Areas/{2}/Views/{1}/{0}.cshtml",
+                "~/Areas/{2}/Views/{1}/{0}.vbhtml",
+                "~/Areas/{2}/Views/Shared/{0}.cshtml",
+                "~/Areas/{2}/Views/Shared/{0}.vbhtml"
+            };
+            AreaMasterLocationFormats = new[] {
+                "~/Areas/{2}/Views/{1}/{0}.cshtml",
+                "~/Areas/{2}/Views/{1}/{0}.vbhtml",
+                "~/Areas/{2}/Views/Shared/{0}.cshtml",
+                "~/Areas/{2}/Views/Shared/{0}.vbhtml"
+            };
+            AreaPartialViewLocationFormats = new[] {
+                "~/Areas/{2}/Views/{1}/{0}.cshtml",
+                "~/Areas/{2}/Views/{1}/{0}.vbhtml",
+                "~/Areas/{2}/Views/Shared/{0}.cshtml",
+                "~/Areas/{2}/Views/Shared/{0}.vbhtml"
+            };
+
+            ViewLocationFormats = new[] {
+                "~/Views/{1}/{0}.cshtml",
+                "~/Views/{1}/{0}.vbhtml",
+                "~/Views/Shared/{0}.cshtml",
+                "~/Views/Shared/{0}.vbhtml"
+            };
+            MasterLocationFormats = new[] {
+                "~/Views/{1}/{0}.cshtml",
+                "~/Views/{1}/{0}.vbhtml",
+                "~/Views/Shared/{0}.cshtml",
+                "~/Views/Shared/{0}.vbhtml"
+            };
+            PartialViewLocationFormats = new[] {
+                "~/Views/{1}/{0}.cshtml",
+                "~/Views/{1}/{0}.vbhtml",
+                "~/Views/Shared/{0}.cshtml",
+                "~/Views/Shared/{0}.vbhtml"
+            };
+
+            FileExtensions = new[] {
+                "cshtml",
+                "vbhtml",
+            };
+        }
+
+        protected override IView CreatePartialView(ControllerContext controllerContext, string partialPath) {
+            return new RazorView(controllerContext, partialPath,
+                                 layoutPath: null, runViewStartPages: false, viewStartFileExtensions: FileExtensions, viewPageActivator: ViewPageActivator);
+        }
+
+        protected override IView CreateView(ControllerContext controllerContext, string viewPath, string masterPath) {
+            var view = new RazorView(controllerContext, viewPath,
+                                     layoutPath: masterPath, runViewStartPages: true, viewStartFileExtensions: FileExtensions, viewPageActivator: ViewPageActivator);
+            return view;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ReaderWriterCache`2.cs b/mcs/class/System.Web.Mvc3/Mvc/ReaderWriterCache`2.cs
new file mode 100644 (file)
index 0000000..6856240
--- /dev/null
@@ -0,0 +1,59 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Threading;
+
+    [SuppressMessage("Microsoft.Design", "CA1001:TypesThatOwnDisposableFieldsShouldBeDisposable", Justification = "Instances of this type are meant to be singletons.")]
+    internal abstract class ReaderWriterCache<TKey, TValue> {
+
+        private readonly Dictionary<TKey, TValue> _cache;
+        private readonly ReaderWriterLockSlim _rwLock = new ReaderWriterLockSlim();
+
+        protected ReaderWriterCache()
+            : this(null) {
+        }
+
+        protected ReaderWriterCache(IEqualityComparer<TKey> comparer) {
+            _cache = new Dictionary<TKey, TValue>(comparer);
+        }
+
+        protected Dictionary<TKey, TValue> Cache {
+            get {
+                return _cache;
+            }
+        }
+
+        protected TValue FetchOrCreateItem(TKey key, Func<TValue> creator) {
+            // first, see if the item already exists in the cache
+            _rwLock.EnterReadLock();
+            try {
+                TValue existingEntry;
+                if (_cache.TryGetValue(key, out existingEntry)) {
+                    return existingEntry;
+                }
+            }
+            finally {
+                _rwLock.ExitReadLock();
+            }
+
+            // insert the new item into the cache
+            TValue newEntry = creator();
+            _rwLock.EnterWriteLock();
+            try {
+                TValue existingEntry;
+                if (_cache.TryGetValue(key, out existingEntry)) {
+                    // another thread already inserted an item, so use that one
+                    return existingEntry;
+                }
+
+                _cache[key] = newEntry;
+                return newEntry;
+            }
+            finally {
+                _rwLock.ExitWriteLock();
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RedirectResult.cs b/mcs/class/System.Web.Mvc3/Mvc/RedirectResult.cs
new file mode 100644 (file)
index 0000000..bb3e93d
--- /dev/null
@@ -0,0 +1,55 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web.Mvc.Resources;
+
+    // represents a result that performs a redirection given some URI
+    public class RedirectResult : ActionResult {
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "0#", Justification = "Response.Redirect() takes its URI as a string parameter.")]
+        public RedirectResult(string url)
+            : this(url, permanent: false) {
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "0#", Justification = "Response.Redirect() takes its URI as a string parameter.")]
+        public RedirectResult(string url, bool permanent) {
+            if (String.IsNullOrEmpty(url)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "url");
+            }
+
+            Permanent = permanent;
+            Url = url;
+        }
+
+        public bool Permanent {
+            get;
+            private set;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1056:UriPropertiesShouldNotBeStrings", Justification = "Response.Redirect() takes its URI as a string parameter.")]
+        public string Url {
+            get;
+            private set;
+        }
+
+        public override void ExecuteResult(ControllerContext context) {
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+            if (context.IsChildAction) {
+                throw new InvalidOperationException(MvcResources.RedirectAction_CannotRedirectInChildAction);
+            }
+
+            string destinationUrl = UrlHelper.GenerateContentUrl(Url, context.HttpContext);
+            context.Controller.TempData.Keep();
+
+            if (Permanent) {
+                context.HttpContext.Response.RedirectPermanent(destinationUrl, endResponse: false);
+            }
+            else {
+                context.HttpContext.Response.Redirect(destinationUrl, endResponse: false);
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RedirectToRouteResult.cs b/mcs/class/System.Web.Mvc3/Mvc/RedirectToRouteResult.cs
new file mode 100644 (file)
index 0000000..d45b634
--- /dev/null
@@ -0,0 +1,76 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    // represents a result that performs a redirection given some values dictionary
+    public class RedirectToRouteResult : ActionResult {
+
+        private RouteCollection _routes;
+
+        public RedirectToRouteResult(RouteValueDictionary routeValues) :
+            this(null, routeValues) {
+        }
+
+        public RedirectToRouteResult(string routeName, RouteValueDictionary routeValues)
+            : this(routeName, routeValues, permanent: false) {
+        }
+
+        public RedirectToRouteResult(string routeName, RouteValueDictionary routeValues, bool permanent) {
+            Permanent = permanent;
+            RouteName = routeName ?? String.Empty;
+            RouteValues = routeValues ?? new RouteValueDictionary();
+        }
+
+        public bool Permanent {
+            get;
+            private set;
+        }
+
+        public string RouteName {
+            get;
+            private set;
+        }
+
+        public RouteValueDictionary RouteValues {
+            get;
+            private set;
+        }
+
+        internal RouteCollection Routes {
+            get {
+                if (_routes == null) {
+                    _routes = RouteTable.Routes;
+                }
+                return _routes;
+            }
+            set {
+                _routes = value;
+            }
+        }
+
+        public override void ExecuteResult(ControllerContext context) {
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+            if (context.IsChildAction) {
+                throw new InvalidOperationException(MvcResources.RedirectAction_CannotRedirectInChildAction);
+            }
+
+            string destinationUrl = UrlHelper.GenerateUrl(RouteName, null /* actionName */, null /* controllerName */, RouteValues, Routes, context.RequestContext, false /* includeImplicitMvcValues */);
+            if (String.IsNullOrEmpty(destinationUrl)) {
+                throw new InvalidOperationException(MvcResources.Common_NoRouteMatched);
+            }
+
+            context.Controller.TempData.Keep();
+
+            if (Permanent) {
+                context.HttpContext.Response.RedirectPermanent(destinationUrl, endResponse: false);
+            }
+            else {
+                context.HttpContext.Response.Redirect(destinationUrl, endResponse: false);
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ReflectedActionDescriptor.cs b/mcs/class/System.Web.Mvc3/Mvc/ReflectedActionDescriptor.cs
new file mode 100644 (file)
index 0000000..afedad5
--- /dev/null
@@ -0,0 +1,134 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    public class ReflectedActionDescriptor : ActionDescriptor {
+
+        private readonly string _actionName;
+        private readonly ControllerDescriptor _controllerDescriptor;
+        private ParameterDescriptor[] _parametersCache;
+        private readonly Lazy<string> _uniqueId;
+
+        public ReflectedActionDescriptor(MethodInfo methodInfo, string actionName, ControllerDescriptor controllerDescriptor)
+            : this(methodInfo, actionName, controllerDescriptor, true /* validateMethod */) {
+        }
+
+        internal ReflectedActionDescriptor(MethodInfo methodInfo, string actionName, ControllerDescriptor controllerDescriptor, bool validateMethod) {
+            if (methodInfo == null) {
+                throw new ArgumentNullException("methodInfo");
+            }
+            if (String.IsNullOrEmpty(actionName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "actionName");
+            }
+            if (controllerDescriptor == null) {
+                throw new ArgumentNullException("controllerDescriptor");
+            }
+
+            if (validateMethod) {
+                string failedMessage = VerifyActionMethodIsCallable(methodInfo);
+                if (failedMessage != null) {
+                    throw new ArgumentException(failedMessage, "methodInfo");
+                }
+            }
+
+            MethodInfo = methodInfo;
+            _actionName = actionName;
+            _controllerDescriptor = controllerDescriptor;
+            _uniqueId = new Lazy<string>(CreateUniqueId);
+        }
+
+        public override string ActionName {
+            get {
+                return _actionName;
+            }
+        }
+
+        public override ControllerDescriptor ControllerDescriptor {
+            get {
+                return _controllerDescriptor;
+            }
+        }
+
+        public MethodInfo MethodInfo {
+            get;
+            private set;
+        }
+
+        public override string UniqueId {
+            get {
+                return _uniqueId.Value;
+            }
+        }
+
+        private string CreateUniqueId() {
+            return base.UniqueId + DescriptorUtil.CreateUniqueId(MethodInfo);
+        }
+
+        public override object Execute(ControllerContext controllerContext, IDictionary<string, object> parameters) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (parameters == null) {
+                throw new ArgumentNullException("parameters");
+            }
+
+            ParameterInfo[] parameterInfos = MethodInfo.GetParameters();
+            var rawParameterValues = from parameterInfo in parameterInfos
+                                     select ExtractParameterFromDictionary(parameterInfo, parameters, MethodInfo);
+            object[] parametersArray = rawParameterValues.ToArray();
+
+            ActionMethodDispatcher dispatcher = DispatcherCache.GetDispatcher(MethodInfo);
+            object actionReturnValue = dispatcher.Execute(controllerContext.Controller, parametersArray);
+            return actionReturnValue;
+        }
+
+        public override object[] GetCustomAttributes(bool inherit) {
+            return MethodInfo.GetCustomAttributes(inherit);
+        }
+
+        public override object[] GetCustomAttributes(Type attributeType, bool inherit) {
+            return MethodInfo.GetCustomAttributes(attributeType, inherit);
+        }
+
+        internal override IEnumerable<FilterAttribute> GetFilterAttributes(bool useCache) {
+            if (useCache && GetType() == typeof(ReflectedActionDescriptor)) {
+                // Do not look at cache in types derived from this type because they might incorrectly implement GetCustomAttributes
+                return ReflectedAttributeCache.GetMethodFilterAttributes(MethodInfo);
+            }
+            return base.GetFilterAttributes(useCache);
+        }
+
+        public override ParameterDescriptor[] GetParameters() {
+            ParameterDescriptor[] parameters = LazilyFetchParametersCollection();
+
+            // need to clone array so that user modifications aren't accidentally stored
+            return (ParameterDescriptor[])parameters.Clone();
+        }
+
+        public override ICollection<ActionSelector> GetSelectors() {
+            ActionMethodSelectorAttribute[] attrs = (ActionMethodSelectorAttribute[])MethodInfo.GetCustomAttributes(typeof(ActionMethodSelectorAttribute), true /* inherit */);
+            ActionSelector[] selectors = Array.ConvertAll(attrs, attr => (ActionSelector)(controllerContext => attr.IsValidForRequest(controllerContext, MethodInfo)));
+            return selectors;
+        }
+
+        public override bool IsDefined(Type attributeType, bool inherit) {
+            return MethodInfo.IsDefined(attributeType, inherit);
+        }
+
+        private ParameterDescriptor[] LazilyFetchParametersCollection() {
+            return DescriptorUtil.LazilyFetchOrCreateDescriptors<ParameterInfo, ParameterDescriptor>(
+                ref _parametersCache /* cacheLocation */,
+                MethodInfo.GetParameters /* initializer */,
+                parameterInfo => new ReflectedParameterDescriptor(parameterInfo, this) /* converter */);
+        }
+
+        internal static ReflectedActionDescriptor TryCreateDescriptor(MethodInfo methodInfo, string name, ControllerDescriptor controllerDescriptor) {
+            ReflectedActionDescriptor descriptor = new ReflectedActionDescriptor(methodInfo, name, controllerDescriptor, false /* validateMethod */);
+            string failedMessage = VerifyActionMethodIsCallable(methodInfo);
+            return (failedMessage == null) ? descriptor : null;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ReflectedAttributeCache.cs b/mcs/class/System.Web.Mvc3/Mvc/ReflectedAttributeCache.cs
new file mode 100644 (file)
index 0000000..a05ad25
--- /dev/null
@@ -0,0 +1,41 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Concurrent;
+    using System.Diagnostics;
+    using System.Reflection;
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+
+    internal static class ReflectedAttributeCache {
+        private static readonly ConcurrentDictionary<MethodInfo, ReadOnlyCollection<ActionMethodSelectorAttribute>> _actionMethodSelectorAttributeCache = new ConcurrentDictionary<MethodInfo, ReadOnlyCollection<ActionMethodSelectorAttribute>>();
+        private static readonly ConcurrentDictionary<MethodInfo, ReadOnlyCollection<ActionNameSelectorAttribute>> _actionNameSelectorAttributeCache = new ConcurrentDictionary<MethodInfo, ReadOnlyCollection<ActionNameSelectorAttribute>>();
+        private static readonly ConcurrentDictionary<MethodInfo, ReadOnlyCollection<FilterAttribute>> _methodFilterAttributeCache = new ConcurrentDictionary<MethodInfo, ReadOnlyCollection<FilterAttribute>>();
+
+        private static readonly ConcurrentDictionary<Type, ReadOnlyCollection<FilterAttribute>> _typeFilterAttributeCache = new ConcurrentDictionary<Type, ReadOnlyCollection<FilterAttribute>>();
+
+        public static ICollection<FilterAttribute> GetTypeFilterAttributes(Type type) {
+            return GetAttributes(_typeFilterAttributeCache, type);
+        }
+
+        public static ICollection<FilterAttribute> GetMethodFilterAttributes(MethodInfo methodInfo) {
+            return GetAttributes(_methodFilterAttributeCache, methodInfo);
+        }
+
+        public static ICollection<ActionMethodSelectorAttribute> GetActionMethodSelectorAttributes(MethodInfo methodInfo) {
+            return GetAttributes(_actionMethodSelectorAttributeCache, methodInfo);
+        }
+
+        public static ICollection<ActionNameSelectorAttribute> GetActionNameSelectorAttributes(MethodInfo methodInfo) {
+            return GetAttributes(_actionNameSelectorAttributeCache, methodInfo);
+        }
+
+        private static ReadOnlyCollection<TAttribute> GetAttributes<TMemberInfo, TAttribute>(ConcurrentDictionary<TMemberInfo, ReadOnlyCollection<TAttribute>> lookup, TMemberInfo memberInfo)
+            where TAttribute : Attribute
+            where TMemberInfo : MemberInfo {
+
+            Debug.Assert(memberInfo != null);
+            Debug.Assert(lookup != null);
+            return lookup.GetOrAdd(memberInfo, mi => new ReadOnlyCollection<TAttribute>((TAttribute[])memberInfo.GetCustomAttributes(typeof(TAttribute), inherit: true)));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ReflectedControllerDescriptor.cs b/mcs/class/System.Web.Mvc3/Mvc/ReflectedControllerDescriptor.cs
new file mode 100644 (file)
index 0000000..486207f
--- /dev/null
@@ -0,0 +1,87 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    public class ReflectedControllerDescriptor : ControllerDescriptor {
+
+        private ActionDescriptor[] _canonicalActionsCache;
+        private readonly Type _controllerType;
+        private readonly ActionMethodSelector _selector;
+
+        public ReflectedControllerDescriptor(Type controllerType) {
+            if (controllerType == null) {
+                throw new ArgumentNullException("controllerType");
+            }
+
+            _controllerType = controllerType;
+            _selector = new ActionMethodSelector(_controllerType);
+        }
+
+        public sealed override Type ControllerType {
+            get {
+                return _controllerType;
+            }
+        }
+
+        public override ActionDescriptor FindAction(ControllerContext controllerContext, string actionName) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (String.IsNullOrEmpty(actionName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "actionName");
+            }
+
+            MethodInfo matched = _selector.FindActionMethod(controllerContext, actionName);
+            if (matched == null) {
+                return null;
+            }
+
+            return new ReflectedActionDescriptor(matched, actionName, this);
+        }
+
+        private MethodInfo[] GetAllActionMethodsFromSelector() {
+            List<MethodInfo> allValidMethods = new List<MethodInfo>();
+            allValidMethods.AddRange(_selector.AliasedMethods);
+            allValidMethods.AddRange(_selector.NonAliasedMethods.SelectMany(g => g));
+            return allValidMethods.ToArray();
+        }
+
+        public override ActionDescriptor[] GetCanonicalActions() {
+            ActionDescriptor[] actions = LazilyFetchCanonicalActionsCollection();
+
+            // need to clone array so that user modifications aren't accidentally stored
+            return (ActionDescriptor[])actions.Clone();
+        }
+
+        public override object[] GetCustomAttributes(bool inherit) {
+            return ControllerType.GetCustomAttributes(inherit);
+        }
+
+        public override object[] GetCustomAttributes(Type attributeType, bool inherit) {
+            return ControllerType.GetCustomAttributes(attributeType, inherit);
+        }
+
+        internal override IEnumerable<FilterAttribute> GetFilterAttributes(bool useCache) {
+            if (useCache && GetType() == typeof(ReflectedControllerDescriptor)) {
+                // Do not look at cache in types derived from this type because they might incorrectly implement GetCustomAttributes
+                return ReflectedAttributeCache.GetTypeFilterAttributes(ControllerType);
+            }
+            return base.GetFilterAttributes(useCache);
+        }
+
+        public override bool IsDefined(Type attributeType, bool inherit) {
+            return ControllerType.IsDefined(attributeType, inherit);
+        }
+
+        private ActionDescriptor[] LazilyFetchCanonicalActionsCollection() {
+            return DescriptorUtil.LazilyFetchOrCreateDescriptors<MethodInfo, ActionDescriptor>(
+                ref _canonicalActionsCache /* cacheLocation */,
+                GetAllActionMethodsFromSelector /* initializer */,
+                methodInfo => ReflectedActionDescriptor.TryCreateDescriptor(methodInfo, methodInfo.Name, this) /* converter */);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ReflectedParameterBindingInfo.cs b/mcs/class/System.Web.Mvc3/Mvc/ReflectedParameterBindingInfo.cs
new file mode 100644 (file)
index 0000000..e145ee4
--- /dev/null
@@ -0,0 +1,61 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+    using System.Globalization;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    internal class ReflectedParameterBindingInfo : ParameterBindingInfo {
+
+        private ICollection<string> _exclude = new string[0];
+        private ICollection<string> _include = new string[0];
+        private readonly ParameterInfo _parameterInfo;
+        private string _prefix;
+
+        public ReflectedParameterBindingInfo(ParameterInfo parameterInfo) {
+            _parameterInfo = parameterInfo;
+            ReadSettingsFromBindAttribute();
+        }
+
+        public override IModelBinder Binder {
+            get {
+                IModelBinder binder = ModelBinders.GetBinderFromAttributes(_parameterInfo,
+                    () => String.Format(CultureInfo.CurrentCulture, MvcResources.ReflectedParameterBindingInfo_MultipleConverterAttributes,
+                        _parameterInfo.Name, _parameterInfo.Member));
+
+                return binder;
+            }
+        }
+
+        public override ICollection<string> Exclude {
+            get {
+                return _exclude;
+            }
+        }
+
+        public override ICollection<string> Include {
+            get {
+                return _include;
+            }
+        }
+
+        public override string Prefix {
+            get {
+                return _prefix;
+            }
+        }
+
+        private void ReadSettingsFromBindAttribute() {
+            BindAttribute attr = (BindAttribute)Attribute.GetCustomAttribute(_parameterInfo, typeof(BindAttribute));
+            if (attr == null) {
+                return;
+            }
+
+            _exclude = new ReadOnlyCollection<string>(AuthorizeAttribute.SplitString(attr.Exclude));
+            _include = new ReadOnlyCollection<string>(AuthorizeAttribute.SplitString(attr.Include));
+            _prefix = attr.Prefix;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ReflectedParameterDescriptor.cs b/mcs/class/System.Web.Mvc3/Mvc/ReflectedParameterDescriptor.cs
new file mode 100644 (file)
index 0000000..42f7d25
--- /dev/null
@@ -0,0 +1,78 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.ComponentModel;
+    using System.Reflection;
+
+    public class ReflectedParameterDescriptor : ParameterDescriptor {
+
+        private readonly ActionDescriptor _actionDescriptor;
+        private readonly ReflectedParameterBindingInfo _bindingInfo;
+
+        public ReflectedParameterDescriptor(ParameterInfo parameterInfo, ActionDescriptor actionDescriptor) {
+            if (parameterInfo == null) {
+                throw new ArgumentNullException("parameterInfo");
+            }
+            if (actionDescriptor == null) {
+                throw new ArgumentNullException("actionDescriptor");
+            }
+
+            ParameterInfo = parameterInfo;
+            _actionDescriptor = actionDescriptor;
+            _bindingInfo = new ReflectedParameterBindingInfo(parameterInfo);
+        }
+
+        public override ActionDescriptor ActionDescriptor {
+            get {
+                return _actionDescriptor;
+            }
+        }
+
+        public override ParameterBindingInfo BindingInfo {
+            get {
+                return _bindingInfo;
+            }
+        }
+
+        public override object DefaultValue {
+            get {
+                object value;
+                if (ParameterInfoUtil.TryGetDefaultValue(ParameterInfo, out value)) {
+                    return value;
+                }
+                else {
+                    return base.DefaultValue;
+                }
+            }
+        }
+
+        public ParameterInfo ParameterInfo {
+            get;
+            private set;
+        }
+
+        public override string ParameterName {
+            get {
+                return ParameterInfo.Name;
+            }
+        }
+
+        public override Type ParameterType {
+            get {
+                return ParameterInfo.ParameterType;
+            }
+        }
+
+        public override object[] GetCustomAttributes(bool inherit) {
+            return ParameterInfo.GetCustomAttributes(inherit);
+        }
+
+        public override object[] GetCustomAttributes(Type attributeType, bool inherit) {
+            return ParameterInfo.GetCustomAttributes(attributeType, inherit);
+        }
+
+        public override bool IsDefined(Type attributeType, bool inherit) {
+            return ParameterInfo.IsDefined(attributeType, inherit);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RegularExpressionAttributeAdapter.cs b/mcs/class/System.Web.Mvc3/Mvc/RegularExpressionAttributeAdapter.cs
new file mode 100644 (file)
index 0000000..2de12ac
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.ComponentModel.DataAnnotations;
+
+    public class RegularExpressionAttributeAdapter : DataAnnotationsModelValidator<RegularExpressionAttribute> {
+        public RegularExpressionAttributeAdapter(ModelMetadata metadata, ControllerContext context, RegularExpressionAttribute attribute)
+            : base(metadata, context, attribute) {
+        }
+
+        public override IEnumerable<ModelClientValidationRule> GetClientValidationRules() {
+            return new[] { new ModelClientValidationRegexRule(ErrorMessage, Attribute.Pattern) };
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RemoteAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/RemoteAttribute.cs
new file mode 100644 (file)
index 0000000..e49fd98
--- /dev/null
@@ -0,0 +1,121 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel.DataAnnotations;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    [AttributeUsage(AttributeTargets.Property)]
+    [SuppressMessage("Microsoft.Design", "CA1019:DefineAccessorsForAttributeArguments", Justification = "The constructor parameters are used to feed RouteData, which is public.")]
+    [SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes", Justification = "This attribute is designed to be a base class for other attributes.")]
+    public class RemoteAttribute : ValidationAttribute, IClientValidatable {
+
+        private string _additionalFields;
+        private string[] _additonalFieldsSplit = new string[0];
+
+        protected RemoteAttribute()
+            : base(MvcResources.RemoteAttribute_RemoteValidationFailed) {
+            RouteData = new RouteValueDictionary();
+        }
+
+        public RemoteAttribute(string routeName)
+            : this() {
+            if (String.IsNullOrWhiteSpace(routeName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "routeName");
+            }
+
+            RouteName = routeName;
+        }
+
+        public RemoteAttribute(string action, string controller) :
+            this(action, controller, null /* areaName */) {
+        }
+
+        public RemoteAttribute(string action, string controller, string areaName)
+            : this() {
+            if (String.IsNullOrWhiteSpace(action)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "action");
+            }
+            if (String.IsNullOrWhiteSpace(controller)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "controller");
+            }
+
+            RouteData["controller"] = controller;
+            RouteData["action"] = action;
+
+            if (!String.IsNullOrWhiteSpace(areaName)) {
+                RouteData["area"] = areaName;
+            }
+        }
+
+        public string HttpMethod { get; set; }
+
+        public string AdditionalFields {
+            get {
+                return _additionalFields ?? String.Empty;
+            }
+            set {
+                _additionalFields = value;
+                _additonalFieldsSplit = AuthorizeAttribute.SplitString(value);
+            }
+        }
+
+        public string FormatAdditionalFieldsForClientValidation(string property) {
+            if (String.IsNullOrEmpty(property)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "property");
+            }
+
+            string delimitedAdditionalFields = FormatPropertyForClientValidation(property);
+
+            foreach (string field in _additonalFieldsSplit) {
+                delimitedAdditionalFields += "," + FormatPropertyForClientValidation(field);
+            }
+
+            return delimitedAdditionalFields;
+        }
+
+        public static string FormatPropertyForClientValidation(string property) {
+            if (String.IsNullOrEmpty(property)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "property");
+            }
+            return "*." + property;
+        }
+
+        protected RouteValueDictionary RouteData { get; private set; }
+
+        protected string RouteName { get; set; }
+
+        protected virtual RouteCollection Routes {
+            get {
+                return RouteTable.Routes;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "The value is a not a regular URL since it may contain ~/ ASP.NET-specific characters")]
+        protected virtual string GetUrl(ControllerContext controllerContext) {
+            var pathData = Routes.GetVirtualPathForArea(controllerContext.RequestContext,
+                                                        RouteName,
+                                                        RouteData);
+
+            if (pathData == null) {
+                throw new InvalidOperationException(MvcResources.RemoteAttribute_NoUrlFound);
+            }
+
+            return pathData.VirtualPath;
+        }
+
+        public override string FormatErrorMessage(string name) {
+            return string.Format(CultureInfo.CurrentCulture, ErrorMessageString, name);
+        }
+
+        public override bool IsValid(object value) {
+            return true;
+        }
+
+        public IEnumerable<ModelClientValidationRule> GetClientValidationRules(ModelMetadata metadata, ControllerContext context) {
+            yield return new ModelClientValidationRemoteRule(FormatErrorMessage(metadata.GetDisplayName()), GetUrl(context), HttpMethod, FormatAdditionalFieldsForClientValidation(metadata.PropertyName));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RequireHttpsAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/RequireHttpsAttribute.cs
new file mode 100644 (file)
index 0000000..723f1b6
--- /dev/null
@@ -0,0 +1,34 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web.Mvc.Resources;
+
+    [SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes", Justification = "Unsealed because type contains virtual extensibility points.")]
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
+    public class RequireHttpsAttribute : FilterAttribute, IAuthorizationFilter {
+
+        public virtual void OnAuthorization(AuthorizationContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            if (!filterContext.HttpContext.Request.IsSecureConnection) {
+                HandleNonHttpsRequest(filterContext);
+            }
+        }
+
+        protected virtual void HandleNonHttpsRequest(AuthorizationContext filterContext) {
+            // only redirect for GET requests, otherwise the browser might not propagate the verb and request
+            // body correctly.
+
+            if (!String.Equals(filterContext.HttpContext.Request.HttpMethod, "GET", StringComparison.OrdinalIgnoreCase)) {
+                throw new InvalidOperationException(MvcResources.RequireHttpsAttribute_MustUseSsl);
+            }
+
+            // redirect to HTTPS version of page
+            string url = "https://" + filterContext.HttpContext.Request.Url.Host + filterContext.HttpContext.Request.RawUrl;
+            filterContext.Result = new RedirectResult(url);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RequiredAttributeAdapter.cs b/mcs/class/System.Web.Mvc3/Mvc/RequiredAttributeAdapter.cs
new file mode 100644 (file)
index 0000000..458ad5b
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.ComponentModel.DataAnnotations;
+
+    public class RequiredAttributeAdapter : DataAnnotationsModelValidator<RequiredAttribute> {
+        public RequiredAttributeAdapter(ModelMetadata metadata, ControllerContext context, RequiredAttribute attribute)
+            : base(metadata, context, attribute) {
+        }
+
+        public override IEnumerable<ModelClientValidationRule> GetClientValidationRules() {
+            return new[] { new ModelClientValidationRequiredRule(ErrorMessage) };
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Resources/MvcResources.Designer.cs b/mcs/class/System.Web.Mvc3/Mvc/Resources/MvcResources.Designer.cs
new file mode 100644 (file)
index 0000000..b306729
--- /dev/null
@@ -0,0 +1,1022 @@
+//------------------------------------------------------------------------------
+// <auto-generated>
+//     This code was generated by a tool.
+//     Runtime Version:4.0.30319.1
+//
+//     Changes to this file may cause incorrect behavior and will be lost if
+//     the code is regenerated.
+// </auto-generated>
+//------------------------------------------------------------------------------
+
+namespace System.Web.Mvc.Resources {
+    using System;
+    
+    
+    /// <summary>
+    ///   A strongly-typed resource class, for looking up localized strings, etc.
+    /// </summary>
+    // This class was auto-generated by the StronglyTypedResourceBuilder
+    // class via a tool like ResGen or Visual Studio.
+    // To add or remove a member, edit your .ResX file then rerun ResGen
+    // with the /str option, or rebuild your VS project.
+    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
+    [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+    [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+    internal class MvcResources {
+        
+        private static global::System.Resources.ResourceManager resourceMan;
+        
+        private static global::System.Globalization.CultureInfo resourceCulture;
+        
+        [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
+        internal MvcResources() {
+        }
+        
+        /// <summary>
+        ///   Returns the cached ResourceManager instance used by this class.
+        /// </summary>
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+        internal static global::System.Resources.ResourceManager ResourceManager {
+            get {
+                if (object.ReferenceEquals(resourceMan, null)) {
+                    global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("System.Web.Mvc.Resources.MvcResources", typeof(MvcResources).Assembly);
+                    resourceMan = temp;
+                }
+                return resourceMan;
+            }
+        }
+        
+        /// <summary>
+        ///   Overrides the current thread's CurrentUICulture property for all
+        ///   resource lookups using this strongly typed resource class.
+        /// </summary>
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+        internal static global::System.Globalization.CultureInfo Culture {
+            get {
+                return resourceCulture;
+            }
+            set {
+                resourceCulture = value;
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The current request for action &apos;{0}&apos; on controller type &apos;{1}&apos; is ambiguous between the following action methods:{2}.
+        /// </summary>
+        internal static string ActionMethodSelector_AmbiguousMatch {
+            get {
+                return ResourceManager.GetString("ActionMethodSelector_AmbiguousMatch", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to {0} on type {1}.
+        /// </summary>
+        internal static string ActionMethodSelector_AmbiguousMatchType {
+            get {
+                return ResourceManager.GetString("ActionMethodSelector_AmbiguousMatchType", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Lookup for method &apos;{0}&apos; on controller type &apos;{1}&apos; failed because of an ambiguity between the following methods:{2}.
+        /// </summary>
+        internal static string AsyncActionMethodSelector_AmbiguousMethodMatch {
+            get {
+                return ResourceManager.GetString("AsyncActionMethodSelector_AmbiguousMethodMatch", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Could not locate a method named &apos;{0}&apos; on controller type {1}..
+        /// </summary>
+        internal static string AsyncActionMethodSelector_CouldNotFindMethod {
+            get {
+                return ResourceManager.GetString("AsyncActionMethodSelector_CouldNotFindMethod", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The provided IAsyncResult has already been consumed..
+        /// </summary>
+        internal static string AsyncCommon_AsyncResultAlreadyConsumed {
+            get {
+                return ResourceManager.GetString("AsyncCommon_AsyncResultAlreadyConsumed", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The controller of type &apos;{0}&apos; must subclass AsyncController or implement the IAsyncManagerContainer interface..
+        /// </summary>
+        internal static string AsyncCommon_ControllerMustImplementIAsyncManagerContainer {
+            get {
+                return ResourceManager.GetString("AsyncCommon_ControllerMustImplementIAsyncManagerContainer", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The provided IAsyncResult is not valid for this method..
+        /// </summary>
+        internal static string AsyncCommon_InvalidAsyncResult {
+            get {
+                return ResourceManager.GetString("AsyncCommon_InvalidAsyncResult", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The timeout value must be non-negative or Timeout.Infinite..
+        /// </summary>
+        internal static string AsyncCommon_InvalidTimeout {
+            get {
+                return ResourceManager.GetString("AsyncCommon_InvalidTimeout", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to AuthorizeAttribute cannot be used within a child action caching block..
+        /// </summary>
+        internal static string AuthorizeAttribute_CannotUseWithinChildActionCache {
+            get {
+                return ResourceManager.GetString("AuthorizeAttribute_CannotUseWithinChildActionCache", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The action &apos;{0}&apos; is accessible only by a child request..
+        /// </summary>
+        internal static string ChildActionOnlyAttribute_MustBeInChildRequest {
+            get {
+                return ResourceManager.GetString("ChildActionOnlyAttribute_MustBeInChildRequest", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The field {0} must be a number..
+        /// </summary>
+        internal static string ClientDataTypeModelValidatorProvider_FieldMustBeNumeric {
+            get {
+                return ResourceManager.GetString("ClientDataTypeModelValidatorProvider_FieldMustBeNumeric", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to No route in the route table matches the supplied values..
+        /// </summary>
+        internal static string Common_NoRouteMatched {
+            get {
+                return ResourceManager.GetString("Common_NoRouteMatched", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Value cannot be null or empty..
+        /// </summary>
+        internal static string Common_NullOrEmpty {
+            get {
+                return ResourceManager.GetString("Common_NullOrEmpty", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The partial view &apos;{0}&apos; was not found or no view engine supports the searched locations. The following locations were searched:{1}.
+        /// </summary>
+        internal static string Common_PartialViewNotFound {
+            get {
+                return ResourceManager.GetString("Common_PartialViewNotFound", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The property &apos;{0}&apos; cannot be null or empty..
+        /// </summary>
+        internal static string Common_PropertyCannotBeNullOrEmpty {
+            get {
+                return ResourceManager.GetString("Common_PropertyCannotBeNullOrEmpty", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The property {0}.{1} could not be found..
+        /// </summary>
+        internal static string Common_PropertyNotFound {
+            get {
+                return ResourceManager.GetString("Common_PropertyNotFound", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to False.
+        /// </summary>
+        internal static string Common_TriState_False {
+            get {
+                return ResourceManager.GetString("Common_TriState_False", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Not Set.
+        /// </summary>
+        internal static string Common_TriState_NotSet {
+            get {
+                return ResourceManager.GetString("Common_TriState_NotSet", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to True.
+        /// </summary>
+        internal static string Common_TriState_True {
+            get {
+                return ResourceManager.GetString("Common_TriState_True", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The type {0} must derive from {1}.
+        /// </summary>
+        internal static string Common_TypeMustDriveFromType {
+            get {
+                return ResourceManager.GetString("Common_TypeMustDriveFromType", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The value &apos;{0}&apos; is invalid..
+        /// </summary>
+        internal static string Common_ValueNotValidForProperty {
+            get {
+                return ResourceManager.GetString("Common_ValueNotValidForProperty", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The view &apos;{0}&apos; or its master was not found or no view engine supports the searched locations. The following locations were searched:{1}.
+        /// </summary>
+        internal static string Common_ViewNotFound {
+            get {
+                return ResourceManager.GetString("Common_ViewNotFound", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to &apos;{0}&apos; and &apos;{1}&apos; do not match..
+        /// </summary>
+        internal static string CompareAttribute_MustMatch {
+            get {
+                return ResourceManager.GetString("CompareAttribute_MustMatch", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Could not find a property named {0}..
+        /// </summary>
+        internal static string CompareAttribute_UnknownProperty {
+            get {
+                return ResourceManager.GetString("CompareAttribute_UnknownProperty", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to A public action method &apos;{0}&apos; was not found on controller &apos;{1}&apos;..
+        /// </summary>
+        internal static string Controller_UnknownAction {
+            get {
+                return ResourceManager.GetString("Controller_UnknownAction", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The model of type &apos;{0}&apos; could not be updated..
+        /// </summary>
+        internal static string Controller_UpdateModel_UpdateUnsuccessful {
+            get {
+                return ResourceManager.GetString("Controller_UpdateModel_UpdateUnsuccessful", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The model of type &apos;{0}&apos; is not valid..
+        /// </summary>
+        internal static string Controller_Validate_ValidationFailed {
+            get {
+                return ResourceManager.GetString("Controller_Validate_ValidationFailed", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Cannot execute Controller with a null HttpContext..
+        /// </summary>
+        internal static string ControllerBase_CannotExecuteWithNullHttpContext {
+            get {
+                return ResourceManager.GetString("ControllerBase_CannotExecuteWithNullHttpContext", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to A single instance of controller &apos;{0}&apos; cannot be used to handle multiple requests. If a custom controller factory is in use, make sure that it creates a new instance of the controller for each request..
+        /// </summary>
+        internal static string ControllerBase_CannotHandleMultipleRequests {
+            get {
+                return ResourceManager.GetString("ControllerBase_CannotHandleMultipleRequests", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to An error occurred when trying to create the IControllerFactory &apos;{0}&apos;. Make sure that the controller factory has a public parameterless constructor..
+        /// </summary>
+        internal static string ControllerBuilder_ErrorCreatingControllerFactory {
+            get {
+                return ResourceManager.GetString("ControllerBuilder_ErrorCreatingControllerFactory", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The IControllerFactory &apos;{0}&apos; did not return a controller for the name &apos;{1}&apos;..
+        /// </summary>
+        internal static string ControllerBuilder_FactoryReturnedNull {
+            get {
+                return ResourceManager.GetString("ControllerBuilder_FactoryReturnedNull", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The controller factory type &apos;{0}&apos; must implement the IControllerFactory interface..
+        /// </summary>
+        internal static string ControllerBuilder_MissingIControllerFactory {
+            get {
+                return ResourceManager.GetString("ControllerBuilder_MissingIControllerFactory", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The view found at &apos;{0}&apos; was not created..
+        /// </summary>
+        internal static string CshtmlView_ViewCouldNotBeCreated {
+            get {
+                return ResourceManager.GetString("CshtmlView_ViewCouldNotBeCreated", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The view at &apos;{0}&apos; must derive from WebViewPage, or WebViewPage&lt;TModel&gt;..
+        /// </summary>
+        internal static string CshtmlView_WrongViewBase {
+            get {
+                return ResourceManager.GetString("CshtmlView_WrongViewBase", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to {0} has a DisplayColumn attribute for {1}, but property {1} does not exist..
+        /// </summary>
+        internal static string DataAnnotationsModelMetadataProvider_UnknownProperty {
+            get {
+                return ResourceManager.GetString("DataAnnotationsModelMetadataProvider_UnknownProperty", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to {0} has a DisplayColumn attribute for {1}, but property {1} does not have a public getter..
+        /// </summary>
+        internal static string DataAnnotationsModelMetadataProvider_UnreadableProperty {
+            get {
+                return ResourceManager.GetString("DataAnnotationsModelMetadataProvider_UnreadableProperty", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The type {0} must have a public constructor which accepts three parameters of types {1}, {2}, and {3}.
+        /// </summary>
+        internal static string DataAnnotationsModelValidatorProvider_ConstructorRequirements {
+            get {
+                return ResourceManager.GetString("DataAnnotationsModelValidatorProvider_ConstructorRequirements", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The type {0} must have a public constructor which accepts two parameters of types {1} and {2}..
+        /// </summary>
+        internal static string DataAnnotationsModelValidatorProvider_ValidatableConstructorRequirements {
+            get {
+                return ResourceManager.GetString("DataAnnotationsModelValidatorProvider_ValidatableConstructorRequirements", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Multiple types were found that match the controller named &apos;{0}&apos;. This can happen if the route that services this request does not specify namespaces to search for a controller that matches the request. If this is the case, register this route by calling an overload of the &apos;MapRoute&apos; method that takes a &apos;namespaces&apos; parameter.
+        ///
+        ///The request for &apos;{0}&apos; has found the following matching controllers:{1}.
+        /// </summary>
+        internal static string DefaultControllerFactory_ControllerNameAmbiguous_WithoutRouteUrl {
+            get {
+                return ResourceManager.GetString("DefaultControllerFactory_ControllerNameAmbiguous_WithoutRouteUrl", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Multiple types were found that match the controller named &apos;{0}&apos;. This can happen if the route that services this request (&apos;{1}&apos;) does not specify namespaces to search for a controller that matches the request. If this is the case, register this route by calling an overload of the &apos;MapRoute&apos; method that takes a &apos;namespaces&apos; parameter.
+        ///
+        ///The request for &apos;{0}&apos; has found the following matching controllers:{2}.
+        /// </summary>
+        internal static string DefaultControllerFactory_ControllerNameAmbiguous_WithRouteUrl {
+            get {
+                return ResourceManager.GetString("DefaultControllerFactory_ControllerNameAmbiguous_WithRouteUrl", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to An error occurred when trying to create a controller of type &apos;{0}&apos;. Make sure that the controller has a parameterless public constructor..
+        /// </summary>
+        internal static string DefaultControllerFactory_ErrorCreatingController {
+            get {
+                return ResourceManager.GetString("DefaultControllerFactory_ErrorCreatingController", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The controller for path &apos;{0}&apos; was not found or does not implement IController..
+        /// </summary>
+        internal static string DefaultControllerFactory_NoControllerFound {
+            get {
+                return ResourceManager.GetString("DefaultControllerFactory_NoControllerFound", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The controller type &apos;{0}&apos; must implement IController..
+        /// </summary>
+        internal static string DefaultControllerFactory_TypeDoesNotSubclassControllerBase {
+            get {
+                return ResourceManager.GetString("DefaultControllerFactory_TypeDoesNotSubclassControllerBase", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The value &apos;{0}&apos; is not valid for {1}..
+        /// </summary>
+        internal static string DefaultModelBinder_ValueInvalid {
+            get {
+                return ResourceManager.GetString("DefaultModelBinder_ValueInvalid", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to A value is required..
+        /// </summary>
+        internal static string DefaultModelBinder_ValueRequired {
+            get {
+                return ResourceManager.GetString("DefaultModelBinder_ValueRequired", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The number of ticks for the TimeSpan value must be greater than or equal to 0..
+        /// </summary>
+        internal static string DefaultViewLocationCache_NegativeTimeSpan {
+            get {
+                return ResourceManager.GetString("DefaultViewLocationCache_NegativeTimeSpan", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The type {0} does not appear to implement Microsoft.Practices.ServiceLocation.IServiceLocator..
+        /// </summary>
+        internal static string DependencyResolver_DoesNotImplementICommonServiceLocator {
+            get {
+                return ResourceManager.GetString("DependencyResolver_DoesNotImplementICommonServiceLocator", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The type &apos;{0}&apos; does not inherit from Exception..
+        /// </summary>
+        internal static string ExceptionViewAttribute_NonExceptionType {
+            get {
+                return ResourceManager.GetString("ExceptionViewAttribute_NonExceptionType", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The expression compiler was unable to evaluate the indexer expression &apos;{0}&apos; because it references the model parameter &apos;{1}&apos; which is unavailable..
+        /// </summary>
+        internal static string ExpressionHelper_InvalidIndexerExpression {
+            get {
+                return ResourceManager.GetString("ExpressionHelper_InvalidIndexerExpression", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Order must be greater than or equal to -1..
+        /// </summary>
+        internal static string FilterAttribute_OrderOutOfRange {
+            get {
+                return ResourceManager.GetString("FilterAttribute_OrderOutOfRange", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The GET and POST HTTP methods are not supported..
+        /// </summary>
+        internal static string HtmlHelper_InvalidHttpMethod {
+            get {
+                return ResourceManager.GetString("HtmlHelper_InvalidHttpMethod", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The specified HttpVerbs value is not supported. The supported values are Delete, Head, and Put..
+        /// </summary>
+        internal static string HtmlHelper_InvalidHttpVerb {
+            get {
+                return ResourceManager.GetString("HtmlHelper_InvalidHttpVerb", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to There is no ViewData item of type &apos;{1}&apos; that has the key &apos;{0}&apos;..
+        /// </summary>
+        internal static string HtmlHelper_MissingSelectData {
+            get {
+                return ResourceManager.GetString("HtmlHelper_MissingSelectData", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The value must be greater than or equal to zero..
+        /// </summary>
+        internal static string HtmlHelper_TextAreaParameterOutOfRange {
+            get {
+                return ResourceManager.GetString("HtmlHelper_TextAreaParameterOutOfRange", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Validation parameter names in unobtrusive client validation rules cannot be empty. Client rule type: {0}.
+        /// </summary>
+        internal static string HtmlHelper_ValidationParameterCannotBeEmpty {
+            get {
+                return ResourceManager.GetString("HtmlHelper_ValidationParameterCannotBeEmpty", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Validation parameter names in unobtrusive client validation rules must start with a lowercase letter and consist of only lowercase letters or digits. Validation parameter name: {0}, client rule type: {1}.
+        /// </summary>
+        internal static string HtmlHelper_ValidationParameterMustBeLegal {
+            get {
+                return ResourceManager.GetString("HtmlHelper_ValidationParameterMustBeLegal", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Validation type names in unobtrusive client validation rules cannot be empty. Client rule type: {0}.
+        /// </summary>
+        internal static string HtmlHelper_ValidationTypeCannotBeEmpty {
+            get {
+                return ResourceManager.GetString("HtmlHelper_ValidationTypeCannotBeEmpty", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Validation type names in unobtrusive client validation rules must consist of only lowercase letters. Invalid name: &quot;{0}&quot;, client rule type: {1}.
+        /// </summary>
+        internal static string HtmlHelper_ValidationTypeMustBeLegal {
+            get {
+                return ResourceManager.GetString("HtmlHelper_ValidationTypeMustBeLegal", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Validation type names in unobtrusive client validation rules must be unique. The following validation type was seen more than once: {0}.
+        /// </summary>
+        internal static string HtmlHelper_ValidationTypeMustBeUnique {
+            get {
+                return ResourceManager.GetString("HtmlHelper_ValidationTypeMustBeUnique", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The ViewData item that has the key &apos;{0}&apos; is of type &apos;{1}&apos; but must be of type &apos;{2}&apos;..
+        /// </summary>
+        internal static string HtmlHelper_WrongSelectDataType {
+            get {
+                return ResourceManager.GetString("HtmlHelper_WrongSelectDataType", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to This request has been blocked because sensitive information could be disclosed to third party web sites when this is used in a GET request. To allow GET requests, set JsonRequestBehavior to AllowGet..
+        /// </summary>
+        internal static string JsonRequest_GetNotAllowed {
+            get {
+                return ResourceManager.GetString("JsonRequest_GetNotAllowed", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to An error occurred when trying to create the IModelBinder &apos;{0}&apos;. Make sure that the binder has a public parameterless constructor..
+        /// </summary>
+        internal static string ModelBinderAttribute_ErrorCreatingModelBinder {
+            get {
+                return ResourceManager.GetString("ModelBinderAttribute_ErrorCreatingModelBinder", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The type &apos;{0}&apos; does not implement the IModelBinder interface..
+        /// </summary>
+        internal static string ModelBinderAttribute_TypeNotIModelBinder {
+            get {
+                return ResourceManager.GetString("ModelBinderAttribute_TypeNotIModelBinder", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The type &apos;{0}&apos; contains multiple attributes that inherit from CustomModelBinderAttribute..
+        /// </summary>
+        internal static string ModelBinderDictionary_MultipleAttributes {
+            get {
+                return ResourceManager.GetString("ModelBinderDictionary_MultipleAttributes", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to This property setter is obsolete, because its value is derived from ModelMetadata.Model now..
+        /// </summary>
+        internal static string ModelMetadata_PropertyNotSettable {
+            get {
+                return ResourceManager.GetString("ModelMetadata_PropertyNotSettable", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The &apos;inherits&apos; keyword is not allowed when a &apos;{0}&apos; keyword is used..
+        /// </summary>
+        internal static string MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword {
+            get {
+                return ResourceManager.GetString("MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The &apos;{0}&apos; keyword must be followed by a type name on the same line..
+        /// </summary>
+        internal static string MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName {
+            get {
+                return ResourceManager.GetString("MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Only one &apos;{0}&apos; statement is allowed in a file..
+        /// </summary>
+        internal static string MvcRazorCodeParser_OnlyOneModelStatementIsAllowed {
+            get {
+                return ResourceManager.GetString("MvcRazorCodeParser_OnlyOneModelStatementIsAllowed", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to OutputCacheAttribute is not allowed on child actions which are children of an already cached child action..
+        /// </summary>
+        internal static string OutputCacheAttribute_CannotNestChildCache {
+            get {
+                return ResourceManager.GetString("OutputCacheAttribute_CannotNestChildCache", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to OutputCacheAttribute for child actions only supports Duration, VaryByCustom, and VaryByParam values. Please do not set CacheProfile, Location, NoStore, SqlDependency, VaryByContentEncoding, or VaryByHeader values for child actions..
+        /// </summary>
+        internal static string OutputCacheAttribute_ChildAction_UnsupportedSetting {
+            get {
+                return ResourceManager.GetString("OutputCacheAttribute_ChildAction_UnsupportedSetting", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Duration must be a positive number..
+        /// </summary>
+        internal static string OutputCacheAttribute_InvalidDuration {
+            get {
+                return ResourceManager.GetString("OutputCacheAttribute_InvalidDuration", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to VaryByParam must be &apos;*&apos;, &apos;none&apos;, or a semicolon-delimited list of keys..
+        /// </summary>
+        internal static string OutputCacheAttribute_InvalidVaryByParam {
+            get {
+                return ResourceManager.GetString("OutputCacheAttribute_InvalidVaryByParam", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The associated metadata type for type &apos;{0}&apos; contains the following unknown properties or fields: {1}. Please make sure that the names of these members match the names of the properties on the main type..
+        /// </summary>
+        internal static string PrivateAssociatedMetadataTypeTypeDescriptor_MetadataTypeContainsUnknownProperties {
+            get {
+                return ResourceManager.GetString("PrivateAssociatedMetadataTypeTypeDescriptor_MetadataTypeContainsUnknownProperties" +
+                        "", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Child actions are not allowed to perform redirect actions..
+        /// </summary>
+        internal static string RedirectAction_CannotRedirectInChildAction {
+            get {
+                return ResourceManager.GetString("RedirectAction_CannotRedirectInChildAction", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Cannot create a descriptor for instance method &apos;{0}&apos; on type &apos;{1}&apos; because the type does not derive from ControllerBase..
+        /// </summary>
+        internal static string ReflectedActionDescriptor_CannotCallInstanceMethodOnNonControllerType {
+            get {
+                return ResourceManager.GetString("ReflectedActionDescriptor_CannotCallInstanceMethodOnNonControllerType", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Cannot call action method &apos;{0}&apos; on controller &apos;{1}&apos; because the parameter &apos;{2}&apos; is passed by reference..
+        /// </summary>
+        internal static string ReflectedActionDescriptor_CannotCallMethodsWithOutOrRefParameters {
+            get {
+                return ResourceManager.GetString("ReflectedActionDescriptor_CannotCallMethodsWithOutOrRefParameters", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Cannot call action method &apos;{0}&apos; on controller &apos;{1}&apos; because the action method is a generic method..
+        /// </summary>
+        internal static string ReflectedActionDescriptor_CannotCallOpenGenericMethods {
+            get {
+                return ResourceManager.GetString("ReflectedActionDescriptor_CannotCallOpenGenericMethods", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Cannot call action method &apos;{0}&apos; on controller &apos;{1}&apos; because the action method is a static method..
+        /// </summary>
+        internal static string ReflectedActionDescriptor_CannotCallStaticMethod {
+            get {
+                return ResourceManager.GetString("ReflectedActionDescriptor_CannotCallStaticMethod", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The parameters dictionary contains a null entry for parameter &apos;{0}&apos; of non-nullable type &apos;{1}&apos; for method &apos;{2}&apos; in &apos;{3}&apos;. An optional parameter must be a reference type, a nullable type, or be declared as an optional parameter..
+        /// </summary>
+        internal static string ReflectedActionDescriptor_ParameterCannotBeNull {
+            get {
+                return ResourceManager.GetString("ReflectedActionDescriptor_ParameterCannotBeNull", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The parameters dictionary does not contain an entry for parameter &apos;{0}&apos; of type &apos;{1}&apos; for method &apos;{2}&apos; in &apos;{3}&apos;. The dictionary must contain an entry for each parameter, including parameters that have null values..
+        /// </summary>
+        internal static string ReflectedActionDescriptor_ParameterNotInDictionary {
+            get {
+                return ResourceManager.GetString("ReflectedActionDescriptor_ParameterNotInDictionary", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The parameters dictionary contains an invalid entry for parameter &apos;{0}&apos; for method &apos;{1}&apos; in &apos;{2}&apos;. The dictionary contains a value of type &apos;{3}&apos;, but the parameter requires a value of type &apos;{4}&apos;..
+        /// </summary>
+        internal static string ReflectedActionDescriptor_ParameterValueHasWrongType {
+            get {
+                return ResourceManager.GetString("ReflectedActionDescriptor_ParameterValueHasWrongType", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The asynchronous action method &apos;{0}&apos; cannot be executed synchronously..
+        /// </summary>
+        internal static string ReflectedAsyncActionDescriptor_CannotExecuteSynchronously {
+            get {
+                return ResourceManager.GetString("ReflectedAsyncActionDescriptor_CannotExecuteSynchronously", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The parameter &apos;{0}&apos; on method &apos;{1}&apos; contains multiple attributes that inherit from CustomModelBinderAttribute..
+        /// </summary>
+        internal static string ReflectedParameterBindingInfo_MultipleConverterAttributes {
+            get {
+                return ResourceManager.GetString("ReflectedParameterBindingInfo_MultipleConverterAttributes", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to No url for remote validation could be found..
+        /// </summary>
+        internal static string RemoteAttribute_NoUrlFound {
+            get {
+                return ResourceManager.GetString("RemoteAttribute_NoUrlFound", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to &apos;{0}&apos; is invalid..
+        /// </summary>
+        internal static string RemoteAttribute_RemoteValidationFailed {
+            get {
+                return ResourceManager.GetString("RemoteAttribute_RemoteValidationFailed", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The requested resource can only be accessed via SSL..
+        /// </summary>
+        internal static string RequireHttpsAttribute_MustUseSsl {
+            get {
+                return ResourceManager.GetString("RequireHttpsAttribute_MustUseSsl", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The SessionStateTempDataProvider class requires session state to be enabled..
+        /// </summary>
+        internal static string SessionStateTempDataProvider_SessionStateDisabled {
+            get {
+                return ResourceManager.GetString("SessionStateTempDataProvider_SessionStateDisabled", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to An instance of {0} was found in the resolver as well as a custom registered provider in {1}. Please set only one or the other..
+        /// </summary>
+        internal static string SingleServiceResolver_CannotRegisterTwoInstances {
+            get {
+                return ResourceManager.GetString("SingleServiceResolver_CannotRegisterTwoInstances", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to An operation that crossed a synchronization context failed. See the inner exception for more information..
+        /// </summary>
+        internal static string SynchronizationContextUtil_ExceptionThrown {
+            get {
+                return ResourceManager.GetString("SynchronizationContextUtil_ExceptionThrown", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Unable to locate an appropriate template for type {0}..
+        /// </summary>
+        internal static string TemplateHelpers_NoTemplate {
+            get {
+                return ResourceManager.GetString("TemplateHelpers_NoTemplate", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Templates can be used only with field access, property access, single-dimension array index, or single-parameter custom indexer expressions..
+        /// </summary>
+        internal static string TemplateHelpers_TemplateLimitations {
+            get {
+                return ResourceManager.GetString("TemplateHelpers_TemplateLimitations", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The Collection template was used with an object of type &apos;{0}&apos;, which does not implement System.IEnumerable..
+        /// </summary>
+        internal static string Templates_TypeMustImplementIEnumerable {
+            get {
+                return ResourceManager.GetString("Templates_TypeMustImplementIEnumerable", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to This file is automatically generated. Please do not modify the contents of this file..
+        /// </summary>
+        internal static string TypeCache_DoNotModify {
+            get {
+                return ResourceManager.GetString("TypeCache_DoNotModify", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The model object inside the metadata claimed to be compatible with {0}, but was actually {1}..
+        /// </summary>
+        internal static string ValidatableObjectAdapter_IncompatibleType {
+            get {
+                return ResourceManager.GetString("ValidatableObjectAdapter_IncompatibleType", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The parameter conversion from type &apos;{0}&apos; to type &apos;{1}&apos; failed. See the inner exception for more information..
+        /// </summary>
+        internal static string ValueProviderResult_ConversionThrew {
+            get {
+                return ResourceManager.GetString("ValueProviderResult_ConversionThrew", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The parameter conversion from type &apos;{0}&apos; to type &apos;{1}&apos; failed because no type converter can convert between these types..
+        /// </summary>
+        internal static string ValueProviderResult_NoConverterExists {
+            get {
+                return ResourceManager.GetString("ValueProviderResult_NoConverterExists", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The model item passed into the dictionary is null, but this dictionary requires a non-null model item of type &apos;{0}&apos;..
+        /// </summary>
+        internal static string ViewDataDictionary_ModelCannotBeNull {
+            get {
+                return ResourceManager.GetString("ViewDataDictionary_ModelCannotBeNull", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The model item passed into the dictionary is of type &apos;{0}&apos;, but this dictionary requires a model item of type &apos;{1}&apos;..
+        /// </summary>
+        internal static string ViewDataDictionary_WrongTModelType {
+            get {
+                return ResourceManager.GetString("ViewDataDictionary_WrongTModelType", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to A ViewMasterPage can be used only with content pages that derive from ViewPage or ViewPage&lt;TModel&gt;..
+        /// </summary>
+        internal static string ViewMasterPage_RequiresViewPage {
+            get {
+                return ResourceManager.GetString("ViewMasterPage_RequiresViewPage", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to Execution of the child request failed. Please examine the InnerException for more information..
+        /// </summary>
+        internal static string ViewPageHttpHandlerWrapper_ExceptionOccurred {
+            get {
+                return ResourceManager.GetString("ViewPageHttpHandlerWrapper_ExceptionOccurred", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to A ViewStartPage can be used only with with a page that derives from WebViewPage or another ViewStartPage..
+        /// </summary>
+        internal static string ViewStartPage_RequiresMvcRazorView {
+            get {
+                return ResourceManager.GetString("ViewStartPage_RequiresMvcRazorView", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The ViewUserControl &apos;{0}&apos; cannot find an IViewDataContainer object. The ViewUserControl must be inside a ViewPage, a ViewMasterPage, or another ViewUserControl..
+        /// </summary>
+        internal static string ViewUserControl_RequiresViewDataProvider {
+            get {
+                return ResourceManager.GetString("ViewUserControl_RequiresViewDataProvider", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to A ViewUserControl can be used only in pages that derive from ViewPage or ViewPage&lt;TModel&gt;..
+        /// </summary>
+        internal static string ViewUserControl_RequiresViewPage {
+            get {
+                return ResourceManager.GetString("ViewUserControl_RequiresViewPage", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to A master name cannot be specified when the view is a ViewUserControl..
+        /// </summary>
+        internal static string WebFormViewEngine_UserControlCannotHaveMaster {
+            get {
+                return ResourceManager.GetString("WebFormViewEngine_UserControlCannotHaveMaster", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The view found at &apos;{0}&apos; was not created..
+        /// </summary>
+        internal static string WebFormViewEngine_ViewCouldNotBeCreated {
+            get {
+                return ResourceManager.GetString("WebFormViewEngine_ViewCouldNotBeCreated", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   Looks up a localized string similar to The view at &apos;{0}&apos; must derive from ViewPage, ViewPage&lt;TModel&gt;, ViewUserControl, or ViewUserControl&lt;TModel&gt;..
+        /// </summary>
+        internal static string WebFormViewEngine_WrongViewBase {
+            get {
+                return ResourceManager.GetString("WebFormViewEngine_WrongViewBase", resourceCulture);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/Resources/MvcResources.resx b/mcs/class/System.Web.Mvc3/Mvc/Resources/MvcResources.resx
new file mode 100644 (file)
index 0000000..32fb5f8
--- /dev/null
@@ -0,0 +1,442 @@
+<?xml version="1.0" encoding="utf-8"?>
+<root>
+  <!-- 
+    Microsoft ResX Schema 
+    
+    Version 2.0
+    
+    The primary goals of this format is to allow a simple XML format 
+    that is mostly human readable. The generation and parsing of the 
+    various data types are done through the TypeConverter classes 
+    associated with the data types.
+    
+    Example:
+    
+    ... ado.net/XML headers & schema ...
+    <resheader name="resmimetype">text/microsoft-resx</resheader>
+    <resheader name="version">2.0</resheader>
+    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
+    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+        <value>[base64 mime encoded serialized .NET Framework object]</value>
+    </data>
+    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+        <comment>This is a comment</comment>
+    </data>
+                
+    There are any number of "resheader" rows that contain simple 
+    name/value pairs.
+    
+    Each data row contains a name, and value. The row also contains a 
+    type or mimetype. Type corresponds to a .NET class that support 
+    text/value conversion through the TypeConverter architecture. 
+    Classes that don't support this are serialized and stored with the 
+    mimetype set.
+    
+    The mimetype is used for serialized objects, and tells the 
+    ResXResourceReader how to depersist the object. This is currently not 
+    extensible. For a given mimetype the value must be set accordingly:
+    
+    Note - application/x-microsoft.net.object.binary.base64 is the format 
+    that the ResXResourceWriter will generate, however the reader can 
+    read any of the formats listed below.
+    
+    mimetype: application/x-microsoft.net.object.binary.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
+            : and then encoded with base64 encoding.
+    
+    mimetype: application/x-microsoft.net.object.soap.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+            : and then encoded with base64 encoding.
+
+    mimetype: application/x-microsoft.net.object.bytearray.base64
+    value   : The object must be serialized into a byte array 
+            : using a System.ComponentModel.TypeConverter
+            : and then encoded with base64 encoding.
+    -->
+  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
+    <xsd:element name="root" msdata:IsDataSet="true">
+      <xsd:complexType>
+        <xsd:choice maxOccurs="unbounded">
+          <xsd:element name="metadata">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" />
+              </xsd:sequence>
+              <xsd:attribute name="name" use="required" type="xsd:string" />
+              <xsd:attribute name="type" type="xsd:string" />
+              <xsd:attribute name="mimetype" type="xsd:string" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="assembly">
+            <xsd:complexType>
+              <xsd:attribute name="alias" type="xsd:string" />
+              <xsd:attribute name="name" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="data">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
+              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="resheader">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" />
+            </xsd:complexType>
+          </xsd:element>
+        </xsd:choice>
+      </xsd:complexType>
+    </xsd:element>
+  </xsd:schema>
+  <resheader name="resmimetype">
+    <value>text/microsoft-resx</value>
+  </resheader>
+  <resheader name="version">
+    <value>2.0</value>
+  </resheader>
+  <resheader name="reader">
+    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <resheader name="writer">
+    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <data name="ActionMethodSelector_AmbiguousMatch" xml:space="preserve">
+    <value>The current request for action '{0}' on controller type '{1}' is ambiguous between the following action methods:{2}</value>
+  </data>
+  <data name="Common_NoRouteMatched" xml:space="preserve">
+    <value>No route in the route table matches the supplied values.</value>
+  </data>
+  <data name="Common_NullOrEmpty" xml:space="preserve">
+    <value>Value cannot be null or empty.</value>
+  </data>
+  <data name="Common_PartialViewNotFound" xml:space="preserve">
+    <value>The partial view '{0}' was not found or no view engine supports the searched locations. The following locations were searched:{1}</value>
+  </data>
+  <data name="Common_PropertyCannotBeNullOrEmpty" xml:space="preserve">
+    <value>The property '{0}' cannot be null or empty.</value>
+  </data>
+  <data name="Common_ViewNotFound" xml:space="preserve">
+    <value>The view '{0}' or its master was not found or no view engine supports the searched locations. The following locations were searched:{1}</value>
+  </data>
+  <data name="ControllerBuilder_ErrorCreatingControllerFactory" xml:space="preserve">
+    <value>An error occurred when trying to create the IControllerFactory '{0}'. Make sure that the controller factory has a public parameterless constructor.</value>
+  </data>
+  <data name="ControllerBuilder_FactoryReturnedNull" xml:space="preserve">
+    <value>The IControllerFactory '{0}' did not return a controller for the name '{1}'.</value>
+  </data>
+  <data name="ControllerBuilder_MissingIControllerFactory" xml:space="preserve">
+    <value>The controller factory type '{0}' must implement the IControllerFactory interface.</value>
+  </data>
+  <data name="Controller_UnknownAction" xml:space="preserve">
+    <value>A public action method '{0}' was not found on controller '{1}'.</value>
+  </data>
+  <data name="DefaultControllerFactory_ErrorCreatingController" xml:space="preserve">
+    <value>An error occurred when trying to create a controller of type '{0}'. Make sure that the controller has a parameterless public constructor.</value>
+  </data>
+  <data name="DefaultControllerFactory_NoControllerFound" xml:space="preserve">
+    <value>The controller for path '{0}' was not found or does not implement IController.</value>
+  </data>
+  <data name="DefaultControllerFactory_TypeDoesNotSubclassControllerBase" xml:space="preserve">
+    <value>The controller type '{0}' must implement IController.</value>
+  </data>
+  <data name="ValueProviderResult_ConversionThrew" xml:space="preserve">
+    <value>The parameter conversion from type '{0}' to type '{1}' failed. See the inner exception for more information.</value>
+  </data>
+  <data name="ValueProviderResult_NoConverterExists" xml:space="preserve">
+    <value>The parameter conversion from type '{0}' to type '{1}' failed because no type converter can convert between these types.</value>
+  </data>
+  <data name="ExceptionViewAttribute_NonExceptionType" xml:space="preserve">
+    <value>The type '{0}' does not inherit from Exception.</value>
+  </data>
+  <data name="FilterAttribute_OrderOutOfRange" xml:space="preserve">
+    <value>Order must be greater than or equal to -1.</value>
+  </data>
+  <data name="HtmlHelper_MissingSelectData" xml:space="preserve">
+    <value>There is no ViewData item of type '{1}' that has the key '{0}'.</value>
+  </data>
+  <data name="HtmlHelper_TextAreaParameterOutOfRange" xml:space="preserve">
+    <value>The value must be greater than or equal to zero.</value>
+  </data>
+  <data name="HtmlHelper_WrongSelectDataType" xml:space="preserve">
+    <value>The ViewData item that has the key '{0}' is of type '{1}' but must be of type '{2}'.</value>
+  </data>
+  <data name="ModelBinderAttribute_ErrorCreatingModelBinder" xml:space="preserve">
+    <value>An error occurred when trying to create the IModelBinder '{0}'. Make sure that the binder has a public parameterless constructor.</value>
+  </data>
+  <data name="ModelBinderAttribute_TypeNotIModelBinder" xml:space="preserve">
+    <value>The type '{0}' does not implement the IModelBinder interface.</value>
+  </data>
+  <data name="ModelBinderDictionary_MultipleAttributes" xml:space="preserve">
+    <value>The type '{0}' contains multiple attributes that inherit from CustomModelBinderAttribute.</value>
+  </data>
+  <data name="SessionStateTempDataProvider_SessionStateDisabled" xml:space="preserve">
+    <value>The SessionStateTempDataProvider class requires session state to be enabled.</value>
+  </data>
+  <data name="ViewDataDictionary_WrongTModelType" xml:space="preserve">
+    <value>The model item passed into the dictionary is of type '{0}', but this dictionary requires a model item of type '{1}'.</value>
+  </data>
+  <data name="ViewMasterPage_RequiresViewPage" xml:space="preserve">
+    <value>A ViewMasterPage can be used only with content pages that derive from ViewPage or ViewPage&lt;TModel&gt;.</value>
+  </data>
+  <data name="ViewUserControl_RequiresViewDataProvider" xml:space="preserve">
+    <value>The ViewUserControl '{0}' cannot find an IViewDataContainer object. The ViewUserControl must be inside a ViewPage, a ViewMasterPage, or another ViewUserControl.</value>
+  </data>
+  <data name="ViewUserControl_RequiresViewPage" xml:space="preserve">
+    <value>A ViewUserControl can be used only in pages that derive from ViewPage or ViewPage&lt;TModel&gt;.</value>
+  </data>
+  <data name="WebFormViewEngine_UserControlCannotHaveMaster" xml:space="preserve">
+    <value>A master name cannot be specified when the view is a ViewUserControl.</value>
+  </data>
+  <data name="WebFormViewEngine_ViewCouldNotBeCreated" xml:space="preserve">
+    <value>The view found at '{0}' was not created.</value>
+  </data>
+  <data name="WebFormViewEngine_WrongViewBase" xml:space="preserve">
+    <value>The view at '{0}' must derive from ViewPage, ViewPage&lt;TModel&gt;, ViewUserControl, or ViewUserControl&lt;TModel&gt;.</value>
+  </data>
+  <data name="Common_ValueNotValidForProperty" xml:space="preserve">
+    <value>The value '{0}' is invalid.</value>
+  </data>
+  <data name="ActionMethodSelector_AmbiguousMatchType" xml:space="preserve">
+    <value>{0} on type {1}</value>
+  </data>
+  <data name="Controller_UpdateModel_UpdateUnsuccessful" xml:space="preserve">
+    <value>The model of type '{0}' could not be updated.</value>
+  </data>
+  <data name="DefaultModelBinder_ValueRequired" xml:space="preserve">
+    <value>A value is required.</value>
+  </data>
+  <data name="ReflectedActionDescriptor_ParameterCannotBeNull" xml:space="preserve">
+    <value>The parameters dictionary contains a null entry for parameter '{0}' of non-nullable type '{1}' for method '{2}' in '{3}'. An optional parameter must be a reference type, a nullable type, or be declared as an optional parameter.</value>
+  </data>
+  <data name="ReflectedActionDescriptor_ParameterNotInDictionary" xml:space="preserve">
+    <value>The parameters dictionary does not contain an entry for parameter '{0}' of type '{1}' for method '{2}' in '{3}'. The dictionary must contain an entry for each parameter, including parameters that have null values.</value>
+  </data>
+  <data name="ReflectedActionDescriptor_ParameterValueHasWrongType" xml:space="preserve">
+    <value>The parameters dictionary contains an invalid entry for parameter '{0}' for method '{1}' in '{2}'. The dictionary contains a value of type '{3}', but the parameter requires a value of type '{4}'.</value>
+  </data>
+  <data name="ReflectedParameterBindingInfo_MultipleConverterAttributes" xml:space="preserve">
+    <value>The parameter '{0}' on method '{1}' contains multiple attributes that inherit from CustomModelBinderAttribute.</value>
+  </data>
+  <data name="ReflectedActionDescriptor_CannotCallInstanceMethodOnNonControllerType" xml:space="preserve">
+    <value>Cannot create a descriptor for instance method '{0}' on type '{1}' because the type does not derive from ControllerBase.</value>
+  </data>
+  <data name="ReflectedActionDescriptor_CannotCallMethodsWithOutOrRefParameters" xml:space="preserve">
+    <value>Cannot call action method '{0}' on controller '{1}' because the parameter '{2}' is passed by reference.</value>
+  </data>
+  <data name="ReflectedActionDescriptor_CannotCallOpenGenericMethods" xml:space="preserve">
+    <value>Cannot call action method '{0}' on controller '{1}' because the action method is a generic method.</value>
+  </data>
+  <data name="DefaultViewLocationCache_NegativeTimeSpan" xml:space="preserve">
+    <value>The number of ticks for the TimeSpan value must be greater than or equal to 0.</value>
+  </data>
+  <data name="DefaultModelBinder_ValueInvalid" xml:space="preserve">
+    <value>The value '{0}' is not valid for {1}.</value>
+  </data>
+  <data name="TemplateHelpers_TemplateLimitations" xml:space="preserve">
+    <value>Templates can be used only with field access, property access, single-dimension array index, or single-parameter custom indexer expressions.</value>
+  </data>
+  <data name="Common_TriState_False" xml:space="preserve">
+    <value>False</value>
+  </data>
+  <data name="Common_TriState_NotSet" xml:space="preserve">
+    <value>Not Set</value>
+  </data>
+  <data name="Common_TriState_True" xml:space="preserve">
+    <value>True</value>
+  </data>
+  <data name="ControllerBase_CannotHandleMultipleRequests" xml:space="preserve">
+    <value>A single instance of controller '{0}' cannot be used to handle multiple requests. If a custom controller factory is in use, make sure that it creates a new instance of the controller for each request.</value>
+  </data>
+  <data name="Common_PropertyNotFound" xml:space="preserve">
+    <value>The property {0}.{1} could not be found.</value>
+  </data>
+  <data name="DataAnnotationsModelMetadataProvider_UnknownProperty" xml:space="preserve">
+    <value>{0} has a DisplayColumn attribute for {1}, but property {1} does not exist.</value>
+  </data>
+  <data name="DataAnnotationsModelMetadataProvider_UnreadableProperty" xml:space="preserve">
+    <value>{0} has a DisplayColumn attribute for {1}, but property {1} does not have a public getter.</value>
+  </data>
+  <data name="TemplateHelpers_NoTemplate" xml:space="preserve">
+    <value>Unable to locate an appropriate template for type {0}.</value>
+  </data>
+  <data name="RequireHttpsAttribute_MustUseSsl" xml:space="preserve">
+    <value>The requested resource can only be accessed via SSL.</value>
+  </data>
+  <data name="HtmlHelper_InvalidHttpVerb" xml:space="preserve">
+    <value>The specified HttpVerbs value is not supported. The supported values are Delete, Head, and Put.</value>
+  </data>
+  <data name="HtmlHelper_InvalidHttpMethod" xml:space="preserve">
+    <value>The GET and POST HTTP methods are not supported.</value>
+  </data>
+  <data name="JsonRequest_GetNotAllowed" xml:space="preserve">
+    <value>This request has been blocked because sensitive information could be disclosed to third party web sites when this is used in a GET request. To allow GET requests, set JsonRequestBehavior to AllowGet.</value>
+  </data>
+  <data name="ModelMetadata_PropertyNotSettable" xml:space="preserve">
+    <value>This property setter is obsolete, because its value is derived from ModelMetadata.Model now.</value>
+  </data>
+  <data name="ViewDataDictionary_ModelCannotBeNull" xml:space="preserve">
+    <value>The model item passed into the dictionary is null, but this dictionary requires a non-null model item of type '{0}'.</value>
+  </data>
+  <data name="Common_TypeMustDriveFromType" xml:space="preserve">
+    <value>The type {0} must derive from {1}</value>
+  </data>
+  <data name="DataAnnotationsModelValidatorProvider_ConstructorRequirements" xml:space="preserve">
+    <value>The type {0} must have a public constructor which accepts three parameters of types {1}, {2}, and {3}</value>
+  </data>
+  <data name="ViewPageHttpHandlerWrapper_ExceptionOccurred" xml:space="preserve">
+    <value>Execution of the child request failed. Please examine the InnerException for more information.</value>
+  </data>
+  <data name="RedirectAction_CannotRedirectInChildAction" xml:space="preserve">
+    <value>Child actions are not allowed to perform redirect actions.</value>
+  </data>
+  <data name="AsyncCommon_AsyncResultAlreadyConsumed" xml:space="preserve">
+    <value>The provided IAsyncResult has already been consumed.</value>
+  </data>
+  <data name="AsyncCommon_InvalidAsyncResult" xml:space="preserve">
+    <value>The provided IAsyncResult is not valid for this method.</value>
+  </data>
+  <data name="SynchronizationContextUtil_ExceptionThrown" xml:space="preserve">
+    <value>An operation that crossed a synchronization context failed. See the inner exception for more information.</value>
+  </data>
+  <data name="ReflectedAsyncActionDescriptor_CannotExecuteSynchronously" xml:space="preserve">
+    <value>The asynchronous action method '{0}' cannot be executed synchronously.</value>
+  </data>
+  <data name="AsyncCommon_ControllerMustImplementIAsyncManagerContainer" xml:space="preserve">
+    <value>The controller of type '{0}' must subclass AsyncController or implement the IAsyncManagerContainer interface.</value>
+  </data>
+  <data name="AsyncCommon_InvalidTimeout" xml:space="preserve">
+    <value>The timeout value must be non-negative or Timeout.Infinite.</value>
+  </data>
+  <data name="AsyncActionMethodSelector_AmbiguousMethodMatch" xml:space="preserve">
+    <value>Lookup for method '{0}' on controller type '{1}' failed because of an ambiguity between the following methods:{2}</value>
+  </data>
+  <data name="AsyncActionMethodSelector_CouldNotFindMethod" xml:space="preserve">
+    <value>Could not locate a method named '{0}' on controller type {1}.</value>
+  </data>
+  <data name="ChildActionOnlyAttribute_MustBeInChildRequest" xml:space="preserve">
+    <value>The action '{0}' is accessible only by a child request.</value>
+  </data>
+  <data name="Templates_TypeMustImplementIEnumerable" xml:space="preserve">
+    <value>The Collection template was used with an object of type '{0}', which does not implement System.IEnumerable.</value>
+  </data>
+  <data name="TypeCache_DoNotModify" xml:space="preserve">
+    <value>This file is automatically generated. Please do not modify the contents of this file.</value>
+  </data>
+  <data name="PrivateAssociatedMetadataTypeTypeDescriptor_MetadataTypeContainsUnknownProperties" xml:space="preserve">
+    <value>The associated metadata type for type '{0}' contains the following unknown properties or fields: {1}. Please make sure that the names of these members match the names of the properties on the main type.</value>
+  </data>
+  <data name="ClientDataTypeModelValidatorProvider_FieldMustBeNumeric" xml:space="preserve">
+    <value>The field {0} must be a number.</value>
+  </data>
+  <data name="ExpressionHelper_InvalidIndexerExpression" xml:space="preserve">
+    <value>The expression compiler was unable to evaluate the indexer expression '{0}' because it references the model parameter '{1}' which is unavailable.</value>
+  </data>
+  <data name="Controller_Validate_ValidationFailed" xml:space="preserve">
+    <value>The model of type '{0}' is not valid.</value>
+  </data>
+  <data name="DefaultControllerFactory_ControllerNameAmbiguous_WithoutRouteUrl" xml:space="preserve">
+    <value>Multiple types were found that match the controller named '{0}'. This can happen if the route that services this request does not specify namespaces to search for a controller that matches the request. If this is the case, register this route by calling an overload of the 'MapRoute' method that takes a 'namespaces' parameter.
+
+The request for '{0}' has found the following matching controllers:{1}</value>
+  </data>
+  <data name="DefaultControllerFactory_ControllerNameAmbiguous_WithRouteUrl" xml:space="preserve">
+    <value>Multiple types were found that match the controller named '{0}'. This can happen if the route that services this request ('{1}') does not specify namespaces to search for a controller that matches the request. If this is the case, register this route by calling an overload of the 'MapRoute' method that takes a 'namespaces' parameter.
+
+The request for '{0}' has found the following matching controllers:{2}</value>
+  </data>
+  <data name="DataAnnotationsModelValidatorProvider_ValidatableConstructorRequirements" xml:space="preserve">
+    <value>The type {0} must have a public constructor which accepts two parameters of types {1} and {2}.</value>
+  </data>
+  <data name="ValidatableObjectAdapter_IncompatibleType" xml:space="preserve">
+    <value>The model object inside the metadata claimed to be compatible with {0}, but was actually {1}.</value>
+  </data>
+  <data name="CshtmlView_ViewCouldNotBeCreated" xml:space="preserve">
+    <value>The view found at '{0}' was not created.</value>
+  </data>
+  <data name="CshtmlView_WrongViewBase" xml:space="preserve">
+    <value>The view at '{0}' must derive from WebViewPage, or WebViewPage&lt;TModel&gt;.</value>
+  </data>
+  <data name="ReflectedActionDescriptor_CannotCallStaticMethod" xml:space="preserve">
+    <value>Cannot call action method '{0}' on controller '{1}' because the action method is a static method.</value>
+  </data>
+  <data name="MvcRazorCodeParser_ModelKeywordMustBeFollowedByTypeName" xml:space="preserve">
+    <value>The '{0}' keyword must be followed by a type name on the same line.</value>
+  </data>
+  <data name="MvcRazorCodeParser_CannotHaveModelAndInheritsKeyword" xml:space="preserve">
+    <value>The 'inherits' keyword is not allowed when a '{0}' keyword is used.</value>
+  </data>
+  <data name="MvcRazorCodeParser_OnlyOneModelStatementIsAllowed" xml:space="preserve">
+    <value>Only one '{0}' statement is allowed in a file.</value>
+  </data>
+  <data name="SingleServiceResolver_CannotRegisterTwoInstances" xml:space="preserve">
+    <value>An instance of {0} was found in the resolver as well as a custom registered provider in {1}. Please set only one or the other.</value>
+  </data>
+  <data name="DependencyResolver_DoesNotImplementICommonServiceLocator" xml:space="preserve">
+    <value>The type {0} does not appear to implement Microsoft.Practices.ServiceLocation.IServiceLocator.</value>
+  </data>
+  <data name="HtmlHelper_ValidationTypeCannotBeEmpty" xml:space="preserve">
+    <value>Validation type names in unobtrusive client validation rules cannot be empty. Client rule type: {0}</value>
+  </data>
+  <data name="HtmlHelper_ValidationTypeMustBeUnique" xml:space="preserve">
+    <value>Validation type names in unobtrusive client validation rules must be unique. The following validation type was seen more than once: {0}</value>
+  </data>
+  <data name="HtmlHelper_ValidationTypeMustBeLegal" xml:space="preserve">
+    <value>Validation type names in unobtrusive client validation rules must consist of only lowercase letters. Invalid name: "{0}", client rule type: {1}</value>
+  </data>
+  <data name="HtmlHelper_ValidationParameterCannotBeEmpty" xml:space="preserve">
+    <value>Validation parameter names in unobtrusive client validation rules cannot be empty. Client rule type: {0}</value>
+  </data>
+  <data name="HtmlHelper_ValidationParameterMustBeLegal" xml:space="preserve">
+    <value>Validation parameter names in unobtrusive client validation rules must start with a lowercase letter and consist of only lowercase letters or digits. Validation parameter name: {0}, client rule type: {1}</value>
+  </data>
+  <data name="ViewStartPage_RequiresMvcRazorView" xml:space="preserve">
+    <value>A ViewStartPage can be used only with with a page that derives from WebViewPage or another ViewStartPage.</value>
+  </data>
+  <data name="ControllerBase_CannotExecuteWithNullHttpContext" xml:space="preserve">
+    <value>Cannot execute Controller with a null HttpContext.</value>
+  </data>
+  <data name="CompareAttribute_MustMatch" xml:space="preserve">
+    <value>'{0}' and '{1}' do not match.</value>
+  </data>
+  <data name="RemoteAttribute_RemoteValidationFailed" xml:space="preserve">
+    <value>'{0}' is invalid.</value>
+  </data>
+  <data name="RemoteAttribute_NoUrlFound" xml:space="preserve">
+    <value>No url for remote validation could be found.</value>
+  </data>
+  <data name="AuthorizeAttribute_CannotUseWithinChildActionCache" xml:space="preserve">
+    <value>AuthorizeAttribute cannot be used within a child action caching block.</value>
+  </data>
+  <data name="OutputCacheAttribute_InvalidDuration" xml:space="preserve">
+    <value>Duration must be a positive number.</value>
+  </data>
+  <data name="OutputCacheAttribute_InvalidVaryByParam" xml:space="preserve">
+    <value>VaryByParam must be '*', 'none', or a semicolon-delimited list of keys.</value>
+  </data>
+  <data name="OutputCacheAttribute_ChildAction_UnsupportedSetting" xml:space="preserve">
+    <value>OutputCacheAttribute for child actions only supports Duration, VaryByCustom, and VaryByParam values. Please do not set CacheProfile, Location, NoStore, SqlDependency, VaryByContentEncoding, or VaryByHeader values for child actions.</value>
+  </data>
+  <data name="OutputCacheAttribute_CannotNestChildCache" xml:space="preserve">
+    <value>OutputCacheAttribute is not allowed on child actions which are children of an already cached child action.</value>
+  </data>
+  <data name="CompareAttribute_UnknownProperty" xml:space="preserve">
+    <value>Could not find a property named {0}.</value>
+  </data>
+</root>
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ResultExecutedContext.cs b/mcs/class/System.Web.Mvc3/Mvc/ResultExecutedContext.cs
new file mode 100644 (file)
index 0000000..bc7eeb3
--- /dev/null
@@ -0,0 +1,44 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+
+    public class ResultExecutedContext : ControllerContext {
+
+        // parameterless constructor used for mocking
+        public ResultExecutedContext() {
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
+        public ResultExecutedContext(ControllerContext controllerContext, ActionResult result, bool canceled, Exception exception)
+            : base(controllerContext) {
+            if (result == null) {
+                throw new ArgumentNullException("result");
+            }
+
+            Result = result;
+            Canceled = canceled;
+            Exception = exception;
+        }
+
+        public virtual bool Canceled {
+            get;
+            set;
+        }
+
+        public virtual Exception Exception {
+            get;
+            set;
+        }
+
+        public bool ExceptionHandled {
+            get;
+            set;
+        }
+
+        public virtual ActionResult Result {
+            get;
+            set;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ResultExecutingContext.cs b/mcs/class/System.Web.Mvc3/Mvc/ResultExecutingContext.cs
new file mode 100644 (file)
index 0000000..ab472f1
--- /dev/null
@@ -0,0 +1,32 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+
+    public class ResultExecutingContext : ControllerContext {
+
+        // parameterless constructor used for mocking
+        public ResultExecutingContext() {
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
+        public ResultExecutingContext(ControllerContext controllerContext, ActionResult result)
+            : base(controllerContext) {
+            if (result == null) {
+                throw new ArgumentNullException("result");
+            }
+
+            Result = result;
+        }
+
+        public bool Cancel {
+            get;
+            set;
+        }
+
+        public virtual ActionResult Result {
+            get;
+            set;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RouteCollectionExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/RouteCollectionExtensions.cs
new file mode 100644 (file)
index 0000000..6233dd0
--- /dev/null
@@ -0,0 +1,161 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web.Routing;
+
+    public static class RouteCollectionExtensions {
+
+        // This method returns a new RouteCollection containing only routes that matched a particular area.
+        // The Boolean out parameter is just a flag specifying whether any registered routes were area-aware.
+        private static RouteCollection FilterRouteCollectionByArea(RouteCollection routes, string areaName, out bool usingAreas) {
+            if (areaName == null) {
+                areaName = String.Empty;
+            }
+
+            usingAreas = false;
+            RouteCollection filteredRoutes = new RouteCollection();
+
+            using (routes.GetReadLock()) {
+                foreach (RouteBase route in routes) {
+                    string thisAreaName = AreaHelpers.GetAreaName(route) ?? String.Empty;
+                    usingAreas |= (thisAreaName.Length > 0);
+                    if (String.Equals(thisAreaName, areaName, StringComparison.OrdinalIgnoreCase)) {
+                        filteredRoutes.Add(route);
+                    }
+                }
+            }
+
+            // if areas are not in use, the filtered route collection might be incorrect
+            return (usingAreas) ? filteredRoutes : routes;
+        }
+
+        public static VirtualPathData GetVirtualPathForArea(this RouteCollection routes, RequestContext requestContext, RouteValueDictionary values) {
+            return GetVirtualPathForArea(routes, requestContext, null /* name */, values);
+        }
+
+        public static VirtualPathData GetVirtualPathForArea(this RouteCollection routes, RequestContext requestContext, string name, RouteValueDictionary values) {
+            bool usingAreas; // don't care about this value
+            return GetVirtualPathForArea(routes, requestContext, name, values, out usingAreas);
+        }
+
+        internal static VirtualPathData GetVirtualPathForArea(this RouteCollection routes, RequestContext requestContext, string name, RouteValueDictionary values, out bool usingAreas) {
+            if (routes == null) {
+                throw new ArgumentNullException("routes");
+            }
+
+            if (!String.IsNullOrEmpty(name)) {
+                // the route name is a stronger qualifier than the area name, so just pipe it through
+                usingAreas = false;
+                return routes.GetVirtualPath(requestContext, name, values);
+            }
+
+            string targetArea = null;
+            if (values != null) {
+                object targetAreaRawValue;
+                if (values.TryGetValue("area", out targetAreaRawValue)) {
+                    targetArea = targetAreaRawValue as string;
+                }
+                else {
+                    // set target area to current area
+                    if (requestContext != null) {
+                        targetArea = AreaHelpers.GetAreaName(requestContext.RouteData);
+                    }
+                }
+            }
+
+            // need to apply a correction to the RVD if areas are in use
+            RouteValueDictionary correctedValues = values;
+            RouteCollection filteredRoutes = FilterRouteCollectionByArea(routes, targetArea, out usingAreas);
+            if (usingAreas) {
+                correctedValues = new RouteValueDictionary(values);
+                correctedValues.Remove("area");
+            }
+
+            VirtualPathData vpd = filteredRoutes.GetVirtualPath(requestContext, correctedValues);
+            return vpd;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "1#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public static void IgnoreRoute(this RouteCollection routes, string url) {
+            IgnoreRoute(routes, url, null /* constraints */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "1#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public static void IgnoreRoute(this RouteCollection routes, string url, object constraints) {
+            if (routes == null) {
+                throw new ArgumentNullException("routes");
+            }
+            if (url == null) {
+                throw new ArgumentNullException("url");
+            }
+
+            IgnoreRouteInternal route = new IgnoreRouteInternal(url) {
+                Constraints = new RouteValueDictionary(constraints)
+            };
+
+            routes.Add(route);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "2#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public static Route MapRoute(this RouteCollection routes, string name, string url) {
+            return MapRoute(routes, name, url, null /* defaults */, (object)null /* constraints */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "2#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public static Route MapRoute(this RouteCollection routes, string name, string url, object defaults) {
+            return MapRoute(routes, name, url, defaults, (object)null /* constraints */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "2#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public static Route MapRoute(this RouteCollection routes, string name, string url, object defaults, object constraints) {
+            return MapRoute(routes, name, url, defaults, constraints, null /* namespaces */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "2#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public static Route MapRoute(this RouteCollection routes, string name, string url, string[] namespaces) {
+            return MapRoute(routes, name, url, null /* defaults */, null /* constraints */, namespaces);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "2#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public static Route MapRoute(this RouteCollection routes, string name, string url, object defaults, string[] namespaces) {
+            return MapRoute(routes, name, url, defaults, null /* constraints */, namespaces);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "2#", Justification = "This is not a regular URL as it may contain special routing characters.")]
+        public static Route MapRoute(this RouteCollection routes, string name, string url, object defaults, object constraints, string[] namespaces) {
+            if (routes == null) {
+                throw new ArgumentNullException("routes");
+            }
+            if (url == null) {
+                throw new ArgumentNullException("url");
+            }
+
+            Route route = new Route(url, new MvcRouteHandler()) {
+                Defaults = new RouteValueDictionary(defaults),
+                Constraints = new RouteValueDictionary(constraints),
+                DataTokens = new RouteValueDictionary()
+            };
+
+            if ((namespaces != null) && (namespaces.Length > 0)) {
+                route.DataTokens["Namespaces"] = namespaces;
+            }
+
+            routes.Add(name, route);
+
+            return route;
+        }
+
+        private sealed class IgnoreRouteInternal : Route {
+            public IgnoreRouteInternal(string url)
+                : base(url, new StopRoutingHandler()) {
+            }
+
+            public override VirtualPathData GetVirtualPath(RequestContext requestContext, RouteValueDictionary routeValues) {
+                // Never match during route generation. This avoids the scenario where an IgnoreRoute with
+                // fairly relaxed constraints ends up eagerly matching all generated URLs.
+                return null;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RouteDataValueProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/RouteDataValueProvider.cs
new file mode 100644 (file)
index 0000000..5e79a82
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Globalization;
+
+    public sealed class RouteDataValueProvider : DictionaryValueProvider<object> {
+
+        // RouteData should use the invariant culture since it's part of the URL, and the URL should be
+        // interpreted in a uniform fashion regardless of the origin of a particular request.
+        public RouteDataValueProvider(ControllerContext controllerContext)
+            : base(controllerContext.RouteData.Values, CultureInfo.InvariantCulture) {
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RouteDataValueProviderFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/RouteDataValueProviderFactory.cs
new file mode 100644 (file)
index 0000000..90f0535
--- /dev/null
@@ -0,0 +1,15 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public sealed class RouteDataValueProviderFactory : ValueProviderFactory {
+
+        public override IValueProvider GetValueProvider(ControllerContext controllerContext) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            return new RouteDataValueProvider(controllerContext);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/RouteValuesHelpers.cs b/mcs/class/System.Web.Mvc3/Mvc/RouteValuesHelpers.cs
new file mode 100644 (file)
index 0000000..0bf1406
--- /dev/null
@@ -0,0 +1,49 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Web.Routing;
+
+    internal static class RouteValuesHelpers {
+        public static RouteValueDictionary GetRouteValues(RouteValueDictionary routeValues) {
+            return (routeValues != null) ? new RouteValueDictionary(routeValues) : new RouteValueDictionary();
+        }
+
+        public static RouteValueDictionary MergeRouteValues(string actionName, string controllerName, RouteValueDictionary implicitRouteValues, RouteValueDictionary routeValues, bool includeImplicitMvcValues) {
+            // Create a new dictionary containing implicit and auto-generated values
+            RouteValueDictionary mergedRouteValues = new RouteValueDictionary();
+
+            if (includeImplicitMvcValues) {
+                // We only include MVC-specific values like 'controller' and 'action' if we are generating an action link.
+                // If we are generating a route link [as to MapRoute("Foo", "any/url", new { controller = ... })], including
+                // the current controller name will cause the route match to fail if the current controller is not the same
+                // as the destination controller.
+
+                object implicitValue;
+                if (implicitRouteValues != null && implicitRouteValues.TryGetValue("action", out implicitValue)) {
+                    mergedRouteValues["action"] = implicitValue;
+                }
+
+                if (implicitRouteValues != null && implicitRouteValues.TryGetValue("controller", out implicitValue)) {
+                    mergedRouteValues["controller"] = implicitValue;
+                }
+            }
+
+            // Merge values from the user's dictionary/object
+            if (routeValues != null) {
+                foreach (KeyValuePair<string, object> routeElement in GetRouteValues(routeValues)) {
+                    mergedRouteValues[routeElement.Key] = routeElement.Value;
+                }
+            }
+
+            // Merge explicit parameters when not null
+            if (actionName != null) {
+                mergedRouteValues["action"] = actionName;
+            }
+
+            if (controllerName != null) {
+                mergedRouteValues["controller"] = controllerName;
+            }
+
+            return mergedRouteValues;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/SecurityUtil.cs b/mcs/class/System.Web.Mvc3/Mvc/SecurityUtil.cs
new file mode 100644 (file)
index 0000000..bff5346
--- /dev/null
@@ -0,0 +1,66 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Reflection;
+    using System.Security;
+
+    internal static class SecurityUtil {
+
+        private static Action<Action> _callInAppTrustThunk;
+
+        // !! IMPORTANT !!
+        // Do not try to optimize this method or perform any extra caching; doing so could lead to MVC not operating
+        // correctly until the AppDomain is restarted.
+        [SuppressMessage("Microsoft.Security", "CA2107:ReviewDenyAndPermitOnlyUsage",
+            Justification = "This is essentially the same logic as Page.ProcessRequest.")]
+        [SuppressMessage("Microsoft.Design", "CA1031:DoNotCatchGeneralExceptionTypes",
+            Justification = "If an exception is thrown, assume we're running in same trust level as the application itself, so we don't need to do anything special.")]
+        private static Action<Action> GetCallInAppTrustThunk() {
+            // do we need to create the thunk?
+            if (_callInAppTrustThunk == null) {
+                try {
+                    if (!typeof(SecurityUtil).Assembly.IsFullyTrusted /* bin-deployed */
+                        || AppDomain.CurrentDomain.IsHomogenous /* .NET 4 CAS model */) {
+                        // we're already running in the application's trust level, so nothing to do
+                        _callInAppTrustThunk = f => f();
+                    }
+                    else {
+                        // legacy CAS model - need to lower own permission level to be compatible with legacy systems
+                        // This is essentially the same logic as Page.ProcessRequest(HttpContext)
+                        NamedPermissionSet namedPermissionSet = (NamedPermissionSet)typeof(HttpRuntime).GetProperty("NamedPermissionSet", BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Static).GetValue(null, null);
+                        bool disableProcessRequestInApplicationTrust = (bool)typeof(HttpRuntime).GetProperty("DisableProcessRequestInApplicationTrust", BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Static).GetValue(null, null);
+                        if (namedPermissionSet != null && !disableProcessRequestInApplicationTrust) {
+                            _callInAppTrustThunk = f => {
+                                // lower permissions
+                                namedPermissionSet.PermitOnly();
+                                f();
+                            };
+                        }
+                        else {
+                            // application's trust level is FullTrust, so nothing to do
+                            _callInAppTrustThunk = f => f();
+                        }
+                    }
+                }
+                catch {
+                    // MVC assembly is already running in application trust, so swallow exceptions
+                }
+            }
+
+            // if there was an error, just process transparently
+            return _callInAppTrustThunk ?? (Action<Action>)(f => f());
+        }
+
+        public static TResult ProcessInApplicationTrust<TResult>(Func<TResult> func) {
+            TResult result = default(TResult);
+            ProcessInApplicationTrust(delegate { result = func(); });
+            return result;
+        }
+
+        public static void ProcessInApplicationTrust(Action action) {
+            Action<Action> executor = GetCallInAppTrustThunk();
+            executor(action);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/SelectList.cs b/mcs/class/System.Web.Mvc3/Mvc/SelectList.cs
new file mode 100644 (file)
index 0000000..8b1651a
--- /dev/null
@@ -0,0 +1,34 @@
+namespace System.Web.Mvc {
+    using System.Collections;
+    using System.Diagnostics.CodeAnalysis;
+
+    [SuppressMessage("Microsoft.Naming", "CA1710:IdentifiersShouldHaveCorrectSuffix")]
+    public class SelectList : MultiSelectList {
+
+        public SelectList(IEnumerable items)
+            : this(items, null /* selectedValue */) {
+        }
+
+        public SelectList(IEnumerable items, object selectedValue)
+            : this(items, null /* dataValuefield */, null /* dataTextField */, selectedValue) {
+        }
+
+        public SelectList(IEnumerable items, string dataValueField, string dataTextField)
+            : this(items, dataValueField, dataTextField, null /* selectedValue */) {
+        }
+
+        public SelectList(IEnumerable items, string dataValueField, string dataTextField, object selectedValue)
+            : base(items, dataValueField, dataTextField, ToEnumerable(selectedValue)) {
+            SelectedValue = selectedValue;
+        }
+
+        public object SelectedValue {
+            get;
+            private set;
+        }
+
+        private static IEnumerable ToEnumerable(object selectedValue) {
+            return (selectedValue != null) ? new object[] { selectedValue } : null;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/SelectListItem.cs b/mcs/class/System.Web.Mvc3/Mvc/SelectListItem.cs
new file mode 100644 (file)
index 0000000..786b1de
--- /dev/null
@@ -0,0 +1,20 @@
+namespace System.Web.Mvc {
+
+    public class SelectListItem {
+
+        public bool Selected {
+            get;
+            set;
+        }
+
+        public string Text {
+            get;
+            set;
+        }
+
+        public string Value {
+            get;
+            set;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/SessionStateAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/SessionStateAttribute.cs
new file mode 100644 (file)
index 0000000..2069350
--- /dev/null
@@ -0,0 +1,17 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Web.SessionState;
+
+    [AttributeUsage(AttributeTargets.Class, AllowMultiple = false, Inherited = true)]
+    public sealed class SessionStateAttribute : Attribute {
+
+        public SessionStateAttribute(SessionStateBehavior behavior) {
+            Behavior = behavior;
+        }
+
+        public SessionStateBehavior Behavior {
+            get;
+            private set;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/SessionStateTempDataProvider.cs b/mcs/class/System.Web.Mvc3/Mvc/SessionStateTempDataProvider.cs
new file mode 100644 (file)
index 0000000..cc95a32
--- /dev/null
@@ -0,0 +1,53 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Web.Mvc.Resources;
+
+    public class SessionStateTempDataProvider : ITempDataProvider {
+        internal const string TempDataSessionStateKey = "__ControllerTempData";
+
+        public virtual IDictionary<string, object> LoadTempData(ControllerContext controllerContext) {
+            HttpSessionStateBase session = controllerContext.HttpContext.Session;
+
+            if (session != null) {
+                Dictionary<string, object> tempDataDictionary = session[TempDataSessionStateKey] as Dictionary<string, object>;
+
+                if (tempDataDictionary != null) {
+                    // If we got it from Session, remove it so that no other request gets it
+                    session.Remove(TempDataSessionStateKey);
+                    return tempDataDictionary;
+                }
+            }
+
+            return new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
+        }
+
+        public virtual void SaveTempData(ControllerContext controllerContext, IDictionary<string, object> values) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+
+            HttpSessionStateBase session = controllerContext.HttpContext.Session;
+            bool isDirty = (values != null && values.Count > 0);
+
+            if (session == null) {
+                if (isDirty) {
+                    throw new InvalidOperationException(MvcResources.SessionStateTempDataProvider_SessionStateDisabled);
+                }
+            }
+            else {
+                if (isDirty) {
+                    session[TempDataSessionStateKey] = values;
+                }
+                else {
+                    // Since the default implementation of Remove() (from SessionStateItemCollection) dirties the
+                    // collection, we shouldn't call it unless we really do need to remove the existing key.
+                    if (session[TempDataSessionStateKey] != null) {
+                        session.Remove(TempDataSessionStateKey);
+                    }
+                }
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/SingleServiceResolver.cs b/mcs/class/System.Web.Mvc3/Mvc/SingleServiceResolver.cs
new file mode 100644 (file)
index 0000000..17f55dc
--- /dev/null
@@ -0,0 +1,52 @@
+namespace System.Web.Mvc {
+    using System.Globalization;
+    using System.Web.Mvc.Resources;
+
+    internal class SingleServiceResolver<TService> : IResolver<TService> where TService : class {
+
+        private TService _currentValueFromResolver;
+        private Func<TService> _currentValueThunk;
+        private TService _defaultValue;
+        private Func<IDependencyResolver> _resolverThunk;
+        private string _callerMethodName;
+
+        public SingleServiceResolver(Func<TService> currentValueThunk, TService defaultValue, string callerMethodName) {
+            if (currentValueThunk == null) {
+                throw new ArgumentNullException("currentValueThunk");
+            }
+            if (defaultValue == null) {
+                throw new ArgumentNullException("defaultValue");
+            }
+
+            _resolverThunk = () => DependencyResolver.Current;
+            _currentValueThunk = currentValueThunk;
+            _defaultValue = defaultValue;
+            _callerMethodName = callerMethodName;
+        }
+
+        internal SingleServiceResolver(Func<TService> staticAccessor, TService defaultValue, IDependencyResolver resolver, string callerMethodName)
+            : this(staticAccessor, defaultValue, callerMethodName) {
+            if (resolver != null) {
+                _resolverThunk = () => resolver;
+            }
+        }
+
+        public TService Current {
+            get {
+                if (_resolverThunk != null) {
+                    lock (_currentValueThunk) {
+                        if (_resolverThunk != null) {
+                            _currentValueFromResolver = _resolverThunk().GetService<TService>();
+                            _resolverThunk = null;
+
+                            if (_currentValueFromResolver != null && _currentValueThunk() != null) {
+                                throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture, MvcResources.SingleServiceResolver_CannotRegisterTwoInstances, typeof(TService).Name.ToString(), _callerMethodName));
+                            }
+                        }
+                    }
+                }
+                return _currentValueFromResolver ?? _currentValueThunk() ?? _defaultValue;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/StringLengthAttributeAdapter.cs b/mcs/class/System.Web.Mvc3/Mvc/StringLengthAttributeAdapter.cs
new file mode 100644 (file)
index 0000000..d1af094
--- /dev/null
@@ -0,0 +1,14 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.ComponentModel.DataAnnotations;
+
+    public class StringLengthAttributeAdapter : DataAnnotationsModelValidator<StringLengthAttribute> {
+        public StringLengthAttributeAdapter(ModelMetadata metadata, ControllerContext context, StringLengthAttribute attribute)
+            : base(metadata, context, attribute) {
+        }
+
+        public override IEnumerable<ModelClientValidationRule> GetClientValidationRules() {
+            return new[] { new ModelClientValidationStringLengthRule(ErrorMessage, Attribute.MinimumLength, Attribute.MaximumLength) };
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/TagBuilderExtensions.cs b/mcs/class/System.Web.Mvc3/Mvc/TagBuilderExtensions.cs
new file mode 100644 (file)
index 0000000..7b87fd5
--- /dev/null
@@ -0,0 +1,10 @@
+namespace System.Web.Mvc {
+    using System.Diagnostics;
+
+    internal static class TagBuilderExtensions {
+        internal static MvcHtmlString ToMvcHtmlString(this TagBuilder tagBuilder, TagRenderMode renderMode) {
+            Debug.Assert(tagBuilder != null);
+            return new MvcHtmlString(tagBuilder.ToString(renderMode));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/TempDataDictionary.cs b/mcs/class/System.Web.Mvc3/Mvc/TempDataDictionary.cs
new file mode 100644 (file)
index 0000000..257893e
--- /dev/null
@@ -0,0 +1,191 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Linq;
+    using System.Runtime.Serialization;
+
+    public class TempDataDictionary : IDictionary<string, object> {
+        internal const string _tempDataSerializationKey = "__tempData";
+
+        private Dictionary<string, object> _data;
+        private HashSet<string> _initialKeys = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
+        private HashSet<string> _retainedKeys = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
+
+        public TempDataDictionary() {
+            _data = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
+        }
+
+        public int Count {
+            get {
+                return _data.Count;
+            }
+        }
+
+        public ICollection<string> Keys {
+            get {
+                return _data.Keys;
+            }
+        }
+
+        public void Keep() {
+            _retainedKeys.Clear();
+            _retainedKeys.UnionWith(_data.Keys);
+        }
+
+        public void Keep(string key) {
+            _retainedKeys.Add(key);
+        }
+
+        public void Load(ControllerContext controllerContext, ITempDataProvider tempDataProvider) {
+            IDictionary<string, object> providerDictionary = tempDataProvider.LoadTempData(controllerContext);
+            _data = (providerDictionary != null) ? new Dictionary<string, object>(providerDictionary, StringComparer.OrdinalIgnoreCase) :
+                new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
+            _initialKeys = new HashSet<string>(_data.Keys, StringComparer.OrdinalIgnoreCase);
+            _retainedKeys.Clear();
+        }
+
+        public object Peek(string key) {
+            object value;
+            _data.TryGetValue(key, out value);
+            return value;
+        }
+
+        public void Save(ControllerContext controllerContext, ITempDataProvider tempDataProvider) {
+            string[] keysToKeep = _initialKeys.Union(_retainedKeys, StringComparer.OrdinalIgnoreCase).ToArray();
+            string[] keysToRemove = _data.Keys.Except(keysToKeep, StringComparer.OrdinalIgnoreCase).ToArray();
+            foreach (string key in keysToRemove) {
+                _data.Remove(key);
+            }
+            tempDataProvider.SaveTempData(controllerContext, _data);
+        }
+
+        public ICollection<object> Values {
+            get {
+                return _data.Values;
+            }
+        }
+
+        public object this[string key] {
+            get {
+                object value;
+                if (TryGetValue(key, out value)) {
+                    _initialKeys.Remove(key);
+                    return value;
+                }
+                return null;
+            }
+            set {
+                _data[key] = value;
+                _initialKeys.Add(key);
+            }
+        }
+
+        public void Add(string key, object value) {
+            _data.Add(key, value);
+            _initialKeys.Add(key);
+        }
+
+        public void Clear() {
+            _data.Clear();
+            _retainedKeys.Clear();
+            _initialKeys.Clear();
+        }
+
+        public bool ContainsKey(string key) {
+            return _data.ContainsKey(key);
+        }
+
+        public bool ContainsValue(object value) {
+            return _data.ContainsValue(value);
+        }
+
+        public IEnumerator<KeyValuePair<string, object>> GetEnumerator() {
+            return new TempDataDictionaryEnumerator(this);
+        }
+
+        public bool Remove(string key) {
+            _retainedKeys.Remove(key);
+            _initialKeys.Remove(key);
+            return _data.Remove(key);
+        }
+
+        public bool TryGetValue(string key, out object value) {
+            _initialKeys.Remove(key);
+            return _data.TryGetValue(key, out value);
+        }
+
+        #region ICollection<KeyValuePair<string, object>> Implementation
+        bool ICollection<KeyValuePair<string, object>>.IsReadOnly {
+            get {
+                return ((ICollection<KeyValuePair<string, object>>)_data).IsReadOnly;
+            }
+        }
+
+        void ICollection<KeyValuePair<string, object>>.CopyTo(KeyValuePair<string, object>[] array, int index) {
+            ((ICollection<KeyValuePair<string, object>>)_data).CopyTo(array, index);
+        }
+
+        void ICollection<KeyValuePair<string, object>>.Add(KeyValuePair<string, object> keyValuePair) {
+            _initialKeys.Add(keyValuePair.Key);
+            ((ICollection<KeyValuePair<string, object>>)_data).Add(keyValuePair);
+        }
+
+        bool ICollection<KeyValuePair<string, object>>.Contains(KeyValuePair<string, object> keyValuePair) {
+            return ((ICollection<KeyValuePair<string, object>>)_data).Contains(keyValuePair);
+        }
+
+        bool ICollection<KeyValuePair<string, object>>.Remove(KeyValuePair<string, object> keyValuePair) {
+            _initialKeys.Remove(keyValuePair.Key);
+            return ((ICollection<KeyValuePair<string, object>>)_data).Remove(keyValuePair);
+        }
+        #endregion
+
+        #region IEnumerable Implementation
+        IEnumerator IEnumerable.GetEnumerator() {
+            return (IEnumerator)(new TempDataDictionaryEnumerator(this));
+        }
+        #endregion
+
+        private sealed class TempDataDictionaryEnumerator : IEnumerator<KeyValuePair<string, object>> {
+            private IEnumerator<KeyValuePair<string, object>> _enumerator;
+            private TempDataDictionary _tempData;
+
+            public TempDataDictionaryEnumerator(TempDataDictionary tempData) {
+                _tempData = tempData;
+                _enumerator = _tempData._data.GetEnumerator();
+            }
+
+            public KeyValuePair<string, object> Current {
+                get {
+                    KeyValuePair<string, object> kvp = _enumerator.Current;
+                    _tempData._initialKeys.Remove(kvp.Key);
+                    return kvp;
+                }
+            }
+
+            public bool MoveNext() {
+                return _enumerator.MoveNext();
+            }
+
+            public void Reset() {
+                _enumerator.Reset();
+            }
+
+            #region IEnumerator Implementation
+            object IEnumerator.Current {
+                get {
+                    return Current;
+                }
+            }
+            #endregion
+
+            #region IDisposable Implementation
+            void IDisposable.Dispose() {
+                _enumerator.Dispose();
+            }
+            #endregion
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/TemplateInfo.cs b/mcs/class/System.Web.Mvc3/Mvc/TemplateInfo.cs
new file mode 100644 (file)
index 0000000..88cf7a7
--- /dev/null
@@ -0,0 +1,59 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+
+    public class TemplateInfo {
+        private string _htmlFieldPrefix;
+        private object _formattedModelValue;
+        private HashSet<object> _visitedObjects;
+
+        public object FormattedModelValue {
+            get {
+                return _formattedModelValue ?? String.Empty;
+            }
+            set {
+                _formattedModelValue = value;
+            }
+        }
+
+        public string HtmlFieldPrefix {
+            get {
+                return _htmlFieldPrefix ?? String.Empty;
+            }
+            set {
+                _htmlFieldPrefix = value;
+            }
+        }
+
+        public int TemplateDepth {
+            get {
+                return VisitedObjects.Count;
+            }
+        }
+
+        // DDB #224750 - Keep a collection of visited objects to prevent infinite recursion
+        internal HashSet<object> VisitedObjects {
+            get {
+                if (_visitedObjects == null) {
+                    _visitedObjects = new HashSet<object>();
+                }
+                return _visitedObjects;
+            }
+            set {
+                _visitedObjects = value;
+            }
+        }
+
+        public string GetFullHtmlFieldId(string partialFieldName) {
+            return HtmlHelper.GenerateIdFromName(GetFullHtmlFieldName(partialFieldName));
+        }
+
+        public string GetFullHtmlFieldName(string partialFieldName) {
+            // This uses "combine and trim" because either or both of these values might be empty
+            return (HtmlFieldPrefix + "." + (partialFieldName ?? String.Empty)).Trim('.');
+        }
+
+        public bool Visited(ModelMetadata metadata) {
+            return VisitedObjects.Contains(metadata.Model ?? metadata.ModelType);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/TryGetValueDelegate.cs b/mcs/class/System.Web.Mvc3/Mvc/TryGetValueDelegate.cs
new file mode 100644 (file)
index 0000000..f9ee08f
--- /dev/null
@@ -0,0 +1,5 @@
+namespace System.Web.Mvc {
+    using System;
+
+    internal delegate bool TryGetValueDelegate(object dictionary, string key, out object value);
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/TypeCacheSerializer.cs b/mcs/class/System.Web.Mvc3/Mvc/TypeCacheSerializer.cs
new file mode 100644 (file)
index 0000000..00ba819
--- /dev/null
@@ -0,0 +1,115 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.IO;
+    using System.Linq;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+    using System.Xml;
+
+    // Processes files with this format:
+    //
+    // <typeCache lastModified=... mvcVersionId=...>
+    //   <assembly name=...>
+    //     <module versionId=...>
+    //       <type>...</type>
+    //     </module>
+    //   </assembly>
+    // </typeCache>
+    //
+    // This is used to store caches of files between AppDomain resets, leading to improved cold boot time
+    // and more efficient use of memory.
+
+    internal sealed class TypeCacheSerializer {
+
+        private static readonly Guid _mvcVersionId = typeof(TypeCacheSerializer).Module.ModuleVersionId;
+
+        // used for unit testing
+
+        private DateTime CurrentDate {
+            get {
+                return CurrentDateOverride ?? DateTime.Now;
+            }
+        }
+
+        internal DateTime? CurrentDateOverride {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "This is an instance method for consistency with the SerializeTypes() method.")]
+        public List<Type> DeserializeTypes(TextReader input) {
+            XmlDocument doc = new XmlDocument();
+            doc.Load(input);
+            XmlElement rootElement = doc.DocumentElement;
+
+            Guid readMvcVersionId = new Guid(rootElement.Attributes["mvcVersionId"].Value);
+            if (readMvcVersionId != _mvcVersionId) {
+                // The cache is outdated because the cache file was produced by a different version
+                // of MVC.
+                return null;
+            }
+
+            List<Type> deserializedTypes = new List<Type>();
+            foreach (XmlNode assemblyNode in rootElement.ChildNodes) {
+                string assemblyName = assemblyNode.Attributes["name"].Value;
+                Assembly assembly = Assembly.Load(assemblyName);
+
+                foreach (XmlNode moduleNode in assemblyNode.ChildNodes) {
+                    Guid moduleVersionId = new Guid(moduleNode.Attributes["versionId"].Value);
+
+                    foreach (XmlNode typeNode in moduleNode.ChildNodes) {
+                        string typeName = typeNode.InnerText;
+                        Type type = assembly.GetType(typeName);
+                        if (type == null || type.Module.ModuleVersionId != moduleVersionId) {
+                            // The cache is outdated because we couldn't find a previously recorded
+                            // type or the type's containing module was modified.
+                            return null;
+                        }
+                        else {
+                            deserializedTypes.Add(type);
+                        }
+                    }
+                }
+            }
+
+            return deserializedTypes;
+        }
+
+        public void SerializeTypes(IEnumerable<Type> types, TextWriter output) {
+            var groupedByAssembly = from type in types
+                                    group type by type.Module into groupedByModule
+                                    group groupedByModule by groupedByModule.Key.Assembly;
+
+            XmlDocument doc = new XmlDocument();
+            doc.AppendChild(doc.CreateComment(MvcResources.TypeCache_DoNotModify));
+
+            XmlElement typeCacheElement = doc.CreateElement("typeCache");
+            doc.AppendChild(typeCacheElement);
+            typeCacheElement.SetAttribute("lastModified", CurrentDate.ToString());
+            typeCacheElement.SetAttribute("mvcVersionId", _mvcVersionId.ToString());
+
+            foreach (var assemblyGroup in groupedByAssembly) {
+                XmlElement assemblyElement = doc.CreateElement("assembly");
+                typeCacheElement.AppendChild(assemblyElement);
+                assemblyElement.SetAttribute("name", assemblyGroup.Key.FullName);
+
+                foreach (var moduleGroup in assemblyGroup) {
+                    XmlElement moduleElement = doc.CreateElement("module");
+                    assemblyElement.AppendChild(moduleElement);
+                    moduleElement.SetAttribute("versionId", moduleGroup.Key.ModuleVersionId.ToString());
+
+                    foreach (Type type in moduleGroup) {
+                        XmlElement typeElement = doc.CreateElement("type");
+                        moduleElement.AppendChild(typeElement);
+                        typeElement.AppendChild(doc.CreateTextNode(type.FullName));
+                    }
+                }
+            }
+
+            doc.Save(output);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/TypeCacheUtil.cs b/mcs/class/System.Web.Mvc3/Mvc/TypeCacheUtil.cs
new file mode 100644 (file)
index 0000000..3bd97f5
--- /dev/null
@@ -0,0 +1,87 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.IO;
+    using System.Linq;
+    using System.Reflection;
+
+    internal static class TypeCacheUtil {
+
+        private static IEnumerable<Type> FilterTypesInAssemblies(IBuildManager buildManager, Predicate<Type> predicate) {
+            // Go through all assemblies referenced by the application and search for types matching a predicate
+            IEnumerable<Type> typesSoFar = Type.EmptyTypes;
+
+            ICollection assemblies = buildManager.GetReferencedAssemblies();
+            foreach (Assembly assembly in assemblies) {
+                Type[] typesInAsm;
+                try {
+                    typesInAsm = assembly.GetTypes();
+                }
+                catch (ReflectionTypeLoadException ex) {
+                    typesInAsm = ex.Types;
+                }
+                typesSoFar = typesSoFar.Concat(typesInAsm);
+            }
+            return typesSoFar.Where(type => TypeIsPublicClass(type) && predicate(type));
+        }
+
+        public static List<Type> GetFilteredTypesFromAssemblies(string cacheName, Predicate<Type> predicate, IBuildManager buildManager) {
+            TypeCacheSerializer serializer = new TypeCacheSerializer();
+
+            // first, try reading from the cache on disk
+            List<Type> matchingTypes = ReadTypesFromCache(cacheName, predicate, buildManager, serializer);
+            if (matchingTypes != null) {
+                return matchingTypes;
+            }
+
+            // if reading from the cache failed, enumerate over every assembly looking for a matching type
+            matchingTypes = FilterTypesInAssemblies(buildManager, predicate).ToList();
+
+            // finally, save the cache back to disk
+            SaveTypesToCache(cacheName, matchingTypes, buildManager, serializer);
+
+            return matchingTypes;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1031:DoNotCatchGeneralExceptionTypes", Justification = "Cache failures are not fatal, and the code should continue executing normally.")]
+        internal static List<Type> ReadTypesFromCache(string cacheName, Predicate<Type> predicate, IBuildManager buildManager, TypeCacheSerializer serializer) {
+            try {
+                Stream stream = buildManager.ReadCachedFile(cacheName);
+                if (stream != null) {
+                    using (StreamReader reader = new StreamReader(stream)) {
+                        List<Type> deserializedTypes = serializer.DeserializeTypes(reader);
+                        if (deserializedTypes != null && deserializedTypes.All(type => TypeIsPublicClass(type) && predicate(type))) {
+                            // If all read types still match the predicate, success!
+                            return deserializedTypes;
+                        }
+                    }
+                }
+            }
+            catch {
+            }
+
+            return null;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1031:DoNotCatchGeneralExceptionTypes", Justification = "Cache failures are not fatal, and the code should continue executing normally.")]
+        internal static void SaveTypesToCache(string cacheName, IList<Type> matchingTypes, IBuildManager buildManager, TypeCacheSerializer serializer) {
+            try {
+                Stream stream = buildManager.CreateCachedFile(cacheName);
+                if (stream != null) {
+                    using (StreamWriter writer = new StreamWriter(stream)) {
+                        serializer.SerializeTypes(matchingTypes, writer);
+                    }
+                }
+            }
+            catch {
+            }
+        }
+
+        private static bool TypeIsPublicClass(Type type) {
+            return (type != null && type.IsPublic && type.IsClass && !type.IsAbstract);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/TypeDescriptorHelper.cs b/mcs/class/System.Web.Mvc3/Mvc/TypeDescriptorHelper.cs
new file mode 100644 (file)
index 0000000..4b128b0
--- /dev/null
@@ -0,0 +1,13 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.ComponentModel;
+    using System.ComponentModel.DataAnnotations;
+
+    internal static class TypeDescriptorHelper {
+
+        public static ICustomTypeDescriptor Get(Type type) {
+            return new AssociatedMetadataTypeTypeDescriptionProvider(type).GetTypeDescriptor(type);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/TypeHelpers.cs b/mcs/class/System.Web.Mvc3/Mvc/TypeHelpers.cs
new file mode 100644 (file)
index 0000000..90ebcbe
--- /dev/null
@@ -0,0 +1,126 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Linq;
+    using System.Reflection;
+    using System.Threading;
+
+    internal static class TypeHelpers {
+
+        private static readonly Dictionary<Type, TryGetValueDelegate> _tryGetValueDelegateCache = new Dictionary<Type, TryGetValueDelegate>();
+        private static readonly ReaderWriterLockSlim _tryGetValueDelegateCacheLock = new ReaderWriterLockSlim();
+
+        private static readonly MethodInfo _strongTryGetValueImplInfo = typeof(TypeHelpers).GetMethod("StrongTryGetValueImpl", BindingFlags.NonPublic | BindingFlags.Static);
+
+        public static readonly Assembly MsCorLibAssembly = typeof(string).Assembly;
+        public static readonly Assembly MvcAssembly = typeof(Controller).Assembly;
+        public static readonly Assembly SystemWebAssembly = typeof(HttpContext).Assembly;
+
+        // method is used primarily for lighting up new .NET Framework features even if MVC targets the previous version
+        // thisParameter is the 'this' parameter if target method is instance method, should be null for static method
+        public static TDelegate CreateDelegate<TDelegate>(Assembly assembly, string typeName, string methodName, object thisParameter) where TDelegate : class {
+            // ensure target type exists
+            Type targetType = assembly.GetType(typeName, false /* throwOnError */);
+            if (targetType == null) {
+                return null;
+            }
+
+            return CreateDelegate<TDelegate>(targetType, methodName, thisParameter);
+        }
+
+        public static TDelegate CreateDelegate<TDelegate>(Type targetType, string methodName, object thisParameter) where TDelegate : class {
+            // ensure target method exists
+            ParameterInfo[] delegateParameters = typeof(TDelegate).GetMethod("Invoke").GetParameters();
+            Type[] argumentTypes = Array.ConvertAll(delegateParameters, pInfo => pInfo.ParameterType);
+            MethodInfo targetMethod = targetType.GetMethod(methodName, argumentTypes);
+            if (targetMethod == null) {
+                return null;
+            }
+
+            TDelegate d = Delegate.CreateDelegate(typeof(TDelegate), thisParameter, targetMethod, false /* throwOnBindFailure */) as TDelegate;
+            return d;
+        }
+
+        public static TryGetValueDelegate CreateTryGetValueDelegate(Type targetType) {
+            TryGetValueDelegate result;
+
+            _tryGetValueDelegateCacheLock.EnterReadLock();
+            try {
+                if (_tryGetValueDelegateCache.TryGetValue(targetType, out result)) {
+                    return result;
+                }
+            }
+            finally {
+                _tryGetValueDelegateCacheLock.ExitReadLock();
+            }
+
+            Type dictionaryType = ExtractGenericInterface(targetType, typeof(IDictionary<,>));
+
+            // just wrap a call to the underlying IDictionary<TKey, TValue>.TryGetValue() where string can be cast to TKey
+            if (dictionaryType != null) {
+                Type[] typeArguments = dictionaryType.GetGenericArguments();
+                Type keyType = typeArguments[0];
+                Type returnType = typeArguments[1];
+
+                if (keyType.IsAssignableFrom(typeof(string))) {
+                    MethodInfo strongImplInfo = _strongTryGetValueImplInfo.MakeGenericMethod(keyType, returnType);
+                    result = (TryGetValueDelegate)Delegate.CreateDelegate(typeof(TryGetValueDelegate), strongImplInfo);
+                }
+            }
+
+            // wrap a call to the underlying IDictionary.Item()
+            if (result == null && typeof(IDictionary).IsAssignableFrom(targetType)) {
+                result = TryGetValueFromNonGenericDictionary;
+            }
+
+            _tryGetValueDelegateCacheLock.EnterWriteLock();
+            try {
+                _tryGetValueDelegateCache[targetType] = result;
+            }
+            finally {
+                _tryGetValueDelegateCacheLock.ExitWriteLock();
+            }
+
+            return result;
+        }
+
+        public static Type ExtractGenericInterface(Type queryType, Type interfaceType) {
+            Func<Type, bool> matchesInterface = t => t.IsGenericType && t.GetGenericTypeDefinition() == interfaceType;
+            return (matchesInterface(queryType)) ? queryType : queryType.GetInterfaces().FirstOrDefault(matchesInterface);
+        }
+
+        public static object GetDefaultValue(Type type) {
+            return (TypeAllowsNullValue(type)) ? null : Activator.CreateInstance(type);
+        }
+
+        public static bool IsCompatibleObject<T>(object value) {
+            return (value is T || (value == null && TypeAllowsNullValue(typeof(T))));
+        }
+
+        public static bool IsNullableValueType(Type type) {
+            return Nullable.GetUnderlyingType(type) != null;
+        }
+
+        private static bool StrongTryGetValueImpl<TKey, TValue>(object dictionary, string key, out object value) {
+            IDictionary<TKey, TValue> strongDict = (IDictionary<TKey, TValue>)dictionary;
+
+            TValue strongValue;
+            bool retVal = strongDict.TryGetValue((TKey)(object)key, out strongValue);
+            value = strongValue;
+            return retVal;
+        }
+
+        private static bool TryGetValueFromNonGenericDictionary(object dictionary, string key, out object value) {
+            IDictionary weakDict = (IDictionary)dictionary;
+
+            bool containsKey = weakDict.Contains(key);
+            value = (containsKey) ? weakDict[key] : null;
+            return containsKey;
+        }
+
+        public static bool TypeAllowsNullValue(Type type) {
+            return (!type.IsValueType || IsNullableValueType(type));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/UnvalidatedRequestValuesAccessor.cs b/mcs/class/System.Web.Mvc3/Mvc/UnvalidatedRequestValuesAccessor.cs
new file mode 100644 (file)
index 0000000..660ab22
--- /dev/null
@@ -0,0 +1,6 @@
+namespace System.Web.Mvc {
+    using System;
+
+    internal delegate IUnvalidatedRequestValues UnvalidatedRequestValuesAccessor(ControllerContext controllerContext);
+
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/UnvalidatedRequestValuesWrapper.cs b/mcs/class/System.Web.Mvc3/Mvc/UnvalidatedRequestValuesWrapper.cs
new file mode 100644 (file)
index 0000000..90b5493
--- /dev/null
@@ -0,0 +1,28 @@
+namespace System.Web.Mvc {
+    using System.Collections.Specialized;
+    using System.Web.Helpers;
+
+    // Concrete implementation for the IUnvalidatedRequestValues helper interface
+
+    internal sealed class UnvalidatedRequestValuesWrapper : IUnvalidatedRequestValues {
+
+        private readonly UnvalidatedRequestValues _unvalidatedValues;
+
+        public UnvalidatedRequestValuesWrapper(UnvalidatedRequestValues unvalidatedValues) {
+            _unvalidatedValues = unvalidatedValues;
+        }
+
+        public NameValueCollection Form {
+            get { return _unvalidatedValues.Form; }
+        }
+
+        public NameValueCollection QueryString {
+            get { return _unvalidatedValues.QueryString; }
+        }
+
+        public string this[string key] {
+            get { return _unvalidatedValues[key]; }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/UrlHelper.cs b/mcs/class/System.Web.Mvc3/Mvc/UrlHelper.cs
new file mode 100644 (file)
index 0000000..0e16cc2
--- /dev/null
@@ -0,0 +1,189 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Web.Mvc.Resources;
+    using System.Web.Routing;
+
+    public class UrlHelper {
+        public UrlHelper(RequestContext requestContext)
+            : this(requestContext, RouteTable.Routes) {
+        }
+
+        public UrlHelper(RequestContext requestContext, RouteCollection routeCollection) {
+            if (requestContext == null) {
+                throw new ArgumentNullException("requestContext");
+            }
+            if (routeCollection == null) {
+                throw new ArgumentNullException("routeCollection");
+            }
+            RequestContext = requestContext;
+            RouteCollection = routeCollection;
+        }
+
+        public RequestContext RequestContext {
+            get;
+            private set;
+        }
+
+        public RouteCollection RouteCollection {
+            get;
+            private set;
+        }
+
+        public string Action(string actionName) {
+            return GenerateUrl(null /* routeName */, actionName, null, (RouteValueDictionary)null /* routeValues */);
+        }
+
+        public string Action(string actionName, object routeValues) {
+            return GenerateUrl(null /* routeName */, actionName, null /* controllerName */, new RouteValueDictionary(routeValues));
+        }
+
+        public string Action(string actionName, RouteValueDictionary routeValues) {
+            return GenerateUrl(null /* routeName */, actionName, null /* controllerName */, routeValues);
+        }
+
+        public string Action(string actionName, string controllerName) {
+            return GenerateUrl(null /* routeName */, actionName, controllerName, (RouteValueDictionary)null /* routeValues */);
+        }
+
+        public string Action(string actionName, string controllerName, object routeValues) {
+            return GenerateUrl(null /* routeName */, actionName, controllerName, new RouteValueDictionary(routeValues));
+        }
+
+        public string Action(string actionName, string controllerName, RouteValueDictionary routeValues) {
+            return GenerateUrl(null /* routeName */, actionName, controllerName, routeValues);
+        }
+
+        public string Action(string actionName, string controllerName, object routeValues, string protocol) {
+            return GenerateUrl(null /* routeName */, actionName, controllerName, protocol, null /* hostName */, null /* fragment */, new RouteValueDictionary(routeValues), RouteCollection, RequestContext, true /* includeImplicitMvcValues */);
+        }
+
+        public string Action(string actionName, string controllerName, RouteValueDictionary routeValues, string protocol, string hostName) {
+            return GenerateUrl(null /* routeName */, actionName, controllerName, protocol, hostName, null /* fragment */, routeValues, RouteCollection, RequestContext, true /* includeImplicitMvcValues */);
+        }
+
+        public string Content(string contentPath) {
+            return GenerateContentUrl(contentPath, RequestContext.HttpContext);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public static string GenerateContentUrl(string contentPath, HttpContextBase httpContext) {
+            if (String.IsNullOrEmpty(contentPath)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "contentPath");
+            }
+
+            if (httpContext == null) {
+                throw new ArgumentNullException("httpContext");
+            }
+
+            if (contentPath[0] == '~') {
+                return PathHelpers.GenerateClientUrl(httpContext, contentPath);
+            }
+            else {
+                return contentPath;
+            }
+        }
+
+        //REVIEW: Should we have an overload that takes Uri?
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", Justification = "Needs to take same parameters as HttpUtility.UrlEncode()")]
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "For consistency, all helpers are instance methods.")]
+        public string Encode(string url) {
+            return HttpUtility.UrlEncode(url);
+        }
+
+        private string GenerateUrl(string routeName, string actionName, string controllerName, RouteValueDictionary routeValues) {
+            return GenerateUrl(routeName, actionName, controllerName, routeValues, RouteCollection, RequestContext, true /* includeImplicitMvcValues */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public static string GenerateUrl(string routeName, string actionName, string controllerName, string protocol, string hostName, string fragment, RouteValueDictionary routeValues, RouteCollection routeCollection, RequestContext requestContext, bool includeImplicitMvcValues) {
+            string url = GenerateUrl(routeName, actionName, controllerName, routeValues, routeCollection, requestContext, includeImplicitMvcValues);
+
+            if (url != null) {
+                if (!String.IsNullOrEmpty(fragment)) {
+                    url = url + "#" + fragment;
+                }
+
+                if (!String.IsNullOrEmpty(protocol) || !String.IsNullOrEmpty(hostName)) {
+                    Uri requestUrl = requestContext.HttpContext.Request.Url;
+                    protocol = (!String.IsNullOrEmpty(protocol)) ? protocol : Uri.UriSchemeHttp;
+                    hostName = (!String.IsNullOrEmpty(hostName)) ? hostName : requestUrl.Host;
+
+                    string port = String.Empty;
+                    string requestProtocol = requestUrl.Scheme;
+
+                    if (String.Equals(protocol, requestProtocol, StringComparison.OrdinalIgnoreCase)) {
+                        port = requestUrl.IsDefaultPort ? String.Empty : (":" + Convert.ToString(requestUrl.Port, CultureInfo.InvariantCulture));
+                    }
+
+                    url = protocol + Uri.SchemeDelimiter + hostName + port + url;
+                }
+            }
+
+            return url;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public static string GenerateUrl(string routeName, string actionName, string controllerName, RouteValueDictionary routeValues, RouteCollection routeCollection, RequestContext requestContext, bool includeImplicitMvcValues) {
+            if (routeCollection == null) {
+                throw new ArgumentNullException("routeCollection");
+            }
+
+            if (requestContext == null) {
+                throw new ArgumentNullException("requestContext");
+            }
+
+            RouteValueDictionary mergedRouteValues = RouteValuesHelpers.MergeRouteValues(actionName, controllerName, requestContext.RouteData.Values, routeValues, includeImplicitMvcValues);
+
+            VirtualPathData vpd = routeCollection.GetVirtualPathForArea(requestContext, routeName, mergedRouteValues);
+            if (vpd == null) {
+                return null;
+            }
+
+            string modifiedUrl = PathHelpers.GenerateClientUrl(requestContext.HttpContext, vpd.VirtualPath);
+            return modifiedUrl;
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "0#", Justification = "Response.Redirect() takes its URI as a string parameter.")]
+        public bool IsLocalUrl(string url) {
+            // TODO this should call the System.Web.dll API once it gets added to the framework and MVC takes a dependency on it.
+            return System.Web.WebPages.RequestExtensions.IsUrlLocalToHost(RequestContext.HttpContext.Request, url);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public string RouteUrl(object routeValues) {
+            return RouteUrl(null /* routeName */, routeValues);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public string RouteUrl(RouteValueDictionary routeValues) {
+            return RouteUrl(null /* routeName */, routeValues);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public string RouteUrl(string routeName) {
+            return RouteUrl(routeName, (object)null /* routeValues */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public string RouteUrl(string routeName, object routeValues) {
+            return RouteUrl(routeName, routeValues, null /* protocol */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public string RouteUrl(string routeName, RouteValueDictionary routeValues) {
+            return RouteUrl(routeName, routeValues, null /* protocol */, null /* hostName */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public string RouteUrl(string routeName, object routeValues, string protocol) {
+            return GenerateUrl(routeName, null /* actionName */, null /* controllerName */, protocol, null /* hostName */, null /* fragment */, new RouteValueDictionary(routeValues), RouteCollection, RequestContext, false /* includeImplicitMvcValues */);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1055:UriReturnValuesShouldNotBeStrings", Justification = "As the return value will used only for rendering, string return value is more appropriate.")]
+        public string RouteUrl(string routeName, RouteValueDictionary routeValues, string protocol, string hostName) {
+            return GenerateUrl(routeName, null /* actionName */, null /* controllerName */, protocol, hostName, null /* fragment */, routeValues, RouteCollection, RequestContext, false /* includeImplicitMvcValues */);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/UrlParameter.cs b/mcs/class/System.Web.Mvc3/Mvc/UrlParameter.cs
new file mode 100644 (file)
index 0000000..73ca5ce
--- /dev/null
@@ -0,0 +1,17 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+
+    public sealed class UrlParameter {
+
+        [SuppressMessage("Microsoft.Security", "CA2104:DoNotDeclareReadOnlyMutableReferenceTypes", Justification = "This type is immutable.")]
+        public static readonly UrlParameter Optional = new UrlParameter();
+
+        // singleton constructor
+        private UrlParameter() { }
+
+        public override string ToString() {
+            return String.Empty;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/UrlRewriterHelper.cs b/mcs/class/System.Web.Mvc3/Mvc/UrlRewriterHelper.cs
new file mode 100644 (file)
index 0000000..8d0d5b8
--- /dev/null
@@ -0,0 +1,37 @@
+namespace System.Web.Mvc {
+    using System.Collections.Specialized;
+
+    internal class UrlRewriterHelper {
+        private const string _urlWasRewrittenServerVar = "IIS_WasUrlRewritten";
+        private const string _urlRewriterEnabledServerVar = "IIS_UrlRewriteModule";
+
+        private object _lockObject = new object();
+        private bool _urlRewriterIsTurnedOnValue;
+        private bool _urlRewriterIsTurnedOnCalculated = false;
+
+        private static bool WasThisRequestRewritten(HttpContextBase httpContext) {
+            NameValueCollection serverVars = httpContext.Request.ServerVariables;
+            bool requestWasRewritten = (serverVars != null && serverVars[_urlWasRewrittenServerVar] != null);
+            return requestWasRewritten;
+        }
+
+        private bool IsUrlRewriterTurnedOn(HttpContextBase httpContext) {
+            // Need to do double-check locking because a single instance of this class is shared in the entire app domain (see PathHelpers)
+            if (!_urlRewriterIsTurnedOnCalculated) {
+                lock (_lockObject) {
+                    if (!_urlRewriterIsTurnedOnCalculated) {
+                        NameValueCollection serverVars = httpContext.Request.ServerVariables;
+                        bool urlRewriterIsEnabled = (serverVars != null && serverVars[_urlRewriterEnabledServerVar] != null);
+                        _urlRewriterIsTurnedOnValue = urlRewriterIsEnabled;
+                        _urlRewriterIsTurnedOnCalculated = true;
+                    }
+                }
+            }
+            return _urlRewriterIsTurnedOnValue;
+        }
+
+        public virtual bool WasRequestRewritten(HttpContextBase httpContext) {
+            return IsUrlRewriterTurnedOn(httpContext) && WasThisRequestRewritten(httpContext);
+        }
+    }
+}
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValidatableObjectAdapter.cs b/mcs/class/System.Web.Mvc3/Mvc/ValidatableObjectAdapter.cs
new file mode 100644 (file)
index 0000000..fbccc6d
--- /dev/null
@@ -0,0 +1,54 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.ComponentModel.DataAnnotations;
+    using System.Globalization;
+    using System.Linq;
+    using System.Web.Mvc.Resources;
+
+    public class ValidatableObjectAdapter : ModelValidator {
+        public ValidatableObjectAdapter(ModelMetadata metadata, ControllerContext context)
+            : base(metadata, context) {
+        }
+
+        public override IEnumerable<ModelValidationResult> Validate(object container) {
+            // NOTE: Container is never used here, because IValidatableObject doesn't give you
+            // any way to get access to your container.
+
+            object model = Metadata.Model;
+            if (model == null) {
+                return Enumerable.Empty<ModelValidationResult>();
+            }
+
+            IValidatableObject validatable = model as IValidatableObject;
+            if (validatable == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.ValidatableObjectAdapter_IncompatibleType,
+                        typeof(IValidatableObject).FullName,
+                        model.GetType().FullName
+                    )
+                );
+            }
+
+            ValidationContext validationContext = new ValidationContext(validatable, null, null);
+            return ConvertResults(validatable.Validate(validationContext));
+        }
+
+        private IEnumerable<ModelValidationResult> ConvertResults(IEnumerable<ValidationResult> results) {
+            foreach (ValidationResult result in results) {
+                if (result != ValidationResult.Success) {
+                    if (result.MemberNames == null || !result.MemberNames.Any()) {
+                        yield return new ModelValidationResult { Message = result.ErrorMessage };
+                    }
+                    else {
+                        foreach (string memberName in result.MemberNames) {
+                            yield return new ModelValidationResult { Message = result.ErrorMessage, MemberName = memberName };
+                        }
+                    }
+                }
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValidateAntiForgeryTokenAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/ValidateAntiForgeryTokenAttribute.cs
new file mode 100644 (file)
index 0000000..f6cbf95
--- /dev/null
@@ -0,0 +1,45 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics;
+    using System.Web;
+    using System.Web.Helpers;
+
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
+    public sealed class ValidateAntiForgeryTokenAttribute : FilterAttribute, IAuthorizationFilter {
+
+        private string _salt;
+
+        public string Salt {
+            get {
+                return _salt ?? String.Empty;
+            }
+            set {
+                _salt = value;
+            }
+        }
+
+        internal Action ValidateAction {
+            get;
+            private set;
+        }
+
+        public ValidateAntiForgeryTokenAttribute()
+            : this(AntiForgery.Validate) {
+        }
+
+       //Modified to compile MVC3 with the newer System.Web.WebPages helpers
+        internal ValidateAntiForgeryTokenAttribute(Action validateAction) {
+            Debug.Assert(validateAction != null);
+            ValidateAction = validateAction;
+        }
+
+        public void OnAuthorization(AuthorizationContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+           //Modified to compile MVC3 with the newer System.Web.WebPages helpers
+            ValidateAction();
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValidateInputAttribute.cs b/mcs/class/System.Web.Mvc3/Mvc/ValidateInputAttribute.cs
new file mode 100644 (file)
index 0000000..96a6c18
--- /dev/null
@@ -0,0 +1,27 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+
+    [SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes", Justification = "No compelling performance reason to seal this type.")]
+    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
+    public class ValidateInputAttribute : FilterAttribute, IAuthorizationFilter {
+
+        public ValidateInputAttribute(bool enableValidation) {
+            EnableValidation = enableValidation;
+        }
+
+        public bool EnableValidation {
+            get;
+            private set;
+        }
+
+        public virtual void OnAuthorization(AuthorizationContext filterContext) {
+            if (filterContext == null) {
+                throw new ArgumentNullException("filterContext");
+            }
+
+            filterContext.Controller.ValidateRequest = EnableValidation;
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValueProviderCollection.cs b/mcs/class/System.Web.Mvc3/Mvc/ValueProviderCollection.cs
new file mode 100644 (file)
index 0000000..3bd7944
--- /dev/null
@@ -0,0 +1,55 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+    using System.Linq;
+
+    public class ValueProviderCollection : Collection<IValueProvider>, IValueProvider, IUnvalidatedValueProvider {
+
+        public ValueProviderCollection() {
+        }
+
+        public ValueProviderCollection(IList<IValueProvider> list)
+            : base(list) {
+        }
+
+        public virtual bool ContainsPrefix(string prefix) {
+            return this.Any(vp => vp.ContainsPrefix(prefix));
+        }
+
+        public virtual ValueProviderResult GetValue(string key) {
+            return GetValue(key, skipValidation: false);
+        }
+
+        public virtual ValueProviderResult GetValue(string key, bool skipValidation) {
+            return (from provider in this
+                    let result = GetValueFromProvider(provider, key, skipValidation)
+                    where result != null
+                    select result).FirstOrDefault();
+        }
+
+        internal static ValueProviderResult GetValueFromProvider(IValueProvider provider, string key, bool skipValidation) {
+            // Since IUnvalidatedValueProvider is a superset of IValueProvider, it's always OK to use the
+            // IUnvalidatedValueProvider-supplied members if they're present. Otherwise just call the
+            // normal IValueProvider members.
+
+            IUnvalidatedValueProvider unvalidatedProvider = provider as IUnvalidatedValueProvider;
+            return (unvalidatedProvider != null) ? unvalidatedProvider.GetValue(key, skipValidation) : provider.GetValue(key);
+        }
+
+        protected override void InsertItem(int index, IValueProvider item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.InsertItem(index, item);
+        }
+
+        protected override void SetItem(int index, IValueProvider item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.SetItem(index, item);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValueProviderDictionary.cs b/mcs/class/System.Web.Mvc3/Mvc/ValueProviderDictionary.cs
new file mode 100644 (file)
index 0000000..60f7e23
--- /dev/null
@@ -0,0 +1,194 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Collections.Specialized;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Web.Routing;
+
+    [Obsolete("The recommended alternative is to use one of the specific ValueProvider types, such as FormValueProvider.")]
+    public class ValueProviderDictionary : IDictionary<string, ValueProviderResult>, IValueProvider {
+
+        private readonly Dictionary<string, ValueProviderResult> _dictionary = new Dictionary<string, ValueProviderResult>(StringComparer.OrdinalIgnoreCase);
+
+        public ValueProviderDictionary(ControllerContext controllerContext) {
+            ControllerContext = controllerContext;
+            if (controllerContext != null) {
+                PopulateDictionary();
+            }
+        }
+
+        public ControllerContext ControllerContext {
+            get;
+            private set;
+        }
+
+        public int Count {
+            get {
+                return ((ICollection<KeyValuePair<string, ValueProviderResult>>)Dictionary).Count;
+            }
+        }
+
+        internal Dictionary<string, ValueProviderResult> Dictionary {
+            get {
+                return _dictionary;
+            }
+        }
+
+        public bool IsReadOnly {
+            get {
+                return ((ICollection<KeyValuePair<string, ValueProviderResult>>)Dictionary).IsReadOnly;
+            }
+        }
+
+        public ICollection<string> Keys {
+            get {
+                return Dictionary.Keys;
+            }
+        }
+
+        public ValueProviderResult this[string key] {
+            get {
+                ValueProviderResult result;
+                Dictionary.TryGetValue(key, out result);
+                return result;
+            }
+            set {
+                Dictionary[key] = value;
+            }
+        }
+
+        public ICollection<ValueProviderResult> Values {
+            get {
+                return Dictionary.Values;
+            }
+        }
+
+        public void Add(KeyValuePair<string, ValueProviderResult> item) {
+            ((ICollection<KeyValuePair<string, ValueProviderResult>>)Dictionary).Add(item);
+        }
+
+        public void Add(string key, object value) {
+            string attemptedValue = Convert.ToString(value, CultureInfo.InvariantCulture);
+            ValueProviderResult vpResult = new ValueProviderResult(value, attemptedValue, CultureInfo.InvariantCulture);
+            Add(key, vpResult);
+        }
+
+        public void Add(string key, ValueProviderResult value) {
+            Dictionary.Add(key, value);
+        }
+
+        private void AddToDictionaryIfNotPresent(string key, ValueProviderResult result) {
+            if (!String.IsNullOrEmpty(key)) {
+                if (!Dictionary.ContainsKey(key)) {
+                    Dictionary.Add(key, result);
+                }
+            }
+        }
+
+        public void Clear() {
+            ((ICollection<KeyValuePair<string, ValueProviderResult>>)Dictionary).Clear();
+        }
+
+        public bool Contains(KeyValuePair<string, ValueProviderResult> item) {
+            return ((ICollection<KeyValuePair<string, ValueProviderResult>>)Dictionary).Contains(item);
+        }
+
+        public bool ContainsKey(string key) {
+            return Dictionary.ContainsKey(key);
+        }
+
+        public void CopyTo(KeyValuePair<string, ValueProviderResult>[] array, int arrayIndex) {
+            ((ICollection<KeyValuePair<string, ValueProviderResult>>)Dictionary).CopyTo(array, arrayIndex);
+        }
+
+        public IEnumerator<KeyValuePair<string, ValueProviderResult>> GetEnumerator() {
+            return ((IEnumerable<KeyValuePair<string, ValueProviderResult>>)Dictionary).GetEnumerator();
+        }
+
+        private void PopulateDictionary() {
+            CultureInfo currentCulture = CultureInfo.CurrentCulture;
+            CultureInfo invariantCulture = CultureInfo.InvariantCulture;
+
+            // We use this order of precedence to populate the dictionary:
+            // 1. Request form submission (should be culture-aware)
+            // 2. Values from the RouteData (could be from the typed-in URL or from the route's default values)
+            // 3. URI query string
+
+            NameValueCollection form = ControllerContext.HttpContext.Request.Form;
+            if (form != null) {
+                string[] keys = form.AllKeys;
+                foreach (string key in keys) {
+                    string[] rawValue = form.GetValues(key);
+                    string attemptedValue = form[key];
+                    ValueProviderResult result = new ValueProviderResult(rawValue, attemptedValue, currentCulture);
+                    AddToDictionaryIfNotPresent(key, result);
+                }
+            }
+
+            RouteValueDictionary routeValues = ControllerContext.RouteData.Values;
+            if (routeValues != null) {
+                foreach (var kvp in routeValues) {
+                    string key = kvp.Key;
+                    object rawValue = kvp.Value;
+                    string attemptedValue = Convert.ToString(rawValue, invariantCulture);
+                    ValueProviderResult result = new ValueProviderResult(rawValue, attemptedValue, invariantCulture);
+                    AddToDictionaryIfNotPresent(key, result);
+                }
+            }
+
+            NameValueCollection queryString = ControllerContext.HttpContext.Request.QueryString;
+            if (queryString != null) {
+                string[] keys = queryString.AllKeys;
+                foreach (string key in keys) {
+                    string[] rawValue = queryString.GetValues(key);
+                    string attemptedValue = queryString[key];
+                    ValueProviderResult result = new ValueProviderResult(rawValue, attemptedValue, invariantCulture);
+                    AddToDictionaryIfNotPresent(key, result);
+                }
+            }
+        }
+
+        public bool Remove(KeyValuePair<string, ValueProviderResult> item) {
+            return ((ICollection<KeyValuePair<string, ValueProviderResult>>)Dictionary).Remove(item);
+        }
+
+        public bool Remove(string key) {
+            return Dictionary.Remove(key);
+        }
+
+        public bool TryGetValue(string key, out ValueProviderResult value) {
+            return Dictionary.TryGetValue(key, out value);
+        }
+
+        #region IEnumerable Members
+        IEnumerator IEnumerable.GetEnumerator() {
+            return ((IEnumerable)Dictionary).GetEnumerator();
+        }
+        #endregion
+
+        #region IValueProvider Members
+        [SuppressMessage("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes", Justification = "The declaring type is obsolete, so there is little benefit to exposing this as a virtual method.")]
+        bool IValueProvider.ContainsPrefix(string prefix) {
+            if (prefix == null) {
+                throw new ArgumentNullException("prefix");
+            }
+
+            return ValueProviderUtil.CollectionContainsPrefix(Keys, prefix);
+        }
+
+        [SuppressMessage("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes", Justification = "The declaring type is obsolete, so there is little benefit to exposing this as a virtual method.")]
+        ValueProviderResult IValueProvider.GetValue(string key) {
+            if (key == null) {
+                throw new ArgumentNullException("key");
+            }
+
+            ValueProviderResult vpResult;
+            TryGetValue(key, out vpResult);
+            return vpResult;
+        }
+        #endregion
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValueProviderFactories.cs b/mcs/class/System.Web.Mvc3/Mvc/ValueProviderFactories.cs
new file mode 100644 (file)
index 0000000..bf9df94
--- /dev/null
@@ -0,0 +1,22 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public static class ValueProviderFactories {
+
+        private static readonly ValueProviderFactoryCollection _factories = new ValueProviderFactoryCollection() {
+            new ChildActionValueProviderFactory(),
+            new FormValueProviderFactory(),
+            new JsonValueProviderFactory(),
+            new RouteDataValueProviderFactory(),
+            new QueryStringValueProviderFactory(),
+            new HttpFileCollectionValueProviderFactory(),
+        };
+
+        public static ValueProviderFactoryCollection Factories {
+            get {
+                return _factories;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValueProviderFactory.cs b/mcs/class/System.Web.Mvc3/Mvc/ValueProviderFactory.cs
new file mode 100644 (file)
index 0000000..52d4fac
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public abstract class ValueProviderFactory {
+        public abstract IValueProvider GetValueProvider(ControllerContext controllerContext);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValueProviderFactoryCollection.cs b/mcs/class/System.Web.Mvc3/Mvc/ValueProviderFactoryCollection.cs
new file mode 100644 (file)
index 0000000..14a1dbf
--- /dev/null
@@ -0,0 +1,51 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+    using System.Linq;
+
+    public class ValueProviderFactoryCollection : Collection<ValueProviderFactory> {
+        private IResolver<IEnumerable<ValueProviderFactory>> _serviceResolver;
+
+        public ValueProviderFactoryCollection() {
+            _serviceResolver = new MultiServiceResolver<ValueProviderFactory>(() => Items);
+        }
+
+        public ValueProviderFactoryCollection(IList<ValueProviderFactory> list)
+            : base(list) {
+            _serviceResolver = new MultiServiceResolver<ValueProviderFactory>(() => Items);
+        }
+
+        internal ValueProviderFactoryCollection(IResolver<IEnumerable<ValueProviderFactory>> serviceResolver, params ValueProviderFactory[] valueProviderFactories)
+            : base(valueProviderFactories) {
+            _serviceResolver = serviceResolver ?? new MultiServiceResolver<ValueProviderFactory>(
+                   () => Items
+                   );
+        }
+
+        public IValueProvider GetValueProvider(ControllerContext controllerContext) {
+            var valueProviders = from factory in _serviceResolver.Current
+                                 let valueProvider = factory.GetValueProvider(controllerContext)
+                                 where valueProvider != null
+                                 select valueProvider;
+
+            return new ValueProviderCollection(valueProviders.ToList());
+        }
+
+
+        protected override void InsertItem(int index, ValueProviderFactory item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.InsertItem(index, item);
+        }
+
+        protected override void SetItem(int index, ValueProviderFactory item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.SetItem(index, item);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValueProviderResult.cs b/mcs/class/System.Web.Mvc3/Mvc/ValueProviderResult.cs
new file mode 100644 (file)
index 0000000..6c36dc2
--- /dev/null
@@ -0,0 +1,135 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.ComponentModel;
+    using System.Globalization;
+    using System.Web.Mvc.Resources;
+
+    [Serializable]
+    public class ValueProviderResult {
+
+        private static readonly CultureInfo _staticCulture = CultureInfo.InvariantCulture;
+        private CultureInfo _instanceCulture;
+
+        // default constructor so that subclassed types can set the properties themselves
+        protected ValueProviderResult() {
+        }
+
+        public ValueProviderResult(object rawValue, string attemptedValue, CultureInfo culture) {
+            RawValue = rawValue;
+            AttemptedValue = attemptedValue;
+            Culture = culture;
+        }
+
+        public string AttemptedValue {
+            get;
+            protected set;
+        }
+
+        public CultureInfo Culture {
+            get {
+                if (_instanceCulture == null) {
+                    _instanceCulture = _staticCulture;
+                }
+                return _instanceCulture;
+            }
+            protected set {
+                _instanceCulture = value;
+            }
+        }
+
+        public object RawValue {
+            get;
+            protected set;
+        }
+
+        private static object ConvertSimpleType(CultureInfo culture, object value, Type destinationType) {
+            if (value == null || destinationType.IsInstanceOfType(value)) {
+                return value;
+            }
+
+            // if this is a user-input value but the user didn't type anything, return no value
+            string valueAsString = value as string;
+            if (valueAsString != null && valueAsString.Trim().Length == 0) {
+                return null;
+            }
+
+            TypeConverter converter = TypeDescriptor.GetConverter(destinationType);
+            bool canConvertFrom = converter.CanConvertFrom(value.GetType());
+            if (!canConvertFrom) {
+                converter = TypeDescriptor.GetConverter(value.GetType());
+            }
+            if (!(canConvertFrom || converter.CanConvertTo(destinationType))) {
+                string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ValueProviderResult_NoConverterExists,
+                    value.GetType().FullName, destinationType.FullName);
+                throw new InvalidOperationException(message);
+            }
+
+            try {
+                object convertedValue = (canConvertFrom) ?
+                     converter.ConvertFrom(null /* context */, culture, value) :
+                     converter.ConvertTo(null /* context */, culture, value, destinationType);
+                return convertedValue;
+            }
+            catch (Exception ex) {
+                string message = String.Format(CultureInfo.CurrentCulture, MvcResources.ValueProviderResult_ConversionThrew,
+                    value.GetType().FullName, destinationType.FullName);
+                throw new InvalidOperationException(message, ex);
+            }
+        }
+
+        public object ConvertTo(Type type) {
+            return ConvertTo(type, null /* culture */);
+        }
+
+        public virtual object ConvertTo(Type type, CultureInfo culture) {
+            if (type == null) {
+                throw new ArgumentNullException("type");
+            }
+
+            CultureInfo cultureToUse = culture ?? Culture;
+            return UnwrapPossibleArrayType(cultureToUse, RawValue, type);
+        }
+
+        private static object UnwrapPossibleArrayType(CultureInfo culture, object value, Type destinationType) {
+            if (value == null || destinationType.IsInstanceOfType(value)) {
+                return value;
+            }
+
+            // array conversion results in four cases, as below
+            Array valueAsArray = value as Array;
+            if (destinationType.IsArray) {
+                Type destinationElementType = destinationType.GetElementType();
+                if (valueAsArray != null) {
+                    // case 1: both destination + source type are arrays, so convert each element
+                    IList converted = Array.CreateInstance(destinationElementType, valueAsArray.Length);
+                    for (int i = 0; i < valueAsArray.Length; i++) {
+                        converted[i] = ConvertSimpleType(culture, valueAsArray.GetValue(i), destinationElementType);
+                    }
+                    return converted;
+                }
+                else {
+                    // case 2: destination type is array but source is single element, so wrap element in array + convert
+                    object element = ConvertSimpleType(culture, value, destinationElementType);
+                    IList converted = Array.CreateInstance(destinationElementType, 1);
+                    converted[0] = element;
+                    return converted;
+                }
+            }
+            else if (valueAsArray != null) {
+                // case 3: destination type is single element but source is array, so extract first element + convert
+                if (valueAsArray.Length > 0) {
+                    value = valueAsArray.GetValue(0);
+                    return ConvertSimpleType(culture, value, destinationType);
+                }
+                else {
+                    // case 3(a): source is empty array, so can't perform conversion
+                    return null;
+                }
+            }
+            // case 4: both destination + source type are single elements, so convert
+            return ConvertSimpleType(culture, value, destinationType);
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ValueProviderUtil.cs b/mcs/class/System.Web.Mvc3/Mvc/ValueProviderUtil.cs
new file mode 100644 (file)
index 0000000..09e0e38
--- /dev/null
@@ -0,0 +1,51 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Linq;
+
+    internal static class ValueProviderUtil {
+
+        // Given "foo.bar[baz].quux", this method will return:
+        // - "foo.bar[baz].quux"
+        // - "foo.bar[baz]"
+        // - "foo.bar"
+        // - "foo"
+        public static IEnumerable<string> GetPrefixes(string key) {
+            yield return key;
+            for (int i = key.Length - 1; i >= 0; i--) {
+                switch (key[i]) {
+                    case '.':
+                    case '[':
+                        yield return key.Substring(0, i);
+                        break;
+                }
+            }
+        }
+
+        public static bool CollectionContainsPrefix(IEnumerable<string> collection, string prefix) {
+            foreach (string key in collection) {
+                if (key != null) {
+                    if (prefix.Length == 0) {
+                        return true; // shortcut - non-null key matches empty prefix
+                    }
+
+                    if (key.StartsWith(prefix, StringComparison.OrdinalIgnoreCase)) {
+                        if (key.Length == prefix.Length) {
+                            return true; // exact match
+                        }
+                        else {
+                            switch (key[prefix.Length]) {
+                                case '.': // known separator characters
+                                case '[':
+                                    return true;
+                            }
+                        }
+                    }
+                }
+            }
+
+            return false; // nothing found
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewContext.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewContext.cs
new file mode 100644 (file)
index 0000000..fc68729
--- /dev/null
@@ -0,0 +1,259 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.IO;
+    using System.Web.WebPages.Scope;
+
+    public class ViewContext : ControllerContext {
+
+        private const string _clientValidationScript = @"<script type=""text/javascript"">
+//<![CDATA[
+if (!window.mvcClientValidationMetadata) {{ window.mvcClientValidationMetadata = []; }}
+window.mvcClientValidationMetadata.push({0});
+//]]>
+</script>";
+
+        internal static readonly string ClientValidationKeyName = "ClientValidationEnabled";
+        internal static readonly string UnobtrusiveJavaScriptKeyName = "UnobtrusiveJavaScriptEnabled";
+
+        // Some values have to be stored in HttpContext.Items in order to be propagated between calls
+        // to RenderPartial(), RenderAction(), etc.
+        private static readonly object _formContextKey = new object();
+        private static readonly object _lastFormNumKey = new object();
+
+        private Func<IDictionary<object, object>> _scopeThunk;
+        private IDictionary<object, object> _transientScope;
+
+        private Func<string> _formIdGenerator;
+
+        // parameterless constructor used for mocking
+        public ViewContext() {
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
+        public ViewContext(ControllerContext controllerContext, IView view, ViewDataDictionary viewData, TempDataDictionary tempData, TextWriter writer)
+            : base(controllerContext) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (view == null) {
+                throw new ArgumentNullException("view");
+            }
+            if (viewData == null) {
+                throw new ArgumentNullException("viewData");
+            }
+            if (tempData == null) {
+                throw new ArgumentNullException("tempData");
+            }
+            if (writer == null) {
+                throw new ArgumentNullException("writer");
+            }
+
+            View = view;
+            ViewData = viewData;
+            Writer = writer;
+            TempData = tempData;
+        }
+
+        public virtual bool ClientValidationEnabled {
+            get {
+                return GetClientValidationEnabled(Scope, HttpContext);
+            }
+            set {
+                SetClientValidationEnabled(value, Scope, HttpContext);
+            }
+        }
+
+        public virtual FormContext FormContext {
+            get {
+                return HttpContext.Items[_formContextKey] as FormContext;
+            }
+            set {
+                HttpContext.Items[_formContextKey] = value;
+            }
+        }
+
+        internal Func<string> FormIdGenerator {
+            get {
+                if (_formIdGenerator == null) {
+                    _formIdGenerator = DefaultFormIdGenerator;
+                }
+                return _formIdGenerator;
+            }
+            set {
+                _formIdGenerator = value;
+            }
+        }
+
+        internal static Func<IDictionary<object, object>> GlobalScopeThunk {
+            get;
+            set;
+        }
+
+        private IDictionary<object, object> Scope {
+            get {
+                if (ScopeThunk != null) {
+                    return ScopeThunk();
+                }
+                if (_transientScope == null) {
+                    _transientScope = new Dictionary<object, object>();
+                }
+                return _transientScope;
+            }
+        }
+
+        internal Func<IDictionary<object, object>> ScopeThunk {
+            get {
+                return _scopeThunk ?? GlobalScopeThunk;
+            }
+            set {
+                _scopeThunk = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "The property setter is only here to support mocking this type and should not be called at runtime.")]
+        public virtual TempDataDictionary TempData {
+            get;
+            set;
+        }
+
+        public virtual bool UnobtrusiveJavaScriptEnabled {
+            get {
+                return GetUnobtrusiveJavaScriptEnabled(Scope, HttpContext);
+            }
+            set {
+                SetUnobtrusiveJavaScriptEnabled(value, Scope, HttpContext);
+            }
+        }
+
+        public virtual IView View {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "The property setter is only here to support mocking this type and should not be called at runtime.")]
+        public virtual ViewDataDictionary ViewData {
+            get;
+            set;
+        }
+
+        public virtual TextWriter Writer {
+            get;
+            set;
+        }
+
+        private string DefaultFormIdGenerator() {
+            int formNum = IncrementFormCount(HttpContext.Items);
+            return String.Format(CultureInfo.InvariantCulture, "form{0}", formNum);
+        }
+
+        internal static bool GetClientValidationEnabled(IDictionary<object, object> scope = null, HttpContextBase httpContext = null) {
+            return ScopeCache.Get(scope, httpContext).ClientValidationEnabled;
+        }
+
+        internal FormContext GetFormContextForClientValidation() {
+            return (ClientValidationEnabled) ? FormContext : null;
+        }
+
+        internal static bool GetUnobtrusiveJavaScriptEnabled(IDictionary<object, object> scope = null, HttpContextBase httpContext = null) {
+            return ScopeCache.Get(scope, httpContext).UnobtrusiveJavaScriptEnabled;
+        }
+
+        private static int IncrementFormCount(IDictionary items) {
+            object lastFormNum = items[_lastFormNumKey];
+            int newFormNum = (lastFormNum != null) ? ((int)lastFormNum) + 1 : 0;
+            items[_lastFormNumKey] = newFormNum;
+            return newFormNum;
+        }
+
+        public void OutputClientValidation() {
+            FormContext formContext = GetFormContextForClientValidation();
+            if (formContext == null || UnobtrusiveJavaScriptEnabled) {
+                return; // do nothing
+            }
+
+            string scriptWithCorrectNewLines = _clientValidationScript.Replace("\r\n", Environment.NewLine);
+            string validationJson = formContext.GetJsonValidationMetadata();
+            string formatted = String.Format(CultureInfo.InvariantCulture, scriptWithCorrectNewLines, validationJson);
+
+            Writer.Write(formatted);
+            FormContext = null;
+        }
+
+        internal static void SetClientValidationEnabled(bool enabled, IDictionary<object, object> scope = null, HttpContextBase httpContext = null) {
+            ScopeCache.Get(scope, httpContext).ClientValidationEnabled = enabled;
+        }
+
+        internal static void SetUnobtrusiveJavaScriptEnabled(bool enabled, IDictionary<object, object> scope = null, HttpContextBase httpContext = null) {
+            ScopeCache.Get(scope, httpContext).UnobtrusiveJavaScriptEnabled = enabled;
+        }
+
+        private static TValue ScopeGet<TValue>(IDictionary<object, object> scope, string name, TValue defaultValue = default(TValue)) {
+            object result;
+            if (scope.TryGetValue(name, out result)) {
+                return (TValue)Convert.ChangeType(result, typeof(TValue), CultureInfo.InvariantCulture);
+            }
+            return defaultValue;
+        }
+
+        private sealed class ScopeCache {
+            private static readonly object _cacheKey = new object();
+            private bool _clientValidationEnabled;
+            private IDictionary<object, object> _scope;
+            private bool _unobtrusiveJavaScriptEnabled;
+
+            private ScopeCache(IDictionary<object, object> scope) {
+                _scope = scope;
+
+                _clientValidationEnabled = ScopeGet(scope, ClientValidationKeyName, false);
+                _unobtrusiveJavaScriptEnabled = ScopeGet(scope, UnobtrusiveJavaScriptKeyName, false);
+            }
+
+            public bool ClientValidationEnabled {
+                get {
+                    return _clientValidationEnabled;
+                }
+                set {
+                    _clientValidationEnabled = value;
+                    _scope[ClientValidationKeyName] = value;
+                }
+            }
+
+            public bool UnobtrusiveJavaScriptEnabled {
+                get {
+                    return _unobtrusiveJavaScriptEnabled;
+                }
+                set {
+                    _unobtrusiveJavaScriptEnabled = value;
+                    _scope[UnobtrusiveJavaScriptKeyName] = value;
+                }
+            }
+
+            public static ScopeCache Get(IDictionary<object, object> scope, HttpContextBase httpContext) {
+                if (httpContext == null && System.Web.HttpContext.Current != null) {
+                    httpContext = new HttpContextWrapper(System.Web.HttpContext.Current);
+                }
+
+                ScopeCache result = null;
+                scope = scope ?? ScopeStorage.CurrentScope;
+
+                if (httpContext != null) {
+                    result = httpContext.Items[_cacheKey] as ScopeCache;
+                }
+
+                if (result == null || result._scope != scope) {
+                    result = new ScopeCache(scope);
+
+                    if (httpContext != null) {
+                        httpContext.Items[_cacheKey] = result;
+                    }
+                }
+
+                return result;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewDataDictionary.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewDataDictionary.cs
new file mode 100644 (file)
index 0000000..576280e
--- /dev/null
@@ -0,0 +1,340 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.ComponentModel;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Reflection;
+    using System.Web.Mvc.Resources;
+
+    // TODO: Unit test ModelState interaction with VDD
+
+    public class ViewDataDictionary : IDictionary<string, object> {
+
+        private readonly Dictionary<string, object> _innerDictionary = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
+        private object _model;
+        private ModelMetadata _modelMetadata;
+        private readonly ModelStateDictionary _modelState = new ModelStateDictionary();
+        private TemplateInfo _templateMetadata;
+
+        public ViewDataDictionary()
+            : this((object)null) {
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "See note on SetModel() method.")]
+        public ViewDataDictionary(object model) {
+            Model = model;
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors", Justification = "See note on SetModel() method.")]
+        public ViewDataDictionary(ViewDataDictionary dictionary) {
+            if (dictionary == null) {
+                throw new ArgumentNullException("dictionary");
+            }
+
+            foreach (var entry in dictionary) {
+                _innerDictionary.Add(entry.Key, entry.Value);
+            }
+            foreach (var entry in dictionary.ModelState) {
+                ModelState.Add(entry.Key, entry.Value);
+            }
+
+            Model = dictionary.Model;
+            TemplateInfo = dictionary.TemplateInfo;
+
+            // PERF: Don't unnecessarily instantiate the model metadata
+            _modelMetadata = dictionary._modelMetadata;
+        }
+
+        public int Count {
+            get {
+                return _innerDictionary.Count;
+            }
+        }
+
+        public bool IsReadOnly {
+            get {
+                return ((IDictionary<string, object>)_innerDictionary).IsReadOnly;
+            }
+        }
+
+        public ICollection<string> Keys {
+            get {
+                return _innerDictionary.Keys;
+            }
+        }
+
+        public object Model {
+            get {
+                return _model;
+            }
+            set {
+                _modelMetadata = null;
+                SetModel(value);
+            }
+        }
+
+        public virtual ModelMetadata ModelMetadata {
+            get {
+                if (_modelMetadata == null && _model != null) {
+                    _modelMetadata = ModelMetadataProviders.Current.GetMetadataForType(() => _model, _model.GetType());
+                }
+                return _modelMetadata;
+            }
+            set {
+                _modelMetadata = value;
+            }
+        }
+
+        public ModelStateDictionary ModelState {
+            get {
+                return _modelState;
+            }
+        }
+
+        public object this[string key] {
+            get {
+                object value;
+                _innerDictionary.TryGetValue(key, out value);
+                return value;
+            }
+            set {
+                _innerDictionary[key] = value;
+            }
+        }
+
+        public TemplateInfo TemplateInfo {
+            get {
+                if (_templateMetadata == null) {
+                    _templateMetadata = new TemplateInfo();
+                }
+                return _templateMetadata;
+            }
+            set {
+                _templateMetadata = value;
+            }
+        }
+
+        public ICollection<object> Values {
+            get {
+                return _innerDictionary.Values;
+            }
+        }
+
+        public void Add(KeyValuePair<string, object> item) {
+            ((IDictionary<string, object>)_innerDictionary).Add(item);
+        }
+
+        public void Add(string key, object value) {
+            _innerDictionary.Add(key, value);
+        }
+
+        public void Clear() {
+            _innerDictionary.Clear();
+        }
+
+        public bool Contains(KeyValuePair<string, object> item) {
+            return ((IDictionary<string, object>)_innerDictionary).Contains(item);
+        }
+
+        public bool ContainsKey(string key) {
+            return _innerDictionary.ContainsKey(key);
+        }
+
+        public void CopyTo(KeyValuePair<string, object>[] array, int arrayIndex) {
+            ((IDictionary<string, object>)_innerDictionary).CopyTo(array, arrayIndex);
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Eval", Justification = "Commonly used shorthand for Evaluate.")]
+        public object Eval(string expression) {
+            ViewDataInfo info = GetViewDataInfo(expression);
+            return (info != null) ? info.Value : null;
+        }
+
+        [SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Eval", Justification = "Commonly used shorthand for Evaluate.")]
+        public string Eval(string expression, string format) {
+            object value = Eval(expression);
+
+            if (value == null) {
+                return String.Empty;
+            }
+
+            if (String.IsNullOrEmpty(format)) {
+                return Convert.ToString(value, CultureInfo.CurrentCulture);
+            }
+            else {
+                return String.Format(CultureInfo.CurrentCulture, format, value);
+            }
+        }
+
+        public IEnumerator<KeyValuePair<string, object>> GetEnumerator() {
+            return _innerDictionary.GetEnumerator();
+        }
+
+        public ViewDataInfo GetViewDataInfo(string expression) {
+            if (String.IsNullOrEmpty(expression)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "expression");
+            }
+
+            return ViewDataEvaluator.Eval(this, expression);
+        }
+
+        public bool Remove(KeyValuePair<string, object> item) {
+            return ((IDictionary<string, object>)_innerDictionary).Remove(item);
+        }
+
+        public bool Remove(string key) {
+            return _innerDictionary.Remove(key);
+        }
+
+        // This method will execute before the derived type's instance constructor executes. Derived types must
+        // be aware of this and should plan accordingly. For example, the logic in SetModel() should be simple
+        // enough so as not to depend on the "this" pointer referencing a fully constructed object.
+        protected virtual void SetModel(object value) {
+            _model = value;
+        }
+
+        public bool TryGetValue(string key, out object value) {
+            return _innerDictionary.TryGetValue(key, out value);
+        }
+
+        internal static class ViewDataEvaluator {
+
+            public static ViewDataInfo Eval(ViewDataDictionary vdd, string expression) {
+                //Given an expression "foo.bar.baz" we look up the following (pseudocode):
+                //  this["foo.bar.baz.quux"]
+                //  this["foo.bar.baz"]["quux"]
+                //  this["foo.bar"]["baz.quux]
+                //  this["foo.bar"]["baz"]["quux"]
+                //  this["foo"]["bar.baz.quux"]
+                //  this["foo"]["bar.baz"]["quux"]
+                //  this["foo"]["bar"]["baz.quux"]
+                //  this["foo"]["bar"]["baz"]["quux"]
+
+                ViewDataInfo evaluated = EvalComplexExpression(vdd, expression);
+                return evaluated;
+            }
+
+            private static ViewDataInfo EvalComplexExpression(object indexableObject, string expression) {
+                foreach (ExpressionPair expressionPair in GetRightToLeftExpressions(expression)) {
+                    string subExpression = expressionPair.Left;
+                    string postExpression = expressionPair.Right;
+
+                    ViewDataInfo subTargetInfo = GetPropertyValue(indexableObject, subExpression);
+                    if (subTargetInfo != null) {
+                        if (String.IsNullOrEmpty(postExpression)) {
+                            return subTargetInfo;
+                        }
+
+                        if (subTargetInfo.Value != null) {
+                            ViewDataInfo potential = EvalComplexExpression(subTargetInfo.Value, postExpression);
+                            if (potential != null) {
+                                return potential;
+                            }
+                        }
+                    }
+                }
+                return null;
+            }
+
+            private static IEnumerable<ExpressionPair> GetRightToLeftExpressions(string expression) {
+                // Produces an enumeration of all the combinations of complex property names
+                // given a complex expression. See the list above for an example of the result
+                // of the enumeration.
+
+                yield return new ExpressionPair(expression, String.Empty);
+
+                int lastDot = expression.LastIndexOf('.');
+
+                string subExpression = expression;
+                string postExpression = string.Empty;
+
+                while (lastDot > -1) {
+                    subExpression = expression.Substring(0, lastDot);
+                    postExpression = expression.Substring(lastDot + 1);
+                    yield return new ExpressionPair(subExpression, postExpression);
+
+                    lastDot = subExpression.LastIndexOf('.');
+                }
+            }
+
+            private static ViewDataInfo GetIndexedPropertyValue(object indexableObject, string key) {
+                IDictionary<string, object> dict = indexableObject as IDictionary<string, object>;
+                object value = null;
+                bool success = false;
+
+                if (dict != null) {
+                    success = dict.TryGetValue(key, out value);
+                }
+                else {
+                    TryGetValueDelegate tgvDel = TypeHelpers.CreateTryGetValueDelegate(indexableObject.GetType());
+                    if (tgvDel != null) {
+                        success = tgvDel(indexableObject, key, out value);
+                    }
+                }
+
+                if (success) {
+                    return new ViewDataInfo() {
+                        Container = indexableObject,
+                        Value = value
+                    };
+                }
+
+                return null;
+            }
+
+            private static ViewDataInfo GetPropertyValue(object container, string propertyName) {
+                // This method handles one "segment" of a complex property expression
+
+                // First, we try to evaluate the property based on its indexer
+                ViewDataInfo value = GetIndexedPropertyValue(container, propertyName);
+                if (value != null) {
+                    return value;
+                }
+
+                // If the indexer didn't return anything useful, continue...
+
+                // If the container is a ViewDataDictionary then treat its Model property
+                // as the container instead of the ViewDataDictionary itself.
+                ViewDataDictionary vdd = container as ViewDataDictionary;
+                if (vdd != null) {
+                    container = vdd.Model;
+                }
+
+                // If the container is null, we're out of options
+                if (container == null) {
+                    return null;
+                }
+
+                // Second, we try to use PropertyDescriptors and treat the expression as a property name
+                PropertyDescriptor descriptor = TypeDescriptor.GetProperties(container).Find(propertyName, true);
+                if (descriptor == null) {
+                    return null;
+                }
+
+                return new ViewDataInfo(() => descriptor.GetValue(container)) {
+                    Container = container,
+                    PropertyDescriptor = descriptor
+                };
+            }
+
+            private struct ExpressionPair {
+                public readonly string Left;
+                public readonly string Right;
+
+                public ExpressionPair(string left, string right) {
+                    Left = left;
+                    Right = right;
+                }
+            }
+        }
+
+        #region IEnumerable Members
+        IEnumerator IEnumerable.GetEnumerator() {
+            return ((IEnumerable)_innerDictionary).GetEnumerator();
+        }
+        #endregion
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewDataDictionary`1.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewDataDictionary`1.cs
new file mode 100644 (file)
index 0000000..3c9c9c4
--- /dev/null
@@ -0,0 +1,54 @@
+namespace System.Web.Mvc {
+    using System;
+
+    public class ViewDataDictionary<TModel> : ViewDataDictionary {
+        public ViewDataDictionary() :
+            base(default(TModel)) {
+        }
+
+        public ViewDataDictionary(TModel model) :
+            base(model) {
+        }
+
+        public ViewDataDictionary(ViewDataDictionary viewDataDictionary) :
+            base(viewDataDictionary) {
+        }
+
+        public new TModel Model {
+            get {
+                return (TModel)base.Model;
+            }
+            set {
+                SetModel(value);
+            }
+        }
+
+        public override ModelMetadata ModelMetadata {
+            get {
+                ModelMetadata result = base.ModelMetadata;
+                if (result == null) {
+                    result = base.ModelMetadata = ModelMetadataProviders.Current.GetMetadataForType(null, typeof(TModel));
+                }
+                return result;
+            }
+            set {
+                base.ModelMetadata = value;
+            }
+        }
+
+        protected override void SetModel(object value) {
+            bool castWillSucceed = TypeHelpers.IsCompatibleObject<TModel>(value);
+
+            if (castWillSucceed) {
+                base.SetModel((TModel)value);
+            }
+            else {
+                InvalidOperationException exception = (value != null)
+                    ? Error.ViewDataDictionary_WrongTModelType(value.GetType(), typeof(TModel))
+                    : Error.ViewDataDictionary_ModelCannotBeNull(typeof(TModel));
+                throw exception;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewDataInfo.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewDataInfo.cs
new file mode 100644 (file)
index 0000000..31e0201
--- /dev/null
@@ -0,0 +1,43 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.ComponentModel;
+
+    public class ViewDataInfo {
+
+        private object _value;
+        private Func<object> _valueAccessor;
+
+        public ViewDataInfo() {
+        }
+
+        public ViewDataInfo(Func<object> valueAccessor) {
+            _valueAccessor = valueAccessor;
+        }
+
+        public object Container {
+            get;
+            set;
+        }
+
+        public PropertyDescriptor PropertyDescriptor {
+            get;
+            set;
+        }
+
+        public object Value {
+            get {
+                if (_valueAccessor != null) {
+                    _value = _valueAccessor();
+                    _valueAccessor = null;
+                }
+
+                return _value;
+            }
+            set {
+                _value = value;
+                _valueAccessor = null;
+            }
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewEngineCollection.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewEngineCollection.cs
new file mode 100644 (file)
index 0000000..e394c67
--- /dev/null
@@ -0,0 +1,112 @@
+namespace System.Web.Mvc {
+    using System.Collections.Generic;
+    using System.Collections.ObjectModel;
+    using System.Linq;
+    using System.Web.Mvc.Resources;
+
+    public class ViewEngineCollection : Collection<IViewEngine> {
+        private IResolver<IEnumerable<IViewEngine>> _serviceResolver;
+
+        public ViewEngineCollection() {
+            _serviceResolver = new MultiServiceResolver<IViewEngine>(() => Items);
+        }
+
+        public ViewEngineCollection(IList<IViewEngine> list)
+            : base(list) {
+            _serviceResolver = new MultiServiceResolver<IViewEngine>(() => Items);
+        }
+
+        internal ViewEngineCollection(IResolver<IEnumerable<IViewEngine>> serviceResolver, params IViewEngine[] engines)
+            : base(engines) {
+            _serviceResolver = serviceResolver ?? new MultiServiceResolver<IViewEngine>(
+                () => Items
+                );
+        }
+        private IEnumerable<IViewEngine> CombinedItems {
+            get {
+                return _serviceResolver.Current;
+            }
+        }
+
+        protected override void InsertItem(int index, IViewEngine item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.InsertItem(index, item);
+        }
+
+        protected override void SetItem(int index, IViewEngine item) {
+            if (item == null) {
+                throw new ArgumentNullException("item");
+            }
+            base.SetItem(index, item);
+        }
+
+        private ViewEngineResult Find(Func<IViewEngine, ViewEngineResult> cacheLocator, Func<IViewEngine, ViewEngineResult> locator) {
+            // First, look up using the cacheLocator and do not track the searched paths in non-matching view engines
+            // Then, look up using the normal locator and track the searched paths so that an error view engine can be returned
+            return Find(cacheLocator, trackSearchedPaths: false)
+                ?? Find(locator, trackSearchedPaths: true);
+        }
+
+        private ViewEngineResult Find(Func<IViewEngine, ViewEngineResult> lookup, bool trackSearchedPaths) {
+            // Returns
+            //    1st result
+            // OR list of searched paths (if trackSearchedPaths == true)
+            // OR null
+            ViewEngineResult result;
+
+            List<string> searched = null;
+            if (trackSearchedPaths) {
+                searched = new List<string>();
+            }
+
+            foreach (IViewEngine engine in CombinedItems) {
+                if (engine != null) {
+                    result = lookup(engine);
+
+                    if (result.View != null) {
+                        return result;
+                    }
+
+                    if (trackSearchedPaths) {
+                        searched.AddRange(result.SearchedLocations);
+                    }
+                }
+            }
+
+            if (trackSearchedPaths) {
+                // Remove duplicate search paths since multiple view engines could have potentially looked at the same path
+                return new ViewEngineResult(searched.Distinct().ToList());
+            }
+            else {
+                return null;
+            }
+        }
+
+
+        public virtual ViewEngineResult FindPartialView(ControllerContext controllerContext, string partialViewName) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (string.IsNullOrEmpty(partialViewName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "partialViewName");
+            }
+
+            return Find(e => e.FindPartialView(controllerContext, partialViewName, true),
+                        e => e.FindPartialView(controllerContext, partialViewName, false));
+        }
+
+        public virtual ViewEngineResult FindView(ControllerContext controllerContext, string viewName, string masterName) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (string.IsNullOrEmpty(viewName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "viewName");
+            }
+
+            return Find(e => e.FindView(controllerContext, viewName, masterName, true),
+                        e => e.FindView(controllerContext, viewName, masterName, false));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewEngineResult.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewEngineResult.cs
new file mode 100644 (file)
index 0000000..ef69d19
--- /dev/null
@@ -0,0 +1,42 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+
+    public class ViewEngineResult {
+
+        public ViewEngineResult(IEnumerable<string> searchedLocations) {
+            if (searchedLocations == null) {
+                throw new ArgumentNullException("searchedLocations");
+            }
+
+            SearchedLocations = searchedLocations;
+        }
+
+        public ViewEngineResult(IView view, IViewEngine viewEngine) {
+            if (view == null) {
+                throw new ArgumentNullException("view");
+            }
+            if (viewEngine == null) {
+                throw new ArgumentNullException("viewEngine");
+            }
+
+            View = view;
+            ViewEngine = viewEngine;
+        }
+
+        public IEnumerable<string> SearchedLocations {
+            get;
+            private set;
+        }
+
+        public IView View {
+            get;
+            private set;
+        }
+
+        public IViewEngine ViewEngine {
+            get;
+            private set;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewEngines.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewEngines.cs
new file mode 100644 (file)
index 0000000..a71969f
--- /dev/null
@@ -0,0 +1,16 @@
+namespace System.Web.Mvc {
+
+    public static class ViewEngines {
+
+        private readonly static ViewEngineCollection _engines = new ViewEngineCollection {
+            new WebFormViewEngine(),
+            new RazorViewEngine(),
+        };
+
+        public static ViewEngineCollection Engines {
+            get {
+                return _engines;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewMasterPage.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewMasterPage.cs
new file mode 100644 (file)
index 0000000..903ccca
--- /dev/null
@@ -0,0 +1,72 @@
+namespace System.Web.Mvc {
+    using System.Globalization;
+    using System.Web.Mvc.Resources;
+    using System.Web.UI;
+
+    [FileLevelControlBuilder(typeof(ViewMasterPageControlBuilder))]
+    public class ViewMasterPage : MasterPage {
+        public AjaxHelper<object> Ajax {
+            get {
+                return ViewPage.Ajax;
+            }
+        }
+
+        public HtmlHelper<object> Html {
+            get {
+                return ViewPage.Html;
+            }
+        }
+
+        public object Model {
+            get {
+                return ViewData.Model;
+            }
+        }
+
+        public TempDataDictionary TempData {
+            get {
+                return ViewPage.TempData;
+            }
+        }
+
+        public UrlHelper Url {
+            get {
+                return ViewPage.Url;
+            }
+        }
+
+        public dynamic ViewBag {
+            get {
+                return ViewPage.ViewBag;
+            }
+        }
+
+        public ViewContext ViewContext {
+            get {
+                return ViewPage.ViewContext;
+            }
+        }
+
+        public ViewDataDictionary ViewData {
+            get {
+                return ViewPage.ViewData;
+            }
+        }
+
+        internal ViewPage ViewPage {
+            get {
+                ViewPage viewPage = Page as ViewPage;
+                if (viewPage == null) {
+                    throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture, MvcResources.ViewMasterPage_RequiresViewPage));
+                }
+                return viewPage;
+            }
+        }
+
+        public HtmlTextWriter Writer {
+            get {
+                return ViewPage.Writer;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewMasterPageControlBuilder.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewMasterPageControlBuilder.cs
new file mode 100644 (file)
index 0000000..c0b3e68
--- /dev/null
@@ -0,0 +1,17 @@
+namespace System.Web.Mvc {
+    using System.CodeDom;
+    using System.Web.UI;
+
+    internal sealed class ViewMasterPageControlBuilder : FileLevelMasterPageControlBuilder, IMvcControlBuilder {
+        public string Inherits {
+            get;
+            set;
+        }
+
+        public override void ProcessGeneratedCode(CodeCompileUnit codeCompileUnit, CodeTypeDeclaration baseType, CodeTypeDeclaration derivedType, CodeMemberMethod buildMethod, CodeMemberMethod dataBindingMethod) {
+            if (!String.IsNullOrWhiteSpace(Inherits)) {
+                derivedType.BaseTypes[0] = new CodeTypeReference(Inherits);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewMasterPage`1.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewMasterPage`1.cs
new file mode 100644 (file)
index 0000000..f05663a
--- /dev/null
@@ -0,0 +1,41 @@
+namespace System.Web.Mvc {
+
+    public class ViewMasterPage<TModel> : ViewMasterPage {
+        private AjaxHelper<TModel> _ajaxHelper;
+        private HtmlHelper<TModel> _htmlHelper;
+        private ViewDataDictionary<TModel> _viewData;
+
+        public new AjaxHelper<TModel> Ajax {
+            get {
+                if (_ajaxHelper == null) {
+                    _ajaxHelper = new AjaxHelper<TModel>(ViewContext, ViewPage);
+                }
+                return _ajaxHelper;
+            }
+        }
+
+        public new HtmlHelper<TModel> Html {
+            get {
+                if (_htmlHelper == null) {
+                    _htmlHelper = new HtmlHelper<TModel>(ViewContext, ViewPage);
+                }
+                return _htmlHelper;
+            }
+        }
+
+        public new TModel Model {
+            get {
+                return ViewData.Model;
+            }
+        }
+
+        public new ViewDataDictionary<TModel> ViewData {
+            get {
+                if (_viewData == null) {
+                    _viewData = new ViewDataDictionary<TModel>(ViewPage.ViewData);
+                }
+                return _viewData;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewPage.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewPage.cs
new file mode 100644 (file)
index 0000000..5d696d8
--- /dev/null
@@ -0,0 +1,386 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.IO;
+    using System.Text;
+    using System.Web;
+    using System.Web.UI;
+
+    [FileLevelControlBuilder(typeof(ViewPageControlBuilder))]
+    public class ViewPage : Page, IViewDataContainer {
+
+        private DynamicViewDataDictionary _dynamicViewData;
+        private string _masterLocation;
+        [ThreadStatic]
+        private static int _nextId;
+        private ViewDataDictionary _viewData;
+
+        public AjaxHelper<object> Ajax {
+            get;
+            set;
+        }
+
+        public HtmlHelper<object> Html {
+            get;
+            set;
+        }
+
+        public string MasterLocation {
+            get {
+                return _masterLocation ?? String.Empty;
+            }
+            set {
+                _masterLocation = value;
+            }
+        }
+
+        public object Model {
+            get {
+                return ViewData.Model;
+            }
+        }
+
+        public TempDataDictionary TempData {
+            get {
+                return ViewContext.TempData;
+            }
+        }
+
+        public UrlHelper Url {
+            get;
+            set;
+        }
+
+        public dynamic ViewBag {
+            get {
+                if (_dynamicViewData == null) {
+                    _dynamicViewData = new DynamicViewDataDictionary(() => ViewData);
+                }
+                return _dynamicViewData;
+            }
+        }
+
+        public ViewContext ViewContext {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This is the mechanism by which the ViewPage gets its ViewDataDictionary object.")]
+        public ViewDataDictionary ViewData {
+            get {
+                if (_viewData == null) {
+                    SetViewData(new ViewDataDictionary());
+                }
+                return _viewData;
+            }
+            set {
+                SetViewData(value);
+            }
+        }
+
+        public HtmlTextWriter Writer {
+            get;
+            private set;
+        }
+
+        public virtual void InitHelpers() {
+            Ajax = new AjaxHelper<object>(ViewContext, this);
+            Html = new HtmlHelper<object>(ViewContext, this);
+            Url = new UrlHelper(ViewContext.RequestContext);
+        }
+
+        internal static string NextId() {
+            return (++_nextId).ToString(CultureInfo.InvariantCulture);
+        }
+
+        protected override void OnPreInit(EventArgs e) {
+            base.OnPreInit(e);
+
+            if (!String.IsNullOrEmpty(MasterLocation)) {
+                MasterPageFile = MasterLocation;
+            }
+        }
+
+        public override void ProcessRequest(HttpContext context) {
+            // Tracing requires IDs to be unique.
+            ID = NextId();
+
+            base.ProcessRequest(context);
+        }
+
+        protected override void Render(HtmlTextWriter writer) {
+            Writer = writer;
+            try {
+                base.Render(writer);
+            }
+            finally {
+                Writer = null;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Reliability", "CA2000:Dispose objects before losing scope", Justification = "The object is disposed in the finally block of the method")]
+        public virtual void RenderView(ViewContext viewContext) {
+            ViewContext = viewContext;
+            InitHelpers();
+
+            bool createdSwitchWriter = false;
+            SwitchWriter switchWriter = viewContext.HttpContext.Response.Output as SwitchWriter;
+
+            try {
+                if (switchWriter == null) {
+                    switchWriter = new SwitchWriter();
+                    createdSwitchWriter = true;
+                }
+
+                using (switchWriter.Scope(viewContext.Writer)) {
+                    if (createdSwitchWriter) {
+                        // It's safe to reset the _nextId within a Server.Execute() since it pushes a new TraceContext onto
+                        // the stack, so there won't be an ID conflict.
+                        int originalNextId = _nextId;
+                        try {
+                            _nextId = 0;
+                            viewContext.HttpContext.Server.Execute(HttpHandlerUtil.WrapForServerExecute(this), switchWriter, true /* preserveForm */);
+                        }
+                        finally {
+                            // Restore the original _nextId in case this isn't actually the outermost view, since resetting
+                            // the _nextId may now cause trace ID conflicts in the outer view.
+                            _nextId = originalNextId;
+                        }
+                    }
+                    else {
+                        ProcessRequest(HttpContext.Current);
+                    }
+                }
+            }
+            finally {
+                if (createdSwitchWriter) {
+                    switchWriter.Dispose();
+                }
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "textWriter", Justification = "This method existed in MVC 1.0 and has been deprecated.")]
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "This method existed in MVC 1.0 and has been deprecated.")]
+        [Obsolete("The TextWriter is now provided by the ViewContext object passed to the RenderView method.", true /* error */)]
+        public void SetTextWriter(TextWriter textWriter) {
+            // this is now a no-op
+        }
+
+        protected virtual void SetViewData(ViewDataDictionary viewData) {
+            _viewData = viewData;
+        }
+
+        internal class SwitchWriter : TextWriter {
+            public SwitchWriter()
+                : base(CultureInfo.CurrentCulture) {
+            }
+
+            public override Encoding Encoding {
+                get {
+                    return InnerWriter.Encoding;
+                }
+            }
+
+            public override IFormatProvider FormatProvider {
+                get {
+                    return InnerWriter.FormatProvider;
+                }
+            }
+
+            internal TextWriter InnerWriter {
+                get;
+                set;
+            }
+
+            public override string NewLine {
+                get {
+                    return InnerWriter.NewLine;
+                }
+                set {
+                    InnerWriter.NewLine = value;
+                }
+            }
+
+            public override void Close() {
+                InnerWriter.Close();
+            }
+
+            public override void Flush() {
+                InnerWriter.Flush();
+            }
+
+            public IDisposable Scope(TextWriter writer) {
+                WriterScope scope = new WriterScope(this, InnerWriter);
+
+                try {
+                    if (writer != this) {
+                        InnerWriter = writer;
+                    }
+
+                    return scope;
+                }
+                catch {
+                    scope.Dispose();
+                    throw;
+                }
+            }
+
+            public override void Write(bool value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(char value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(char[] buffer) {
+                InnerWriter.Write(buffer);
+            }
+
+            public override void Write(char[] buffer, int index, int count) {
+                InnerWriter.Write(buffer, index, count);
+            }
+
+            public override void Write(decimal value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(double value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(float value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(int value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(long value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(object value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(string format, object arg0) {
+                InnerWriter.Write(format, arg0);
+            }
+
+            public override void Write(string format, object arg0, object arg1) {
+                InnerWriter.Write(format, arg0, arg1);
+            }
+
+            public override void Write(string format, object arg0, object arg1, object arg2) {
+                InnerWriter.Write(format, arg0, arg1, arg2);
+            }
+
+            public override void Write(string format, params object[] arg) {
+                InnerWriter.Write(format, arg);
+            }
+
+            public override void Write(string value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(uint value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void Write(ulong value) {
+                InnerWriter.Write(value);
+            }
+
+            public override void WriteLine() {
+                InnerWriter.WriteLine();
+            }
+
+            public override void WriteLine(bool value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(char value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(char[] buffer) {
+                InnerWriter.WriteLine(buffer);
+            }
+
+            public override void WriteLine(char[] buffer, int index, int count) {
+                InnerWriter.WriteLine(buffer, index, count);
+            }
+
+            public override void WriteLine(decimal value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(double value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(float value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(int value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(long value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(object value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(string format, object arg0) {
+                InnerWriter.WriteLine(format, arg0);
+            }
+
+            public override void WriteLine(string format, object arg0, object arg1) {
+                InnerWriter.WriteLine(format, arg0, arg1);
+            }
+
+            public override void WriteLine(string format, object arg0, object arg1, object arg2) {
+                InnerWriter.WriteLine(format, arg0, arg1, arg2);
+            }
+
+            public override void WriteLine(string format, params object[] arg) {
+                InnerWriter.WriteLine(format, arg);
+            }
+
+            public override void WriteLine(string value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(uint value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            public override void WriteLine(ulong value) {
+                InnerWriter.WriteLine(value);
+            }
+
+            private sealed class WriterScope : IDisposable {
+                private SwitchWriter _switchWriter;
+                private TextWriter _writerToRestore;
+
+                public WriterScope(SwitchWriter switchWriter, TextWriter writerToRestore) {
+                    _switchWriter = switchWriter;
+                    _writerToRestore = writerToRestore;
+                }
+
+                public void Dispose() {
+                    _switchWriter.InnerWriter = _writerToRestore;
+                }
+            }
+
+        }
+
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewPageControlBuilder.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewPageControlBuilder.cs
new file mode 100644 (file)
index 0000000..1fab076
--- /dev/null
@@ -0,0 +1,17 @@
+namespace System.Web.Mvc {
+    using System.CodeDom;
+    using System.Web.UI;
+
+    internal sealed class ViewPageControlBuilder : FileLevelPageControlBuilder, IMvcControlBuilder {
+        public string Inherits {
+            get;
+            set;
+        }
+
+        public override void ProcessGeneratedCode(CodeCompileUnit codeCompileUnit, CodeTypeDeclaration baseType, CodeTypeDeclaration derivedType, CodeMemberMethod buildMethod, CodeMemberMethod dataBindingMethod) {
+            if (!String.IsNullOrWhiteSpace(Inherits)) {
+                derivedType.BaseTypes[0] = new CodeTypeReference(Inherits);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewPage`1.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewPage`1.cs
new file mode 100644 (file)
index 0000000..dbcd562
--- /dev/null
@@ -0,0 +1,50 @@
+namespace System.Web.Mvc {
+    using System.Diagnostics.CodeAnalysis;
+
+    public class ViewPage<TModel> : ViewPage {
+
+        private ViewDataDictionary<TModel> _viewData;
+
+        public new AjaxHelper<TModel> Ajax {
+            get;
+            set;
+        }
+
+        public new HtmlHelper<TModel> Html {
+            get;
+            set;
+        }
+
+        public new TModel Model {
+            get {
+                return ViewData.Model;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+        public new ViewDataDictionary<TModel> ViewData {
+            get {
+                if (_viewData == null) {
+                    SetViewData(new ViewDataDictionary<TModel>());
+                }
+                return _viewData;
+            }
+            set {
+                SetViewData(value);
+            }
+        }
+
+        public override void InitHelpers() {
+            base.InitHelpers();
+
+            Ajax = new AjaxHelper<TModel>(ViewContext, this);
+            Html = new HtmlHelper<TModel>(ViewContext, this);
+        }
+
+        protected override void SetViewData(ViewDataDictionary viewData) {
+            _viewData = new ViewDataDictionary<TModel>(viewData);
+
+            base.SetViewData(_viewData);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewResult.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewResult.cs
new file mode 100644 (file)
index 0000000..9a464ea
--- /dev/null
@@ -0,0 +1,35 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Globalization;
+    using System.Text;
+    using System.Web.Mvc.Resources;
+
+    public class ViewResult : ViewResultBase {
+        private string _masterName;
+
+        public string MasterName {
+            get {
+                return _masterName ?? String.Empty;
+            }
+            set {
+                _masterName = value;
+            }
+        }
+
+        protected override ViewEngineResult FindView(ControllerContext context) {
+            ViewEngineResult result = ViewEngineCollection.FindView(context, ViewName, MasterName);
+            if (result.View != null) {
+                return result;
+            }
+
+            // we need to generate an exception containing all the locations we searched
+            StringBuilder locationsText = new StringBuilder();
+            foreach (string location in result.SearchedLocations) {
+                locationsText.AppendLine();
+                locationsText.Append(location);
+            }
+            throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture,
+                MvcResources.Common_ViewNotFound, ViewName, locationsText));
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewResultBase.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewResultBase.cs
new file mode 100644 (file)
index 0000000..627bca4
--- /dev/null
@@ -0,0 +1,104 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Diagnostics.CodeAnalysis;
+    using System.IO;
+
+    public abstract class ViewResultBase : ActionResult {
+        private DynamicViewDataDictionary _dynamicViewData;
+        private TempDataDictionary _tempData;
+        private ViewDataDictionary _viewData;
+        private ViewEngineCollection _viewEngineCollection;
+        private string _viewName;
+
+        public object Model {
+            get {
+                return ViewData.Model;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This entire type is meant to be mutable.")]
+        public TempDataDictionary TempData {
+            get {
+                if (_tempData == null) {
+                    _tempData = new TempDataDictionary();
+                }
+                return _tempData;
+            }
+            set {
+                _tempData = value;
+            }
+        }
+
+        public IView View {
+            get;
+            set;
+        }
+
+        public dynamic ViewBag {
+            get {
+                if (_dynamicViewData == null) {
+                    _dynamicViewData = new DynamicViewDataDictionary(() => ViewData);
+                }
+                return _dynamicViewData;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This entire type is meant to be mutable.")]
+        public ViewDataDictionary ViewData {
+            get {
+                if (_viewData == null) {
+                    _viewData = new ViewDataDictionary();
+                }
+                return _viewData;
+            }
+            set {
+                _viewData = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This entire type is meant to be mutable.")]
+        public ViewEngineCollection ViewEngineCollection {
+            get {
+                return _viewEngineCollection ?? ViewEngines.Engines;
+            }
+            set {
+                _viewEngineCollection = value;
+            }
+        }
+
+        public string ViewName {
+            get {
+                return _viewName ?? String.Empty;
+            }
+            set {
+                _viewName = value;
+            }
+        }
+
+        public override void ExecuteResult(ControllerContext context) {
+            if (context == null) {
+                throw new ArgumentNullException("context");
+            }
+            if (String.IsNullOrEmpty(ViewName)) {
+                ViewName = context.RouteData.GetRequiredString("action");
+            }
+
+            ViewEngineResult result = null;
+
+            if (View == null) {
+                result = FindView(context);
+                View = result.View;
+            }
+
+            TextWriter writer = context.HttpContext.Response.Output;
+            ViewContext viewContext = new ViewContext(context, View, ViewData, TempData, writer);
+            View.Render(viewContext, writer);
+
+            if (result != null) {
+                result.ViewEngine.ReleaseView(context, View);
+            }
+        }
+
+        protected abstract ViewEngineResult FindView(ControllerContext context);
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewStartPage.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewStartPage.cs
new file mode 100644 (file)
index 0000000..a1f79fc
--- /dev/null
@@ -0,0 +1,40 @@
+namespace System.Web.Mvc {
+    using System.Web.Mvc.Resources;
+    using System.Web.WebPages;
+
+    public abstract class ViewStartPage : StartPage, IViewStartPageChild {
+        private IViewStartPageChild _viewStartPageChild;
+
+        public HtmlHelper<object> Html {
+            get {
+                return ViewStartPageChild.Html;
+            }
+        }
+
+        public UrlHelper Url {
+            get {
+                return ViewStartPageChild.Url;
+            }
+        }
+
+        public ViewContext ViewContext {
+            get {
+                return ViewStartPageChild.ViewContext;
+            }
+        }
+
+        internal IViewStartPageChild ViewStartPageChild {
+            get {
+                if (_viewStartPageChild == null) {
+                    IViewStartPageChild child = base.ChildPage as IViewStartPageChild;
+                    if (child == null) {
+                        throw new InvalidOperationException(MvcResources.ViewStartPage_RequiresMvcRazorView);
+                    }
+                    _viewStartPageChild = child;
+                }
+
+                return _viewStartPageChild;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewTemplateUserControl.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewTemplateUserControl.cs
new file mode 100644 (file)
index 0000000..e6c33cb
--- /dev/null
@@ -0,0 +1,3 @@
+namespace System.Web.Mvc {
+    public class ViewTemplateUserControl : ViewTemplateUserControl<object> { }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewTemplateUserControl`1.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewTemplateUserControl`1.cs
new file mode 100644 (file)
index 0000000..f17b0ae
--- /dev/null
@@ -0,0 +1,7 @@
+namespace System.Web.Mvc {
+    public class ViewTemplateUserControl<TModel> : ViewUserControl<TModel> {
+        protected string FormattedModelValue {
+            get { return ViewData.TemplateInfo.FormattedModelValue.ToString(); }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewType.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewType.cs
new file mode 100644 (file)
index 0000000..9bdcf54
--- /dev/null
@@ -0,0 +1,20 @@
+namespace System.Web.Mvc {
+    using System.ComponentModel;
+    using System.Web.UI;
+
+    [ControlBuilder(typeof(ViewTypeControlBuilder))]
+    [NonVisualControl]
+    public class ViewType : Control {
+        private string _typeName;
+
+        [DefaultValue("")]
+        public string TypeName {
+            get {
+                return _typeName ?? String.Empty;
+            }
+            set {
+                _typeName = value;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewTypeControlBuilder.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewTypeControlBuilder.cs
new file mode 100644 (file)
index 0000000..50080dd
--- /dev/null
@@ -0,0 +1,27 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.CodeDom;
+    using System.Collections;
+    using System.Web.UI;
+
+    internal sealed class ViewTypeControlBuilder : ControlBuilder {
+        private string _typeName;
+
+        public override void Init(TemplateParser parser, ControlBuilder parentBuilder, Type type, string tagName, string id, IDictionary attribs) {
+            base.Init(parser, parentBuilder, type, tagName, id, attribs);
+
+            _typeName = (string)attribs["typename"];
+        }
+
+        public override void ProcessGeneratedCode(
+            CodeCompileUnit codeCompileUnit,
+            CodeTypeDeclaration baseType,
+            CodeTypeDeclaration derivedType,
+            CodeMemberMethod buildMethod,
+            CodeMemberMethod dataBindingMethod) {
+
+            // Override the view's base type with the explicit base type
+            derivedType.BaseTypes[0] = new CodeTypeReference(_typeName);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewTypeParserFilter.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewTypeParserFilter.cs
new file mode 100644 (file)
index 0000000..2357352
--- /dev/null
@@ -0,0 +1,102 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Web.UI;
+
+    internal class ViewTypeParserFilter : PageParserFilter {
+
+        private static Dictionary<string, Type> _directiveBaseTypeMappings = new Dictionary<string, Type> {
+            { "page",    typeof(ViewPage)        },
+            { "control", typeof(ViewUserControl) },
+            { "master",  typeof(ViewMasterPage)  },
+        };
+
+        private string _inherits;
+
+        [SuppressMessage("Microsoft.Security", "CA2141:TransparentMethodsMustNotSatisfyLinkDemandsFxCopRule", Justification = "System.Web.Mvc is SecurityTransparent and requires medium trust to run, so this downstream link demand is fine")]
+        public ViewTypeParserFilter() {
+        }
+
+        [SuppressMessage("Microsoft.Security", "CA2141:TransparentMethodsMustNotSatisfyLinkDemandsFxCopRule", Justification = "System.Web.Mvc is SecurityTransparent and requires medium trust to run, so this downstream link demand is fine")]
+        public override void PreprocessDirective(string directiveName, IDictionary attributes) {
+            base.PreprocessDirective(directiveName, attributes);
+
+            Type baseType;
+            if (_directiveBaseTypeMappings.TryGetValue(directiveName, out baseType)) {
+                string inheritsAttribute = attributes["inherits"] as string;
+
+                // Since the ASP.NET page parser doesn't understand native generic syntax, we
+                // need to swap out whatever the user provided with the default base type for
+                // the given directive (page vs. control vs. master). We stash the old value
+                // and swap it back in inside the control builder. Our "is this generic?"
+                // check here really only works for C# and VB.NET, since we're checking for
+                // < or ( in the type name.
+                //
+                // We only change generic directives, because doing so breaks back-compat
+                // for property setters on @Page, @Control, and @Master directives. The user
+                // can work around this breaking behavior by using a non-generic inherits
+                // directive, or by using the CLR syntax for generic type names.
+
+                if (inheritsAttribute != null && inheritsAttribute.IndexOfAny(new[] { '<', '(' }) > 0) {
+                    attributes["inherits"] = baseType.FullName;
+                    _inherits = inheritsAttribute;
+                }
+            }
+        }
+
+        [SuppressMessage("Microsoft.Security", "CA2141:TransparentMethodsMustNotSatisfyLinkDemandsFxCopRule", Justification = "System.Web.Mvc is SecurityTransparent and requires medium trust to run, so this downstream link demand is fine")]
+        public override void ParseComplete(ControlBuilder rootBuilder) {
+            base.ParseComplete(rootBuilder);
+
+            IMvcControlBuilder builder = rootBuilder as IMvcControlBuilder;
+            if (builder != null) {
+                builder.Inherits = _inherits;
+            }
+        }
+
+        // Everything else in this class is unrelated to our 'inherits' handling.
+        // Since PageParserFilter blocks everything by default, we need to unblock it
+
+        public override bool AllowCode {
+            get {
+                return true;
+            }
+        }
+
+        public override bool AllowBaseType(Type baseType) {
+            return true;
+        }
+
+        public override bool AllowControl(Type controlType, ControlBuilder builder) {
+            return true;
+        }
+
+        public override bool AllowVirtualReference(string referenceVirtualPath, VirtualReferenceType referenceType) {
+            return true;
+        }
+
+        public override bool AllowServerSideInclude(string includeVirtualPath) {
+            return true;
+        }
+
+        public override int NumberOfControlsAllowed {
+            get {
+                return -1;
+            }
+        }
+
+        public override int NumberOfDirectDependenciesAllowed {
+            get {
+                return -1;
+            }
+        }
+
+        public override int TotalNumberOfDependenciesAllowed {
+            get {
+                return -1;
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewUserControl.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewUserControl.cs
new file mode 100644 (file)
index 0000000..0bc59c5
--- /dev/null
@@ -0,0 +1,195 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.ComponentModel;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.IO;
+    using System.Web.Mvc.Resources;
+    using System.Web.UI;
+
+    [FileLevelControlBuilder(typeof(ViewUserControlControlBuilder))]
+    public class ViewUserControl : UserControl, IViewDataContainer {
+        private AjaxHelper<object> _ajaxHelper;
+        private DynamicViewDataDictionary _dynamicViewData;
+        private HtmlHelper<object> _htmlHelper;
+        private ViewContext _viewContext;
+        private ViewDataDictionary _viewData;
+        private string _viewDataKey;
+
+        public AjaxHelper<object> Ajax {
+            get {
+                if (_ajaxHelper == null) {
+                    _ajaxHelper = new AjaxHelper<object>(ViewContext, this);
+                }
+                return _ajaxHelper;
+            }
+        }
+
+        public HtmlHelper<object> Html {
+            get {
+                if (_htmlHelper == null) {
+                    _htmlHelper = new HtmlHelper<object>(ViewContext, this);
+                }
+                return _htmlHelper;
+            }
+        }
+
+        public object Model {
+            get {
+                return ViewData.Model;
+            }
+        }
+
+        public TempDataDictionary TempData {
+            get {
+                return ViewPage.TempData;
+            }
+        }
+
+        public UrlHelper Url {
+            get {
+                return ViewPage.Url;
+            }
+        }
+
+        public dynamic ViewBag {
+            get {
+                if (_dynamicViewData == null) {
+                    _dynamicViewData = new DynamicViewDataDictionary(() => ViewData);
+                }
+                return _dynamicViewData;
+            }
+        }
+
+        [Browsable(false)]
+        [DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
+        public ViewContext ViewContext {
+            get {
+                return _viewContext ?? ViewPage.ViewContext;
+            }
+            set {
+                _viewContext = value;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This is the mechanism by which the ViewUserControl gets its ViewDataDictionary object.")]
+        [Browsable(false)]
+        [DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
+        public ViewDataDictionary ViewData {
+            get {
+                EnsureViewData();
+                return _viewData;
+            }
+            set {
+                SetViewData(value);
+            }
+        }
+
+        [DefaultValue("")]
+        public string ViewDataKey {
+            get {
+                return _viewDataKey ?? String.Empty;
+            }
+            set {
+                _viewDataKey = value;
+            }
+        }
+
+        internal ViewPage ViewPage {
+            get {
+                ViewPage viewPage = Page as ViewPage;
+                if (viewPage == null) {
+                    throw new InvalidOperationException(MvcResources.ViewUserControl_RequiresViewPage);
+                }
+                return viewPage;
+            }
+        }
+
+        public HtmlTextWriter Writer {
+            get {
+                return ViewPage.Writer;
+            }
+        }
+
+        protected virtual void SetViewData(ViewDataDictionary viewData) {
+            _viewData = viewData;
+        }
+
+        protected void EnsureViewData() {
+            if (_viewData != null) {
+                return;
+            }
+
+            // Get the ViewData for this ViewUserControl, optionally using the specified ViewDataKey
+            IViewDataContainer vdc = GetViewDataContainer(this);
+            if (vdc == null) {
+                throw new InvalidOperationException(
+                    String.Format(
+                        CultureInfo.CurrentCulture,
+                        MvcResources.ViewUserControl_RequiresViewDataProvider,
+                        AppRelativeVirtualPath));
+            }
+
+            ViewDataDictionary myViewData = vdc.ViewData;
+
+            // If we have a ViewDataKey, try to extract the ViewData from the dictionary, otherwise
+            // return the container's ViewData.
+            if (!String.IsNullOrEmpty(ViewDataKey)) {
+                object target = myViewData.Eval(ViewDataKey);
+                myViewData = target as ViewDataDictionary ?? new ViewDataDictionary(myViewData) { Model = target };
+            }
+
+            SetViewData(myViewData);
+        }
+
+        private static IViewDataContainer GetViewDataContainer(Control control) {
+            // Walk up the control hierarchy until we find someone that implements IViewDataContainer
+            while (control != null) {
+                control = control.Parent;
+                IViewDataContainer vdc = control as IViewDataContainer;
+                if (vdc != null) {
+                    return vdc;
+                }
+            }
+            return null;
+        }
+
+        public virtual void RenderView(ViewContext viewContext) {
+            using (ViewUserControlContainerPage containerPage = new ViewUserControlContainerPage(this)) {
+                RenderViewAndRestoreContentType(containerPage, viewContext);
+            }
+        }
+
+        internal static void RenderViewAndRestoreContentType(ViewPage containerPage, ViewContext viewContext) {
+            // We need to restore the Content-Type since Page.SetIntrinsics() will reset it. It's not possible
+            // to work around the call to SetIntrinsics() since the control's render method requires the
+            // containing page's Response property to be non-null, and SetIntrinsics() is the only way to set
+            // this.
+            string savedContentType = viewContext.HttpContext.Response.ContentType;
+            containerPage.RenderView(viewContext);
+            viewContext.HttpContext.Response.ContentType = savedContentType;
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "textWriter", Justification = "This method existed in MVC 1.0 and has been deprecated.")]
+        [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic", Justification = "This method existed in MVC 1.0 and has been deprecated.")]
+        [Obsolete("The TextWriter is now provided by the ViewContext object passed to the RenderView method.", true /* error */)]
+        public void SetTextWriter(TextWriter textWriter) {
+            // this is now a no-op
+        }
+
+        private sealed class ViewUserControlContainerPage : ViewPage {
+            private readonly ViewUserControl _userControl;
+
+            public ViewUserControlContainerPage(ViewUserControl userControl) {
+                _userControl = userControl;
+            }
+
+            public override void ProcessRequest(HttpContext context) {
+                _userControl.ID = ViewPage.NextId();
+                Controls.Add(_userControl);
+
+                base.ProcessRequest(context);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewUserControlControlBuilder.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewUserControlControlBuilder.cs
new file mode 100644 (file)
index 0000000..a608561
--- /dev/null
@@ -0,0 +1,17 @@
+namespace System.Web.Mvc {
+    using System.CodeDom;
+    using System.Web.UI;
+
+    internal sealed class ViewUserControlControlBuilder : FileLevelUserControlBuilder, IMvcControlBuilder {
+        public string Inherits {
+            get;
+            set;
+        }
+
+        public override void ProcessGeneratedCode(CodeCompileUnit codeCompileUnit, CodeTypeDeclaration baseType, CodeTypeDeclaration derivedType, CodeMemberMethod buildMethod, CodeMemberMethod dataBindingMethod) {
+            if (!String.IsNullOrWhiteSpace(Inherits)) {
+                derivedType.BaseTypes[0] = new CodeTypeReference(Inherits);
+            }
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/ViewUserControl`1.cs b/mcs/class/System.Web.Mvc3/Mvc/ViewUserControl`1.cs
new file mode 100644 (file)
index 0000000..ee81f34
--- /dev/null
@@ -0,0 +1,50 @@
+namespace System.Web.Mvc {
+    using System.Diagnostics.CodeAnalysis;
+
+    public class ViewUserControl<TModel> : ViewUserControl {
+        private AjaxHelper<TModel> _ajaxHelper;
+        private HtmlHelper<TModel> _htmlHelper;
+        private ViewDataDictionary<TModel> _viewData;
+
+        public new AjaxHelper<TModel> Ajax {
+            get {
+                if (_ajaxHelper == null) {
+                    _ajaxHelper = new AjaxHelper<TModel>(ViewContext, this);
+                }
+                return _ajaxHelper;
+            }
+        }
+
+        public new HtmlHelper<TModel> Html {
+            get {
+                if (_htmlHelper == null) {
+                    _htmlHelper = new HtmlHelper<TModel>(ViewContext, this);
+                }
+                return _htmlHelper;
+            }
+        }
+
+        public new TModel Model {
+            get {
+                return ViewData.Model;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+        public new ViewDataDictionary<TModel> ViewData {
+            get {
+                EnsureViewData();
+                return _viewData;
+            }
+            set {
+                SetViewData(value);
+            }
+        }
+
+        protected override void SetViewData(ViewDataDictionary viewData) {
+            _viewData = new ViewDataDictionary<TModel>(viewData);
+
+            base.SetViewData(_viewData);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/VirtualPathProviderViewEngine.cs b/mcs/class/System.Web.Mvc3/Mvc/VirtualPathProviderViewEngine.cs
new file mode 100644 (file)
index 0000000..b989aaf
--- /dev/null
@@ -0,0 +1,273 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Linq;
+    using System.Web;
+    using System.Web.Hosting;
+    using System.Web.Mvc.Resources;
+
+    public abstract class VirtualPathProviderViewEngine : IViewEngine {
+        // format is ":ViewCacheEntry:{cacheType}:{prefix}:{name}:{controllerName}:{areaName}:"
+        private const string _cacheKeyFormat = ":ViewCacheEntry:{0}:{1}:{2}:{3}:{4}:";
+        private const string _cacheKeyPrefix_Master = "Master";
+        private const string _cacheKeyPrefix_Partial = "Partial";
+        private const string _cacheKeyPrefix_View = "View";
+        private static readonly string[] _emptyLocations = new string[0];
+
+        private VirtualPathProvider _vpp;
+        internal Func<string, string> GetExtensionThunk = VirtualPathUtility.GetExtension;
+
+        [SuppressMessage("Microsoft.Performance", "CA1819:PropertiesShouldNotReturnArrays")]
+        public string[] AreaMasterLocationFormats {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1819:PropertiesShouldNotReturnArrays")]
+        public string[] AreaPartialViewLocationFormats {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1819:PropertiesShouldNotReturnArrays")]
+        public string[] AreaViewLocationFormats {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1819:PropertiesShouldNotReturnArrays")]
+        public string[] FileExtensions {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1819:PropertiesShouldNotReturnArrays")]
+        public string[] MasterLocationFormats {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1819:PropertiesShouldNotReturnArrays")]
+        public string[] PartialViewLocationFormats {
+            get;
+            set;
+        }
+
+        public IViewLocationCache ViewLocationCache {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Performance", "CA1819:PropertiesShouldNotReturnArrays")]
+        public string[] ViewLocationFormats {
+            get;
+            set;
+        }
+
+        protected VirtualPathProvider VirtualPathProvider {
+            get {
+                if (_vpp == null) {
+                    _vpp = HostingEnvironment.VirtualPathProvider;
+                }
+                return _vpp;
+            }
+            set {
+                _vpp = value;
+            }
+        }
+
+        protected VirtualPathProviderViewEngine() {
+            if (HttpContext.Current == null || HttpContext.Current.IsDebuggingEnabled) {
+                ViewLocationCache = DefaultViewLocationCache.Null;
+            }
+            else {
+                ViewLocationCache = new DefaultViewLocationCache();
+            }
+        }
+
+        private string CreateCacheKey(string prefix, string name, string controllerName, string areaName) {
+            return String.Format(CultureInfo.InvariantCulture, _cacheKeyFormat,
+                GetType().AssemblyQualifiedName, prefix, name, controllerName, areaName);
+        }
+
+        protected abstract IView CreatePartialView(ControllerContext controllerContext, string partialPath);
+
+        protected abstract IView CreateView(ControllerContext controllerContext, string viewPath, string masterPath);
+
+        protected virtual bool FileExists(ControllerContext controllerContext, string virtualPath) {
+            return VirtualPathProvider.FileExists(virtualPath);
+        }
+
+        public virtual ViewEngineResult FindPartialView(ControllerContext controllerContext, string partialViewName, bool useCache) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (String.IsNullOrEmpty(partialViewName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "partialViewName");
+            }
+
+            string[] searched;
+            string controllerName = controllerContext.RouteData.GetRequiredString("controller");
+            string partialPath = GetPath(controllerContext, PartialViewLocationFormats, AreaPartialViewLocationFormats, "PartialViewLocationFormats", partialViewName, controllerName, _cacheKeyPrefix_Partial, useCache, out searched);
+
+            if (String.IsNullOrEmpty(partialPath)) {
+                return new ViewEngineResult(searched);
+            }
+
+            return new ViewEngineResult(CreatePartialView(controllerContext, partialPath), this);
+        }
+
+        public virtual ViewEngineResult FindView(ControllerContext controllerContext, string viewName, string masterName, bool useCache) {
+            if (controllerContext == null) {
+                throw new ArgumentNullException("controllerContext");
+            }
+            if (String.IsNullOrEmpty(viewName)) {
+                throw new ArgumentException(MvcResources.Common_NullOrEmpty, "viewName");
+            }
+
+            string[] viewLocationsSearched;
+            string[] masterLocationsSearched;
+
+            string controllerName = controllerContext.RouteData.GetRequiredString("controller");
+            string viewPath = GetPath(controllerContext, ViewLocationFormats, AreaViewLocationFormats, "ViewLocationFormats", viewName, controllerName, _cacheKeyPrefix_View, useCache, out viewLocationsSearched);
+            string masterPath = GetPath(controllerContext, MasterLocationFormats, AreaMasterLocationFormats, "MasterLocationFormats", masterName, controllerName, _cacheKeyPrefix_Master, useCache, out masterLocationsSearched);
+
+            if (String.IsNullOrEmpty(viewPath) || (String.IsNullOrEmpty(masterPath) && !String.IsNullOrEmpty(masterName))) {
+                return new ViewEngineResult(viewLocationsSearched.Union(masterLocationsSearched));
+            }
+
+            return new ViewEngineResult(CreateView(controllerContext, viewPath, masterPath), this);
+        }
+
+        private string GetPath(ControllerContext controllerContext, string[] locations, string[] areaLocations, string locationsPropertyName, string name, string controllerName, string cacheKeyPrefix, bool useCache, out string[] searchedLocations) {
+            searchedLocations = _emptyLocations;
+
+            if (String.IsNullOrEmpty(name)) {
+                return String.Empty;
+            }
+
+            string areaName = AreaHelpers.GetAreaName(controllerContext.RouteData);
+            bool usingAreas = !String.IsNullOrEmpty(areaName);
+            List<ViewLocation> viewLocations = GetViewLocations(locations, (usingAreas) ? areaLocations : null);
+
+            if (viewLocations.Count == 0) {
+                throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture,
+                    MvcResources.Common_PropertyCannotBeNullOrEmpty, locationsPropertyName));
+            }
+
+            bool nameRepresentsPath = IsSpecificPath(name);
+            string cacheKey = CreateCacheKey(cacheKeyPrefix, name, (nameRepresentsPath) ? String.Empty : controllerName, areaName);
+
+            if (useCache) {
+                return ViewLocationCache.GetViewLocation(controllerContext.HttpContext, cacheKey);
+            }
+
+            return (nameRepresentsPath) ?
+                GetPathFromSpecificName(controllerContext, name, cacheKey, ref searchedLocations) :
+                GetPathFromGeneralName(controllerContext, viewLocations, name, controllerName, areaName, cacheKey, ref searchedLocations);
+        }
+
+        private string GetPathFromGeneralName(ControllerContext controllerContext, List<ViewLocation> locations, string name, string controllerName, string areaName, string cacheKey, ref string[] searchedLocations) {
+            string result = String.Empty;
+            searchedLocations = new string[locations.Count];
+
+            for (int i = 0; i < locations.Count; i++) {
+                ViewLocation location = locations[i];
+                string virtualPath = location.Format(name, controllerName, areaName);
+
+                if (FileExists(controllerContext, virtualPath)) {
+                    searchedLocations = _emptyLocations;
+                    result = virtualPath;
+                    ViewLocationCache.InsertViewLocation(controllerContext.HttpContext, cacheKey, result);
+                    break;
+                }
+
+                searchedLocations[i] = virtualPath;
+            }
+
+            return result;
+        }
+
+        private string GetPathFromSpecificName(ControllerContext controllerContext, string name, string cacheKey, ref string[] searchedLocations) {
+            string result = name;
+
+            if (!(FilePathIsSupported(name) && FileExists(controllerContext, name))) {
+                result = String.Empty;
+                searchedLocations = new[] { name };
+            }
+
+            ViewLocationCache.InsertViewLocation(controllerContext.HttpContext, cacheKey, result);
+            return result;
+        }
+
+        private bool FilePathIsSupported(string virtualPath) {
+            if (FileExtensions == null) {
+                // legacy behavior for custom ViewEngine that might not set the FileExtensions property
+                return true;
+            }
+            else {
+                // get rid of the '.' because the FileExtensions property expects extensions withouth a dot.
+                string extension = GetExtensionThunk(virtualPath).TrimStart('.');
+                return FileExtensions.Contains(extension, StringComparer.OrdinalIgnoreCase);
+            }
+        }
+
+        private static List<ViewLocation> GetViewLocations(string[] viewLocationFormats, string[] areaViewLocationFormats) {
+            List<ViewLocation> allLocations = new List<ViewLocation>();
+
+            if (areaViewLocationFormats != null) {
+                foreach (string areaViewLocationFormat in areaViewLocationFormats) {
+                    allLocations.Add(new AreaAwareViewLocation(areaViewLocationFormat));
+                }
+            }
+
+            if (viewLocationFormats != null) {
+                foreach (string viewLocationFormat in viewLocationFormats) {
+                    allLocations.Add(new ViewLocation(viewLocationFormat));
+                }
+            }
+
+            return allLocations;
+        }
+
+        private static bool IsSpecificPath(string name) {
+            char c = name[0];
+            return (c == '~' || c == '/');
+        }
+
+        public virtual void ReleaseView(ControllerContext controllerContext, IView view) {
+            IDisposable disposable = view as IDisposable;
+            if (disposable != null) {
+                disposable.Dispose();
+            }
+        }
+
+        private class ViewLocation {
+
+            protected string _virtualPathFormatString;
+
+            public ViewLocation(string virtualPathFormatString) {
+                _virtualPathFormatString = virtualPathFormatString;
+            }
+
+            public virtual string Format(string viewName, string controllerName, string areaName) {
+                return String.Format(CultureInfo.InvariantCulture, _virtualPathFormatString, viewName, controllerName);
+            }
+
+        }
+
+        private class AreaAwareViewLocation : ViewLocation {
+
+            public AreaAwareViewLocation(string virtualPathFormatString)
+                : base(virtualPathFormatString) {
+            }
+
+            public override string Format(string viewName, string controllerName, string areaName) {
+                return String.Format(CultureInfo.InvariantCulture, _virtualPathFormatString, viewName, controllerName, areaName);
+            }
+
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/WebFormView.cs b/mcs/class/System.Web.Mvc3/Mvc/WebFormView.cs
new file mode 100644 (file)
index 0000000..a380574
--- /dev/null
@@ -0,0 +1,66 @@
+namespace System.Web.Mvc {
+    using System;
+    using System.Globalization;
+    using System.IO;
+    using System.Web.Mvc.Resources;
+
+    public class WebFormView : BuildManagerCompiledView {
+
+        public WebFormView(ControllerContext controllerContext, string viewPath)
+            : this(controllerContext, viewPath, null, null) {
+        }
+
+        public WebFormView(ControllerContext controllerContext, string viewPath, string masterPath)
+            : this(controllerContext, viewPath, masterPath, null) {
+        }
+
+        public WebFormView(ControllerContext controllerContext, string viewPath, string masterPath, IViewPageActivator viewPageActivator)
+            : base(controllerContext, viewPath, viewPageActivator) {
+            MasterPath = masterPath ?? String.Empty;
+        }
+
+        public string MasterPath {
+            get;
+            private set;
+        }
+
+        protected override void RenderView(ViewContext viewContext, TextWriter writer, object instance) {
+
+            ViewPage viewPage = instance as ViewPage;
+            if (viewPage != null) {
+                RenderViewPage(viewContext, viewPage);
+                return;
+            }
+
+            ViewUserControl viewUserControl = instance as ViewUserControl;
+            if (viewUserControl != null) {
+                RenderViewUserControl(viewContext, viewUserControl);
+                return;
+            }
+
+            throw new InvalidOperationException(
+                String.Format(
+                    CultureInfo.CurrentCulture,
+                    MvcResources.WebFormViewEngine_WrongViewBase,
+                    ViewPath));
+        }
+
+        private void RenderViewPage(ViewContext context, ViewPage page) {
+            if (!String.IsNullOrEmpty(MasterPath)) {
+                page.MasterLocation = MasterPath;
+            }
+
+            page.ViewData = context.ViewData;
+            page.RenderView(context);
+        }
+
+        private void RenderViewUserControl(ViewContext context, ViewUserControl control) {
+            if (!String.IsNullOrEmpty(MasterPath)) {
+                throw new InvalidOperationException(MvcResources.WebFormViewEngine_UserControlCannotHaveMaster);
+            }
+
+            control.ViewData = context.ViewData;
+            control.RenderView(context);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/WebFormViewEngine.cs b/mcs/class/System.Web.Mvc3/Mvc/WebFormViewEngine.cs
new file mode 100644 (file)
index 0000000..1b115ec
--- /dev/null
@@ -0,0 +1,52 @@
+namespace System.Web.Mvc {
+    public class WebFormViewEngine : BuildManagerViewEngine {
+
+        public WebFormViewEngine()
+            : this(null) {
+        }
+
+        public WebFormViewEngine(IViewPageActivator viewPageActivator)
+            :base(viewPageActivator){
+            MasterLocationFormats = new[] {
+                "~/Views/{1}/{0}.master",
+                "~/Views/Shared/{0}.master"
+            };
+
+            AreaMasterLocationFormats = new[] {
+                "~/Areas/{2}/Views/{1}/{0}.master",
+                "~/Areas/{2}/Views/Shared/{0}.master",
+            };
+
+            ViewLocationFormats = new[] {
+                "~/Views/{1}/{0}.aspx",
+                "~/Views/{1}/{0}.ascx",
+                "~/Views/Shared/{0}.aspx",
+                "~/Views/Shared/{0}.ascx"
+            };
+
+            AreaViewLocationFormats = new[] {
+                "~/Areas/{2}/Views/{1}/{0}.aspx",
+                "~/Areas/{2}/Views/{1}/{0}.ascx",
+                "~/Areas/{2}/Views/Shared/{0}.aspx",
+                "~/Areas/{2}/Views/Shared/{0}.ascx",
+            };
+
+            PartialViewLocationFormats = ViewLocationFormats;
+            AreaPartialViewLocationFormats = AreaViewLocationFormats;
+
+            FileExtensions = new[] {
+                "aspx",
+                "ascx",
+                "master",
+            };
+        }
+
+        protected override IView CreatePartialView(ControllerContext controllerContext, string partialPath) {
+            return new WebFormView(controllerContext, partialPath, null, ViewPageActivator);
+        }
+
+        protected override IView CreateView(ControllerContext controllerContext, string viewPath, string masterPath) {
+            return new WebFormView(controllerContext, viewPath, masterPath, ViewPageActivator);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/WebViewPage.cs b/mcs/class/System.Web.Mvc3/Mvc/WebViewPage.cs
new file mode 100644 (file)
index 0000000..0ed9d30
--- /dev/null
@@ -0,0 +1,116 @@
+namespace System.Web.Mvc {
+    using System.Diagnostics.CodeAnalysis;
+    using System.Globalization;
+    using System.Web.Mvc.Resources;
+    using System.Web.WebPages;
+
+    public abstract class WebViewPage : WebPageBase, IViewDataContainer, IViewStartPageChild {
+
+        private ViewDataDictionary _viewData;
+        private DynamicViewDataDictionary _dynamicViewData;
+        private HttpContextBase _context;
+
+        public AjaxHelper<object> Ajax {
+            get;
+            set;
+        }
+
+        public override HttpContextBase Context {
+            // REVIEW why are we forced to override this?
+            get {
+                return _context ?? ViewContext.HttpContext;
+            }
+            set {
+                _context = value;
+            }
+        }
+
+        public HtmlHelper<object> Html {
+            get;
+            set;
+        }
+
+        public object Model {
+            get {
+                return ViewData.Model;
+            }
+        }
+
+        internal string OverridenLayoutPath { get; set; }
+
+        public TempDataDictionary TempData {
+            get {
+                return ViewContext.TempData;
+            }
+        }
+
+        public UrlHelper Url {
+            get;
+            set;
+        }
+
+        public dynamic ViewBag {
+            get {
+                if (_dynamicViewData == null) {
+                    _dynamicViewData = new DynamicViewDataDictionary(() => ViewData);
+                }
+                return _dynamicViewData;
+            }
+        }
+
+        public ViewContext ViewContext {
+            get;
+            set;
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This is the mechanism by which the ViewPage gets its ViewDataDictionary object.")]
+        public ViewDataDictionary ViewData {
+            get {
+                if (_viewData == null) {
+                    SetViewData(new ViewDataDictionary());
+                }
+                return _viewData;
+            }
+            set {
+                SetViewData(value);
+            }
+        }
+
+        protected override void ConfigurePage(WebPageBase parentPage) {
+            var baseViewPage = parentPage as WebViewPage;
+            if (baseViewPage == null) {
+                // TODO : review if this check is even necessary.
+                // When this method is called by the framework parentPage should already be an instance of WebViewPage
+                // Need to review what happens if this method gets called in Plan9 pointing at an MVC view
+                throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture, MvcResources.CshtmlView_WrongViewBase, parentPage.VirtualPath));
+            }
+
+            // Set ViewContext and ViewData here so that the layout page inherits ViewData from the main page
+            ViewContext = baseViewPage.ViewContext;
+            ViewData = baseViewPage.ViewData;
+            InitHelpers();
+        }
+
+        public override void ExecutePageHierarchy() {
+            // Change the Writer so that things like Html.BeginForm work correctly
+            ViewContext.Writer = Output;
+
+            base.ExecutePageHierarchy();
+
+            // Overwrite LayoutPage so that returning a view with a custom master page works.
+            if (!String.IsNullOrEmpty(OverridenLayoutPath)) {
+                Layout = OverridenLayoutPath;
+            }
+        }
+
+        public virtual void InitHelpers() {
+            Ajax = new AjaxHelper<object>(ViewContext, this);
+            Html = new HtmlHelper<object>(ViewContext, this);
+            Url = new UrlHelper(ViewContext.RequestContext);
+        }
+
+        protected virtual void SetViewData(ViewDataDictionary viewData) {
+            _viewData = viewData;
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Mvc/WebViewPage`1.cs b/mcs/class/System.Web.Mvc3/Mvc/WebViewPage`1.cs
new file mode 100644 (file)
index 0000000..873b47b
--- /dev/null
@@ -0,0 +1,49 @@
+namespace System.Web.Mvc {
+    using System.Diagnostics.CodeAnalysis;
+
+    public abstract class WebViewPage<TModel> : WebViewPage {
+        private ViewDataDictionary<TModel> _viewData;
+
+        public new AjaxHelper<TModel> Ajax {
+            get;
+            set;
+        }
+
+        public new HtmlHelper<TModel> Html {
+            get;
+            set;
+        }
+
+        public new TModel Model {
+            get {
+                return ViewData.Model;
+            }
+        }
+
+        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly", Justification = "This is the mechanism by which the ViewPage gets its ViewDataDictionary object.")]
+        public new ViewDataDictionary<TModel> ViewData {
+            get {
+                if (_viewData == null) {
+                    SetViewData(new ViewDataDictionary<TModel>());
+                }
+                return _viewData;
+            }
+            set {
+                SetViewData(value);
+            }
+        }
+
+        public override void InitHelpers() {
+            base.InitHelpers();
+
+            Ajax = new AjaxHelper<TModel>(ViewContext, this);
+            Html = new HtmlHelper<TModel>(ViewContext, this);
+        }
+
+        protected override void SetViewData(ViewDataDictionary viewData) {
+            _viewData = new ViewDataDictionary<TModel>(viewData);
+
+            base.SetViewData(_viewData);
+        }
+    }
+}
diff --git a/mcs/class/System.Web.Mvc3/Properties/AssemblyInfo.cs b/mcs/class/System.Web.Mvc3/Properties/AssemblyInfo.cs
new file mode 100644 (file)
index 0000000..6875085
--- /dev/null
@@ -0,0 +1,27 @@
+using System;
+using System.Diagnostics.CodeAnalysis;
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+using System.Security;
+using System.Web;
+
+[assembly: AssemblyTitle("System.Web.Mvc.dll")]
+[assembly: AssemblyDescription("System.Web.Mvc.dll")]
+[assembly: ComVisible(false)]
+[assembly: Guid("4b5f4208-c6b0-4c37-9a41-63325ffa52ad")]
+#if !CODE_COVERAGE
+[assembly: AllowPartiallyTrustedCallers]
+[assembly: SecurityTransparent]
+#endif
+[assembly: CLSCompliant(true)]
+#if !MONO
+[assembly: InternalsVisibleTo("System.Web.Mvc.Test")]
+#endif
+
+[assembly: PreApplicationStartMethod(typeof(System.Web.Mvc.PreApplicationStartCode), "Start")]
+
+[assembly: TypeForwardedTo(typeof(System.Web.Mvc.TagBuilder))]
+[assembly: TypeForwardedTo(typeof(System.Web.Mvc.TagRenderMode))]
+[assembly: TypeForwardedTo(typeof(System.Web.Mvc.HttpAntiForgeryException))]
+
diff --git a/mcs/class/System.Web.Mvc3/System.Web.Mvc.csproj b/mcs/class/System.Web.Mvc3/System.Web.Mvc.csproj
new file mode 100644 (file)
index 0000000..c134594
--- /dev/null
@@ -0,0 +1,471 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{3D3FFD8A-624D-4E9B-954B-E1C105507975}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <RootNamespace>System.Web</RootNamespace>\r
+    <AssemblyName>System.Web.Mvc</AssemblyName>\r
+    <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>\r
+    <FileAlignment>512</FileAlignment>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <TreatWarningsAsErrors>true</TreatWarningsAsErrors>\r
+    <BaseAddress>1609891840</BaseAddress>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <Optimize>false</Optimize>\r
+    <OutputPath>..\..\bin\Debug\</OutputPath>\r
+    <DefineConstants>DEBUG;TRACE</DefineConstants>\r
+    <CodeAnalysisRuleSet>..\FxCopRules.ruleset</CodeAnalysisRuleSet>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <Optimize>true</Optimize>\r
+    <OutputPath>..\..\bin\Release\</OutputPath>\r
+    <DefineConstants>TRACE</DefineConstants>\r
+    <CodeAnalysisRuleSet>..\FxCopRules.ruleset</CodeAnalysisRuleSet>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'FxCop|AnyCPU'">\r
+    <DebugType>pdbonly</DebugType>\r
+    <Optimize>true</Optimize>\r
+    <OutputPath>..\..\bin\FxCop\</OutputPath>\r
+    <DefineConstants>TRACE;CODE_ANALYSIS</DefineConstants>\r
+    <CodeAnalysisRuleSet>..\FxCopRules.ruleset</CodeAnalysisRuleSet>\r
+    <RunCodeAnalysis>true</RunCodeAnalysis>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'CodeCoverage|AnyCPU'">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <OutputPath>..\..\bin\CodeCoverage\</OutputPath>\r
+    <DefineConstants>TRACE;DEBUG;CODE_COVERAGE</DefineConstants>\r
+    <DebugType>full</DebugType>\r
+    <CodeAnalysisRuleSet>..\FxCopRules.ruleset</CodeAnalysisRuleSet>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="Microsoft.Web.Infrastructure, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">\r
+      <SpecificVersion>False</SpecificVersion>\r
+      <HintPath>..\..\..\webpages\ReferenceAssemblies\Microsoft.Web.Infrastructure.dll</HintPath>\r
+    </Reference>\r
+    <Reference Include="System" />\r
+    <Reference Include="System.ComponentModel.DataAnnotations" />\r
+    <Reference Include="System.configuration" />\r
+    <Reference Include="System.Core" />\r
+    <Reference Include="System.Data.Entity" />\r
+    <Reference Include="System.Data.Linq" />\r
+    <Reference Include="System.Runtime.Caching" />\r
+    <Reference Include="System.Web" />\r
+    <Reference Include="System.Data" />\r
+    <Reference Include="System.Web.Abstractions" />\r
+    <Reference Include="System.Web.Extensions" />\r
+    <Reference Include="System.Web.Routing" />\r
+    <Reference Include="System.Xml" />\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Compile Include="..\GlobalAssemblyInfo.cs">\r
+      <Link>Properties\GlobalAssemblyInfo.cs</Link>\r
+    </Compile>\r
+    <Compile Include="Mvc\AdditionalMetaDataAttribute.cs" />\r
+    <Compile Include="Mvc\BuildManagerCompiledView.cs" />\r
+    <Compile Include="Mvc\BuildManagerViewEngine.cs" />\r
+    <Compile Include="Mvc\CompareAttribute.cs" />\r
+    <Compile Include="Mvc\ChildActionValueProvider.cs" />\r
+    <Compile Include="Mvc\ChildActionValueProviderFactory.cs" />\r
+    <Compile Include="Mvc\DataTypeUtil.cs" />\r
+    <Compile Include="Mvc\ReflectedAttributeCache.cs" />\r
+    <Compile Include="Mvc\SessionStateAttribute.cs" />\r
+    <Compile Include="Mvc\AllowHtmlAttribute.cs" />\r
+    <Compile Include="Mvc\UnvalidatedRequestValuesAccessor.cs" />\r
+    <Compile Include="Mvc\UnvalidatedRequestValuesWrapper.cs" />\r
+    <Compile Include="Mvc\IUnvalidatedRequestValues.cs" />\r
+    <Compile Include="Mvc\IUnvalidatedValueProvider.cs" />\r
+    <Compile Include="Mvc\DependencyResolverExtensions.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\BinaryExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\CachedExpressionCompiler.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\ConditionalExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\ConstantExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\DefaultExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\ExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\ExpressionFingerprintChain.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\FingerprintingExpressionVisitor.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\HashCodeCombiner.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\Hoisted`2.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\HoistingExpressionVisitor.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\IndexExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\LambdaExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\MemberExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\MethodCallExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\ParameterExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\TypeBinaryExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\ExpressionUtil\UnaryExpressionFingerprint.cs" />\r
+    <Compile Include="Mvc\IControllerActivator.cs" />\r
+    <Compile Include="Mvc\IModelBinderProvider.cs" />\r
+    <Compile Include="Mvc\IUniquelyIdentifiable.cs" />\r
+    <Compile Include="Mvc\IViewStartPageChild.cs" />\r
+    <Compile Include="Mvc\IResolver.cs" />\r
+    <Compile Include="Mvc\ControllerInstanceFilterProvider.cs" />\r
+    <Compile Include="Mvc\ModelClientValidationEqualToRule.cs" />\r
+    <Compile Include="Mvc\ModelClientValidationRemoteRule.cs" />\r
+    <Compile Include="Mvc\RazorView.cs" />\r
+    <Compile Include="Mvc\RazorViewEngine.cs" />\r
+    <Compile Include="Mvc\DynamicViewDataDictionary.cs" />\r
+    <Compile Include="Mvc\Filter.cs" />\r
+    <Compile Include="Mvc\FilterAttributeFilterProvider.cs" />\r
+    <Compile Include="Mvc\FilterProviderCollection.cs" />\r
+    <Compile Include="Mvc\FilterProviders.cs" />\r
+    <Compile Include="Mvc\FilterScope.cs" />\r
+    <Compile Include="Mvc\GlobalFilterCollection.cs" />\r
+    <Compile Include="Mvc\GlobalFilters.cs" />\r
+    <Compile Include="Mvc\IFilterProvider.cs" />\r
+    <Compile Include="Mvc\IMvcFilter.cs" />\r
+    <Compile Include="Mvc\IViewPageActivator.cs" />\r
+    <Compile Include="Mvc\ModelBinderProviderCollection.cs" />\r
+    <Compile Include="Mvc\ModelBinderProviders.cs" />\r
+    <Compile Include="Mvc\MultiServiceResolver.cs" />\r
+    <Compile Include="Mvc\Razor\ModelSpan.cs" />\r
+    <Compile Include="Mvc\Razor\MvcCSharpRazorCodeParser.cs" />\r
+    <Compile Include="Mvc\Razor\MvcCSharpRazorCodeGenerator.cs" />\r
+    <Compile Include="Mvc\MvcFilter.cs" />\r
+    <Compile Include="Mvc\Razor\MvcVBRazorCodeGenerator.cs" />\r
+    <Compile Include="Mvc\Razor\MvcVBRazorCodeParser.cs" />\r
+    <Compile Include="Mvc\Razor\MvcWebPageRazorHost.cs" />\r
+    <Compile Include="Mvc\MvcWebRazorHostFactory.cs" />\r
+    <Compile Include="Mvc\PreApplicationStartCode.cs" />\r
+    <Compile Include="Mvc\RemoteAttribute.cs" />\r
+    <Compile Include="Mvc\SecurityUtil.cs" />\r
+    <Compile Include="Mvc\SingleServiceResolver.cs" />\r
+    <Compile Include="Mvc\Razor\StartPageLookupDelegate.cs" />\r
+    <Compile Include="Mvc\TagBuilderExtensions.cs" />\r
+    <Compile Include="Mvc\UrlRewriterHelper.cs" />\r
+    <Compile Include="Mvc\ViewStartPage.cs" />\r
+    <Compile Include="Mvc\WebViewPage.cs" />\r
+    <Compile Include="Mvc\WebViewPage`1.cs" />\r
+    <Compile Include="Mvc\HttpNotFoundResult.cs" />\r
+    <Compile Include="Mvc\HttpStatusCodeResult.cs" />\r
+    <Compile Include="Mvc\IMvcControlBuilder.cs" />\r
+    <Compile Include="Mvc\AssociatedMetadataProvider.cs" />\r
+    <Compile Include="Mvc\ActionExecutedContext.cs" />\r
+    <Compile Include="Mvc\ActionExecutingContext.cs" />\r
+    <Compile Include="Mvc\ClientDataTypeModelValidatorProvider.cs" />\r
+    <Compile Include="Mvc\AssociatedValidatorProvider.cs" />\r
+    <Compile Include="Mvc\Async\ActionDescriptorCreator.cs" />\r
+    <Compile Include="Mvc\Async\AsyncActionDescriptor.cs" />\r
+    <Compile Include="Mvc\Async\AsyncActionMethodSelector.cs" />\r
+    <Compile Include="Mvc\Async\AsyncControllerActionInvoker.cs" />\r
+    <Compile Include="Mvc\Async\SynchronousOperationException.cs" />\r
+    <Compile Include="Mvc\Async\AsyncManager.cs" />\r
+    <Compile Include="Mvc\AsyncTimeoutAttribute.cs" />\r
+    <Compile Include="Mvc\Async\BeginInvokeDelegate.cs" />\r
+    <Compile Include="Mvc\Async\AsyncResultWrapper.cs" />\r
+    <Compile Include="Mvc\Async\AsyncVoid.cs" />\r
+    <Compile Include="Mvc\AsyncController.cs" />\r
+    <Compile Include="Mvc\Async\AsyncUtil.cs" />\r
+    <Compile Include="Mvc\Async\IAsyncController.cs" />\r
+    <Compile Include="Mvc\Async\IAsyncActionInvoker.cs" />\r
+    <Compile Include="Mvc\Async\IAsyncManagerContainer.cs" />\r
+    <Compile Include="Mvc\IClientValidatable.cs" />\r
+    <Compile Include="Mvc\IMetadataAware.cs" />\r
+    <Compile Include="Mvc\IDependencyResolver.cs" />\r
+    <Compile Include="Mvc\JsonValueProviderFactory.cs" />\r
+    <Compile Include="Mvc\DependencyResolver.cs" />\r
+    <Compile Include="Mvc\UrlParameter.cs" />\r
+    <Compile Include="Mvc\FormValueProvider.cs" />\r
+    <Compile Include="Mvc\FormValueProviderFactory.cs" />\r
+    <Compile Include="Mvc\HttpFileCollectionValueProvider.cs" />\r
+    <Compile Include="Mvc\HttpFileCollectionValueProviderFactory.cs" />\r
+    <Compile Include="Mvc\QueryStringValueProvider.cs" />\r
+    <Compile Include="Mvc\QueryStringValueProviderFactory.cs" />\r
+    <Compile Include="Mvc\RangeAttributeAdapter.cs" />\r
+    <Compile Include="Mvc\RegularExpressionAttributeAdapter.cs" />\r
+    <Compile Include="Mvc\RequiredAttributeAdapter.cs" />\r
+    <Compile Include="Mvc\RouteDataValueProvider.cs" />\r
+    <Compile Include="Mvc\RouteDataValueProviderFactory.cs" />\r
+    <Compile Include="Mvc\StringLengthAttributeAdapter.cs" />\r
+    <Compile Include="Mvc\TypeCacheUtil.cs" />\r
+    <Compile Include="Mvc\TypeCacheSerializer.cs" />\r
+    <Compile Include="Mvc\Html\DisplayTextExtensions.cs" />\r
+    <Compile Include="Mvc\NoAsyncTimeoutAttribute.cs" />\r
+    <Compile Include="Mvc\Async\OperationCounter.cs" />\r
+    <Compile Include="Mvc\Async\ReflectedAsyncActionDescriptor.cs" />\r
+    <Compile Include="Mvc\Async\ReflectedAsyncControllerDescriptor.cs" />\r
+    <Compile Include="Mvc\Async\Trigger.cs" />\r
+    <Compile Include="Mvc\Async\TriggerListener.cs" />\r
+    <Compile Include="Mvc\Async\SimpleAsyncResult.cs" />\r
+    <Compile Include="Mvc\Async\EndInvokeDelegate.cs" />\r
+    <Compile Include="Mvc\Async\EndInvokeDelegate`1.cs" />\r
+    <Compile Include="Mvc\Async\SynchronizationContextUtil.cs" />\r
+    <Compile Include="Mvc\AuthorizationContext.cs" />\r
+    <Compile Include="Mvc\ByteArrayModelBinder.cs" />\r
+    <Compile Include="Mvc\ControllerContext.cs" />\r
+    <Compile Include="Mvc\Html\ChildActionExtensions.cs" />\r
+    <Compile Include="Mvc\ParameterInfoUtil.cs" />\r
+    <Compile Include="Mvc\HttpHandlerUtil.cs" />\r
+    <Compile Include="Mvc\ChildActionOnlyAttribute.cs" />\r
+    <Compile Include="Mvc\TypeDescriptorHelper.cs" />\r
+    <Compile Include="Mvc\ValidatableObjectAdapter.cs" />\r
+    <Compile Include="Mvc\ValueProviderFactories.cs" />\r
+    <Compile Include="Mvc\ValueProviderFactory.cs" />\r
+    <Compile Include="Mvc\ValueProviderFactoryCollection.cs" />\r
+    <Compile Include="Mvc\ValueProviderCollection.cs" />\r
+    <Compile Include="Mvc\DictionaryValueProvider`1.cs" />\r
+    <Compile Include="Mvc\NameValueCollectionValueProvider.cs" />\r
+    <Compile Include="Mvc\ValueProviderUtil.cs" />\r
+    <Compile Include="Mvc\IValueProvider.cs" />\r
+    <Compile Include="Mvc\DataErrorInfoModelValidatorProvider.cs" />\r
+    <Compile Include="Mvc\ModelValidatorProviderCollection.cs" />\r
+    <Compile Include="Mvc\DataAnnotationsModelMetadata.cs" />\r
+    <Compile Include="Mvc\HiddenInputAttribute.cs" />\r
+    <Compile Include="Mvc\HttpGetAttribute.cs" />\r
+    <Compile Include="Mvc\HttpPutAttribute.cs" />\r
+    <Compile Include="Mvc\HttpDeleteAttribute.cs" />\r
+    <Compile Include="Mvc\ModelClientValidationRequiredRule.cs" />\r
+    <Compile Include="Mvc\ModelClientValidationRangeRule.cs" />\r
+    <Compile Include="Mvc\ModelClientValidationStringLengthRule.cs" />\r
+    <Compile Include="Mvc\MvcHtmlString.cs" />\r
+    <Compile Include="Mvc\DataAnnotationsModelValidator.cs" />\r
+    <Compile Include="Mvc\DataAnnotationsModelValidatorProvider.cs" />\r
+    <Compile Include="Mvc\DataAnnotationsModelValidator`1.cs" />\r
+    <Compile Include="Mvc\EmptyModelValidatorProvider.cs" />\r
+    <Compile Include="Mvc\ExpressionHelper.cs" />\r
+    <Compile Include="Mvc\FieldValidationMetadata.cs" />\r
+    <Compile Include="Mvc\FormContext.cs" />\r
+    <Compile Include="Mvc\JsonRequestBehavior.cs" />\r
+    <Compile Include="Mvc\ModelClientValidationRegexRule.cs" />\r
+    <Compile Include="Mvc\ModelClientValidationRule.cs" />\r
+    <Compile Include="Mvc\ModelValidationResult.cs" />\r
+    <Compile Include="Mvc\ModelValidator.cs" />\r
+    <Compile Include="Mvc\ModelValidatorProvider.cs" />\r
+    <Compile Include="Mvc\ModelValidatorProviders.cs" />\r
+    <Compile Include="Mvc\RequireHttpsAttribute.cs" />\r
+    <Compile Include="Mvc\HttpRequestExtensions.cs" />\r
+    <Compile Include="Mvc\DataAnnotationsModelMetadataProvider.cs" />\r
+    <Compile Include="Mvc\EmptyModelMetadataProvider.cs" />\r
+    <Compile Include="Mvc\ModelMetadata.cs" />\r
+    <Compile Include="Mvc\ModelMetadataProvider.cs" />\r
+    <Compile Include="Mvc\ModelMetadataProviders.cs" />\r
+    <Compile Include="Mvc\AreaHelpers.cs" />\r
+    <Compile Include="Mvc\AreaRegistration.cs" />\r
+    <Compile Include="Mvc\AreaRegistrationContext.cs" />\r
+    <Compile Include="Mvc\Error.cs" />\r
+    <Compile Include="Mvc\IRouteWithArea.cs" />\r
+    <Compile Include="Mvc\Async\SingleEntryGate.cs" />\r
+    <Compile Include="Mvc\Html\PartialExtensions.cs" />\r
+    <Compile Include="Mvc\LinqBinaryModelBinder.cs" />\r
+    <Compile Include="Mvc\TryGetValueDelegate.cs" />\r
+    <Compile Include="Mvc\ViewDataInfo.cs" />\r
+    <Compile Include="Mvc\Html\DefaultDisplayTemplates.cs" />\r
+    <Compile Include="Mvc\Html\DefaultEditorTemplates.cs" />\r
+    <Compile Include="Mvc\Html\DisplayExtensions.cs" />\r
+    <Compile Include="Mvc\Html\EditorExtensions.cs" />\r
+    <Compile Include="Mvc\Html\LabelExtensions.cs" />\r
+    <Compile Include="Mvc\Html\TemplateHelpers.cs" />\r
+    <Compile Include="Mvc\HttpPostAttribute.cs" />\r
+    <Compile Include="Mvc\PathHelpers.cs" />\r
+    <Compile Include="Mvc\ExceptionContext.cs" />\r
+    <Compile Include="Mvc\ResultExecutedContext.cs" />\r
+    <Compile Include="Mvc\ResultExecutingContext.cs" />\r
+    <Compile Include="Mvc\TemplateInfo.cs" />\r
+    <Compile Include="Mvc\ValidateAntiForgeryTokenAttribute.cs" />\r
+    <Compile Include="Mvc\JavaScriptResult.cs" />\r
+    <Compile Include="Mvc\ActionDescriptor.cs" />\r
+    <Compile Include="Mvc\ActionMethodDispatcher.cs" />\r
+    <Compile Include="Mvc\ActionMethodSelector.cs" />\r
+    <Compile Include="Mvc\ActionMethodSelectorAttribute.cs" />\r
+    <Compile Include="Mvc\ActionNameSelectorAttribute.cs" />\r
+    <Compile Include="Mvc\AuthorizeAttribute.cs" />\r
+    <Compile Include="Mvc\Ajax\AjaxOptions.cs" />\r
+    <Compile Include="Mvc\Ajax\AjaxExtensions.cs" />\r
+    <Compile Include="Mvc\ActionMethodDispatcherCache.cs" />\r
+    <Compile Include="Mvc\BindAttribute.cs" />\r
+    <Compile Include="Mvc\ControllerBase.cs" />\r
+    <Compile Include="Mvc\ActionNameAttribute.cs" />\r
+    <Compile Include="Mvc\AcceptVerbsAttribute.cs" />\r
+    <Compile Include="Mvc\AjaxHelper`1.cs" />\r
+    <Compile Include="Mvc\HtmlHelper`1.cs" />\r
+    <Compile Include="Mvc\DictionaryHelpers.cs" />\r
+    <Compile Include="Mvc\AjaxRequestExtensions.cs" />\r
+    <Compile Include="Mvc\ModelBinderDictionary.cs" />\r
+    <Compile Include="Mvc\ValueProviderDictionary.cs" />\r
+    <Compile Include="Mvc\ViewContext.cs" />\r
+    <Compile Include="Mvc\ViewMasterPageControlBuilder.cs" />\r
+    <Compile Include="Mvc\ViewTemplateUserControl.cs">\r
+      <SubType>ASPXCodeBehind</SubType>\r
+    </Compile>\r
+    <Compile Include="Mvc\ViewTemplateUserControl`1.cs">\r
+      <SubType>ASPXCodeBehind</SubType>\r
+    </Compile>\r
+    <Compile Include="Mvc\ViewType.cs" />\r
+    <Compile Include="Mvc\ViewTypeControlBuilder.cs" />\r
+    <Compile Include="Mvc\ViewUserControlControlBuilder.cs">\r
+    </Compile>\r
+    <Compile Include="Mvc\ViewPageControlBuilder.cs">\r
+    </Compile>\r
+    <Compile Include="Mvc\ViewTypeParserFilter.cs" />\r
+    <Compile Include="Mvc\DefaultViewLocationCache.cs" />\r
+    <Compile Include="Mvc\FormCollection.cs" />\r
+    <Compile Include="Mvc\HttpPostedFileBaseModelBinder.cs" />\r
+    <Compile Include="Mvc\NullViewLocationCache.cs" />\r
+    <Compile Include="Mvc\ValidateInputAttribute.cs" />\r
+    <Compile Include="Mvc\FileContentResult.cs" />\r
+    <Compile Include="Mvc\FilePathResult.cs" />\r
+    <Compile Include="Mvc\FileResult.cs" />\r
+    <Compile Include="Mvc\FileStreamResult.cs" />\r
+    <Compile Include="Mvc\InputType.cs" />\r
+    <Compile Include="Mvc\ControllerDescriptorCache.cs" />\r
+    <Compile Include="Mvc\ReflectedParameterBindingInfo.cs" />\r
+    <Compile Include="Mvc\ParameterBindingInfo.cs" />\r
+    <Compile Include="Mvc\ReaderWriterCache`2.cs" />\r
+    <Compile Include="Mvc\DescriptorUtil.cs" />\r
+    <Compile Include="Mvc\ReflectedControllerDescriptor.cs" />\r
+    <Compile Include="Mvc\ControllerDescriptor.cs" />\r
+    <Compile Include="Mvc\ActionSelector.cs" />\r
+    <Compile Include="Mvc\ReflectedActionDescriptor.cs" />\r
+    <Compile Include="Mvc\Html\MvcForm.cs" />\r
+    <Compile Include="Mvc\HttpVerbs.cs" />\r
+    <Compile Include="Mvc\DefaultModelBinder.cs" />\r
+    <Compile Include="Mvc\ModelBindingContext.cs" />\r
+    <Compile Include="Mvc\ParameterDescriptor.cs" />\r
+    <Compile Include="Mvc\RouteValuesHelpers.cs" />\r
+    <Compile Include="Mvc\SelectListItem.cs" />\r
+    <Compile Include="Mvc\ReflectedParameterDescriptor.cs" />\r
+    <Compile Include="Mvc\ValueProviderResult.cs" />\r
+    <Compile Include="Mvc\CustomModelBinderAttribute.cs" />\r
+    <Compile Include="Mvc\FormMethod.cs" />\r
+    <Compile Include="Mvc\Html\FormExtensions.cs" />\r
+    <Compile Include="Mvc\Html\InputExtensions.cs">\r
+      <SubType>Code</SubType>\r
+    </Compile>\r
+    <Compile Include="Mvc\Html\RenderPartialExtensions.cs" />\r
+    <Compile Include="Mvc\Html\SelectExtensions.cs" />\r
+    <Compile Include="Mvc\Html\TextAreaExtensions.cs" />\r
+    <Compile Include="Mvc\Html\ValidationExtensions.cs" />\r
+    <Compile Include="Mvc\IModelBinder.cs" />\r
+    <Compile Include="Mvc\Html\LinkExtensions.cs" />\r
+    <Compile Include="Mvc\ModelBinderAttribute.cs" />\r
+    <Compile Include="Mvc\ModelBinders.cs" />\r
+    <Compile Include="Mvc\ModelStateDictionary.cs" />\r
+    <Compile Include="Mvc\ModelState.cs" />\r
+    <Compile Include="Mvc\ModelErrorCollection.cs" />\r
+    <Compile Include="Mvc\ModelError.cs" />\r
+    <Compile Include="Mvc\Ajax\InsertionMode.cs" />\r
+    <Compile Include="Mvc\HandleErrorAttribute.cs" />\r
+    <Compile Include="Mvc\HandleErrorInfo.cs" />\r
+    <Compile Include="Mvc\HttpUnauthorizedResult.cs" />\r
+    <Compile Include="Mvc\IActionInvoker.cs" />\r
+    <Compile Include="Mvc\IView.cs" />\r
+    <Compile Include="Mvc\IViewLocationCache.cs" />\r
+    <Compile Include="Mvc\MvcHttpHandler.cs" />\r
+    <Compile Include="Mvc\PartialViewResult.cs" />\r
+    <Compile Include="Mvc\SessionStateTempDataProvider.cs" />\r
+    <Compile Include="Mvc\ITempDataProvider.cs" />\r
+    <Compile Include="Mvc\OutputCacheAttribute.cs" />\r
+    <Compile Include="Mvc\FilterInfo.cs" />\r
+    <Compile Include="GlobalSuppressions.cs" />\r
+    <Compile Include="Mvc\ActionFilterAttribute.cs" />\r
+    <Compile Include="Mvc\ActionResult.cs" />\r
+    <Compile Include="Mvc\AjaxHelper.cs" />\r
+    <Compile Include="Mvc\BuildManagerWrapper.cs" />\r
+    <Compile Include="Mvc\Controller.cs" />\r
+    <Compile Include="Mvc\ControllerActionInvoker.cs" />\r
+    <Compile Include="Mvc\ControllerBuilder.cs" />\r
+    <Compile Include="Mvc\ControllerTypeCache.cs" />\r
+    <Compile Include="Mvc\ContentResult.cs" />\r
+    <Compile Include="Mvc\FilterAttribute.cs" />\r
+    <Compile Include="Mvc\IResultFilter.cs" />\r
+    <Compile Include="Mvc\IExceptionFilter.cs" />\r
+    <Compile Include="Mvc\IAuthorizationFilter.cs" />\r
+    <Compile Include="Mvc\JsonResult.cs" />\r
+    <Compile Include="Mvc\NameValueCollectionExtensions.cs" />\r
+    <Compile Include="Mvc\ViewDataDictionary`1.cs" />\r
+    <Compile Include="Mvc\EmptyResult.cs" />\r
+    <Compile Include="Mvc\MultiSelectList.cs" />\r
+    <Compile Include="Mvc\RedirectResult.cs" />\r
+    <Compile Include="Mvc\RedirectToRouteResult.cs" />\r
+    <Compile Include="Mvc\DefaultControllerFactory.cs" />\r
+    <Compile Include="Mvc\HtmlHelper.cs" />\r
+    <Compile Include="Mvc\IActionFilter.cs" />\r
+    <Compile Include="Mvc\IBuildManager.cs" />\r
+    <Compile Include="Mvc\IController.cs" />\r
+    <Compile Include="Mvc\IControllerFactory.cs" />\r
+    <Compile Include="Mvc\IViewDataContainer.cs" />\r
+    <Compile Include="Mvc\IViewEngine.cs" />\r
+    <Compile Include="Mvc\MvcHandler.cs" />\r
+    <Compile Include="Mvc\MvcRouteHandler.cs" />\r
+    <Compile Include="Mvc\NonActionAttribute.cs" />\r
+    <Compile Include="Mvc\RouteCollectionExtensions.cs" />\r
+    <Compile Include="Mvc\SelectList.cs" />\r
+    <Compile Include="Mvc\TempDataDictionary.cs" />\r
+    <Compile Include="Mvc\TypeHelpers.cs" />\r
+    <Compile Include="Mvc\UrlHelper.cs" />\r
+    <Compile Include="Mvc\ViewDataDictionary.cs" />\r
+    <Compile Include="Mvc\ViewEngineCollection.cs" />\r
+    <Compile Include="Mvc\ViewEngineResult.cs" />\r
+    <Compile Include="Mvc\ViewEngines.cs" />\r
+    <Compile Include="Mvc\ViewMasterPage.cs">\r
+      <SubType>ASPXCodeBehind</SubType>\r
+    </Compile>\r
+    <Compile Include="Mvc\ViewMasterPage`1.cs">\r
+      <SubType>ASPXCodeBehind</SubType>\r
+    </Compile>\r
+    <Compile Include="Mvc\ViewPage.cs">\r
+      <SubType>ASPXCodeBehind</SubType>\r
+    </Compile>\r
+    <Compile Include="Mvc\ViewPage`1.cs">\r
+      <SubType>ASPXCodeBehind</SubType>\r
+    </Compile>\r
+    <Compile Include="Mvc\ViewResult.cs" />\r
+    <Compile Include="Mvc\ViewResultBase.cs" />\r
+    <Compile Include="Mvc\ViewUserControl.cs">\r
+      <SubType>ASPXCodeBehind</SubType>\r
+    </Compile>\r
+    <Compile Include="Mvc\ViewUserControl`1.cs">\r
+      <SubType>ASPXCodeBehind</SubType>\r
+    </Compile>\r
+    <Compile Include="Mvc\VirtualPathProviderViewEngine.cs" />\r
+    <Compile Include="Mvc\WebFormView.cs" />\r
+    <Compile Include="Mvc\WebFormViewEngine.cs" />\r
+    <Compile Include="Properties\AssemblyInfo.cs" />\r
+    <Compile Include="Mvc\Resources\MvcResources.Designer.cs">\r
+      <AutoGen>True</AutoGen>\r
+      <DesignTime>True</DesignTime>\r
+      <DependentUpon>MvcResources.resx</DependentUpon>\r
+    </Compile>\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <EmbeddedResource Include="Mvc\Resources\MvcResources.resx">\r
+      <Generator>ResXFileCodeGenerator</Generator>\r
+      <LastGenOutput>MvcResources.Designer.cs</LastGenOutput>\r
+      <SubType>Designer</SubType>\r
+    </EmbeddedResource>\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <CodeAnalysisDictionary Include="..\CustomDictionary.xml" />\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <ProjectReference Include="..\..\..\webpages\src\System.Web.Razor\System.Web.Razor.csproj">\r
+      <Project>{8F18041B-9410-4C36-A9C5-067813DF5F31}</Project>\r
+      <Name>System.Web.Razor</Name>\r
+    </ProjectReference>\r
+    <ProjectReference Include="..\..\..\webpages\src\System.Web.WebPages.Razor\System.Web.WebPages.Razor.csproj">\r
+      <Project>{0939B11A-FE4E-4BA1-8AD6-D97741EE314F}</Project>\r
+      <Name>System.Web.WebPages.Razor</Name>\r
+    </ProjectReference>\r
+    <ProjectReference Include="..\..\..\webpages\src\System.Web.WebPages\System.Web.WebPages.csproj">\r
+      <Project>{76EFA9C5-8D7E-4FDF-B710-E20F8B6B00D2}</Project>\r
+      <Name>System.Web.WebPages</Name>\r
+    </ProjectReference>\r
+  </ItemGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+</Project>
\ No newline at end of file
diff --git a/mcs/class/System.Web.Mvc3/System.Web.Mvc3-net_4_5.csproj b/mcs/class/System.Web.Mvc3/System.Web.Mvc3-net_4_5.csproj
new file mode 100644 (file)
index 0000000..8ce7aac
--- /dev/null
@@ -0,0 +1,475 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <NoWarn>1699</NoWarn>\r
+    <OutputPath>./../../class/lib/net_4_5/tmp</OutputPath>\r
+    <NoStdLib>true</NoStdLib>\r
+    \r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <RootNamespace></RootNamespace>\r
+    <AssemblyName>System.Web.Mvc</AssemblyName>\r
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>\r
+    <FileAlignment>512</FileAlignment>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>false</Optimize>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;MONO</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>true</Optimize>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;MONO</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <ItemGroup>\r
+   <Compile Include=".\GlobalSuppressions.cs" />
+   <Compile Include=".\GlobalAssemblyInfo.cs" />
+   <Compile Include=".\Mvc\AcceptVerbsAttribute.cs" />
+   <Compile Include=".\Mvc\ActionDescriptor.cs" />
+   <Compile Include=".\Mvc\ActionExecutedContext.cs" />
+   <Compile Include=".\Mvc\ActionExecutingContext.cs" />
+   <Compile Include=".\Mvc\ActionFilterAttribute.cs" />
+   <Compile Include=".\Mvc\ActionMethodDispatcherCache.cs" />
+   <Compile Include=".\Mvc\ActionMethodDispatcher.cs" />
+   <Compile Include=".\Mvc\ActionMethodSelectorAttribute.cs" />
+   <Compile Include=".\Mvc\ActionMethodSelector.cs" />
+   <Compile Include=".\Mvc\ActionNameAttribute.cs" />
+   <Compile Include=".\Mvc\ActionNameSelectorAttribute.cs" />
+   <Compile Include=".\Mvc\ActionResult.cs" />
+   <Compile Include=".\Mvc\ActionSelector.cs" />
+   <Compile Include=".\Mvc\AdditionalMetaDataAttribute.cs" />
+   <Compile Include=".\Mvc\Ajax\AjaxExtensions.cs" />
+   <Compile Include=".\Mvc\Ajax\AjaxOptions.cs" />
+   <Compile Include=".\Mvc\AjaxHelper`1.cs" />
+   <Compile Include=".\Mvc\AjaxHelper.cs" />
+   <Compile Include=".\Mvc\Ajax\InsertionMode.cs" />
+   <Compile Include=".\Mvc\AjaxRequestExtensions.cs" />
+   <Compile Include=".\Mvc\AllowHtmlAttribute.cs" />
+   <Compile Include=".\Mvc\AreaHelpers.cs" />
+   <Compile Include=".\Mvc\AreaRegistrationContext.cs" />
+   <Compile Include=".\Mvc\AreaRegistration.cs" />
+   <Compile Include=".\Mvc\AssociatedMetadataProvider.cs" />
+   <Compile Include=".\Mvc\AssociatedValidatorProvider.cs" />
+   <Compile Include=".\Mvc\Async\ActionDescriptorCreator.cs" />
+   <Compile Include=".\Mvc\Async\AsyncActionDescriptor.cs" />
+   <Compile Include=".\Mvc\Async\AsyncActionMethodSelector.cs" />
+   <Compile Include=".\Mvc\Async\AsyncControllerActionInvoker.cs" />
+   <Compile Include=".\Mvc\Async\AsyncManager.cs" />
+   <Compile Include=".\Mvc\Async\AsyncResultWrapper.cs" />
+   <Compile Include=".\Mvc\Async\AsyncUtil.cs" />
+   <Compile Include=".\Mvc\Async\AsyncVoid.cs" />
+   <Compile Include=".\Mvc\Async\BeginInvokeDelegate.cs" />
+   <Compile Include=".\Mvc\AsyncController.cs" />
+   <Compile Include=".\Mvc\Async\EndInvokeDelegate`1.cs" />
+   <Compile Include=".\Mvc\Async\EndInvokeDelegate.cs" />
+   <Compile Include=".\Mvc\Async\IAsyncActionInvoker.cs" />
+   <Compile Include=".\Mvc\Async\IAsyncController.cs" />
+   <Compile Include=".\Mvc\Async\IAsyncManagerContainer.cs" />
+   <Compile Include=".\Mvc\Async\OperationCounter.cs" />
+   <Compile Include=".\Mvc\Async\ReflectedAsyncActionDescriptor.cs" />
+   <Compile Include=".\Mvc\Async\ReflectedAsyncControllerDescriptor.cs" />
+   <Compile Include=".\Mvc\Async\SimpleAsyncResult.cs" />
+   <Compile Include=".\Mvc\Async\SingleEntryGate.cs" />
+   <Compile Include=".\Mvc\Async\SynchronizationContextUtil.cs" />
+   <Compile Include=".\Mvc\Async\SynchronousOperationException.cs" />
+   <Compile Include=".\Mvc\AsyncTimeoutAttribute.cs" />
+   <Compile Include=".\Mvc\Async\Trigger.cs" />
+   <Compile Include=".\Mvc\Async\TriggerListener.cs" />
+   <Compile Include=".\Mvc\AuthorizationContext.cs" />
+   <Compile Include=".\Mvc\AuthorizeAttribute.cs" />
+   <Compile Include=".\Mvc\BindAttribute.cs" />
+   <Compile Include=".\Mvc\BuildManagerCompiledView.cs" />
+   <Compile Include=".\Mvc\BuildManagerViewEngine.cs" />
+   <Compile Include=".\Mvc\BuildManagerWrapper.cs" />
+   <Compile Include=".\Mvc\ByteArrayModelBinder.cs" />
+   <Compile Include=".\Mvc\ChildActionOnlyAttribute.cs" />
+   <Compile Include=".\Mvc\ChildActionValueProvider.cs" />
+   <Compile Include=".\Mvc\ChildActionValueProviderFactory.cs" />
+   <Compile Include=".\Mvc\ClientDataTypeModelValidatorProvider.cs" />
+   <Compile Include=".\Mvc\CompareAttribute.cs" />
+   <Compile Include=".\Mvc\ContentResult.cs" />
+   <Compile Include=".\Mvc\ControllerActionInvoker.cs" />
+   <Compile Include=".\Mvc\ControllerBase.cs" />
+   <Compile Include=".\Mvc\ControllerBuilder.cs" />
+   <Compile Include=".\Mvc\ControllerContext.cs" />
+   <Compile Include=".\Mvc\Controller.cs" />
+   <Compile Include=".\Mvc\ControllerDescriptorCache.cs" />
+   <Compile Include=".\Mvc\ControllerDescriptor.cs" />
+   <Compile Include=".\Mvc\ControllerInstanceFilterProvider.cs" />
+   <Compile Include=".\Mvc\ControllerTypeCache.cs" />
+   <Compile Include=".\Mvc\CustomModelBinderAttribute.cs" />
+   <Compile Include=".\Mvc\DataAnnotationsModelMetadata.cs" />
+   <Compile Include=".\Mvc\DataAnnotationsModelMetadataProvider.cs" />
+   <Compile Include=".\Mvc\DataAnnotationsModelValidator`1.cs" />
+   <Compile Include=".\Mvc\DataAnnotationsModelValidator.cs" />
+   <Compile Include=".\Mvc\DataAnnotationsModelValidatorProvider.cs" />
+   <Compile Include=".\Mvc\DataErrorInfoModelValidatorProvider.cs" />
+   <Compile Include=".\Mvc\DataTypeUtil.cs" />
+   <Compile Include=".\Mvc\DefaultControllerFactory.cs" />
+   <Compile Include=".\Mvc\DefaultModelBinder.cs" />
+   <Compile Include=".\Mvc\DefaultViewLocationCache.cs" />
+   <Compile Include=".\Mvc\DependencyResolver.cs" />
+   <Compile Include=".\Mvc\DependencyResolverExtensions.cs" />
+   <Compile Include=".\Mvc\DescriptorUtil.cs" />
+   <Compile Include=".\Mvc\DictionaryHelpers.cs" />
+   <Compile Include=".\Mvc\DictionaryValueProvider`1.cs" />
+   <Compile Include=".\Mvc\DynamicViewDataDictionary.cs" />
+   <Compile Include=".\Mvc\EmptyModelMetadataProvider.cs" />
+   <Compile Include=".\Mvc\EmptyModelValidatorProvider.cs" />
+   <Compile Include=".\Mvc\EmptyResult.cs" />
+   <Compile Include=".\Mvc\Error.cs" />
+   <Compile Include=".\Mvc\ExceptionContext.cs" />
+   <Compile Include=".\Mvc\ExpressionHelper.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\BinaryExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\CachedExpressionCompiler.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\ConditionalExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\ConstantExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\DefaultExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\ExpressionFingerprintChain.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\ExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\FingerprintingExpressionVisitor.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\HashCodeCombiner.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\Hoisted`2.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\HoistingExpressionVisitor.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\IndexExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\LambdaExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\MemberExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\MethodCallExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\ParameterExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\TypeBinaryExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\ExpressionUtil\UnaryExpressionFingerprint.cs" />
+   <Compile Include=".\Mvc\FieldValidationMetadata.cs" />
+   <Compile Include=".\Mvc\FileContentResult.cs" />
+   <Compile Include=".\Mvc\FilePathResult.cs" />
+   <Compile Include=".\Mvc\FileResult.cs" />
+   <Compile Include=".\Mvc\FileStreamResult.cs" />
+   <Compile Include=".\Mvc\FilterAttribute.cs" />
+   <Compile Include=".\Mvc\FilterAttributeFilterProvider.cs" />
+   <Compile Include=".\Mvc\Filter.cs" />
+   <Compile Include=".\Mvc\FilterInfo.cs" />
+   <Compile Include=".\Mvc\FilterProviderCollection.cs" />
+   <Compile Include=".\Mvc\FilterProviders.cs" />
+   <Compile Include=".\Mvc\FilterScope.cs" />
+   <Compile Include=".\Mvc\FormCollection.cs" />
+   <Compile Include=".\Mvc\FormContext.cs" />
+   <Compile Include=".\Mvc\FormMethod.cs" />
+   <Compile Include=".\Mvc\FormValueProvider.cs" />
+   <Compile Include=".\Mvc\FormValueProviderFactory.cs" />
+   <Compile Include=".\Mvc\GlobalFilterCollection.cs" />
+   <Compile Include=".\Mvc\GlobalFilters.cs" />
+   <Compile Include=".\Mvc\HandleErrorAttribute.cs" />
+   <Compile Include=".\Mvc\HandleErrorInfo.cs" />
+   <Compile Include=".\Mvc\HiddenInputAttribute.cs" />
+   <Compile Include=".\Mvc\Html\ChildActionExtensions.cs" />
+   <Compile Include=".\Mvc\Html\DefaultDisplayTemplates.cs" />
+   <Compile Include=".\Mvc\Html\DefaultEditorTemplates.cs" />
+   <Compile Include=".\Mvc\Html\DisplayExtensions.cs" />
+   <Compile Include=".\Mvc\Html\DisplayTextExtensions.cs" />
+   <Compile Include=".\Mvc\Html\EditorExtensions.cs" />
+   <Compile Include=".\Mvc\Html\FormExtensions.cs" />
+   <Compile Include=".\Mvc\HtmlHelper`1.cs" />
+   <Compile Include=".\Mvc\HtmlHelper.cs" />
+   <Compile Include=".\Mvc\Html\InputExtensions.cs" />
+   <Compile Include=".\Mvc\Html\LabelExtensions.cs" />
+   <Compile Include=".\Mvc\Html\LinkExtensions.cs" />
+   <Compile Include=".\Mvc\Html\MvcForm.cs" />
+   <Compile Include=".\Mvc\Html\PartialExtensions.cs" />
+   <Compile Include=".\Mvc\Html\RenderPartialExtensions.cs" />
+   <Compile Include=".\Mvc\Html\SelectExtensions.cs" />
+   <Compile Include=".\Mvc\Html\TemplateHelpers.cs" />
+   <Compile Include=".\Mvc\Html\TextAreaExtensions.cs" />
+   <Compile Include=".\Mvc\Html\ValidationExtensions.cs" />
+   <Compile Include=".\Mvc\HttpDeleteAttribute.cs" />
+   <Compile Include=".\Mvc\HttpFileCollectionValueProvider.cs" />
+   <Compile Include=".\Mvc\HttpFileCollectionValueProviderFactory.cs" />
+   <Compile Include=".\Mvc\HttpGetAttribute.cs" />
+   <Compile Include=".\Mvc\HttpHandlerUtil.cs" />
+   <Compile Include=".\Mvc\HttpNotFoundResult.cs" />
+   <Compile Include=".\Mvc\HttpPostAttribute.cs" />
+   <Compile Include=".\Mvc\HttpPostedFileBaseModelBinder.cs" />
+   <Compile Include=".\Mvc\HttpPutAttribute.cs" />
+   <Compile Include=".\Mvc\HttpRequestExtensions.cs" />
+   <Compile Include=".\Mvc\HttpStatusCodeResult.cs" />
+   <Compile Include=".\Mvc\HttpUnauthorizedResult.cs" />
+   <Compile Include=".\Mvc\HttpVerbs.cs" />
+   <Compile Include=".\Mvc\IActionFilter.cs" />
+   <Compile Include=".\Mvc\IActionInvoker.cs" />
+   <Compile Include=".\Mvc\IAuthorizationFilter.cs" />
+   <Compile Include=".\Mvc\IBuildManager.cs" />
+   <Compile Include=".\Mvc\IClientValidatable.cs" />
+   <Compile Include=".\Mvc\IControllerActivator.cs" />
+   <Compile Include=".\Mvc\IController.cs" />
+   <Compile Include=".\Mvc\IControllerFactory.cs" />
+   <Compile Include=".\Mvc\IDependencyResolver.cs" />
+   <Compile Include=".\Mvc\IExceptionFilter.cs" />
+   <Compile Include=".\Mvc\IFilterProvider.cs" />
+   <Compile Include=".\Mvc\IMetadataAware.cs" />
+   <Compile Include=".\Mvc\IModelBinder.cs" />
+   <Compile Include=".\Mvc\IModelBinderProvider.cs" />
+   <Compile Include=".\Mvc\IMvcControlBuilder.cs" />
+   <Compile Include=".\Mvc\IMvcFilter.cs" />
+   <Compile Include=".\Mvc\InputType.cs" />
+   <Compile Include=".\Mvc\IResolver.cs" />
+   <Compile Include=".\Mvc\IResultFilter.cs" />
+   <Compile Include=".\Mvc\IRouteWithArea.cs" />
+   <Compile Include=".\Mvc\ITempDataProvider.cs" />
+   <Compile Include=".\Mvc\IUniquelyIdentifiable.cs" />
+   <Compile Include=".\Mvc\IUnvalidatedRequestValues.cs" />
+   <Compile Include=".\Mvc\IUnvalidatedValueProvider.cs" />
+   <Compile Include=".\Mvc\IValueProvider.cs" />
+   <Compile Include=".\Mvc\IView.cs" />
+   <Compile Include=".\Mvc\IViewDataContainer.cs" />
+   <Compile Include=".\Mvc\IViewEngine.cs" />
+   <Compile Include=".\Mvc\IViewLocationCache.cs" />
+   <Compile Include=".\Mvc\IViewPageActivator.cs" />
+   <Compile Include=".\Mvc\IViewStartPageChild.cs" />
+   <Compile Include=".\Mvc\JavaScriptResult.cs" />
+   <Compile Include=".\Mvc\JsonRequestBehavior.cs" />
+   <Compile Include=".\Mvc\JsonResult.cs" />
+   <Compile Include=".\Mvc\JsonValueProviderFactory.cs" />
+   <Compile Include=".\Mvc\LinqBinaryModelBinder.cs" />
+   <Compile Include=".\Mvc\ModelBinderAttribute.cs" />
+   <Compile Include=".\Mvc\ModelBinderDictionary.cs" />
+   <Compile Include=".\Mvc\ModelBinderProviderCollection.cs" />
+   <Compile Include=".\Mvc\ModelBinderProviders.cs" />
+   <Compile Include=".\Mvc\ModelBinders.cs" />
+   <Compile Include=".\Mvc\ModelBindingContext.cs" />
+   <Compile Include=".\Mvc\ModelClientValidationEqualToRule.cs" />
+   <Compile Include=".\Mvc\ModelClientValidationRangeRule.cs" />
+   <Compile Include=".\Mvc\ModelClientValidationRegexRule.cs" />
+   <Compile Include=".\Mvc\ModelClientValidationRemoteRule.cs" />
+   <Compile Include=".\Mvc\ModelClientValidationRequiredRule.cs" />
+   <Compile Include=".\Mvc\ModelClientValidationRule.cs" />
+   <Compile Include=".\Mvc\ModelClientValidationStringLengthRule.cs" />
+   <Compile Include=".\Mvc\ModelErrorCollection.cs" />
+   <Compile Include=".\Mvc\ModelError.cs" />
+   <Compile Include=".\Mvc\ModelMetadata.cs" />
+   <Compile Include=".\Mvc\ModelMetadataProvider.cs" />
+   <Compile Include=".\Mvc\ModelMetadataProviders.cs" />
+   <Compile Include=".\Mvc\ModelState.cs" />
+   <Compile Include=".\Mvc\ModelStateDictionary.cs" />
+   <Compile Include=".\Mvc\ModelValidationResult.cs" />
+   <Compile Include=".\Mvc\ModelValidator.cs" />
+   <Compile Include=".\Mvc\ModelValidatorProviderCollection.cs" />
+   <Compile Include=".\Mvc\ModelValidatorProvider.cs" />
+   <Compile Include=".\Mvc\ModelValidatorProviders.cs" />
+   <Compile Include=".\Mvc\MultiSelectList.cs" />
+   <Compile Include=".\Mvc\MultiServiceResolver.cs" />
+   <Compile Include=".\Mvc\MvcFilter.cs" />
+   <Compile Include=".\Mvc\MvcHandler.cs" />
+   <Compile Include=".\Mvc\MvcHtmlString.cs" />
+   <Compile Include=".\Mvc\MvcHttpHandler.cs" />
+   <Compile Include=".\Mvc\MvcRouteHandler.cs" />
+   <Compile Include=".\Mvc\MvcWebRazorHostFactory.cs" />
+   <Compile Include=".\Mvc\NameValueCollectionExtensions.cs" />
+   <Compile Include=".\Mvc\NameValueCollectionValueProvider.cs" />
+   <Compile Include=".\Mvc\NoAsyncTimeoutAttribute.cs" />
+   <Compile Include=".\Mvc\NonActionAttribute.cs" />
+   <Compile Include=".\Mvc\NullViewLocationCache.cs" />
+   <Compile Include=".\Mvc\OutputCacheAttribute.cs" />
+   <Compile Include=".\Mvc\ParameterBindingInfo.cs" />
+   <Compile Include=".\Mvc\ParameterDescriptor.cs" />
+   <Compile Include=".\Mvc\ParameterInfoUtil.cs" />
+   <Compile Include=".\Mvc\PartialViewResult.cs" />
+   <Compile Include=".\Mvc\PathHelpers.cs" />
+   <Compile Include=".\Mvc\PreApplicationStartCode.cs" />
+   <Compile Include=".\Mvc\QueryStringValueProvider.cs" />
+   <Compile Include=".\Mvc\QueryStringValueProviderFactory.cs" />
+   <Compile Include=".\Mvc\RangeAttributeAdapter.cs" />
+   <Compile Include=".\Mvc\Razor\MvcCSharpRazorCodeGenerator.cs" />
+   <Compile Include=".\Mvc\Razor\MvcCSharpRazorCodeParser.cs" />
+   <Compile Include=".\Mvc\Razor\MvcVBRazorCodeParser.cs" />
+   <Compile Include=".\Mvc\Razor\MvcWebPageRazorHost.cs" />
+   <Compile Include=".\Mvc\Razor\SetModelTypeCodeGenerator.cs" />
+   <Compile Include=".\Mvc\Razor\StartPageLookupDelegate.cs" />
+   <Compile Include=".\Mvc\RazorView.cs" />
+   <Compile Include=".\Mvc\RazorViewEngine.cs" />
+   <Compile Include=".\Mvc\ReaderWriterCache`2.cs" />
+   <Compile Include=".\Mvc\RedirectResult.cs" />
+   <Compile Include=".\Mvc\RedirectToRouteResult.cs" />
+   <Compile Include=".\Mvc\ReflectedActionDescriptor.cs" />
+   <Compile Include=".\Mvc\ReflectedAttributeCache.cs" />
+   <Compile Include=".\Mvc\ReflectedControllerDescriptor.cs" />
+   <Compile Include=".\Mvc\ReflectedParameterBindingInfo.cs" />
+   <Compile Include=".\Mvc\ReflectedParameterDescriptor.cs" />
+   <Compile Include=".\Mvc\RegularExpressionAttributeAdapter.cs" />
+   <Compile Include=".\Mvc\RemoteAttribute.cs" />
+   <Compile Include=".\Mvc\RequiredAttributeAdapter.cs" />
+   <Compile Include=".\Mvc\RequireHttpsAttribute.cs" />
+   <Compile Include=".\Mvc\Resources\MvcResources.Designer.cs" />
+   <Compile Include=".\Mvc\ResultExecutedContext.cs" />
+   <Compile Include=".\Mvc\ResultExecutingContext.cs" />
+   <Compile Include=".\Mvc\RouteCollectionExtensions.cs" />
+   <Compile Include=".\Mvc\RouteDataValueProvider.cs" />
+   <Compile Include=".\Mvc\RouteDataValueProviderFactory.cs" />
+   <Compile Include=".\Mvc\RouteValuesHelpers.cs" />
+   <Compile Include=".\Mvc\SecurityUtil.cs" />
+   <Compile Include=".\Mvc\SelectList.cs" />
+   <Compile Include=".\Mvc\SelectListItem.cs" />
+   <Compile Include=".\Mvc\SessionStateAttribute.cs" />
+   <Compile Include=".\Mvc\SessionStateTempDataProvider.cs" />
+   <Compile Include=".\Mvc\SingleServiceResolver.cs" />
+   <Compile Include=".\Mvc\StringLengthAttributeAdapter.cs" />
+   <Compile Include=".\Mvc\TagBuilderExtensions.cs" />
+   <Compile Include=".\Mvc\TempDataDictionary.cs" />
+   <Compile Include=".\Mvc\TemplateInfo.cs" />
+   <Compile Include=".\Mvc\TryGetValueDelegate.cs" />
+   <Compile Include=".\Mvc\TypeCacheSerializer.cs" />
+   <Compile Include=".\Mvc\TypeCacheUtil.cs" />
+   <Compile Include=".\Mvc\TypeDescriptorHelper.cs" />
+   <Compile Include=".\Mvc\TypeHelpers.cs" />
+   <Compile Include=".\Mvc\UnvalidatedRequestValuesAccessor.cs" />
+   <Compile Include=".\Mvc\UnvalidatedRequestValuesWrapper.cs" />
+   <Compile Include=".\Mvc\UrlHelper.cs" />
+   <Compile Include=".\Mvc\UrlParameter.cs" />
+   <Compile Include=".\Mvc\UrlRewriterHelper.cs" />
+   <Compile Include=".\Mvc\ValidatableObjectAdapter.cs" />
+   <Compile Include=".\Mvc\ValidateAntiForgeryTokenAttribute.cs" />
+   <Compile Include=".\Mvc\ValidateInputAttribute.cs" />
+   <Compile Include=".\Mvc\ValueProviderCollection.cs" />
+   <Compile Include=".\Mvc\ValueProviderDictionary.cs" />
+   <Compile Include=".\Mvc\ValueProviderFactories.cs" />
+   <Compile Include=".\Mvc\ValueProviderFactoryCollection.cs" />
+   <Compile Include=".\Mvc\ValueProviderFactory.cs" />
+   <Compile Include=".\Mvc\ValueProviderResult.cs" />
+   <Compile Include=".\Mvc\ValueProviderUtil.cs" />
+   <Compile Include=".\Mvc\ViewContext.cs" />
+   <Compile Include=".\Mvc\ViewDataDictionary`1.cs" />
+   <Compile Include=".\Mvc\ViewDataDictionary.cs" />
+   <Compile Include=".\Mvc\ViewDataInfo.cs" />
+   <Compile Include=".\Mvc\ViewEngineCollection.cs" />
+   <Compile Include=".\Mvc\ViewEngineResult.cs" />
+   <Compile Include=".\Mvc\ViewEngines.cs" />
+   <Compile Include=".\Mvc\ViewMasterPage`1.cs" />
+   <Compile Include=".\Mvc\ViewMasterPageControlBuilder.cs" />
+   <Compile Include=".\Mvc\ViewMasterPage.cs" />
+   <Compile Include=".\Mvc\ViewPage`1.cs" />
+   <Compile Include=".\Mvc\ViewPageControlBuilder.cs" />
+   <Compile Include=".\Mvc\ViewPage.cs" />
+   <Compile Include=".\Mvc\ViewResultBase.cs" />
+   <Compile Include=".\Mvc\ViewResult.cs" />
+   <Compile Include=".\Mvc\ViewStartPage.cs" />
+   <Compile Include=".\Mvc\ViewTemplateUserControl`1.cs" />
+   <Compile Include=".\Mvc\ViewTemplateUserControl.cs" />
+   <Compile Include=".\Mvc\ViewTypeControlBuilder.cs" />
+   <Compile Include=".\Mvc\ViewType.cs" />
+   <Compile Include=".\Mvc\ViewTypeParserFilter.cs" />
+   <Compile Include=".\Mvc\ViewUserControl`1.cs" />
+   <Compile Include=".\Mvc\ViewUserControlControlBuilder.cs" />
+   <Compile Include=".\Mvc\ViewUserControl.cs" />
+   <Compile Include=".\Mvc\VirtualPathProviderViewEngine.cs" />
+   <Compile Include=".\Mvc\WebFormView.cs" />
+   <Compile Include=".\Mvc\WebFormViewEngine.cs" />
+   <Compile Include=".\Mvc\WebViewPage`1.cs" />
+   <Compile Include=".\Mvc\WebViewPage.cs" />
+   <Compile Include=".\Properties\AssemblyInfo.cs" />
+\r
+  </ItemGroup>\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+  <PropertyGroup>\r
+    <PreBuildEvent></PreBuildEvent>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="mscorlib.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>mscorlib.dll</HintPath>
+    </Reference>
+    <Reference Include="Microsoft.Web.Infrastructure.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>Microsoft.Web.Infrastructure.dll</HintPath>
+    </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Configuration.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Configuration.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Data.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Data.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.Abstractions.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.Abstractions.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.Routing.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.Routing.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.Extensions.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.Extensions.dll</HintPath>
+    </Reference>
+    <Reference Include="System.ComponentModel.DataAnnotations.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.ComponentModel.DataAnnotations.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Data.Linq.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Data.Linq.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Runtime.Caching.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Runtime.Caching.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.Razor.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.Razor.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.WebPages.Razor.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.WebPages.Razor.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.WebPages.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.WebPages.dll</HintPath>
+    </Reference>
+\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Folder Include="Properties\" />\r
+  </ItemGroup>\r
+    <ItemGroup>
+    <EmbeddedResource Include="Mvc/Resources/MvcResources.resources">
+       <LogicalName>System.Web.Mvc.Resources.MvcResources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
+</Project>\r
+
diff --git a/mcs/class/System.Web.Mvc3/System.Web.Mvc3.dll.sources b/mcs/class/System.Web.Mvc3/System.Web.Mvc3.dll.sources
new file mode 100644 (file)
index 0000000..d65c2ff
--- /dev/null
@@ -0,0 +1,341 @@
+./GlobalSuppressions.cs
+./GlobalAssemblyInfo.cs
+./Mvc/AcceptVerbsAttribute.cs
+./Mvc/ActionDescriptor.cs
+./Mvc/ActionExecutedContext.cs
+./Mvc/ActionExecutingContext.cs
+./Mvc/ActionFilterAttribute.cs
+./Mvc/ActionMethodDispatcherCache.cs
+./Mvc/ActionMethodDispatcher.cs
+./Mvc/ActionMethodSelectorAttribute.cs
+./Mvc/ActionMethodSelector.cs
+./Mvc/ActionNameAttribute.cs
+./Mvc/ActionNameSelectorAttribute.cs
+./Mvc/ActionResult.cs
+./Mvc/ActionSelector.cs
+./Mvc/AdditionalMetaDataAttribute.cs
+./Mvc/Ajax/AjaxExtensions.cs
+./Mvc/Ajax/AjaxOptions.cs
+./Mvc/AjaxHelper`1.cs
+./Mvc/AjaxHelper.cs
+./Mvc/Ajax/InsertionMode.cs
+./Mvc/AjaxRequestExtensions.cs
+./Mvc/AllowHtmlAttribute.cs
+./Mvc/AreaHelpers.cs
+./Mvc/AreaRegistrationContext.cs
+./Mvc/AreaRegistration.cs
+./Mvc/AssociatedMetadataProvider.cs
+./Mvc/AssociatedValidatorProvider.cs
+./Mvc/Async/ActionDescriptorCreator.cs
+./Mvc/Async/AsyncActionDescriptor.cs
+./Mvc/Async/AsyncActionMethodSelector.cs
+./Mvc/Async/AsyncControllerActionInvoker.cs
+./Mvc/Async/AsyncManager.cs
+./Mvc/Async/AsyncResultWrapper.cs
+./Mvc/Async/AsyncUtil.cs
+./Mvc/Async/AsyncVoid.cs
+./Mvc/Async/BeginInvokeDelegate.cs
+./Mvc/AsyncController.cs
+./Mvc/Async/EndInvokeDelegate`1.cs
+./Mvc/Async/EndInvokeDelegate.cs
+./Mvc/Async/IAsyncActionInvoker.cs
+./Mvc/Async/IAsyncController.cs
+./Mvc/Async/IAsyncManagerContainer.cs
+./Mvc/Async/OperationCounter.cs
+./Mvc/Async/ReflectedAsyncActionDescriptor.cs
+./Mvc/Async/ReflectedAsyncControllerDescriptor.cs
+./Mvc/Async/SimpleAsyncResult.cs
+./Mvc/Async/SingleEntryGate.cs
+./Mvc/Async/SynchronizationContextUtil.cs
+./Mvc/Async/SynchronousOperationException.cs
+./Mvc/AsyncTimeoutAttribute.cs
+./Mvc/Async/Trigger.cs
+./Mvc/Async/TriggerListener.cs
+./Mvc/AuthorizationContext.cs
+./Mvc/AuthorizeAttribute.cs
+./Mvc/BindAttribute.cs
+./Mvc/BuildManagerCompiledView.cs
+./Mvc/BuildManagerViewEngine.cs
+./Mvc/BuildManagerWrapper.cs
+./Mvc/ByteArrayModelBinder.cs
+./Mvc/ChildActionOnlyAttribute.cs
+./Mvc/ChildActionValueProvider.cs
+./Mvc/ChildActionValueProviderFactory.cs
+./Mvc/ClientDataTypeModelValidatorProvider.cs
+./Mvc/CompareAttribute.cs
+./Mvc/ContentResult.cs
+./Mvc/ControllerActionInvoker.cs
+./Mvc/ControllerBase.cs
+./Mvc/ControllerBuilder.cs
+./Mvc/ControllerContext.cs
+./Mvc/Controller.cs
+./Mvc/ControllerDescriptorCache.cs
+./Mvc/ControllerDescriptor.cs
+./Mvc/ControllerInstanceFilterProvider.cs
+./Mvc/ControllerTypeCache.cs
+./Mvc/CustomModelBinderAttribute.cs
+./Mvc/DataAnnotationsModelMetadata.cs
+./Mvc/DataAnnotationsModelMetadataProvider.cs
+./Mvc/DataAnnotationsModelValidator`1.cs
+./Mvc/DataAnnotationsModelValidator.cs
+./Mvc/DataAnnotationsModelValidatorProvider.cs
+./Mvc/DataErrorInfoModelValidatorProvider.cs
+./Mvc/DataTypeUtil.cs
+./Mvc/DefaultControllerFactory.cs
+./Mvc/DefaultModelBinder.cs
+./Mvc/DefaultViewLocationCache.cs
+./Mvc/DependencyResolver.cs
+./Mvc/DependencyResolverExtensions.cs
+./Mvc/DescriptorUtil.cs
+./Mvc/DictionaryHelpers.cs
+./Mvc/DictionaryValueProvider`1.cs
+./Mvc/DynamicViewDataDictionary.cs
+./Mvc/EmptyModelMetadataProvider.cs
+./Mvc/EmptyModelValidatorProvider.cs
+./Mvc/EmptyResult.cs
+./Mvc/Error.cs
+./Mvc/ExceptionContext.cs
+./Mvc/ExpressionHelper.cs
+./Mvc/ExpressionUtil/BinaryExpressionFingerprint.cs
+./Mvc/ExpressionUtil/CachedExpressionCompiler.cs
+./Mvc/ExpressionUtil/ConditionalExpressionFingerprint.cs
+./Mvc/ExpressionUtil/ConstantExpressionFingerprint.cs
+./Mvc/ExpressionUtil/DefaultExpressionFingerprint.cs
+./Mvc/ExpressionUtil/ExpressionFingerprintChain.cs
+./Mvc/ExpressionUtil/ExpressionFingerprint.cs
+./Mvc/ExpressionUtil/FingerprintingExpressionVisitor.cs
+./Mvc/ExpressionUtil/HashCodeCombiner.cs
+./Mvc/ExpressionUtil/Hoisted`2.cs
+./Mvc/ExpressionUtil/HoistingExpressionVisitor.cs
+./Mvc/ExpressionUtil/IndexExpressionFingerprint.cs
+./Mvc/ExpressionUtil/LambdaExpressionFingerprint.cs
+./Mvc/ExpressionUtil/MemberExpressionFingerprint.cs
+./Mvc/ExpressionUtil/MethodCallExpressionFingerprint.cs
+./Mvc/ExpressionUtil/ParameterExpressionFingerprint.cs
+./Mvc/ExpressionUtil/TypeBinaryExpressionFingerprint.cs
+./Mvc/ExpressionUtil/UnaryExpressionFingerprint.cs
+./Mvc/FieldValidationMetadata.cs
+./Mvc/FileContentResult.cs
+./Mvc/FilePathResult.cs
+./Mvc/FileResult.cs
+./Mvc/FileStreamResult.cs
+./Mvc/FilterAttribute.cs
+./Mvc/FilterAttributeFilterProvider.cs
+./Mvc/Filter.cs
+./Mvc/FilterInfo.cs
+./Mvc/FilterProviderCollection.cs
+./Mvc/FilterProviders.cs
+./Mvc/FilterScope.cs
+./Mvc/FormCollection.cs
+./Mvc/FormContext.cs
+./Mvc/FormMethod.cs
+./Mvc/FormValueProvider.cs
+./Mvc/FormValueProviderFactory.cs
+./Mvc/GlobalFilterCollection.cs
+./Mvc/GlobalFilters.cs
+./Mvc/HandleErrorAttribute.cs
+./Mvc/HandleErrorInfo.cs
+./Mvc/HiddenInputAttribute.cs
+./Mvc/Html/ChildActionExtensions.cs
+./Mvc/Html/DefaultDisplayTemplates.cs
+./Mvc/Html/DefaultEditorTemplates.cs
+./Mvc/Html/DisplayExtensions.cs
+./Mvc/Html/DisplayTextExtensions.cs
+./Mvc/Html/EditorExtensions.cs
+./Mvc/Html/FormExtensions.cs
+./Mvc/HtmlHelper`1.cs
+./Mvc/HtmlHelper.cs
+./Mvc/Html/InputExtensions.cs
+./Mvc/Html/LabelExtensions.cs
+./Mvc/Html/LinkExtensions.cs
+./Mvc/Html/MvcForm.cs
+./Mvc/Html/PartialExtensions.cs
+./Mvc/Html/RenderPartialExtensions.cs
+./Mvc/Html/SelectExtensions.cs
+./Mvc/Html/TemplateHelpers.cs
+./Mvc/Html/TextAreaExtensions.cs
+./Mvc/Html/ValidationExtensions.cs
+./Mvc/HttpDeleteAttribute.cs
+./Mvc/HttpFileCollectionValueProvider.cs
+./Mvc/HttpFileCollectionValueProviderFactory.cs
+./Mvc/HttpGetAttribute.cs
+./Mvc/HttpHandlerUtil.cs
+./Mvc/HttpNotFoundResult.cs
+./Mvc/HttpPostAttribute.cs
+./Mvc/HttpPostedFileBaseModelBinder.cs
+./Mvc/HttpPutAttribute.cs
+./Mvc/HttpRequestExtensions.cs
+./Mvc/HttpStatusCodeResult.cs
+./Mvc/HttpUnauthorizedResult.cs
+./Mvc/HttpVerbs.cs
+./Mvc/IActionFilter.cs
+./Mvc/IActionInvoker.cs
+./Mvc/IAuthorizationFilter.cs
+./Mvc/IBuildManager.cs
+./Mvc/IClientValidatable.cs
+./Mvc/IControllerActivator.cs
+./Mvc/IController.cs
+./Mvc/IControllerFactory.cs
+./Mvc/IDependencyResolver.cs
+./Mvc/IExceptionFilter.cs
+./Mvc/IFilterProvider.cs
+./Mvc/IMetadataAware.cs
+./Mvc/IModelBinder.cs
+./Mvc/IModelBinderProvider.cs
+./Mvc/IMvcControlBuilder.cs
+./Mvc/IMvcFilter.cs
+./Mvc/InputType.cs
+./Mvc/IResolver.cs
+./Mvc/IResultFilter.cs
+./Mvc/IRouteWithArea.cs
+./Mvc/ITempDataProvider.cs
+./Mvc/IUniquelyIdentifiable.cs
+./Mvc/IUnvalidatedRequestValues.cs
+./Mvc/IUnvalidatedValueProvider.cs
+./Mvc/IValueProvider.cs
+./Mvc/IView.cs
+./Mvc/IViewDataContainer.cs
+./Mvc/IViewEngine.cs
+./Mvc/IViewLocationCache.cs
+./Mvc/IViewPageActivator.cs
+./Mvc/IViewStartPageChild.cs
+./Mvc/JavaScriptResult.cs
+./Mvc/JsonRequestBehavior.cs
+./Mvc/JsonResult.cs
+./Mvc/JsonValueProviderFactory.cs
+./Mvc/LinqBinaryModelBinder.cs
+./Mvc/ModelBinderAttribute.cs
+./Mvc/ModelBinderDictionary.cs
+./Mvc/ModelBinderProviderCollection.cs
+./Mvc/ModelBinderProviders.cs
+./Mvc/ModelBinders.cs
+./Mvc/ModelBindingContext.cs
+./Mvc/ModelClientValidationEqualToRule.cs
+./Mvc/ModelClientValidationRangeRule.cs
+./Mvc/ModelClientValidationRegexRule.cs
+./Mvc/ModelClientValidationRemoteRule.cs
+./Mvc/ModelClientValidationRequiredRule.cs
+./Mvc/ModelClientValidationRule.cs
+./Mvc/ModelClientValidationStringLengthRule.cs
+./Mvc/ModelErrorCollection.cs
+./Mvc/ModelError.cs
+./Mvc/ModelMetadata.cs
+./Mvc/ModelMetadataProvider.cs
+./Mvc/ModelMetadataProviders.cs
+./Mvc/ModelState.cs
+./Mvc/ModelStateDictionary.cs
+./Mvc/ModelValidationResult.cs
+./Mvc/ModelValidator.cs
+./Mvc/ModelValidatorProviderCollection.cs
+./Mvc/ModelValidatorProvider.cs
+./Mvc/ModelValidatorProviders.cs
+./Mvc/MultiSelectList.cs
+./Mvc/MultiServiceResolver.cs
+./Mvc/MvcFilter.cs
+./Mvc/MvcHandler.cs
+./Mvc/MvcHtmlString.cs
+./Mvc/MvcHttpHandler.cs
+./Mvc/MvcRouteHandler.cs
+./Mvc/MvcWebRazorHostFactory.cs
+./Mvc/NameValueCollectionExtensions.cs
+./Mvc/NameValueCollectionValueProvider.cs
+./Mvc/NoAsyncTimeoutAttribute.cs
+./Mvc/NonActionAttribute.cs
+./Mvc/NullViewLocationCache.cs
+./Mvc/OutputCacheAttribute.cs
+./Mvc/ParameterBindingInfo.cs
+./Mvc/ParameterDescriptor.cs
+./Mvc/ParameterInfoUtil.cs
+./Mvc/PartialViewResult.cs
+./Mvc/PathHelpers.cs
+./Mvc/PreApplicationStartCode.cs
+./Mvc/QueryStringValueProvider.cs
+./Mvc/QueryStringValueProviderFactory.cs
+./Mvc/RangeAttributeAdapter.cs
+./Mvc/Razor/MvcCSharpRazorCodeGenerator.cs
+./Mvc/Razor/MvcCSharpRazorCodeParser.cs
+./Mvc/Razor/MvcVBRazorCodeParser.cs
+./Mvc/Razor/MvcWebPageRazorHost.cs
+./Mvc/Razor/SetModelTypeCodeGenerator.cs
+./Mvc/Razor/StartPageLookupDelegate.cs
+./Mvc/RazorView.cs
+./Mvc/RazorViewEngine.cs
+./Mvc/ReaderWriterCache`2.cs
+./Mvc/RedirectResult.cs
+./Mvc/RedirectToRouteResult.cs
+./Mvc/ReflectedActionDescriptor.cs
+./Mvc/ReflectedAttributeCache.cs
+./Mvc/ReflectedControllerDescriptor.cs
+./Mvc/ReflectedParameterBindingInfo.cs
+./Mvc/ReflectedParameterDescriptor.cs
+./Mvc/RegularExpressionAttributeAdapter.cs
+./Mvc/RemoteAttribute.cs
+./Mvc/RequiredAttributeAdapter.cs
+./Mvc/RequireHttpsAttribute.cs
+./Mvc/Resources/MvcResources.Designer.cs
+./Mvc/ResultExecutedContext.cs
+./Mvc/ResultExecutingContext.cs
+./Mvc/RouteCollectionExtensions.cs
+./Mvc/RouteDataValueProvider.cs
+./Mvc/RouteDataValueProviderFactory.cs
+./Mvc/RouteValuesHelpers.cs
+./Mvc/SecurityUtil.cs
+./Mvc/SelectList.cs
+./Mvc/SelectListItem.cs
+./Mvc/SessionStateAttribute.cs
+./Mvc/SessionStateTempDataProvider.cs
+./Mvc/SingleServiceResolver.cs
+./Mvc/StringLengthAttributeAdapter.cs
+./Mvc/TagBuilderExtensions.cs
+./Mvc/TempDataDictionary.cs
+./Mvc/TemplateInfo.cs
+./Mvc/TryGetValueDelegate.cs
+./Mvc/TypeCacheSerializer.cs
+./Mvc/TypeCacheUtil.cs
+./Mvc/TypeDescriptorHelper.cs
+./Mvc/TypeHelpers.cs
+./Mvc/UnvalidatedRequestValuesAccessor.cs
+./Mvc/UnvalidatedRequestValuesWrapper.cs
+./Mvc/UrlHelper.cs
+./Mvc/UrlParameter.cs
+./Mvc/UrlRewriterHelper.cs
+./Mvc/ValidatableObjectAdapter.cs
+./Mvc/ValidateAntiForgeryTokenAttribute.cs
+./Mvc/ValidateInputAttribute.cs
+./Mvc/ValueProviderCollection.cs
+./Mvc/ValueProviderDictionary.cs
+./Mvc/ValueProviderFactories.cs
+./Mvc/ValueProviderFactoryCollection.cs
+./Mvc/ValueProviderFactory.cs
+./Mvc/ValueProviderResult.cs
+./Mvc/ValueProviderUtil.cs
+./Mvc/ViewContext.cs
+./Mvc/ViewDataDictionary`1.cs
+./Mvc/ViewDataDictionary.cs
+./Mvc/ViewDataInfo.cs
+./Mvc/ViewEngineCollection.cs
+./Mvc/ViewEngineResult.cs
+./Mvc/ViewEngines.cs
+./Mvc/ViewMasterPage`1.cs
+./Mvc/ViewMasterPageControlBuilder.cs
+./Mvc/ViewMasterPage.cs
+./Mvc/ViewPage`1.cs
+./Mvc/ViewPageControlBuilder.cs
+./Mvc/ViewPage.cs
+./Mvc/ViewResultBase.cs
+./Mvc/ViewResult.cs
+./Mvc/ViewStartPage.cs
+./Mvc/ViewTemplateUserControl`1.cs
+./Mvc/ViewTemplateUserControl.cs
+./Mvc/ViewTypeControlBuilder.cs
+./Mvc/ViewType.cs
+./Mvc/ViewTypeParserFilter.cs
+./Mvc/ViewUserControl`1.cs
+./Mvc/ViewUserControlControlBuilder.cs
+./Mvc/ViewUserControl.cs
+./Mvc/VirtualPathProviderViewEngine.cs
+./Mvc/WebFormView.cs
+./Mvc/WebFormViewEngine.cs
+./Mvc/WebViewPage`1.cs
+./Mvc/WebViewPage.cs
+./Properties/AssemblyInfo.cs
diff --git a/mcs/class/System.Web.Razor/Assembly/AssemblyInfo.cs b/mcs/class/System.Web.Razor/Assembly/AssemblyInfo.cs
new file mode 100644 (file)
index 0000000..bce0eb0
--- /dev/null
@@ -0,0 +1,41 @@
+//
+// AssemblyInfo.cs
+//
+// Authors:
+//     Marek Safar (marek.safar@gmail.com)
+//
+// Copyright (C) 2007 Novell, Inc (http://www.novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+using System.Reflection;
+using System.Resources;
+using System.Security;
+using System.Security.Permissions;
+using System.Diagnostics;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+[assembly: AssemblyDefaultAlias ("System.Web.Razor.dll")]
+
+[assembly: AssemblyInformationalVersion (Consts.FxFileVersion)]
+
diff --git a/mcs/class/System.Web.Razor/Makefile b/mcs/class/System.Web.Razor/Makefile
new file mode 100644 (file)
index 0000000..9597322
--- /dev/null
@@ -0,0 +1,26 @@
+thisdir = class/System.Web.Razor
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Web.Razor.dll
+LIBRARY_NAME = System.Web.Razor.dll
+
+System.Web.Razor.Common.CommonResources.resources: ../../../external/aspnetwebstack/src/CommonResources.resx
+       $(RESGEN) "$<" "$@"
+       
+System.Web.Razor.Resources.RazorResources.resources: ../../../external/aspnetwebstack/src/System.Web.Razor/Resources/RazorResources.resx
+       $(RESGEN) "$<" "$@"
+
+LIB_MCS_FLAGS = \
+               /warn:1 \
+               /keyfile:../winfx.pub -delaysign \
+               /r:System.dll \
+               /r:System.Core.dll \
+               /d:ASPNETWEBPAGES \
+               /resource:System.Web.Razor.Resources.RazorResources.resources \
+               /resource:System.Web.Razor.Common.CommonResources.resources
+
+include ../../build/library.make
+
+$(build_lib): System.Web.Razor.Resources.RazorResources.resources \
+               System.Web.Razor.Common.CommonResources.resources
diff --git a/mcs/class/System.Web.Razor/System.Web.Razor-net_4_5.csproj b/mcs/class/System.Web.Razor/System.Web.Razor-net_4_5.csproj
new file mode 100644 (file)
index 0000000..27d686e
--- /dev/null
@@ -0,0 +1,231 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <NoWarn>1699</NoWarn>\r
+    <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
+    <NoStdLib>true</NoStdLib>\r
+    \r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <RootNamespace></RootNamespace>\r
+    <AssemblyName>System.Web.Razor</AssemblyName>\r
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>\r
+    <FileAlignment>512</FileAlignment>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>false</Optimize>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETWEBPAGES</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>true</Optimize>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETWEBPAGES</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <ItemGroup>\r
+   <Compile Include="..\..\build\common\Consts.cs" />
+   <Compile Include="Assembly\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\ExceptionHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\HashCodeCombiner.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\TransparentCommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\CSharpRazorCodeLanguage.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\DocumentParseCompleteEventArgs.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Editor\AutoCompleteEditHandler.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Editor\BackgroundParseTask.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Editor\EditorHints.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Editor\EditResult.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Editor\ImplicitExpressionEditHandler.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Editor\SingleLineMarkupEditHandler.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Editor\SpanEditHandler.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\AddImportCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\AttributeBlockCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\BaseCodeWriter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\BlockCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\CodeGenerationCompleteEventArgs.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\CodeGeneratorBase.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\CodeGeneratorContext.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\CodeWriter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\CodeWriterExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\CSharpCodeWriter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\CSharpRazorCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\DynamicAttributeBlockCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\ExpressionCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\ExpressionRenderingMode.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\GeneratedClassContext.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\GeneratedCodeMapping.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\HelperCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\HybridCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\IBlockCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\ISpanCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\LiteralAttributeCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\MarkupCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\RazorCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\RazorCommentCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\RazorDirectiveAttributeCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\ResolveUrlCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\GeneratorResults.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\SectionCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\SetBaseTypeCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\SetLayoutCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\SetVBOptionCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\SpanCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\StatementCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\TemplateBlockCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\TypeMemberCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\VBCodeWriter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Generator\VBRazorCodeGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\BalancingModes.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\CallbackVisitor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\ConditionalAttributeCollapser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\CSharpCodeParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\CSharpCodeParser.Directives.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\CSharpCodeParser.Statements.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\CSharpLanguageCharacteristics.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\HtmlLanguageCharacteristics.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\HtmlMarkupParser.Block.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\HtmlMarkupParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\HtmlMarkupParser.Document.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\HtmlMarkupParser.Section.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\ISyntaxTreeRewriter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\LanguageCharacteristics.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\MarkupCollapser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\MarkupRewriter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\ParserBase.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\ParserContext.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\ParserHelpers.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\ParserVisitor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\ParserVisitorExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\RazorParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\ParserResults.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxConstants.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\AcceptedCharacters.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\BlockBuilder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\Block.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\BlockType.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\EquivalenceComparer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\RazorError.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\SpanBuilder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\Span.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\SpanKind.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\SyntaxTree\SyntaxTreeNode.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\TextReaderExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\TokenizerBackedParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\TokenizerBackedParser.Helpers.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\VBCodeParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\VBCodeParser.Directives.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\VBCodeParser.Statements.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\VBLanguageCharacteristics.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Parser\WhitespaceRewriter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\PartialParseResult.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Properties\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\RazorCodeLanguage.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\RazorDebugHelpers.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\RazorDirectiveAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\RazorEditorParser.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\RazorEngineHost.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\RazorTemplateEngine.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Resources\RazorResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\StateMachine.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\BufferingTextReader.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\ITextBuffer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\LineTrackingStringBuffer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\LocationTagged.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\LookaheadTextReader.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\LookaheadToken.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\SeekableTextReader.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\SourceLocation.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\SourceLocationTracker.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\TextBufferReader.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\TextChange.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\TextChangeType.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\TextDocumentReader.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Text\TextExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\CSharpHelpers.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\CSharpKeywordDetector.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\CSharpTokenizer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\HtmlTokenizer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\ITokenizer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\CSharpKeyword.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\CSharpSymbol.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\CSharpSymbolType.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\HtmlSymbol.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\HtmlSymbolType.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\ISymbol.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\KnownSymbolType.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\SymbolBase.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\SymbolExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\SymbolTypeSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\VBKeyword.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\VBSymbol.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Symbols\VBSymbolType.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\Tokenizer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\TokenizerView.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\VBHelpers.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\VBKeywordDetector.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\VBTokenizer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Tokenizer\XmlHelpers.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Utils\CharUtils.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Utils\DisposableAction.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Utils\EnumeratorExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\Utils\EnumUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.Razor\VBRazorCodeLanguage.cs" />
+\r
+  </ItemGroup>\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+  <PropertyGroup>\r
+    <PreBuildEvent></PreBuildEvent>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="mscorlib.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>mscorlib.dll</HintPath>
+    </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
+\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Folder Include="Properties\" />\r
+  </ItemGroup>\r
+    <ItemGroup>
+    <EmbeddedResource Include="System.Web.Razor.Resources.RazorResources.resources">
+       <LogicalName>System.Web.Razor.Resources.RazorResources.resources</LogicalName>
+    </EmbeddedResource>
+    <EmbeddedResource Include="System.Web.Razor.Common.CommonResources.resources">
+       <LogicalName>System.Web.Razor.Common.CommonResources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
+</Project>\r
+
diff --git a/mcs/class/System.Web.Razor/System.Web.Razor.dll.sources b/mcs/class/System.Web.Razor/System.Web.Razor.dll.sources
new file mode 100644 (file)
index 0000000..052e19d
--- /dev/null
@@ -0,0 +1,153 @@
+../../build/common/Consts.cs
+
+Assembly/AssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/CommonAssemblyInfo.cs
+../../../external/aspnetwebstack/src/CommonResources.Designer.cs
+../../../external/aspnetwebstack/src/ExceptionHelper.cs
+../../../external/aspnetwebstack/src/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/HashCodeCombiner.cs
+../../../external/aspnetwebstack/src/TransparentCommonAssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/System.Web.Razor/CSharpRazorCodeLanguage.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/DocumentParseCompleteEventArgs.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Editor/AutoCompleteEditHandler.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Editor/BackgroundParseTask.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Editor/EditorHints.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Editor/EditResult.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Editor/ImplicitExpressionEditHandler.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Editor/SingleLineMarkupEditHandler.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Editor/SpanEditHandler.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/AddImportCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/AttributeBlockCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/BaseCodeWriter.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/BlockCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/CodeGenerationCompleteEventArgs.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/CodeGeneratorBase.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/CodeGeneratorContext.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/CodeWriter.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/CodeWriterExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/CSharpCodeWriter.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/CSharpRazorCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/DynamicAttributeBlockCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/ExpressionCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/ExpressionRenderingMode.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/GeneratedClassContext.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/GeneratedCodeMapping.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/HelperCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/HybridCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/IBlockCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/ISpanCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/LiteralAttributeCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/MarkupCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/RazorCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/RazorCommentCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/RazorDirectiveAttributeCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/ResolveUrlCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/GeneratorResults.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/SectionCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/SetBaseTypeCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/SetLayoutCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/SetVBOptionCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/SpanCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/StatementCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/TemplateBlockCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/TypeMemberCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/VBCodeWriter.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Generator/VBRazorCodeGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/BalancingModes.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/CallbackVisitor.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/ConditionalAttributeCollapser.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/CSharpCodeParser.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/CSharpCodeParser.Directives.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/CSharpCodeParser.Statements.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/CSharpLanguageCharacteristics.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/HtmlLanguageCharacteristics.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/HtmlMarkupParser.Block.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/HtmlMarkupParser.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/HtmlMarkupParser.Document.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/HtmlMarkupParser.Section.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/ISyntaxTreeRewriter.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/LanguageCharacteristics.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/MarkupCollapser.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/MarkupRewriter.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/ParserBase.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/ParserContext.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/ParserHelpers.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/ParserVisitor.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/ParserVisitorExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/RazorParser.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/ParserResults.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxConstants.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/AcceptedCharacters.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/BlockBuilder.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/Block.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/BlockType.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/EquivalenceComparer.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/RazorError.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/SpanBuilder.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/Span.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/SpanKind.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/SyntaxTree/SyntaxTreeNode.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/TextReaderExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/TokenizerBackedParser.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/TokenizerBackedParser.Helpers.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/VBCodeParser.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/VBCodeParser.Directives.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/VBCodeParser.Statements.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/VBLanguageCharacteristics.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Parser/WhitespaceRewriter.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/PartialParseResult.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Properties/AssemblyInfo.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/RazorCodeLanguage.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/RazorDebugHelpers.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/RazorDirectiveAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/RazorEditorParser.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/RazorEngineHost.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/RazorTemplateEngine.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Resources/RazorResources.Designer.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/StateMachine.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/BufferingTextReader.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/ITextBuffer.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/LineTrackingStringBuffer.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/LocationTagged.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/LookaheadTextReader.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/LookaheadToken.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/SeekableTextReader.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/SourceLocation.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/SourceLocationTracker.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/TextBufferReader.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/TextChange.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/TextChangeType.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/TextDocumentReader.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Text/TextExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/CSharpHelpers.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/CSharpKeywordDetector.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/CSharpTokenizer.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/HtmlTokenizer.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/ITokenizer.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/CSharpKeyword.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/CSharpSymbol.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/CSharpSymbolType.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/HtmlSymbol.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/HtmlSymbolType.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/ISymbol.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/KnownSymbolType.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/SymbolBase.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/SymbolExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/SymbolTypeSuppressions.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/VBKeyword.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/VBSymbol.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Symbols/VBSymbolType.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/Tokenizer.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/TokenizerView.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/VBHelpers.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/VBKeywordDetector.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/VBTokenizer.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Tokenizer/XmlHelpers.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Utils/CharUtils.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Utils/DisposableAction.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Utils/EnumeratorExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/Utils/EnumUtil.cs
+../../../external/aspnetwebstack/src/System.Web.Razor/VBRazorCodeLanguage.cs
index 6958a5c14defd349a0d1ef942b4ffe8265fbb258..e601f94de8e5fa94dbd4424686c0c1423f1c435f 100644 (file)
@@ -73,7 +73,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index cd0580c04e4bffa5d1083ef62fa4fb22ab84f229..fd3c7f58ded2fea89310249a9309e44fbbc07978 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a6915e64fe23ca2462c9b79f2bad8a60107dd2ff..ff919fe2d08467549a17ba495b85d4aecf73b06e 100644 (file)
@@ -54,7 +54,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c69c4218cfef3181447ff2381eac43fa2ac6e3e2..846fe41cddbed4c01a2a9fbac911b9b4549b3c48 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e1d8d2b5c08a7314ebe97aa07e95a502748230e5..cf253eb538ca3a105b47fdd07fc0212ce264ad0e 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ed57bc8e17f93b284126ca3e3f4c753a4820c7d0..d5095c6d6cbbde194b693fff91b1649a92bd1d2a 100644 (file)
@@ -66,7 +66,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c7e595549d4b01bc93fb2db6a5cb07df9aa4ba28..6499a48ca650db73b0b7fa68d5c32bea5dd02ef9 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index af4afcebd1fa29206ebf0b0866e0b26c1a4fa890..28398793cf1320ce9b697f4e77f74b5ab2645ab1 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index be86d0ba5d218800e3deaeaf2c7fd765aa965fab..87d5b11ec5cb453055e82d72b8abb33b1c9bb847 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8ec84a340bd9a82bae114577ae88fa22da59c089..4c73ca829eec4e04b904b6720c6763fce2c7144b 100644 (file)
@@ -87,7 +87,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3fa62cb52e02c418a39bca9229926424e08c7fa6..8613da7016139838609d8d30f9434b2cf59ae5c0 100644 (file)
@@ -87,7 +87,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 239be626859eee355f3df4b23037720686c67952..8cb64e772ddb7cc112d79942ab246e3bb9539507 100644 (file)
@@ -87,7 +87,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
diff --git a/mcs/class/System.Web.WebPages.Deployment/Assembly/AssemblyInfo.cs b/mcs/class/System.Web.WebPages.Deployment/Assembly/AssemblyInfo.cs
new file mode 100644 (file)
index 0000000..e8362ba
--- /dev/null
@@ -0,0 +1,39 @@
+//
+// AssemblyInfo.cs
+//
+// Authors:
+//     Marek Safar (marek.safar@gmail.com)
+//
+// Copyright (C) 2007 Novell, Inc (http://www.novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+using System.Reflection;
+using System.Resources;
+using System.Security;
+using System.Security.Permissions;
+using System.Diagnostics;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+[assembly: AssemblyDefaultAlias ("System.Web.WebPages.Deployment.dll")]
+[assembly: AssemblyInformationalVersion (Consts.FxFileVersion)]
diff --git a/mcs/class/System.Web.WebPages.Deployment/Makefile b/mcs/class/System.Web.WebPages.Deployment/Makefile
new file mode 100644 (file)
index 0000000..cb46616
--- /dev/null
@@ -0,0 +1,29 @@
+thisdir = class/System.Web.WebPages.Deployment
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Web.WebPages.Deployment.dll
+LIBRARY_NAME = System.Web.WebPages.Deployment.dll
+
+System.Web.WebPages.Deployment.Common.CommonResources.resources: ../../../external/aspnetwebstack/src/CommonResources.resx
+       $(RESGEN) "$<" "$@"
+       
+System.Web.WebPages.Deployment.Resources.ConfigurationResources.resources: ../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/Resources/ConfigurationResources.resx
+       $(RESGEN) "$<" "$@"
+
+LIB_MCS_FLAGS = \
+               /warn:1 \
+               /keyfile:../winfx.pub -delaysign \
+               /r:System.dll \
+               /r:System.Core.dll \
+               /r:System.Configuration.dll \
+               /r:System.Web.dll \
+               /r:Microsoft.Web.Infrastructure.dll \
+               /d:ASPNETWEBPAGES \
+               /resource:System.Web.WebPages.Deployment.Common.CommonResources.resources \
+               /resource:System.Web.WebPages.Deployment.Resources.ConfigurationResources.resources
+
+include ../../build/library.make
+
+$(build_lib): System.Web.WebPages.Deployment.Common.CommonResources.resources \
+               System.Web.WebPages.Deployment.Resources.ConfigurationResources.resources
diff --git a/mcs/class/System.Web.WebPages.Deployment/System.Web.WebPages.Deployment-net_4_5.csproj b/mcs/class/System.Web.WebPages.Deployment/System.Web.WebPages.Deployment-net_4_5.csproj
new file mode 100644 (file)
index 0000000..923e12b
--- /dev/null
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <NoWarn>1699</NoWarn>\r
+    <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
+    <NoStdLib>true</NoStdLib>\r
+    \r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <RootNamespace></RootNamespace>\r
+    <AssemblyName>System.Web.WebPages.Deployment</AssemblyName>\r
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>\r
+    <FileAlignment>512</FileAlignment>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>false</Optimize>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETWEBPAGES</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>true</Optimize>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETWEBPAGES</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <ItemGroup>\r
+   <Compile Include="..\..\build\common\Consts.cs" />
+   <Compile Include="Assembly\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\ExceptionHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\TransparentCommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\AppDomainHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\AssemblyUtils.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\BuildManagerWrapper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\Common\IFileSystem.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\Common\PhysicalFileSystem.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\IBuildManager.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\PreApplicationStartCode.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\Properties\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\Resources\ConfigurationResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Deployment\WebPagesDeployment.cs" />
+\r
+  </ItemGroup>\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+  <PropertyGroup>\r
+    <PreBuildEvent></PreBuildEvent>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="mscorlib.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>mscorlib.dll</HintPath>
+    </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Configuration.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Configuration.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.dll</HintPath>
+    </Reference>
+    <Reference Include="Microsoft.Web.Infrastructure.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>Microsoft.Web.Infrastructure.dll</HintPath>
+    </Reference>
+\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Folder Include="Properties\" />\r
+  </ItemGroup>\r
+    <ItemGroup>
+    <EmbeddedResource Include="System.Web.WebPages.Deployment.Common.CommonResources.resources">
+       <LogicalName>System.Web.WebPages.Deployment.Common.CommonResources.resources</LogicalName>
+    </EmbeddedResource>
+    <EmbeddedResource Include="System.Web.WebPages.Deployment.Resources.ConfigurationResources.resources">
+       <LogicalName>System.Web.WebPages.Deployment.Resources.ConfigurationResources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
+</Project>\r
+
diff --git a/mcs/class/System.Web.WebPages.Deployment/System.Web.WebPages.Deployment.dll.sources b/mcs/class/System.Web.WebPages.Deployment/System.Web.WebPages.Deployment.dll.sources
new file mode 100644 (file)
index 0000000..66d8179
--- /dev/null
@@ -0,0 +1,21 @@
+../../build/common/Consts.cs
+
+Assembly/AssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/CommonAssemblyInfo.cs
+../../../external/aspnetwebstack/src/CommonResources.Designer.cs
+../../../external/aspnetwebstack/src/ExceptionHelper.cs
+../../../external/aspnetwebstack/src/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/TransparentCommonAssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/AppDomainHelper.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/AssemblyUtils.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/BuildManagerWrapper.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/Common/IFileSystem.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/Common/PhysicalFileSystem.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/IBuildManager.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/PreApplicationStartCode.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/Properties/AssemblyInfo.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/Resources/ConfigurationResources.Designer.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Deployment/WebPagesDeployment.cs
diff --git a/mcs/class/System.Web.WebPages.Razor/Assembly/AssemblyInfo.cs b/mcs/class/System.Web.WebPages.Razor/Assembly/AssemblyInfo.cs
new file mode 100644 (file)
index 0000000..be48746
--- /dev/null
@@ -0,0 +1,42 @@
+//
+// AssemblyInfo.cs
+//
+// Authors:
+//     Marek Safar (marek.safar@gmail.com)
+//
+// Copyright (C) 2007 Novell, Inc (http://www.novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+using System.Reflection;
+using System.Resources;
+using System.Security;
+using System.Security.Permissions;
+using System.Diagnostics;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+[assembly: AssemblyDefaultAlias ("System.Web.WebPages.Razor.dll")]
+
+[assembly: SatelliteContractVersion (Consts.FxVersion)]
+[assembly: AssemblyInformationalVersion (Consts.FxFileVersion)]
+
diff --git a/mcs/class/System.Web.WebPages.Razor/Makefile b/mcs/class/System.Web.WebPages.Razor/Makefile
new file mode 100644 (file)
index 0000000..f94ee8a
--- /dev/null
@@ -0,0 +1,33 @@
+thisdir = class/System.Web.WebPages.Razor
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Web.WebPages.Razor.dll
+LIBRARY_NAME = System.Web.WebPages.Razor.dll
+
+System.Web.WebPages.Razor.Common.CommonResources.resources: ../../../external/aspnetwebstack/src/CommonResources.resx
+       $(RESGEN) "$<" "$@"
+       
+System.Web.WebPages.Razor.Resources.RazorWebResources.resources: ../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/Resources/RazorWebResources.resx
+       $(RESGEN) "$<" "$@"
+
+LIB_MCS_FLAGS = \
+               /warn:1 \
+               /keyfile:../winfx.pub \
+               /delaysign \
+               /r:System.dll \
+               /r:System.Core.dll \
+               /r:System.Configuration.dll \
+               /r:System.Web.dll \
+               /r:System.Web.WebPages.dll \
+               /r:System.Web.Razor.dll \
+               /d:ASPNETWEBPAGES \
+               /resource:System.Web.WebPages.Razor.Resources.RazorWebResources.resources \
+               /resource:System.Web.WebPages.Razor.Common.CommonResources.resources
+
+include ../../build/library.make
+
+$(build_lib): System.Web.WebPages.Razor.Resources.RazorWebResources.resources \
+               System.Web.WebPages.Razor.Common.CommonResources.resources
+
+
diff --git a/mcs/class/System.Web.WebPages.Razor/System.Web.WebPages.Razor-net_4_5.csproj b/mcs/class/System.Web.WebPages.Razor/System.Web.WebPages.Razor-net_4_5.csproj
new file mode 100644 (file)
index 0000000..f9b15af
--- /dev/null
@@ -0,0 +1,118 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <NoWarn>1699</NoWarn>\r
+    <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
+    <NoStdLib>true</NoStdLib>\r
+    \r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <RootNamespace></RootNamespace>\r
+    <AssemblyName>System.Web.WebPages.Razor</AssemblyName>\r
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>\r
+    <FileAlignment>512</FileAlignment>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>false</Optimize>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETWEBPAGES</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>true</Optimize>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETWEBPAGES</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <ItemGroup>\r
+   <Compile Include="..\..\build\common\Consts.cs" />
+   <Compile Include="Assembly\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\TransparentCommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\AssemblyBuilderWrapper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\CompilingPathEventArgs.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\Configuration\HostSection.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\Configuration\RazorPagesSection.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\Configuration\RazorWebSectionGroup.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\HostingEnvironmentWrapper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\IAssemblyBuilder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\IHostingEnvironment.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\PreApplicationStartCode.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\Properties\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\RazorBuildProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\Resources\RazorWebResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\WebCodeRazorHost.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\WebPageRazorHost.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages.Razor\WebRazorHostFactory.cs" />
+\r
+  </ItemGroup>\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+  <PropertyGroup>\r
+    <PreBuildEvent></PreBuildEvent>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="mscorlib.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>mscorlib.dll</HintPath>
+    </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Configuration.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Configuration.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.WebPages.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.WebPages.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.Razor.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.Razor.dll</HintPath>
+    </Reference>
+\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Folder Include="Properties\" />\r
+  </ItemGroup>\r
+    <ItemGroup>
+    <EmbeddedResource Include="System.Web.WebPages.Razor.Resources.RazorWebResources.resources">
+       <LogicalName>System.Web.WebPages.Razor.Resources.RazorWebResources.resources</LogicalName>
+    </EmbeddedResource>
+    <EmbeddedResource Include="System.Web.WebPages.Razor.Common.CommonResources.resources">
+       <LogicalName>System.Web.WebPages.Razor.Common.CommonResources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
+</Project>\r
+
diff --git a/mcs/class/System.Web.WebPages.Razor/System.Web.WebPages.Razor.dll.sources b/mcs/class/System.Web.WebPages.Razor/System.Web.WebPages.Razor.dll.sources
new file mode 100644 (file)
index 0000000..2adb7c2
--- /dev/null
@@ -0,0 +1,24 @@
+../../build/common/Consts.cs
+
+Assembly/AssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/CommonAssemblyInfo.cs
+../../../external/aspnetwebstack/src/CommonResources.Designer.cs
+../../../external/aspnetwebstack/src/TransparentCommonAssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/AssemblyBuilderWrapper.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/CompilingPathEventArgs.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/Configuration/HostSection.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/Configuration/RazorPagesSection.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/Configuration/RazorWebSectionGroup.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/HostingEnvironmentWrapper.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/IAssemblyBuilder.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/IHostingEnvironment.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/PreApplicationStartCode.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/Properties/AssemblyInfo.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/RazorBuildProvider.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/Resources/RazorWebResources.Designer.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/WebCodeRazorHost.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/WebPageRazorHost.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages.Razor/WebRazorHostFactory.cs
diff --git a/mcs/class/System.Web.WebPages/Assembly/AssemblyInfo.cs b/mcs/class/System.Web.WebPages/Assembly/AssemblyInfo.cs
new file mode 100644 (file)
index 0000000..c9f1293
--- /dev/null
@@ -0,0 +1,42 @@
+//
+// AssemblyInfo.cs
+//
+// Authors:
+//     Marek Safar (marek.safar@gmail.com)
+//
+// Copyright (C) 2007 Novell, Inc (http://www.novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+using System.Reflection;
+using System.Resources;
+using System.Security;
+using System.Security.Permissions;
+using System.Diagnostics;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+[assembly: AssemblyDefaultAlias ("System.Web.WebPages.dll")]
+
+[assembly: SatelliteContractVersion (Consts.FxVersion)]
+[assembly: AssemblyInformationalVersion (Consts.FxFileVersion)]
+
diff --git a/mcs/class/System.Web.WebPages/Makefile b/mcs/class/System.Web.WebPages/Makefile
new file mode 100644 (file)
index 0000000..a3eb5d1
--- /dev/null
@@ -0,0 +1,39 @@
+thisdir = class/System.Web.WebPages
+SUBDIRS = 
+include ../../build/rules.make
+
+LIBRARY = System.Web.WebPages.dll
+LIBRARY_NAME = System.Web.WebPages.dll
+
+System.Web.WebPages.Common.CommonResources.resources: ../../../external/aspnetwebstack/src/CommonResources.resx
+       $(RESGEN) "$<" "$@"
+       
+System.Web.WebPages.Resources.WebPageResources.resources: ../../../external/aspnetwebstack/src/System.Web.WebPages/Resources/WebPageResources.resx
+       $(RESGEN) "$<" "$@"
+
+LIB_MCS_FLAGS = \
+               /warn:1 \
+               /keyfile:../winfx.pub \
+               /delaysign \
+               /r:Microsoft.CSharp.dll \
+               /r:Microsoft.Web.Infrastructure.dll \
+               /r:System.dll \
+               /r:System.ComponentModel.DataAnnotations.dll \
+               /r:System.Configuration.dll \
+               /r:System.Core.dll \
+               /r:System.Data.Linq.dll \
+               /r:System.Web.dll \
+               /r:System.Web.WebPages.Deployment.dll \
+               /r:System.Web.Razor.dll \
+               /r:System.Xml.dll \
+               /r:System.Xml.Linq.dll \
+               /d:ASPNETWEBPAGES \
+               /resource:System.Web.WebPages.Resources.WebPageResources.resources \
+               /resource:System.Web.WebPages.Common.CommonResources.resources
+
+EXTRA_DISTFILES = $(RESX_DIST)
+
+include ../../build/library.make
+
+$(build_lib): System.Web.WebPages.Resources.WebPageResources.resources \
+               System.Web.WebPages.Common.CommonResources.resources
diff --git a/mcs/class/System.Web.WebPages/System.Web.WebPages-net_4_5.csproj b/mcs/class/System.Web.WebPages/System.Web.WebPages-net_4_5.csproj
new file mode 100644 (file)
index 0000000..d2749d7
--- /dev/null
@@ -0,0 +1,266 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>\r
+    <ProductVersion>9.0.30729</ProductVersion>\r
+    <SchemaVersion>2.0</SchemaVersion>\r
+    <ProjectGuid>{155AEF28-C81F-405D-9072-9D52780E3E70}</ProjectGuid>\r
+    <OutputType>Library</OutputType>\r
+    <NoWarn>1699</NoWarn>\r
+    <OutputPath>./../../class/lib/net_4_5</OutputPath>\r
+    <NoStdLib>true</NoStdLib>\r
+    \r
+    <AppDesignerFolder>Properties</AppDesignerFolder>\r
+    <RootNamespace></RootNamespace>\r
+    <AssemblyName>System.Web.WebPages</AssemblyName>\r
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>\r
+    <FileAlignment>512</FileAlignment>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>false</Optimize>\r
+    <DefineConstants>DEBUG;TRACE;NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETWEBPAGES</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <NoWarn>1699</NoWarn>\r
+    <Optimize>true</Optimize>\r
+    <DefineConstants>NET_1_1;NET_2_0;NET_3_0;NET_3_5;NET_4_0;NET_4_5;ASPNETWEBPAGES</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <AdditionalLibPaths>./../../class/lib/net_4_5</AdditionalLibPaths>\r
+  </PropertyGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />\r
+  <ItemGroup>\r
+   <Compile Include="..\..\build\common\Consts.cs" />
+   <Compile Include="Assembly\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\CommonResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\ExceptionHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\HashCodeCombiner.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\TransparentCommonAssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\MimeMapping.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\IVirtualPathUtility.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\VirtualPathUtilityWrapper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ApplicationPart.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ApplicationParts\ApplicationPartRegistry.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ApplicationParts\DictionaryBasedVirtualPathFactory.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ApplicationParts\IResourceAssembly.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ApplicationParts\LazyAction.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ApplicationParts\ResourceAssembly.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ApplicationParts\ResourceHandler.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ApplicationParts\ResourceRouteHandler.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ApplicationStartPage.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\AttributeValue.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\BrowserHelpers.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\BrowserOverride.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\BrowserOverrideStore.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\BrowserOverrideStores.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\BuildManagerWrapper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Common\DisposableAction.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\CookieBrowserOverrideStore.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\DefaultDisplayMode.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\DisplayInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\DisplayModeProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\DynamicHttpApplicationState.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\DynamicPageDataDictionary.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\FileExistenceCache.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\GlobalSuppressions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\HelperPage.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\HelperResult.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiForgeryConfig.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiForgery.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\AntiForgeryConfigWrapper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\AntiForgeryToken.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\AntiForgeryTokenSerializer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\AntiForgeryTokenStore.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\AntiForgeryWorker.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\BinaryBlob.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\ClaimUidExtractor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\IAntiForgeryConfig.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\IAntiForgeryTokenSerializer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\IClaimUidExtractor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\ICryptoSystem.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\ITokenStore.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\ITokenValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\MachineKeyCryptoSystem.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\AntiXsrf\TokenValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\Claims\Claim.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\Claims\ClaimsIdentityConverter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\Claims\ClaimsIdentity.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\CryptoUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\IAntiForgeryAdditionalDataProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\UnvalidatedRequestValues.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Helpers\Validation.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\HtmlHelper.Checkbox.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\HtmlHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\HtmlHelper.Input.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\HtmlHelper.Internal.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\HtmlHelper.Label.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\HtmlHelper.Radio.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\HtmlHelper.Select.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\HtmlHelper.TextArea.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\HtmlHelper.Validation.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\ModelState.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\ModelStateDictionary.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Html\SelectListItem.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\HttpContextExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\IDisplayMode.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Instrumentation\HttpContextAdapter.Availability.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Instrumentation\HttpContextAdapter.generated.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Instrumentation\InstrumentationService.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Instrumentation\PageExecutionContextAdapter.generated.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Instrumentation\PageExecutionListenerAdapter.generated.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Instrumentation\PageInstrumentationServiceAdapter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Instrumentation\PositionTagged.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ITemplateFile.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\IVirtualPathFactory.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\IWebPageRequestExecutor.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\HttpAntiForgeryException.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\ModelClientValidationEqualToRule.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\ModelClientValidationRangeRule.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\ModelClientValidationRegexRule.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\ModelClientValidationRemoteRule.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\ModelClientValidationRequiredRule.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\ModelClientValidationRule.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\ModelClientValidationStringLengthRule.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\TagBuilder.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\TagRenderMode.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Mvc\UnobtrusiveValidationAttributesGenerator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\PageDataDictionary.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\PageVirtualPathAttribute.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\PreApplicationStartCode.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Properties\AssemblyInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ReflectionDynamicObject.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\RequestBrowserOverrideStore.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\RequestExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\RequestResourceTracker.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Resources\WebPageResources.Designer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\ResponseExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Scope\ApplicationScopeStorageDictionary.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Scope\AspNetRequestScopeStorageProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Scope\IScopeStorageProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Scope\ScopeStorageComparer.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Scope\ScopeStorage.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Scope\ScopeStorageDictionary.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Scope\StaticScopeStorageProvider.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Scope\WebConfigScopeStorageDictionary.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\SectionWriter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\SecurityUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\StartPage.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\StringExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\TemplateFileInfo.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\TemplateStack.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\UrlDataList.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Utils\BuildManagerExceptionUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Utils\CultureUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Utils\PathUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Utils\SessionStateUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Utils\TypeHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Utils\UrlUtil.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Validation\CompareValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Validation\DataTypeValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Validation\IValidator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Validation\RequestFieldValidatorBase.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Validation\ValidationAttributeAdapter.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Validation\ValidationHelper.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\Validation\Validator.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\VirtualPathFactoryExtensions.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\VirtualPathFactoryManager.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\WebPageBase.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\WebPageContext.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\WebPage.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\WebPageExecutingBase.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\WebPageHttpHandler.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\WebPageHttpModule.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\WebPageMatch.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\WebPageRenderingBase.cs" />
+   <Compile Include="..\..\..\external\aspnetwebstack\src\System.Web.WebPages\WebPageRoute.cs" />
+\r
+  </ItemGroup>\r
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
+       Other similar extension points exist, see Microsoft.Common.targets.\r
+  <Target Name="BeforeBuild">\r
+  </Target>\r
+  <Target Name="AfterBuild">\r
+  </Target>\r
+  -->\r
+  <PropertyGroup>\r
+    <PreBuildEvent></PreBuildEvent>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="mscorlib.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>mscorlib.dll</HintPath>
+    </Reference>
+    <Reference Include="Microsoft.CSharp.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>Microsoft.CSharp.dll</HintPath>
+    </Reference>
+    <Reference Include="Microsoft.Web.Infrastructure.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>Microsoft.Web.Infrastructure.dll</HintPath>
+    </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.ComponentModel.DataAnnotations.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.ComponentModel.DataAnnotations.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Configuration.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Configuration.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Data.Linq.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Data.Linq.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.WebPages.Deployment.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.WebPages.Deployment.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.Razor.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Web.Razor.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.Linq.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.Linq.dll</HintPath>
+    </Reference>
+\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Folder Include="Properties\" />\r
+  </ItemGroup>\r
+    <ItemGroup>
+    <EmbeddedResource Include="System.Web.WebPages.Resources.WebPageResources.resources">
+       <LogicalName>System.Web.WebPages.Resources.WebPageResources.resources</LogicalName>
+    </EmbeddedResource>
+    <EmbeddedResource Include="System.Web.WebPages.Common.CommonResources.resources">
+       <LogicalName>System.Web.WebPages.Common.CommonResources.resources</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+\r
+</Project>\r
+
diff --git a/mcs/class/System.Web.WebPages/System.Web.WebPages.dll.sources b/mcs/class/System.Web.WebPages/System.Web.WebPages.dll.sources
new file mode 100644 (file)
index 0000000..60df2df
--- /dev/null
@@ -0,0 +1,148 @@
+../../build/common/Consts.cs
+
+Assembly/AssemblyInfo.cs
+
+../../../external/aspnetwebstack/src/CommonAssemblyInfo.cs
+../../../external/aspnetwebstack/src/CommonResources.Designer.cs
+../../../external/aspnetwebstack/src/ExceptionHelper.cs
+../../../external/aspnetwebstack/src/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/HashCodeCombiner.cs
+../../../external/aspnetwebstack/src/TransparentCommonAssemblyInfo.cs
+../../../external/aspnetwebstack/src/MimeMapping.cs
+../../../external/aspnetwebstack/src/IVirtualPathUtility.cs
+../../../external/aspnetwebstack/src/VirtualPathUtilityWrapper.cs
+
+../../../external/aspnetwebstack/src/System.Web.WebPages/ApplicationPart.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ApplicationParts/ApplicationPartRegistry.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ApplicationParts/DictionaryBasedVirtualPathFactory.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ApplicationParts/IResourceAssembly.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ApplicationParts/LazyAction.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ApplicationParts/ResourceAssembly.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ApplicationParts/ResourceHandler.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ApplicationParts/ResourceRouteHandler.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ApplicationStartPage.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/AttributeValue.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/BrowserHelpers.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/BrowserOverride.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/BrowserOverrideStore.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/BrowserOverrideStores.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/BuildManagerWrapper.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Common/DisposableAction.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/CookieBrowserOverrideStore.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/DefaultDisplayMode.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/DisplayInfo.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/DisplayModeProvider.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/DynamicHttpApplicationState.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/DynamicPageDataDictionary.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/FileExistenceCache.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/GlobalSuppressions.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/HelperPage.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/HelperResult.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiForgeryConfig.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiForgery.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/AntiForgeryConfigWrapper.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/AntiForgeryToken.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/AntiForgeryTokenSerializer.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/AntiForgeryTokenStore.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/AntiForgeryWorker.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/BinaryBlob.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/ClaimUidExtractor.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/IAntiForgeryConfig.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/IAntiForgeryTokenSerializer.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/IClaimUidExtractor.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/ICryptoSystem.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/ITokenStore.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/ITokenValidator.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/MachineKeyCryptoSystem.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/AntiXsrf/TokenValidator.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/Claims/Claim.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/Claims/ClaimsIdentityConverter.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/Claims/ClaimsIdentity.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/CryptoUtil.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/IAntiForgeryAdditionalDataProvider.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/UnvalidatedRequestValues.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Helpers/Validation.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/HtmlHelper.Checkbox.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/HtmlHelper.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/HtmlHelper.Input.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/HtmlHelper.Internal.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/HtmlHelper.Label.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/HtmlHelper.Radio.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/HtmlHelper.Select.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/HtmlHelper.TextArea.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/HtmlHelper.Validation.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/ModelState.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/ModelStateDictionary.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Html/SelectListItem.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/HttpContextExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/IDisplayMode.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Instrumentation/HttpContextAdapter.Availability.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Instrumentation/HttpContextAdapter.generated.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Instrumentation/InstrumentationService.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Instrumentation/PageExecutionContextAdapter.generated.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Instrumentation/PageExecutionListenerAdapter.generated.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Instrumentation/PageInstrumentationServiceAdapter.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Instrumentation/PositionTagged.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ITemplateFile.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/IVirtualPathFactory.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/IWebPageRequestExecutor.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/HttpAntiForgeryException.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/ModelClientValidationEqualToRule.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/ModelClientValidationRangeRule.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/ModelClientValidationRegexRule.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/ModelClientValidationRemoteRule.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/ModelClientValidationRequiredRule.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/ModelClientValidationRule.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/ModelClientValidationStringLengthRule.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/TagBuilder.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/TagRenderMode.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Mvc/UnobtrusiveValidationAttributesGenerator.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/PageDataDictionary.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/PageVirtualPathAttribute.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/PreApplicationStartCode.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Properties/AssemblyInfo.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ReflectionDynamicObject.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/RequestBrowserOverrideStore.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/RequestExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/RequestResourceTracker.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Resources/WebPageResources.Designer.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/ResponseExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Scope/ApplicationScopeStorageDictionary.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Scope/AspNetRequestScopeStorageProvider.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Scope/IScopeStorageProvider.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Scope/ScopeStorageComparer.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Scope/ScopeStorage.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Scope/ScopeStorageDictionary.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Scope/StaticScopeStorageProvider.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Scope/WebConfigScopeStorageDictionary.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/SectionWriter.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/SecurityUtil.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/StartPage.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/StringExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/TemplateFileInfo.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/TemplateStack.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/UrlDataList.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Utils/BuildManagerExceptionUtil.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Utils/CultureUtil.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Utils/PathUtil.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Utils/SessionStateUtil.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Utils/TypeHelper.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Utils/UrlUtil.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Validation/CompareValidator.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Validation/DataTypeValidator.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Validation/IValidator.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Validation/RequestFieldValidatorBase.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Validation/ValidationAttributeAdapter.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Validation/ValidationHelper.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/Validation/Validator.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/VirtualPathFactoryExtensions.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/VirtualPathFactoryManager.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/WebPageBase.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/WebPageContext.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/WebPage.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/WebPageExecutingBase.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/WebPageHttpHandler.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/WebPageHttpModule.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/WebPageMatch.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/WebPageRenderingBase.cs
+../../../external/aspnetwebstack/src/System.Web.WebPages/WebPageRoute.cs
index e8c1a5799bd270e71789a59197563838819f515b..432ee8ec5c09377761637fdbbd6365d5452abd57 100644 (file)
@@ -102,7 +102,7 @@ using System.Web.UI;
 [assembly: InternalsVisibleTo ("SystemWebTestShim, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]
 [assembly: InternalsVisibleTo ("System.Web_test_net_2_0, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]
 [assembly: InternalsVisibleTo ("System.Web_test_net_4_0, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]
-
+[assembly: InternalsVisibleTo ("System.Web_test_net_4_5, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]
 // Resources
 
 [assembly: WebResource ("TreeView_noexpand.gif", "image/gif")]
index 7f1691c32fceb94a78fc27c967166545e286eaae..399812855e1ba649a72764f53e9f54e89f7c23c2 100644 (file)
@@ -321,6 +321,7 @@ EXTRA_DISTFILES = \
        $(shell find Test/tools/ -path '*/.svn' -prune -o -type f -printf "'%p' ") \
        System.Web_standalone_test.dll.sources \
        standalone-runner-support.dll.sources \
+       $(shell find Test/System.Web.Caching/CacheItemPriorityQueueTestData/ -name "Sequence*.*" -type f -printf "'%p' ") \
        ASPState.sql
 
 BUILT_SOURCES = System.Web/UplevelHelper.cs 
index 5e22a3ee94195ccfbdfed8f8a320305bfeefbad2..524b0ad662a6c34ca2c53aa522cb1044a23bdbd4 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3ce19bd334c6fe3a050fa91295aeca0d5cbeb4ec..c598ca68e4a069e1137161f3a40f52a4c5774dff 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index e54335df35b050c9c03bd74459cc9378734f5c49..0ee7c6027f9a53fa76a73dd2688d36cc069736f9 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f8264dffff2783b1fa7494249b3727fc1ecc9fd9..4bce1cf1db8020234243d54cfa44000101fbd15f 100644 (file)
@@ -336,19 +336,6 @@ namespace System.Web.Handlers
                        return href;
                }
 
-               bool HasCacheControl (HttpRequest request, NameValueCollection queryString, out long atime)
-               {
-                       if (String.Compare (request.Headers ["Cache-Control"], "max-age=0", StringComparison.Ordinal) != 0) {
-                               atime = 0;
-                               return false;
-                       }
-                       
-                       if (Int64.TryParse (request.QueryString ["t"], out atime))
-                               return true;
-
-                       return false;
-               }
-
                bool HasIfModifiedSince (HttpRequest request, out DateTime modified)
                {
                        string modif_since = request.Headers ["If-Modified-Since"];
@@ -373,7 +360,6 @@ namespace System.Web.Handlers
                        response.Clear ();
                        response.StatusCode = 304;
                        response.ContentType = null;
-                       response.CacheControl = "public"; // easier to set it to public as MS than remove it
                        context.ApplicationInstance.CompleteRequest ();
                }
                
@@ -400,13 +386,6 @@ namespace System.Web.Handlers
                                assembly = Assembly.Load (entry.AssemblyName);
                        
                        long atime;
-                       if (HasCacheControl (request, queryString, out atime)) {
-                               if (atime == File.GetLastWriteTimeUtc (assembly.Location).Ticks) {
-                                       RespondWithNotModified (context);
-                                       return;
-                               }
-                       }
-
                        DateTime modified;
                        if (HasIfModifiedSince (request, out modified)) {
                                if (File.GetLastWriteTimeUtc (assembly.Location) <= modified) {
index 535f742429decc37e03b3e95a1a816fff07c9768..e8396503bb344be4dda2ebc0b1dd2917e0fef620 100644 (file)
@@ -10,6 +10,7 @@
 
 //
 // Copyright (C) 2005-2010 Novell, Inc (http://www.novell.com)
+// Copyright (C) 2011-2012 Xamarin, Inc (http://xamarin.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
@@ -1057,7 +1058,7 @@ namespace System.Web
                public string Path {
                        get {
                                if (unescaped_path == null) {
-                                       unescaped_path = Uri.UnescapeDataString (PathNoValidation);
+                                       unescaped_path = PathNoValidation;
 #if NET_4_0
                                        if (validateRequestNewMode) {
                                                RequestValidator validator = RequestValidator.Current;
index 8d99381877de4bc57bd53514234a39dd71192264..9d22efe2ada905451f4492d04c34009633a825ff 100644 (file)
@@ -3,7 +3,7 @@ SUBDIRS =
 include ../../../../build/rules.make
 
 LOCAL_MCS_FLAGS = /nowarn:0168 /nowarn:0162 /unsafe \
- /noconfig /r:System.dll /r:System.Web.dll \
+ /r:System.dll /r:System.Web.dll \
  /r:System.Drawing.dll /r:System.Xml.dll
 
 all-local install-local uninstall-local doc-update-local csproj-local:
index 22c0945aa255312ae1c4b271ba2f1bafc7ca5198..67c8f56c19bfc3f90b047734833b26994fe6fc69 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8e01cc1fd634888305148f5e28cf707b090c138f..12f4111f280b3a73f98e6a16bcc2f2622e532eda 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index b664bca0850a3c7d1e82548855bdf0c8db6970cb..db6d5bc49f8829d2b90629270acd597772736227 100644 (file)
@@ -26,7 +26,7 @@ endif
 ifeq (2.1, $(FRAMEWORK_VERSION))
 LIB_MCS_FLAGS += -unsafe -d:AGCLR -d:NET_2_1_HACK
 endif
-TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data
+TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data.dll -r:System.Core.dll
 
 ifeq (2.0, $(FRAMEWORK_VERSION))
 # Happens on net_2_0_bootstrap and net_2_0 profiles
@@ -66,7 +66,7 @@ EXTRA_DISTFILES = \
        Test/XmlFiles/76102.xml         \
        Test/XmlFiles/79683.dtd         \
        Test/XmlFiles/496192.xml        \
-       Test/XmlFiles/496192.xsd        \
+       Test/XmlFiles/*.xsd     \
        $(wildcard Test/XmlFiles/xsd/*.xml) \
        $(wildcard Test/XmlFiles/xsd/*.xsd) \
        $(wildcard Test/XmlFiles/xsl/*.xml) \
index 88207bdf3332cf36e02679a990afff6c2bb3e7dd..c03e6fc1e40f70234e217ae01c5ff9513196e1a5 100644 (file)
    <Compile Include="System.Xml.Schema\XmlSchemaReader.cs" />
    <Compile Include="System.Xml.Schema\XmlSchemaValidationFlags.cs" />
    <Compile Include="System.Xml.Schema\XmlTypeCode.cs" />
+   <Compile Include="System.Xml.Schema\XmlValueConverter.cs" />
    <Compile Include="System.Xml.Schema\XmlValueGetter.cs" />
    <Compile Include="System.Xml.Serialization\IXmlTextParser.cs" />
    <Compile Include="System.Xml.Serialization\CodeExporter.cs" />
@@ -447,7 +448,7 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
 \r</PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index cc8b2a05241c316c692e50908fe24d5d50f186e4..951fd2ef18d9f3de9f23d6f266d91cf240049c99 100644 (file)
    <Compile Include="System.Xml.Schema\XmlSchemaReader.cs" />
    <Compile Include="System.Xml.Schema\XmlSchemaValidationFlags.cs" />
    <Compile Include="System.Xml.Schema\XmlTypeCode.cs" />
+   <Compile Include="System.Xml.Schema\XmlValueConverter.cs" />
    <Compile Include="System.Xml.Schema\XmlValueGetter.cs" />
    <Compile Include="System.Xml.Serialization\IXmlTextParser.cs" />
    <Compile Include="System.Xml.Serialization\CodeExporter.cs" />
@@ -447,7 +448,7 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
 \r</PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 9b1897ea3b3dbfe2587ac9ff12485a3d6f5ddc36..49b5c4d7851d11a4f7e6c725241e90c114ddf06f 100644 (file)
    <Compile Include="System.Xml.Schema\XmlSchemaReader.cs" />
    <Compile Include="System.Xml.Schema\XmlSchemaValidationFlags.cs" />
    <Compile Include="System.Xml.Schema\XmlTypeCode.cs" />
+   <Compile Include="System.Xml.Schema\XmlValueConverter.cs" />
    <Compile Include="System.Xml.Schema\XmlValueGetter.cs" />
    <Compile Include="System.Xml.Serialization\IXmlTextParser.cs" />
    <Compile Include="System.Xml.Serialization\CodeExporter.cs" />
@@ -447,7 +448,7 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
 \r</PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7d76fac78d3819d64794e33c7f7d166f874153d5..f5e834164185304ec79e00b34c26fd5fa712eefb 100644 (file)
    <Compile Include="System.Xml.Schema\XmlSchemaReader.cs" />
    <Compile Include="System.Xml.Schema\XmlSchemaValidationFlags.cs" />
    <Compile Include="System.Xml.Schema\XmlTypeCode.cs" />
+   <Compile Include="System.Xml.Schema\XmlValueConverter.cs" />
    <Compile Include="System.Xml.Schema\XmlValueGetter.cs" />
    <Compile Include="System.Xml.Serialization\IXmlTextParser.cs" />
    <Compile Include="System.Xml.Serialization\CodeExporter.cs" />
@@ -447,7 +448,7 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
 \r</PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2a6d6bc75386b23aceb35fa0e0674b06ce4ee8f9..dcc1142a9c3efd266dceb68a8e39492cccddd3ae 100644 (file)
@@ -173,7 +173,7 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
 \r</PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
@@ -193,9 +193,13 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Configuration.dll</HintPath>
     </Reference>
-    <Reference Include="System.Data">
+    <Reference Include="System.Data.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Data.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Data</HintPath>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="System.Configuration">
       <SpecificVersion>False</SpecificVersion>
index 414edbc50a4dcc033aabed5b869b9bd2b7c8b61f..bbebf1e8cde569a0a59c72c95c7d4fd7a698771e 100644 (file)
@@ -173,7 +173,7 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
 \r</PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
@@ -189,9 +189,13 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.dll</HintPath>
     </Reference>
-    <Reference Include="System.Data">
+    <Reference Include="System.Data.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Data.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Data</HintPath>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="nunit.framework" />
 \r
index 2e26f15034364928afb71a38e951bc36c137b72c..b40ea0e971ffcfdae2fa24cdf11592fc1c2e2cb7 100644 (file)
@@ -173,7 +173,7 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
 \r</PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
@@ -189,9 +189,13 @@ type $(ProjectDir)\System.Xml.XPath\Tokenizer.cs >> $(ProjectDir)\Mono.Xml.Xsl\P
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.dll</HintPath>
     </Reference>
-    <Reference Include="System.Data">
+    <Reference Include="System.Data.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Data.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Data</HintPath>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="nunit.framework" />
 \r
index 17d5233e098d903a83cdf9e4f890e68a3365872f..85560cd255d56444831dc9cbf10b8996e39a6114 100644 (file)
@@ -98,6 +98,22 @@ namespace System.Xml.Serialization
                                else if(obj is XmlTypeAttribute)
                                        xmlType = (XmlTypeAttribute) obj;
                        }
+                       
+                       if (xmlIgnore) {
+                               xmlAnyAttribute = null;
+                               xmlAnyElements.Clear ();
+                               xmlArray = null;
+                               xmlArrayItems.Clear ();
+                               xmlAttribute = null;
+                               xmlChoiceIdentifier = null;
+                               xmlDefaultValue = null;
+                               xmlElements.Clear ();
+                               xmlEnum = null;
+                               xmlns = false;
+                               xmlRoot = null;
+                               xmlText = null;
+                               xmlType = null;
+                       }
                }
 
                #region public properties
index 94bc14d81037a97e52385be650d84e6fed7bb43f..dffae294ea472d457b3f0ca1a9b4100af6f75477 100644 (file)
@@ -154,7 +154,6 @@ namespace System.Xml.Serialization {
                        ArrayList mapping = new ArrayList ();
                        for (int n=0; n<members.Length; n++)
                        {
-                               if (members[n].XmlAttributes.XmlIgnore) continue;
                                XmlTypeMapMember mapMem = CreateMapMember (null, members[n], ns);
                                mapMem.GlobalIndex = n;
                                mapMem.CheckOptionalValueType (members);
index aae1733ec5231c7941cd0366d907b083808bf712..f2e3e52f6f58f27177c58d925a79ceef41bef584 100644 (file)
 //
 
 using System;
-#if NET_2_0
 using System.Collections.Generic;
-#else
-using System.Collections;
-#endif
 
 namespace System.Xml
 {
-#if NET_2_0
        public interface IXmlNamespaceResolver
-#else
-       internal interface IXmlNamespaceResolver
-#endif
        {
-#if NET_2_0
                IDictionary<string, string> GetNamespacesInScope (XmlNamespaceScope scope);
-#else
-               IDictionary GetNamespacesInScope (XmlNamespaceScope scope);
-#endif
 
                string LookupNamespace (string prefix);
 
-               string LookupPrefix (string ns);
+               string LookupPrefix (string namespaceName);
        }
 }
index 4a79204ceb21e4af69c04d09a884db942f36a71a..8095b0d640781cd0f3052c6041668fefa0bc8e81 100644 (file)
@@ -117,25 +117,12 @@ namespace System.Xml
                }
 
                public override string InnerText {
-#if !(NET_2_0)
-                       get {
-                               return base.InnerText;
-                       }
-#endif
-
                        set {
                                Value = value;
                        }
                }
 
                public override string InnerXml {
-#if !(NET_2_0)
-                       get {
-                               // Not sure why this is an override.  Passing through for now.
-                               return base.InnerXml;
-                       }
-#endif
-
                        set {
                                RemoveAll ();
                                XmlNamespaceManager nsmgr = ConstructNamespaceManager ();
@@ -266,9 +253,9 @@ namespace System.Xml
                #region Methods
 
 #if NET_2_0
-               public override XmlNode AppendChild (XmlNode child)
+               public override XmlNode AppendChild (XmlNode newChild)
                {
-                       return base.AppendChild (child);
+                       return base.AppendChild (newChild);
                }
 
                public override XmlNode InsertBefore (XmlNode newChild, XmlNode refChild)
@@ -281,14 +268,14 @@ namespace System.Xml
                        return base.InsertAfter (newChild, refChild);
                }
 
-               public override XmlNode PrependChild (XmlNode node)
+               public override XmlNode PrependChild (XmlNode newChild)
                {
-                       return base.PrependChild (node);
+                       return base.PrependChild (newChild);
                }
 
-               public override XmlNode RemoveChild (XmlNode node)
+               public override XmlNode RemoveChild (XmlNode oldChild)
                {
-                       return base.RemoveChild (node);
+                       return base.RemoveChild (oldChild);
                }
 
                public override XmlNode ReplaceChild (XmlNode newChild, XmlNode oldChild)
index 4aca351e3980db7863e47de706108504f02bed54..ae31b62983cb6255af04a748bb4588d88a3b4947 100644 (file)
@@ -367,22 +367,22 @@ namespace System.Xml {
                }
                
 #if NET_2_0
-               public static DateTime ToDateTime (string value, XmlDateTimeSerializationMode mode)
+               public static DateTime ToDateTime (string s, XmlDateTimeSerializationMode dateTimeOption)
                {
                        DateTime dt;
-                       switch (mode) {
+                       switch (dateTimeOption) {
                        case XmlDateTimeSerializationMode.Local:
-                               dt = ToDateTime (value, localDateTimeFormats);
+                               dt = ToDateTime (s, localDateTimeFormats);
                                return new DateTime (dt.Ticks, DateTimeKind.Local);
                        case XmlDateTimeSerializationMode.RoundtripKind:
-                               return ToDateTime (value, roundtripDateTimeFormats, _defaultStyle | DateTimeStyles.RoundtripKind);
+                               return ToDateTime (s, roundtripDateTimeFormats, _defaultStyle | DateTimeStyles.RoundtripKind);
                        case XmlDateTimeSerializationMode.Utc:
-                               dt = ToDateTime (value, utcDateTimeFormats);
+                               dt = ToDateTime (s, utcDateTimeFormats);
                                return new DateTime (dt.Ticks, DateTimeKind.Utc);
                        case XmlDateTimeSerializationMode.Unspecified:
-                               return ToDateTime (value, unspecifiedDateTimeFormats);
+                               return ToDateTime (s, unspecifiedDateTimeFormats);
                        default:
-                               return ToDateTime (value, defaultDateTimeFormats);
+                               return ToDateTime (s, defaultDateTimeFormats);
                        }
                }
 #endif
@@ -630,11 +630,11 @@ namespace System.Xml {
                }
 
 #if NET_2_0
-               public static string ToString (DateTime value, XmlDateTimeSerializationMode mode)
+               public static string ToString (DateTime value, XmlDateTimeSerializationMode dateTimeOption)
                {
                        // Unlike usual DateTime formatting, it preserves
                        // MaxValue/MinValue as is.
-                       switch (mode) {
+                       switch (dateTimeOption) {
                        case XmlDateTimeSerializationMode.Local:
                                return (value == DateTime.MinValue ? DateTime.MinValue : value == DateTime.MaxValue ? value : value.ToLocalTime ()).ToString (
                                        "yyyy-MM-ddTHH:mm:ss.FFFFFFFzzz",
@@ -808,37 +808,33 @@ namespace System.Xml {
                        
                }
 
-               public static string VerifyNCName (string ncname)
+               public static string VerifyNCName (string name)
                {
-                       if (ncname == null || ncname.Length == 0)
-                               throw new ArgumentNullException("ncname");
+                       if (name == null || name.Length == 0)
+                               throw new ArgumentNullException("name");
 
-                       if (!XmlChar.IsNCName (ncname))
-                               throw new XmlException ("'" + ncname + "' is not a valid XML NCName");
-                       return ncname;
+                       if (!XmlChar.IsNCName (name))
+                               throw new XmlException ("'" + name + "' is not a valid XML NCName");
+                       return name;
                }
 
-#if NET_2_0
-               public static string VerifyTOKEN (string name)
-#else
-               internal static string VerifyTOKEN (string name)
-#endif
+               public static string VerifyTOKEN (string token)
                {
-                       if (name == null)
-                               throw new ArgumentNullException("name");
+                       if (token == null)
+                               throw new ArgumentNullException("token");
 
-                       if (name.Length == 0)
-                               return name;
+                       if (token.Length == 0)
+                               return token;
 
-                       if (XmlChar.IsWhitespace (name [0]) ||
-                               XmlChar.IsWhitespace (name [name.Length - 1]))
+                       if (XmlChar.IsWhitespace (token [0]) ||
+                               XmlChar.IsWhitespace (token [token.Length - 1]))
                                throw new XmlException ("Whitespace characters (#xA, #xD, #x9, #x20) are not allowed as leading or trailing whitespaces of xs:token.");
 
-                       for (int i = 0; i < name.Length; i++)
-                               if (XmlChar.IsWhitespace (name [i]) && name [i] != ' ')
-                               throw new XmlException ("Either #xA, #xD or #x9 are not allowed inside xs:token.");
+                       for (int i = 0; i < token.Length; i++)
+                               if (XmlChar.IsWhitespace (token [i]) && token [i] != ' ')
+                                       throw new XmlException ("Either #xA, #xD or #x9 are not allowed inside xs:token.");
 
-                       return name;
+                       return token;
                }
 
 #if NET_2_0
index 6a9627da2b01927745171e1177a159d2024dcd32..88e18006b0ed57b6c1bfa8af636a601f691d4f82 100644 (file)
@@ -722,7 +722,7 @@ namespace System.Xml
                        Load (vr);
                }
 
-               public virtual void Load (XmlReader xmlReader)
+               public virtual void Load (XmlReader reader)
                {
                        // Reset our document
                        // For now this just means removing all our children but later this
@@ -730,20 +730,20 @@ namespace System.Xml
                        // like properties we have, etc.
                        RemoveAll ();
 
-                       this.baseURI = xmlReader.BaseURI;
+                       this.baseURI = reader.BaseURI;
                        // create all contents with use of ReadNode()
                        try {
                                loadMode = true;
                                do {
-                                       XmlNode n = ReadNode (xmlReader);
+                                       XmlNode n = ReadNode (reader);
                                        if (n == null)
                                                break;
                                        if (preserveWhitespace || n.NodeType != XmlNodeType.Whitespace)
                                                AppendChild (n, false);
-                               } while (xmlReader.NodeType != XmlNodeType.EndElement);
+                               } while (reader.NodeType != XmlNodeType.EndElement);
 #if NET_2_0
-                               if (xmlReader.Settings != null)
-                                       schemas = xmlReader.Settings.Schemas;
+                               if (reader.Settings != null)
+                                       schemas = reader.Settings.Schemas;
 #endif
                        } finally {
                                loadMode = false;
@@ -1069,24 +1069,24 @@ namespace System.Xml
                        xmlWriter.Flush ();
                }
 
-               public virtual void Save (XmlWriter xmlWriter)
+               public virtual void Save (XmlWriter w)
                {
                        //
                        // This should preserve white space if PreserveWhiteSpace is true
                        //
                        bool autoXmlDecl = FirstChild != null && FirstChild.NodeType != XmlNodeType.XmlDeclaration;
                        if (autoXmlDecl)
-                               xmlWriter.WriteStartDocument ();
-                       WriteContentTo (xmlWriter);
+                               w.WriteStartDocument ();
+                       WriteContentTo (w);
                        if (autoXmlDecl)
-                               xmlWriter.WriteEndDocument ();
-                       xmlWriter.Flush ();
+                               w.WriteEndDocument ();
+                       w.Flush ();
                }
 
-               public override void WriteContentTo (XmlWriter w)
+               public override void WriteContentTo (XmlWriter xw)
                {
                        for (XmlNode n = FirstChild; n != null; n = n.NextSibling)
-                               n.WriteTo (w);
+                               n.WriteTo (xw);
                }
 
                public override void WriteTo (XmlWriter w)
@@ -1122,16 +1122,15 @@ namespace System.Xml
                }
 
 #if NET_2_0
-               public void Validate (ValidationEventHandler handler)
+               public void Validate (ValidationEventHandler validationEventHandler)
                {
-                       Validate (handler, this,
+                       Validate (validationEventHandler, this,
                                XmlSchemaValidationFlags.ProcessIdentityConstraints);
                }
 
-               public void Validate (ValidationEventHandler handler,
-                       XmlNode node)
+               public void Validate (ValidationEventHandler validationEventHandler, XmlNode nodeToValidate)
                {
-                       Validate (handler, node,
+                       Validate (validationEventHandler, nodeToValidate,
                                XmlSchemaValidationFlags.ProcessIdentityConstraints);
                }
 
index 7451e4f249d908260c5822b43a75325887160114..3e715d46a00b08a15362527c56e4c0551ce63a29 100644 (file)
@@ -41,8 +41,8 @@ namespace System.Xml
 
                #region Constructor
 
-               protected internal XmlDocumentFragment (XmlDocument doc)
-                       : base (doc)
+               protected internal XmlDocumentFragment (XmlDocument ownerDocument)
+                       : base (ownerDocument)
                {
                }
                
index 1a3067b8ff2363849da509a90fffdfdbdf3c31cf..c62fe4f986a1abed4d0cf807d40a430c421d05cf 100644 (file)
@@ -38,14 +38,9 @@ namespace System.Xml
                {
                }
 
-#if NET_2_0
-               public
-#else
-               internal
-#endif
-               XmlImplementation (XmlNameTable nameTable)
+               public XmlImplementation (XmlNameTable nt)
                {
-                       InternalNameTable = nameTable;
+                       InternalNameTable = nt;
                }
                #endregion
 
index 31d533271f835e8cfc8c4cc5e4888aa2c2437278..beb986072edffd57989359c4f654b536ccfd755b 100644 (file)
@@ -33,9 +33,9 @@ namespace System.Xml
 {
        public abstract class XmlNameTable
        {
-               public abstract string Add (string name);
-               public abstract string Add (char [] buffer, int offset, int length);
-               public abstract string Get (string name);
-               public abstract string Get (char [] buffer, int offset, int length);
+               public abstract string Add (string array);
+               public abstract string Add (char [] array, int offset, int length);
+               public abstract string Get (string array);
+               public abstract string Get (char [] array, int offset, int length);
        }
 }
index 4c58656206c0631b2efe20965c4403144beee22e..da549157f1d5d46617da0f39a9412cac11007079 100644 (file)
@@ -271,13 +271,13 @@ namespace System.Xml
                }
 #endif
 
-               public override void MoveToAttribute (int i)
+               public override void MoveToAttribute (int attributeIndex)
                {
                        if (entity != null && entityInsideAttribute) {
                                entity.Close ();
                                entity = null;
                        }
-                       Current.MoveToAttribute (i);
+                       Current.MoveToAttribute (attributeIndex);
                        insideAttribute = true;
                }
 
@@ -295,11 +295,11 @@ namespace System.Xml
                        return true;
                }
 
-               public override bool MoveToAttribute (string localName, string namespaceURI)
+               public override bool MoveToAttribute (string name, string namespaceURI)
                {
                        if (entity != null && !entityInsideAttribute)
-                               return entity.MoveToAttribute (localName, namespaceURI);
-                       if (!source.MoveToAttribute (localName, namespaceURI))
+                               return entity.MoveToAttribute (name, namespaceURI);
+                       if (!source.MoveToAttribute (name, namespaceURI))
                                return false;
                        if (entity != null && entityInsideAttribute) {
                                entity.Close ();
@@ -374,60 +374,57 @@ namespace System.Xml
                }
 
 #if NET_2_0
-               public override int ReadContentAsBase64 (
-                       byte [] buffer, int offset, int length)
+               public override int ReadContentAsBase64 (byte [] buffer, int index, int count)
                {
 //                     return base.ReadContentAsBase64 (
 //                             buffer, offset, length);
                        // FIXME: This is problematic wrt end of entity.
                        if (entity != null)
                                return entity.ReadContentAsBase64 (
-                                       buffer, offset, length);
+                                       buffer, index, count);
                        else
                                return source.ReadContentAsBase64 (
-                                       buffer, offset, length);
+                                       buffer, index, count);
                }
 
-               public override int ReadContentAsBinHex (
-                       byte [] buffer, int offset, int length)
+               public override int ReadContentAsBinHex (byte [] buffer, int index, int count)
                {
 //                     return base.ReadContentAsBinHex (
 //                             buffer, offset, length);
                        // FIXME: This is problematic wrt end of entity.
                        if (entity != null)
                                return entity.ReadContentAsBinHex (
-                                       buffer, offset, length);
+                                       buffer, index, count);
                        else
                                return source.ReadContentAsBinHex (
-                                       buffer, offset, length);
+                                       buffer, index, count);
                }
 
-               public override int ReadElementContentAsBase64 (
-                       byte [] buffer, int offset, int length)
+               public override int ReadElementContentAsBase64 (byte [] buffer, int index, int count)
                {
 //                     return base.ReadElementContentAsBase64 (
-//                             buffer, offset, length);
+//                             buffer, index, count);
                        // FIXME: This is problematic wrt end of entity.
                        if (entity != null)
                                return entity.ReadElementContentAsBase64 (
-                                       buffer, offset, length);
+                                       buffer, index, count);
                        else
                                return source.ReadElementContentAsBase64 (
-                                       buffer, offset, length);
+                                       buffer, index, count);
                }
 
                public override int ReadElementContentAsBinHex (
-                       byte [] buffer, int offset, int length)
+                       byte [] buffer, int index, int count)
                {
 //                     return base.ReadElementContentAsBinHex (
-//                             buffer, offset, length);
+//                             buffer, index, count);
                        // FIXME: This is problematic wrt end of entity.
                        if (entity != null)
                                return entity.ReadElementContentAsBinHex (
-                                       buffer, offset, length);
+                                       buffer, index, count);
                        else
                                return source.ReadElementContentAsBinHex (
-                                       buffer, offset, length);
+                                       buffer, index, count);
                }
 #endif
 
index f5434ec7cf396e1989a8a4124e24459f2e63a7f4..38f195aaba659aef4a104828f59a556b5a158e03 100644 (file)
@@ -274,34 +274,34 @@ namespace System.Xml
                                XmlNodeType.Document;
                }
 
-               public static XmlReader Create (Stream stream)
+               public static XmlReader Create (Stream input)
                {
-                       return Create (stream, null);
+                       return Create (input, null);
                }
 
-               public static XmlReader Create (string url)
+               public static XmlReader Create (string inputUri)
                {
-                       return Create (url, null);
+                       return Create (inputUri, null);
                }
 
-               public static XmlReader Create (TextReader reader)
+               public static XmlReader Create (TextReader input)
                {
-                       return Create (reader, null);
+                       return Create (input, null);
                }
 
-               public static XmlReader Create (string url, XmlReaderSettings settings)
+               public static XmlReader Create (string inputUri, XmlReaderSettings settings)
                {
-                       return Create (url, settings, null);
+                       return Create (inputUri, settings, null);
                }
 
-               public static XmlReader Create (Stream stream, XmlReaderSettings settings)
+               public static XmlReader Create (Stream input, XmlReaderSettings settings)
                {
-                       return Create (stream, settings, String.Empty);
+                       return Create (input, settings, String.Empty);
                }
 
-               public static XmlReader Create (TextReader reader, XmlReaderSettings settings)
+               public static XmlReader Create (TextReader input, XmlReaderSettings settings)
                {
-                       return Create (reader, settings, String.Empty);
+                       return Create (input, settings, String.Empty);
                }
 
                static XmlReaderSettings PopulateSettings (XmlReaderSettings src)
@@ -312,17 +312,17 @@ namespace System.Xml
                                return src.Clone ();
                }
 
-               public static XmlReader Create (Stream stream, XmlReaderSettings settings, string baseUri)
+               public static XmlReader Create (Stream input, XmlReaderSettings settings, string baseUri)
                {
                        settings = PopulateSettings (settings);
-                       return Create (stream, settings,
+                       return Create (input, settings,
                                PopulateParserContext (settings, baseUri));
                }
 
-               public static XmlReader Create (TextReader reader, XmlReaderSettings settings, string baseUri)
+               public static XmlReader Create (TextReader input, XmlReaderSettings settings, string baseUri)
                {
                        settings = PopulateSettings (settings);
-                       return Create (reader, settings,
+                       return Create (input, settings,
                                PopulateParserContext (settings, baseUri));
                }
 
@@ -334,15 +334,15 @@ namespace System.Xml
                        return r;
                }
 
-               public static XmlReader Create (string url, XmlReaderSettings settings, XmlParserContext context)
+               public static XmlReader Create (string inputUri, XmlReaderSettings settings, XmlParserContext inputContext)
                {
                        settings = PopulateSettings (settings);
                        bool closeInputBak = settings.CloseInput;
                        try {
                                settings.CloseInput = true; // forced. See XmlReaderCommonTests.CreateFromUrlClose().
-                               if (context == null)
-                                       context = PopulateParserContext (settings, url);
-                               XmlTextReader xtr = new XmlTextReader (false, settings.XmlResolver, url, GetNodeType (settings), context);
+                               if (inputContext == null)
+                                       inputContext = PopulateParserContext (settings, inputUri);
+                               XmlTextReader xtr = new XmlTextReader (false, settings.XmlResolver, inputUri, GetNodeType (settings), inputContext);
                                XmlReader ret = CreateCustomizedTextReader (xtr, settings);
                                return ret;
                        } finally {
@@ -350,20 +350,20 @@ namespace System.Xml
                        }
                }
 
-               public static XmlReader Create (Stream stream, XmlReaderSettings settings, XmlParserContext context)
+               public static XmlReader Create (Stream input, XmlReaderSettings settings, XmlParserContext inputContext)
                {
                        settings = PopulateSettings (settings);
-                       if (context == null)
-                               context = PopulateParserContext (settings, String.Empty);
-                       return CreateCustomizedTextReader (new XmlTextReader (stream, GetNodeType (settings), context), settings);
+                       if (inputContext == null)
+                               inputContext = PopulateParserContext (settings, String.Empty);
+                       return CreateCustomizedTextReader (new XmlTextReader (input, GetNodeType (settings), inputContext), settings);
                }
 
-               public static XmlReader Create (TextReader reader, XmlReaderSettings settings, XmlParserContext context)
+               public static XmlReader Create (TextReader input, XmlReaderSettings settings, XmlParserContext inputContext)
                {
                        settings = PopulateSettings (settings);
-                       if (context == null)
-                               context = PopulateParserContext (settings, String.Empty);
-                       return CreateCustomizedTextReader (new XmlTextReader (context.BaseURI, reader, GetNodeType (settings), context), settings);
+                       if (inputContext == null)
+                               inputContext = PopulateParserContext (settings, String.Empty);
+                       return CreateCustomizedTextReader (new XmlTextReader (inputContext.BaseURI, input, GetNodeType (settings), inputContext), settings);
                }
 
                private static XmlReader CreateCustomizedTextReader (XmlTextReader reader, XmlReaderSettings settings)
@@ -464,7 +464,11 @@ namespace System.Xml
 #endif
                }
 
-               void IDisposable.Dispose ()
+#if NET_4_0 || MOBILE
+               public void Dispose ()
+#else
+               void IDisposable.Dispose() 
+#endif
                {
                        Dispose (false);
                }
@@ -480,18 +484,16 @@ namespace System.Xml
 
                public abstract string GetAttribute (string name);
 
-               public abstract string GetAttribute (
-                       string localName,
-                       string namespaceName);
+               public abstract string GetAttribute (string name, string namespaceURI);
 
-               public static bool IsName (string s)
+               public static bool IsName (string str)
                {
-                       return s != null && XmlChar.IsName (s);
+                       return str != null && XmlChar.IsName (str);
                }
 
-               public static bool IsNameToken (string s)
+               public static bool IsNameToken (string str)
                {
-                       return s != null && XmlChar.IsNmToken (s);
+                       return str != null && XmlChar.IsNmToken (str);
                }
 
                public virtual bool IsStartElement ()
@@ -507,12 +509,12 @@ namespace System.Xml
                        return (Name == name);
                }
 
-               public virtual bool IsStartElement (string localName, string namespaceName)
+               public virtual bool IsStartElement (string localname, string ns)
                {
                        if (!IsStartElement ())
                                return false;
 
-                       return (LocalName == localName && NamespaceURI == namespaceName);
+                       return (LocalName == localname && NamespaceURI == ns);
                }
 
                public abstract string LookupNamespace (string prefix);
@@ -532,9 +534,7 @@ namespace System.Xml
 
                public abstract bool MoveToAttribute (string name);
 
-               public abstract bool MoveToAttribute (
-                       string localName,
-                       string namespaceName);
+               public abstract bool MoveToAttribute (string name, string ns);
 
                private bool IsContent (XmlNodeType nodeType)
                {
@@ -642,7 +642,7 @@ namespace System.Xml
                        return result;
                }
 
-               public virtual string ReadElementString (string localName, string namespaceName)
+               public virtual string ReadElementString (string localname, string ns)
                {
                        if (MoveToContent () != XmlNodeType.Element) {
                                string error = String.Format ("'{0}' is an invalid node type.",
@@ -650,7 +650,7 @@ namespace System.Xml
                                throw XmlError (error);
                        }
 
-                       if (localName != LocalName || NamespaceURI != namespaceName) {
+                       if (localname != LocalName || NamespaceURI != ns) {
                                string error = String.Format ("The {0} tag from namespace {1} is expected.",
                                                              LocalName, NamespaceURI);
                                throw XmlError (error);
@@ -756,7 +756,7 @@ namespace System.Xml
                        Read ();
                }
 
-               public virtual void ReadStartElement (string localName, string namespaceName)
+               public virtual void ReadStartElement (string localname, string ns)
                {
                        if (MoveToContent () != XmlNodeType.Element) {
                                string error = String.Format ("'{0}' is an invalid node type.",
@@ -764,9 +764,9 @@ namespace System.Xml
                                throw XmlError (error);
                        }
 
-                       if (localName != LocalName || NamespaceURI != namespaceName) {
+                       if (localname != LocalName || NamespaceURI != ns) {
                                string error = String.Format ("Expecting {0} tag from namespace {1}, got {2} and {3} instead",
-                                                             localName, namespaceName,
+                                                             localname, ns,
                                                              LocalName, NamespaceURI);
                                throw XmlError (error);
                        }
@@ -979,30 +979,30 @@ namespace System.Xml
                        return ReadContentAs (ValueType, null);
                }
 
-               public virtual object ReadElementContentAs (Type type, IXmlNamespaceResolver resolver)
+               public virtual object ReadElementContentAs (Type returnType, IXmlNamespaceResolver namespaceResolver)
                {
                        bool isEmpty = IsEmptyElement;
                        ReadStartElement ();
-                       object obj = ValueAs (isEmpty ? String.Empty : ReadContentString (false), type, resolver, false);
+                       object obj = ValueAs (isEmpty ? String.Empty : ReadContentString (false), returnType, namespaceResolver, false);
                        if (!isEmpty)
                                ReadEndElement ();
                        return obj;
                }
 
-               public virtual object ReadElementContentAs (Type type, IXmlNamespaceResolver resolver, string localName, string namespaceURI)
+               public virtual object ReadElementContentAs (Type returnType, IXmlNamespaceResolver namespaceResolver, string localName, string namespaceURI)
                {
                        bool isEmpty = IsEmptyElement;
                        ReadStartElement (localName, namespaceURI);
                        if (isEmpty)
-                               return ValueAs (String.Empty, type, resolver, false);
-                       object obj = ReadContentAs (type, resolver);
+                               return ValueAs (String.Empty, returnType, namespaceResolver, false);
+                       object obj = ReadContentAs (returnType, namespaceResolver);
                        ReadEndElement ();
                        return obj;
                }
 
-               public virtual object ReadContentAs (Type type, IXmlNamespaceResolver resolver)
+               public virtual object ReadContentAs (Type returnType, IXmlNamespaceResolver namespaceResolver)
                {
-                       return ValueAs (ReadContentString (), type, resolver, false);
+                       return ValueAs (ReadContentString (), returnType, namespaceResolver, false);
                }
 
                private object ValueAs (string text, Type type, IXmlNamespaceResolver resolver, bool isArrayItem)
@@ -1279,35 +1279,35 @@ namespace System.Xml
                }
 
                public virtual int ReadContentAsBase64 (
-                       byte [] buffer, int offset, int length)
+                       byte [] buffer, int index, int count)
                {
                        CheckSupport ();
                        return binary.ReadContentAsBase64 (
-                               buffer, offset, length);
+                               buffer, index, count);
                }
 
                public virtual int ReadContentAsBinHex (
-                       byte [] buffer, int offset, int length)
+                       byte [] buffer, int index, int count)
                {
                        CheckSupport ();
                        return binary.ReadContentAsBinHex (
-                               buffer, offset, length);
+                               buffer, index, count);
                }
 
                public virtual int ReadElementContentAsBase64 (
-                       byte [] buffer, int offset, int length)
+                       byte [] buffer, int index, int count)
                {
                        CheckSupport ();
                        return binary.ReadElementContentAsBase64 (
-                               buffer, offset, length);
+                               buffer, index, count);
                }
 
                public virtual int ReadElementContentAsBinHex (
-                       byte [] buffer, int offset, int length)
+                       byte [] buffer, int index, int count)
                {
                        CheckSupport ();
                        return binary.ReadElementContentAsBinHex (
-                               buffer, offset, length);
+                               buffer, index, count);
                }
 
                private void CheckSupport ()
@@ -1321,19 +1321,13 @@ namespace System.Xml
                
 #endif
 
-#if NET_2_0
-               public virtual int ReadValueChunk (
-                       char [] buffer, int offset, int length)
-#else
-               internal virtual int ReadValueChunk (
-                       char [] buffer, int offset, int length)
-#endif
+               public virtual int ReadValueChunk (char [] buffer, int index, int count)
                {
                        if (!CanReadValueChunk)
                                throw new NotSupportedException ();
                        if (binary == null)
                                binary = new XmlReaderBinarySupport (this);
-                       return binary.ReadValueChunk (buffer, offset, length);
+                       return binary.ReadValueChunk (buffer, index, count);
                }
 
                public abstract void ResolveEntity ();
index b258b23e0d8828080fb12fcf6d83e165044d7c80..eb7c3b74fc8640a5492d55d77172b6862bfef5de 100644 (file)
@@ -58,7 +58,7 @@ namespace System.Xml
                private ValidationType validationType;
 #endif
                private XmlResolver xmlResolver;
-#if NET_4_0 || MOONLIGHT
+#if NET_4_0 || NET_2_1
                private DtdProcessing dtdProcessing;
 #endif
                private long maxCharactersFromEntities;
@@ -116,7 +116,7 @@ namespace System.Xml
                        get { return conformance; }
                        set { conformance = value; }
                }
-#if NET_4_0 || MOONLIGHT
+#if NET_4_0 || NET_2_1
                public DtdProcessing DtdProcessing {
                        get { return dtdProcessing; }
                        set {
@@ -161,6 +161,9 @@ namespace System.Xml
                        set { linePositionOffset = value; }
                }
 
+#if NET_4_0
+               [ObsoleteAttribute("Use DtdProcessing property instead")]
+#endif
                public bool ProhibitDtd {
                        get { return prohibitDtd; }
                        set { prohibitDtd = value; }
index 356873a61e207da9fa661e916df5ac37408e3624..8949225d3bbfdb06b05ccf43892feaf68983e5d3 100644 (file)
@@ -42,10 +42,7 @@ namespace System.Xml
                public abstract ICredentials Credentials { set; }
 #endif
 
-               public abstract object GetEntity (
-                       Uri absoluteUri,
-                       string role,
-                       Type type);
+               public abstract object GetEntity (Uri absoluteUri, string role, Type ofObjectToReturn);
 
                [PermissionSet (SecurityAction.InheritanceDemand, Unrestricted = true)]
                public virtual Uri ResolveUri (Uri baseUri, string relativeUri)
index 008a22366d6a0977d125cc285795a8db2b275fcf..8abbfeb9e6540756349c87a629bde4472c6d3ad1 100644 (file)
@@ -277,6 +277,7 @@ namespace Mono.Xml
                        if (settings == null)
                                settings = new XmlWriterSettings ();
 
+                       newline_handling = settings.NewLineHandling;
                        Initialize (writer);
 
                        close_output_stream = closeOutput;
@@ -309,7 +310,6 @@ namespace Mono.Xml
                        indent_attributes = settings.NewLineOnAttributes;
 
                        check_character_validity = settings.CheckCharacters;
-                       newline_handling = settings.NewLineHandling;
                        namespace_handling = settings.NamespaceHandling;
                }
 #endif
@@ -331,7 +331,9 @@ namespace Mono.Xml
                                new char [] {'&', '<', '>', '\r', '\n'} :
                                new char [] {'&', '<', '>'};
                        escaped_attr_chars =
-                               new char [] {'"', '&', '<', '>', '\r', '\n'};
+                               newline_handling != NewLineHandling.None ?
+                               new char [] {'"', '&', '<', '>', '\r', '\n', '\t'} :
+                               new char [] {'"', '&', '<', '>' };
                }
 
 #if NET_2_0
@@ -1454,30 +1456,43 @@ namespace Mono.Xml
                                        if (isAttribute && text [i] == quote_char)
                                                goto case '&';
                                        continue;
+                               case '\t':
+                                       if(isAttribute
+                                          && newline_handling != NewLineHandling.None) {
+                                               if (start < i)
+                                                       WriteCheckedBuffer (text, start, i - start);
+                                               writer.Write ("&#x9;");
+                                       } else
+                                               continue;
+                                       break;
                                case '\r':
-                                       if (i + 1 < end && text [i] == '\n')
-                                               i++; // CRLF
-                                       goto case '\n';
                                case '\n':
+                                       // If no translation was requested, don't change
+                                       // anything.
+                                       if(newline_handling == NewLineHandling.None)
+                                               continue;
+                                       // \n is left alone in text if entitizing.
+                                       if(!isAttribute
+                                          && newline_handling == NewLineHandling.Entitize
+                                          && text [i] == '\n')
+                                               continue;
                                        if (start < i)
                                                WriteCheckedBuffer (text, start, i - start);
-                                       if (isAttribute) {
-                                               writer.Write (text [i] == '\r' ?
-                                                       "&#xD;" : "&#xA;");
-                                               break;
-                                       }
-                                       switch (newline_handling) {
-                                       case NewLineHandling.Entitize:
+                                       // Both newline characters in attributes are fully
+                                       // entitized for both Entitize and Replace.
+                                       if(isAttribute
+                                          || newline_handling == NewLineHandling.Entitize) {
                                                writer.Write (text [i] == '\r' ?
                                                        "&#xD;" : "&#xA;");
                                                break;
-                                       case NewLineHandling.Replace:
-                                               writer.Write (newline);
-                                               break;
-                                       default:
-                                               writer.Write (text [i]);
-                                               break;
                                        }
+                                       // By this point the requested behavior must be
+                                       // Replace, and the text must not be an attribute
+                                       // value.  CR, LF and CRLF all get converted to
+                                       // the configured newline sequence.
+                                       if (text [i] == '\r' && i + 1 < end && text [i + 1] == '\n')
+                                               i++; // CRLF
+                                       writer.Write (newline);
                                        break;
                                }
                                start = i + 1;
index 066e762b79260b91849fd5997e71d1c36ca9f85d..22278787b47d45796240576045c22c9c54a94a3b 100755 (executable)
@@ -184,7 +184,11 @@ namespace System.Xml
                        Close ();
                }
 
-               void IDisposable.Dispose ()
+#if NET_4_0 || MOBILE
+               public void Dispose ()
+#else
+               void IDisposable.Dispose() 
+#endif
                {
                        Dispose (false);
                }
index e5e29639980eed16eefe89fcffcad06a1b686b47..141f9f3d4785dc8db4d9b102662fcff2ffa7e5ba 100644 (file)
@@ -17,7 +17,7 @@ using NUnit.Framework;
 namespace MonoTests.System.Xml
 {
        [TestFixture]
-       public class XmlSchemaCollectionTests : Assertion
+       public class XmlSchemaCollectionTests
        {
                private XmlSchema GetSchema (string path)
                {
@@ -66,10 +66,10 @@ namespace MonoTests.System.Xml
                public void TestAddDoesCompilation ()
                {
                        XmlSchema schema = new XmlSchema ();
-                       Assert (!schema.IsCompiled);
+                       Assert.IsFalse (schema.IsCompiled);
                        XmlSchemaCollection col = new XmlSchemaCollection ();
                        col.Add (schema);
-                       Assert (schema.IsCompiled);
+                       Assert.IsTrue (schema.IsCompiled);
                }
 
                [Test] // bug #75126
@@ -115,8 +115,8 @@ namespace MonoTests.System.Xml
                        schemas.Add (schema2);
                        schemas.Add (schema1);
 
-                       Assert ("#1", schema1.IsCompiled);
-                       Assert ("#2", schema2.IsCompiled);
+                       Assert.IsTrue (schema1.IsCompiled, "#1");
+                       Assert.IsTrue (schema2.IsCompiled, "#2");
                }
        }
 }
index 88072c55f5dc45245ab7d5a03864256244c6eb89..a69c1045b76d41422c6d01e68d3ea06347ea102a 100644 (file)
@@ -19,7 +19,7 @@ using NUnit.Framework;
 namespace MonoTests.System.XmlSerialization
 {
        [TestFixture]
-       public class ComplexDataStructure: Assertion
+       public class ComplexDataStructure
        {
                [Test]
                [NUnit.Framework.Category("NotDotNet")] // FDBK50639 
@@ -42,7 +42,7 @@ namespace MonoTests.System.XmlSerialization
                        sr.Close ();
                        
                        expected = XmlSerializerTests.Infoset (expected);
-                       AssertEquals (expected, serialized);
+                       Assert.AreEqual (expected, serialized);
                }
                
                [Test]
@@ -213,12 +213,12 @@ namespace MonoTests.System.XmlSerialization
                
                void CheckObjectContent (Test exp, Test t)
                {
-                       AssertEquals ("t.a", exp.a, t.a);
-                       AssertEquals ("t.b", exp.b, t.b);
-                       AssertEquals ("t.bbis", exp.bbis, t.bbis);
-                       AssertEquals ("t.c", exp.c, t.c);
+                       Assert.AreEqual (exp.a, t.a, "t.a");
+                       Assert.AreEqual (exp.b, t.b, "t.b");
+                       Assert.AreEqual (exp.bbis, t.bbis, "t.bbis");
+                       Assert.AreEqual (exp.c, t.c, "t.c");
                        
-                       AssertNotNull ("t.parts", t.parts);
+                       Assert.IsNotNull (t.parts, "t.parts");
                        CheckParts ("t.parts", exp.parts, t.parts);
                        
                        TestPart.AssertEquals ("t.part", exp.part, t.part);
@@ -228,24 +228,24 @@ namespace MonoTests.System.XmlSerialization
                        
                        TA.AssertEquals ("t.ta", exp.ta, t.ta);
 
-                       AssertNotNull ("t.tam2", t.tam2);
+                       Assert.IsNotNull (t.tam2, "t.tam2");
                        CheckTaArray ("t.tam2", exp.tam2, t.tam2);
                        
-                       AssertNotNull ("t.tam3", t.tam3);
+                       Assert.IsNotNull (t.tam3, "t.tam3");
                        CheckTaArray ("t.tam3", exp.tam3, t.tam3);
                        
-                       AssertNotNull ("t.flatParts", t.flatParts);
+                       Assert.IsNotNull (t.flatParts, "t.flatParts");
                        CheckParts ("t.flatParts", exp.flatParts, t.flatParts);
 
                        // Null element is ignored
-                       AssertNotNull ("t.flatParts2", t.flatParts2);
-                       AssertEquals ("t.flatParts2.Length", 3, t.flatParts2.Length);
+                       Assert.IsNotNull (t.flatParts2, "t.flatParts2");
+                       Assert.AreEqual (3, t.flatParts2.Length, "t.flatParts2.Length");
                        TA.AssertEquals ("t.flatParts2 0", exp.flatParts2[0], t.flatParts2[0]);
                        TA.AssertEquals ("t.flatParts2 1", exp.flatParts2[1], t.flatParts2[1]);
                        TA.AssertEquals ("t.flatParts2 2", exp.flatParts2[3], t.flatParts2[2]);
                        
-                       AssertNotNull ("t.anot", t.anot);
-                       AssertEquals ("t.anot.lo", ((AnotherTestPart)exp.anot).lo, ((AnotherTestPart)t.anot).lo);
+                       Assert.IsNotNull (t.anot, "t.anot");
+                       Assert.AreEqual (((AnotherTestPart)exp.anot).lo, ((AnotherTestPart)t.anot).lo, "t.anot.lo");
 
                        TestPart.AssertEquals ("t.ob", exp.ob as TestPart, t.ob as TestPart);
                        TestPart.AssertEquals ("t.ob2", exp.ob2 as TestPart, t.ob2 as TestPart);
@@ -254,18 +254,18 @@ namespace MonoTests.System.XmlSerialization
                        AssertionHelper.AssertEqualsXml ("t.oneElem2", exp.oneElem2, t.oneElem2);
                        
                        // One of the elements was null and it is ignored
-                       AssertNotNull ("t.someElems", t.someElems);
-                       AssertEquals ("t.someElems.Length", 2, t.someElems.Length);
+                       Assert.IsNotNull (t.someElems, "t.someElems");
+                       Assert.AreEqual (2, t.someElems.Length, "t.someElems.Length");
                        AssertionHelper.AssertEqualsXml ("t.someElems[0]", exp.someElems[0], t.someElems[0]);
                        AssertionHelper.AssertEqualsXml ("t.someElems[1]", exp.someElems[2], t.someElems[1]);
 
-                       AssertNotNull ("t.extraElems", t.extraElems);
-                       AssertEquals ("t.extraElems.Length", exp.extraElems.Length, t.extraElems.Length);
+                       Assert.IsNotNull (t.extraElems, "t.extraElems");
+                       Assert.AreEqual (exp.extraElems.Length, t.extraElems.Length, "t.extraElems.Length");
                        for (int n=0; n<exp.extraElems.Length; n++)
                                AssertionHelper.AssertEqualsXml ("t.extraElems[" + n + "]", exp.extraElems[n], t.extraElems[n]);
                        
-                       AssertNotNull ("t.extraElems23", t.extraElems23);
-                       AssertEquals ("t.extraElems23.Length", exp.extraElems23.Length, t.extraElems23.Length);
+                       Assert.IsNotNull (t.extraElems23, "t.extraElems23");
+                       Assert.AreEqual (exp.extraElems23.Length, t.extraElems23.Length, "t.extraElems23.Length");
                        for (int n=0; n<t.extraElems23.Length; n++)
                                AssertionHelper.AssertEqualsXml ("t.extraElems23[" + n + "]", exp.extraElems23[n], t.extraElems23[n]);
                        
@@ -273,59 +273,59 @@ namespace MonoTests.System.XmlSerialization
                        
                        UnknownAttributeTester.AssertEquals ("t.uktester", exp.uktester, t.uktester);
 
-                       AssertEquals ("t.ob3", exp.ob3, t.ob3);
-                       AssertEquals ("t.ob4", exp.ob4, t.ob4);
-                       AssertEquals ("t.op1", exp.op1, t.op1);
+                       Assert.AreEqual (exp.ob3, t.ob3, "t.ob3");
+                       Assert.AreEqual (exp.ob4, t.ob4, "t.ob4");
+                       Assert.AreEqual (exp.op1, t.op1, "t.op1");
                        
                        AssertionHelper.AssertEqualsArray ("t.opArray", exp.opArray, t.opArray);
 
-                       AssertEquals ("t.ukOpt", exp.ukOpt, t.ukOpt);
-                       AssertEquals ("t.opAtt", exp.opAtt, t.opAtt);
+                       Assert.AreEqual (exp.ukOpt, t.ukOpt, "t.ukOpt");
+                       Assert.AreEqual (exp.opAtt, t.opAtt, "t.opAtt");
 
                        AssertionHelper.AssertEqualsArray ("t.byteArray", exp.byteArray, t.byteArray);
                        AssertionHelper.AssertEqualsArray ("t.byteByteArray", exp.byteByteArray, t.byteByteArray);
                        
-                       AssertNotNull ("t.ttList", t.ttList);
+                       Assert.IsNotNull (t.ttList, "t.ttList");
                        AssertionHelper.AssertEqualsArray ("t.ttList", exp.ttList.ToArray(), t.ttList.ToArray());
                        
-                       AssertNotNull ("t.RoList", t.RoList);
-                       AssertEquals ("t.RoList.Count", exp.RoList.Count, t.RoList.Count);
+                       Assert.IsNotNull (t.RoList, "t.RoList");
+                       Assert.AreEqual (exp.RoList.Count, t.RoList.Count, "t.RoList.Count");
                        for (int n=0; n<exp.RoList.Count; n++)
                                TestPart.AssertEquals ("t.RoList " + n, (TestPart)exp.RoList[n], (TestPart)t.RoList[n]);
                        
-                       AssertEquals ("t.struc.aa", exp.struc.aa, t.struc.aa);
-                       AssertEquals ("t.struc.cc", exp.struc.cc, t.struc.cc);
+                       Assert.AreEqual (exp.struc.aa, t.struc.aa, "t.struc.aa");
+                       Assert.AreSame (exp.struc.cc, t.struc.cc, "t.struc.cc");
 
-                       AssertNotNull ("t.multiList", t.multiList);
-                       AssertEquals ("t.multiList.Count", exp.multiList.Length, t.multiList.Length);
+                       Assert.IsNotNull (t.multiList, "t.multiList");
+                       Assert.AreEqual (exp.multiList.Length, t.multiList.Length, "t.multiList.Count");
                        for (int n=0; n<exp.multiList.Length; n++)
                                AssertionHelper.AssertEqualsArray ("t.multiList " + n, exp.multiList[n].ToArray(), t.multiList[n].ToArray());
                        
-                       AssertEquals ("t.defElem", exp.defElem, t.defElem);
-                       AssertEquals ("t.defAttr", exp.defAttr, t.defAttr);
+                       Assert.AreEqual (exp.defElem, t.defElem, "t.defElem");
+                       Assert.AreEqual (exp.defAttr, t.defAttr, "t.defAttr");
 
                        CustomHashtable.AssertEquals ("t.special", exp.special, t.special);
 
-                       AssertEquals ("t.attqname", exp.attqname, t.attqname);
+                       Assert.AreEqual (exp.attqname, t.attqname, "t.attqname");
 
-                       AssertNotNull ("t.dbscontainer", t.dbscontainer);
+                       Assert.IsNotNull (t.dbscontainer, "t.dbscontainer");
                        DblStringContainer tdbca = t.dbscontainer.at as DblStringContainer;
                        DblStringContainer expdbca = exp.dbscontainer.at as DblStringContainer;
-                       AssertNotNull ("t.dbscontainer.at", tdbca);
+                       Assert.IsNotNull (tdbca, "t.dbscontainer.at");
                        
-                       AssertNotNull ("t.dbscontainer.dbca", tdbca);
+                       Assert.IsNotNull (tdbca, "t.dbscontainer.dbca");
                        AssertionHelper.AssertEqualsArray ("t.dbscontainer.at.doublestring", expdbca.doublestring, tdbca.doublestring);
                        
                        AnotherTestPart tat = tdbca.at as AnotherTestPart;
                        AnotherTestPart expat = expdbca.at as AnotherTestPart;
-                       AssertNotNull ("t.dbscontainer.dbca.at", tat);
-                       AssertEquals ("t.dbscontainer.dbca.at.lo", expat.lo, tat.lo);
+                       Assert.IsNotNull (tat, "t.dbscontainer.dbca.at");
+                       Assert.AreEqual (expat.lo, tat.lo, "t.dbscontainer.dbca.at.lo");
                }
                
                void CheckParts (string id, TestPart[] exp, TestPart[] parts)
                {
                        AssertionHelper.AssertType (id, exp, parts);
-                       AssertEquals (id + " Len", exp.Length, parts.Length);
+                       Assert.AreEqual (exp.Length, parts.Length, id + " Len");
                        for (int n=0; n<exp.Length; n++)
                                TestPart.AssertEquals (id + "[" + n + "]", exp[n], parts[n]);
                }
@@ -333,14 +333,14 @@ namespace MonoTests.System.XmlSerialization
                void CheckTaArray (string id, TA[][][] exp, TA[][][] arr)
                {
                        AssertionHelper.AssertType (id, exp, arr);
-                       AssertEquals (id + " Len", exp.Length, arr.Length);
+                       Assert.AreEqual (exp.Length, arr.Length, id + " Len");
                        for (int n=0; n<exp.Length; n++)
                        {
                                TA[][] tar = arr[n];
                                TA[][] expar = exp[n];
                                
                                AssertionHelper.AssertType (id, expar, tar);
-                               AssertEquals (expar.Length, tar.Length);
+                               Assert.AreEqual (expar.Length, tar.Length);
                                
                                for (int m=0; m<expar.Length; m++)
                                {
@@ -348,7 +348,7 @@ namespace MonoTests.System.XmlSerialization
                                        TA[] expar2 = expar[m];
                                        
                                        AssertionHelper.AssertType (id, expar2, tar2);
-                                       AssertEquals (id, expar2.Length, tar2.Length);
+                                       Assert.AreEqual (expar2.Length, tar2.Length, id);
                                        
                                        for (int i=0; i<expar2.Length; i++)
                                                TA.AssertEquals (id + "[" + n + "][" + m + "][" + i + "]", expar2[i], tar2[i]);
@@ -362,12 +362,12 @@ namespace MonoTests.System.XmlSerialization
                public static bool AssertType (string id, object exp, object ob)
                {
                        if (exp == null) {
-                               Assertion.AssertNull (id, ob);
+                               Assert.IsNull (ob, id);
                                return false;
                        }
                        else {
-                               Assertion.AssertNotNull (id, ob);
-                               Assertion.AssertEquals (id + " type", exp.GetType(), ob.GetType());
+                               Assert.IsNotNull (ob, id);
+                               Assert.AreEqual (exp.GetType(), ob.GetType(), id + " type");
                                return true;
                        }
                }
@@ -375,19 +375,19 @@ namespace MonoTests.System.XmlSerialization
                public static void AssertEqualsXml (string id, XmlNode exp, XmlNode ob)
                {
                        if (!AssertType (id, exp, ob)) return;
-                       Assertion.AssertEquals (id, XmlSerializerTests.Infoset (exp), XmlSerializerTests.Infoset (ob));
+                       Assert.AreEqual (XmlSerializerTests.Infoset (exp), XmlSerializerTests.Infoset (ob), id);
                }
                
                public static void AssertEqualsArray (string id, Array exp, Array ob)
                {
                        if (!AssertType (id, exp, ob)) return;
-                       Assertion.AssertEquals (id + " Length", exp.GetLength(0), ob.GetLength(0));
+                       Assert.AreEqual (exp.GetLength(0), ob.GetLength(0), id + " Length");
                        for (int n=0; n<exp.GetLength(0); n++) {
                                object it = exp.GetValue(n);
                                if (it is Array) 
                                        AssertEqualsArray (id + "[" + n + "]", it as Array, ob.GetValue(n) as Array);
                                else
-                                       Assertion.AssertEquals (id + "[" + n + "]", it, ob.GetValue(n));
+                                       Assert.AreEqual (it, ob.GetValue(n), id + "[" + n + "]");
                        }
                }
        }
@@ -579,7 +579,7 @@ namespace MonoTests.System.XmlSerialization
                public static void AssertEquals (string id, TA expected, TA ob)
                {
                        if (!AssertionHelper.AssertType (id, expected, ob)) return;
-                       Assertion.AssertEquals (id + " xx", expected.xx, ob.xx);
+                       Assert.AreEqual (expected.xx, ob.xx, id + " xx");
                        // TODO: extraTextNodes
                }
        }
@@ -591,7 +591,7 @@ namespace MonoTests.System.XmlSerialization
                public static void AssertEquals (string id, TB expected, TB ob)
                {
                        if (!AssertionHelper.AssertType (id, expected, ob)) return;
-                       Assertion.AssertEquals (id + " yy", expected.yy, ob.yy);
+                       Assert.AreEqual (expected.yy, ob.yy, id + " yy");
                        TA.AssertEquals (id + " base", expected, ob);
                }
        }
@@ -613,7 +613,7 @@ namespace MonoTests.System.XmlSerialization
                public static void AssertEquals (string id, UnknownAttributeTester exp, UnknownAttributeTester ob)
                {
                        if (!AssertionHelper.AssertType (id, exp, ob)) return;
-                       Assertion.AssertEquals (id + " aa", exp.aa, ob.aa);
+                       Assert.AreEqual (exp.aa, ob.aa, id + " aa");
                        
                        if (!AssertionHelper.AssertType (id + " extraAtts", exp.extraAtts, ob.extraAtts)) return;
                        
@@ -622,7 +622,7 @@ namespace MonoTests.System.XmlSerialization
                        {
                                XmlAttribute at = ob.extraAtts [n];
                                if (at.NamespaceURI == "http://www.w3.org/2000/xmlns/") continue;
-                               Assertion.Assert (id + " extraAtts length", p < exp.extraAtts.Length);
+                               Assert.IsTrue (p < exp.extraAtts.Length, id + " extraAtts length");
                                AssertionHelper.AssertEqualsXml (id + ".extraAtts " + n, exp.extraAtts [p], ob.extraAtts[n]);
                                p++;
                        }
@@ -639,8 +639,8 @@ namespace MonoTests.System.XmlSerialization
                public static void AssertEquals (string id, TestPart expected, TestPart ob)
                {
                        if (!AssertionHelper.AssertType (id, expected, ob)) return;
-                       Assertion.AssertEquals (id + " name", expected.name, ob.name);
-                       Assertion.AssertEquals (id + " bval", expected.bval, ob.bval);
+                       Assert.AreEqual (expected.name, ob.name, id + " name");
+                       Assert.AreEqual (expected.bval, ob.bval, id + " bval");
                }
        }
 
@@ -690,10 +690,10 @@ namespace MonoTests.System.XmlSerialization
                        if (!AssertionHelper.AssertType (id, exp, ob)) return;
                        if (!AssertionHelper.AssertType (id, exp.data, ob.data)) return;
                        
-                       Assertion.AssertEquals (id + " data Count", exp.data.Count, ob.data.Count);
+                       Assert.AreEqual (exp.data.Count, ob.data.Count, id + " data Count");
                        
                        foreach (DictionaryEntry entry in exp.data)
-                               Assertion.AssertEquals (entry.Value, ob.data[entry.Key]);
+                               Assert.AreEqual (entry.Value, ob.data[entry.Key]);
                }
                
                public void ReadXml (XmlReader reader)
index 62d3e27ccf8ae796ec48b25c0fe270b3f906a2b4..b2843765a640a368875b29684f010119e9fe9ee4 100644 (file)
@@ -1480,5 +1480,70 @@ namespace MonoTests.System.XmlSerialization
                        Assert.AreEqual (DateTime.MinValue, o.FancyDateTime, "#1");
                        Assert.AreEqual (0, o.Numeric, "#2");
                }
+               
+               [Test] // bug bxc 4367
+               public void SpecifiedXmlIgnoreTest ()
+               {
+                       XmlReflectionMember [] out_members = new XmlReflectionMember [2];
+                       XmlReflectionMember m;
+                       
+                       m = new XmlReflectionMember ();
+                       m.IsReturnValue = false;
+                       m.MemberName = "HasPermissionsForUserResult";
+                       m.MemberType = typeof (bool);
+                       m.SoapAttributes = new SoapAttributes ();
+                       m.XmlAttributes = new XmlAttributes ();
+                       out_members [0] = m;
+                       
+                       m = new XmlReflectionMember ();
+                       m.IsReturnValue = false;
+                       m.MemberName = "HasPermissionsForUserResultSpecified";
+                       m.MemberType = typeof (bool);
+                       m.SoapAttributes = new SoapAttributes ();
+                       m.XmlAttributes = new XmlAttributes ();
+                       m.XmlAttributes.XmlIgnore = true;
+                       out_members [1] = m;
+                       
+                       XmlReflectionImporter xmlImporter = new XmlReflectionImporter ();
+                       XmlMembersMapping OutputMembersMapping = xmlImporter.ImportMembersMapping ("HasPermissionsForUserResponse", "http://tempuri.org", out_members, true);
+                       XmlSerializer xmlSerializer = XmlSerializer.FromMappings (new XmlMapping [] { OutputMembersMapping }) [0];
+                       
+                       Assert.AreEqual (2, OutputMembersMapping.Count, "#count");
+                       
+                       string msg = @"
+                       <HasPermissionsForUserResponse xmlns=""http://tempuri.org/"">
+                               <HasPermissionsForUserResult>true</HasPermissionsForUserResult>
+                       </HasPermissionsForUserResponse>
+                       ";
+                       
+                       object res = xmlSerializer.Deserialize (new StringReader (msg));
+                       Assert.AreEqual (typeof (object[]), res.GetType (), "type");
+                       Assert.AreEqual (2, ((object[]) res).Length, "length");
+               }
+               
+               [Test]
+               public void InvalidNullableTypeTest ()
+               {
+                       XmlReflectionMember [] out_members = new XmlReflectionMember [1];
+                       XmlReflectionMember m;
+                       
+                       m = new XmlReflectionMember ();
+                       m.IsReturnValue = false;
+                       m.MemberName = "HasPermissionsForUserResultSpecified";
+                       m.MemberType = typeof (bool);
+                       m.SoapAttributes = new SoapAttributes ();
+                       m.XmlAttributes = new XmlAttributes ();
+                       m.XmlAttributes.XmlIgnore = true;
+                       m.XmlAttributes.XmlElements.Add (new XmlElementAttribute () { IsNullable = true });
+                       out_members [0] = m;
+                       
+                       XmlReflectionImporter xmlImporter = new XmlReflectionImporter ();
+                       
+                       try {
+                               xmlImporter.ImportMembersMapping ("HasPermissionsForUserResponse", "http://tempuri.org", out_members, true);
+                               Assert.Fail ("Expected InvalidOperationException");
+                       } catch (InvalidOperationException) {
+                       }
+               }
        }
 }
index 893f354d48f2a75eeefb19703996014d13d2c8dd..9cf534f2012fd87cf1d55ac7ac0238af9e865885 100644 (file)
@@ -10,6 +10,7 @@
 using System;
 using System.IO;
 using System.Text;
+using System.Reflection;
 using System.Xml;
 using System.Xml.Schema;
 using System.Xml.Serialization;
@@ -113,5 +114,20 @@ namespace MonoTests.System.XmlSerialization
                        } catch (InvalidOperationException ex) {
                        }
                }
+               
+               [Test]
+               public void XmlIgnore ()
+               {
+                       FieldInfo field = GetType ().GetField ("XmlIgnoreField");
+                       XmlAttributes atts = new XmlAttributes (field);
+                       Assert.AreEqual (true, atts.XmlIgnore, "#1");
+                       Assert.AreEqual (0, atts.XmlElements.Count, "#2");
+                       Assert.AreEqual (0, atts.XmlAnyElements.Count, "#3");
+               }
+               
+               [XmlIgnore]
+               [XmlElement (IsNullable = true)]
+               [XmlAnyElement]
+               public int XmlIgnoreField;
        }
 }
index 1c2a24ab259c98cf59bd0e7760340bbe37f894da..0982fd9ef185ba320b366dbae80583ef9f9a0c45 100644 (file)
@@ -303,6 +303,79 @@ namespace MonoTests.System.Xml
 <root />";
                        Assert.AreEqual (xml, sw.ToString ().Replace ("\r\n", "\n"), "#1");
                }
+
+               [Test]
+               public void NewlineHandlingNone ()
+               {
+                       var sw = new StringWriter ();
+                       var xw = XmlWriter.Create (sw, new XmlWriterSettings () { NewLineHandling = NewLineHandling.None });
+                       xw.WriteStartElement("root");
+                       xw.WriteElementString("element", "lf\ncr\rcrlf\r\nht\t");
+                       xw.WriteStartElement("element");
+                       xw.WriteAttributeString("attr", "lf\ncr\rcrlf\r\nht\t");
+                       xw.WriteEndElement();
+                       xw.WriteEndElement();
+                       xw.Close();
+                       string xml = "<?xml version=\"1.0\" encoding=\"utf-16\"?><root><element>lf\ncr\rcrlf\r\nht\t</element><element attr=\"lf\ncr\rcrlf\r\nht\t\" /></root>";
+                       Assert.AreEqual (xml, sw.ToString ());
+               }
+
+               [Test]
+               public void NewlineHandlingReplace ()
+               {
+                       var sw = new StringWriter ();
+                       var xw = XmlWriter.Create (sw, new XmlWriterSettings () { 
+                                       NewLineHandling = NewLineHandling.Replace,
+                                       NewLineChars = "\n"
+                       });
+                       xw.WriteStartElement("root");
+                       xw.WriteElementString("element", "lf\ncr\rcrlf\r\nht\t");
+                       xw.WriteStartElement("element");
+                       xw.WriteAttributeString("attr", "lf\ncr\rcrlf\r\nht\t");
+                       xw.WriteEndElement();
+                       xw.WriteEndElement();
+                       xw.Close();
+                       string xml = "<?xml version=\"1.0\" encoding=\"utf-16\"?><root><element>lf\ncr\ncrlf\nht\t</element><element attr=\"lf&#xA;cr&#xD;crlf&#xD;&#xA;ht&#x9;\" /></root>";
+                       Assert.AreEqual (xml, sw.ToString ());
+               }
+
+               [Test]
+               public void NewlineHandlingReplaceCRLF ()
+               {
+                       var sw = new StringWriter ();
+                       var xw = XmlWriter.Create (sw, new XmlWriterSettings () { 
+                                       NewLineHandling = NewLineHandling.Replace,
+                                       NewLineChars = "\r\n"
+                       });
+                       xw.WriteStartElement("root");
+                       xw.WriteElementString("element", "lf\ncr\rcrlf\r\nht\t");
+                       xw.WriteStartElement("element");
+                       xw.WriteAttributeString("attr", "lf\ncr\rcrlf\r\nht\t");
+                       xw.WriteEndElement();
+                       xw.WriteEndElement();
+                       xw.Close();
+                       string xml = "<?xml version=\"1.0\" encoding=\"utf-16\"?><root><element>lf\r\ncr\r\ncrlf\r\nht\t</element><element attr=\"lf&#xA;cr&#xD;crlf&#xD;&#xA;ht&#x9;\" /></root>";
+                       Assert.AreEqual (xml, sw.ToString ());
+               }
+
+               [Test]
+               public void NewlineHandlingEntitize ()
+               {
+                       var sw = new StringWriter ();
+                       var xw = XmlWriter.Create (sw, new XmlWriterSettings () { 
+                                       NewLineHandling = NewLineHandling.Entitize,
+                                       NewLineChars = "\n"
+                       });
+                       xw.WriteStartElement("root");
+                       xw.WriteElementString("element", "lf\ncr\rcrlf\r\nht\t");
+                       xw.WriteStartElement("element");
+                       xw.WriteAttributeString("attr", "lf\ncr\rcrlf\r\nht\t");
+                       xw.WriteEndElement();
+                       xw.WriteEndElement();
+                       xw.Close();
+                       string xml = "<?xml version=\"1.0\" encoding=\"utf-16\"?><root><element>lf\ncr&#xD;crlf&#xD;\nht\t</element><element attr=\"lf&#xA;cr&#xD;crlf&#xD;&#xA;ht&#x9;\" /></root>";
+                       Assert.AreEqual (xml, sw.ToString ());
+               }
        }
 }
 #endif
index 05592f22911613d2b614e9d9c3224d4014db5a5c..458410154b693dcf3511bf452c81d30bc8a1df51 100644 (file)
@@ -80,6 +80,7 @@ Mono.Xml/XmlNodeWriter.cs
 System.Xml/ConformanceLevel.cs
 System.Xml/DTDAutomata.cs
 System.Xml/DTDObjectModel.cs
+System.Xml/DtdProcessing.cs
 System.Xml/DTDReader.cs
 System.Xml/DTDValidatingReader2.cs
 System.Xml/DefaultXmlWriter.cs
index 4396fb4f38c61e5913151da0bd827034868f9b6a..cdc77157b773c75f20bce6002c01b1af00890df8 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 43f36ed08dfc0d3de5d3e9dfe29e0f324d70d32a..e3e6aaa32b39fe20e13fc0e6182c4cbad3384788 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index c933da4332bc30e6f0b0e63bca850b8aa343e630..9f1593a605ab925ada5a35215f57a61c072d73fe 100644 (file)
@@ -91,7 +91,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 4cf7e4d72bad649be1311689a6590bc741231568..608fc5644c698dbe7eb57b34f13598930d6b501d 100644 (file)
@@ -91,7 +91,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index ab180a3e9e2c83d77f7123473975149b453212f8..436cf13a23b3b168471243ab9c6e65cfb10e27bd 100644 (file)
@@ -85,7 +85,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index a654f6f15eb14ce93a49ac7dc00444e0390930c9..30f0456ff41030e5f56a0c4bd7a36d2eeeef03a1 100644 (file)
@@ -85,7 +85,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 7b5b89c7cf45ecabdcf74eb1a06100bc09b579bb..e3aea615d9a20d1efe8fa34a3ef3f1c099efdca3 100644 (file)
@@ -85,7 +85,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1a877483d43c23d8bc75320a83a1bbf067e462e4..082fd3562a3b0eba07ebab15459fb03170c93fee 100644 (file)
@@ -71,7 +71,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 3a817579a4e542868d8adf8e0f93f7c9e7264cb2..2678f7184a3edecfcaa181877f057419ac97dcd1 100644 (file)
@@ -71,7 +71,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f70b9360b1b0f445253894f1ad2454b63099397f..9952e7e44e7179348bbe789d777458c7bb19b017 100644 (file)
@@ -71,7 +71,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d8a0ad6dd37e475341d501704f3f4d3a33230a81..ea785e9168e03e91c0716637a08835f58d50bc07 100644 (file)
@@ -236,12 +236,10 @@ namespace System.Xml.Linq
 
                public override void WriteTo (XmlWriter w)
                {
-                       if (xmldecl != null) {
-                               if (xmldecl.Standalone != null)
-                                       w.WriteStartDocument (xmldecl.Standalone == "yes");
-                               else
-                                       w.WriteStartDocument ();
-                       }
+                       if (xmldecl != null && xmldecl.Standalone != null)
+                               w.WriteStartDocument (xmldecl.Standalone == "yes");
+                       else
+                               w.WriteStartDocument ();
                        foreach (XNode node in Nodes ())
                                node.WriteTo (w);
                }
index 408b3a8574660e8c784650af46e9bd89e3b0eb66..eb379a1d503234cbbc63531f91046b99c673d29f 100644 (file)
@@ -655,7 +655,7 @@ namespace System.Xml.Linq
 
                string LookupPrefix (string ns, XmlWriter w)
                {
-                       string prefix = ns.Length > 0 ? w.LookupPrefix (ns) : String.Empty;
+                       string prefix = ns.Length > 0 ? GetPrefixOfNamespace (ns) ?? w.LookupPrefix (ns) : String.Empty;
                        foreach (XAttribute a in Attributes ()) {
                                if (a.IsNamespaceDeclaration && a.Value == ns) {
                                        if (a.Name.Namespace == XNamespace.Xmlns)
@@ -666,25 +666,27 @@ namespace System.Xml.Linq
                        }
                        return prefix;
                }
+               
+               static string CreateDummyNamespace (ref int createdNS, IEnumerable<XAttribute> atts)
+               {
+                       string p = null;
+                       do {
+                               p = "p" + (++createdNS);
+                               // check conflict
+                               if (atts.All (a => a.Name.LocalName != p))
+                                       break;
+                       } while (true);
+                       return p;
+               }
 
                public override void WriteTo (XmlWriter w)
                {
                        // some people expect the same prefix output as in input,
                        // in the loss of performance... see bug #466423.
-                       int createdNS = 0;
                        string prefix = LookupPrefix (name.NamespaceName, w);
-                       Func<string> nsCreator = () => {
-                               string p = null;
-                               do {
-                                       p = "p" + (++createdNS);
-                                       // check conflict
-                                       if (Attributes ().All (a => a.Name.LocalName != p))
-                                               break;
-                               } while (true);
-                               return p;
-                               };
+                       int createdNS = 0;
                        if (prefix == null)
-                               prefix = nsCreator ();
+                               prefix = CreateDummyNamespace (ref createdNS, Attributes ());
 
                        w.WriteStartElement (prefix, name.LocalName, name.Namespace.NamespaceName);
 
@@ -697,7 +699,7 @@ namespace System.Xml.Linq
                                } else {
                                        string apfix = LookupPrefix (a.Name.NamespaceName, w);
                                        if (apfix == null)
-                                               apfix = nsCreator ();
+                                               apfix = CreateDummyNamespace (ref createdNS, Attributes ());
                                        w.WriteAttributeString (apfix, a.Name.LocalName, a.Name.Namespace.NamespaceName, a.Value);
                                }
                        }
@@ -772,9 +774,10 @@ namespace System.Xml.Linq
                public void SetElementValue (XName name, object value)
                {
                        var element = Element (name);
-                       if (element == null) {
-                               element = new XElement (name, value);
-                               Add (element);
+                       if (element == null && value != null) {
+                               Add (new XElement (name, value));
+                       } else if (element != null && value == null) {
+                               element.Remove ();
                        } else
                                element.SetValue (value);
                }
index b79d362a772a5838008434187a7230fac91b678c..84cb492334cf8ffe9c05502aac3e32e9ebd328f2 100644 (file)
@@ -336,7 +336,7 @@ namespace System.Xml.Linq
                public override bool MoveToNext ()
                {
                        XNode xn = node.NextNode;
-                       if (node is XText)
+                       if (xn is XText)
                                for (; xn != null; xn = xn.NextNode)
                                        if (!(xn.NextNode is XText))
                                                break;
@@ -413,8 +413,12 @@ namespace System.Xml.Linq
 
                public override void MoveToRoot ()
                {
-                       node = node.Document ?? node;
                        attr = null;
+                       if (node.Document != null)
+                               node = node.Document;
+                       else
+                               while (node.Owner != null)
+                                       node = node.Owner;
                }
        }
 }
index 5d5a843df4ef9edb2efdb170ba35a1fafe29df37..7a1fbcb06b562f02e609230c4d96d7fd46c1ec57 100644 (file)
@@ -112,5 +112,19 @@ namespace MonoTests.System.Xml.Linq
                        var doc = new XDocument ();
                        doc.Add (new XAttribute ("foo", " "));
                }
+               
+               [Test] // bug #4850
+               public void AddXmlDeclarationEvenForDecllessDoc ()
+               {
+                       var doc = new XDocument (
+                               new XElement ("resources",
+                                       new XElement ("string",
+                                               new XAttribute ("name", "whatever"),
+                                               "This is sparta")));
+                       var sw = new StringWriter ();
+                       using (var writer = new XmlTextWriter (sw))
+                               doc.WriteTo (writer);
+                       Assert.IsTrue (sw.ToString ().StartsWith ("<?xml"), "#1");
+               }
        }
 }
index 2c4691310180d3c811f7e66d515d0439eb2556dc..3a89e1299e3bf7982c06bc3c4363d17f93f0d075 100644 (file)
@@ -1668,6 +1668,9 @@ namespace MonoTests.System.Xml.Linq
                        element.SetElementValue ("gaz", "gazonk");
 
                        Assert.AreEqual ("<foo><bar>babar</bar><baz>babaz</baz><gaz>gazonk</gaz></foo>", element.ToString (SaveOptions.DisableFormatting));
+
+                       element.SetElementValue ("gaz", null);
+                       Assert.AreEqual ("<foo><bar>babar</bar><baz>babaz</baz></foo>", element.ToString (SaveOptions.DisableFormatting));
                }
 
                [Test]
@@ -1704,5 +1707,20 @@ namespace MonoTests.System.Xml.Linq
                                Thread.CurrentThread.CurrentCulture = bak;
                        }
                }
+               
+               [Test] // bug #3972
+               public void UseGetPrefixOfNamespaceForToString ()
+               {
+                       string xml = @"
+                       <xsi:Event
+                         xsi1:type='xsi:SubscriptionEvent'
+                         xmlns:xsi='http://relevo.se/xsi'
+                         xmlns:xsi1='http://www.w3.org/2001/XMLSchema-instance'>
+                         <xsi:eventData xsi1:type='xsi:CallSubscriptionEvent'/>
+                       </xsi:Event>";
+                       var e = XElement.Parse (xml);
+                       string expected = @"<xsi:eventData xsi1:type='xsi:CallSubscriptionEvent' xmlns:xsi1='http://www.w3.org/2001/XMLSchema-instance' xmlns:xsi='http://relevo.se/xsi' />".Replace ('\'', '"');
+                       Assert.AreEqual (expected, e.Nodes ().First ().ToString (), "#1");
+               }
        }
 }
index c0694df42d1e48d2cbb8bb419ce3e420621fe660..329abee447a059f4697e4e535219361665ae5e58 100644 (file)
@@ -74,5 +74,28 @@ namespace MonoTests.System.Xml.Linq
                        XElement xeOldRef = xeOldOwner.XPathSelectElement(xpathOld);
                        Assert.AreEqual ("<objsur t='o' guid='06974d9a-ff86-4e1c-a3e5-7ce8c961dcb9' />".Replace ('\'', '"'), xeOldRef.ToString (), "#1");
                }
+
+               [Test]
+               public void Bug4739 ()
+               {
+                       string data = "<root><parent>A<child>B</child>C</parent></root>";
+                       XElement doc = XElement.Parse (data);
+                       var iterator = doc.CreateNavigator ().Select ("//parent/child");
+                       iterator.MoveNext ();
+                       var element = iterator.Current;
+                       Assert.AreEqual ("B", element.InnerXml);
+               }
+
+               [Test]
+               public void MoveToRoot_Bug4690 ()
+               {
+                       string data = "<root><parent><child/></parent></root>";
+                       XElement doc = XElement.Parse (data);
+                       var iterator = doc.CreateNavigator ().Select ("//child");
+                       iterator.MoveNext ();
+                       var element = iterator.Current;
+                       element.MoveToRoot ();
+                       Assert.AreEqual ("root", element.Name);
+               }
        }
 }
index a6ec552db4ea84bf94cd6d2eb3e4ec317b801e6c..a565b594ac3e93a2465b749adc11a3b0c2d3db5f 100644 (file)
@@ -73,7 +73,7 @@ using System.Runtime.InteropServices;
        [assembly: InternalsVisibleTo ("System.Net, PublicKey=00240000048000009400000006020000002400005253413100040000010001008D56C76F9E8649383049F383C44BE0EC204181822A6C31CF5EB7EF486944D032188EA1D3920763712CCB12D75FB77E9811149E6148E5D32FBAAB37611C1878DDC19E20EF135D0CB2CFF2BFEC3D115810C3D9069638FE4BE215DBF795861920E5AB6F7DB2E2CEEF136AC23D5DD2BF031700AEC232F6C6B1C785B4305C123B37AB")]
 #else
        [assembly: InternalsVisibleTo ("System.ComponentModel.DataAnnotations, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]
-       [assembly: InternalsVisibleTo ("System.Net.Http, PublicKey=00000000000000000400000000000000")]
+       [assembly: InternalsVisibleTo ("System.Net.Http, PublicKey=002400000480000094000000060200000024000052534131000400000100010007d1fa57c4aed9f0a32e84aa0faefd0de9e8fd6aec8f87fb03766c834c99921eb23be79ad9d5dcc1dd9ad236132102900b723cf980957fc4e177108fc607774f29e8320e92ea05ece4e821c0a5efe8f1645c4c0c93c1ab99285d622caa652c1dfad63d745d6f2de5f17e5eaf0fc4963d261c8a12436518206dc093344d5ad293")]
        [assembly: StringFreezing]
        [assembly: DefaultDependency (LoadHint.Always)]
 #endif
index c2ace9b4c1329e6aa5c1e0eef41a310db53b7a79..c366874de7cd1443c4ad86588e23d363f2e59ce0 100644 (file)
@@ -20,7 +20,7 @@ TEST_RESOURCES = \
        Test/System/test-uri-props-manual.txt \
        Test/System/test-uri-relative-props.txt
 
-TEST_MCS_FLAGS = -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 \
+TEST_MCS_FLAGS = -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 \
        $(foreach f, $(TEST_RESOURCES), -resource:$(f),$(notdir $(f)))
 
 ifneq (1, $(FRAMEWORK_VERSION_MAJOR))
index 1423cbda1b46d83b910b9b3fc230abfe7e48876c..1883afe7ed93218122f6af01e3eadf2cf4017c72 100644 (file)
@@ -78,7 +78,7 @@ namespace Mono.CSharp
                                if (!File.Exists (windowsMonoPath))
                                        throw new FileNotFoundException ("Windows mono path not found: " + windowsMonoPath);
 
-                               windowsMcsPath = Path.Combine (p, "4.0\\mcs.exe");
+                               windowsMcsPath = Path.Combine (p, "4.5\\mcs.exe");
                                if (!File.Exists (windowsMcsPath))
                                        windowsMcsPath = Path.Combine(Path.GetDirectoryName (p), "lib\\build\\mcs.exe");
                                
index 17bb14597b293bf53e511ad0122d9ae538ece385..e5d9e5e7e669b6fa293eed9d2037467b419084eb 100644 (file)
@@ -4,6 +4,7 @@
 // Author:
 //   Daniel Stodden (stodden@in.tum.de)
 //   Marek Safar (marek.safar@seznam.cz)
+//   Ilker Cetinkaya (mail@ilker.de)
 //
 // (C) 2002 Ximian, Inc.
 //
@@ -171,18 +172,36 @@ namespace Mono.CSharp
                {
                        GenerateCompileUnitStart (compileUnit);
 
+                       GenerateGlobalNamespace (compileUnit);
+
                        if (compileUnit.AssemblyCustomAttributes.Count > 0) {
                                OutputAttributes (compileUnit.AssemblyCustomAttributes, 
                                        "assembly: ", false);
                                Output.WriteLine ("");
                        }
 
-                       foreach (CodeNamespace ns in compileUnit.Namespaces)
-                               GenerateNamespace (ns);
+                       GenerateLocalNamespaces (compileUnit);
 
                        GenerateCompileUnitEnd (compileUnit);
                }
 
+               private void GenerateGlobalNamespace (CodeCompileUnit compileUnit) {
+                       CodeNamespace globalNamespace = null;
+
+                       foreach (CodeNamespace codeNamespace in compileUnit.Namespaces)
+                               if (string.IsNullOrEmpty (codeNamespace.Name)) 
+                                       globalNamespace = codeNamespace;
+  
+                       if (globalNamespace != null)
+                               GenerateNamespace (globalNamespace);
+               }
+
+               private void GenerateLocalNamespaces (CodeCompileUnit compileUnit) {
+                       foreach (CodeNamespace codeNamespace in compileUnit.Namespaces)
+                               if (!string.IsNullOrEmpty (codeNamespace.Name))
+                                       GenerateNamespace (codeNamespace);
+               }
+
                protected override void GenerateDefaultValueExpression (CodeDefaultValueExpression e)
                {
                        Output.Write ("default(");
@@ -1385,14 +1404,14 @@ namespace Mono.CSharp
                }
 
                static bool is_identifier_start_character (char c)
-                {
-                        return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || c == '_' || c == '@' || Char.IsLetter (c);
-                }
-
-                static bool is_identifier_part_character (char c)
-                {
-                        return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || c == '_' || (c >= '0' && c <= '9') || Char.IsLetter (c);
-                }
+               {
+                       return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || c == '_' || c == '@' || Char.IsLetter (c);
+               }
+
+               static bool is_identifier_part_character (char c)
+               {
+                       return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || c == '_' || (c >= '0' && c <= '9') || Char.IsLetter (c);
+               }
                
                protected override bool IsValidIdentifier (string identifier)
                {
@@ -1406,13 +1425,13 @@ namespace Mono.CSharp
                                return false;
 
                        if (!is_identifier_start_character (identifier [0]))
-                                return false;
-                        
-                        for (int i = 1; i < identifier.Length; i ++)
-                                if (! is_identifier_part_character (identifier [i]))
-                                        return false;
-                        
-                        return true;
+                               return false;
+
+                       for (int i = 1; i < identifier.Length; i ++)
+                               if (! is_identifier_part_character (identifier [i]))
+                                       return false;
+
+                       return true;
                }
 
                protected override bool Supports (GeneratorSupport supports)
index fac9bcdfeb60b25c8b6e670ff3b99898422eeed4..b2b1bb748acf90de57e2959815784556871a5165 100644 (file)
    <Compile Include="System.Net.Mime\DispositionTypeNames.cs" />
    <Compile Include="System.Net.Mime\MediaTypeNames.cs" />
    <Compile Include="System.Net.Mime\TransferEncoding.cs" />
+   <Compile Include="System.Net\MacProxy.cs" />
    <Compile Include="System.Net\MonoHttpDate.cs" />
    <Compile Include="System.Net\NetConfig.cs" />
    <Compile Include="System.Net\NetworkAccess.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 8cb4cfb71f2d09084ae72d8f9c5986cb8c033215..680ca7ca9ae286a51b3bc17e1fe2c58b849a4b8e 100644 (file)
    <Compile Include="System.Net.Mime\DispositionTypeNames.cs" />
    <Compile Include="System.Net.Mime\MediaTypeNames.cs" />
    <Compile Include="System.Net.Mime\TransferEncoding.cs" />
+   <Compile Include="System.Net\MacProxy.cs" />
    <Compile Include="System.Net\MonoHttpDate.cs" />
    <Compile Include="System.Net\NetConfig.cs" />
    <Compile Include="System.Net\NetworkAccess.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 141e93eee102dc72d0034f235ef9ee52f72eb48f..1fc575f20a2a30b270a666cfb882ecb2ff73e8c3 100644 (file)
    <Compile Include="System.Net.Mime\DispositionTypeNames.cs" />
    <Compile Include="System.Net.Mime\MediaTypeNames.cs" />
    <Compile Include="System.Net.Mime\TransferEncoding.cs" />
+   <Compile Include="System.Net\MacProxy.cs" />
    <Compile Include="System.Net\MonoHttpDate.cs" />
    <Compile Include="System.Net\NetConfig.cs" />
    <Compile Include="System.Net\NetworkAccess.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 86bd1155f261c390a0fe99b2e2a77b3d2e6aece9..d9232f0e5517d81616be32f320706ecb70118eb4 100644 (file)
    <Compile Include="System.Net.Mime\DispositionTypeNames.cs" />
    <Compile Include="System.Net.Mime\MediaTypeNames.cs" />
    <Compile Include="System.Net.Mime\TransferEncoding.cs" />
+   <Compile Include="System.Net\MacProxy.cs" />
    <Compile Include="System.Net\MonoHttpDate.cs" />
    <Compile Include="System.Net\NetConfig.cs" />
    <Compile Include="System.Net\NetworkAccess.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index d0119d8234755422f0cd691d6e3c57d4220f48b7..ab4d0dab0f1f4401dbe02bf0a33c3f9c5af7a28b 100644 (file)
    <Compile Include="Test\System.CodeDom\CodeVariableReferenceExpressionTest.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorFromTypeTestBase.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorOptionsTest.cs" />
+   <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorGenerateFromCompileUnitTest.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorTest.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorTestBase.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\ExecutorTest.cs" />
    <Compile Include="Test\System.Configuration\SettingsPropertyTest.cs" />
    <Compile Include="Test\System.Configuration\SettingsPropertyValueCollectionTest.cs" />
    <Compile Include="Test\System.Configuration\SettingsPropertyValueTest.cs" />
+   <Compile Include="Test\System.Diagnostics\DebugTest.cs" />
    <Compile Include="Test\System.Diagnostics\DelimitedListTraceListenerTest.cs" />
    <Compile Include="Test\System.Diagnostics\EventLogTest.cs" />
    <Compile Include="Test\System.Diagnostics\StopwatchTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\PublicKeyTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X500DistinguishedNameTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509BasicConstraintsExtensionTest.cs" />
+   <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Cert20Test.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Certificate2Test.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509CertificateCollectionTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Certificate2CollectionTest.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Data</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="System.Configuration">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Configuration</HintPath>
index e338340d3efcf6ad46ccaf2eaa67516f5379acc3..2e1368322a1f97f5f75e7457875270bd9735654a 100644 (file)
    <Compile Include="Test\System.CodeDom\CodeVariableReferenceExpressionTest.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorFromTypeTestBase.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorOptionsTest.cs" />
+   <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorGenerateFromCompileUnitTest.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorTest.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorTestBase.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\ExecutorTest.cs" />
    <Compile Include="Test\System.Configuration\SettingsPropertyTest.cs" />
    <Compile Include="Test\System.Configuration\SettingsPropertyValueCollectionTest.cs" />
    <Compile Include="Test\System.Configuration\SettingsPropertyValueTest.cs" />
+   <Compile Include="Test\System.Diagnostics\DebugTest.cs" />
    <Compile Include="Test\System.Diagnostics\DelimitedListTraceListenerTest.cs" />
    <Compile Include="Test\System.Diagnostics\EventLogTest.cs" />
    <Compile Include="Test\System.Diagnostics\StopwatchTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\PublicKeyTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X500DistinguishedNameTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509BasicConstraintsExtensionTest.cs" />
+   <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Cert20Test.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Certificate2Test.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509CertificateCollectionTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Certificate2CollectionTest.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Data</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="System.Configuration">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Configuration</HintPath>
index 8a57393181732e409ca253c8330824230a24eab9..466a06ff15bdad28dac6ac50d91296dc801869b7 100644 (file)
    <Compile Include="Test\System.CodeDom\CodeVariableReferenceExpressionTest.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorFromTypeTestBase.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorOptionsTest.cs" />
+   <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorGenerateFromCompileUnitTest.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorTest.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\CodeGeneratorTestBase.cs" />
    <Compile Include="Test\System.CodeDom.Compiler\ExecutorTest.cs" />
    <Compile Include="Test\System.Configuration\SettingsPropertyTest.cs" />
    <Compile Include="Test\System.Configuration\SettingsPropertyValueCollectionTest.cs" />
    <Compile Include="Test\System.Configuration\SettingsPropertyValueTest.cs" />
+   <Compile Include="Test\System.Diagnostics\DebugTest.cs" />
    <Compile Include="Test\System.Diagnostics\DelimitedListTraceListenerTest.cs" />
    <Compile Include="Test\System.Diagnostics\EventLogTest.cs" />
    <Compile Include="Test\System.Diagnostics\StopwatchTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\PublicKeyTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X500DistinguishedNameTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509BasicConstraintsExtensionTest.cs" />
+   <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Cert20Test.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Certificate2Test.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509CertificateCollectionTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Certificate2CollectionTest.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Data</HintPath>
     </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="System.Configuration">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Configuration</HintPath>
index 773c5b52578d735ef9a5244605a02252083bd937..2a562095ab55d74d7e3e0885d8c7647237a0a585 100644 (file)
@@ -207,6 +207,10 @@ namespace System.CodeDom.Compiler {
                {
                        GenerateCompileUnitStart (compileUnit);
 
+                       foreach (CodeNamespace ns in compileUnit.Namespaces)
+                               if (string.IsNullOrEmpty(ns.Name))
+                                       GenerateNamespace (ns);
+                                     
                        CodeAttributeDeclarationCollection attributes = compileUnit.AssemblyCustomAttributes;
                        if (attributes.Count != 0) {
                                foreach (CodeAttributeDeclaration att in attributes) {
@@ -219,7 +223,8 @@ namespace System.CodeDom.Compiler {
                        }
 
                        foreach (CodeNamespace ns in compileUnit.Namespaces)
-                               GenerateNamespace (ns);
+                               if (!string.IsNullOrEmpty(ns.Name))
+                                       GenerateNamespace (ns);
 
                        GenerateCompileUnitEnd (compileUnit);
                }
index 6e53d250e7a456a236cf835057b40a0d484ed917..9bb3a500e8e31c9275ed6adaa1871a89132b910a 100644 (file)
@@ -76,7 +76,7 @@ namespace System.Diagnostics {
                        TraceImpl.Assert (condition, message, detailMessage);
                }
 
-#if NET_4_0
+#if NET_4_0 || MOBILE
                [Conditional ("DEBUG")]
                public static void Assert (bool condition, string message,
                        string detailMessageFormat, params object [] args)
@@ -185,7 +185,7 @@ namespace System.Diagnostics {
                        TraceImpl.WriteLine (message);
                }
 
-#if NET_4_0
+#if NET_4_0 || MOBILE
                [Conditional("DEBUG")]
                public static void WriteLine (string format, params object [] args)
                {
@@ -231,7 +231,7 @@ namespace System.Diagnostics {
                        TraceImpl.WriteLineIf (condition, message, category);
                }
 
-#if NET_2_0
+#if NET_2_0 || MOBILE
                [Conditional("DEBUG")]
                public static void Print (string message)
                {
index 2ee3a8ee2da09ca0d8eb4755f67f87edbe96ca23..42dce1ffe26e3ddf5a83246e4060c5b34f027c12 100644 (file)
@@ -77,6 +77,11 @@ namespace System.Diagnostics {
                                String trace = Environment.GetEnvironmentVariable("MONO_TRACE_LISTENER");
 #endif
 
+#if MOBILE
+                               if (trace == null)
+                                       trace = ConsoleOutTrace;
+#endif
+
                                if (trace != null) {
                                        string file = null;
                                        string prefix = null;
index 7f8f96d25213d7d261bc40a131c9c95277c8bdc0..72d3cef3f067970aa316a91cf42e7a45ad2e0525 100644 (file)
@@ -118,7 +118,7 @@ namespace System.Diagnostics
                        is_running = false;
                }
 
-#if NET_4_0
+#if NET_4_0 || MOBILE
                public void Restart ()
                {
                        started = GetTimestamp ();
index 265cd6eb60d4c3b456999502657f930dbf367e11..167045711178e4572ebb9eb009c25089764d0277 100644 (file)
@@ -37,6 +37,7 @@ using System.Threading;
 
 namespace System.Diagnostics {
 
+#if !MOBILE
        internal class TraceImplSettings {
                public const string Key = ".__TraceInfoSettingsKey__.";
 
@@ -49,10 +50,13 @@ namespace System.Diagnostics {
                        Listeners.Add (new DefaultTraceListener (), this);
                }
        }
+#endif
 
        internal class TraceImpl {
 
+#if !MOBILE
                private static object initLock = new object ();
+#endif
 
                private static bool autoFlush;
 
@@ -91,6 +95,13 @@ namespace System.Diagnostics {
                {
                }
 
+#if MOBILE
+               static TraceImpl ()
+               {
+                       listeners = new TraceListenerCollection (true);
+               }
+#endif
+
                public static bool AutoFlush {
                        get {
                                InitOnce ();
@@ -151,7 +162,7 @@ namespace System.Diagnostics {
                }
 
                static bool use_global_lock;
-#if NET_2_0
+#if NET_2_0 && !MOBILE
                static CorrelationManager correlation_manager = new CorrelationManager ();
 
                public static CorrelationManager CorrelationManager {
@@ -193,6 +204,7 @@ namespace System.Diagnostics {
                // in the IDictionary returned).
                private static void InitOnce ()
                {
+#if !MOBILE
                        if (initLock != null) {
                                lock (initLock) {
                                        if (listeners == null) {
@@ -209,6 +221,7 @@ namespace System.Diagnostics {
                                }
                                initLock = null;
                        }
+#endif
                }
 
                // FIXME: According to MSDN, this method should display a dialog box
index 873a62343c63dd7e6c17524706b06f0ee1166874..6ce37000c10bc7614089c66d93e7ab0115499d43 100644 (file)
@@ -76,10 +76,12 @@ namespace System.Diagnostics {
                        set { System.Threading.Thread.SetData (_attributesStore, value); }
                }
 
+#if !MOBILE
                private TraceFilter filter {
                        get { return (TraceFilter) System.Threading.Thread.GetData (_filterStore); }
                        set { System.Threading.Thread.SetData (_filterStore, value); }
                }
+#endif
 
                private TraceOptions options {
                        get {
@@ -101,8 +103,10 @@ namespace System.Diagnostics {
 #if NET_2_0
                [ThreadStatic]
                private StringDictionary attributes = new StringDictionary ();
+#if !MOBILE
                [ThreadStatic]
                private TraceFilter filter;
+#endif
                [ThreadStatic]
                private TraceOptions options;
 #endif
@@ -234,6 +238,7 @@ namespace System.Diagnostics {
                        return String.Join (joiner, arr);
                }
 
+#if !MOBILE
                [ComVisible (false)]
                public virtual void TraceData (TraceEventCache eventCache, string source,
                        TraceEventType eventType, int id, object data)
@@ -298,6 +303,7 @@ namespace System.Diagnostics {
                {
                        TraceEvent (eventCache, source, TraceEventType.Transfer, id, String.Format ("{0}, relatedActivityId={1}", message, relatedActivityId));
                }
+#endif
 
                protected internal virtual string [] GetSupportedAttributes ()
                {
@@ -308,11 +314,13 @@ namespace System.Diagnostics {
                        get { return attributes; }
                }
 
+#if !MOBILE
                [ComVisibleAttribute (false)]
                public TraceFilter Filter {
                        get { return filter; }
                        set { filter = value; }
                }
+#endif
 
                [ComVisibleAttribute (false)]
                public TraceOptions TraceOutputOptions {
index d01064be91c0548043f8d1384ce904e2cd85cc82..f2c36d87f9aef9d87ce796f9f40bd7fa1f5710e6 100644 (file)
@@ -109,12 +109,14 @@ namespace System.Diagnostics {
                        return listeners.Add (listener);
                }
 
+#if !MOBILE
                internal void Add (TraceListener listener, TraceImplSettings settings)
                {
                        listener.IndentLevel = settings.IndentLevel;
                        listener.IndentSize  = settings.IndentSize;
                        listeners.Add (listener);
                }
+#endif
 
                private void InitializeListener (TraceListener listener)
                {
index e29aca4722fff3a6da236519f9eecc4219661e76..280082a706a7b008c4ae6a70faa379d082257a5e 100644 (file)
@@ -78,7 +78,9 @@ namespace System.IO.Ports
                                bool dtr_enable, bool rts_enable, Handshake hs, int read_timeout, int write_timeout,
                                int read_buffer_size, int write_buffer_size)
                {
-                       handle = CreateFile (port_name, GenericRead | GenericWrite, 0, 0, OpenExisting,
+                       handle = CreateFile (port_name != null && !port_name.StartsWith(@"\\.\")
+                                       ? @"\\.\" + port_name : port_name,
+                                       GenericRead | GenericWrite, 0, 0, OpenExisting,
                                        FileFlagOverlapped, 0);
 
                        if (handle == -1)
index 50ffae0ea400a18d62036cdcfdef5165ccb8f7f2..25a91d9af32acfc4658317f09608d906a3cd08a0 100644 (file)
@@ -81,7 +81,7 @@ namespace System.Net.Mime {
                        int l = val.Length;
                        if (l >= 2 && val [0] == '"' && val [l - 1] == '"')
                                val = val.Substring (1, l - 2);
-                       parameters.Add (key, val);
+                       parameters [key] = val;
                }
 
                #endregion // Constructors
index 92d2e42df66f147255fa82f4d70c0a781d7687f2..9ff82f5ca6ac6b8eb62ce8a3889c901e5b69252d 100644 (file)
@@ -468,7 +468,7 @@ namespace System.Net.NetworkInformation {
                                                        MacOsStructs.sockaddr_dl sockaddrdl = (MacOsStructs.sockaddr_dl) Marshal.PtrToStructure (addr.ifa_addr, typeof (MacOsStructs.sockaddr_dl));
 
                                                        macAddress = new byte [(int) sockaddrdl.sdl_alen];
-                                                       Array.Copy (sockaddrdl.sdl_data, sockaddrdl.sdl_nlen, macAddress, 0, Math.Min (macAddress.Length, sockaddrdl.sdl_data.Length - macAddress.Length));
+                                                       Array.Copy (sockaddrdl.sdl_data, sockaddrdl.sdl_nlen, macAddress, 0, Math.Min (macAddress.Length, sockaddrdl.sdl_data.Length - sockaddrdl.sdl_nlen));
                                                        index = sockaddrdl.sdl_index;
 
                                                        int hwtype = (int) sockaddrdl.sdl_type;
index ea25e8c5c16bcf52876cbc88373a06a446765ee6..f45f6f8c0716791d2f14c6b0115fb833826ddf40 100644 (file)
@@ -747,6 +747,21 @@ namespace System.Net.Sockets
                        socket_pool_queue (Worker.Dispatcher, req);
                        return(req);
                }
+
+               void CheckRange (byte[] buffer, int offset, int size)
+               {
+                       if (offset < 0)
+                               throw new ArgumentOutOfRangeException ("offset", "offset must be >= 0");
+                               
+                       if (offset > buffer.Length)
+                               throw new ArgumentOutOfRangeException ("offset", "offset must be <= buffer.Length");
+
+                       if (size < 0)                          
+                               throw new ArgumentOutOfRangeException ("size", "size must be >= 0");
+                               
+                       if (size > buffer.Length - offset)
+                               throw new ArgumentOutOfRangeException ("size", "size must be <= buffer.Length - offset");
+               }
                
                public IAsyncResult BeginReceive(byte[] buffer, int offset,
                                                 int size,
@@ -760,11 +775,7 @@ namespace System.Net.Sockets
                        if (buffer == null)
                                throw new ArgumentNullException ("buffer");
 
-                       if (offset < 0 || offset > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset");
-
-                       if (size < 0 || offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buffer, offset, size);
 
                        SocketAsyncResult req = new SocketAsyncResult (this, state, callback, SocketOperation.Receive);
                        req.Buffer = buffer;
@@ -852,14 +863,7 @@ namespace System.Net.Sockets
                        if (remote_end == null)
                                throw new ArgumentNullException ("remote_end");
 
-                       if (offset < 0)
-                               throw new ArgumentOutOfRangeException ("offset", "offset must be >= 0");
-
-                       if (size < 0)
-                               throw new ArgumentOutOfRangeException ("size", "size must be >= 0");
-
-                       if (offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset, size", "offset + size exceeds the buffer length");
+                       CheckRange (buffer, offset, size);
 
                        SocketAsyncResult req = new SocketAsyncResult (this, state, callback, SocketOperation.ReceiveFrom);
                        req.Buffer = buffer;
@@ -892,11 +896,7 @@ namespace System.Net.Sockets
                        if (remoteEP == null)
                                throw new ArgumentNullException ("remoteEP");
 
-                       if (offset < 0 || offset > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset");
-
-                       if (size < 0 || offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buffer, offset, size);
 
                        throw new NotImplementedException ();
                }
@@ -910,14 +910,7 @@ namespace System.Net.Sockets
                        if (buffer == null)
                                throw new ArgumentNullException ("buffer");
 
-                       if (offset < 0)
-                               throw new ArgumentOutOfRangeException ("offset", "offset must be >= 0");
-
-                       if (size < 0)
-                               throw new ArgumentOutOfRangeException ("size", "size must be >= 0");
-
-                       if (offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset, size", "offset + size exceeds the buffer length");
+                       CheckRange (buffer, offset, size);
 
                        if (!connected)
                                throw new SocketException ((int)SocketError.NotConnected);
@@ -1083,14 +1076,7 @@ namespace System.Net.Sockets
                        if (buffer == null)
                                throw new ArgumentNullException ("buffer");
 
-                       if (offset < 0)
-                               throw new ArgumentOutOfRangeException ("offset", "offset must be >= 0");
-
-                       if (size < 0)
-                               throw new ArgumentOutOfRangeException ("size", "size must be >= 0");
-
-                       if (offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset, size", "offset + size exceeds the buffer length");
+                       CheckRange (buffer, offset, size);
 
                        SocketAsyncResult req = new SocketAsyncResult (this, state, callback, SocketOperation.SendTo);
                        req.Buffer = buffer;
@@ -1563,8 +1549,7 @@ namespace System.Net.Sockets
                        if (buffer == null)
                                throw new ArgumentNullException ("buffer");
 
-                       if (size < 0 || size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buffer, 0, size);
 
                        SocketError error;
 
@@ -1587,11 +1572,7 @@ namespace System.Net.Sockets
                        if (buffer == null)
                                throw new ArgumentNullException ("buffer");
 
-                       if (offset < 0 || offset > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset");
-
-                       if (size < 0 || offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buffer, offset, size);
                        
                        SocketError error;
 
@@ -1614,11 +1595,7 @@ namespace System.Net.Sockets
                        if (buffer == null)
                                throw new ArgumentNullException ("buffer");
 
-                       if (offset < 0 || offset > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset");
-
-                       if (size < 0 || offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buffer, offset, size);
                        
                        return Receive_nochecks (buffer, offset, size, flags, out error);
                }
@@ -1722,11 +1699,7 @@ namespace System.Net.Sockets
                        if (remoteEP == null)
                                throw new ArgumentNullException ("remoteEP");
 
-                       if (offset < 0 || offset > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset");
-
-                       if (size < 0 || offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buffer, offset, size);
 
                        return ReceiveFrom_nochecks (buffer, offset, size, flags, ref remoteEP);
                }
@@ -1804,11 +1777,7 @@ namespace System.Net.Sockets
                        if (remoteEP == null)
                                throw new ArgumentNullException ("remoteEP");
 
-                       if (offset < 0 || offset > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset");
-
-                       if (size < 0 || offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buffer, offset, size);
 
                        /* FIXME: figure out how we get hold of the
                         * IPPacketInformation
@@ -1871,8 +1840,7 @@ namespace System.Net.Sockets
                        if (buf == null)
                                throw new ArgumentNullException ("buf");
 
-                       if (size < 0 || size > buf.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buf, 0, size);
 
                        SocketError error;
 
@@ -1892,11 +1860,7 @@ namespace System.Net.Sockets
                        if (buf == null)
                                throw new ArgumentNullException ("buffer");
 
-                       if (offset < 0 || offset > buf.Length)
-                               throw new ArgumentOutOfRangeException ("offset");
-
-                       if (size < 0 || offset + size > buf.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buf, offset, size);
 
                        SocketError error;
 
@@ -1916,11 +1880,7 @@ namespace System.Net.Sockets
                        if (buf == null)
                                throw new ArgumentNullException ("buffer");
 
-                       if (offset < 0 || offset > buf.Length)
-                               throw new ArgumentOutOfRangeException ("offset");
-
-                       if (size < 0 || offset + size > buf.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buf, offset, size);
 
                        return Send_nochecks (buf, offset, size, flags, out error);
                }
@@ -2032,8 +1992,7 @@ namespace System.Net.Sockets
                        if (remote_end == null)
                                throw new ArgumentNullException ("remote_end");
 
-                       if (size < 0 || size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buffer, 0, size);
 
                        return SendTo_nochecks (buffer, 0, size, flags, remote_end);
                }
@@ -2059,11 +2018,7 @@ namespace System.Net.Sockets
                        if (remote_end == null)
                                throw new ArgumentNullException("remote_end");
 
-                       if (offset < 0 || offset > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("offset");
-
-                       if (size < 0 || offset + size > buffer.Length)
-                               throw new ArgumentOutOfRangeException ("size");
+                       CheckRange (buffer, offset, size);
 
                        return SendTo_nochecks (buffer, offset, size, flags, remote_end);
                }
index 2c29b417c9cfb6bd1f3739016131a3b6e5221093..b3888fb1581c24f417e505c54c4423411b41c185 100644 (file)
@@ -130,7 +130,8 @@ namespace System.Net
                
                public void Write (byte [] buffer, int offset, int size)
                {
-                       InternalWrite (buffer, ref offset, size);
+                       if (offset < size)
+                               InternalWrite (buffer, ref offset, size);
                }
                
                void InternalWrite (byte [] buffer, ref int offset, int size)
index 015b8ca1908a02d626a185ebf067bf9c6eb13f1a..5b24159f5e6acaf6cad549ead61b0dbc661d5d4f 100644 (file)
@@ -196,6 +196,7 @@ namespace System.Net {
 
                internal int [] Ports {
                        get { return ports; }
+                       set { ports = value; }
                }
 
                public bool Secure {
index 84e507de60fd0e8c339cba5d5318eb2c10050c63..ccf47b9abf98f7db04f0b4b14bee845201a0a8d9 100644 (file)
@@ -5,10 +5,12 @@
 //     Lawrence Pit (loz@cable.a2000.nl)
 //     Gonzalo Paniagua Javier (gonzalo@ximian.com)
 //     Sebastien Pouliot  <sebastien@ximian.com>
+//  Marek Safar (marek.safar@gmail.com)
 //
 // (c) 2003 Ximian, Inc. (http://www.ximian.com)
 // (c) Copyright 2004 Ximian, Inc. (http://www.ximian.com)
 // Copyright (C) 2009 Novell, Inc (http://www.novell.com)
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
 
 //
 // Permission is hereby granted, free of charge, to any person obtaining
@@ -245,7 +247,7 @@ namespace System.Net
                        }
 
                        if (cookie.Port.Length == 0 && uri != null && !uri.IsDefaultPort) {
-                               cookie.Port = "\"" + uri.Port.ToString () + "\"";
+                               cookie.Ports = new [] { uri.Port };
                        }
                }
 
index 8fb54a4c6c5b139176620bbda6ea5995424b7127..094f8a5f3ebe045df6b2800fb43cc8713d3b4eb7 100644 (file)
@@ -2,9 +2,10 @@
 // System.Net.EndPointListener
 //
 // Author:
-//     Gonzalo Paniagua Javier (gonzalo@novell.com)
+//     Gonzalo Paniagua Javier (gonzalo.mono@gmail.com)
 //
 // Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
+// Copyright (c) 2012 Xamarin, Inc. (http://xamarin.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
@@ -76,7 +77,11 @@ namespace System.Net {
                                string path = Path.Combine (dirname, ".mono");
                                path = Path.Combine (path, "httplistener");
                                string cert_file = Path.Combine (path, String.Format ("{0}.cer", port));
+                               if (!File.Exists (cert_file))
+                                       return;
                                string pvk_file = Path.Combine (path, String.Format ("{0}.pvk", port));
+                               if (!File.Exists (pvk_file))
+                                       return;
                                cert = new X509Certificate2 (cert_file);
                                key = PrivateKey.CreateFromFile (pvk_file).RSA;
                        } catch {
index e90cc39e27eb783243ad0dfa92977eccaea98847..6e7775b5c339105e87d246696bd50b4d3e3c4f92 100644 (file)
@@ -2,9 +2,10 @@
 // System.Net.HttpConnection
 //
 // Author:
-//     Gonzalo Paniagua Javier (gonzalo@novell.com)
+//     Gonzalo Paniagua Javier (gonzalo.mono@gmail.com)
 //
-// Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
+// Copyright (c) 2005-2009 Novell, Inc. (http://www.novell.com)
+// Copyright (c) 2012 Xamarin, Inc. (http://xamarin.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
@@ -61,6 +62,8 @@ namespace System.Net {
                Timer timer;
                IPEndPoint local_ep;
                HttpListener last_listener;
+               int [] client_cert_errors;
+               X509Certificate2 client_cert;
 
                public HttpConnection (Socket sock, EndPointListener epl, bool secure, X509Certificate2 cert, AsymmetricAlgorithm key)
                {
@@ -71,14 +74,35 @@ namespace System.Net {
                        if (secure == false) {
                                stream = new NetworkStream (sock, false);
                        } else {
-                               SslServerStream ssl_stream = new SslServerStream (new NetworkStream (sock, false), cert, false, false);
+                               SslServerStream ssl_stream = new SslServerStream (new NetworkStream (sock, false), cert, false, true, false);
                                ssl_stream.PrivateKeyCertSelectionDelegate += OnPVKSelection;
+                               ssl_stream.ClientCertValidationDelegate += OnClientCertificateValidation;
                                stream = ssl_stream;
                        }
                        timer = new Timer (OnTimeout, null, Timeout.Infinite, Timeout.Infinite);
                        Init ();
                }
 
+               internal int [] ClientCertificateErrors {
+                       get { return client_cert_errors; }
+               }
+
+               internal X509Certificate2 ClientCertificate {
+                       get { return client_cert; }
+               }
+
+               bool OnClientCertificateValidation (X509Certificate certificate, int[] errors)
+               {
+                       if (certificate == null)
+                               return true;
+                       X509Certificate2 cert = certificate as X509Certificate2;
+                       if (cert == null)
+                               cert = new X509Certificate2 (certificate.GetRawCertData ());
+                       client_cert = cert;
+                       client_cert_errors = errors;
+                       return true;
+               }
+
                AsymmetricAlgorithm OnPVKSelection (X509Certificate certificate, string targetHost)
                {
                        return key;
index 3e5e5f7e6fd922422d23b4f2dac4fd17cb985252..f8be5c4f3b9e2e8b8d0eb065fe27b2be74937f33 100644 (file)
@@ -2,11 +2,11 @@
 // System.Net.HttpListenerRequest
 //
 // Authors:
-//     Gonzalo Paniagua Javier (gonzalo@novell.com)
+//     Gonzalo Paniagua Javier (gonzalo.mono@gmail.com)
 //     Marek Safar (marek.safar@gmail.com)
 //
 // Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
-// Copyright 2011 Xamarin Inc.
+// Copyright (c) 2011-2012 Xamarin, Inc. (http://xamarin.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
@@ -42,6 +42,7 @@ using System.Security.Authentication.ExtendedProtection;
 #if NET_4_5
 using System.Threading.Tasks;
 #endif
+using Mono.Security.Protocol.Tls;
 
 namespace System.Net {
        public sealed class HttpListenerRequest
@@ -57,8 +58,6 @@ namespace System.Net {
 #endif
 
                string [] accept_types;
-//             int client_cert_error;
-//             bool no_get_certificate;
                Encoding content_encoding;
                long content_length;
                bool cl_set;
@@ -76,6 +75,9 @@ namespace System.Net {
                bool is_chunked;
                bool ka_set;
                bool keep_alive;
+               delegate X509Certificate2 GCCDelegate ();
+               GCCDelegate gcc_delegate;
+
                static byte [] _100continue = Encoding.ASCII.GetBytes ("HTTP/1.1 100 Continue\r\n\r\n");
 
                internal HttpListenerRequest (HttpListenerContext context)
@@ -331,15 +333,14 @@ namespace System.Net {
                        get { return accept_types; }
                }
 
-               [MonoTODO ("Always returns 0")]
                public int ClientCertificateError {
                        get {
-/*                             
-                               if (no_get_certificate)
-                                       throw new InvalidOperationException (
-                                               "Call GetClientCertificate() before calling this method.");
-                               return client_cert_error;
-*/
+                               HttpConnection cnc = context.Connection;
+                               if (cnc.ClientCertificate == null)
+                                       throw new InvalidOperationException ("No client certificate");
+                               int [] errors = cnc.ClientCertificateErrors;
+                               if (errors != null && errors.Length > 0)
+                                       return errors [0];
                                return 0;
                        }
                }
@@ -479,24 +480,27 @@ namespace System.Net {
                        get { return user_languages; }
                }
 
-               [MonoTODO]
                public IAsyncResult BeginGetClientCertificate (AsyncCallback requestCallback, object state)
                {
-                       throw new NotImplementedException ();
+                       if (gcc_delegate == null)
+                               gcc_delegate = new GCCDelegate (GetClientCertificate);
+                       return gcc_delegate.BeginInvoke (requestCallback, state);
                }
 
-               [MonoTODO]
                public X509Certificate2 EndGetClientCertificate (IAsyncResult asyncResult)
                {
-                       throw new NotImplementedException ();
+                       if (asyncResult == null)
+                               throw new ArgumentNullException ("asyncResult");
+
+                       if (gcc_delegate == null)
+                               throw new InvalidOperationException ();
+
+                       return gcc_delegate.EndInvoke (asyncResult);
                }
 
                public X509Certificate2 GetClientCertificate ()
                {
-                       // set no_client_certificate once done.
-
-                       // InvalidOp if call in progress.
-                       return null;
+                       return context.Connection.ClientCertificate;
                }
 
 #if NET_4_0
index 483e2b81dbdaf25adc1efbad7847125cf6eacd74..3f027fa8c28c9d9c45d6fe649392d362250c9867 100644 (file)
@@ -140,7 +140,8 @@ namespace System.Net
                        this.actualUri = uri;
                        this.proxy = GlobalProxySelection.Select;
                        this.webHeaders = new WebHeaderCollection (WebHeaderCollection.HeaderInfo.Request);
-               }               
+                       ThrowOnError = true;
+               }
                
                [Obsolete ("Serialization is obsoleted for this type", false)]
                protected HttpWebRequest (SerializationInfo serializationInfo, StreamingContext streamingContext) 
@@ -271,6 +272,8 @@ namespace System.Net
                internal long InternalContentLength {
                        set { contentLength = value; }
                }
+                       
+               internal bool ThrowOnError { get; set; }
                
                public override string ContentType { 
                        get { return webHeaders ["Content-Type"]; }
@@ -553,7 +556,18 @@ namespace System.Net
                public ServicePoint ServicePoint {
                        get { return GetServicePoint (); }
                }
-               
+
+               internal ServicePoint ServicePointNoLock {
+                       get { return servicePoint; }
+               }
+#if NET_4_5 || MOBILE
+               [MonoTODO ("for portable library support")]
+               public bool SupportsCookieContainer { 
+                       get {
+                               throw new NotImplementedException ();
+                       }
+               }
+#endif
                public override int Timeout { 
                        get { return timeout; }
                        set {
@@ -815,8 +829,18 @@ namespace System.Net
 
                void CheckIfForceWrite ()
                {
-                       if (writeStream == null || writeStream.RequestWritten || (contentLength < 0 && writeStream.CanWrite == true) || !InternalAllowBuffering)
+                       if (writeStream == null || writeStream.RequestWritten || !InternalAllowBuffering)
                                return;
+#if NET_4_0
+                       if (contentLength < 0 && writeStream.CanWrite == true && writeStream.WriteBufferLength <= 0)
+                               return;
+
+                       if (contentLength < 0 && writeStream.WriteBufferLength > 0)
+                               InternalContentLength = writeStream.WriteBufferLength;
+#else
+                       if (contentLength < 0 && writeStream.CanWrite == true)
+                               return;
+#endif
 
                        // This will write the POST/PUT if the write stream already has the expected
                        // amount of bytes in it (ContentLength) (bug #77753) or if the write stream
@@ -1487,13 +1511,16 @@ namespace System.Net
                                                        bodyBuffer = null;
                                                        return true;
                                                }
-                                               
+
+                                               if (!ThrowOnError)
+                                                       return false;
+                                                       
                                                writeStream.InternalClose ();
                                                writeStream = null;
                                                webResponse.Close ();
                                                webResponse = null;
                                                bodyBuffer = null;
-
+                                                       
                                                throw new WebException ("This request requires buffering " +
                                                                        "of data for authentication or " +
                                                                        "redirection to be sucessful.");
@@ -1536,6 +1563,9 @@ namespace System.Net
 
                                return b;
                        }
+                               
+                       if (!ThrowOnError)
+                               return false;
 
                        if (writeStream != null) {
                                writeStream.InternalClose ();
diff --git a/mcs/class/System/System.Net/MacProxy.cs b/mcs/class/System/System.Net/MacProxy.cs
new file mode 100644 (file)
index 0000000..f213b0d
--- /dev/null
@@ -0,0 +1,865 @@
+// 
+// MacProxy.cs
+//  
+// Author: Jeffrey Stedfast <jeff@xamarin.com>
+// 
+// Copyright (c) 2012 Xamarin Inc.
+// 
+// Permission is hereby granted, free of charge, to any person obtaining a copy
+// of this software and associated documentation files (the "Software"), to deal
+// in the Software without restriction, including without limitation the rights
+// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+// copies of the Software, and to permit persons to whom the Software is
+// furnished to do so, subject to the following conditions:
+// 
+// The above copyright notice and this permission notice shall be included in
+// all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+// THE SOFTWARE.
+// 
+
+using System;
+using System.Runtime.InteropServices;
+
+namespace System.Net
+{
+       internal class CFObject : IDisposable
+       {
+               public const string CoreFoundationLibrary = "/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation";
+               const string SystemLibrary = "/usr/lib/libSystem.dylib";
+
+               [DllImport (SystemLibrary)]
+               public static extern IntPtr dlopen (string path, int mode);
+
+               [DllImport (SystemLibrary)]
+               public static extern IntPtr dlsym (IntPtr handle, string symbol);
+
+               [DllImport (SystemLibrary)]
+               public static extern void dlclose (IntPtr handle);
+
+               public static IntPtr GetIndirect (IntPtr handle, string symbol)
+               {
+                       return dlsym (handle, symbol);
+               }
+
+               public static IntPtr GetCFObjectHandle (IntPtr handle, string symbol)
+               {
+                       var indirect = dlsym (handle, symbol);
+                       if (indirect == IntPtr.Zero)
+                               return IntPtr.Zero;
+
+                       return Marshal.ReadIntPtr (indirect);
+               }
+
+               public CFObject (IntPtr handle, bool own)
+               {
+                       Handle = handle;
+
+                       if (!own)
+                               Retain ();
+               }
+
+               ~CFObject ()
+               {
+                       Dispose (false);
+               }
+
+               public IntPtr Handle { get; private set; }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static IntPtr CFRetain (IntPtr handle);
+
+               void Retain ()
+               {
+                       CFRetain (Handle);
+               }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static IntPtr CFRelease (IntPtr handle);
+
+               void Release ()
+               {
+                       CFRelease (Handle);
+               }
+
+               protected virtual void Dispose (bool disposing)
+               {
+                       if (Handle != IntPtr.Zero) {
+                               Release ();
+                               Handle = IntPtr.Zero;
+                       }
+               }
+
+               public void Dispose ()
+               {
+                       Dispose (true);
+                       GC.SuppressFinalize (this);
+               }
+       }
+
+       internal class CFArray : CFObject
+       {
+               public CFArray (IntPtr handle, bool own) : base (handle, own) { }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static IntPtr CFArrayCreate (IntPtr allocator, IntPtr values, int numValues, IntPtr callbacks);
+               static readonly IntPtr kCFTypeArrayCallbacks;
+
+               static CFArray ()
+               {
+                       var handle = dlopen (CoreFoundationLibrary, 0);
+                       if (handle == IntPtr.Zero)
+                               return;
+
+                       try {
+                               kCFTypeArrayCallbacks = GetIndirect (handle, "kCFTypeArrayCallBacks");
+                       } finally {
+                               dlclose (handle);
+                       }
+               }
+
+               static unsafe CFArray Create (params IntPtr[] values)
+               {
+                       if (values == null)
+                               throw new ArgumentNullException ("values");
+
+                       fixed (IntPtr *pv = values) {
+                               IntPtr handle = CFArrayCreate (IntPtr.Zero, (IntPtr) pv, values.Length, kCFTypeArrayCallbacks);
+
+                               return new CFArray (handle, false);
+                       }
+               }
+
+               public static CFArray Create (params CFObject[] values)
+               {
+                       if (values == null)
+                               throw new ArgumentNullException ("values");
+
+                       IntPtr[] _values = new IntPtr [values.Length];
+                       for (int i = 0; i < _values.Length; i++)
+                               _values[i] = values[i].Handle;
+
+                       return Create (_values);
+               }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static int CFArrayGetCount (IntPtr handle);
+
+               public int Count {
+                       get { return CFArrayGetCount (Handle); }
+               }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static IntPtr CFArrayGetValueAtIndex (IntPtr handle, int index);
+
+               public IntPtr this[int index] {
+                       get {
+                               return CFArrayGetValueAtIndex (Handle, index);
+                       }
+               }
+       }
+
+       internal class CFNumber : CFObject
+       {
+               public CFNumber (IntPtr handle, bool own) : base (handle, own) { }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static bool CFNumberGetValue (IntPtr handle, int type, out bool value);
+
+               public static bool AsBool (IntPtr handle)
+               {
+                       bool value;
+
+                       if (handle == IntPtr.Zero)
+                               return false;
+
+                       CFNumberGetValue (handle, 1, out value);
+
+                       return value;
+               }
+
+               public static implicit operator bool (CFNumber number)
+               {
+                       return AsBool (number.Handle);
+               }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static bool CFNumberGetValue (IntPtr handle, int type, out int value);
+
+               public static int AsInt32 (IntPtr handle)
+               {
+                       int value;
+
+                       if (handle == IntPtr.Zero)
+                               return 0;
+
+                       CFNumberGetValue (handle, 9, out value);
+
+                       return value;
+               }
+
+               public static implicit operator int (CFNumber number)
+               {
+                       return AsInt32 (number.Handle);
+               }
+       }
+
+       internal struct CFRange {
+               public int Location, Length;
+               
+               public CFRange (int loc, int len)
+               {
+                       Location = loc;
+                       Length = len;
+               }
+       }
+
+       internal class CFString : CFObject
+       {
+               string str;
+
+               public CFString (IntPtr handle, bool own) : base (handle, own) { }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static IntPtr CFStringCreateWithCharacters (IntPtr alloc, IntPtr chars, int length);
+
+               public static CFString Create (string value)
+               {
+                       IntPtr handle;
+
+                       unsafe {
+                               fixed (char *ptr = value) {
+                                       handle = CFStringCreateWithCharacters (IntPtr.Zero, (IntPtr) ptr, value.Length);
+                               }
+                       }
+
+                       if (handle == IntPtr.Zero)
+                               return null;
+
+                       return new CFString (handle, true);
+               }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static int CFStringGetLength (IntPtr handle);
+
+               public int Length {
+                       get {
+                               if (str != null)
+                                       return str.Length;
+
+                               return CFStringGetLength (Handle);
+                       }
+               }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static IntPtr CFStringGetCharactersPtr (IntPtr handle);
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static IntPtr CFStringGetCharacters (IntPtr handle, CFRange range, IntPtr buffer);
+
+               public static string AsString (IntPtr handle)
+               {
+                       if (handle == IntPtr.Zero)
+                               return null;
+                       
+                       int len = CFStringGetLength (handle);
+                       
+                       if (len == 0)
+                               return string.Empty;
+                       
+                       IntPtr chars = CFStringGetCharactersPtr (handle);
+                       IntPtr buffer = IntPtr.Zero;
+                       
+                       if (chars == IntPtr.Zero) {
+                               CFRange range = new CFRange (0, len);
+                               buffer = Marshal.AllocHGlobal (len * 2);
+                               CFStringGetCharacters (handle, range, buffer);
+                               chars = buffer;
+                       }
+
+                       string str;
+
+                       unsafe {
+                               str = new string ((char *) chars, 0, len);
+                       }
+                       
+                       if (buffer != IntPtr.Zero)
+                               Marshal.FreeHGlobal (buffer);
+
+                       return str;
+               }
+
+               public override string ToString ()
+               {
+                       if (str == null)
+                               str = AsString (Handle);
+
+                       return str;
+               }
+
+               public static implicit operator string (CFString str)
+               {
+                       return str.ToString ();
+               }
+
+               public static implicit operator CFString (string str)
+               {
+                       return Create (str);
+               }
+       }
+
+       internal class CFDictionary : CFObject
+       {
+               public CFDictionary (IntPtr handle, bool own) : base (handle, own) { }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static IntPtr CFDictionaryGetValue (IntPtr handle, IntPtr key);
+
+               public IntPtr GetValue (IntPtr key)
+               {
+                       return CFDictionaryGetValue (Handle, key);
+               }
+
+               public IntPtr this[IntPtr key] {
+                       get {
+                               return GetValue (key);
+                       }
+               }
+       }
+
+       internal class CFUrl : CFObject
+       {
+               public CFUrl (IntPtr handle, bool own) : base (handle, own) { }
+
+               [DllImport (CoreFoundationLibrary)]
+               extern static IntPtr CFURLCreateWithString (IntPtr allocator, IntPtr str, IntPtr baseURL);
+
+               public static CFUrl Create (string absolute)
+               {
+                       if (string.IsNullOrEmpty (absolute))
+                               return null;
+
+                       CFString str = CFString.Create (absolute);
+                       IntPtr handle = CFURLCreateWithString (IntPtr.Zero, str.Handle, IntPtr.Zero);
+                       str.Dispose ();
+
+                       if (handle == IntPtr.Zero)
+                               return null;
+
+                       return new CFUrl (handle, true);
+               }
+       }
+
+       internal enum CFProxyType {
+               None,
+               AutoConfigurationUrl,
+               AutoConfigurationJavaScript,
+               FTP,
+               HTTP,
+               HTTPS,
+               SOCKS
+       }
+       
+       internal class CFProxy {
+               //static IntPtr kCFProxyAutoConfigurationHTTPResponseKey;
+               static IntPtr kCFProxyAutoConfigurationJavaScriptKey;
+               static IntPtr kCFProxyAutoConfigurationURLKey;
+               static IntPtr kCFProxyHostNameKey;
+               static IntPtr kCFProxyPasswordKey;
+               static IntPtr kCFProxyPortNumberKey;
+               static IntPtr kCFProxyTypeKey;
+               static IntPtr kCFProxyUsernameKey;
+
+               //static IntPtr kCFProxyTypeNone;
+               static IntPtr kCFProxyTypeAutoConfigurationURL;
+               static IntPtr kCFProxyTypeAutoConfigurationJavaScript;
+               static IntPtr kCFProxyTypeFTP;
+               static IntPtr kCFProxyTypeHTTP;
+               static IntPtr kCFProxyTypeHTTPS;
+               static IntPtr kCFProxyTypeSOCKS;
+
+               static CFProxy ()
+               {
+                       IntPtr handle = CFObject.dlopen (CFNetwork.CFNetworkLibrary, 0);
+
+                       //kCFProxyAutoConfigurationHTTPResponseKey = CFObject.GetCFObjectHandle (handle, "kCFProxyAutoConfigurationHTTPResponseKey");
+                       kCFProxyAutoConfigurationJavaScriptKey = CFObject.GetCFObjectHandle (handle, "kCFProxyAutoConfigurationJavaScriptKey");
+                       kCFProxyAutoConfigurationURLKey = CFObject.GetCFObjectHandle (handle, "kCFProxyAutoConfigurationURLKey");
+                       kCFProxyHostNameKey = CFObject.GetCFObjectHandle (handle, "kCFProxyHostNameKey");
+                       kCFProxyPasswordKey = CFObject.GetCFObjectHandle (handle, "kCFProxyPasswordKey");
+                       kCFProxyPortNumberKey = CFObject.GetCFObjectHandle (handle, "kCFProxyPortNumberKey");
+                       kCFProxyTypeKey = CFObject.GetCFObjectHandle (handle, "kCFProxyTypeKey");
+                       kCFProxyUsernameKey = CFObject.GetCFObjectHandle (handle, "kCFProxyUsernameKey");
+
+                       //kCFProxyTypeNone = CFObject.GetCFObjectHandle (handle, "kCFProxyTypeNone");
+                       kCFProxyTypeAutoConfigurationURL = CFObject.GetCFObjectHandle (handle, "kCFProxyTypeAutoConfigurationURL");
+                       kCFProxyTypeAutoConfigurationJavaScript = CFObject.GetCFObjectHandle (handle, "kCFProxyTypeAutoConfigurationJavaScript");
+                       kCFProxyTypeFTP = CFObject.GetCFObjectHandle (handle, "kCFProxyTypeFTP");
+                       kCFProxyTypeHTTP = CFObject.GetCFObjectHandle (handle, "kCFProxyTypeHTTP");
+                       kCFProxyTypeHTTPS = CFObject.GetCFObjectHandle (handle, "kCFProxyTypeHTTPS");
+                       kCFProxyTypeSOCKS = CFObject.GetCFObjectHandle (handle, "kCFProxyTypeSOCKS");
+
+                       CFObject.dlclose (handle);
+               }
+
+               CFDictionary settings;
+               
+               internal CFProxy (CFDictionary settings)
+               {
+                       this.settings = settings;
+               }
+               
+               static CFProxyType CFProxyTypeToEnum (IntPtr type)
+               {
+                       if (type == kCFProxyTypeAutoConfigurationJavaScript)
+                               return CFProxyType.AutoConfigurationJavaScript;
+
+                       if (type == kCFProxyTypeAutoConfigurationURL)
+                               return CFProxyType.AutoConfigurationUrl;
+
+                       if (type == kCFProxyTypeFTP)
+                               return CFProxyType.FTP;
+
+                       if (type == kCFProxyTypeHTTP)
+                               return CFProxyType.HTTP;
+
+                       if (type == kCFProxyTypeHTTPS)
+                               return CFProxyType.HTTPS;
+
+                       if (type == kCFProxyTypeSOCKS)
+                               return CFProxyType.SOCKS;
+                       
+                       return CFProxyType.None;
+               }
+               
+#if false
+               // AFAICT these get used with CFNetworkExecuteProxyAutoConfiguration*()
+               
+               // TODO: bind CFHTTPMessage so we can return the proper type here.
+               public IntPtr AutoConfigurationHTTPResponse {
+                       get { return settings[kCFProxyAutoConfigurationHTTPResponseKey]; }
+               }
+#endif
+
+               public IntPtr AutoConfigurationJavaScript {
+                       get {
+                               if (kCFProxyAutoConfigurationJavaScriptKey == IntPtr.Zero)
+                                       return IntPtr.Zero;
+                               
+                               return settings[kCFProxyAutoConfigurationJavaScriptKey];
+                       }
+               }
+               
+               public IntPtr AutoConfigurationUrl {
+                       get {
+                               if (kCFProxyAutoConfigurationURLKey == IntPtr.Zero)
+                                       return IntPtr.Zero;
+                               
+                               return settings[kCFProxyAutoConfigurationURLKey];
+                       }
+               }
+               
+               public string HostName {
+                       get {
+                               if (kCFProxyHostNameKey == IntPtr.Zero)
+                                       return null;
+                               
+                               return CFString.AsString (settings[kCFProxyHostNameKey]);
+                       }
+               }
+               
+               public string Password {
+                       get {
+                               if (kCFProxyPasswordKey == IntPtr.Zero)
+                                       return null;
+
+                               return CFString.AsString (settings[kCFProxyPasswordKey]);
+                       }
+               }
+               
+               public int Port {
+                       get {
+                               if (kCFProxyPortNumberKey == IntPtr.Zero)
+                                       return 0;
+                               
+                               return CFNumber.AsInt32 (settings[kCFProxyPortNumberKey]);
+                       }
+               }
+               
+               public CFProxyType ProxyType {
+                       get {
+                               if (kCFProxyTypeKey == IntPtr.Zero)
+                                       return CFProxyType.None;
+                               
+                               return CFProxyTypeToEnum (settings[kCFProxyTypeKey]);
+                       }
+               }
+               
+               public string Username {
+                       get {
+                               if (kCFProxyUsernameKey == IntPtr.Zero)
+                                       return null;
+
+                               return CFString.AsString (settings[kCFProxyUsernameKey]);
+                       }
+               }
+       }
+       
+       internal class CFProxySettings {
+               static IntPtr kCFNetworkProxiesHTTPEnable;
+               static IntPtr kCFNetworkProxiesHTTPPort;
+               static IntPtr kCFNetworkProxiesHTTPProxy;
+               static IntPtr kCFNetworkProxiesProxyAutoConfigEnable;
+               static IntPtr kCFNetworkProxiesProxyAutoConfigJavaScript;
+               static IntPtr kCFNetworkProxiesProxyAutoConfigURLString;
+
+               static CFProxySettings ()
+               {
+                       IntPtr handle = CFObject.dlopen (CFNetwork.CFNetworkLibrary, 0);
+
+                       kCFNetworkProxiesHTTPEnable = CFObject.GetCFObjectHandle (handle, "kCFNetworkProxiesHTTPEnable");
+                       kCFNetworkProxiesHTTPPort = CFObject.GetCFObjectHandle (handle, "kCFNetworkProxiesHTTPPort");
+                       kCFNetworkProxiesHTTPProxy = CFObject.GetCFObjectHandle (handle, "kCFNetworkProxiesHTTPProxy");
+                       kCFNetworkProxiesProxyAutoConfigEnable = CFObject.GetCFObjectHandle (handle, "kCFNetworkProxiesProxyAutoConfigEnable");
+                       kCFNetworkProxiesProxyAutoConfigJavaScript = CFObject.GetCFObjectHandle (handle, "kCFNetworkProxiesProxyAutoConfigJavaScript");
+                       kCFNetworkProxiesProxyAutoConfigURLString = CFObject.GetCFObjectHandle (handle, "kCFNetworkProxiesProxyAutoConfigURLString");
+
+                       CFObject.dlclose (handle);
+               }
+
+               CFDictionary settings;
+               
+               public CFProxySettings (CFDictionary settings)
+               {
+                       this.settings = settings;
+               }
+               
+               public CFDictionary Dictionary {
+                       get { return settings; }
+               }
+               
+               public bool HTTPEnable {
+                       get {
+                               if (kCFNetworkProxiesHTTPEnable == IntPtr.Zero)
+                                       return false;
+
+                               return CFNumber.AsBool (settings[kCFNetworkProxiesHTTPEnable]);
+                       }
+               }
+               
+               public int HTTPPort {
+                       get {
+                               if (kCFNetworkProxiesHTTPPort == IntPtr.Zero)
+                                       return 0;
+                               
+                               return CFNumber.AsInt32 (settings[kCFNetworkProxiesHTTPPort]);
+                       }
+               }
+               
+               public string HTTPProxy {
+                       get {
+                               if (kCFNetworkProxiesHTTPProxy == IntPtr.Zero)
+                                       return null;
+                               
+                               return CFString.AsString (settings[kCFNetworkProxiesHTTPProxy]);
+                       }
+               }
+               
+               public bool ProxyAutoConfigEnable {
+                       get {
+                               if (kCFNetworkProxiesProxyAutoConfigEnable == IntPtr.Zero)
+                                       return false;
+                               
+                               return CFNumber.AsBool (settings[kCFNetworkProxiesProxyAutoConfigEnable]);
+                       }
+               }
+               
+               public string ProxyAutoConfigJavaScript {
+                       get {
+                               if (kCFNetworkProxiesProxyAutoConfigJavaScript == IntPtr.Zero)
+                                       return null;
+                               
+                               return CFString.AsString (settings[kCFNetworkProxiesProxyAutoConfigJavaScript]);
+                       }
+               }
+               
+               public string ProxyAutoConfigURLString {
+                       get {
+                               if (kCFNetworkProxiesProxyAutoConfigURLString == IntPtr.Zero)
+                                       return null;
+                               
+                               return CFString.AsString (settings[kCFNetworkProxiesProxyAutoConfigURLString]);
+                       }
+               }
+       }
+       
+       internal static class CFNetwork {
+#if !MONOTOUCH
+               public const string CFNetworkLibrary = "/System/Library/Frameworks/CoreServices.framework/Frameworks/CFNetwork.framework/CFNetwork";
+#else
+               public const string CFNetworkLibrary = "/System/Library/Frameworks/CFNetwork.framework/CFNetwork";
+#endif
+               
+               [DllImport (CFNetworkLibrary)]
+               // CFArrayRef CFNetworkCopyProxiesForAutoConfigurationScript (CFStringRef proxyAutoConfigurationScript, CFURLRef targetURL);
+               extern static IntPtr CFNetworkCopyProxiesForAutoConfigurationScript (IntPtr proxyAutoConfigurationScript, IntPtr targetURL);
+               
+               static CFArray CopyProxiesForAutoConfigurationScript (IntPtr proxyAutoConfigurationScript, CFUrl targetURL)
+               {
+                       IntPtr native = CFNetworkCopyProxiesForAutoConfigurationScript (proxyAutoConfigurationScript, targetURL.Handle);
+                       
+                       if (native == IntPtr.Zero)
+                               return null;
+                       
+                       return new CFArray (native, true);
+               }
+               
+               public static CFProxy[] GetProxiesForAutoConfigurationScript (IntPtr proxyAutoConfigurationScript, CFUrl targetURL)
+               {
+                       if (proxyAutoConfigurationScript == IntPtr.Zero)
+                               throw new ArgumentNullException ("proxyAutoConfigurationScript");
+                       
+                       if (targetURL == null)
+                               throw new ArgumentNullException ("targetURL");
+                       
+                       CFArray array = CopyProxiesForAutoConfigurationScript (proxyAutoConfigurationScript, targetURL);
+                       
+                       if (array == null)
+                               return null;
+                       
+                       CFProxy[] proxies = new CFProxy [array.Count];
+                       for (int i = 0; i < proxies.Length; i++) {
+                               CFDictionary dict = new CFDictionary (array[i], false);
+                               proxies[i] = new CFProxy (dict);
+                       }
+
+                       array.Dispose ();
+                       
+                       return proxies;
+               }
+               
+               public static CFProxy[] GetProxiesForAutoConfigurationScript (IntPtr proxyAutoConfigurationScript, Uri targetUri)
+               {
+                       if (proxyAutoConfigurationScript == IntPtr.Zero)
+                               throw new ArgumentNullException ("proxyAutoConfigurationScript");
+                       
+                       if (targetUri == null)
+                               throw new ArgumentNullException ("targetUri");
+                       
+                       CFUrl targetURL = CFUrl.Create (targetUri.AbsoluteUri);
+                       CFProxy[] proxies = GetProxiesForAutoConfigurationScript (proxyAutoConfigurationScript, targetURL);
+                       targetURL.Dispose ();
+                       
+                       return proxies;
+               }
+               
+               [DllImport (CFNetworkLibrary)]
+               // CFArrayRef CFNetworkCopyProxiesForURL (CFURLRef url, CFDictionaryRef proxySettings);
+               extern static IntPtr CFNetworkCopyProxiesForURL (IntPtr url, IntPtr proxySettings);
+               
+               static CFArray CopyProxiesForURL (CFUrl url, CFDictionary proxySettings)
+               {
+                       IntPtr native = CFNetworkCopyProxiesForURL (url.Handle, proxySettings != null ? proxySettings.Handle : IntPtr.Zero);
+                       
+                       if (native == IntPtr.Zero)
+                               return null;
+                       
+                       return new CFArray (native, true);
+               }
+               
+               public static CFProxy[] GetProxiesForURL (CFUrl url, CFProxySettings proxySettings)
+               {
+                       if (url == null || url.Handle == IntPtr.Zero)
+                               throw new ArgumentNullException ("url");
+                       
+                       if (proxySettings == null)
+                               proxySettings = GetSystemProxySettings ();
+                       
+                       CFArray array = CopyProxiesForURL (url, proxySettings.Dictionary);
+                       
+                       if (array == null)
+                               return null;
+
+                       CFProxy[] proxies = new CFProxy [array.Count];
+                       for (int i = 0; i < proxies.Length; i++) {
+                               CFDictionary dict = new CFDictionary (array[i], false);
+                               proxies[i] = new CFProxy (dict);
+                       }
+
+                       array.Dispose ();
+                       
+                       return proxies;
+               }
+               
+               public static CFProxy[] GetProxiesForUri (Uri uri, CFProxySettings proxySettings)
+               {
+                       if (uri == null)
+                               throw new ArgumentNullException ("uri");
+                       
+                       CFUrl url = CFUrl.Create (uri.AbsoluteUri);
+                       if (url == null)
+                               return null;
+                       
+                       CFProxy[] proxies = GetProxiesForURL (url, proxySettings);
+                       url.Dispose ();
+                       
+                       return proxies;
+               }
+               
+               [DllImport (CFNetworkLibrary)]
+               // CFDictionaryRef CFNetworkCopySystemProxySettings (void);
+               extern static IntPtr CFNetworkCopySystemProxySettings ();
+               
+               public static CFProxySettings GetSystemProxySettings ()
+               {
+                       IntPtr native = CFNetworkCopySystemProxySettings ();
+                       
+                       if (native == IntPtr.Zero)
+                               return null;
+                       
+                       var dict = new CFDictionary (native, true);
+
+                       return new CFProxySettings (dict);
+               }
+               
+               class CFWebProxy : IWebProxy {
+                       public CFWebProxy ()
+                       {
+                               
+                       }
+                       
+                       public ICredentials Credentials {
+                               get; set;
+                       }
+                       
+                       static Uri GetProxyUri (CFProxy proxy)
+                       {
+                               string protocol;
+                               
+                               switch (proxy.ProxyType) {
+                               case CFProxyType.FTP:
+                                       protocol = "ftp://";
+                                       break;
+                               case CFProxyType.HTTP:
+                               case CFProxyType.HTTPS:
+                                       protocol = "http://";
+                                       break;
+                               default:
+                                       return null;
+                               }
+                               
+                               string username = proxy.Username;
+                               string password = proxy.Password;
+                               string hostname = proxy.HostName;
+                               int port = proxy.Port;
+                               string userinfo;
+                               string uri;
+                               
+                               if (username != null) {
+                                       if (password != null)
+                                               userinfo = Uri.EscapeDataString (username) + ':' + Uri.EscapeDataString (password) + '@';
+                                       else
+                                               userinfo = Uri.EscapeDataString (username) + '@';
+                               } else {
+                                       userinfo = string.Empty;
+                               }
+                               
+                               uri = protocol + userinfo + hostname + (port != 0 ? ':' + port.ToString () : string.Empty);
+                               
+                               return new Uri (uri, UriKind.Absolute);
+                       }
+                       
+                       static Uri GetProxyUriFromScript (IntPtr script, Uri targetUri)
+                       {
+                               CFProxy[] proxies = CFNetwork.GetProxiesForAutoConfigurationScript (script, targetUri);
+                               
+                               if (proxies == null)
+                                       return targetUri;
+                               
+                               for (int i = 0; i < proxies.Length; i++) {
+                                       switch (proxies[i].ProxyType) {
+                                       case CFProxyType.HTTPS:
+                                       case CFProxyType.HTTP:
+                                       case CFProxyType.FTP:
+                                               // create a Uri based on the hostname/port/etc info
+                                               return GetProxyUri (proxies[i]);
+                                       case CFProxyType.SOCKS:
+                                       default:
+                                               // unsupported proxy type, try the next one
+                                               break;
+                                       case CFProxyType.None:
+                                               // no proxy should be used
+                                               return targetUri;
+                                       }
+                               }
+                               
+                               return null;
+                       }
+                       
+                       public Uri GetProxy (Uri targetUri)
+                       {
+                               if (targetUri == null)
+                                       throw new ArgumentNullException ("targetUri");
+                               
+                               try {
+                                       CFProxySettings settings = CFNetwork.GetSystemProxySettings ();
+                                       CFProxy[] proxies = CFNetwork.GetProxiesForUri (targetUri, settings);
+                                       Uri uri;
+                                       
+                                       if (proxies == null)
+                                               return targetUri;
+                                       
+                                       for (int i = 0; i < proxies.Length; i++) {
+                                               switch (proxies[i].ProxyType) {
+                                               case CFProxyType.AutoConfigurationJavaScript:
+                                                       if ((uri = GetProxyUriFromScript (proxies[i].AutoConfigurationJavaScript, targetUri)) != null)
+                                                               return uri;
+                                                       break;
+                                               case CFProxyType.AutoConfigurationUrl:
+                                                       // unsupported proxy type (requires fetching script from remote url)
+                                                       break;
+                                               case CFProxyType.HTTPS:
+                                               case CFProxyType.HTTP:
+                                               case CFProxyType.FTP:
+                                                       // create a Uri based on the hostname/port/etc info
+                                                       return GetProxyUri (proxies[i]);
+                                               case CFProxyType.SOCKS:
+                                                       // unsupported proxy type, try the next one
+                                                       break;
+                                               case CFProxyType.None:
+                                                       // no proxy should be used
+                                                       return targetUri;
+                                               }
+                                       }
+                               } catch {
+                                       // ignore errors while retrieving proxy data
+                               }
+                               // no supported proxies for this Uri, fall back to trying to connect to targetUri directly.
+                               return targetUri;
+                       }
+                       
+                       public bool IsBypassed (Uri targetUri)
+                       {
+                               if (targetUri == null)
+                                       throw new ArgumentNullException ("targetUri");
+                               
+                               return GetProxy (targetUri) == targetUri;
+                       }
+               }
+               
+               static CFWebProxy defaultWebProxy;
+               public static IWebProxy GetDefaultProxy ()
+               {
+                       if (defaultWebProxy == null)
+                               defaultWebProxy = new CFWebProxy ();
+                       
+                       return defaultWebProxy;
+               }
+       }
+}
index 16292185200d4842f0cb378714d6fc585ca129ff..3e35e93a867020fca08fd47404f30aa09851b73d 100644 (file)
@@ -540,7 +540,7 @@ namespace System.Net
                                        ServicePoint sp = null;
                                        HttpWebRequest req = sender as HttpWebRequest;
                                        if (req != null)
-                                               sp = req.ServicePoint;
+                                               sp = req.ServicePointNoLock;
                                        if (status11 == 0 && errors != 0)
                                                status11 = GetStatusFromChain (chain);
 
index c7d8d17653ad06d655e059f81e2c325138e714cb..b8e28b5c08e53b88d5b9545a697638b8d544e278 100644 (file)
@@ -91,7 +91,7 @@ namespace System.Net
                 {
                         Type type = Type.GetType ("MonoTouch.ObjCRuntime.Runtime, monotouch");
                        if (type != null)
-                               start_wwan = type.GetMethod ("StartWWAN");
+                               start_wwan = type.GetMethod ("StartWWAN", new Type [] { typeof (System.Uri) });
                 }
 #endif
 
index c9b7ee2b03da1a363ce89a5706974f77c9f4f7b4..d136d830d1290afce0789d856bd9db2bab597c25 100644 (file)
@@ -181,6 +181,12 @@ namespace System.Net
                                headerValue = headerValue.Trim ();
                        if (!IsHeaderValue (headerValue))
                                throw new ArgumentException ("invalid header value: " + headerValue, "headerValue");
+                       
+                       AddValue (headerName, headerValue);
+               }
+                       
+               internal void AddValue (string headerName, string headerValue)
+               {
                        base.Add (headerName, headerValue);                     
                }
 
index aa88aeecd555e0629b01d98bda40a17ccef5123d..df007846cc6f65ae96de0488a417b228debf7231 100644 (file)
@@ -63,22 +63,11 @@ namespace System.Net
                static bool isDefaultWebProxySet;
                static IWebProxy defaultWebProxy;
                static RequestCachePolicy defaultCachePolicy;
-               static MethodInfo cfGetDefaultProxy;
                
                // Constructors
                
                static WebRequest ()
                {
-                       if (Platform.IsMacOS) {
-#if MONOTOUCH
-                               Type type = Type.GetType ("MonoTouch.CoreFoundation.CFNetwork, monotouch");
-#else
-                               Type type = Type.GetType ("MonoMac.CoreFoundation.CFNetwork, monomac");
-#endif
-                               if (type != null)
-                                       cfGetDefaultProxy = type.GetMethod ("GetDefaultProxy");
-                       }
-                       
 #if NET_2_1
                        IWebRequestCreate http = new HttpRequestCreator ();
                        RegisterPrefix ("http", http);
@@ -246,9 +235,14 @@ namespace System.Net
                        
                        ProxyElement pe = sec.Proxy;
                        
-                       if ((pe.UseSystemDefault != ProxyElement.UseSystemDefaultValues.False) && (pe.ProxyAddress == null))
-                               p = (WebProxy) GetSystemWebProxy ();
-                       else
+                       if ((pe.UseSystemDefault != ProxyElement.UseSystemDefaultValues.False) && (pe.ProxyAddress == null)) {
+                               IWebProxy proxy = GetSystemWebProxy ();
+                               
+                               if (!(proxy is WebProxy))
+                                       return proxy;
+                               
+                               p = (WebProxy) proxy;
+                       } else
                                p = new WebProxy ();
                        
                        if (pe.ProxyAddress != null)
@@ -303,7 +297,19 @@ namespace System.Net
                                throw new ArgumentNullException ("requestUri");
                        return GetCreator (requestUri.Scheme).Create (requestUri);
                }
-
+#if NET_4_5 || MOBILE  
+               [MonoTODO ("for portable library support")]
+               public static HttpWebRequest CreateHttp (string requestUriString)
+               {
+                       throw new NotImplementedException ();
+               }
+                       
+               [MonoTODO ("for portable library support")]
+               public static HttpWebRequest CreateHttp (Uri requestUri)
+               {
+                       throw new NotImplementedException ();
+               }
+#endif
                public virtual Stream EndGetRequestStream (IAsyncResult asyncResult)
                {
                        throw GetMustImplement ();
@@ -362,6 +368,9 @@ namespace System.Net
                                }
                        } else {
 #endif
+                               if (Platform.IsMacOS)
+                                       return CFNetwork.GetDefaultProxy ();
+                               
                                string address = Environment.GetEnvironmentVariable ("http_proxy");
 
                                if (address == null)
@@ -413,9 +422,6 @@ namespace System.Net
                        }
 #endif
                        
-                       if (cfGetDefaultProxy != null)
-                               return (IWebProxy) cfGetDefaultProxy.Invoke (null, null);
-                       
                        return new WebProxy ();
                }
 
index b87d65b40c2e2f3b18c79f2672c4209949d8cdd5..43864f4424fd195b2e622001363729cbf7f62844 100644 (file)
@@ -87,7 +87,12 @@ namespace System.Net
                public virtual Uri ResponseUri {                \r
                        get { throw new NotSupportedException (); }\r
                }               \r
-\r
+#if NET_4_5 || MOBILE\r
+               [MonoTODO ("for portable library support")]\r
+               public virtual bool SupportsHeaders {\r
+                       get { throw new NotImplementedException (); }\r
+               }\r
+#endif\r
                // Methods\r
                \r
                public virtual void Close()\r
@@ -101,6 +106,8 @@ namespace System.Net
                }\r
 #if TARGET_JVM //enable overrides for extenders\r
                public virtual void Dispose()\r
+#elif NET_4_0 || MOBILE\r
+               public void Dispose ()\r
 #else\r
                void IDisposable.Dispose()\r
 #endif\r
index 937aa22305a81b28a3933a5fbd72d0cb6a818602..905d6324474f41fdc9047538c0e66e7f97be4129 100644 (file)
@@ -133,10 +133,10 @@ namespace Mono.Security.X509 {
 
                                if (certArray != IntPtr.Zero)
                                        CFRelease (certArray);
-                               else
-                                       for (int i = 0; i < certCount; i++)
-                                               if (secCerts [i] != IntPtr.Zero)
-                                                       CFRelease (secCerts [i]);
+                               
+                               for (int i = 0; i < certCount; i++)
+                                       if (secCerts [i] != IntPtr.Zero)
+                                               CFRelease (secCerts [i]);
                        }
                }
        }
diff --git a/mcs/class/System/System.Windows.Input/ICommand.cs b/mcs/class/System/System.Windows.Input/ICommand.cs
new file mode 100644 (file)
index 0000000..c36fea2
--- /dev/null
@@ -0,0 +1,41 @@
+//
+// System.Windows.Input.ICommand
+//
+// Contact:
+//   Moonlight List (moonlight-list@lists.ximian.com)
+//
+// Copyright 2008 Novell, Inc.
+// Copyright 2012 Xamarin Inc.
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+#if NET_4_5 || MOBILE
+
+namespace System.Windows.Input {
+       
+       public interface ICommand {
+               bool CanExecute (object parameter);
+               void Execute (object parameter);
+               event EventHandler CanExecuteChanged;
+       }
+}
+
+#endif
\ No newline at end of file
index 6d7dc002dc25ec9ab6eecd0301457e343a4350f6..50b020320ba185e6e2e863f92a22c58c8e0939da 100644 (file)
@@ -763,6 +763,7 @@ System.Net.Mime/ContentType.cs
 System.Net.Mime/DispositionTypeNames.cs
 System.Net.Mime/MediaTypeNames.cs
 System.Net.Mime/TransferEncoding.cs
+System.Net/MacProxy.cs
 System.Net/MonoHttpDate.cs
 System.Net/NetConfig.cs
 System.Net/NetworkAccess.cs
@@ -1076,3 +1077,4 @@ Mono.Net.Dns/SimpleResolver.cs
 Mono.Net.Dns/ResolverError.cs
 Mono.Net.Dns/SimpleResolverEventArgs.cs
 System.Net/DnsAsyncResult.cs
+System.Windows.Input/ICommand.cs
\ No newline at end of file
index 9b88d69b0c7c8a2f3aaa15c73f6dcd338e53635f..0978cafb21bde30783ed892b70cff688441a647b 100644 (file)
@@ -704,12 +704,7 @@ namespace System {
                        }
                }
 
-#if NET_2_0
-               public
-#else
-               internal
-#endif
-               bool IsAbsoluteUri {
+               public bool IsAbsoluteUri {
                        get { return isAbsoluteUri; }
                }
 
@@ -2051,11 +2046,19 @@ namespace System {
                //
                static bool NeedToEscapeDataChar (char b)
                {
+#if NET_4_0
+                       // .NET 4.0 follows RFC 3986 Unreserved Characters
+                       return !((b >= 'A' && b <= 'Z') ||
+                                (b >= 'a' && b <= 'z') ||
+                                (b >= '0' && b <= '9') ||
+                                b == '-' || b == '.' || b == '_' || b == '~');
+#else
                        return !((b >= 'A' && b <= 'Z') ||
                                 (b >= 'a' && b <= 'z') ||
                                 (b >= '0' && b <= '9') ||
                                 b == '_' || b == '~' || b == '!' || b == '\'' ||
                                 b == '(' || b == ')' || b == '*' || b == '-' || b == '.');
+#endif
                }
                
                public static string EscapeDataString (string stringToEscape)
@@ -2064,9 +2067,9 @@ namespace System {
                                throw new ArgumentNullException ("stringToEscape");
 
                        if (stringToEscape.Length > MaxUriLength) {
-                               string msg = Locale.GetText ("Uri is longer than the maximum {0} characters.");
-                               throw new UriFormatException (msg);
+                               throw new UriFormatException (string.Format ("Uri is longer than the maximum {0} characters.", MaxUriLength));
                        }
+
                        bool escape = false;
                        foreach (char c in stringToEscape){
                                if (NeedToEscapeDataChar (c)){
@@ -2094,11 +2097,27 @@ namespace System {
                //
                static bool NeedToEscapeUriChar (char b)
                {
-                       return !((b >= 'A' && b <= 'Z') ||
-                                (b >= 'a' && b <= 'z') ||
-                                (b >= '&' && b <= ';') ||
-                                b == '!' || b == '#' || b == '$' || b == '=' ||
-                                b == '?' || b == '@' || b == '_' || b == '~');
+                       if ((b >= 'A' && b <= 'Z') || (b >= 'a' && b <= 'z') || (b >= '&' && b <= ';'))
+                               return false;
+
+                       switch (b) {
+                       case '!':
+                       case '#':
+                       case '$':
+                       case '=':
+                       case '?':
+                       case '@':
+                       case '_':
+                       case '~':
+#if NET_4_0
+                       // .NET 4.0 follows RFC 3986
+                       case '[':
+                       case ']':
+#endif
+                               return false;
+                       default:
+                               return true;
+                       }
                }
                
                public static string EscapeUriString (string stringToEscape)
@@ -2107,8 +2126,7 @@ namespace System {
                                throw new ArgumentNullException ("stringToEscape");
 
                        if (stringToEscape.Length > MaxUriLength) {
-                               string msg = Locale.GetText ("Uri is longer than the maximum {0} characters.");
-                               throw new UriFormatException (msg);
+                               throw new UriFormatException (string.Format ("Uri is longer than the maximum {0} characters.", MaxUriLength));
                        }
 
                        bool escape = false;
index c7ae4636ab58236949e2c927124f775ff80f57e2..c800abcd726f2c47a7f52038a2751b87674b8d1e 100644 (file)
@@ -87,6 +87,7 @@ System.CodeDom/CodeVariableDeclarationStatementTest.cs
 System.CodeDom/CodeVariableReferenceExpressionTest.cs
 System.CodeDom.Compiler/CodeGeneratorFromTypeTestBase.cs
 System.CodeDom.Compiler/CodeGeneratorOptionsTest.cs
+System.CodeDom.Compiler/CodeGeneratorGenerateFromCompileUnitTest.cs
 System.CodeDom.Compiler/CodeGeneratorTest.cs
 System.CodeDom.Compiler/CodeGeneratorTestBase.cs
 System.CodeDom.Compiler/ExecutorTest.cs
@@ -175,6 +176,7 @@ System.Configuration/SettingsPropertyCollectionTest.cs
 System.Configuration/SettingsPropertyTest.cs
 System.Configuration/SettingsPropertyValueCollectionTest.cs
 System.Configuration/SettingsPropertyValueTest.cs
+System.Diagnostics/DebugTest.cs
 System.Diagnostics/DelimitedListTraceListenerTest.cs
 System.Diagnostics/EventLogTest.cs
 System.Diagnostics/StopwatchTest.cs
@@ -286,6 +288,7 @@ System.Security.Cryptography.X509Certificates/Pkits_4_16_PrivateCertificateExten
 System.Security.Cryptography.X509Certificates/PublicKeyTest.cs
 System.Security.Cryptography.X509Certificates/X500DistinguishedNameTest.cs
 System.Security.Cryptography.X509Certificates/X509BasicConstraintsExtensionTest.cs
+System.Security.Cryptography.X509Certificates/X509Cert20Test.cs
 System.Security.Cryptography.X509Certificates/X509Certificate2Test.cs
 System.Security.Cryptography.X509Certificates/X509CertificateCollectionTest.cs
 System.Security.Cryptography.X509Certificates/X509Certificate2CollectionTest.cs
@@ -491,4 +494,4 @@ System.Web/AspNetHostingPermissionAttributeCas.cs
 System.Collections.Concurrent/BlockingCollectionTests.cs
 System.Collections.Concurrent/ConcurrentBagTests.cs
 System.Collections.Concurrent/CollectionStressTestHelper.cs
-System.Collections.Concurrent/ParallelTestHelper.cs
\ No newline at end of file
+System.Collections.Concurrent/ParallelTestHelper.cs
index 812abbdaf85488c973ff09c6aa875ad49ee3ca6b..c9eea9c165b380e9e9477f48729589ac7a55ca6f 100644 (file)
@@ -3,9 +3,11 @@
 //
 // Authors:
 //     Erik LeBel (eriklebel@yahoo.ca)
+//     Ilker Cetinkaya (mail@ilker.de)
 //
 // (c) 2003 Erik LeBel
 //
+
 using System;
 using System.CodeDom;
 using System.CodeDom.Compiler;
@@ -175,5 +177,28 @@ namespace MonoTests.Microsoft.CSharp
                        writer.Close ();
                        Assert.AreEqual ("public class Test1 {}" + writer.NewLine, writer.ToString ());
                }
+
+               [Test]
+               public void AttributeAndGlobalNamespaceWithImportTest ()
+               {
+                       var import = new CodeNamespaceImport ("Z");
+                       AddGlobalNamespaceWithImport (codeUnit, import);
+                       AddAssemblyAttribute (codeUnit, "A");
+
+                       Assert.AreEqual (string.Format (CultureInfo.InvariantCulture,
+                               "using Z;{0}{0}[assembly: A()]{0}{0}", NewLine), Generate ());
+               }
+
+               private static void AddGlobalNamespaceWithImport (CodeCompileUnit codeUnit, CodeNamespaceImport import) {
+                       CodeNamespace ns = new CodeNamespace ();
+                       ns.Imports.Add (import);
+                       codeUnit.Namespaces.Add (ns);
+               }
+
+               private static void AddAssemblyAttribute (CodeCompileUnit codeUnit, string attributeName) {
+                       CodeAttributeDeclaration attrDec = new CodeAttributeDeclaration ();
+                       attrDec.Name = attributeName;
+                       codeUnit.AssemblyCustomAttributes.Add (attrDec);
+               }
        }
 }
diff --git a/mcs/class/System/Test/System.CodeDom.Compiler/CodeGeneratorGenerateFromCompileUnitTest.cs b/mcs/class/System/Test/System.CodeDom.Compiler/CodeGeneratorGenerateFromCompileUnitTest.cs
new file mode 100644 (file)
index 0000000..041e1ab
--- /dev/null
@@ -0,0 +1,133 @@
+//
+// CodeGenerator.GenerateFromCompileUnit Tests
+//
+// Authors:
+// Ilker Cetinkaya (mail@ilker.de)
+//
+// This is a specific test for an issue on GenerateFromCompileUnit.
+// Up until 2012 (version 2.10.n) the method emits attribute first
+// and imports afterwards on global namespace scope. Example:
+//
+// ~~~~
+// [assembly: AssemblyVersion("1.0")]
+// using System.Reflection;
+// ~~~~
+//
+// This in particular causes compiler to bail with CS1529.
+// Albeit well aware that this is a _language specific_ issue
+// (or requirement), the actual fix is aimed on CodeGenerator since
+// the wrong emit order is as well in GenerateFromCompileUnit of abstract
+// base. The probability to harm any other language generators
+// is very low. It's near common sense to have imports on top
+// on global namespace / file level.
+//
+// The test is being repeated for the internal `CSharpCodeGenerator`.
+// See `Microsoft.CSharp` (Mono.CSharp namespace) for details.
+//
+// This test verifies the issue as well as describes correct expectation.
+
+using System;
+using System.CodeDom;
+using System.CodeDom.Compiler;
+using System.IO;
+
+using NUnit.Framework;
+
+namespace MonoTests.System.CodeDom.Compiler
+{
+       [TestFixture]
+       public class CodeGeneratorGenerateFromCompileUnitTest {
+               [Test]
+               public void When_Having_AssemblyAttribute_And_Using_Namespace_It_Should_Generate_Namespace_First_And_Attribute_Afterwards () {
+                       ICodeGenerator generator = new SampleCodeGenerator ();
+                       var compileUnit = ACompileUnitWithAttributeAndNamespace ();
+                       var writer = new StringWriter ();
+                       var options = new CodeGeneratorOptions ();
+
+                       generator.GenerateCodeFromCompileUnit (compileUnit, writer, options);
+
+                       string result = writer.ToString ();
+                       
+                       int importPosition = result.IndexOf (IMPORT);
+                       int attributePosition = result.IndexOf (ATTRIBUTE);
+
+                       Assert.Greater (attributePosition, importPosition, "Actual order: " + result);
+               }
+
+               private const string ATTRIBUTE = "ATTRIBUTE";
+               private const string IMPORT = "IMPORT";
+
+               private CodeCompileUnit ACompileUnitWithAttributeAndNamespace () {
+                       var compileUnit = new CodeCompileUnit ();
+                       var importNs = new CodeNamespace ();
+
+                       importNs.Imports.Add (new CodeNamespaceImport (IMPORT));
+
+                       compileUnit.AssemblyCustomAttributes.Add (new CodeAttributeDeclaration (ATTRIBUTE));
+                       compileUnit.Namespaces.Add (importNs);
+
+                       return compileUnit;
+               }
+
+               private class SampleCodeGenerator : CodeGenerator {
+                       /* test overrides */
+                       protected override void GenerateAttributeDeclarationsStart (CodeAttributeDeclarationCollection attributes) { Output.Write ("ATTRIBUTE"); }
+                       protected override void GenerateAttributeDeclarationsEnd (CodeAttributeDeclarationCollection attributes) {}
+                       protected override void GenerateNamespaceImport (CodeNamespaceImport i) { Output.Write ("IMPORT"); }
+                       /* must overrides */
+                       protected override string NullToken { get { return string.Empty; } }
+                       protected override void GenerateArgumentReferenceExpression (CodeArgumentReferenceExpression e) {}
+                       protected override void GenerateArrayCreateExpression (CodeArrayCreateExpression e) {}
+                       protected override void GenerateArrayIndexerExpression (CodeArrayIndexerExpression e) {}
+                       protected override void GenerateAssignStatement (CodeAssignStatement s) {}
+                       protected override void GenerateAttachEventStatement (CodeAttachEventStatement s) {}
+                       protected override void GenerateBaseReferenceExpression (CodeBaseReferenceExpression e) {}
+                       protected override void GenerateCastExpression (CodeCastExpression e) {}
+                       protected override void GenerateComment (CodeComment comment) {}
+                       protected override void GenerateConditionStatement (CodeConditionStatement s) {}
+                       protected override void GenerateConstructor (CodeConstructor x, CodeTypeDeclaration d) {}
+                       protected override void GenerateDelegateCreateExpression (CodeDelegateCreateExpression e) {}
+                       protected override void GenerateDelegateInvokeExpression (CodeDelegateInvokeExpression e) {}
+                       protected override void GenerateEntryPointMethod (CodeEntryPointMethod m, CodeTypeDeclaration d) {}
+                       protected override void GenerateEvent (CodeMemberEvent ev, CodeTypeDeclaration d) {}
+                       protected override void GenerateEventReferenceExpression (CodeEventReferenceExpression e) {}
+                       protected override void GenerateExpressionStatement (CodeExpressionStatement statement) {}
+                       protected override void GenerateField (CodeMemberField f) {}
+                       protected override void GenerateFieldReferenceExpression (CodeFieldReferenceExpression e) {}
+                       protected override void GenerateGotoStatement (CodeGotoStatement statement) {}
+                       protected override void GenerateIndexerExpression (CodeIndexerExpression e) {}
+                       protected override void GenerateIterationStatement (CodeIterationStatement s) {}
+                       protected override void GenerateLabeledStatement (CodeLabeledStatement statement) {}
+                       protected override void GenerateLinePragmaStart (CodeLinePragma p) {}
+                       protected override void GenerateLinePragmaEnd (CodeLinePragma p) {}
+                       protected override void GenerateMethod (CodeMemberMethod m, CodeTypeDeclaration d) {}
+                       protected override void GenerateMethodInvokeExpression (CodeMethodInvokeExpression e) {}
+                       protected override void GenerateMethodReferenceExpression (CodeMethodReferenceExpression e) {}
+                       protected override void GenerateMethodReturnStatement (CodeMethodReturnStatement e) {}
+                       protected override void GenerateNamespaceStart (CodeNamespace ns) {}
+                       protected override void GenerateNamespaceEnd (CodeNamespace ns) {}
+                       protected override void GenerateObjectCreateExpression (CodeObjectCreateExpression e) {}
+                       protected override void GenerateProperty (CodeMemberProperty p, CodeTypeDeclaration d) {}
+                       protected override void GeneratePropertyReferenceExpression (CodePropertyReferenceExpression e) {}
+                       protected override void GeneratePropertySetValueReferenceExpression (CodePropertySetValueReferenceExpression e) {}
+                       protected override void GenerateRemoveEventStatement (CodeRemoveEventStatement statement) {}
+                       protected override void GenerateSnippetExpression (CodeSnippetExpression e) {}
+                       protected override void GenerateSnippetMember (CodeSnippetTypeMember m) {}
+                       protected override void GenerateThisReferenceExpression (CodeThisReferenceExpression e) {}
+                       protected override void GenerateThrowExceptionStatement (CodeThrowExceptionStatement s) {}
+                       protected override void GenerateTryCatchFinallyStatement (CodeTryCatchFinallyStatement s) {}
+                       protected override void GenerateTypeEnd (CodeTypeDeclaration declaration) {}
+                       protected override void GenerateTypeConstructor (CodeTypeConstructor constructor) {}
+                       protected override void GenerateTypeStart (CodeTypeDeclaration declaration) {}
+                       protected override void GenerateVariableDeclarationStatement (CodeVariableDeclarationStatement e) {}
+                       protected override void GenerateVariableReferenceExpression (CodeVariableReferenceExpression e) {}
+                       protected override void OutputType (CodeTypeReference t) {}
+                       protected override string QuoteSnippetString (string value) { return string.Empty; }
+                       protected override string CreateEscapedIdentifier (string value) { return string.Empty; }
+                       protected override string CreateValidIdentifier (string value) { return string.Empty; }
+                       protected override string GetTypeOutput (CodeTypeReference type) { return string.Empty; }
+                       protected override bool IsValidIdentifier (string value) { return false; }
+                       protected override bool Supports (GeneratorSupport supports) { return false; }
+               }
+       }
+}
index 2e4d104b2395b8dcb8ee8b4d6aa45c24febd6a3b..58277c22f22138ba3c475013cd44fffeb7a75519 100644 (file)
@@ -14,7 +14,7 @@ using System.IO;
 
 using NUnit.Framework;
 
-namespace CodeGeneratorTest
+namespace MonoTests.System.CodeDom.Compiler
 {
        [TestFixture]
        public class MockCodeGenerator : CodeGenerator
index b9ab0236b678812f9f949007a8aaa4a937c95504..7edb8b952e04c969da308a4a3f466617f187b4a3 100644 (file)
@@ -15,7 +15,7 @@ using NUnit.Framework;
 namespace MonoTests.System.Collections.Specialized {
 
        [TestFixture]
-       public class BasicOperationsTest : Assertion {
+       public class BasicOperationsTest {
 
                protected NameValueCollection nvc;
                private static Random rnd;
@@ -53,44 +53,44 @@ namespace MonoTests.System.Collections.Specialized {
                public void AddRemoveClearSetGet() 
                {
                        nvc.Clear();
-                       Assert(nvc.Count==0&& !nvc.HasKeys());
+                       Assert.AreEqual (0, nvc.Count);
+                       Assert.IsFalse(nvc.HasKeys());
 
                        SetDefaultData();
-                       Assert(nvc.Count==4);
-                       Assert("Get operation returns wrong result.\n"+FormatForPrinting(nvc),(nvc.Get(0).Equals("this"))&&(nvc.Get("k1").Equals("this")));
+                       Assert.AreEqual(4, nvc.Count);
+                       Assert.IsTrue((nvc.Get(0).Equals("this"))&&(nvc.Get("k1").Equals("this")), "Get operation returns wrong result.\n"+FormatForPrinting(nvc));
 
 
                        nvc.Add("k2","programmer");
-                       Assert(nvc["k2"].Equals("test,programmer"));
+                       Assert.AreEqual("test,programmer", nvc["k2"]);
 
                        nvc["k2"]="project";
                        nvc.Add("k2","project");
-                       Assert(nvc.Count==4);
-                       Assert("Wrong effect of add(samekey,samevalue)\n"+FormatForPrinting(nvc), nvc["k2"].Equals("project,project"));
+                       Assert.AreEqual(4, nvc.Count);
+                       Assert.AreEqual("project,project", nvc["k2"], "Wrong effect of add(samekey,samevalue)\n"+FormatForPrinting(nvc));
                        // TODO: add Remove test
                        nvc.Remove("k4");
-                       Assert("wrong nvc.Count="+nvc.Count,nvc.Count==3);
-                       Assert(nvc["k4"]==null);
+                       Assert.AreEqual(3, nvc.Count);
+                       Assert.IsNull(nvc["k4"]);
                        
                        NameValueCollection nvc1 = new NameValueCollection();
                        nvc1["k1"]="these";
                        nvc1["k5"]="!";
                        nvc.Add(nvc1);
-                       Assert(FormatForPrinting(nvc)+"Count is wrong after Add(nvc1) Count="+nvc.Count,nvc.Count==4);
-                       Assert("Values are wrong after Add(nvc1)",(nvc["k1"].Equals("this,these"))&&(nvc["k5"].Equals("!")));
+                       Assert.AreEqual (4, nvc.Count, FormatForPrinting(nvc)+"Count is wrong after Add(nvc1)");
+                       Assert.IsTrue((nvc["k1"].Equals("this,these"))&&(nvc["k5"].Equals("!")), "Values are wrong after Add(nvc1)");
                        
                        nvc.Set("k3","accomplished");
-                       Assert("Wrong result of Set operation",nvc["k3"].Equals("accomplished"));
-                       
+                       Assert.AreEqual("accomplished", nvc["k3"], "Wrong result of Set operation");
                }
                
                [Test]
                public void GetKeyGetValues()
                {
                        SetDefaultData();
-                       Assert(nvc.GetKey(0).Equals("k1"));
+                       Assert.AreEqual ("k1", nvc.GetKey(0));
                        string[] values = nvc.GetValues(0);
-                       Assert(values[0].Equals("this"));
+                       Assert.AreEqual ("this", values[0]);
                        
                }
                
@@ -125,14 +125,16 @@ namespace MonoTests.System.Collections.Specialized {
                                }
                        }
 
-                       Assert(nvc.Count==n);
+                       Assert.AreEqual (n, nvc.Count);
 
                        for (int i=0;i<n;i++) {
                                String key=cache[i];
                                String val=nvc[key] as String;
                                String err="nvc[\""+key+"\"]=\""+val+
                                      "\", expected \""+cache[i+max]+"\"";
-                               Assert(err,val!=null && val.Equals(cache[i+max]));
+                               
+                               Assert.IsNotNull (val);
+                               Assert.AreEqual (val, cache[i+max], err);
                        }
 
                        int r1=(n/3);
@@ -145,13 +147,14 @@ namespace MonoTests.System.Collections.Specialized {
 
                        for (int i=0;i<n;i++) {
                                if (i>=r1 && i<r2) {
-                                       Assert(nvc[cache[i]]==null);
+                                       Assert.IsNull (nvc[cache[i]]);
                                } else {
                                        String key=cache[i];
                                        String val=nvc[key] as String;
                                        String err="ht[\""+key+"\"]=\""+val+
                                              "\", expected \""+cache[i+max]+"\"";
-                                       Assert(err,val!=null && val.Equals(cache[i+max]));
+                                       
+                                       Assert.AreEqual (val, cache[i+max], err);
                                }
                        }
 
index 1cd9d9aa10e5e084ea7f22ba881c4684d8648b64..115965b1a32347df62e23039535440318d240638 100644 (file)
@@ -41,26 +41,26 @@ namespace MonoTests.System.Collections.Specialized {
                [Test]
                public void SimpleCount() 
                {
-                       Assertion.Assert(sc.Count == 7);
+                       Assert.AreEqual(7, sc.Count);
                }
                
                [Test]
                public void SimpleIsReadOnly() 
                {
-                       Assertion.Assert(!sc.IsReadOnly);
+                       Assert.IsFalse(sc.IsReadOnly);
                }
                
                [Test]
                public void SimpleIsSynchronized() 
                {
-                       Assertion.Assert(!sc.IsSynchronized);
+                       Assert.IsFalse(sc.IsSynchronized);
                }
                
                [Test]
                public void SimpleItemGet() 
                {
                        for(int i = 0; i < strings.Length; i++) {
-                               Assertion.Assert(strings[i].Equals(sc[i]));
+                               Assert.AreEqual(strings[i], sc[i]);
                        }
                }
                
@@ -68,24 +68,21 @@ namespace MonoTests.System.Collections.Specialized {
                public void SimpleItemSet() 
                {
                        sc[0] = "bob";
-                       Assertion.Assert(sc[0].Equals("bob"));
+                       Assert.AreEqual("bob", sc[0]);
                }
                
                [Test]
-#if NET_2_0
-               [Category ("NotDotNet")] // SyncRoot != this on 2.0
-#endif
                public void SimpleSyncRoot() 
                {
-                       Assertion.Assert(sc.Equals(sc.SyncRoot));
+                       Assert.AreEqual(sc, sc.SyncRoot);
                }
                
                [Test]
                public void SimpleAdd() 
                {
                        int index = sc.Add("chuck");
-                       Assertion.Assert(index == strings.Length);
-                       Assertion.Assert(sc[strings.Length].Equals("chuck"));
+                       Assert.AreEqual(strings.Length, index);
+                       Assert.AreEqual("chuck", sc[strings.Length]);
                }
                
                [Test]
@@ -100,10 +97,10 @@ namespace MonoTests.System.Collections.Specialized {
                        int index = sc.Count;
                        sc.AddRange(newStrings);
                        
-                       Assertion.Assert(sc.Count == index + newStrings.Length);
+                       Assert.AreEqual(index + newStrings.Length, sc.Count);
                        
                        for (int i = 0; i+index <= sc.Count-1; i++) {
-                               Assertion.Assert(newStrings[i].Equals(sc[i+index]));
+                               Assert.AreEqual(newStrings[i], sc[i+index]);
                        }
                }
                
@@ -111,14 +108,14 @@ namespace MonoTests.System.Collections.Specialized {
                public void SimpleClear() 
                {
                        sc.Clear();
-                       Assertion.Assert(sc.Count == 0);
+                       Assert.AreEqual(0, sc.Count);
                }
                
                [Test]
                public void SimpleContains() 
                {
-                       Assertion.Assert(sc.Contains(strings[0]));
-                       Assertion.Assert(!sc.Contains("NOT CONTAINED"));
+                       Assert.IsTrue(sc.Contains(strings[0]));
+                       Assert.IsFalse(sc.Contains("NOT CONTAINED"));
                }
                
                [Test]
@@ -127,7 +124,7 @@ namespace MonoTests.System.Collections.Specialized {
                        string[] copyArray = new string[sc.Count];
                        sc.CopyTo(copyArray, 0);
                        for (int i = 0; i < copyArray.Length; i++) {
-                               Assertion.Assert(copyArray[i] == sc[i]);
+                               Assert.AreEqual(copyArray[i], sc[i]);
                        }
                }
                
@@ -136,7 +133,7 @@ namespace MonoTests.System.Collections.Specialized {
                {
                        int index = 0;
                        foreach(string s in sc) {
-                               Assertion.Assert(s.Equals(strings[index]));
+                               Assert.AreEqual(s, strings[index]);
                                index++;
                        }
                }
@@ -144,7 +141,7 @@ namespace MonoTests.System.Collections.Specialized {
                [Test]
                public void SimpleIndexOf() 
                {
-                       Assertion.Assert(sc.IndexOf(strings[0]) == 0);
+                       Assert.AreEqual(0, sc.IndexOf(strings[0]));
                }
                
                [Test]
@@ -159,11 +156,11 @@ namespace MonoTests.System.Collections.Specialized {
                        
                        sc.Insert(index, newStr);
                        
-                       Assertion.Assert(sc.Count == oldCount + 1);
-                       Assertion.Assert(sc[index].Equals(newStr));
-                       Assertion.Assert(sc[index-1].Equals(before));
-                       Assertion.Assert(sc[index+1].Equals(current));
-                       Assertion.Assert(sc[index+2].Equals(after));
+                       Assert.AreEqual(oldCount + 1, sc.Count);
+                       Assert.AreEqual(newStr, sc[index]);
+                       Assert.AreEqual(before, sc[index-1]);
+                       Assert.AreEqual(current, sc[index+1]);
+                       Assert.AreEqual(after, sc[index+2]);
                }
                
                [Test]
@@ -171,8 +168,8 @@ namespace MonoTests.System.Collections.Specialized {
                {
                        int oldCount = sc.Count;
                        sc.Remove(strings[0]);
-                       Assertion.Assert(oldCount == sc.Count + 1);
-                       Assertion.Assert(!sc.Contains(strings[0]));
+                       Assert.AreEqual(sc.Count + 1, oldCount);
+                       Assert.IsFalse(sc.Contains(strings[0]));
                }
                
                [Test]
@@ -183,8 +180,8 @@ namespace MonoTests.System.Collections.Specialized {
                        string after = sc[index+1];
                        
                        sc.RemoveAt(index);
-                       Assertion.Assert(oldCount == sc.Count + 1);
-                       Assertion.Assert(sc[index].Equals(after));
+                       Assert.AreEqual(sc.Count + 1, oldCount);
+                       Assert.AreEqual(after, sc[index]);
                }
 
                [Test]
index 5fb4a9c5c65e50a4de5c14cb6d30f85aac4c10a6..f0c2c63ca6e9a1c4c33c3681f4c60e6b96d23de1 100644 (file)
@@ -165,6 +165,7 @@ namespace MonoTests.System.ComponentModel
                }
 
                [Test]
+               [SetCulture("en-US")]
                public void ConvertToString ()
                {
                        CultureInfo ciUS = new CultureInfo("en-US");
index d8e40b649981c8c5e9d28fcefdd1e1aed6199ae1..becaf2006921a33b284b803bf3d18fc45713f437 100644 (file)
@@ -45,61 +45,61 @@ namespace MonoTests.System.ComponentModel
                        EventHandler two = new EventHandler (Deleg2);
                        EventHandler d;
 
-                       Assertion.AssertEquals ("All #01", null, list [i1]);
-                       Assertion.AssertEquals ("All #02", null, list [i2]);
+                       Assert.IsNull (list [i1], "All #01");
+                       Assert.IsNull (list [i2], "All #02");
 
                        list.AddHandler (i1, one);
                        d = list [i1] as EventHandler;
-                       Assertion.Assert ("All #03", d != null);
+                       Assert.IsNotNull (d, "All #03");
 
                        d (this, EventArgs.Empty);
-                       Assertion.AssertEquals ("All #04", 1, calls);
+                       Assert.AreEqual (1, calls, "All #04");
 
                        list.AddHandler (i2, two);
                        d = list [i1] as EventHandler;
-                       Assertion.Assert ("All #05", d != null);
+                       Assert.IsNotNull (d, "All #05");
 
                        d (this, EventArgs.Empty);
-                       Assertion.AssertEquals ("All #06", 2, calls);
+                       Assert.AreEqual (2, calls, "All #06");
 
                        d = list [i2] as EventHandler;
-                       Assertion.Assert ("All #07", d != null);
+                       Assert.IsNotNull (d, "All #07");
 
                        d (this, EventArgs.Empty);
-                       Assertion.AssertEquals ("All #08", 4, calls);
+                       Assert.AreEqual (4, calls, "All #08");
 
                        list.AddHandler (i2, two);
                        d = list [i2] as EventHandler;
-                       Assertion.Assert ("All #08", d != null);
+                       Assert.IsNotNull (d, "All #08");
 
                        d (this, EventArgs.Empty);
-                       Assertion.AssertEquals ("All #09", 16, calls);
+                       Assert.AreEqual (16, calls, "All #09");
 
                        list.RemoveHandler (i1, one);
                        d = list [i1] as EventHandler;
-                       Assertion.Assert ("All #10", d == null);
+                       Assert.IsNull (d, "All #10");
 
                        list.RemoveHandler (i2, two);
                        d = list [i2] as EventHandler;
-                       Assertion.Assert ("All #11", d != null);
+                       Assert.IsNotNull (d, "All #11");
 
                        list.RemoveHandler (i2, two);
                        d = list [i2] as EventHandler;
-                       Assertion.Assert ("All #12", d == null);
+                       Assert.IsNull (d, "All #12");
 
                        list.AddHandler (i1, one);
                        d = list [i1] as EventHandler;
-                       Assertion.Assert ("All #13", d != null);
+                       Assert.IsNotNull (d, "All #13");
 
                        list.AddHandler (i2, two);
                        d = list [i2] as EventHandler;
-                       Assertion.Assert ("All #14", d != null);
+                       Assert.IsNotNull (d, "All #14");
 
                        list.AddHandler (i1, null);
-                       Assertion.Assert ("All #15", list [i1] != null);
+                       Assert.IsNotNull (list [i1], "All #15");
 
                        list.AddHandler (i2, null);
-                       Assertion.Assert ("All #16", list [i2] != null);
+                       Assert.IsNotNull (list [i2], "All #16");
 
                        list.Dispose ();
                }
@@ -112,11 +112,11 @@ namespace MonoTests.System.ComponentModel
                        
                        list.AddHandler (null, one);
                        EventHandler d = list [null] as EventHandler;
-                       Assertion.Assert ("NullKey #01", d != null);
+                       Assert.IsNotNull (d, "NullKey #01");
                        
                        list.RemoveHandler (null, one);
                        d = list [null] as EventHandler;
-                       Assertion.Assert ("NullKey #02", d == null);
+                       Assert.IsNull (d, "NullKey #02");
                }
        }
 }
diff --git a/mcs/class/System/Test/System.Diagnostics/DebugTest.cs b/mcs/class/System/Test/System.Diagnostics/DebugTest.cs
new file mode 100644 (file)
index 0000000..3d7f254
--- /dev/null
@@ -0,0 +1,67 @@
+//
+// MonoTests.System.Diagnostics.DebugTest.cs
+//
+// Author:
+//     John R. Hicks (angryjohn69@nc.rr.com)
+//
+// (C) 2002
+using System;
+using System.Diagnostics;
+using NUnit.Framework;
+
+namespace MonoTests.System.Diagnostics
+{
+               [TestFixture]
+               public class DebugTest2
+               {
+                       [SetUp]
+                       protected void SetUp()
+                       {
+                               Debug.Listeners.Add(new TextWriterTraceListener(Console.Error));        
+                       }
+                       
+                       [TearDown]
+                       protected void TearDown()
+                       {
+                               
+                       }
+
+                       [Test]
+                       public void TestAssert()
+                       {
+                               Debug.Assert(false, "Testing Assertions");
+                       }
+
+                       [Test]                  
+                       public void TestFail ()
+                       {
+                               Debug.Fail("Testing Fail method");
+                       }
+
+                       [Test]                  
+                       public void TestWrite()
+                       {
+                               Debug.Write("Testing Write", "Testing the output of the Write method");
+                       }
+
+                       [Test]                  
+                       public void TestWriteIf()
+                       {
+                               Debug.WriteIf(true, "Testing WriteIf");
+                               Debug.WriteIf(false, "Testing WriteIf", "Passed false");
+                       }
+
+                       [Test]                  
+                       public void TestWriteLine()
+                       {
+                               Debug.WriteLine("Testing WriteLine method");
+                       }
+
+                       [Test]                  
+                       public void TestWriteLineIf()
+                       {
+                               Debug.WriteLineIf(true, "Testing WriteLineIf");
+                               Debug.WriteLineIf(false, "Testing WriteLineIf", "Passed false");
+                       }
+               }
+}
index fb54e83931b7aed1708eb4e11d1112a241e3c877..866d5a5728638e017a4acf72c3ac5063eccf6777 100644 (file)
@@ -5,8 +5,10 @@
 //     Gonzalo Paniagua Javier (gonzalo@novell.com)
 //      Daniel Nauck    (dna(at)mono-project(dot)de)
 //     Sebastien Pouliot  <sebastien@ximian.com>
+//  Marek Safar (marek.safar@gmail.com)
 //
 // Copyright (C) 2004,2009 Novell, Inc (http://www.novell.com)
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
 //
 
 using System;
@@ -392,6 +394,29 @@ namespace MonoTests.System.Net {
                        }
                }
 
+               [Test]
+               public void Add_LocalWithPort ()
+               {
+                       CookieContainer cc = new CookieContainer ();
+                       var orig = new Cookie ("mycookie", "vv");
+                       cc.Add (new Uri ("http://localhost:8810/"), orig);
+                       var c = cc.GetCookies (new Uri ("http://localhost:8810/"))[0];
+                       Assert.AreEqual ("", c.Comment, "#1");
+                       Assert.IsNull (c.CommentUri, "#2");
+                       Assert.IsFalse (c.Discard, "#3");
+                       Assert.AreEqual ("localhost", c.Domain, "#4");
+                       Assert.IsFalse (c.Expired, "#5");
+                       Assert.AreEqual (DateTime.MinValue, c.Expires, "#6");
+                       Assert.IsFalse (c.HttpOnly, "#7");
+                       Assert.AreEqual ("mycookie", c.Name, "#8");
+                       Assert.AreEqual ("/", c.Path, "#9");
+                       Assert.AreEqual ("", c.Port, "#10");
+                       Assert.IsFalse (c.Secure, "#11");
+                       Assert.AreEqual ("vv", c.Value, "#13");
+                       Assert.AreEqual (0, c.Version, "#14");
+                       Assert.AreEqual ("mycookie=vv", c.ToString (), "#15");
+               }
+
                [Test] // Add (Cookie)
                public void Add1 ()
                {
index 3ceda9d62fd47ce3a513fbb20463b55366ccc3d5..986f7facba8cd5e641c0e7a54a50a66f51244234 100644 (file)
-//\r
-// SocketPermissionTest.cs - NUnit Test Cases for System.Net.SocketPermission\r
-//\r
-// Authors:\r
-//   Lawrence Pit (loz@cable.a2000.nl)\r
-//   Martin Willemoes Hansen (mwh@sysrq.dk)\r
-//\r
-// (C) 2003 Martin Willemoes Hansen\r
-//\r
-\r
-using NUnit.Framework;\r
-using System;\r
-using System.Net;\r
-using System.Collections;\r
-using System.Security;\r
-using System.Security.Permissions;\r
-\r
-namespace MonoTests.System.Net\r
-{\r
-\r
-[TestFixture]\r
-public class SocketPermissionTest\r
-{\r
-       SocketPermission s1;\r
-       SocketPermission s2;\r
-       \r
-       [SetUp]\r
-        public void GetReady () \r
-        {\r
-               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);\r
-               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "localhost", 8080);\r
-               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "123", SocketPermission.AllPorts);\r
-               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "www.ximian.com", SocketPermission.AllPorts);\r
-               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "120.4.3.2", SocketPermission.AllPorts);\r
-               //s1.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "www.google.com", 80);\r
-               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "1.*.10.*.99", SocketPermission.AllPorts);\r
-               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "128.0.0.1", SocketPermission.AllPorts);\r
-               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "0.0.0.0", SocketPermission.AllPorts);\r
-               s1.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", SocketPermission.AllPorts);\r
-\r
-               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.15", 80);\r
-               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "localhost", 8080);\r
-               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "123", 8080);\r
-               //s2.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "www.google.com", SocketPermission.AllPorts);\r
-               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "213.*.*.*", SocketPermission.AllPorts);\r
-               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "128.0.0.1", 9090);\r
-               s2.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "216.239.*.*", SocketPermission.AllPorts);\r
-               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "128.0.0.1", SocketPermission.AllPorts);\r
-               //s2.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "120.4.3.2", 80);\r
-               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "196.*.*.*", SocketPermission.AllPorts);\r
-               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "1.*.*.*.99", SocketPermission.AllPorts);\r
-               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.*.*", 9090);\r
-               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.7", SocketPermission.AllPorts);            \r
-       }\r
-\r
-        [Test]\r
-        public void IsSubsetOf ()\r
-        {\r
-               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);\r
-               s1.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", SocketPermission.AllPorts);\r
-               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.15", 80);\r
-               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.*.*", 9090);\r
-               \r
-               Assertion.Assert ("#1", !s1.IsSubsetOf (s2));\r
-               Assertion.Assert ("#2", !s2.IsSubsetOf (s1));\r
-\r
-               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);\r
-               s1.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", 9090);\r
-               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.15", 80);\r
-               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.*.*", 9090);\r
-               \r
-               Assertion.Assert ("#4", !s2.IsSubsetOf (s1));\r
-               \r
-               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.*.*", 80);\r
-               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.*", 80);\r
-               Assertion.Assert ("#5", s1.IsSubsetOf (s2));\r
-               Assertion.Assert ("#6", !s2.IsSubsetOf (s1));\r
-\r
-               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);\r
-               s1.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "10.11.*.*", 9090);\r
-               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);\r
-               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", SocketPermission.AllPorts);\r
-               Assertion.Assert ("#7", s1.IsSubsetOf (s2));\r
-               Assertion.Assert ("#8", !s2.IsSubsetOf (s1));\r
-       }\r
-       \r
-       [Test]\r
-       [Category("NotDotNet")]\r
-       public void IsSubsetOf2 ()\r
-       {\r
-               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);\r
-               s1.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", 9090);\r
-               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.15", 80);\r
-               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.*.*", 9090);\r
-               \r
-               Assertion.Assert ("#3: bug in MS.Net", s1.IsSubsetOf (s2));\r
-       }\r
-\r
-       [Test]\r
-       public void Intersect ()\r
-       {\r
-       }\r
-       \r
-    [Test]\r
-       public void Union ()\r
-       {\r
-       }\r
-       \r
-    [Test]\r
-       public void Xml ()\r
-       {\r
-               SecurityElement elem = s2.ToXml ();\r
-               s1.FromXml (elem);\r
-               Assertion.Assert ("#1", s2.IsSubsetOf (s1) && s1.IsSubsetOf (s2));\r
-       }\r
-}\r
-\r
-}\r
-\r
+//
+// SocketPermissionTest.cs - NUnit Test Cases for System.Net.SocketPermission
+//
+// Authors:
+//   Lawrence Pit (loz@cable.a2000.nl)
+//   Martin Willemoes Hansen (mwh@sysrq.dk)
+//
+// (C) 2003 Martin Willemoes Hansen
+//
+
+using NUnit.Framework;
+using System;
+using System.Net;
+using System.Collections;
+using System.Security;
+using System.Security.Permissions;
+
+namespace MonoTests.System.Net
+{
+
+[TestFixture]
+public class SocketPermissionTest
+{
+       SocketPermission s1;
+       SocketPermission s2;
+       
+       [SetUp]
+        public void GetReady () 
+        {
+               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);
+               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "localhost", 8080);
+               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "123", SocketPermission.AllPorts);
+               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "www.ximian.com", SocketPermission.AllPorts);
+               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "120.4.3.2", SocketPermission.AllPorts);
+               //s1.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "www.google.com", 80);
+               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "1.*.10.*.99", SocketPermission.AllPorts);
+               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "128.0.0.1", SocketPermission.AllPorts);
+               //s1.AddPermission(NetworkAccess.Accept, TransportType.All, "0.0.0.0", SocketPermission.AllPorts);
+               s1.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", SocketPermission.AllPorts);
+
+               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.15", 80);
+               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "localhost", 8080);
+               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "123", 8080);
+               //s2.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "www.google.com", SocketPermission.AllPorts);
+               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "213.*.*.*", SocketPermission.AllPorts);
+               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "128.0.0.1", 9090);
+               s2.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "216.239.*.*", SocketPermission.AllPorts);
+               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "128.0.0.1", SocketPermission.AllPorts);
+               //s2.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "120.4.3.2", 80);
+               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "196.*.*.*", SocketPermission.AllPorts);
+               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "1.*.*.*.99", SocketPermission.AllPorts);
+               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.*.*", 9090);
+               //s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.7", SocketPermission.AllPorts);            
+       }
+
+        [Test]
+        public void IsSubsetOf ()
+        {
+               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);
+               s1.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", SocketPermission.AllPorts);
+               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.15", 80);
+               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.*.*", 9090);
+               
+               Assert.IsFalse (s1.IsSubsetOf (s2), "#1");
+               Assert.IsFalse (s2.IsSubsetOf (s1), "#2");
+
+               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);
+               s1.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", 9090);
+               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.15", 80);
+               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.*.*", 9090);
+               
+               Assert.IsFalse (s2.IsSubsetOf (s1), "#4");
+               
+               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.*.*", 80);
+               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.*", 80);
+               Assert.IsTrue (s1.IsSubsetOf (s2), "#5");
+               Assert.IsFalse (s2.IsSubsetOf (s1), "#6");
+
+               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);
+               s1.AddPermission(NetworkAccess.Accept, TransportType.Tcp, "10.11.*.*", 9090);
+               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);
+               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", SocketPermission.AllPorts);
+               Assert.IsTrue (s1.IsSubsetOf (s2), "#7");
+               Assert.IsFalse (s2.IsSubsetOf (s1), "#8");
+       }
+       
+       [Test]
+       [Category("NotDotNet")]
+       public void IsSubsetOf2 ()
+       {
+               s1 = new SocketPermission(NetworkAccess.Connect, TransportType.Tcp, "12.13.14.15", 80);
+               s1.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.4.*", 9090);
+               s2 = new SocketPermission(NetworkAccess.Connect, TransportType.All, "12.13.14.15", 80);
+               s2.AddPermission(NetworkAccess.Accept, TransportType.All, "10.11.*.*", 9090);
+               
+               Assert.IsTrue (s1.IsSubsetOf (s2), "#3: bug in MS.Net");
+       }
+
+       [Test]
+       public void Intersect ()
+       {
+       }
+       
+    [Test]
+       public void Union ()
+       {
+       }
+       
+    [Test]
+       public void Xml ()
+       {
+               SecurityElement elem = s2.ToXml ();
+               s1.FromXml (elem);
+               Assert.IsTrue (s2.IsSubsetOf (s1) && s1.IsSubsetOf (s2), "#1");
+       }
+}
+
+}
+
diff --git a/mcs/class/System/Test/System.Security.Cryptography.X509Certificates/X509Cert20Test.cs b/mcs/class/System/Test/System.Security.Cryptography.X509Certificates/X509Cert20Test.cs
new file mode 100644 (file)
index 0000000..f230b59
--- /dev/null
@@ -0,0 +1,751 @@
+//
+// X509Cert20Test.cs - Unit Tests for new 2.0 features in X509Certificate
+//
+// Author:
+//     Sebastien Pouliot  <sebastien@ximian.com>
+//
+// Copyright (C) 2005-2006 Novell Inc. (http://www.novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+#if NET_2_0
+
+using NUnit.Framework;
+using System;
+using System.IO;
+using System.Runtime.InteropServices;
+using System.Runtime.Serialization;
+using System.Security;
+using System.Security.Cryptography;
+using System.Security.Cryptography.X509Certificates;
+using System.Text;
+
+namespace MonoTests.System.Security.Cryptography.X509Certificates {
+
+       [TestFixture]
+       public class X509Cert20Test {
+
+               static byte[] cert1 = { 0x30,0x82,0x01,0xFF,0x30,0x82,0x01,0x6C,0x02,0x05,0x02,0x72,0x00,0x06,0xE8,0x30,0x0D,0x06,0x09,0x2A,0x86,0x48,0x86,0xF7,0x0D,0x01,0x01,0x02,0x05,0x00,0x30,0x5F,0x31,0x0B,0x30,0x09,0x06,0x03,0x55,0x04,0x06,0x13,0x02,0x55,0x53,0x31,0x20,0x30,0x1E,0x06,0x03,0x55,0x04,0x0A,0x13,0x17,0x52,0x53,0x41,0x20,0x44,0x61,0x74,0x61,0x20,0x53,0x65,0x63,0x75,0x72,0x69,0x74,0x79,0x2C,0x20,0x49,0x6E,0x63,0x2E,0x31,0x2E,0x30,0x2C,0x06,0x03,0x55,0x04,0x0B,0x13,0x25,0x53,0x65,0x63,0x75,0x72,0x65,0x20,0x53,0x65,0x72,0x76,
+                       0x65,0x72,0x20,0x43,0x65,0x72,0x74,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6F,0x6E,0x20,0x41,0x75,0x74,0x68,0x6F,0x72,0x69,0x74,0x79,0x30,0x1E,0x17,0x0D,0x39,0x36,0x30,0x33,0x31,0x32,0x31,0x38,0x33,0x38,0x34,0x37,0x5A,0x17,0x0D,0x39,0x37,0x30,0x33,0x31,0x32,0x31,0x38,0x33,0x38,0x34,0x36,0x5A,0x30,0x61,0x31,0x0B,0x30,0x09,0x06,0x03,0x55,0x04,0x06,0x13,0x02,0x55,0x53,0x31,0x13,0x30,0x11,0x06,0x03,0x55,0x04,0x08,0x13,0x0A,0x43,0x61,0x6C,0x69,0x66,0x6F,0x72,0x6E,0x69,0x61,0x31,0x14,0x30,0x12,0x06,0x03,
+                       0x55,0x04,0x0A,0x13,0x0B,0x43,0x6F,0x6D,0x6D,0x65,0x72,0x63,0x65,0x4E,0x65,0x74,0x31,0x27,0x30,0x25,0x06,0x03,0x55,0x04,0x0B,0x13,0x1E,0x53,0x65,0x72,0x76,0x65,0x72,0x20,0x43,0x65,0x72,0x74,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6F,0x6E,0x20,0x41,0x75,0x74,0x68,0x6F,0x72,0x69,0x74,0x79,0x30,0x70,0x30,0x0D,0x06,0x09,0x2A,0x86,0x48,0x86,0xF7,0x0D,0x01,0x01,0x01,0x05,0x00,0x03,0x5F,0x00,0x30,0x5C,0x02,0x55,0x2D,0x58,0xE9,0xBF,0xF0,0x31,0xCD,0x79,0x06,0x50,0x5A,0xD5,0x9E,0x0E,0x2C,0xE6,0xC2,0xF7,0xF9,
+                       0xD2,0xCE,0x55,0x64,0x85,0xB1,0x90,0x9A,0x92,0xB3,0x36,0xC1,0xBC,0xEA,0xC8,0x23,0xB7,0xAB,0x3A,0xA7,0x64,0x63,0x77,0x5F,0x84,0x22,0x8E,0xE5,0xB6,0x45,0xDD,0x46,0xAE,0x0A,0xDD,0x00,0xC2,0x1F,0xBA,0xD9,0xAD,0xC0,0x75,0x62,0xF8,0x95,0x82,0xA2,0x80,0xB1,0x82,0x69,0xFA,0xE1,0xAF,0x7F,0xBC,0x7D,0xE2,0x7C,0x76,0xD5,0xBC,0x2A,0x80,0xFB,0x02,0x03,0x01,0x00,0x01,0x30,0x0D,0x06,0x09,0x2A,0x86,0x48,0x86,0xF7,0x0D,0x01,0x01,0x02,0x05,0x00,0x03,0x7E,0x00,0x54,0x20,0x67,0x12,0xBB,0x66,0x14,0xC3,0x26,0x6B,0x7F,
+                       0xDA,0x4A,0x25,0x4D,0x8B,0xE0,0xFD,0x1E,0x53,0x6D,0xAC,0xA2,0xD0,0x89,0xB8,0x2E,0x90,0xA0,0x27,0x43,0xA4,0xEE,0x4A,0x26,0x86,0x40,0xFF,0xB8,0x72,0x8D,0x1E,0xE7,0xB7,0x77,0xDC,0x7D,0xD8,0x3F,0x3A,0x6E,0x55,0x10,0xA6,0x1D,0xB5,0x58,0xF2,0xF9,0x0F,0x2E,0xB4,0x10,0x55,0x48,0xDC,0x13,0x5F,0x0D,0x08,0x26,0x88,0xC9,0xAF,0x66,0xF2,0x2C,0x9C,0x6F,0x3D,0xC3,0x2B,0x69,0x28,0x89,0x40,0x6F,0x8F,0x35,0x3B,0x9E,0xF6,0x8E,0xF1,0x11,0x17,0xFB,0x0C,0x98,0x95,0xA1,0xC2,0xBA,0x89,0x48,0xEB,0xB4,0x06,0x6A,0x22,0x54,
+                       0xD7,0xBA,0x18,0x3A,0x48,0xA6,0xCB,0xC2,0xFD,0x20,0x57,0xBC,0x63,0x1C };
+
+               static public byte[] farscape_pfx = { 0x30, 0x82, 0x06, 0xA3, 0x02, 0x01, 0x03, 0x30, 0x82, 0x06, 0x63, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x06, 0x54, 0x04, 0x82, 0x06, 0x50, 0x30, 0x82, 0x06, 0x4C, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
+                       0x0E, 0x04, 0x08, 0x67, 0xFE, 0x3A, 0x52, 0x75, 0xF3, 0x82, 0x1F, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0x31, 0x6B, 0x00, 0xFA, 0x73, 0xE6, 0x8D, 0x3D, 0x62, 0x93, 0x41, 0xA1, 0x44, 0x04, 0x17, 0x8D, 0x66, 0x7A, 0x75, 0x14, 0x89, 0xA8, 0xD1, 0x4D, 0x2A, 0xD7, 0x20, 0x27, 0x71, 0x58, 0x81, 0x16, 0xB5, 0xA6, 0x41, 0x75, 0x92, 0xB2, 0xF4, 0x0C, 0xAA, 0x9B, 0x00, 0x46, 0x85, 0x85, 0x3B, 0x09, 0x2A, 0x62, 0x33, 0x3F, 0x3D, 0x06, 0xC7, 0xE7, 0x16, 0x0C, 0xA7, 0x1D, 0x9C, 0xDA, 0x9D, 0xD3, 0xC9, 0x05, 0x60, 0xA5, 0xBE, 0xF0, 0x07, 0xD5, 0xA9, 0x4F, 0x8A, 0x80, 0xF8, 0x55, 0x7B, 0x7B, 0x3C, 
+                       0xA0, 0x7C, 0x29, 0x29, 0xAB, 0xB1, 0xE1, 0x5A, 0x25, 0xE3, 0x23, 0x6A, 0x56, 0x98, 0x37, 0x68, 0xAF, 0x9C, 0x87, 0xBB, 0x21, 0x6E, 0x68, 0xBE, 0xAE, 0x65, 0x0C, 0x41, 0x8F, 0x5C, 0x3A, 0xB8, 0xB1, 0x9D, 0x42, 0x37, 0xE4, 0xA0, 0x37, 0xA6, 0xB8, 0xAC, 0x85, 0xD7, 0x85, 0x27, 0x68, 0xD0, 0xB6, 0x3D, 0xC7, 0x39, 0x92, 0x41, 0x46, 0x24, 0xDD, 0x08, 0x57, 0x22, 0x6A, 0xC0, 0xB7, 0xAD, 0x52, 0xC6, 0x7F, 0xE5, 0x74, 0x6A, 0x5E, 0x28, 0xA3, 0x85, 0xBD, 0xE8, 0xAD, 0x5D, 0xA3, 0x55, 0xE6, 0x63, 0x15, 0x56, 0x7B, 0x01, 0x26, 0x68, 0x5F, 0x11, 0xA3, 0x12, 0x37, 0x02, 0xA5, 0xD0, 0xB7, 0x73, 0x0C, 0x7C, 
+                       0x97, 0xE1, 0xC6, 0x2F, 0x98, 0x82, 0x67, 0x2F, 0x5F, 0x3F, 0xBE, 0x32, 0x16, 0x25, 0x9D, 0x51, 0x48, 0x32, 0xCB, 0x42, 0xD1, 0x31, 0x07, 0xBE, 0x5D, 0xF8, 0xCD, 0x2C, 0x38, 0x0A, 0x33, 0x3B, 0x7B, 0x04, 0x84, 0xAE, 0x9C, 0xA7, 0x6B, 0x36, 0x39, 0x12, 0x87, 0x9D, 0x5B, 0x56, 0x00, 0x44, 0x11, 0xB1, 0xE2, 0x78, 0x14, 0x60, 0xF3, 0xE4, 0x1A, 0x08, 0x14, 0xC0, 0x9E, 0x49, 0x9F, 0xE0, 0x4C, 0xEC, 0x95, 0x15, 0x18, 0x48, 0x0E, 0xB9, 0x0B, 0x3A, 0xFE, 0x45, 0xB0, 0x2D, 0x0D, 0x4F, 0x94, 0x5A, 0x3C, 0x43, 0xB7, 0x40, 0x8E, 0x7B, 0xA2, 0x8E, 0x23, 0x9F, 0x75, 0x97, 0xE7, 0x21, 0x0D, 0xEB, 0xA3, 0x9D, 
+                       0x6C, 0xC0, 0xDC, 0x73, 0xED, 0x15, 0x98, 0xE3, 0xE8, 0x32, 0x2C, 0x12, 0x92, 0x45, 0x25, 0x45, 0x76, 0x18, 0xF5, 0x97, 0x7F, 0xAC, 0xCE, 0xCF, 0x23, 0xF7, 0xD1, 0xCF, 0x06, 0xAB, 0x82, 0x96, 0x1F, 0xF8, 0x68, 0x4F, 0x5D, 0xE1, 0x09, 0xAA, 0xCB, 0xB3, 0x50, 0x85, 0x46, 0x72, 0x14, 0x6C, 0x49, 0x84, 0x57, 0x55, 0x00, 0x78, 0x3E, 0xD9, 0xAA, 0xBD, 0xCC, 0xE2, 0x7B, 0x18, 0xAA, 0x2E, 0x5D, 0xB9, 0x28, 0xEA, 0x8F, 0x8C, 0xFA, 0xB7, 0x06, 0x27, 0x07, 0x89, 0x41, 0x3F, 0x66, 0x1A, 0x91, 0xCA, 0xE9, 0xEC, 0x09, 0x12, 0x1C, 0x67, 0xB2, 0x2A, 0x8B, 0x4A, 0xF0, 0x97, 0x17, 0xDC, 0x3E, 0xCD, 0x9F, 0x03, 
+                       0x15, 0xEF, 0x03, 0x84, 0x08, 0x4A, 0x73, 0xAE, 0xE4, 0x07, 0x30, 0x27, 0xF7, 0x25, 0x69, 0x9D, 0x6C, 0x7D, 0x81, 0x88, 0xCC, 0xFA, 0xD4, 0xC7, 0x64, 0x11, 0xC0, 0xC8, 0x2C, 0x23, 0xF6, 0xFF, 0x9B, 0xE3, 0xC8, 0x89, 0x85, 0x0B, 0x3E, 0x81, 0xD8, 0x9C, 0xBD, 0xD0, 0x2D, 0xCD, 0x15, 0xA9, 0x30, 0x84, 0xF7, 0x6D, 0xEF, 0x62, 0x3B, 0xA7, 0x8C, 0xC2, 0x93, 0x90, 0x6F, 0x91, 0xB4, 0x8A, 0x71, 0x4E, 0x41, 0x4E, 0x5C, 0x67, 0xB5, 0x49, 0xF8, 0x56, 0x3A, 0x83, 0x03, 0x4F, 0xB1, 0xF6, 0xB7, 0x31, 0x5B, 0x68, 0x26, 0x70, 0x89, 0xB1, 0x1E, 0x67, 0x4F, 0xBA, 0xE7, 0xD9, 0xDF, 0x91, 0xD8, 0xFB, 0x8A, 0xDD, 
+                       0xB2, 0xD3, 0x4B, 0xBB, 0x9F, 0x5C, 0xA3, 0x04, 0x2C, 0x87, 0xBC, 0xD5, 0xBE, 0x8C, 0xD7, 0xCF, 0x9B, 0x72, 0x82, 0xA6, 0x99, 0xDA, 0xD7, 0x66, 0x48, 0xE7, 0x8F, 0xE9, 0x48, 0x56, 0x9D, 0xD2, 0xB9, 0x28, 0x84, 0x4F, 0x6A, 0x83, 0xB2, 0xB9, 0x4D, 0x91, 0x10, 0x58, 0x22, 0x4C, 0xE7, 0x9D, 0xC6, 0x0C, 0x74, 0xF4, 0x16, 0x58, 0x30, 0xB7, 0xB7, 0x96, 0x39, 0x6C, 0x5D, 0xFA, 0xB2, 0x03, 0x8C, 0x98, 0xD2, 0xC0, 0x64, 0xB8, 0x05, 0x29, 0x4F, 0xF0, 0x4C, 0x43, 0x48, 0xD3, 0xD8, 0xBD, 0xC7, 0xC1, 0xEA, 0x39, 0x2A, 0xDF, 0xD4, 0xDA, 0x79, 0x7C, 0xB9, 0x06, 0xC7, 0x10, 0x8D, 0x8B, 0xF1, 0xA8, 0x8E, 0x44, 
+                       0x9E, 0x99, 0xFF, 0x81, 0x84, 0x8F, 0xD0, 0x38, 0xE1, 0xF0, 0x5A, 0x12, 0x5F, 0xC5, 0xA6, 0xED, 0x6D, 0xEE, 0xE7, 0x69, 0xC0, 0xA2, 0xB4, 0x13, 0xCA, 0x7A, 0x5D, 0xDE, 0x88, 0x75, 0xE7, 0xE2, 0x6D, 0x8A, 0xEC, 0x0F, 0x88, 0x3F, 0xE2, 0xCB, 0x60, 0xF0, 0x6A, 0xEC, 0xD0, 0xF4, 0x0D, 0x11, 0xC2, 0x84, 0x19, 0x67, 0x52, 0xAD, 0xC0, 0xC0, 0x20, 0x84, 0x6D, 0x7D, 0xEA, 0xD2, 0xF9, 0x3F, 0xE5, 0x58, 0x00, 0xED, 0x24, 0xD6, 0x50, 0x9B, 0x80, 0x80, 0x0A, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
+                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
+                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x02, 0xB7, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x02, 0xA8, 0x30, 0x82, 0x02, 0xA4, 0x02, 0x01, 0x00, 0x30, 0x82, 0x02, 0x9D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
+                       0x06, 0x30, 0x0E, 0x04, 0x08, 0xB8, 0x22, 0xEA, 0x3C, 0x70, 0x6A, 0xFC, 0x39, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x02, 0x70, 0x76, 0xBE, 0x5B, 0xD5, 0x3D, 0x05, 0xC1, 0xDB, 0x10, 0xA3, 0x02, 0xBB, 0x7F, 0x0A, 0x8B, 0x54, 0xC1, 0x7D, 0x19, 0xDA, 0x7E, 0x82, 0xDF, 0xAD, 0x6B, 0x42, 0xC2, 0x95, 0x95, 0x00, 0x6E, 0x82, 0x77, 0xD5, 0x42, 0x6E, 0x21, 0xA2, 0x95, 0xB4, 0x98, 0xF5, 0xDD, 0x18, 0x6F, 0xC4, 0xF3, 0xB6, 0x93, 0xA0, 0x6C, 0xF4, 0x34, 0x7A, 0x48, 0x72, 0x08, 0xB1, 0x28, 0x51, 0x54, 0x10, 0x7F, 0x35, 0xB2, 0xE5, 0x89, 0x5C, 0x0A, 0x14, 0x31, 0x1C, 0x9D, 0xA9, 0xE4, 0x94, 0x91, 0x28, 0x65, 
+                       0xC4, 0xE7, 0x5E, 0xA9, 0x37, 0x08, 0x3D, 0xB1, 0x16, 0x61, 0x9D, 0xA9, 0x44, 0x6F, 0x20, 0x0C, 0x55, 0xD7, 0xCC, 0x48, 0x82, 0x13, 0x5D, 0xE1, 0xBD, 0x9D, 0xCE, 0x64, 0x28, 0x6D, 0x69, 0x4E, 0x08, 0x53, 0x09, 0xE0, 0xCC, 0xA8, 0x79, 0x04, 0xCF, 0xFA, 0x35, 0x1C, 0xA6, 0x70, 0x37, 0x64, 0x70, 0x74, 0xF8, 0xD0, 0xC4, 0x34, 0x0F, 0x71, 0xEF, 0x57, 0xC2, 0x43, 0x7D, 0xFA, 0xE5, 0x1B, 0x8C, 0x15, 0xA5, 0x08, 0x60, 0x78, 0xAF, 0xDA, 0x36, 0xDF, 0x79, 0x2D, 0xD7, 0x54, 0x35, 0xD7, 0x8D, 0x99, 0xD5, 0x81, 0xEC, 0x6D, 0x9F, 0x2D, 0x5E, 0xF8, 0x48, 0x85, 0x50, 0x20, 0x7D, 0xBB, 0x16, 0x4E, 0x39, 0x64, 
+                       0xB7, 0xBC, 0xED, 0xA9, 0x6A, 0x7A, 0x06, 0x09, 0x6B, 0xBC, 0x2C, 0x5A, 0xE1, 0x4F, 0xD4, 0xA9, 0x82, 0x83, 0x5B, 0xBD, 0xCE, 0x14, 0x31, 0x89, 0x66, 0xB3, 0x9C, 0x31, 0x23, 0x00, 0x4B, 0x02, 0x34, 0x85, 0x30, 0x39, 0x77, 0x80, 0x5D, 0x72, 0x0A, 0xCE, 0x43, 0x2A, 0x1F, 0x02, 0x09, 0xAB, 0x2D, 0x46, 0x3A, 0x1C, 0xD2, 0x7B, 0xF6, 0x02, 0x92, 0xCA, 0xDA, 0x26, 0x0C, 0xF8, 0xE2, 0x67, 0x7E, 0xE2, 0x55, 0xB1, 0x3F, 0x6A, 0x06, 0x65, 0x6D, 0x74, 0x98, 0x59, 0xE2, 0x8A, 0x1E, 0x61, 0x03, 0x4D, 0xFC, 0x68, 0x31, 0x6A, 0xE7, 0xCF, 0x52, 0x88, 0x8E, 0x06, 0x97, 0x77, 0xB3, 0x20, 0x7E, 0x09, 0x5D, 0x3B, 
+                       0xAF, 0x56, 0xF4, 0xE8, 0x4C, 0x69, 0x09, 0xB9, 0x80, 0x38, 0xDC, 0x66, 0x2E, 0x06, 0xF6, 0xCB, 0x1F, 0x1B, 0xAD, 0x51, 0xFF, 0xFD, 0x38, 0x8D, 0x03, 0x90, 0xCF, 0x31, 0x01, 0x30, 0xEA, 0x48, 0x4C, 0xBB, 0x40, 0x87, 0x1D, 0x97, 0x6A, 0x56, 0x4C, 0xED, 0x07, 0x23, 0x45, 0x50, 0x2F, 0x56, 0xC9, 0x90, 0x79, 0x09, 0xC5, 0x45, 0xB9, 0xAD, 0x58, 0x2B, 0x4C, 0xA3, 0x01, 0xE0, 0x2D, 0xE5, 0x30, 0xBC, 0x54, 0xEC, 0x65, 0xB4, 0x79, 0x22, 0x7D, 0x15, 0xF6, 0x28, 0xCD, 0x84, 0x7E, 0x27, 0x95, 0xA1, 0xC7, 0x82, 0x6D, 0xFB, 0xDF, 0x03, 0xD9, 0x14, 0xFE, 0x0A, 0x06, 0x6F, 0x14, 0xFF, 0x8A, 0x27, 0x80, 0x36, 
+                       0xDC, 0xBA, 0xAE, 0xDD, 0x44, 0x15, 0xA5, 0x6E, 0x64, 0x73, 0xBD, 0xFB, 0xAE, 0x6D, 0x6F, 0x42, 0x96, 0xDF, 0x90, 0xE5, 0x6A, 0x9B, 0x05, 0xAE, 0xD5, 0x0A, 0x22, 0x88, 0xD6, 0x5D, 0x4C, 0x7B, 0xB1, 0x3A, 0xFC, 0x0C, 0x32, 0x02, 0xB1, 0x18, 0x0D, 0xAF, 0xE0, 0xFE, 0x7E, 0x07, 0x96, 0x85, 0xBB, 0xC8, 0x21, 0x68, 0x12, 0xD4, 0xC8, 0xBF, 0x91, 0x47, 0xE2, 0xF3, 0xA5, 0xA3, 0x86, 0xE6, 0x30, 0x42, 0xF5, 0xA9, 0xB9, 0x48, 0xCB, 0x18, 0xE6, 0x64, 0x3B, 0xE0, 0x8E, 0xC3, 0x03, 0x45, 0xA0, 0xED, 0x1A, 0x09, 0xFF, 0xB3, 0x99, 0x14, 0x5F, 0xDA, 0x90, 0x58, 0x61, 0x8E, 0xF7, 0x0A, 0x00, 0xC7, 0x44, 0xE7, 
+                       0x73, 0x78, 0xC4, 0x8B, 0x39, 0xCE, 0x70, 0x0E, 0x24, 0x03, 0x95, 0x94, 0x73, 0x76, 0x10, 0x7E, 0x4C, 0xFF, 0xCA, 0x49, 0x93, 0x89, 0xD4, 0x3E, 0x1A, 0x88, 0xCC, 0x48, 0xA7, 0x78, 0x2F, 0x83, 0x4F, 0x6C, 0x33, 0x55, 0xDD, 0x7F, 0x7D, 0x4D, 0xE5, 0xCD, 0x9C, 0x3D, 0x04, 0x1E, 0xC1, 0x9B, 0x6D, 0x7E, 0x7A, 0xAC, 0x93, 0x5E, 0x2B, 0xC3, 0x85, 0x36, 0x07, 0x66, 0xE8, 0xC9, 0xC0, 0xD1, 0x54, 0xF4, 0x4C, 0x6A, 0x02, 0x24, 0x9A, 0x7D, 0x10, 0xD9, 0x79, 0x94, 0x00, 0x64, 0x63, 0x36, 0xDC, 0x35, 0x0C, 0x8F, 0x79, 0xBA, 0xC7, 0x10, 0x76, 0xF8, 0x4A, 0xD3, 0x69, 0x95, 0x23, 0x89, 0x66, 0xC4, 0x5A, 0xE7, 
+                       0xCE, 0x21, 0xBC, 0xCB, 0xF2, 0x4F, 0x92, 0x33, 0xE7, 0x89, 0xD6, 0x23, 0xF7, 0x67, 0x5B, 0x20, 0xD9, 0xDA, 0x1A, 0xD1, 0xF6, 0x9E, 0x01, 0x83, 0x51, 0xAF, 0x35, 0x43, 0xDD, 0x3A, 0xAB, 0xCA, 0x0E, 0xED, 0x2E, 0x4D, 0x1E, 0x91, 0xCF, 0x2E, 0xA9, 0x4D, 0x08, 0xD9, 0x48, 0x30, 0x37, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0xA2, 0xED, 0x05, 0x50, 0x89, 0x91, 0x1D, 0xEB, 0xF6, 0x57, 0x66, 0xAF, 0x70, 0x15, 0xDD, 0x1A, 0xA1, 0x94, 0xB7, 0xB2, 0x04, 0x14, 0x09, 0xE4, 0x0B, 0xEC, 0x1D, 0x93, 0x3E, 0x32, 0x94, 0x6A, 0x95, 0x36, 0xDD, 0xBA, 0x93, 0x9D, 0x75, 0xB6, 
+                       0x3E, 0xF5 };
+
+               static public byte[] farscape_nopwd_pfx = { 0x30, 0x82, 0x06, 0xA3, 0x02, 0x01, 0x03, 0x30, 0x82, 0x06, 0x63, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x06, 0x54, 0x04, 0x82, 0x06, 0x50, 0x30, 0x82, 0x06, 0x4C, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
+                       0x0E, 0x04, 0x08, 0x31, 0xB9, 0x22, 0x7A, 0x73, 0xB6, 0x67, 0x3E, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0x05, 0x3F, 0x9B, 0x6F, 0x4D, 0xE2, 0x97, 0xC0, 0x71, 0x61, 0xDC, 0x39, 0x33, 0x9B, 0x45, 0x36, 0xD1, 0xC2, 0xC1, 0x2E, 0xE3, 0x22, 0x88, 0xE2, 0x54, 0x18, 0xE8, 0xC9, 0x0E, 0xA7, 0xBB, 0x1B, 0xC6, 0xC8, 0x32, 0xD9, 0x47, 0x64, 0x40, 0xC2, 0x40, 0xDC, 0x34, 0xB5, 0x34, 0x5D, 0x8A, 0x56, 0xD9, 0xF6, 0x0A, 0x03, 0x93, 0x5D, 0xE5, 0x04, 0xDC, 0x5B, 0xBA, 0x49, 0x22, 0x0A, 0x51, 0x33, 0xFF, 0xF0, 0xAF, 0x5D, 0x1F, 0x97, 0x6A, 0x11, 0x1C, 0x6B, 0x1A, 0xCF, 0x2E, 0x41, 0xA1, 0xD0, 0x31, 
+                       0xC2, 0x2D, 0xDD, 0x83, 0xAA, 0x21, 0x0C, 0x0E, 0x78, 0xEE, 0x9C, 0x25, 0x74, 0xC5, 0x4F, 0xE4, 0x94, 0x84, 0xA8, 0xD9, 0x2F, 0x96, 0xF5, 0x06, 0x05, 0xAE, 0x99, 0xBF, 0x8B, 0xD6, 0x67, 0x5E, 0xCB, 0x61, 0x03, 0xCC, 0x5A, 0x5F, 0xAB, 0x82, 0x55, 0xB1, 0x8D, 0xCD, 0xFE, 0x1C, 0x25, 0x48, 0xA7, 0x1D, 0xFF, 0x2E, 0xC0, 0x23, 0x80, 0xF7, 0xE4, 0x22, 0x68, 0x07, 0xFF, 0x58, 0xA5, 0xAA, 0x71, 0x7A, 0xAB, 0x48, 0x2D, 0xE6, 0xDF, 0xB5, 0x3C, 0x90, 0x15, 0xE3, 0x55, 0x4A, 0xB4, 0x37, 0xFE, 0x7F, 0xE1, 0x5B, 0x0C, 0xF1, 0x01, 0x4C, 0x60, 0x2F, 0x6F, 0x59, 0x09, 0x2B, 0x96, 0xDC, 0xE2, 0x2C, 0xF0, 0xB9, 
+                       0xF3, 0x3E, 0x46, 0x5B, 0x68, 0xA9, 0xBB, 0x42, 0x8B, 0xAB, 0xA9, 0x68, 0x56, 0xF9, 0xB2, 0x2E, 0x93, 0xDD, 0xE9, 0xBB, 0x70, 0x9E, 0x2E, 0x48, 0xB9, 0xDB, 0x1C, 0x95, 0x0F, 0x67, 0xD4, 0x13, 0x02, 0x62, 0xE0, 0xFA, 0x18, 0x48, 0xAE, 0x31, 0xB6, 0x1F, 0x68, 0x7D, 0xB2, 0x16, 0x61, 0xCD, 0x04, 0x91, 0x50, 0xBF, 0x35, 0xBF, 0x76, 0xA3, 0x5B, 0x76, 0xFE, 0x3F, 0xAB, 0xB2, 0x59, 0x8B, 0xD0, 0xB7, 0xC6, 0x36, 0x0E, 0x2C, 0x31, 0x48, 0xFB, 0x69, 0x6F, 0x90, 0x37, 0x3F, 0xE1, 0x53, 0x36, 0x5A, 0x60, 0x53, 0x93, 0x46, 0xC4, 0x31, 0x92, 0x3B, 0x11, 0x9F, 0x67, 0xC3, 0xD0, 0x2E, 0x9F, 0x7D, 0xA8, 0xBE, 
+                       0xA3, 0xB2, 0xCF, 0x60, 0xA3, 0xCE, 0x9F, 0x4B, 0x72, 0xCD, 0x44, 0x26, 0x4C, 0x66, 0xF8, 0x75, 0x80, 0xFC, 0x23, 0xBC, 0xA1, 0x3A, 0xCA, 0xC9, 0xE7, 0x50, 0xA3, 0x79, 0x21, 0x2B, 0x2D, 0x09, 0x8C, 0x45, 0x89, 0xB6, 0xAF, 0x66, 0x3E, 0xF7, 0xFD, 0xA5, 0x69, 0x96, 0xB4, 0x65, 0xB5, 0xFE, 0x35, 0x1F, 0x80, 0xA7, 0x41, 0x90, 0xBA, 0x92, 0x8D, 0x3B, 0xC0, 0x37, 0xDE, 0x95, 0xA8, 0x0D, 0xF1, 0x1A, 0x9F, 0xD2, 0x70, 0xED, 0x38, 0x1E, 0xA2, 0xF1, 0x2B, 0x63, 0x62, 0xC5, 0xAE, 0x5D, 0x0F, 0xFC, 0x80, 0xFA, 0x0E, 0xE4, 0xE7, 0x6C, 0x62, 0x3B, 0x19, 0xBB, 0xA8, 0xE5, 0x1D, 0x3E, 0x06, 0x30, 0x0B, 0xE1, 
+                       0xCF, 0xB6, 0xB4, 0x87, 0x96, 0xA2, 0x5E, 0xF8, 0x0F, 0x13, 0xAE, 0x04, 0xAF, 0xB2, 0x6C, 0x9E, 0xA0, 0x28, 0x1C, 0x46, 0xE5, 0xA8, 0x25, 0x62, 0x51, 0x95, 0xB0, 0x70, 0x60, 0xB6, 0xD9, 0xBB, 0xE3, 0xD1, 0xF0, 0x1D, 0x25, 0xBD, 0x93, 0x5E, 0xB6, 0x47, 0x50, 0xCD, 0x77, 0x7A, 0xFF, 0xC5, 0xFF, 0x4A, 0x7A, 0x9A, 0x27, 0x22, 0xEB, 0x7C, 0x12, 0xE5, 0x59, 0x1F, 0x60, 0xEA, 0xC3, 0x93, 0x4D, 0x28, 0x49, 0x2D, 0xF9, 0xC0, 0x13, 0x12, 0x89, 0x96, 0xED, 0x78, 0xB0, 0x1C, 0x82, 0xDE, 0xEE, 0x40, 0xDE, 0x68, 0x2B, 0x45, 0x16, 0xBE, 0xBF, 0xD5, 0x85, 0x6A, 0xDB, 0xD9, 0x1E, 0xEE, 0xFA, 0x6C, 0x95, 0x19, 
+                       0xF3, 0x76, 0x61, 0x72, 0x21, 0x69, 0x77, 0x18, 0x2C, 0xFA, 0x99, 0x7A, 0xD7, 0x58, 0xC4, 0xD6, 0x1D, 0x8B, 0xE8, 0x0B, 0xEC, 0x0F, 0x0F, 0xFA, 0xCE, 0xE2, 0x6F, 0xB1, 0xF5, 0x4F, 0xC3, 0xF7, 0x4A, 0xE4, 0x79, 0xB0, 0xFC, 0x62, 0x88, 0xC0, 0x49, 0xEC, 0xDB, 0xC8, 0xCD, 0xBE, 0x25, 0x00, 0x68, 0xB6, 0x5E, 0x89, 0x78, 0xE6, 0x92, 0xA5, 0x5D, 0x55, 0xA7, 0xAD, 0xFF, 0x3D, 0xC7, 0xF9, 0x95, 0x8D, 0xCF, 0x6E, 0x37, 0x1D, 0x79, 0x74, 0xE1, 0xDE, 0x22, 0x07, 0x6B, 0xE6, 0xB7, 0x7D, 0xD1, 0x0F, 0xB6, 0xA4, 0x3F, 0x0F, 0x31, 0x81, 0x09, 0xAD, 0xFD, 0x5F, 0xA4, 0xF4, 0x8F, 0x3C, 0x02, 0xB8, 0xB0, 0x04, 
+                       0x70, 0x44, 0x2C, 0x73, 0x42, 0xEE, 0xFF, 0xBA, 0x45, 0x50, 0xC0, 0x95, 0xFF, 0x62, 0x14, 0x91, 0x23, 0xF2, 0x8A, 0x65, 0x40, 0x20, 0xEB, 0x4B, 0x7B, 0x66, 0xF2, 0xC2, 0xC8, 0xD7, 0x16, 0x93, 0x0A, 0xBD, 0x5C, 0xCC, 0x11, 0x38, 0xEA, 0x90, 0x9C, 0x37, 0xDA, 0xB2, 0x80, 0xBF, 0x5C, 0x41, 0xC8, 0x3B, 0x16, 0x81, 0x83, 0xF7, 0xE4, 0x16, 0x12, 0x6C, 0x5F, 0x05, 0xBE, 0x2B, 0x04, 0x62, 0x36, 0x13, 0x8F, 0xF1, 0xC2, 0x5A, 0xCB, 0xFB, 0x26, 0x04, 0xE0, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
+                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
+                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x02, 0xB7, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x02, 0xA8, 0x30, 0x82, 0x02, 0xA4, 0x02, 0x01, 0x00, 0x30, 0x82, 0x02, 0x9D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
+                       0x06, 0x30, 0x0E, 0x04, 0x08, 0x37, 0xAE, 0x94, 0x2A, 0x4C, 0x78, 0xA2, 0x9A, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x02, 0x70, 0x49, 0xB9, 0xA3, 0x6E, 0xC7, 0x96, 0xCF, 0x92, 0x12, 0x43, 0x69, 0x57, 0xAD, 0x4B, 0x88, 0xA8, 0x3F, 0xEA, 0x25, 0xB6, 0xE4, 0x16, 0x74, 0x4E, 0xF5, 0xF8, 0xF2, 0xEC, 0xC0, 0xB7, 0xC2, 0x6A, 0x6E, 0xC0, 0x67, 0x5A, 0x5D, 0xFE, 0x0A, 0x7C, 0xBD, 0x06, 0xFF, 0x2F, 0x34, 0xFD, 0xE4, 0x06, 0x70, 0x23, 0xA3, 0x28, 0x27, 0xCA, 0x91, 0xD0, 0xC7, 0xA1, 0x08, 0x4F, 0x78, 0x0E, 0x89, 0xED, 0x29, 0x8F, 0xD6, 0x8E, 0x1C, 0xE0, 0x30, 0x08, 0x77, 0xA0, 0x3F, 0x18, 0xF1, 0x81, 0xD5, 
+                       0x73, 0xD7, 0x1A, 0xCA, 0xD4, 0x6D, 0x56, 0x7D, 0xFD, 0x30, 0xB5, 0xA0, 0x5D, 0x59, 0x82, 0xB9, 0xF7, 0x02, 0x19, 0x83, 0x68, 0x19, 0x08, 0x5E, 0x26, 0xCF, 0x06, 0xFA, 0xA0, 0xB4, 0x85, 0x95, 0x10, 0x6F, 0x91, 0x82, 0x89, 0xE8, 0x46, 0xEE, 0x51, 0xEB, 0x2A, 0x45, 0xAC, 0x93, 0x87, 0x48, 0x8C, 0xB6, 0x02, 0xB4, 0x4D, 0xC6, 0xFC, 0x51, 0x4C, 0x75, 0x9D, 0x5A, 0xE7, 0x46, 0x5B, 0x0A, 0x9D, 0x75, 0xA3, 0x0C, 0xB2, 0x54, 0x2A, 0x3E, 0x3A, 0x25, 0xA3, 0x75, 0x66, 0x52, 0x61, 0x7A, 0x78, 0xED, 0xDD, 0x7E, 0xF2, 0x4A, 0xA6, 0xB6, 0x3D, 0xEA, 0x62, 0xE4, 0x68, 0x95, 0x74, 0x3D, 0x45, 0xC1, 0x6E, 0x6B, 
+                       0xB6, 0x6E, 0x8F, 0x97, 0x39, 0xB5, 0x4F, 0xAA, 0x8E, 0xBB, 0x55, 0x10, 0x19, 0xCB, 0x66, 0xA0, 0xBF, 0xAE, 0x8B, 0xE6, 0xBC, 0x92, 0x8D, 0x2D, 0xC1, 0x83, 0x87, 0x53, 0x81, 0x32, 0x3B, 0x8E, 0x80, 0x76, 0xF9, 0xDE, 0x60, 0x8F, 0x99, 0x02, 0x4F, 0x97, 0x73, 0x3D, 0xE3, 0xC7, 0xBA, 0xBD, 0x4C, 0x3F, 0x8A, 0x9B, 0xE3, 0xFE, 0x24, 0xC3, 0x3E, 0xDE, 0x02, 0x0F, 0x46, 0x84, 0x79, 0xDF, 0x5E, 0xC9, 0xA3, 0x7C, 0x58, 0x62, 0xFC, 0x1D, 0x9F, 0x5E, 0x9A, 0xDB, 0x3C, 0x45, 0x96, 0x91, 0xFD, 0xD9, 0xD0, 0xE7, 0x7F, 0x72, 0xBA, 0x2D, 0xC5, 0x3A, 0x54, 0xBC, 0xA0, 0xAE, 0xAA, 0xFF, 0xE9, 0x18, 0x0C, 0x1B, 
+                       0x9A, 0xD4, 0xDA, 0x82, 0xBF, 0x51, 0x23, 0xB3, 0x6E, 0xEF, 0xDB, 0x85, 0xE5, 0xBF, 0x02, 0xCC, 0xFB, 0x79, 0xA6, 0x45, 0x86, 0xDC, 0xDF, 0xF0, 0x2C, 0x15, 0x0B, 0xD1, 0xE5, 0x80, 0xBB, 0x3F, 0x65, 0x94, 0xE5, 0xAB, 0x76, 0xE4, 0xA5, 0x92, 0x7D, 0x0E, 0x8C, 0xC0, 0x92, 0x83, 0x40, 0x9D, 0x2F, 0xBD, 0x30, 0xE1, 0x7B, 0xB5, 0x91, 0xB2, 0x5E, 0xD9, 0xC6, 0xB7, 0xA4, 0x30, 0x06, 0x18, 0xED, 0x33, 0x95, 0x7B, 0xA6, 0xE3, 0xE5, 0xC0, 0x4B, 0xF5, 0x0B, 0x6A, 0x3A, 0xF5, 0xAC, 0x77, 0x22, 0xC0, 0x84, 0x3C, 0x5B, 0xE5, 0x55, 0xD5, 0xDC, 0x7E, 0xFE, 0x08, 0x02, 0x37, 0x69, 0x52, 0xB8, 0x44, 0x29, 0x16, 
+                       0xB5, 0xE8, 0x8A, 0xA4, 0xAC, 0x24, 0x58, 0xC3, 0x53, 0xAC, 0x37, 0xE2, 0xD4, 0x0F, 0x21, 0xC1, 0x54, 0x62, 0x28, 0xCA, 0xA3, 0x8C, 0x01, 0x26, 0x97, 0xFF, 0xAD, 0x0E, 0x5F, 0xB1, 0x86, 0x96, 0xD1, 0xFA, 0xE5, 0x9F, 0x38, 0x42, 0x4D, 0x32, 0xEB, 0xC8, 0x4B, 0x4A, 0x01, 0x91, 0x5C, 0xCE, 0xC8, 0x89, 0x0A, 0x7C, 0x32, 0x6D, 0x08, 0x3E, 0x7D, 0xB0, 0x3D, 0x16, 0x99, 0x52, 0xB0, 0xE0, 0xBE, 0xFF, 0x42, 0x61, 0xC3, 0x56, 0xE1, 0x9A, 0xA3, 0xFB, 0x72, 0xBB, 0x3B, 0x4C, 0xA3, 0xFC, 0x5E, 0xFE, 0xC7, 0xF2, 0xBB, 0x17, 0x96, 0x00, 0xB6, 0x02, 0xD1, 0x58, 0xF0, 0xDA, 0x63, 0xD2, 0x4C, 0x91, 0xDF, 0xFA, 
+                       0xB5, 0xAF, 0x1E, 0xDA, 0xD7, 0x02, 0x85, 0xFE, 0x80, 0x94, 0x77, 0x92, 0x84, 0x9A, 0x2F, 0x1C, 0xC2, 0x71, 0xA7, 0x3F, 0xFA, 0x00, 0xFC, 0x7E, 0x4B, 0xE2, 0xD2, 0x7B, 0xC8, 0xB9, 0x26, 0xEC, 0xD4, 0x7A, 0x3D, 0x6F, 0x89, 0xB4, 0x22, 0x2F, 0xE9, 0x41, 0xA9, 0x97, 0x8C, 0x76, 0xCE, 0xCD, 0xA6, 0x94, 0xA9, 0x1D, 0x25, 0x7C, 0x4D, 0xCF, 0x2E, 0x51, 0x59, 0xE9, 0xE3, 0xDB, 0x84, 0x28, 0x2E, 0x31, 0x24, 0xF9, 0xA7, 0xC0, 0xA7, 0x77, 0xD0, 0xB5, 0x19, 0x1C, 0xC9, 0x22, 0x28, 0x94, 0x39, 0xF5, 0xC3, 0xAA, 0x78, 0x3A, 0xE6, 0x1D, 0xB3, 0xCA, 0x95, 0x7F, 0x7D, 0xBD, 0xFA, 0x7F, 0xCD, 0x09, 0xA5, 0x77, 
+                       0x8E, 0xC8, 0xEB, 0x03, 0x26, 0xAF, 0x38, 0x5A, 0x9A, 0xFB, 0xDC, 0x90, 0xBD, 0xD7, 0x46, 0xA7, 0xB4, 0x71, 0x8F, 0xF7, 0x66, 0x4A, 0x07, 0x66, 0xE4, 0xD7, 0x3E, 0xC4, 0xD4, 0x2B, 0x15, 0x1F, 0xC8, 0x9C, 0x3A, 0x47, 0x5E, 0x6F, 0x84, 0xE3, 0x02, 0x62, 0x05, 0x86, 0x63, 0x30, 0x37, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0x62, 0x54, 0xAE, 0x53, 0x8C, 0x33, 0xEC, 0x3E, 0x2D, 0x73, 0xE6, 0xEB, 0x9A, 0xDD, 0x31, 0xEE, 0x06, 0x83, 0x4B, 0xBA, 0x04, 0x14, 0x60, 0x9B, 0x73, 0xDD, 0x3F, 0x8F, 0x2E, 0x52, 0x1C, 0x4C, 0xB9, 0x8E, 0x7A, 0xC0, 0xCD, 0x52, 0xB4, 0xBA, 
+                       0xBD, 0x8C };
+
+               static public byte[] farscape_path_pfx = { 0x30, 0x82, 0x0B, 0x53, 0x02, 0x01, 0x03, 0x30, 0x82, 0x0B, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x0B, 0x04, 0x04, 0x82, 0x0B, 0x00, 0x30, 0x82, 0x0A, 0xFC, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
+                       0x0E, 0x04, 0x08, 0x38, 0xE0, 0x5B, 0xD2, 0xF6, 0x07, 0x19, 0xE1, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0x1B, 0xCB, 0x34, 0x7D, 0x3A, 0x5F, 0x9A, 0xA9, 0x87, 0xD7, 0x17, 0xCF, 0x5D, 0xAD, 0x94, 0xB8, 0x36, 0xCD, 0xEC, 0x1B, 0xDF, 0x58, 0xA9, 0x99, 0x18, 0x75, 0xC8, 0x9D, 0x4F, 0x2D, 0xED, 0x82, 0x10, 0x18, 0xFC, 0x9A, 0x89, 0x3D, 0xAC, 0x3C, 0xC3, 0x26, 0x5F, 0x2B, 0x72, 0x48, 0xD5, 0xA3, 0xFA, 0x12, 0x57, 0x7E, 0x60, 0x05, 0xA1, 0x2B, 0x20, 0xAF, 0xB4, 0x3B, 0x1A, 0x38, 0xA4, 0xED, 0x0A, 0x25, 0xA3, 0x4B, 0xBF, 0xAB, 0x64, 0x26, 0xE9, 0xB5, 0x6E, 0xE1, 0x94, 0x44, 0xFA, 0x13, 0x14, 
+                       0x0B, 0x49, 0x76, 0xCB, 0xB8, 0x68, 0xD0, 0x64, 0xEE, 0xB6, 0xBC, 0xA4, 0xD1, 0x30, 0x8C, 0xEF, 0xC9, 0xA7, 0x07, 0x6F, 0x0E, 0xAA, 0xF7, 0x48, 0xA7, 0xE1, 0x7A, 0x3B, 0x85, 0x75, 0x79, 0x65, 0x51, 0xE9, 0xA7, 0x1A, 0x6C, 0xE3, 0x08, 0x99, 0x48, 0x4B, 0xC5, 0x66, 0xC5, 0x73, 0xB3, 0x5B, 0x99, 0x60, 0xDF, 0x8E, 0x3D, 0xB8, 0x04, 0x09, 0xA2, 0x2D, 0x70, 0xBF, 0x6F, 0x00, 0x9D, 0x1B, 0x3F, 0xE0, 0xE7, 0xDE, 0x05, 0x71, 0x54, 0x3F, 0x2D, 0x29, 0x3A, 0xFD, 0x44, 0xE6, 0x7F, 0x30, 0x9B, 0x71, 0x43, 0x55, 0x78, 0x40, 0x74, 0x6D, 0x11, 0x64, 0xBB, 0x04, 0xB7, 0x36, 0xE0, 0xA4, 0x45, 0x74, 0xBC, 0xC4, 
+                       0xC2, 0x40, 0xA5, 0xF1, 0x62, 0x9D, 0x59, 0x18, 0xAD, 0x3D, 0xD6, 0xDB, 0x9A, 0xF3, 0x34, 0x36, 0x8B, 0x0C, 0xAF, 0xC8, 0x72, 0x82, 0x9F, 0x34, 0xC2, 0xE0, 0x96, 0xB4, 0x57, 0xB9, 0x02, 0x8E, 0x00, 0x3F, 0xC6, 0x8A, 0x62, 0x02, 0xFE, 0x15, 0xCB, 0xAE, 0x49, 0xD7, 0x06, 0x4F, 0xFC, 0xF3, 0x93, 0xC1, 0x0F, 0x78, 0x8F, 0xD6, 0xEE, 0xD7, 0xB4, 0x6F, 0xA4, 0xD8, 0x62, 0x13, 0x27, 0x81, 0x58, 0xEC, 0x04, 0x44, 0xB6, 0x47, 0xBB, 0xAA, 0xEA, 0x51, 0x44, 0xF1, 0xD3, 0x2D, 0x7E, 0x79, 0xED, 0xF0, 0x3D, 0x05, 0xA0, 0xC5, 0x61, 0x05, 0x2A, 0xE3, 0x08, 0xF1, 0xD9, 0xFC, 0x85, 0x18, 0xF7, 0x49, 0xEE, 0x33, 
+                       0x01, 0xD8, 0xE1, 0x3C, 0x69, 0xC5, 0x99, 0xE4, 0xA3, 0xCE, 0xBE, 0xA8, 0x19, 0x6A, 0x76, 0x63, 0x09, 0xD3, 0xD3, 0x3B, 0x56, 0x5A, 0xEA, 0x90, 0x6F, 0x2A, 0xA9, 0x24, 0x6C, 0x30, 0x2F, 0x89, 0x8C, 0x77, 0x79, 0xC1, 0x5A, 0x6A, 0xFD, 0xEC, 0x42, 0x5E, 0xAF, 0x75, 0xDE, 0xC9, 0x08, 0x26, 0xCE, 0x2C, 0xF2, 0xBD, 0x86, 0x92, 0x1B, 0xBB, 0x51, 0x84, 0x56, 0xB7, 0x9D, 0x1C, 0x21, 0x31, 0x02, 0xFC, 0xCA, 0x6F, 0xDB, 0x71, 0xC2, 0x5B, 0x13, 0x5C, 0x96, 0x50, 0x14, 0x3B, 0x80, 0x0B, 0x23, 0xB1, 0x21, 0xCE, 0x63, 0x76, 0x7F, 0x0C, 0x00, 0x32, 0xE7, 0x7E, 0x60, 0x6E, 0x76, 0x61, 0xF5, 0xAC, 0xCF, 0xA2, 
+                       0xDC, 0xE6, 0x65, 0xD3, 0x01, 0xD4, 0x9C, 0x26, 0xDA, 0xF3, 0xAD, 0x00, 0xE2, 0x56, 0x24, 0xF2, 0x3F, 0x75, 0x7B, 0xEE, 0x2D, 0xB2, 0xCC, 0xF2, 0x0A, 0x14, 0x90, 0xC4, 0x2A, 0x79, 0xDE, 0x2A, 0x35, 0x66, 0xBC, 0xC2, 0x55, 0xDC, 0xB9, 0x0F, 0xC8, 0x08, 0x51, 0xCE, 0x40, 0xAD, 0x5E, 0xB8, 0xDD, 0xA0, 0x2C, 0x4C, 0x96, 0x99, 0x3B, 0x8F, 0x0B, 0xCC, 0x00, 0xA1, 0x37, 0xF5, 0xDB, 0xE2, 0xF8, 0x15, 0xA1, 0xC3, 0xCE, 0x6B, 0xDE, 0x3F, 0xE9, 0x52, 0x9D, 0x07, 0x2E, 0xBC, 0x7A, 0x67, 0x94, 0x19, 0x50, 0x32, 0xFC, 0x1E, 0x6E, 0x9A, 0x94, 0xDD, 0xB6, 0x87, 0x3D, 0x44, 0xA1, 0xA4, 0x95, 0x7A, 0x10, 0x3E, 
+                       0xAD, 0x73, 0x5E, 0xA8, 0xCF, 0x35, 0x0E, 0x6D, 0x48, 0xE7, 0xC5, 0x2D, 0x91, 0xAB, 0x56, 0xF5, 0x6B, 0x4B, 0xBC, 0x65, 0xB9, 0x3A, 0x7D, 0x46, 0x8E, 0xD0, 0xC0, 0x71, 0x0F, 0x12, 0x0D, 0xFD, 0x50, 0x49, 0xFF, 0x23, 0x0A, 0xC2, 0xA0, 0xB1, 0xD9, 0x5D, 0x08, 0xFE, 0xDB, 0x52, 0x91, 0xD0, 0x8D, 0x60, 0x7D, 0xDC, 0x77, 0x0A, 0x99, 0xBF, 0xC5, 0x42, 0xFB, 0x0D, 0x44, 0x38, 0xF4, 0xC4, 0xB1, 0xF2, 0x87, 0x8B, 0x26, 0x3C, 0x2D, 0x1C, 0xE2, 0x67, 0xEE, 0xF6, 0x84, 0xB8, 0x04, 0xE8, 0x2B, 0x8D, 0x7C, 0x59, 0x0F, 0x70, 0xF5, 0x60, 0xEA, 0x44, 0x1F, 0xB8, 0xB8, 0xCB, 0xEB, 0xFC, 0xBE, 0xBE, 0x82, 0xA6, 
+                       0xBB, 0x1B, 0x77, 0x26, 0x58, 0x45, 0xA6, 0x4B, 0x0A, 0x92, 0x86, 0xC4, 0x52, 0xEA, 0x72, 0xA4, 0xCF, 0x72, 0xB8, 0x98, 0x40, 0x76, 0x2D, 0x2D, 0xB2, 0xCD, 0xC0, 0x0D, 0x0F, 0x96, 0x8A, 0xA0, 0x39, 0xD2, 0xF0, 0x79, 0xD9, 0x19, 0xE3, 0x12, 0x40, 0xAB, 0x49, 0x3F, 0xC9, 0x97, 0x3D, 0x25, 0xFF, 0xCF, 0xEC, 0x01, 0xBF, 0xE3, 0x4E, 0xB4, 0x3B, 0x8F, 0x64, 0xDC, 0x70, 0xDA, 0xA0, 0xE6, 0x1C, 0x09, 0x95, 0x6B, 0xCF, 0x16, 0xBF, 0x44, 0xA5, 0xFA, 0x36, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
+                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
+                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x07, 0x67, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x07, 0x58, 0x30, 0x82, 0x07, 0x54, 0x02, 0x01, 0x00, 0x30, 0x82, 0x07, 0x4D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
+                       0x06, 0x30, 0x0E, 0x04, 0x08, 0xB7, 0xF8, 0xA2, 0x70, 0xCF, 0xB6, 0x51, 0x48, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x07, 0x20, 0x5E, 0x23, 0x13, 0x6E, 0x0A, 0x69, 0x00, 0x0C, 0xDA, 0xAD, 0xA8, 0xC8, 0xF8, 0xAC, 0xDC, 0x31, 0x49, 0xB8, 0x96, 0xF3, 0x75, 0x0F, 0x1C, 0xEF, 0x68, 0xA2, 0x9F, 0xB3, 0xE3, 0xB0, 0x39, 0x81, 0x61, 0x95, 0x86, 0x5A, 0x99, 0x6C, 0x6C, 0x84, 0xE6, 0x8D, 0x8D, 0xD9, 0x2E, 0xA8, 0xE9, 0x3B, 0xC6, 0x74, 0xB1, 0xD1, 0xCA, 0xC2, 0x38, 0x8C, 0x0C, 0xB4, 0x06, 0x29, 0x26, 0x52, 0x35, 0x68, 0x28, 0xA6, 0xF4, 0x7B, 0x0A, 0xE0, 0xBC, 0xA9, 0xBD, 0xAC, 0x5F, 0xFF, 0x06, 0x56, 0x70, 
+                       0xE1, 0xB0, 0x11, 0x2B, 0x17, 0x4B, 0x0A, 0x8C, 0x42, 0x77, 0xD1, 0xF8, 0x08, 0x28, 0x73, 0x60, 0x5A, 0xC1, 0xD9, 0x3F, 0x60, 0x40, 0x21, 0xC6, 0x33, 0x9D, 0x44, 0xF6, 0x98, 0xF4, 0x52, 0xFB, 0x57, 0x6D, 0x1E, 0x9A, 0x52, 0xF6, 0x11, 0xAD, 0xA0, 0xE4, 0xFE, 0x0E, 0xEB, 0x3F, 0xDE, 0x7C, 0xB7, 0x82, 0x04, 0x1C, 0x78, 0xFD, 0xEB, 0x99, 0x4D, 0x8E, 0xEE, 0xCA, 0xB2, 0x4F, 0xD1, 0x47, 0x5B, 0xAA, 0x4A, 0xEB, 0x16, 0xBF, 0x50, 0x93, 0xBF, 0xDF, 0x57, 0x6A, 0x8A, 0xBD, 0x4E, 0xED, 0x72, 0x5D, 0x50, 0x59, 0xC7, 0x4F, 0x4F, 0xB5, 0x7E, 0x4F, 0xA3, 0xC2, 0x51, 0x3B, 0x31, 0x12, 0x14, 0xCC, 0x2E, 0x1C, 
+                       0xC4, 0xD3, 0xC2, 0x89, 0xD3, 0x6A, 0xC4, 0x16, 0xAA, 0x13, 0x83, 0xD6, 0x30, 0xD6, 0x76, 0xE0, 0x16, 0xCF, 0x28, 0x25, 0xA8, 0xFB, 0x25, 0xBC, 0x82, 0xEF, 0xD4, 0xC4, 0x64, 0x3B, 0xE0, 0xC0, 0x91, 0xC0, 0x21, 0x17, 0x43, 0x8F, 0xCB, 0xCE, 0xD3, 0x2B, 0x7B, 0x11, 0x5E, 0x73, 0x62, 0x17, 0x9E, 0xB4, 0x00, 0xF7, 0xB3, 0x7E, 0x24, 0xC9, 0x21, 0xB8, 0xF7, 0x33, 0x02, 0x04, 0xB9, 0xDE, 0x6C, 0x97, 0xC4, 0x3B, 0xCF, 0xDE, 0xC4, 0xF7, 0x2A, 0x68, 0x8A, 0x82, 0x22, 0xA1, 0x95, 0xBB, 0x9E, 0xF6, 0x6C, 0xBB, 0x0E, 0x69, 0x83, 0x55, 0xE2, 0x5A, 0x5F, 0x60, 0x2E, 0x43, 0x41, 0xD1, 0xB8, 0xAB, 0x17, 0x3A, 
+                       0x4C, 0xA8, 0xB9, 0x81, 0xFF, 0x40, 0x28, 0x50, 0x67, 0xCF, 0x3A, 0x01, 0x5D, 0xCC, 0x09, 0xD2, 0x2D, 0x2A, 0x7D, 0x4E, 0xDA, 0x88, 0x85, 0x26, 0x03, 0x05, 0x41, 0x2B, 0x7A, 0x4B, 0xEC, 0x1A, 0xBC, 0xDF, 0xD6, 0x98, 0xFA, 0x22, 0x9D, 0xFA, 0xE3, 0x7D, 0x37, 0x5B, 0x5E, 0xFF, 0x54, 0xB3, 0x48, 0x50, 0x0D, 0xDC, 0x93, 0xD4, 0xF8, 0xC7, 0x05, 0x66, 0xC7, 0xAC, 0x9C, 0x87, 0x4A, 0x90, 0xCE, 0x2E, 0xF3, 0x4C, 0x7E, 0x90, 0xC5, 0xE5, 0x20, 0x2C, 0xD9, 0x24, 0xB4, 0x2C, 0x51, 0x57, 0x1F, 0xD9, 0x24, 0x3C, 0xFA, 0x94, 0x0E, 0xAB, 0xAA, 0x6A, 0x42, 0xFE, 0x9D, 0xE7, 0x53, 0xD6, 0xC2, 0x1D, 0x5F, 0x2E, 
+                       0x79, 0x86, 0x02, 0xDB, 0xD0, 0x8B, 0x0C, 0xD7, 0x43, 0x96, 0x60, 0x2B, 0x4A, 0x8F, 0xEE, 0xE3, 0x19, 0x61, 0x47, 0x82, 0x87, 0x6F, 0x70, 0xB6, 0xE2, 0x3F, 0x17, 0x66, 0x21, 0xE1, 0x53, 0x61, 0xC2, 0xD3, 0xE8, 0x26, 0x02, 0x68, 0x2A, 0x80, 0xC8, 0xFD, 0x8A, 0xA8, 0xCC, 0xD5, 0xAA, 0xCB, 0x14, 0xDD, 0x5A, 0x7D, 0x4A, 0xCA, 0x39, 0xE1, 0x51, 0x8A, 0x26, 0x8A, 0xDA, 0xE2, 0x54, 0x92, 0x28, 0x6E, 0x63, 0x3F, 0x9A, 0x50, 0xC0, 0x5C, 0x76, 0xE2, 0x98, 0x94, 0xFB, 0xBC, 0xAD, 0x93, 0x2C, 0x97, 0xDF, 0x15, 0x20, 0x7D, 0x4F, 0x28, 0xD5, 0xD1, 0x5D, 0x35, 0x8B, 0x5B, 0x96, 0x77, 0x34, 0xDD, 0xA3, 0x07, 
+                       0x44, 0xFB, 0xCD, 0x72, 0x2B, 0x12, 0xD5, 0x1D, 0x23, 0xA1, 0x51, 0x04, 0xF8, 0x9D, 0xF8, 0xFF, 0x0F, 0x39, 0x0F, 0x05, 0x33, 0x24, 0x0A, 0x1F, 0xD1, 0xB5, 0xA8, 0x75, 0x39, 0x41, 0xE8, 0xD5, 0x99, 0x1D, 0x9B, 0x45, 0xFC, 0x32, 0x20, 0x6E, 0xFA, 0x96, 0x80, 0xDD, 0x88, 0x5D, 0x3B, 0x12, 0x1C, 0xC6, 0x86, 0xFA, 0x27, 0x4A, 0x78, 0x46, 0xE2, 0xC0, 0xCC, 0x66, 0x01, 0xE8, 0x30, 0x32, 0x26, 0x42, 0xDE, 0x8B, 0x71, 0xE8, 0x09, 0x9C, 0xF4, 0x90, 0x71, 0x17, 0x66, 0xFE, 0x0A, 0x0F, 0xD4, 0x84, 0x13, 0xFB, 0x66, 0x99, 0x98, 0xAF, 0xD8, 0x16, 0x13, 0x15, 0xAD, 0x18, 0xBE, 0x49, 0x02, 0xAB, 0x42, 0x50, 
+                       0x14, 0xB7, 0x3B, 0x33, 0x3C, 0x22, 0xA9, 0xE1, 0xC5, 0x32, 0xCD, 0x8D, 0xB4, 0x31, 0xF9, 0x27, 0x6C, 0x50, 0x0B, 0x40, 0x5E, 0xBE, 0x02, 0xB5, 0x27, 0xC4, 0x0D, 0x2C, 0xD5, 0xAB, 0x8A, 0x58, 0x5E, 0x53, 0xAD, 0x9C, 0x0D, 0x5B, 0x06, 0xE8, 0x77, 0x24, 0x94, 0xAD, 0xC0, 0x2C, 0x17, 0x8F, 0x20, 0x70, 0xC8, 0x29, 0xEB, 0x9B, 0x84, 0x4A, 0x91, 0xA5, 0xEC, 0x85, 0x2C, 0xCF, 0x68, 0xC9, 0x72, 0xEB, 0x3D, 0x63, 0xE9, 0xDB, 0x7D, 0xBB, 0x3D, 0xBE, 0x9A, 0x37, 0x91, 0x07, 0xE5, 0x95, 0x39, 0x63, 0xB0, 0x3F, 0x46, 0xEA, 0xB7, 0x76, 0x82, 0x05, 0xE1, 0xFF, 0x7C, 0x14, 0x41, 0x0F, 0x74, 0x3E, 0x43, 0xCD, 
+                       0x87, 0x5A, 0xA7, 0x30, 0x61, 0x29, 0xE2, 0xBA, 0x59, 0x7F, 0xF3, 0xBF, 0x78, 0x1C, 0x4A, 0xB8, 0x59, 0xEF, 0x9D, 0xE3, 0xFD, 0xEB, 0xE9, 0x39, 0xA9, 0xDF, 0x3D, 0xC9, 0xD4, 0x42, 0x5F, 0x79, 0xCA, 0xFC, 0xEE, 0xFE, 0xA0, 0x88, 0x30, 0x78, 0x69, 0x37, 0xA0, 0xC2, 0x64, 0xBC, 0x41, 0x65, 0xDB, 0xB8, 0xB0, 0x99, 0xC7, 0xD5, 0xF9, 0x03, 0x05, 0x98, 0x5A, 0xAB, 0x76, 0xB5, 0x0D, 0x7B, 0xDF, 0x9B, 0xFA, 0x92, 0x5D, 0xBD, 0x52, 0x30, 0xB7, 0x0F, 0xE8, 0x60, 0x97, 0xCC, 0xF5, 0x66, 0xA2, 0xD0, 0x77, 0x9E, 0x6B, 0x5C, 0xF2, 0x41, 0x20, 0x21, 0x6D, 0x0C, 0xE1, 0xB6, 0x26, 0xD8, 0xD9, 0x66, 0x94, 0xC0, 
+                       0x55, 0x4E, 0xCC, 0xBC, 0x2D, 0xDC, 0xC3, 0x23, 0x17, 0x9C, 0x7F, 0xA6, 0x75, 0x38, 0x33, 0xBB, 0x49, 0xBE, 0xF0, 0x77, 0xCB, 0xE7, 0xB2, 0xF5, 0x40, 0xE3, 0xD5, 0xCC, 0x1F, 0x83, 0x50, 0xA5, 0x2E, 0x1B, 0x17, 0xBD, 0x63, 0x8C, 0x9F, 0x99, 0x30, 0x41, 0xC8, 0x0D, 0x8B, 0x05, 0x80, 0x67, 0x03, 0x60, 0xCF, 0x2A, 0xA0, 0x55, 0x14, 0x74, 0xA7, 0xEA, 0x43, 0x3F, 0x5A, 0x03, 0x0B, 0xEF, 0x3F, 0xC8, 0xAA, 0x03, 0xB9, 0x1B, 0xC6, 0xB9, 0x63, 0xD4, 0x9C, 0xA1, 0x42, 0x18, 0x32, 0x12, 0x87, 0xEA, 0x44, 0xB9, 0xA8, 0x72, 0xA8, 0x75, 0xB4, 0x09, 0xEB, 0x90, 0x7F, 0xB5, 0x00, 0x39, 0xDE, 0x2C, 0x07, 0x87, 
+                       0xB5, 0x35, 0xDD, 0x44, 0x03, 0x09, 0xA9, 0xA0, 0xD6, 0x40, 0x69, 0x88, 0xC9, 0x2A, 0xDB, 0x3E, 0x56, 0xEF, 0x42, 0x23, 0xB7, 0x4D, 0x62, 0xDA, 0x56, 0x1C, 0xC5, 0xC1, 0x4D, 0x07, 0x02, 0x14, 0x7E, 0xE7, 0x6D, 0x38, 0x05, 0x70, 0x19, 0x77, 0xA6, 0x46, 0xE9, 0x18, 0x3E, 0x06, 0xEE, 0x5A, 0xCA, 0x35, 0xE3, 0xCD, 0xAA, 0x4C, 0x89, 0x5D, 0x41, 0x85, 0x17, 0x53, 0x18, 0x86, 0x3D, 0x20, 0x18, 0x53, 0x1D, 0xF8, 0x4C, 0x09, 0x2C, 0x48, 0x75, 0x00, 0xF8, 0xD1, 0xF4, 0xA5, 0xD7, 0x29, 0xB5, 0xFF, 0x42, 0xFA, 0x6B, 0xCB, 0x47, 0x0F, 0x33, 0x00, 0x59, 0x54, 0x07, 0x62, 0x5C, 0xC7, 0x57, 0x63, 0xB4, 0x32, 
+                       0x5C, 0xF1, 0x8E, 0xBA, 0x6D, 0x0E, 0x85, 0x3B, 0x3D, 0xE7, 0xAA, 0x31, 0x61, 0x77, 0x3F, 0x77, 0xF4, 0x1F, 0xD7, 0x6C, 0x5F, 0x13, 0xCF, 0xB5, 0x9A, 0xAC, 0x6F, 0x2C, 0x49, 0x2D, 0xDD, 0xED, 0x27, 0xA9, 0x77, 0x1F, 0x38, 0x78, 0x16, 0x82, 0x00, 0xB3, 0xD9, 0x8E, 0xFA, 0x43, 0xE2, 0x54, 0xB7, 0x36, 0xED, 0x20, 0x33, 0x1A, 0x7E, 0x0E, 0xF2, 0xEE, 0x20, 0xE7, 0x10, 0xC4, 0xB6, 0x07, 0x0A, 0x42, 0x26, 0xCA, 0xC1, 0x6C, 0x29, 0xA1, 0xBD, 0x05, 0xE0, 0x70, 0xED, 0x17, 0x7C, 0x21, 0xD3, 0x9F, 0x72, 0xE7, 0x47, 0xA3, 0x5F, 0xCA, 0x50, 0x4C, 0x3C, 0x16, 0x9D, 0x20, 0x49, 0x7B, 0x9A, 0x53, 0xCF, 0x7C, 
+                       0x9B, 0x69, 0x5E, 0xE0, 0x56, 0xB0, 0x60, 0xFB, 0xC6, 0xE8, 0x67, 0x31, 0x18, 0xDB, 0x67, 0xA2, 0x61, 0xE2, 0x8E, 0x35, 0xFA, 0xBD, 0xED, 0x43, 0x32, 0xCA, 0x99, 0xAC, 0xF7, 0xCB, 0xB8, 0x1E, 0x57, 0x2D, 0xC7, 0xB4, 0x2A, 0xEA, 0x53, 0xCE, 0xDB, 0xD7, 0xE6, 0x8F, 0x9A, 0x98, 0x12, 0xE3, 0xB0, 0x7E, 0x85, 0x1B, 0x6B, 0x2F, 0xE3, 0xD0, 0x54, 0x5C, 0x31, 0xC0, 0x96, 0xE8, 0x04, 0xD9, 0x87, 0x8F, 0x8A, 0xC9, 0xC1, 0x95, 0x31, 0x11, 0x66, 0xC3, 0x86, 0x06, 0x93, 0xC4, 0xDC, 0x6F, 0xD7, 0x7C, 0x65, 0xF3, 0xF9, 0xB1, 0x6F, 0x34, 0xD8, 0x25, 0x21, 0x02, 0x1B, 0x12, 0x52, 0x19, 0xD0, 0xED, 0xB8, 0x4A, 
+                       0x67, 0x1E, 0x49, 0x2C, 0xDD, 0x47, 0xA7, 0x0A, 0x1F, 0x21, 0x67, 0x5A, 0x0F, 0x34, 0xDB, 0x6D, 0x1E, 0xFB, 0x71, 0xBC, 0xB9, 0x8F, 0x84, 0xE4, 0x3A, 0xE4, 0x47, 0x93, 0x48, 0xC2, 0xCA, 0xDA, 0x5B, 0x7B, 0xA0, 0x3F, 0x2F, 0x9C, 0x68, 0xDC, 0x72, 0x15, 0x18, 0x57, 0xBA, 0x32, 0x6B, 0x92, 0x08, 0x08, 0x65, 0xA5, 0x30, 0xA4, 0xED, 0x35, 0x80, 0xC5, 0xD3, 0x93, 0x01, 0x36, 0x53, 0x8E, 0xC9, 0xF6, 0x2D, 0xCA, 0xB9, 0xE6, 0xE9, 0x94, 0x89, 0xE3, 0x05, 0x81, 0x9B, 0x69, 0x0B, 0xD7, 0xD2, 0x55, 0x0A, 0xFE, 0xAF, 0x98, 0x97, 0xB9, 0xCB, 0xB8, 0xCB, 0xB6, 0x48, 0xD1, 0xB4, 0xF1, 0xD2, 0x19, 0x53, 0xB1, 
+                       0xCE, 0x4E, 0x3D, 0x11, 0xF3, 0xC6, 0x89, 0xFC, 0x68, 0x48, 0x4C, 0xF9, 0x11, 0x1B, 0xDF, 0x10, 0x21, 0x44, 0x2C, 0x43, 0xCC, 0x00, 0x0D, 0xC8, 0x40, 0x6D, 0xDB, 0xCE, 0xC7, 0xBF, 0xA4, 0xCF, 0x6C, 0xAF, 0x71, 0xF4, 0x72, 0xB8, 0xF4, 0x32, 0x19, 0xD2, 0xFC, 0xFE, 0x28, 0xC8, 0x00, 0x44, 0xB9, 0xEC, 0x70, 0x5B, 0xF5, 0x39, 0xDC, 0xBD, 0xF4, 0xEF, 0xC3, 0x8A, 0xF1, 0x06, 0x52, 0x90, 0xAF, 0x18, 0x45, 0xF1, 0xC7, 0x10, 0x0C, 0xD2, 0xB3, 0xBC, 0xE5, 0xF1, 0x32, 0x6A, 0x0C, 0x55, 0x3E, 0x28, 0x62, 0xC9, 0xC1, 0x12, 0x1F, 0x6E, 0x30, 0x6A, 0x4C, 0x9B, 0x6D, 0x32, 0x18, 0x2D, 0xDD, 0xE6, 0x0F, 0xA5, 
+                       0x0B, 0xBE, 0xBB, 0xF8, 0x8D, 0xF7, 0x40, 0x9F, 0x24, 0xB1, 0x85, 0x17, 0x9F, 0x38, 0x2C, 0xEE, 0x2F, 0x50, 0x99, 0x30, 0x75, 0x95, 0x85, 0xA2, 0xB7, 0xA2, 0x7C, 0x42, 0x58, 0xD9, 0x7D, 0x52, 0xB8, 0x0D, 0xF2, 0x68, 0x57, 0x75, 0xEC, 0x5A, 0xFF, 0xBE, 0xC3, 0xB4, 0x21, 0xE2, 0xA1, 0xCB, 0x60, 0x5F, 0x2A, 0x3A, 0xEE, 0xE0, 0xC3, 0xFB, 0x9A, 0x21, 0x02, 0x86, 0x10, 0xA1, 0xCF, 0x2F, 0x6D, 0x83, 0xBC, 0x09, 0xCE, 0x97, 0x08, 0xDB, 0x6E, 0x17, 0x90, 0xEF, 0x06, 0x2E, 0x19, 0x27, 0xC2, 0x1A, 0x9E, 0xB4, 0xB7, 0x16, 0x1A, 0xF6, 0x92, 0x81, 0x5C, 0xF3, 0x8D, 0x52, 0x87, 0xD1, 0x50, 0x23, 0x78, 0xE5, 
+                       0x81, 0x16, 0x24, 0x12, 0x21, 0xD8, 0x70, 0x30, 0xB4, 0x38, 0x40, 0x7B, 0xBC, 0x21, 0x51, 0xDB, 0x66, 0x15, 0x4C, 0x21, 0x8E, 0xF5, 0x5B, 0x78, 0x65, 0x29, 0x7C, 0xEF, 0x5D, 0xE0, 0x7E, 0x4D, 0xF9, 0x35, 0xC6, 0x97, 0xEA, 0x4A, 0x56, 0xB5, 0xA2, 0x38, 0xAE, 0xF1, 0x50, 0x1A, 0xBE, 0xE8, 0xB1, 0x68, 0xBA, 0xB6, 0x4D, 0x67, 0x63, 0x52, 0x07, 0xBC, 0x4E, 0x68, 0x7C, 0x30, 0x75, 0x16, 0x97, 0x99, 0xD5, 0x8E, 0x14, 0xD9, 0x35, 0x80, 0x35, 0x48, 0xA3, 0x42, 0x3B, 0x60, 0xC0, 0xF7, 0xC5, 0x4E, 0x40, 0xEF, 0x1D, 0xA4, 0x2A, 0x43, 0xD3, 0xA9, 0xB5, 0x3D, 0x72, 0x4D, 0x51, 0x17, 0xFC, 0x92, 0x2F, 0xAC, 
+                       0xC8, 0x81, 0xE1, 0x01, 0x25, 0xBE, 0x89, 0xA9, 0x13, 0x9B, 0xE6, 0xBF, 0x60, 0x9E, 0x43, 0x68, 0x65, 0x34, 0x7A, 0x9C, 0x01, 0x9F, 0xA5, 0x32, 0xFC, 0x06, 0x38, 0x93, 0x4F, 0x15, 0x35, 0x42, 0xAB, 0xB0, 0x36, 0x67, 0x06, 0x4F, 0x2C, 0x70, 0x64, 0x41, 0x31, 0x20, 0x90, 0xA6, 0x3B, 0xC9, 0x99, 0xD8, 0x47, 0x42, 0x64, 0xB6, 0x2B, 0x08, 0xD3, 0x0E, 0x41, 0x19, 0x77, 0xF3, 0x5D, 0x56, 0x05, 0xF2, 0xBC, 0xF9, 0x9A, 0x92, 0x43, 0xD9, 0x18, 0x83, 0x90, 0x13, 0xD8, 0xA1, 0x42, 0x2A, 0x18, 0x2D, 0xD8, 0x1D, 0xE8, 0x50, 0xC5, 0xE8, 0x6F, 0x4F, 0x05, 0x45, 0x74, 0x06, 0x2A, 0x8B, 0x24, 0x33, 0xC0, 0xAA, 
+                       0xAA, 0x84, 0x8A, 0xE2, 0xE8, 0xB0, 0x7E, 0x2D, 0xBD, 0x0C, 0x20, 0xD1, 0x44, 0xAA, 0xCA, 0xC4, 0x83, 0x8C, 0x08, 0xA3, 0x17, 0x36, 0xA1, 0xA1, 0xC2, 0x04, 0xA7, 0x06, 0xCB, 0xB7, 0xF2, 0x64, 0x28, 0x0C, 0xC4, 0x91, 0x0B, 0xDF, 0x93, 0xCB, 0xBE, 0x85, 0x07, 0x11, 0xBB, 0xD8, 0x8A, 0xB1, 0xAB, 0xDC, 0x91, 0x02, 0xDE, 0x4F, 0xE5, 0x6E, 0xC7, 0x96, 0xAB, 0x7E, 0x4A, 0xAA, 0xCF, 0x05, 0x46, 0xE2, 0xB3, 0x52, 0xCD, 0x93, 0x7E, 0xAE, 0xB1, 0x40, 0x61, 0x7E, 0xCB, 0x43, 0x7F, 0xF4, 0x32, 0x8C, 0xA5, 0x0D, 0x52, 0xF7, 0x7A, 0x76, 0xBA, 0x05, 0x14, 0x65, 0xAD, 0x36, 0x85, 0x46, 0x15, 0x00, 0x01, 0xD7, 
+                       0x04, 0xA3, 0xD3, 0x1A, 0xAE, 0x59, 0xEF, 0x6E, 0xBE, 0x39, 0xDF, 0x0D, 0x78, 0xEF, 0x6F, 0x14, 0x02, 0xEC, 0x04, 0xB9, 0xE7, 0x15, 0x54, 0x51, 0x83, 0x75, 0xE2, 0x06, 0x1F, 0x07, 0xD3, 0x82, 0xCB, 0x01, 0x03, 0xE5, 0x43, 0xAC, 0x62, 0x66, 0xF7, 0xCF, 0x74, 0x1B, 0xCD, 0x30, 0x37, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0x84, 0xA8, 0x88, 0x5F, 0xF6, 0x8E, 0xEC, 0x49, 0x94, 0x28, 0xDD, 0xC1, 0xA3, 0xCB, 0xBD, 0x73, 0x4A, 0x76, 0x0E, 0x6B, 0x04, 0x14, 0x7B, 0x11, 0xA6, 0xD2, 0x27, 0x3F, 0x96, 0xC9, 0xA7, 0xEF, 0x06, 0x6D, 0x03, 0xF9, 0xEA, 0x04, 0x2C, 0xC7, 
+                       0xF7, 0x11 };
+
+               static public byte[] farscape_strong_pfx = { 0x30, 0x82, 0x06, 0xA7, 0x02, 0x01, 0x03, 0x30, 0x82, 0x06, 0x63, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x06, 0x54, 0x04, 0x82, 0x06, 0x50, 0x30, 0x82, 0x06, 0x4C, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
+                       0x0E, 0x04, 0x08, 0x21, 0x53, 0x51, 0xD2, 0xB9, 0x79, 0xA4, 0x4F, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0xA2, 0xBA, 0x47, 0x19, 0xE3, 0x35, 0x0B, 0xA1, 0x71, 0x60, 0x65, 0x1A, 0xB0, 0x94, 0xF2, 0xF1, 0xDE, 0x8E, 0xA4, 0x59, 0xF5, 0x07, 0x1B, 0xDF, 0xD2, 0x9C, 0xF4, 0xA2, 0x5C, 0x8C, 0xA7, 0x3F, 0x7E, 0xD3, 0x93, 0x1B, 0x87, 0xA8, 0x1A, 0xA0, 0xDD, 0xF4, 0x0B, 0x76, 0x30, 0xDF, 0xE5, 0x56, 0xAE, 0x26, 0xF7, 0x6C, 0x72, 0x0A, 0x41, 0x0E, 0xD7, 0x42, 0xC3, 0x99, 0x8D, 0x8B, 0xC2, 0x18, 0xBE, 0x30, 0x12, 0xED, 0x20, 0xD3, 0xB3, 0xAF, 0xCD, 0xBE, 0x62, 0xED, 0x6F, 0x55, 0x79, 0x33, 0xCD, 
+                       0x8F, 0x2C, 0x1E, 0x1C, 0xB8, 0xDC, 0x1C, 0x4D, 0x45, 0xCE, 0xE6, 0x1E, 0x81, 0x46, 0xC1, 0x93, 0x1B, 0x7A, 0x41, 0x19, 0x82, 0xED, 0xBF, 0x8F, 0x0F, 0xB1, 0x39, 0x50, 0x58, 0xA2, 0xD2, 0xFB, 0xE6, 0x9A, 0x86, 0x68, 0x2C, 0x58, 0xF9, 0xB3, 0x7C, 0xAC, 0xCC, 0x02, 0xB0, 0x70, 0xC2, 0x5D, 0x0B, 0x7F, 0xC0, 0xA7, 0x60, 0x66, 0x41, 0xBA, 0x4F, 0xE6, 0x89, 0x16, 0x5C, 0x0D, 0x4B, 0x4F, 0x43, 0xF5, 0xFD, 0x5E, 0x22, 0x93, 0x4B, 0x34, 0xC3, 0xEC, 0xA9, 0xCF, 0x92, 0x6F, 0x0E, 0xD6, 0x01, 0x21, 0x48, 0xF4, 0x35, 0xF2, 0xA0, 0xF9, 0x84, 0xD4, 0x30, 0xE0, 0x69, 0xD2, 0xB2, 0x03, 0x3F, 0x3A, 0x5E, 0xFA, 
+                       0x06, 0xA2, 0x30, 0x1B, 0x93, 0xAC, 0x0D, 0x5D, 0x9E, 0xFA, 0x49, 0x29, 0x82, 0xE9, 0x91, 0x40, 0x87, 0x52, 0xF1, 0xED, 0xC3, 0x00, 0x1F, 0x00, 0x54, 0x9F, 0xB6, 0xC7, 0xDE, 0xF4, 0xFB, 0xCF, 0xE7, 0x9B, 0x40, 0x8B, 0x51, 0xEF, 0xFD, 0x33, 0x1C, 0xD9, 0x64, 0x19, 0x45, 0x89, 0x6C, 0x46, 0xA1, 0x9B, 0xA9, 0x93, 0xFE, 0xF8, 0x4D, 0x20, 0x63, 0x34, 0xFB, 0x1B, 0xB9, 0xC8, 0xFE, 0xD4, 0x63, 0xD1, 0x03, 0x57, 0x63, 0xC2, 0xEA, 0xC2, 0xA7, 0x9A, 0x03, 0xEB, 0xC0, 0xF1, 0xAF, 0xB8, 0xD7, 0x37, 0x76, 0x0C, 0xD3, 0x98, 0x21, 0xD2, 0x84, 0x11, 0xD6, 0xBF, 0x29, 0xC8, 0x03, 0xA1, 0xAA, 0xCB, 0xA6, 0x51, 
+                       0xF5, 0xBB, 0xA8, 0xFA, 0x43, 0xFB, 0x59, 0x51, 0x41, 0x1D, 0x2F, 0xF3, 0xFC, 0xF7, 0xA2, 0x4C, 0xEC, 0x47, 0x20, 0x14, 0xF3, 0x46, 0x8B, 0x41, 0x5E, 0x65, 0x2F, 0x18, 0x99, 0x07, 0x23, 0x6B, 0xEA, 0x55, 0x16, 0xE3, 0xA8, 0xB7, 0x31, 0x5C, 0x23, 0xF3, 0xD4, 0x1E, 0xC3, 0xB6, 0xF8, 0x53, 0x26, 0x7D, 0x42, 0x2D, 0x3E, 0xC2, 0xAE, 0x9F, 0x01, 0x83, 0x90, 0x0D, 0xA6, 0xB0, 0x2D, 0xBD, 0x86, 0x31, 0x5A, 0x15, 0x07, 0x6F, 0xA6, 0xFC, 0x35, 0x30, 0x6A, 0xEF, 0xF6, 0xC1, 0xEB, 0x18, 0x01, 0xE9, 0xE7, 0xAA, 0x87, 0x54, 0x4C, 0xAE, 0x98, 0x67, 0xDB, 0xDF, 0xFF, 0x4E, 0xA5, 0xA9, 0xA4, 0x05, 0x11, 0xE9, 
+                       0xA4, 0x1D, 0xB2, 0xB1, 0xD3, 0xF6, 0x77, 0xB6, 0xB5, 0x01, 0xC3, 0x3B, 0xAF, 0x6A, 0xA1, 0x60, 0xB9, 0x14, 0x62, 0x5E, 0x2D, 0x70, 0x25, 0xDF, 0xD3, 0x21, 0x02, 0x3C, 0xD7, 0xF1, 0xF6, 0x0E, 0xD9, 0x4D, 0x59, 0x1A, 0x41, 0x2E, 0x82, 0x28, 0x5C, 0x12, 0x26, 0x68, 0x77, 0xE0, 0x46, 0xC1, 0x0B, 0x9F, 0x15, 0x75, 0x87, 0xD7, 0x87, 0x3A, 0xF6, 0xB4, 0x57, 0x4B, 0x2C, 0x66, 0xD2, 0xCF, 0x47, 0x28, 0x31, 0x8A, 0xDF, 0x54, 0xC5, 0x16, 0x58, 0x23, 0x4F, 0x9E, 0x8D, 0x31, 0xFC, 0x9C, 0xF5, 0x07, 0x03, 0x0F, 0x63, 0xBD, 0xD7, 0x38, 0x65, 0x85, 0x7B, 0xB1, 0xBC, 0x19, 0x3C, 0xEF, 0x41, 0x55, 0xA6, 0x0D, 
+                       0x50, 0x61, 0xB6, 0xA5, 0x9F, 0xF8, 0xD6, 0x15, 0xBF, 0x40, 0x44, 0x2E, 0xD5, 0x12, 0xAA, 0x29, 0xFE, 0x8A, 0x27, 0x68, 0xC4, 0x83, 0xD5, 0x75, 0x78, 0xF7, 0x38, 0x8F, 0x0D, 0xD3, 0xC9, 0x25, 0xAC, 0xF5, 0x3E, 0x7B, 0x11, 0xCB, 0x45, 0xE0, 0x4E, 0x6A, 0x99, 0xD9, 0x24, 0xBD, 0x68, 0x59, 0x02, 0xF9, 0x0D, 0x32, 0x99, 0x87, 0xEA, 0xFA, 0x4D, 0x73, 0x72, 0x44, 0x10, 0x1B, 0xEC, 0x38, 0x04, 0xD4, 0xCD, 0x13, 0x98, 0x5F, 0x0A, 0x3F, 0x76, 0x80, 0x1E, 0x30, 0x89, 0xFF, 0x5D, 0x03, 0x38, 0x1C, 0x25, 0x9E, 0x79, 0x0A, 0xA8, 0x08, 0xAE, 0xAE, 0x28, 0x7A, 0x74, 0x68, 0x60, 0x13, 0x97, 0x48, 0x4C, 0xFA, 
+                       0xB3, 0x63, 0x3A, 0x66, 0xD0, 0xAB, 0x42, 0x35, 0x9B, 0xE6, 0x9D, 0x5D, 0xED, 0x05, 0xC5, 0x29, 0x11, 0xB2, 0x36, 0x21, 0x21, 0x86, 0x16, 0xFD, 0x81, 0xF6, 0x5D, 0x26, 0x75, 0xB2, 0x74, 0xD4, 0xF6, 0x59, 0x62, 0x7B, 0xC2, 0x6D, 0xB9, 0xF0, 0xA6, 0x5A, 0x47, 0xEC, 0x55, 0xEA, 0x35, 0xE0, 0xCE, 0x68, 0x63, 0x88, 0x2D, 0x9A, 0xCC, 0xDC, 0x0E, 0x02, 0xAB, 0x69, 0xFE, 0x22, 0xEC, 0xF5, 0xED, 0x36, 0x7B, 0xE9, 0xC2, 0xA6, 0xBF, 0x0C, 0x1C, 0x19, 0xE7, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
+                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
+                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x02, 0xB7, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x02, 0xA8, 0x30, 0x82, 0x02, 0xA4, 0x02, 0x01, 0x00, 0x30, 0x82, 0x02, 0x9D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
+                       0x06, 0x30, 0x0E, 0x04, 0x08, 0x02, 0x77, 0x79, 0xCA, 0x9F, 0x4E, 0x06, 0xE3, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x02, 0x70, 0x82, 0xE1, 0x66, 0x48, 0xDB, 0x24, 0x9E, 0x33, 0x70, 0x43, 0xFB, 0x6D, 0xD0, 0x47, 0x90, 0xF6, 0xEF, 0xAD, 0x61, 0x28, 0xBF, 0x71, 0x9F, 0x63, 0x2A, 0x69, 0x6C, 0x04, 0x14, 0x34, 0x8A, 0x92, 0xB6, 0x7E, 0x67, 0x50, 0x82, 0x6D, 0x16, 0x8B, 0xB2, 0x18, 0xA4, 0x74, 0x7C, 0xC4, 0x97, 0x50, 0xCE, 0x0B, 0xDB, 0x76, 0xFF, 0xCB, 0x8F, 0x21, 0x4F, 0x50, 0x52, 0x41, 0x0C, 0xA0, 0x98, 0xFB, 0xA8, 0x7F, 0xC0, 0xB4, 0xE3, 0x81, 0x37, 0x12, 0x55, 0x53, 0x5C, 0x3E, 0x95, 0x53, 0x40, 
+                       0x39, 0xAB, 0xD6, 0x5A, 0xBA, 0xB5, 0x87, 0xCF, 0x60, 0x2A, 0x07, 0x2E, 0xAC, 0x56, 0xC0, 0xD1, 0x75, 0xE2, 0xFC, 0xE3, 0x24, 0xDA, 0x32, 0xED, 0x11, 0xC9, 0x53, 0xED, 0x54, 0xB4, 0xE4, 0x36, 0x1F, 0x72, 0x8B, 0xA2, 0xB1, 0x8D, 0x4B, 0x4C, 0x3F, 0x75, 0x4C, 0x2F, 0xE9, 0x78, 0x97, 0xFC, 0xBA, 0x77, 0x68, 0xE4, 0x65, 0x22, 0x67, 0xE5, 0x4D, 0xE9, 0x6A, 0x63, 0x0C, 0x89, 0x91, 0x12, 0xD5, 0x3B, 0x0D, 0xF4, 0x16, 0xA7, 0xE8, 0x57, 0xA8, 0x88, 0xF4, 0x48, 0x95, 0x71, 0x91, 0xAC, 0x69, 0x67, 0xEB, 0xF0, 0xF3, 0x8C, 0xFB, 0x35, 0x4F, 0x0F, 0xAD, 0x8B, 0xFE, 0x8A, 0xCE, 0xE2, 0x75, 0xDF, 0x63, 0x38, 
+                       0xB2, 0xD0, 0xAD, 0x71, 0x5F, 0x97, 0x8B, 0x0C, 0xA7, 0x43, 0xC6, 0x62, 0xC0, 0x60, 0x0F, 0xE6, 0x6A, 0xE9, 0x23, 0x47, 0xD2, 0xC4, 0x1D, 0x90, 0x75, 0x17, 0x14, 0xF3, 0x1B, 0xB9, 0x3A, 0x11, 0xA6, 0x04, 0x52, 0x2B, 0x6B, 0xCB, 0x01, 0xE4, 0x62, 0xB8, 0xD7, 0xE3, 0xB7, 0x1B, 0x6B, 0xF3, 0x20, 0x37, 0x24, 0x87, 0xFB, 0xF0, 0x46, 0x87, 0xC4, 0xAB, 0x88, 0xAC, 0x53, 0x37, 0xD8, 0x87, 0x0E, 0xBB, 0x39, 0x91, 0x1A, 0x8C, 0x90, 0xF8, 0xB4, 0x2A, 0xE2, 0xA9, 0x25, 0xAD, 0xE9, 0x8A, 0x0E, 0xEA, 0x4B, 0x49, 0xC2, 0xE9, 0x5B, 0x5A, 0x3C, 0xAC, 0xE2, 0xE9, 0x3B, 0x27, 0xE6, 0x60, 0x00, 0x49, 0x62, 0xAF, 
+                       0xED, 0x41, 0x7A, 0x8E, 0x95, 0xD2, 0xC2, 0x27, 0x04, 0x9F, 0xE9, 0xEE, 0x50, 0xB5, 0xDF, 0x17, 0x59, 0x46, 0x83, 0xED, 0xB7, 0xFB, 0xCE, 0xE4, 0x35, 0x6E, 0x85, 0x66, 0xA4, 0xF9, 0x11, 0xB9, 0x33, 0xAE, 0x84, 0x9B, 0x73, 0xCC, 0x5E, 0x1A, 0xBE, 0xC6, 0xF6, 0x71, 0x41, 0x07, 0x3F, 0xAF, 0x24, 0xA7, 0x37, 0x12, 0x65, 0x30, 0x87, 0x23, 0xAB, 0x6D, 0xB1, 0xF1, 0xE4, 0x71, 0xEA, 0x87, 0xF4, 0x9E, 0xC9, 0xCA, 0x4E, 0x34, 0xA4, 0x60, 0x80, 0xE5, 0x5E, 0x4A, 0xDF, 0x2B, 0xA5, 0x12, 0x5E, 0x7A, 0x76, 0x7E, 0x82, 0x8B, 0xF7, 0x55, 0x72, 0x79, 0xDC, 0x2A, 0x4C, 0xC1, 0x2B, 0xCA, 0xA5, 0x9A, 0x2D, 0x98, 
+                       0x6C, 0x51, 0x00, 0x95, 0x1F, 0x4C, 0x04, 0x6A, 0x44, 0x59, 0x7C, 0x5F, 0xE4, 0xA8, 0xAF, 0x66, 0x32, 0x29, 0x1D, 0x07, 0xD4, 0xAE, 0xC1, 0x9E, 0x45, 0x35, 0x6D, 0xE9, 0x7A, 0x92, 0x22, 0x4B, 0x0D, 0x4A, 0xA6, 0x53, 0x17, 0x31, 0x76, 0x1F, 0x60, 0x32, 0x84, 0x18, 0x6B, 0x90, 0xD3, 0x77, 0x9B, 0xF1, 0xF0, 0x95, 0x4D, 0x23, 0x95, 0x90, 0xF5, 0xDD, 0xFA, 0xC1, 0x3F, 0xB3, 0xDD, 0x5E, 0x54, 0xFC, 0x03, 0xFD, 0xDA, 0xC8, 0xEF, 0x78, 0x2E, 0x5F, 0xFF, 0x1D, 0xDB, 0xB7, 0xF8, 0xBF, 0x1A, 0x2A, 0x98, 0xD0, 0x06, 0x04, 0x9B, 0xE0, 0xFD, 0xFB, 0xA2, 0x2E, 0x83, 0x67, 0x38, 0x77, 0x9E, 0x2D, 0x7C, 0xB4, 
+                       0x95, 0xF2, 0x5F, 0xF8, 0x3B, 0x62, 0x41, 0x9C, 0xAA, 0xAA, 0xAB, 0xEB, 0x46, 0x78, 0x5D, 0xF6, 0x88, 0x6C, 0xED, 0x0F, 0x76, 0x3B, 0xD6, 0xFD, 0x13, 0xCE, 0x68, 0xDE, 0x0A, 0x33, 0xA6, 0x68, 0xB5, 0xCA, 0x64, 0x90, 0x16, 0x00, 0xCE, 0x97, 0xC5, 0xED, 0x57, 0xE1, 0x1D, 0xF2, 0xD3, 0xDC, 0xA7, 0x1B, 0xC3, 0xEE, 0x07, 0xBE, 0xE8, 0xC3, 0xE5, 0x77, 0x10, 0x00, 0x48, 0x7D, 0x4F, 0xEC, 0x3B, 0xEC, 0xEF, 0x0F, 0x86, 0xD6, 0x5E, 0xF0, 0x32, 0xE4, 0x3D, 0x4E, 0xB5, 0x48, 0xA7, 0x0E, 0x2C, 0xCA, 0x1C, 0x9E, 0xDA, 0x6F, 0xDD, 0x53, 0x12, 0x0A, 0xBF, 0x65, 0x61, 0xDD, 0xB3, 0xAE, 0x3E, 0xAA, 0x59, 0x8F, 
+                       0xFC, 0xCD, 0x0E, 0xD0, 0x7D, 0xB0, 0x49, 0x5C, 0x85, 0xF4, 0xEF, 0x77, 0xDA, 0x39, 0x9E, 0x21, 0xCE, 0x9B, 0x26, 0x81, 0x6C, 0x13, 0x09, 0x54, 0xBF, 0x2D, 0x20, 0xF6, 0x57, 0x74, 0x94, 0xE0, 0x99, 0x81, 0x08, 0x9E, 0x72, 0xDB, 0x95, 0xAC, 0xB3, 0x4E, 0x08, 0x66, 0x7C, 0x30, 0x3B, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0x08, 0x95, 0xCA, 0x53, 0x3F, 0xBA, 0xFC, 0x96, 0xB1, 0x48, 0x21, 0x06, 0xA4, 0x9E, 0x5A, 0xD6, 0x23, 0x60, 0x4F, 0x3C, 0x04, 0x14, 0x24, 0x98, 0x3B, 0xFC, 0x6E, 0x4B, 0x07, 0xB7, 0xFA, 0xC1, 0xFE, 0xD3, 0x15, 0xBB, 0x7B, 0x70, 0xA7, 0x97, 
+                       0xBC, 0x0A, 0x02, 0x02, 0x07, 0xD0 };
+
+               static public byte[] farscape_strong_path_pfx = { 0x30, 0x82, 0x0B, 0x57, 0x02, 0x01, 0x03, 0x30, 0x82, 0x0B, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x0B, 0x04, 0x04, 0x82, 0x0B, 0x00, 0x30, 0x82, 0x0A, 0xFC, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
+                       0x0E, 0x04, 0x08, 0x32, 0xC5, 0xBA, 0x13, 0xE8, 0x8D, 0xE0, 0x25, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0x3C, 0xD2, 0x8F, 0x0F, 0x52, 0x6A, 0x97, 0xA2, 0x5D, 0xDC, 0xFC, 0x82, 0x3D, 0x95, 0xE1, 0x19, 0x02, 0x8E, 0x64, 0xC5, 0x7C, 0x64, 0xFF, 0xA3, 0x4E, 0x00, 0x5B, 0xC0, 0x3C, 0x7C, 0x53, 0xEA, 0xEA, 0xF9, 0xC8, 0xF6, 0xD5, 0xDF, 0x62, 0x94, 0x39, 0xA8, 0xF9, 0xAF, 0x46, 0xAE, 0x40, 0xF8, 0xBE, 0x5E, 0xF5, 0xAB, 0x7A, 0xB2, 0x5B, 0x9F, 0x2D, 0x6E, 0xBA, 0xF9, 0xBE, 0x99, 0x32, 0x4C, 0xBF, 0xC0, 0x2C, 0xFB, 0xC6, 0xBD, 0x24, 0x6E, 0x1B, 0x69, 0xF8, 0xB8, 0xA2, 0x3F, 0x0F, 0x7F, 0x03, 
+                       0x60, 0xC6, 0xA8, 0x10, 0x80, 0x7A, 0xEA, 0x16, 0xE2, 0x2E, 0xBA, 0x60, 0x0A, 0x76, 0x9A, 0x60, 0x5A, 0x50, 0x59, 0x06, 0xD6, 0x76, 0x2C, 0x73, 0x7B, 0x50, 0x6F, 0x55, 0x6E, 0x86, 0xED, 0xC5, 0x35, 0x2C, 0xEF, 0x9F, 0xC8, 0x81, 0xE5, 0xFF, 0xBE, 0xDD, 0x48, 0x20, 0x35, 0x1B, 0x9B, 0xCF, 0x77, 0x13, 0x21, 0x9D, 0xD6, 0x19, 0xFC, 0x08, 0x94, 0xB6, 0xB3, 0xF5, 0x03, 0xAE, 0x8F, 0x10, 0x14, 0x9C, 0x7E, 0x86, 0x43, 0x1D, 0x3D, 0x9D, 0xEA, 0x3A, 0xDD, 0x62, 0x53, 0xFE, 0x92, 0x1F, 0xD1, 0x9B, 0x0D, 0x18, 0x0E, 0xCD, 0x5F, 0xF7, 0xE9, 0x92, 0x5F, 0xFE, 0xF2, 0x14, 0x20, 0x46, 0x9C, 0xED, 0x93, 0x0B, 
+                       0x65, 0xE3, 0xDE, 0x41, 0x53, 0x55, 0x83, 0xEE, 0x83, 0x59, 0x61, 0x74, 0x96, 0x67, 0xDB, 0x26, 0x22, 0x0B, 0x19, 0x01, 0x53, 0xF6, 0xDC, 0x13, 0xD9, 0xF5, 0xCD, 0xB3, 0x98, 0xA0, 0x52, 0x65, 0x69, 0x7B, 0xED, 0x76, 0xED, 0xFA, 0xE0, 0xAD, 0x2F, 0xDC, 0xCA, 0x0D, 0xBA, 0x25, 0xBD, 0x13, 0x5D, 0xCA, 0xFC, 0x4A, 0x22, 0xD9, 0x1D, 0xAC, 0x7F, 0x25, 0x35, 0x0D, 0xF7, 0xB0, 0xD9, 0x36, 0x9F, 0x4F, 0x0D, 0x7C, 0x92, 0x93, 0xD0, 0xA5, 0x3F, 0x64, 0xC1, 0x26, 0x41, 0x73, 0xDC, 0x3E, 0x01, 0xCA, 0xB0, 0xD8, 0xF6, 0x6D, 0x83, 0x08, 0xA3, 0x3D, 0xCE, 0xEF, 0x29, 0x6B, 0x25, 0x3D, 0x65, 0xD9, 0xB0, 0xA3, 
+                       0xA4, 0xDC, 0xC8, 0x21, 0xDF, 0x5E, 0xE8, 0x5B, 0x5D, 0xCF, 0x41, 0x81, 0x28, 0xEE, 0x80, 0xDF, 0x87, 0x0B, 0x06, 0x09, 0x46, 0x61, 0xDC, 0x99, 0xF8, 0xC6, 0xD7, 0xA8, 0x4C, 0x59, 0x37, 0xB3, 0x54, 0x82, 0xE7, 0x4F, 0x36, 0x5D, 0x58, 0x8B, 0x26, 0xE8, 0xF7, 0x76, 0x87, 0x3A, 0x43, 0x61, 0x8B, 0x93, 0xAD, 0xDE, 0x35, 0xED, 0xC5, 0x5B, 0xEC, 0x49, 0x9B, 0xA3, 0x5A, 0xC7, 0x94, 0x50, 0x0E, 0x06, 0x2F, 0xC2, 0xF2, 0x28, 0x71, 0x52, 0xE1, 0x4B, 0x24, 0x97, 0x62, 0x2A, 0x28, 0x25, 0xC5, 0x43, 0x35, 0xF1, 0x9C, 0xDF, 0xFD, 0xAD, 0x7C, 0x7D, 0xED, 0x6F, 0xCC, 0x96, 0xBF, 0x93, 0x97, 0xBA, 0x2C, 0x44, 
+                       0xB7, 0xCD, 0x9C, 0x6E, 0x0D, 0x29, 0x7C, 0x19, 0xC9, 0xA0, 0x40, 0x94, 0x35, 0x66, 0xB6, 0x4C, 0xFB, 0xA8, 0x91, 0xC1, 0x89, 0x31, 0x6E, 0x76, 0x03, 0x94, 0x65, 0xF1, 0xA3, 0x2A, 0x1A, 0xD6, 0x99, 0xB9, 0xFF, 0x2E, 0xCF, 0xC3, 0xE7, 0x80, 0x28, 0x7B, 0xD5, 0x18, 0xA6, 0xD1, 0xEC, 0x1F, 0x28, 0x65, 0xB5, 0xB7, 0x32, 0xC9, 0x3A, 0x22, 0x56, 0x87, 0x61, 0x5C, 0xB0, 0xEC, 0x87, 0xA6, 0xA5, 0x23, 0x14, 0xBA, 0x0E, 0xD1, 0xE7, 0xA2, 0x74, 0x94, 0xC9, 0x74, 0x65, 0x9C, 0x5D, 0xAF, 0x5B, 0xDD, 0x3A, 0x8B, 0x2E, 0x44, 0xDF, 0x8C, 0x7F, 0x10, 0x83, 0x3C, 0xFC, 0x2C, 0x48, 0x4D, 0xF0, 0x20, 0xB8, 0xF8, 
+                       0x63, 0x37, 0x83, 0xB1, 0xDB, 0xA3, 0x51, 0x75, 0xF3, 0xA6, 0x77, 0xAD, 0x4A, 0xAF, 0xF6, 0x0F, 0x57, 0xAB, 0x18, 0x68, 0xD8, 0x42, 0xB1, 0xC3, 0x4D, 0xE9, 0xAA, 0x1A, 0xD5, 0xB9, 0xBD, 0xEB, 0xDB, 0x5B, 0x04, 0x95, 0xC2, 0x4E, 0xE2, 0x74, 0x99, 0x6E, 0x42, 0xF0, 0xCA, 0xC5, 0xA1, 0x71, 0x90, 0xFF, 0xF7, 0x08, 0x1E, 0xDA, 0xD7, 0x53, 0x33, 0x12, 0x0A, 0xC9, 0x10, 0x04, 0x60, 0xDA, 0xC2, 0xC8, 0x73, 0x9C, 0x10, 0x03, 0x20, 0x5A, 0xC2, 0xC5, 0x2E, 0x83, 0x88, 0x72, 0x25, 0xA3, 0x98, 0xC0, 0x35, 0x56, 0x16, 0x7B, 0x8F, 0x17, 0x92, 0x72, 0xF8, 0x8A, 0x4C, 0x65, 0x79, 0x7A, 0xA5, 0xAF, 0xCB, 0x03, 
+                       0x0A, 0xAA, 0xBC, 0xBB, 0xF8, 0x30, 0x16, 0xBA, 0x1D, 0x42, 0x6F, 0xF8, 0xAA, 0xC4, 0x3A, 0x89, 0x29, 0x22, 0x7F, 0x22, 0x1F, 0x87, 0xFE, 0x34, 0x06, 0x6C, 0x0E, 0x13, 0xD0, 0x43, 0x43, 0x59, 0x4F, 0x59, 0xAA, 0x2B, 0x1E, 0xDA, 0x96, 0x06, 0x38, 0x3E, 0x18, 0x97, 0xCF, 0x1D, 0xFE, 0x43, 0xA7, 0x8C, 0xB1, 0x0D, 0x40, 0x9B, 0xC6, 0xDD, 0x79, 0x97, 0xD0, 0x0B, 0x67, 0x0E, 0x2C, 0x2D, 0xBE, 0x4F, 0x9F, 0xBC, 0x6D, 0xD1, 0xAC, 0xA3, 0xB6, 0x38, 0x53, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
+                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
+                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x07, 0x67, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x07, 0x58, 0x30, 0x82, 0x07, 0x54, 0x02, 0x01, 0x00, 0x30, 0x82, 0x07, 0x4D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
+                       0x06, 0x30, 0x0E, 0x04, 0x08, 0x4E, 0xEC, 0x16, 0x2C, 0x55, 0x4B, 0x1B, 0x3E, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x07, 0x20, 0x8A, 0xE2, 0x16, 0x78, 0xEB, 0x9F, 0xF6, 0x25, 0x67, 0x15, 0x21, 0x01, 0x86, 0xC3, 0x2E, 0x27, 0x02, 0xF4, 0x0B, 0x98, 0xD8, 0xF2, 0x44, 0xBB, 0x1A, 0xD4, 0xF2, 0xA6, 0xB8, 0x6B, 0x7B, 0x05, 0xD4, 0x57, 0x3C, 0x77, 0xD5, 0x0C, 0xDC, 0x6B, 0x1A, 0xC4, 0xEA, 0x32, 0xFC, 0x28, 0x48, 0x67, 0xA2, 0xC2, 0x20, 0xCA, 0x58, 0x95, 0x45, 0xAA, 0xE1, 0x69, 0x4B, 0x7D, 0xFD, 0x33, 0x43, 0xF3, 0xD2, 0xDF, 0xEA, 0xF3, 0xAD, 0x7D, 0x8F, 0x05, 0x5A, 0xAB, 0x7B, 0x6E, 0x6C, 0x6F, 0xD7, 
+                       0x49, 0xFC, 0x16, 0x1F, 0x30, 0x5D, 0x68, 0xB9, 0x78, 0x65, 0x12, 0x7C, 0x16, 0x14, 0x95, 0x3C, 0xA3, 0xE9, 0xEF, 0x56, 0x72, 0x07, 0x9B, 0x39, 0xA7, 0xA9, 0x52, 0x68, 0x47, 0x18, 0xED, 0x83, 0xC5, 0xFC, 0x4F, 0xC8, 0xFF, 0x86, 0xA5, 0x85, 0xBF, 0xBF, 0x38, 0xBA, 0x88, 0xA5, 0x91, 0x85, 0xE8, 0x68, 0x04, 0x71, 0x89, 0x8A, 0x0E, 0x33, 0x5A, 0x57, 0x65, 0xCC, 0x3A, 0x1D, 0xE8, 0x29, 0x1F, 0xF3, 0x5E, 0xAE, 0xBE, 0x94, 0x60, 0x79, 0x54, 0x40, 0xF6, 0x15, 0x32, 0xD6, 0x6C, 0xEC, 0x8D, 0x1A, 0x63, 0x98, 0x69, 0x6F, 0x93, 0xB2, 0x6C, 0x3E, 0xF3, 0x35, 0x42, 0x08, 0x2E, 0x7E, 0x44, 0x73, 0xC6, 0xE8, 
+                       0x74, 0x07, 0xBF, 0xD3, 0x75, 0xDE, 0x87, 0x93, 0x8D, 0x4C, 0x3B, 0xB8, 0x23, 0x91, 0x2C, 0x62, 0x99, 0xA8, 0xD6, 0xA6, 0x05, 0xB9, 0xE9, 0x8F, 0x9F, 0x86, 0xD0, 0xE0, 0xF5, 0xE6, 0x1C, 0x92, 0x8D, 0xC9, 0x7A, 0xBA, 0xF8, 0x05, 0x7C, 0x6F, 0xFB, 0x7F, 0x62, 0x4B, 0x8C, 0x9B, 0xC5, 0xDB, 0x24, 0xD0, 0x7D, 0xC6, 0xDF, 0xBB, 0x43, 0xB8, 0x31, 0x3C, 0x52, 0x69, 0xC3, 0xA9, 0x4B, 0x6C, 0xA5, 0x5D, 0xF0, 0x25, 0x90, 0x9B, 0xD8, 0xE4, 0xC2, 0x4C, 0x71, 0x68, 0x17, 0x79, 0x21, 0xB7, 0x14, 0x56, 0xC2, 0x31, 0xB5, 0xEF, 0x4D, 0x86, 0x83, 0x24, 0x78, 0x01, 0x6D, 0x41, 0x19, 0x5B, 0xD3, 0x78, 0xC0, 0xE7, 
+                       0xF4, 0xEE, 0x86, 0xEC, 0x4D, 0x19, 0xB4, 0x2E, 0x65, 0x4C, 0x47, 0xFC, 0x7D, 0xDF, 0x56, 0xE1, 0xC3, 0x65, 0xF2, 0x30, 0xB5, 0x13, 0x93, 0xAD, 0x31, 0x56, 0xF3, 0x77, 0x4D, 0x9B, 0x6A, 0xA6, 0xCC, 0xF0, 0x20, 0x34, 0x11, 0xE7, 0xBD, 0xB1, 0xAD, 0xB9, 0xCB, 0xF3, 0x48, 0x6B, 0xB9, 0xF6, 0xB1, 0x7F, 0x9B, 0x61, 0x4C, 0x09, 0x05, 0xC1, 0x8D, 0xA7, 0x2B, 0xF0, 0xE5, 0x6C, 0x7D, 0xEB, 0xE3, 0x83, 0x6B, 0xA0, 0x77, 0x98, 0x6C, 0x5D, 0x59, 0x5B, 0xE2, 0x69, 0xC6, 0x97, 0x15, 0x60, 0x7A, 0x69, 0x7F, 0xC2, 0xF6, 0xF6, 0xAD, 0x33, 0xAE, 0x7D, 0x06, 0xA1, 0xF4, 0x5B, 0xA4, 0x17, 0xC3, 0xA5, 0xB5, 0xFA, 
+                       0x60, 0xD1, 0x58, 0x30, 0x1F, 0x81, 0x15, 0x49, 0x05, 0x6D, 0x54, 0xD8, 0xE8, 0x9E, 0xBF, 0x61, 0xD2, 0xD0, 0x8A, 0x95, 0xBD, 0x1C, 0x05, 0x6B, 0x15, 0xDC, 0x29, 0x80, 0xB1, 0x91, 0x66, 0xCE, 0x57, 0xCE, 0xFD, 0x5A, 0x3F, 0x18, 0xB9, 0x87, 0x32, 0x92, 0x6E, 0xA3, 0x42, 0x20, 0xC4, 0x36, 0xBD, 0x7E, 0xE2, 0x38, 0xF3, 0xDD, 0x50, 0x00, 0x28, 0x8C, 0x78, 0x2C, 0x94, 0xEC, 0x0F, 0xFE, 0xC2, 0x6F, 0x4D, 0x09, 0xC6, 0xE0, 0xCD, 0x50, 0xC6, 0x3B, 0x1D, 0x81, 0x2C, 0xE5, 0xEA, 0xF8, 0x31, 0x17, 0xCC, 0x37, 0x09, 0xBC, 0x7F, 0x19, 0x46, 0x4D, 0x83, 0x4A, 0xB6, 0x6E, 0x02, 0x10, 0x03, 0xAF, 0xEF, 0xE4, 
+                       0x02, 0x4A, 0x11, 0xC6, 0x11, 0xA6, 0xFC, 0xC3, 0x0E, 0x62, 0xAB, 0x98, 0x71, 0x32, 0x86, 0xA6, 0x22, 0x1B, 0x5F, 0x2C, 0x18, 0x78, 0x0E, 0x21, 0xA5, 0x5C, 0xC4, 0x3D, 0x06, 0x9A, 0x1E, 0x03, 0xAA, 0x7A, 0x49, 0x04, 0x0D, 0x82, 0xAF, 0xDD, 0x02, 0x70, 0x2E, 0x33, 0x10, 0x6F, 0x6A, 0xBF, 0xE4, 0x2F, 0xAA, 0x54, 0x8A, 0x0F, 0xCC, 0x85, 0xE9, 0xD9, 0x7E, 0x43, 0xCF, 0xDC, 0x32, 0x35, 0xA8, 0xEC, 0x87, 0x3D, 0x08, 0xB1, 0x63, 0xE3, 0x48, 0xDC, 0xB9, 0xDB, 0x2C, 0xA6, 0x9F, 0xB9, 0x7D, 0x90, 0xCA, 0xD1, 0x03, 0x76, 0xE6, 0x6D, 0xAD, 0x51, 0x10, 0xED, 0xA1, 0x7E, 0x06, 0x72, 0xC2, 0x12, 0x93, 0x7E, 
+                       0x7A, 0xF0, 0x84, 0xFE, 0x1C, 0x2A, 0xB0, 0xF1, 0x13, 0x2F, 0x68, 0x2B, 0x66, 0xB8, 0xAD, 0x14, 0x28, 0x65, 0x85, 0xC4, 0x92, 0x0F, 0x10, 0x3F, 0x1A, 0xCD, 0x6D, 0x74, 0x39, 0x5E, 0x9D, 0x6F, 0x11, 0xD3, 0xB4, 0xDA, 0xB6, 0x1A, 0x1D, 0x73, 0x29, 0xF3, 0x4A, 0x4F, 0x77, 0x19, 0x53, 0x59, 0x38, 0xF5, 0x58, 0x77, 0xE5, 0x45, 0xBA, 0x03, 0xD4, 0x9C, 0x1B, 0x11, 0x9C, 0xA2, 0x91, 0x80, 0xC7, 0x2C, 0xEB, 0x0C, 0x8D, 0x7E, 0xA1, 0x94, 0x1B, 0x7B, 0x74, 0x0F, 0x21, 0xB5, 0xE5, 0xBA, 0xEA, 0x14, 0x65, 0xAA, 0xFB, 0x5F, 0x91, 0x7A, 0x73, 0xBB, 0x04, 0x4E, 0x74, 0xFE, 0x24, 0xDF, 0x63, 0x18, 0xDF, 0xC2, 
+                       0x74, 0x5F, 0x4C, 0x9C, 0x9D, 0x0C, 0x94, 0x58, 0x89, 0x3F, 0x77, 0x63, 0x03, 0x77, 0x9C, 0x6E, 0xDE, 0x01, 0x13, 0x62, 0xEF, 0xCF, 0x57, 0xAB, 0x15, 0x22, 0xB6, 0x40, 0xFF, 0x0A, 0xFC, 0x91, 0xB8, 0x52, 0xFA, 0xCC, 0x7C, 0xEE, 0xB8, 0xA3, 0x7C, 0x8B, 0x3C, 0x04, 0x2E, 0xAB, 0x00, 0x78, 0x95, 0xD5, 0x0B, 0xC0, 0xF1, 0x5D, 0x52, 0x25, 0x92, 0x6B, 0x99, 0x71, 0x2E, 0x2B, 0x3A, 0x15, 0x2A, 0x15, 0xE8, 0xAC, 0x79, 0x71, 0xAE, 0xC7, 0xDA, 0x7C, 0x9D, 0x7E, 0xD5, 0x75, 0x34, 0xA6, 0x76, 0x46, 0xB1, 0x87, 0x94, 0xAD, 0x1F, 0x75, 0x74, 0x69, 0xE7, 0x26, 0xD6, 0xB1, 0x32, 0xFE, 0x0A, 0xCA, 0x3C, 0x54, 
+                       0x7D, 0x24, 0x95, 0xE1, 0xFD, 0x37, 0xE6, 0x34, 0xA5, 0x8B, 0x42, 0x88, 0x71, 0x22, 0xFE, 0x94, 0x42, 0xD5, 0xF8, 0xEE, 0x1E, 0x57, 0x2A, 0xD4, 0xB7, 0xC8, 0x90, 0xA2, 0x4A, 0xE0, 0xB7, 0xB5, 0x37, 0x72, 0x59, 0xF5, 0xA4, 0x8D, 0x3C, 0xFE, 0x3B, 0xD2, 0x8F, 0xEA, 0xBB, 0x83, 0x77, 0x78, 0xDA, 0x6E, 0xF3, 0x35, 0x03, 0x2E, 0xF1, 0x95, 0x6E, 0x91, 0x25, 0x9B, 0x11, 0x35, 0xBE, 0x08, 0xBB, 0xCB, 0x5C, 0x34, 0x1F, 0x22, 0x02, 0xE3, 0x0E, 0x5E, 0xC4, 0xF8, 0xD1, 0x6C, 0xF9, 0x87, 0x67, 0x0B, 0x33, 0xBD, 0xD3, 0xF0, 0x25, 0x5C, 0x68, 0xD5, 0xD0, 0xA7, 0x4E, 0x2E, 0x8B, 0xB6, 0x45, 0xD9, 0x8A, 0x33, 
+                       0x80, 0x08, 0xBD, 0x8D, 0x17, 0xFD, 0x4C, 0x4C, 0xFD, 0x06, 0x85, 0x5A, 0x4A, 0xDF, 0x4C, 0xD7, 0x16, 0x78, 0xB0, 0x0F, 0xA9, 0x35, 0x4A, 0x71, 0x9F, 0x10, 0xE1, 0x26, 0x09, 0x03, 0x29, 0xE3, 0x11, 0x2A, 0xF4, 0x4F, 0x02, 0xBD, 0x29, 0x54, 0xA8, 0x8F, 0xFE, 0xC4, 0x98, 0xD4, 0x28, 0x86, 0x00, 0x37, 0xC9, 0x2C, 0xCF, 0xB6, 0xA6, 0x0B, 0x98, 0x22, 0xE6, 0xAA, 0x8A, 0x51, 0x45, 0xAF, 0xBB, 0x63, 0x25, 0x42, 0x7F, 0x3E, 0x8C, 0x34, 0x30, 0x86, 0x39, 0x9D, 0x58, 0xC1, 0xC0, 0x1F, 0xA8, 0xEE, 0x2A, 0x42, 0x4C, 0x0C, 0xCA, 0x62, 0xCA, 0xD1, 0xA6, 0x26, 0xA1, 0xB9, 0x3D, 0x6C, 0xDE, 0x72, 0x71, 0xC5, 
+                       0xAB, 0xE2, 0xD6, 0x67, 0x36, 0xDD, 0xD9, 0xFE, 0x32, 0x43, 0x3A, 0x33, 0x0E, 0x4C, 0x25, 0x5A, 0x25, 0x77, 0xFD, 0x0C, 0x7E, 0xE3, 0x8F, 0x9A, 0x12, 0x7F, 0x09, 0x15, 0x92, 0x5D, 0x21, 0xB8, 0x6F, 0x6C, 0xBC, 0xCC, 0x37, 0xEF, 0x32, 0x7D, 0xAF, 0x90, 0x47, 0xAF, 0x54, 0xD9, 0xD6, 0x9E, 0x50, 0xB6, 0x7D, 0x1E, 0x1C, 0xD8, 0x8D, 0x72, 0x64, 0x86, 0x93, 0xDB, 0x2E, 0xCE, 0x1E, 0x95, 0xA8, 0xBF, 0x6B, 0x22, 0x9B, 0x16, 0x72, 0x2A, 0xA2, 0x53, 0x37, 0x8F, 0x81, 0xCE, 0x0B, 0x8E, 0x27, 0x23, 0x73, 0x7C, 0xE7, 0x15, 0x32, 0x20, 0xA1, 0xD4, 0xE9, 0xCD, 0x10, 0xC2, 0xC0, 0xB9, 0x92, 0x8E, 0x8E, 0x0B, 
+                       0x50, 0x79, 0x15, 0xFE, 0x64, 0x90, 0x85, 0xB7, 0x65, 0xAD, 0x6A, 0x80, 0xF3, 0x43, 0x3D, 0x1C, 0xCC, 0xFB, 0xC6, 0x8C, 0x83, 0x23, 0xE3, 0xA7, 0x4C, 0xCE, 0x88, 0x8C, 0x99, 0xED, 0xCE, 0xC8, 0x29, 0xA7, 0x45, 0xA7, 0x3A, 0xC2, 0x24, 0x6C, 0xD7, 0x47, 0x37, 0x06, 0xEE, 0xAE, 0xD7, 0xC7, 0xE6, 0x09, 0x2D, 0xAC, 0x13, 0x5A, 0xE1, 0x83, 0x72, 0x65, 0x60, 0x21, 0x97, 0x1A, 0x56, 0x6B, 0xFA, 0xE4, 0x4B, 0x71, 0x6E, 0x99, 0x1F, 0x09, 0xBF, 0x97, 0x23, 0xC2, 0x1A, 0xEE, 0xEA, 0x82, 0x07, 0x9C, 0x8F, 0x7C, 0x80, 0xBA, 0xC3, 0x68, 0xFC, 0x42, 0xE4, 0x50, 0x80, 0x71, 0x48, 0x74, 0x6A, 0x10, 0x23, 0x7E, 
+                       0x44, 0xD6, 0xA2, 0xB9, 0x3E, 0x95, 0xA0, 0x0E, 0x0B, 0xA6, 0xA8, 0x45, 0xD8, 0xE5, 0x18, 0x17, 0x63, 0xB9, 0xE2, 0x66, 0x88, 0xA4, 0xEC, 0x4A, 0x88, 0x3F, 0x54, 0x2B, 0x7D, 0x89, 0xC3, 0x73, 0x84, 0x83, 0x76, 0x62, 0x6B, 0xD6, 0xDA, 0x76, 0x43, 0xD7, 0xCA, 0xE3, 0x78, 0x45, 0x5A, 0x46, 0xA7, 0x6D, 0x0E, 0x42, 0x41, 0x80, 0xDB, 0x03, 0xDD, 0x11, 0x5F, 0xD1, 0x0F, 0x3F, 0x9C, 0xD3, 0xBB, 0xEF, 0xCC, 0x8C, 0x10, 0x96, 0x6B, 0xA0, 0x86, 0xB9, 0x32, 0xFD, 0xB4, 0xA8, 0x55, 0x90, 0x57, 0x80, 0x30, 0x9A, 0xB3, 0xC0, 0xE1, 0xDE, 0xEC, 0x56, 0x3A, 0x16, 0x2F, 0x9B, 0x04, 0x00, 0x4C, 0x84, 0xC1, 0x42, 
+                       0xBE, 0x3D, 0xC8, 0xD4, 0x8B, 0x86, 0x0B, 0x0A, 0x73, 0x32, 0x50, 0x18, 0x73, 0x3E, 0x96, 0x70, 0xB1, 0x58, 0x96, 0x67, 0x60, 0x36, 0xFA, 0x9F, 0xC5, 0x22, 0xBD, 0x29, 0xEB, 0xFB, 0xA9, 0xDA, 0x16, 0xF0, 0x1C, 0xDE, 0xEB, 0x6E, 0xB7, 0x7D, 0x2F, 0x13, 0xBE, 0x13, 0x34, 0xB3, 0x70, 0x49, 0xEF, 0x15, 0x96, 0xEF, 0x55, 0xF4, 0x39, 0x34, 0x2F, 0xB4, 0x3C, 0x26, 0x2B, 0xEC, 0x66, 0x20, 0x29, 0x14, 0xB6, 0x70, 0xCC, 0x40, 0x11, 0xC1, 0xC4, 0x55, 0xDF, 0x44, 0x62, 0xEA, 0x86, 0x26, 0x7F, 0x70, 0x91, 0x37, 0x1E, 0x35, 0x6A, 0x29, 0x29, 0x1D, 0x4A, 0x38, 0x74, 0x4D, 0x19, 0xF2, 0x8B, 0x02, 0x51, 0xF2, 
+                       0x89, 0xE7, 0xBE, 0xEA, 0xCC, 0x3C, 0x7F, 0x94, 0x14, 0xB1, 0x99, 0x99, 0xCB, 0x19, 0xA8, 0x20, 0x1B, 0x5C, 0xEE, 0xAD, 0x5E, 0x41, 0xA3, 0x13, 0x63, 0xD9, 0x3C, 0x6B, 0x7E, 0x60, 0xBB, 0x26, 0x59, 0x11, 0xD1, 0x85, 0x00, 0x08, 0x68, 0xDC, 0xF3, 0xCD, 0x55, 0xAC, 0x0E, 0xC3, 0x77, 0xDC, 0xED, 0x5A, 0x83, 0x51, 0x4C, 0xCC, 0xAE, 0xBA, 0xF7, 0x60, 0x47, 0x61, 0x01, 0xCC, 0x31, 0x46, 0xF5, 0x2A, 0x06, 0x39, 0x15, 0xCD, 0x1C, 0x2C, 0x32, 0x79, 0x2E, 0x1E, 0x73, 0x80, 0xA6, 0x91, 0x7B, 0xCD, 0xFE, 0x0F, 0x8B, 0x86, 0x91, 0xD3, 0xD2, 0x07, 0xB8, 0x48, 0x1A, 0x63, 0x41, 0xE7, 0x62, 0xDF, 0x1E, 0x59, 
+                       0x9B, 0xFA, 0xC8, 0x25, 0xC3, 0x70, 0x96, 0x8E, 0xEB, 0xA7, 0x5D, 0x0D, 0x6C, 0xBA, 0xB1, 0xDD, 0x8F, 0xB7, 0xA8, 0xBF, 0xBD, 0xBE, 0xFF, 0x86, 0x8A, 0x31, 0x11, 0xAF, 0x33, 0x6A, 0x1E, 0x11, 0xDF, 0x06, 0x0C, 0x16, 0x98, 0x9E, 0x5B, 0xE3, 0x4C, 0x31, 0xF4, 0x5F, 0x61, 0xC0, 0x22, 0xAC, 0x80, 0xA7, 0x05, 0xAA, 0x48, 0x77, 0xCE, 0x2F, 0x2F, 0x93, 0xA6, 0x19, 0x12, 0x6C, 0x40, 0x24, 0xC0, 0xF1, 0xF9, 0xC1, 0x13, 0x99, 0x2A, 0xE7, 0x12, 0xB2, 0xA4, 0x67, 0xCD, 0xC6, 0xA7, 0xE2, 0x59, 0x20, 0x71, 0xB8, 0x5D, 0x3C, 0xAC, 0x8A, 0x30, 0x00, 0xDE, 0xAB, 0x97, 0x94, 0x7E, 0x72, 0xF0, 0xDA, 0x6D, 0x9D, 
+                       0xDF, 0x89, 0x53, 0x06, 0x93, 0x6F, 0xA4, 0x90, 0x30, 0xFA, 0xD3, 0x26, 0xE6, 0x24, 0xBF, 0x3E, 0x22, 0xA2, 0x46, 0x55, 0xF6, 0x6A, 0x16, 0x5D, 0x3E, 0x17, 0x7E, 0x13, 0x02, 0x9C, 0x2D, 0x07, 0x79, 0x58, 0x00, 0x32, 0xD2, 0x10, 0x93, 0x85, 0x98, 0x2D, 0xF8, 0x5D, 0x5B, 0x74, 0xB0, 0x7E, 0x4B, 0x57, 0x64, 0xEA, 0x66, 0xDF, 0xE1, 0x04, 0xCC, 0x35, 0x9F, 0x0E, 0x46, 0x8A, 0xFB, 0x1C, 0x0D, 0x37, 0x8D, 0xC0, 0x13, 0x67, 0xAE, 0xC0, 0xD2, 0x2E, 0x9B, 0xB4, 0x16, 0x1B, 0xA4, 0x9A, 0x23, 0x18, 0xD2, 0x58, 0x9E, 0x3F, 0x4B, 0x83, 0x0D, 0x4A, 0xE4, 0xF3, 0xB3, 0xFC, 0x0A, 0xF9, 0xA5, 0x01, 0x9C, 0x44, 
+                       0x89, 0x53, 0xBD, 0x10, 0xAA, 0x1E, 0xC6, 0x41, 0x7C, 0x71, 0xCA, 0x47, 0x79, 0x60, 0x95, 0x2E, 0xAB, 0xF6, 0x17, 0xBE, 0x1D, 0xF1, 0x05, 0xAD, 0x76, 0xD8, 0xBB, 0xF2, 0xBB, 0x36, 0xEE, 0xCD, 0xAA, 0xBC, 0xBA, 0xBE, 0x94, 0x42, 0x9A, 0xA8, 0xEE, 0xE5, 0x93, 0x5C, 0x3C, 0x23, 0xE2, 0x75, 0xD3, 0x59, 0xB4, 0xB3, 0xC4, 0x01, 0xBB, 0xC9, 0x05, 0xFE, 0xFA, 0x1B, 0x31, 0x7A, 0x15, 0x29, 0x91, 0xE6, 0xB9, 0xB2, 0x1E, 0xF9, 0x36, 0xC5, 0x17, 0xB9, 0x9D, 0x32, 0x0D, 0x0D, 0x80, 0x4A, 0x0D, 0x14, 0xB4, 0xDF, 0x89, 0x3A, 0x4B, 0xCA, 0x4B, 0xDE, 0xF8, 0xC0, 0x1B, 0xA6, 0x6D, 0xD9, 0x19, 0xFB, 0x0E, 0x02, 
+                       0x22, 0x82, 0x8E, 0x25, 0x8E, 0x9F, 0xD5, 0x7B, 0xB6, 0x14, 0x15, 0x08, 0x61, 0xCD, 0xA6, 0xB3, 0x0F, 0xC8, 0xE8, 0xF9, 0xEE, 0xDB, 0xAF, 0x25, 0x40, 0x01, 0x85, 0x0E, 0x89, 0x0D, 0x0D, 0x85, 0xA6, 0xA3, 0xC9, 0x65, 0x64, 0x8A, 0xD1, 0xF7, 0x55, 0xF9, 0x31, 0x24, 0x41, 0x30, 0x3B, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0xD4, 0x77, 0x3F, 0x92, 0xB6, 0xA6, 0x1B, 0xD5, 0x7F, 0xC1, 0x1B, 0x93, 0xB3, 0x6E, 0x87, 0x67, 0x80, 0xE7, 0x4C, 0x7C, 0x04, 0x14, 0x58, 0x4C, 0x92, 0xDD, 0x0B, 0xEF, 0x09, 0x35, 0xE0, 0x06, 0x33, 0x54, 0xB2, 0xA8, 0x8E, 0x0C, 0x60, 0x67, 
+                       0xB5, 0x0F, 0x02, 0x02, 0x07, 0xD0 };
+
+               public const string base64_cert = @"-----BEGIN CERTIFICATE-----
+MIIBxTCCATKgAwIBAgIQx3WuSFObHp5EgBXKeBVHaTAJBgUrDgMCHQUAMCUxIzAh
+BgNVBAMeGgBDAEEAUwBUAE8AUgBcAHAAbwB1AHAAbwB1MB4XDTA1MDYwODEzMzg0
+N1oXDTA2MDYwODE5Mzg0N1owJTEjMCEGA1UEAx4aAEMAQQBTAFQATwBSAFwAcABv
+AHUAcABvAHUwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBANrqOTj2OvSL+eLH
+1Sz5GtV1zxess0a9fz+XOC4QQbLE2RQV2Ob5ETiAdePXH8CGpz4CEQTpV7XYV2Un
+e4+6ue+gjxWc7C+FY05Sa6bjM8qGIrr5Bujsy6elqOI+xyF0TsnpBV+ueBJRL/pq
+j3ywZCr7t7JAkSDnMlM/WMqAokHFAgMBAAEwCQYFKw4DAh0FAAOBgQCdV7All4Ei
+PMRhncnb2MfB7fsc3TWY10BYpEOGVPloloW1kby3grJ+e1i9gM40fiKHYjG1Axag
+IBed512qEvWS35Tmac32/IKb3NMwQLFxT0pky9wUyMF/byPO3RkiTyQeJxhmiHqa
+mgk3bWUV6ChegutbguiKrI/DbO7wPiDLxw==
+-----END CERTIFICATE-----";
+
+               static public byte[] farscape_pkcs7 = { 0x30, 0x82, 0x02, 0x59, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x02, 0xA0, 0x82, 0x02, 0x4A, 0x30, 0x82, 0x02, 0x46, 0x02, 0x01, 0x01, 0x31, 0x00, 0x30, 0x0B, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x02, 0x2E, 0x30, 0x82, 0x02, 0x2A, 0x30, 0x82, 0x01, 0x97, 0xA0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x10, 0x91, 0xC4, 0x4B, 0x0D, 0xB7, 0xD8, 0x10, 0x84, 0x42, 0x26, 0x71, 0xB3, 0x97, 0xB5, 0x00, 0x97, 0x30, 0x09, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x30, 0x28, 0x31, 0x26, 0x30, 0x24, 0x06, 0x03, 
+                       0x55, 0x04, 0x03, 0x13, 0x1D, 0x4D, 0x6F, 0x74, 0x75, 0x73, 0x20, 0x54, 0x65, 0x63, 0x68, 0x6E, 0x6F, 0x6C, 0x6F, 0x67, 0x69, 0x65, 0x73, 0x20, 0x69, 0x6E, 0x63, 0x2E, 0x28, 0x74, 0x65, 0x73, 0x74, 0x29, 0x30, 0x1E, 0x17, 0x0D, 0x30, 0x33, 0x30, 0x38, 0x31, 0x33, 0x30, 0x30, 0x34, 0x33, 0x34, 0x37, 0x5A, 0x17, 0x0D, 0x33, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x35, 0x39, 0x35, 0x39, 0x5A, 0x30, 0x13, 0x31, 0x11, 0x30, 0x0F, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x08, 0x46, 0x41, 0x52, 0x53, 0x43, 0x41, 0x50, 0x45, 0x30, 0x81, 0x9F, 0x30, 0x0D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 
+                       0x01, 0x01, 0x01, 0x05, 0x00, 0x03, 0x81, 0x8D, 0x00, 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xD2, 0xCB, 0x47, 0x21, 0xF5, 0x62, 0xDD, 0x35, 0xBF, 0x1D, 0xEC, 0x9A, 0x4C, 0x07, 0x2C, 0x01, 0xF0, 0x28, 0xC2, 0x82, 0x17, 0x8E, 0x58, 0x32, 0xD5, 0x4C, 0xAC, 0x86, 0xB4, 0xC9, 0xEB, 0x21, 0x26, 0xF3, 0x22, 0x30, 0xC5, 0x7A, 0xA3, 0x5A, 0xDD, 0x53, 0xAB, 0x1C, 0x06, 0x3E, 0xB2, 0x13, 0xC4, 0x05, 0x1D, 0x95, 0x8B, 0x0A, 0x71, 0x71, 0x11, 0xA7, 0x47, 0x26, 0x61, 0xF1, 0x76, 0xBE, 0x35, 0x72, 0x32, 0xC5, 0xCB, 0x47, 0xA4, 0x22, 0x41, 0x1E, 0xAD, 0x29, 0x11, 0x0D, 0x39, 0x22, 0x0C, 0x79, 0x90, 0xC6, 
+                       0x52, 0xA1, 0x10, 0xF6, 0x55, 0x09, 0x4E, 0x51, 0x26, 0x47, 0x0E, 0x94, 0xE6, 0x81, 0xF5, 0x18, 0x6B, 0x99, 0xF0, 0x76, 0xF3, 0xB2, 0x4C, 0x91, 0xE9, 0xBA, 0x3B, 0x3F, 0x6E, 0x63, 0xDA, 0x12, 0xD1, 0x0B, 0x73, 0x0E, 0x12, 0xC7, 0x70, 0x77, 0x22, 0x03, 0x9D, 0x5D, 0x02, 0x03, 0x01, 0x00, 0x01, 0xA3, 0x72, 0x30, 0x70, 0x30, 0x13, 0x06, 0x03, 0x55, 0x1D, 0x25, 0x04, 0x0C, 0x30, 0x0A, 0x06, 0x08, 0x2B, 0x06, 0x01, 0x05, 0x05, 0x07, 0x03, 0x01, 0x30, 0x59, 0x06, 0x03, 0x55, 0x1D, 0x01, 0x04, 0x52, 0x30, 0x50, 0x80, 0x10, 0xAE, 0xD7, 0x80, 0x88, 0xA6, 0x3D, 0xBA, 0x50, 0xA1, 0x7E, 0x57, 0xE5, 0x40, 
+                       0xC9, 0x6F, 0xC5, 0xA1, 0x2A, 0x30, 0x28, 0x31, 0x26, 0x30, 0x24, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x1D, 0x4D, 0x6F, 0x74, 0x75, 0x73, 0x20, 0x54, 0x65, 0x63, 0x68, 0x6E, 0x6F, 0x6C, 0x6F, 0x67, 0x69, 0x65, 0x73, 0x20, 0x69, 0x6E, 0x63, 0x2E, 0x28, 0x74, 0x65, 0x73, 0x74, 0x29, 0x82, 0x10, 0x9D, 0xAE, 0xA3, 0x39, 0x47, 0x0E, 0xD4, 0xA2, 0x49, 0x78, 0xEA, 0x6C, 0xBA, 0x0D, 0xDE, 0x9C, 0x30, 0x09, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x03, 0x81, 0x81, 0x00, 0x32, 0x8A, 0x7E, 0xAD, 0xE7, 0x67, 0x9E, 0x5C, 0x4C, 0xD8, 0x33, 0x59, 0x68, 0xCF, 0x94, 0xC0, 0x36, 0x47, 0x7A, 0xA7, 
+                       0x85, 0xC2, 0xDD, 0xD8, 0xDA, 0x11, 0x3C, 0x66, 0xC1, 0x83, 0xE3, 0xAB, 0x33, 0x06, 0x7C, 0xE3, 0x6A, 0x15, 0x72, 0xB8, 0x83, 0x3D, 0x0B, 0xAB, 0x3C, 0xEE, 0x75, 0x13, 0xBD, 0x5C, 0x96, 0x25, 0x56, 0x36, 0x05, 0xFA, 0xAE, 0xD4, 0xF4, 0xCF, 0x52, 0xEC, 0x11, 0xB5, 0xEA, 0x9F, 0x20, 0xA3, 0xC8, 0x34, 0x72, 0x59, 0x09, 0x51, 0xE7, 0x36, 0x87, 0x86, 0x86, 0x98, 0xB5, 0x30, 0x7B, 0xFB, 0x3D, 0xCC, 0x5E, 0xE8, 0xC9, 0x49, 0xE0, 0xC6, 0xEA, 0x02, 0x76, 0x01, 0xE0, 0xBB, 0x8A, 0x70, 0xEB, 0x07, 0x86, 0xE8, 0x04, 0xE7, 0x48, 0xE4, 0x6C, 0x90, 0xE6, 0x16, 0x42, 0xB4, 0xBB, 0xC0, 0xC4, 0x82, 0x5F, 0xF8, 
+                       0xFB, 0x7E, 0xB2, 0x9E, 0xC2, 0x78, 0x26, 0x86, 0x31, 0x00 };
+
+               [Test]
+               public void Equals ()
+               {
+                       X509Certificate x1 = new X509Certificate (cert1);
+                       Assert.IsTrue (x1.Equals (x1), "Equals-Self-X");
+                       Assert.IsTrue (x1.Equals ((object)x1), "Equals-Self-O");
+                       X509Certificate x2 = new X509Certificate (cert1);
+                       Assert.IsTrue (x1.Equals (x2), "Equals-12-X");
+                       Assert.IsTrue (x1.Equals ((object)x2), "Equals-12-O");
+                       Assert.IsTrue (x2.Equals (x1), "Equals-12-X");
+                       Assert.IsTrue (x2.Equals ((object)x1), "Equals-12-O");
+               }
+
+               [Test]
+               public void Equals_Empty_Source ()
+               {
+                       X509Certificate empty = new X509Certificate ();
+                       Assert.IsFalse (empty.Equals (null), "null");
+                       X509Certificate x = new X509Certificate (cert1);
+                       Assert.IsFalse (empty.Equals (x), "X509Certificate");
+                       Assert.IsFalse (empty.Equals ((object) x), "object");
+                       Assert.IsTrue (empty.Equals (empty), "empty");
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Equals_Empty_Destination ()
+               {
+                       new X509Certificate (cert1).Equals (new X509Certificate ());
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Export_Authenticode ()
+               {
+                       new X509Certificate (cert1).Export (X509ContentType.Authenticode);
+               }
+
+               [Test]
+               public void Export_Cert ()
+               {
+                       X509Certificate cert = new X509Certificate (cert1);
+                       byte[] data = cert.Export (X509ContentType.Cert);
+                       Assert.AreEqual (data, cert1, "original");
+
+                       data = cert.Export (X509ContentType.Cert, (string)null);
+                       Assert.AreEqual (data, cert1, "original/string/null");
+
+                       data = cert.Export (X509ContentType.Cert, (SecureString) null);
+                       Assert.AreEqual (data, cert1, "original/SecureString/null");
+               }
+
+               [Test]
+               [Category ("NotWorking")]
+               public void Export_Pfx ()
+               {
+                       X509Certificate cert = new X509Certificate (cert1);
+                       byte[] data = cert.Export (X509ContentType.Pfx);
+                       // usable
+                       X509Certificate2 c = new X509Certificate2 (data);
+                       Assert.AreEqual (cert1, c.GetRawCertData (), "Equals");
+               }
+
+               [Test]
+               [Category ("NotWorking")]
+               public void Export_Pkcs12 ()
+               {
+                       X509Certificate cert = new X509Certificate (cert1);
+                       byte[] data = cert.Export (X509ContentType.Pkcs12);
+                       // usable
+                       X509Certificate2 c = new X509Certificate2 (data);
+                       Assert.AreEqual (cert1, c.GetRawCertData (), "Equals");
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Export_Pkcs7 ()
+               {
+                       new X509Certificate (cert1).Export (X509ContentType.Pkcs7);
+               }
+
+               [Test]
+               [Category ("NotWorking")]
+               public void Export_SerializedCert ()
+               {
+                       X509Certificate cert = new X509Certificate (cert1);
+                       byte[] data = cert.Export (X509ContentType.SerializedCert);
+                       // usable
+                       X509Certificate2 c = new X509Certificate2 (data);
+                       Assert.AreEqual (cert1, c.GetRawCertData (), "Equals");
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Export_SerializedStore ()
+               {
+                       new X509Certificate (cert1).Export (X509ContentType.SerializedStore);
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Export_Unknown ()
+               {
+                       new X509Certificate (cert1).Export (X509ContentType.Unknown);
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Export_Bad ()
+               {
+                       new X509Certificate (cert1).Export ((X509ContentType) Int32.MinValue);
+               }
+
+               [Test]
+               public void UnrequiredPassword ()
+               {
+                       // MS permits to supply an unrequired password for an (unencrypted) DER certificate
+                       X509Certificate x1 = new X509Certificate (cert1, "mono");
+               }
+
+               [Test]
+               public void Empty ()
+               {
+                       X509Certificate x = new X509Certificate ();
+                       Assert.AreEqual ("X509", x.GetFormat (), "GetFormat");
+                       Assert.AreEqual (0, x.GetHashCode (), "GetHashCode");
+                       Assert.AreEqual (IntPtr.Zero, x.Handle, "Handle");
+                       Assert.AreEqual ("System.Security.Cryptography.X509Certificates.X509Certificate", x.ToString (true), "ToString(true)");
+                       Assert.AreEqual ("System.Security.Cryptography.X509Certificates.X509Certificate", x.ToString (false), "ToString(false)");
+                       Assert.IsTrue (x.Equals (x), "Equals(X509Certificate)");
+                       Assert.IsTrue (x.Equals ((object) x), "Equals(object)");
+                       x.Reset ();
+                       x.Import (cert1);
+                       Assert.AreEqual ("02720006E8", x.GetSerialNumberString (), "GetSerialNumberString");
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_Issuer ()
+               {
+                       X509Certificate x = new X509Certificate ();
+                       Assert.IsNotNull (x.Issuer, "Issuer");
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_Subject ()
+               {
+                       X509Certificate x = new X509Certificate ();
+                       Assert.IsNotNull (x.Subject, "Subject");
+               }
+
+               [Test]
+               [Category ("NotDotNet")] // FatalExecutionEngineError / Crash NUnit
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_Export ()
+               {
+                       new X509Certificate ().Export (X509ContentType.Cert);
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetCertHash ()
+               {
+                       new X509Certificate ().GetCertHash ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetCertHashString ()
+               {
+                       new X509Certificate ().GetCertHashString ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetEffectiveDateString ()
+               {
+                       new X509Certificate ().GetEffectiveDateString ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetExpirationDateString ()
+               {
+                       new X509Certificate ().GetExpirationDateString ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetIssuerName ()
+               {
+                       new X509Certificate ().GetIssuerName ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetKeyAlgorithm ()
+               {
+                       new X509Certificate ().GetKeyAlgorithm ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetKeyAlgorithmParameters ()
+               {
+                       new X509Certificate ().GetKeyAlgorithmParameters ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetKeyAlgorithmParametersString ()
+               {
+                       new X509Certificate ().GetKeyAlgorithmParametersString ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetName ()
+               {
+                       new X509Certificate ().GetName ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetPublicKey ()
+               {
+                       new X509Certificate ().GetPublicKey ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetPublicKeyString ()
+               {
+                       new X509Certificate ().GetPublicKeyString ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetRawCertData ()
+               {
+                       new X509Certificate ().GetRawCertData ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetRawCertDataString ()
+               {
+                       new X509Certificate ().GetRawCertDataString ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetSerialNumber ()
+               {
+                       new X509Certificate ().GetSerialNumber ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Empty_GetSerialNumberString ()
+               {
+                       new X509Certificate ().GetSerialNumberString ();
+               }
+
+               [Test]
+               [ExpectedException (typeof (NullReferenceException))]
+               public void GetObjectData_Null ()
+               {
+                       X509Certificate x = new X509Certificate ();
+                       ISerializable s = (x as ISerializable);
+                       s.GetObjectData (null, new StreamingContext (StreamingContextStates.All));
+               }
+
+               [Test]
+               public void GetObjectData ()
+               {
+                       X509Certificate x = new X509Certificate (cert1);
+                       ISerializable s = (x as ISerializable);
+                       Assert.IsNotNull (s, "ISerializable");
+                       SerializationInfo info = new SerializationInfo (typeof (X509Certificate), new FormatterConverter ());
+                       s.GetObjectData (info, new StreamingContext (StreamingContextStates.All));
+                       Assert.AreEqual (1, info.MemberCount, "MemberCount");
+                       byte[] raw = (byte[]) info.GetValue ("RawData", typeof (byte[]));
+               }
+
+               [Test]
+               [ExpectedException (typeof (NullReferenceException))]
+               public void Ctor_Serialization_Null ()
+               {
+                       new X509Certificate (null, new StreamingContext (StreamingContextStates.All));
+               }
+
+               [Test]
+               public void Ctor_Serialization ()
+               {
+                       SerializationInfo info = new SerializationInfo (typeof (X509Certificate), new FormatterConverter ());
+                       info.AddValue ("RawData", cert1);
+                       X509Certificate x = new X509Certificate (info, new StreamingContext (StreamingContextStates.All));
+                       Assert.AreEqual (cert1, x.GetRawCertData (), "GetRawCertData");
+                       // decoding is done too
+                       Assert.AreEqual ("02720006E8", x.GetSerialNumberString (), "SerialNumber");
+               }
+
+
+               [Test]
+               public void Properties ()
+               {
+                       X509Certificate x = new X509Certificate (cert1);
+                       Assert.AreEqual ("OU=Secure Server Certification Authority, O=\"RSA Data Security, Inc.\", C=US", x.Issuer, "Issuer");
+                       Assert.AreEqual ("OU=Server Certification Authority, O=CommerceNet, S=California, C=US", x.Subject, "Subject");
+               }
+
+               [Test]
+               public void Reset ()
+               {
+                       X509Certificate x = new X509Certificate (cert1);
+                       Assert.AreEqual ("02720006E8", x.GetSerialNumberString (), "GetSerialNumberString");
+                       x.Reset ();
+                       Assert.AreEqual ("X509", x.GetFormat (), "GetFormat");
+                       Assert.AreEqual (0, x.GetHashCode (), "GetHashCode");
+                       Assert.AreEqual (IntPtr.Zero, x.Handle, "Handle");
+                       Assert.AreEqual ("System.Security.Cryptography.X509Certificates.X509Certificate", x.ToString (true), "ToString(true)");
+                       Assert.AreEqual ("System.Security.Cryptography.X509Certificates.X509Certificate", x.ToString (false), "ToString(false)");
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Reset_Issuer ()
+               {
+                       X509Certificate x = new X509Certificate (cert1);
+                       x.Reset ();
+                       Assert.IsNotNull (x.Issuer, "Issuer");
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Reset_Subject ()
+               {
+                       X509Certificate x = new X509Certificate (cert1);
+                       x.Reset ();
+                       Assert.IsNotNull (x.Subject, "Subject");
+               }
+
+               private void CheckPkcs12 (X509Certificate x)
+               {
+                       byte[] cert = { 0x30, 0x82, 0x02, 0x1E, 0x30, 0x82, 0x01, 0x8B, 0xA0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x10, 0x74, 0x8B, 0xCD, 0xD9, 0x86, 0x99, 0x9A, 0x91, 0x4A, 0x0C, 0xC3, 0xF4, 0xE1, 0x2F, 0xF5, 0x95, 0x30, 0x09, 
+                               0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x30, 0x23, 0x31, 0x21, 0x30, 0x1F, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x18, 0x4D, 0x6F, 0x6E, 0x6F, 0x20, 0x53, 0x53, 0x4C, 0x20, 0x49, 0x6E, 0x74, 
+                               0x65, 0x72, 0x6D, 0x65, 0x64, 0x69, 0x61, 0x74, 0x65, 0x20, 0x43, 0x41, 0x30, 0x1E, 0x17, 0x0D, 0x30, 0x33, 0x31, 0x31, 0x32, 0x37, 0x30, 0x32, 0x35, 0x37, 0x34, 0x32, 0x5A, 0x17, 0x0D, 0x33, 0x39, 0x31, 
+                               0x32, 0x33, 0x31, 0x32, 0x33, 0x35, 0x39, 0x35, 0x39, 0x5A, 0x30, 0x13, 0x31, 0x11, 0x30, 0x0F, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x08, 0x46, 0x41, 0x52, 0x53, 0x43, 0x41, 0x50, 0x45, 0x30, 0x81, 0x9F, 
+                               0x30, 0x0D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x01, 0x05, 0x00, 0x03, 0x81, 0x8D, 0x00, 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xC4, 0x26, 0x3B, 0xE9, 0x49, 0x07, 0x39, 0x8C, 
+                               0x51, 0x34, 0x3B, 0x84, 0x4C, 0x27, 0x98, 0x70, 0x15, 0x79, 0xF1, 0xF4, 0x2A, 0x32, 0x82, 0xC3, 0xFA, 0xCF, 0x6E, 0x72, 0x37, 0xCE, 0x37, 0x55, 0x1F, 0xFA, 0x8F, 0x78, 0x4A, 0xA0, 0x0C, 0x9D, 0x44, 0x29, 
+                               0xF2, 0x81, 0xD9, 0x87, 0xD5, 0x94, 0x1A, 0xFC, 0x8D, 0xF8, 0x9D, 0xE0, 0xC5, 0xD2, 0x4A, 0x4F, 0x68, 0xD3, 0xAD, 0x65, 0x23, 0xB2, 0x4F, 0x48, 0x35, 0xB9, 0xFE, 0xE1, 0xDB, 0x6B, 0xE7, 0x41, 0x76, 0xEC, 
+                               0x0C, 0x5B, 0x3A, 0xE3, 0x07, 0xC9, 0x3D, 0x94, 0x48, 0xF2, 0xCF, 0x71, 0xAC, 0x2F, 0x71, 0x60, 0x15, 0x0E, 0xD5, 0x9A, 0xF8, 0x6C, 0x7F, 0xE9, 0xC0, 0x19, 0x18, 0x72, 0x09, 0xA1, 0xD6, 0xB8, 0xA9, 0x60, 
+                               0xD1, 0xC3, 0x18, 0x91, 0x98, 0xCE, 0x9A, 0x44, 0x3D, 0xCF, 0x63, 0x79, 0x41, 0x27, 0x18, 0xB3, 0x8E, 0x05, 0x02, 0x03, 0x01, 0x00, 0x01, 0xA3, 0x6B, 0x30, 0x69, 0x30, 0x13, 0x06, 0x03, 0x55, 0x1D, 0x25, 
+                               0x04, 0x0C, 0x30, 0x0A, 0x06, 0x08, 0x2B, 0x06, 0x01, 0x05, 0x05, 0x07, 0x03, 0x01, 0x30, 0x52, 0x06, 0x03, 0x55, 0x1D, 0x01, 0x04, 0x4B, 0x30, 0x49, 0x80, 0x10, 0x7C, 0x13, 0x05, 0xC9, 0xB9, 0x5A, 0xA3, 
+                               0x19, 0x3E, 0x7C, 0x0D, 0x7C, 0xE3, 0xF2, 0xD3, 0x36, 0xA1, 0x23, 0x30, 0x21, 0x31, 0x1F, 0x30, 0x1D, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x16, 0x4D, 0x6F, 0x6E, 0x6F, 0x20, 0x55, 0x6E, 0x69, 0x74, 0x20, 
+                               0x54, 0x65, 0x73, 0x74, 0x20, 0x52, 0x6F, 0x6F, 0x74, 0x20, 0x43, 0x41, 0x82, 0x10, 0x1B, 0xFC, 0x61, 0x41, 0xD0, 0xCF, 0x41, 0xB9, 0x47, 0xEF, 0x21, 0x7D, 0x6A, 0x53, 0x32, 0x76, 0x30, 0x09, 0x06, 0x05, 
+                               0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x03, 0x81, 0x81, 0x00, 0x94, 0xF8, 0xDA, 0xEF, 0x93, 0x6A, 0x23, 0x04, 0x6B, 0x2D, 0xC3, 0x1E, 0x57, 0xC9, 0x7E, 0xE1, 0xF6, 0x6C, 0x55, 0xB6, 0xAC, 0xAB, 0xA8, 
+                               0x67, 0x19, 0xCD, 0x1D, 0x32, 0x1C, 0xD7, 0x63, 0x13, 0x4F, 0x41, 0x85, 0xB0, 0x62, 0xB8, 0x04, 0x38, 0xD0, 0xD8, 0x18, 0x36, 0x80, 0xE2, 0x70, 0xE7, 0x11, 0x05, 0x7A, 0x2D, 0x5D, 0xC8, 0xAD, 0x29, 0x2E, 
+                               0x05, 0x54, 0x66, 0xE2, 0x8E, 0xCC, 0xDA, 0xEE, 0x19, 0x10, 0xB9, 0x37, 0x30, 0x83, 0x62, 0x9A, 0x10, 0xDB, 0x19, 0x41, 0x57, 0x37, 0x1A, 0x39, 0x54, 0x59, 0xE6, 0x6D, 0xDF, 0x1B, 0xCE, 0x6E, 0x78, 0x6A, 
+                               0x5F, 0x06, 0x26, 0x8D, 0xE0, 0x94, 0x52, 0xF4, 0x86, 0x9C, 0x42, 0x58, 0xF0, 0xEB, 0x71, 0xEB, 0xB8, 0x8E, 0xC9, 0x20, 0x84, 0xD5, 0x11, 0x58, 0x40, 0x4A, 0xE9, 0xD1, 0x8E, 0x2F, 0x9D, 0xD9, 0x8B, 0xD0, 
+                               0x55, 0xB8, 0x96 };
+                       Assert.AreEqual ("CN=Mono SSL Intermediate CA", x.Issuer, "Issuer");
+                       Assert.AreEqual ("CN=Mono SSL Intermediate CA", x.GetIssuerName (), "GetIssuerName");
+                       Assert.AreEqual ("CN=FARSCAPE", x.Subject, "Subject");
+                       Assert.AreEqual ("CN=FARSCAPE", x.GetName (), "GetName");
+                       byte[] hash = { 0x30, 0x29, 0x69, 0x4B, 0x22, 0xB2, 0xEE, 0x6A, 0xEC, 0x9B, 0x78, 0x44, 0x9E, 0x51, 0x0F, 0x7C, 0x34, 0x8D, 0xBA, 0x33 };
+                       Assert.AreEqual (hash, x.GetCertHash (), "GetCertHash");
+                       Assert.AreEqual ("3029694B22B2EE6AEC9B78449E510F7C348DBA33", x.GetCertHashString (), "GetCertHashString");
+                       long from = DateTime.Parse (x.GetEffectiveDateString ()).ToUniversalTime ().Ticks;
+                       Assert.AreEqual (632054986620000000, from, "GetEffectiveDateString");
+                       long until = DateTime.Parse (x.GetExpirationDateString ()).ToUniversalTime ().Ticks;
+                       Assert.AreEqual (643445855990000000, until, "GetExpirationDateString");
+                       Assert.AreEqual ("X509", x.GetFormat (), "GetFormat");
+                       Assert.AreEqual (808020299, x.GetHashCode (), "GetHashCode");
+                       Assert.AreEqual ("1.2.840.113549.1.1.1", x.GetKeyAlgorithm (), "GetKeyAlgorithm");
+                       byte[] keyparams = { 0x05,0x00 };
+                       Assert.AreEqual (keyparams, x.GetKeyAlgorithmParameters (), "GetKeyAlgorithmParameters");
+                       Assert.AreEqual ("0500", x.GetKeyAlgorithmParametersString (), "GetKeyAlgorithmParametersString");
+                       byte[] pubkey = { 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xC4, 0x26, 0x3B, 0xE9, 0x49, 0x07, 0x39, 0x8C, 0x51, 0x34, 0x3B, 0x84, 0x4C, 0x27, 0x98, 0x70, 0x15, 0x79, 0xF1, 0xF4, 0x2A, 0x32, 0x82, 0xC3, 0xFA, 0xCF, 0x6E, 0x72, 0x37, 0xCE, 0x37, 0x55, 0x1F, 0xFA, 0x8F, 0x78, 0x4A, 0xA0, 0x0C, 0x9D, 0x44, 0x29, 0xF2, 0x81, 0xD9, 0x87, 0xD5, 0x94, 
+                               0x1A, 0xFC, 0x8D, 0xF8, 0x9D, 0xE0, 0xC5, 0xD2, 0x4A, 0x4F, 0x68, 0xD3, 0xAD, 0x65, 0x23, 0xB2, 0x4F, 0x48, 0x35, 0xB9, 0xFE, 0xE1, 0xDB, 0x6B, 0xE7, 0x41, 0x76, 0xEC, 0x0C, 0x5B, 0x3A, 0xE3, 0x07, 0xC9, 0x3D, 0x94, 0x48, 0xF2, 0xCF, 0x71, 0xAC, 0x2F, 0x71, 0x60, 0x15, 0x0E, 0xD5, 0x9A, 0xF8, 0x6C, 0x7F, 0xE9, 0xC0, 0x19, 0x18, 0x72, 
+                               0x09, 0xA1, 0xD6, 0xB8, 0xA9, 0x60, 0xD1, 0xC3, 0x18, 0x91, 0x98, 0xCE, 0x9A, 0x44, 0x3D, 0xCF, 0x63, 0x79, 0x41, 0x27, 0x18, 0xB3, 0x8E, 0x05, 0x02, 0x03, 0x01, 0x00, 0x01 };
+                       Assert.AreEqual (pubkey, x.GetPublicKey (), "GetPublicKey");
+                       Assert.AreEqual ("30818902818100C4263BE94907398C51343B844C2798701579F1F42A3282C3FACF6E7237CE37551FFA8F784AA00C9D4429F281D987D5941AFC8DF89DE0C5D24A4F68D3AD6523B24F4835B9FEE1DB6BE74176EC0C5B3AE307C93D9448F2CF71AC2F7160150ED59AF86C7FE9C019187209A1D6B8A960D1C3189198CE9A443DCF6379412718B38E050203010001", x.GetPublicKeyString (), "GetPublicKeyString");
+                       Assert.AreEqual (cert, x.GetRawCertData (), "GetRawCertData");
+                       byte[] serial = { 0x95, 0xF5, 0x2F, 0xE1, 0xF4, 0xC3, 0x0C, 0x4A, 0x91, 0x9A, 0x99, 0x86, 0xD9, 0xCD, 0x8B, 0x74 };
+                       Assert.AreEqual (serial, x.GetSerialNumber (), "GetSerialNumber");
+                       Assert.AreEqual ("748BCDD986999A914A0CC3F4E12FF595", x.GetSerialNumberString (), "GetSerialNumberString");
+               }
+
+               [Test]
+               public void Pkcs12_1_Properties ()
+               {
+                       CheckPkcs12 (new X509Certificate (farscape_pfx, "farscape"));
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Pkcs12_1_WithoutPassword ()
+               {
+                       new X509Certificate (farscape_pfx);
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Pkcs12_1_BadPassword ()
+               {
+                       new X509Certificate (farscape_pfx, "b4d p4zzw0rd");
+               }
+
+               [Test]
+               public void Pkcs12_2_Properties ()
+               {
+                       CheckPkcs12 (new X509Certificate (farscape_nopwd_pfx));
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Pkcs12_2_WithUnrequiredPassword ()
+               {
+                       new X509Certificate (farscape_nopwd_pfx, "n0t n33d3d");
+               }
+
+               [Test]
+               public void Pkcs12_3_Properties ()
+               {
+                       CheckPkcs12 (new X509Certificate (farscape_path_pfx, "farscape"));
+               }
+
+               [Test]
+               public void Pkcs12_4_Properties ()
+               {
+                       CheckPkcs12 (new X509Certificate (farscape_strong_pfx, "farscape"));
+               }
+
+               [Test]
+               public void Pkcs12_5_Properties ()
+               {
+                       CheckPkcs12 (new X509Certificate (farscape_strong_path_pfx, "farscape"));
+               }
+
+               private void CheckBase64 (X509Certificate x)
+               {
+                       // note: the raw data is still the DER encoded ASN.1 (not the base64 string)
+                       byte[] cert = { 0x30, 0x82, 0x01, 0xC5, 0x30, 0x82, 0x01, 0x32, 0xA0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x10, 0xC7, 0x75, 0xAE, 0x48, 0x53, 0x9B, 0x1E, 0x9E, 0x44, 0x80, 0x15, 0xCA, 0x78, 0x15, 0x47, 0x69, 0x30, 0x09, 
+                               0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x30, 0x25, 0x31, 0x23, 0x30, 0x21, 0x06, 0x03, 0x55, 0x04, 0x03, 0x1E, 0x1A, 0x00, 0x43, 0x00, 0x41, 0x00, 0x53, 0x00, 0x54, 0x00, 0x4F, 0x00, 0x52, 
+                               0x00, 0x5C, 0x00, 0x70, 0x00, 0x6F, 0x00, 0x75, 0x00, 0x70, 0x00, 0x6F, 0x00, 0x75, 0x30, 0x1E, 0x17, 0x0D, 0x30, 0x35, 0x30, 0x36, 0x30, 0x38, 0x31, 0x33, 0x33, 0x38, 0x34, 0x37, 0x5A, 0x17, 0x0D, 0x30, 
+                               0x36, 0x30, 0x36, 0x30, 0x38, 0x31, 0x39, 0x33, 0x38, 0x34, 0x37, 0x5A, 0x30, 0x25, 0x31, 0x23, 0x30, 0x21, 0x06, 0x03, 0x55, 0x04, 0x03, 0x1E, 0x1A, 0x00, 0x43, 0x00, 0x41, 0x00, 0x53, 0x00, 0x54, 0x00, 
+                               0x4F, 0x00, 0x52, 0x00, 0x5C, 0x00, 0x70, 0x00, 0x6F, 0x00, 0x75, 0x00, 0x70, 0x00, 0x6F, 0x00, 0x75, 0x30, 0x81, 0x9F, 0x30, 0x0D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x01, 0x05, 
+                               0x00, 0x03, 0x81, 0x8D, 0x00, 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xDA, 0xEA, 0x39, 0x38, 0xF6, 0x3A, 0xF4, 0x8B, 0xF9, 0xE2, 0xC7, 0xD5, 0x2C, 0xF9, 0x1A, 0xD5, 0x75, 0xCF, 0x17, 0xAC, 0xB3, 0x46, 
+                               0xBD, 0x7F, 0x3F, 0x97, 0x38, 0x2E, 0x10, 0x41, 0xB2, 0xC4, 0xD9, 0x14, 0x15, 0xD8, 0xE6, 0xF9, 0x11, 0x38, 0x80, 0x75, 0xE3, 0xD7, 0x1F, 0xC0, 0x86, 0xA7, 0x3E, 0x02, 0x11, 0x04, 0xE9, 0x57, 0xB5, 0xD8, 
+                               0x57, 0x65, 0x27, 0x7B, 0x8F, 0xBA, 0xB9, 0xEF, 0xA0, 0x8F, 0x15, 0x9C, 0xEC, 0x2F, 0x85, 0x63, 0x4E, 0x52, 0x6B, 0xA6, 0xE3, 0x33, 0xCA, 0x86, 0x22, 0xBA, 0xF9, 0x06, 0xE8, 0xEC, 0xCB, 0xA7, 0xA5, 0xA8, 
+                               0xE2, 0x3E, 0xC7, 0x21, 0x74, 0x4E, 0xC9, 0xE9, 0x05, 0x5F, 0xAE, 0x78, 0x12, 0x51, 0x2F, 0xFA, 0x6A, 0x8F, 0x7C, 0xB0, 0x64, 0x2A, 0xFB, 0xB7, 0xB2, 0x40, 0x91, 0x20, 0xE7, 0x32, 0x53, 0x3F, 0x58, 0xCA, 
+                               0x80, 0xA2, 0x41, 0xC5, 0x02, 0x03, 0x01, 0x00, 0x01, 0x30, 0x09, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x03, 0x81, 0x81, 0x00, 0x9D, 0x57, 0xB0, 0x25, 0x97, 0x81, 0x22, 0x3C, 0xC4, 0x61, 
+                               0x9D, 0xC9, 0xDB, 0xD8, 0xC7, 0xC1, 0xED, 0xFB, 0x1C, 0xDD, 0x35, 0x98, 0xD7, 0x40, 0x58, 0xA4, 0x43, 0x86, 0x54, 0xF9, 0x68, 0x96, 0x85, 0xB5, 0x91, 0xBC, 0xB7, 0x82, 0xB2, 0x7E, 0x7B, 0x58, 0xBD, 0x80, 
+                               0xCE, 0x34, 0x7E, 0x22, 0x87, 0x62, 0x31, 0xB5, 0x03, 0x16, 0xA0, 0x20, 0x17, 0x9D, 0xE7, 0x5D, 0xAA, 0x12, 0xF5, 0x92, 0xDF, 0x94, 0xE6, 0x69, 0xCD, 0xF6, 0xFC, 0x82, 0x9B, 0xDC, 0xD3, 0x30, 0x40, 0xB1, 
+                               0x71, 0x4F, 0x4A, 0x64, 0xCB, 0xDC, 0x14, 0xC8, 0xC1, 0x7F, 0x6F, 0x23, 0xCE, 0xDD, 0x19, 0x22, 0x4F, 0x24, 0x1E, 0x27, 0x18, 0x66, 0x88, 0x7A, 0x9A, 0x9A, 0x09, 0x37, 0x6D, 0x65, 0x15, 0xE8, 0x28, 0x5E, 
+                               0x82, 0xEB, 0x5B, 0x82, 0xE8, 0x8A, 0xAC, 0x8F, 0xC3, 0x6C, 0xEE, 0xF0, 0x3E, 0x20, 0xCB, 0xC7 };
+                       Assert.AreEqual ("CN=CASTOR\\poupou", x.Issuer, "Issuer");
+                       Assert.AreEqual ("CN=CASTOR\\poupou", x.GetIssuerName (), "GetIssuerName");
+                       Assert.AreEqual ("CN=CASTOR\\poupou", x.Subject, "Subject");
+                       Assert.AreEqual ("CN=CASTOR\\poupou", x.GetName (), "GetName");
+                       byte[] hash = { 0x1D, 0x53, 0xCC, 0x89, 0xD0, 0x9F, 0x11, 0x4A, 0x48, 0x7F, 0x7F, 0x52, 0x9E, 0xCB, 0xD1, 0x86, 0xA3, 0xD5, 0x85, 0x29 };
+                       Assert.AreEqual (hash, x.GetCertHash (), "GetCertHash");
+                       Assert.AreEqual ("1D53CC89D09F114A487F7F529ECBD186A3D58529", x.GetCertHashString (), "GetCertHashString");
+                       long from = DateTime.Parse (x.GetEffectiveDateString ()).ToUniversalTime ().Ticks;
+                       Assert.AreEqual (632538347270000000, from, "GetEffectiveDateString");
+                       long until = DateTime.Parse (x.GetExpirationDateString ()).ToUniversalTime ().Ticks;
+                       Assert.AreEqual (632853923270000000, until, "GetExpirationDateString");
+                       Assert.AreEqual ("X509", x.GetFormat (), "GetFormat");
+                       Assert.AreEqual (492031113, x.GetHashCode (), "GetHashCode");
+                       Assert.AreEqual ("1.2.840.113549.1.1.1", x.GetKeyAlgorithm (), "GetKeyAlgorithm");
+                       byte[] keyparams = { 0x05, 0x00 };
+                       Assert.AreEqual (keyparams, x.GetKeyAlgorithmParameters (), "GetKeyAlgorithmParameters");
+                       Assert.AreEqual ("0500", x.GetKeyAlgorithmParametersString (), "GetKeyAlgorithmParametersString");
+                       byte[] pubkey = { 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xDA, 0xEA, 0x39, 0x38, 0xF6, 0x3A, 0xF4, 0x8B, 0xF9, 0xE2, 0xC7, 0xD5, 0x2C, 0xF9, 0x1A, 0xD5, 0x75, 0xCF, 0x17, 0xAC, 0xB3, 0x46, 0xBD, 0x7F, 0x3F, 0x97, 0x38, 0x2E, 0x10, 0x41, 0xB2, 0xC4, 0xD9, 0x14, 0x15, 0xD8, 0xE6, 0xF9, 0x11, 0x38, 0x80, 0x75, 0xE3, 0xD7, 0x1F, 0xC0, 0x86, 
+                               0xA7, 0x3E, 0x02, 0x11, 0x04, 0xE9, 0x57, 0xB5, 0xD8, 0x57, 0x65, 0x27, 0x7B, 0x8F, 0xBA, 0xB9, 0xEF, 0xA0, 0x8F, 0x15, 0x9C, 0xEC, 0x2F, 0x85, 0x63, 0x4E, 0x52, 0x6B, 0xA6, 0xE3, 0x33, 0xCA, 0x86, 0x22, 0xBA, 0xF9, 0x06, 0xE8, 0xEC, 0xCB, 0xA7, 0xA5, 0xA8, 0xE2, 0x3E, 0xC7, 0x21, 0x74, 0x4E, 0xC9, 0xE9, 0x05, 0x5F, 0xAE, 0x78, 0x12, 
+                               0x51, 0x2F, 0xFA, 0x6A, 0x8F, 0x7C, 0xB0, 0x64, 0x2A, 0xFB, 0xB7, 0xB2, 0x40, 0x91, 0x20, 0xE7, 0x32, 0x53, 0x3F, 0x58, 0xCA, 0x80, 0xA2, 0x41, 0xC5, 0x02, 0x03, 0x01, 0x00, 0x01 };
+                       Assert.AreEqual (pubkey, x.GetPublicKey (), "GetPublicKey");
+                       Assert.AreEqual ("30818902818100DAEA3938F63AF48BF9E2C7D52CF91AD575CF17ACB346BD7F3F97382E1041B2C4D91415D8E6F911388075E3D71FC086A73E021104E957B5D85765277B8FBAB9EFA08F159CEC2F85634E526BA6E333CA8622BAF906E8ECCBA7A5A8E23EC721744EC9E9055FAE7812512FFA6A8F7CB0642AFBB7B2409120E732533F58CA80A241C50203010001", x.GetPublicKeyString (), "GetPublicKeyString");
+                       Assert.AreEqual (cert, x.GetRawCertData (), "GetRawCertData");
+                       byte[] serial = { 0x69, 0x47, 0x15, 0x78, 0xCA, 0x15, 0x80, 0x44, 0x9E, 0x1E, 0x9B, 0x53, 0x48, 0xAE, 0x75, 0xC7 };
+                       Assert.AreEqual (serial, x.GetSerialNumber (), "GetSerialNumber");
+                       Assert.AreEqual ("C775AE48539B1E9E448015CA78154769", x.GetSerialNumberString (), "GetSerialNumberString");
+               }
+
+               [Test]
+               public void Base64_AsByteArray_Properties ()
+               {
+                       // note: the X509Certificate(string) ctor is used for a filename
+                       byte[] raw = Encoding.ASCII.GetBytes (base64_cert);
+                       CheckBase64 (new X509Certificate (raw));
+               }
+
+               [Test]
+               public void Base64_AsFile_Properties ()
+               {
+                       string temp = Path.GetTempFileName ();
+                       try {
+                               using (StreamWriter sw = new StreamWriter (temp)) {
+                                       sw.Write (base64_cert);
+                               }
+                               CheckBase64 (new X509Certificate (temp));
+                       }
+                       finally {
+                               if (File.Exists (temp))
+                                       File.Delete (temp);
+                       }
+               }
+
+               private bool RunningOnWindows ()
+               {
+                       int i = (int) Environment.OSVersion.Platform;
+                       return ((i != 4) && (i != 128));
+               }
+
+               [Test]
+               public void Base64_AsStringData ()
+               {
+                       try {
+                               new X509Certificate (base64_cert);
+                               Assert.Fail ("Expected ArgumentException(Windows) or PathTooLongException(Linux)");
+                       }
+                       catch (ArgumentException) {
+                               // path is invalid on Windows
+                               if (!RunningOnWindows ())
+                                       throw;
+                       }
+                       catch (PathTooLongException) {
+                               // path is too long on Linux
+                               if (RunningOnWindows ())
+                                       throw;
+                       }
+                   catch (DirectoryNotFoundException) {
+                       }
+                       catch (Exception e) {
+                               Assert.Fail (e.ToString ());
+                       }
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Pkcs7_Ctor ()
+               {
+                       new X509Certificate (farscape_pkcs7);
+               }
+
+               [Test]
+               [ExpectedException (typeof (CryptographicException))]
+               public void Pkcs7_Import ()
+               {
+                       X509Certificate x = new X509Certificate ();
+                       x.Import (farscape_pkcs7);
+               }
+       }
+}
+
+#endif
index db1e3953f50be3c2729c034d04163f55ad3582eb..3c0c66dd5d7eefc306bc942a7a184b3e9e75c53f 100644 (file)
@@ -1472,8 +1472,13 @@ namespace MonoTests.System
                        for (int i = 0; i < 128; i++)
                                sb.Append ((char) i);
 
-                       Assert.AreEqual ("%00%01%02%03%04%05%06%07%08%09%0A%0B%0C%0D%0E%0F%10%11%12%13%14%15%16%17%18%19%1A%1B%1C%1D%1E%1F%20!%22%23%24%25%26'()*%2B%2C-.%2F0123456789%3A%3B%3C%3D%3E%3F%40ABCDEFGHIJKLMNOPQRSTUVWXYZ%5B%5C%5D%5E_%60abcdefghijklmnopqrstuvwxyz%7B%7C%7D~%7F",
-                                     Uri.EscapeDataString (sb.ToString ()));
+                       Assert.AreEqual (
+#if NET_4_0
+                               "%00%01%02%03%04%05%06%07%08%09%0A%0B%0C%0D%0E%0F%10%11%12%13%14%15%16%17%18%19%1A%1B%1C%1D%1E%1F%20%21%22%23%24%25%26%27%28%29%2A%2B%2C-.%2F0123456789%3A%3B%3C%3D%3E%3F%40ABCDEFGHIJKLMNOPQRSTUVWXYZ%5B%5C%5D%5E_%60abcdefghijklmnopqrstuvwxyz%7B%7C%7D~%7F",
+#else
+                               "%00%01%02%03%04%05%06%07%08%09%0A%0B%0C%0D%0E%0F%10%11%12%13%14%15%16%17%18%19%1A%1B%1C%1D%1E%1F%20!%22%23%24%25%26'()*%2B%2C-.%2F0123456789%3A%3B%3C%3D%3E%3F%40ABCDEFGHIJKLMNOPQRSTUVWXYZ%5B%5C%5D%5E_%60abcdefghijklmnopqrstuvwxyz%7B%7C%7D~%7F",
+#endif
+                                Uri.EscapeDataString (sb.ToString ()));
 
                        Assert.AreEqual ("%C3%A1", Uri.EscapeDataString ("á"));
                }
@@ -1484,8 +1489,14 @@ namespace MonoTests.System
                        for (int i = 0; i < 128; i++)
                                sb.Append ((char) i);
 
-                       Assert.AreEqual ("%00%01%02%03%04%05%06%07%08%09%0A%0B%0C%0D%0E%0F%10%11%12%13%14%15%16%17%18%19%1A%1B%1C%1D%1E%1F%20!%22#$%25&'()*+,-./0123456789:;%3C=%3E?@ABCDEFGHIJKLMNOPQRSTUVWXYZ%5B%5C%5D%5E_%60abcdefghijklmnopqrstuvwxyz%7B%7C%7D~%7F",
+                       Assert.AreEqual (
+#if NET_4_0
+                               "%00%01%02%03%04%05%06%07%08%09%0A%0B%0C%0D%0E%0F%10%11%12%13%14%15%16%17%18%19%1A%1B%1C%1D%1E%1F%20!%22#$%25&'()*+,-./0123456789:;%3C=%3E?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[%5C]%5E_%60abcdefghijklmnopqrstuvwxyz%7B%7C%7D~%7F",
+#else
+                               "%00%01%02%03%04%05%06%07%08%09%0A%0B%0C%0D%0E%0F%10%11%12%13%14%15%16%17%18%19%1A%1B%1C%1D%1E%1F%20!%22#$%25&'()*+,-./0123456789:;%3C=%3E?@ABCDEFGHIJKLMNOPQRSTUVWXYZ%5B%5C%5D%5E_%60abcdefghijklmnopqrstuvwxyz%7B%7C%7D~%7F",
+#endif
                                Uri.EscapeUriString (sb.ToString ()));
+
                        Assert.AreEqual ("%C3%A1", Uri.EscapeDataString ("á"));
                }
 
index 6656ee67febaf08d209718fd97832722eda3c52c..e02746a1c3000cefb650f525519f11b50e801554 100644 (file)
@@ -191,7 +191,8 @@ System.ComponentModel/WeakObjectWrapperComparer.cs
 System.ComponentModel/Win32Exception.cs
 System.Diagnostics/DataReceivedEventArgs.cs
 System.Diagnostics/DataReceivedEventHandler.cs
-System.Diagnostics/Debug_2_1.cs
+System.Diagnostics/Debug.cs
+System.Diagnostics/DefaultTraceListener.cs
 System.Diagnostics/FileVersionInfo.cs
 System.Diagnostics/MonitoringDescriptionAttribute.cs
 System.Diagnostics/Process.cs
@@ -203,6 +204,10 @@ System.Diagnostics/ProcessThread.cs
 System.Diagnostics/ProcessThreadCollection.cs
 System.Diagnostics/ProcessWindowStyle.cs
 System.Diagnostics/Stopwatch.cs
+System.Diagnostics/TraceImpl.cs
+System.Diagnostics/TraceListener.cs
+System.Diagnostics/TraceListenerCollection.cs
+System.Diagnostics/TraceOptions.cs
 System.Diagnostics/ThreadPriorityLevel.cs
 System.Diagnostics/ThreadState.cs
 System.Diagnostics/ThreadWaitReason.cs
@@ -398,6 +403,7 @@ System.Net/IWebProxyScript.cs
 System.Net/IWebRequestCreate.cs
 System.Net/ListenerAsyncResult.cs
 System.Net/ListenerPrefix.cs
+System.Net/MacProxy.cs
 System.Net/MonoHttpDate.cs
 System.Net/NetConfig.cs
 System.Net/NetworkAccess.cs
@@ -544,3 +550,4 @@ System/UriKind.cs
 System/UriParser.cs
 System/UriPartial.cs
 System/UriTypeConverter.cs
+System.Windows.Input/ICommand.cs
\ No newline at end of file
index 4c01d19bc1b44a506be107b2d29b9688bdff33fd..03432265872de0049e648320b268daf31c0638ca 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 61fe56faeb32fd0fb33707a6e768c53384c84dad..8e8eaf5adb8c460ff65788153aa23374fe637642 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 2bf619ed7a1b16a3a1f4e7974d597f9995359103..8304808ba7a50cedefb448be4dec2bca84b94863 100644 (file)
@@ -58,7 +58,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 1bca6fb491c9b5f53d955da6c51b74ecfe9f1402..30411d736ae49f50482ff735826297c9de35d7ab 100644 (file)
@@ -6,5 +6,5 @@ LIBRARY = WebMatrix.Data.dll
 
 include ../../build/library.make
 
-LIB_MCS_FLAGS += -r:$(corlib) -r:System.dll -r:System.Data.dll -r:System.Core.dll -r:System.Configuration.dll
-TEST_MCS_FLAGS += -r:System.dll -r:System.Data.dll -r:Mono.Data.Sqlite.dll
+LIB_MCS_FLAGS = -r:$(corlib) -r:System.dll -r:System.Data.dll -r:System.Core.dll -r:System.Configuration.dll
+TEST_MCS_FLAGS = -r:System.dll -r:System.Core.dll -r:System.Data.dll -r:Mono.Data.Sqlite.dll -r:Microsoft.CSharp.dll
index 2be165db6bb0f91440ee8069691ac28f6ee6ac18..c2b3f46b9e3527a5f70ff7ab838c11e67bac93a1 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 6cff13c3365d6e006ea86d88bd41f4658c82dec2..4f2d030de945e3bbfc8c013f2e1b7d8ffaea3158 100644 (file)
@@ -57,7 +57,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index f165a048d9edb4e1082a42def615769b2933eba6..c0d053dd34fcf7761a34443cdbe606ca6f62c09d 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 5c76c4dcddfc0b34a5b87004a1bfebea5a6b4bd0..22500d3cb525bed6ab34efbf8d10c6289b8c27c0 100644 (file)
@@ -55,7 +55,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
index 804fc21e31b1ab9fe5aaa2e01c1d0339cfa7b8da..a358cdd078bd4a4263ec1d6c365d60470199505e 100644 (file)
@@ -3,8 +3,8 @@ include ../../build/rules.make
 
 LIBRARY = WindowsBase.dll
 
-LIB_MCS_FLAGS = -unsafe -r:System -r:System.Xml
-TEST_MCS_FLAGS = -unsafe -r:WindowsBase.dll
+LIB_MCS_FLAGS = -unsafe -r:System.dll -r:System.Xml.dll
+TEST_MCS_FLAGS = -unsafe -r:WindowsBase.dll -r:System.dll -r:System.Xml.dll -r:System.Core.dll
 
 ifeq (2.0, $(FRAMEWORK_VERSION))
 LIB_MCS_FLAGS += -d:NET_3_0
index 54e675c33c12ba07cf2bb8807a66145ef21872a8..49e314c772bc713c1b6ede74109790a499c3a38d 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
-    <Reference Include="System">
+    <Reference Include="System.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System</HintPath>
+      <HintPath>System.dll</HintPath>
     </Reference>
-    <Reference Include="System.Xml">
+    <Reference Include="System.Xml.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Xml</HintPath>
+      <HintPath>System.Xml.dll</HintPath>
     </Reference>
 \r
   </ItemGroup>\r
index f96fb6186d26ab463068133598e017836ec000e5..8881f55f12c7c99e021ce1f064f1862688533796 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
-    <Reference Include="System">
+    <Reference Include="System.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System</HintPath>
+      <HintPath>System.dll</HintPath>
     </Reference>
-    <Reference Include="System.Xml">
+    <Reference Include="System.Xml.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Xml</HintPath>
+      <HintPath>System.Xml.dll</HintPath>
     </Reference>
     <Reference Include="System.Xaml.dll">
       <SpecificVersion>False</SpecificVersion>
index b30ff5afacd195c4ba3397d46b33745cfa331a66..9dbaafd13eccaa525bbabeb8247aa67b6e2441f7 100644 (file)
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
-    <Reference Include="System">
+    <Reference Include="System.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System</HintPath>
+      <HintPath>System.dll</HintPath>
     </Reference>
-    <Reference Include="System.Xml">
+    <Reference Include="System.Xml.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>System.Xml</HintPath>
+      <HintPath>System.Xml.dll</HintPath>
     </Reference>
     <Reference Include="System.Xaml.dll">
       <SpecificVersion>False</SpecificVersion>
index edc2519b7b016a354d70997576a61bf3c605ea79..b387733633a38ceb3a767987dc9100b3a24b1bc8 100644 (file)
@@ -95,7 +95,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>WindowsBase.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="nunit.framework" />
 \r
   </ItemGroup>\r
index f59a6e93b1f2e825edac5f74575d237c43d453a7..d6eb3f707d8101ded822ce82b433b87e40c3578a 100644 (file)
@@ -95,7 +95,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>WindowsBase.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="System.Xaml.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Xaml.dll</HintPath>
index 9ee92d4e050c02f7d722499864a508391255ae2f..99d2f06d3d678cefb1421f10a790fe7737ae6b6b 100644 (file)
@@ -95,7 +95,7 @@
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="mscorlib.dll">
+    <Reference Include="mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>mscorlib.dll</HintPath>
     </Reference>
       <SpecificVersion>False</SpecificVersion>
       <HintPath>WindowsBase.dll</HintPath>
     </Reference>
+    <Reference Include="System.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Xml.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Xml.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
+    </Reference>
     <Reference Include="System.Xaml.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>System.Xaml.dll</HintPath>
index 147ed2ae5fdb7e1e5654b6a29279e5b0f366b52d..630bb164aaa22160b4ff18a4c89585f82dff9eb8 100644 (file)
@@ -40,10 +40,9 @@ LOCAL_MCS_FLAGS = -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC
 DEFAULT_REFERENCES =
 
 # System.IO/DirectoryInfoTest.cs needs Mono.Posix
-TEST_MCS_FLAGS = -debug+ -debug:full -nowarn:168,219,618,672 -unsafe -r:$(topdir)/class/lib/$(PROFILE)/Mono.Posix.dll -define:MONO_DATACONVERTER_STATIC_METHODS
+TEST_MCS_FLAGS = -debug+ -debug:full -nowarn:168,219,618,672 -unsafe -r:Mono.Posix.dll -r:System.Core.dll -define:MONO_DATACONVERTER_STATIC_METHODS
 
 EXTRA_DISTFILES = \
-       Test/ms_run_test.sh                     \
        Test/resources/MyResources.resources    \
        Test/resources/MyResources.de.resources \
        Test/resources/Empty.resources          \
@@ -90,40 +89,40 @@ $(cmp_makefrag): $(cmp_response)
 $(cmp_response) $(cmp_makefrag): Makefile $(depsdir)/.stamp
 endif
 
-vts = VersionTolerantSerialization
-vtsdir = Test/System.Runtime.Serialization.Formatters.Binary/$(vts)
+vtsdir = Test/System.Runtime.Serialization.Formatters.Binary/VersionTolerantSerialization
 vtslibs = \
-       $(vtsdir)/$(vts)TestLib/1.0/Address.dll \
-       $(vtsdir)/$(vts)TestLib/2.0/Address.dll \
-       $(vtsdir)/$(vts)TestLib/3.0/Address.dll \
-       $(vtsdir)/$(vts)TestLib/4.0/Address.dll \
-       $(vtsdir)/$(vts)TestLib/5.0/Address.dll \
-       $(vtsdir)/$(vts)TestLib/6.0/Address.dll
+       $(vtsdir)/$(PROFILE)_TestLib/1.0/Address.dll \
+       $(vtsdir)/$(PROFILE)_TestLib/2.0/Address.dll \
+       $(vtsdir)/$(PROFILE)_TestLib/3.0/Address.dll \
+       $(vtsdir)/$(PROFILE)_TestLib/4.0/Address.dll \
+       $(vtsdir)/$(PROFILE)_TestLib/5.0/Address.dll \
+       $(vtsdir)/$(PROFILE)_TestLib/6.0/Address.dll
 
-test-vts: $(vtslibs) $(vtsdir)/BinarySerializationOverVersions.exe
+test-vts: $(vtslibs) $(vtsdir)/$(PROFILE)_TestLib/BinarySerializationOverVersions.exe
 
-$(vtsdir)/$(vts)TestLib/%/Address.dll: $(vtsdir)/$(vts)TestLib/%/Address.cs
-       $(Q_MCS) $(MCS) -target:library -warn:0  $^
+$(vtsdir)/$(PROFILE)_TestLib/%/Address.dll: $(vtsdir)/VersionTolerantSerializationTestLib/%/Address.cs
+       @mkdir -p $(dir $@)
+       $(CSCOMPILE) -target:library -r:$(corlib) -warn:0 -out:$@ $^
 
-$(vtsdir)/BinarySerializationOverVersions.exe: $(vtsdir)/BinarySerializationOverVersions.cs $(vtsdir)/$(vts)TestLib/1.0/Address.dll
-       $(Q_MCS) $(MCS) $(test_nunit_ref) -warn:0  \
-               -r:$(vtsdir)/$(vts)TestLib/1.0/Address.dll \
-               $(vtsdir)/BinarySerializationOverVersions.cs
-       @cp $(vtsdir)/$(vts)TestLib/1.0/Address.dll $(vtsdir)
+$(vtsdir)/$(PROFILE)_TestLib/BinarySerializationOverVersions.exe: $(vtsdir)/BinarySerializationOverVersions.cs $(vtsdir)/$(PROFILE)_TestLib/1.0/Address.dll
+       $(CSCOMPILE) $(test_nunit_ref) -warn:0 -r:$(corlib) \
+               -r:$(vtsdir)/$(PROFILE)_TestLib/1.0/Address.dll \
+               $(vtsdir)/BinarySerializationOverVersions.cs -out:$@
+       @cp $(vtsdir)/$(PROFILE)_TestLib/1.0/Address.dll $(vtsdir)/$(PROFILE)_TestLib
 
 # Need to define MONO_PATH to an absolute dir since the test is ran from a subdir
 run-test-vts: test-vts
        @echo Running vts tests...
-       MONO_PATH=$(PWD)/../lib/$(PROFILE) $(TEST_RUNTIME) $(RUNTIME_FLAGS) $(TEST_HARNESS) -noshadow \
-               $(vtsdir)/BinarySerializationOverVersions.exe 
+       PATH="$(TEST_RUNTIME_WRAPPERS_PATH):$(PATH)" $(TEST_RUNTIME) $(RUNTIME_FLAGS) $(TEST_HARNESS) -noshadow \
+               $(vtsdir)/$(PROFILE)_TestLib/BinarySerializationOverVersions.exe
 test: test-vts
 run-test: run-test-vts
 
 EXTRA_DISTFILES += \
-       $(vtsdir)/$(vts)TestLib/1.0/Address.cs \
-       $(vtsdir)/$(vts)TestLib/2.0/Address.cs \
-       $(vtsdir)/$(vts)TestLib/3.0/Address.cs \
-       $(vtsdir)/$(vts)TestLib/4.0/Address.cs \
-       $(vtsdir)/$(vts)TestLib/5.0/Address.cs \
-       $(vtsdir)/$(vts)TestLib/6.0/Address.cs \
+       $(vtsdir)/VersionTolerantSerializationTestLib/1.0/Address.cs \
+       $(vtsdir)/VersionTolerantSerializationTestLib/2.0/Address.cs \
+       $(vtsdir)/VersionTolerantSerializationTestLib/3.0/Address.cs \
+       $(vtsdir)/VersionTolerantSerializationTestLib/4.0/Address.cs \
+       $(vtsdir)/VersionTolerantSerializationTestLib/5.0/Address.cs \
+       $(vtsdir)/VersionTolerantSerializationTestLib/6.0/Address.cs \
        $(vtsdir)/BinarySerializationOverVersions.cs
index abc9e5822f1d461e2deccdd61782bb8c5f0add9f..05a5ad976163a899fba74011ad5592ee9a6d81b5 100644 (file)
@@ -139,11 +139,22 @@ namespace System.Collections.Concurrent
 
                public int TryPopRange (T[] items)
                {
+                       if (items == null)
+                               throw new ArgumentNullException ("items");
                        return TryPopRange (items, 0, items.Length);
                }
 
                public int TryPopRange (T[] items, int startIndex, int count)
                {
+                       if (items == null)
+                               throw new ArgumentNullException ("items");
+                       if (startIndex < 0 || startIndex >= items.Length)
+                               throw new ArgumentOutOfRangeException ("startIndex");
+                       if (count < 0)
+                               throw new ArgumentOutOfRangeException ("count");
+                       if (startIndex + count > items.Length)
+                               throw new ArgumentException ("startIndex + count is greater than the length of items.");
+
                        Node temp;
                        Node end;
                        
@@ -152,7 +163,7 @@ namespace System.Collections.Concurrent
                                if (temp == null)
                                        return -1;
                                end = temp;
-                               for (int j = 0; j < count - 1; j++) {
+                               for (int j = 0; j < count; j++) {
                                        end = end.Next;
                                        if (end == null)
                                                break;
@@ -160,14 +171,15 @@ namespace System.Collections.Concurrent
                        } while (Interlocked.CompareExchange (ref head, end, temp) != temp);
                        
                        int i;
-                       for (i = startIndex; i < count && temp != null; i++) {
+                       for (i = startIndex; i < startIndex + count && temp != null; i++) {
                                items[i] = temp.Value;
                                end = temp;
                                temp = temp.Next;
                                pool.Release (ZeroOut (end));
                        }
+                       this.count -= (i - startIndex);
                        
-                       return i - 1;
+                       return i - startIndex;
                }
                
                public bool TryPeek (out T result)
index e1ed19f396139a6ac4cc1da2aebb1167f38d3b69..cb894d969f1d37d2f389a79fe4d39dde10254254 100644 (file)
@@ -62,19 +62,21 @@ namespace System.Globalization
                                /* This will build the ICU collator, and store
                                 * the pointer in ICU_collator
                                 */
+                               /*
                                try {
                                        this.construct_compareinfo (icu_name);
                                } catch {
                                //      ICU_collator=IntPtr.Zero;
                                }
+                               */
                        }
                }
 
-               [MethodImplAttribute (MethodImplOptions.InternalCall)]
-               private extern void construct_compareinfo (string locale);
+               //[MethodImplAttribute (MethodImplOptions.InternalCall)]
+               //private extern void construct_compareinfo (string locale);
 
-               [MethodImplAttribute (MethodImplOptions.InternalCall)]
-               private extern void free_internal_collator ();
+               //[MethodImplAttribute (MethodImplOptions.InternalCall)]
+               //private extern void free_internal_collator ();
 
                [MethodImplAttribute (MethodImplOptions.InternalCall)]
                private extern int internal_compare (string str1, int offset1,
@@ -113,15 +115,16 @@ namespace System.Globalization
 
                // Keep in synch with MonoCompareInfo in the runtime. 
                private int culture;
-               [NonSerialized]
-               private string icu_name;
+//             [NonSerialized]
+//             private string icu_name;
 //             [NonSerialized]
 //             private IntPtr ICU_collator;
 
 #pragma warning disable 169            
                private int win32LCID;  // Unused, but MS.NET serializes this
-               private string m_name; // Unused, but MS.NET serializes this
 #pragma warning restore 169
+               
+               readonly string m_name; // MS.NET serializes this
 
                [NonSerialized]
                SimpleCollator collator;
@@ -133,12 +136,10 @@ namespace System.Globalization
                // Protects access to 'collators'
                private static object monitor = new Object ();
                
-               /* Hide the .ctor() */
-               CompareInfo() {}
-               
                internal CompareInfo (CultureInfo ci)
                {
                        this.culture = ci.LCID;
+                       this.m_name = ci.Name;
                        if (UseManagedCollation) {
                                lock (monitor) {
                                        if (collators == null)
@@ -150,20 +151,22 @@ namespace System.Globalization
                                        }
                                }
                        } else {
+/*
 #if !MOONLIGHT
                                this.icu_name = ci.IcuName;
                                this.construct_compareinfo (icu_name);
 #endif
+*/
                        }
                }
-
+/*
                ~CompareInfo ()
                {
 #if !MOONLIGHT
                        free_internal_collator ();
 #endif
                }
-
+*/
 #if !MOONLIGHT
                private int internal_compare_managed (string str1, int offset1,
                                                int length1, string str2,
@@ -853,16 +856,15 @@ namespace System.Globalization
                 * shows it.  Some documentation about what it does
                 * would be nice.
                 */
-               public int LCID
-               {
+               public int LCID {
                        get {
-                               return(culture);
+                               return culture;
                        }
                }
 
                [ComVisible (false)]
                public virtual string Name {
-                       get { return icu_name; }
+                       get { return m_name; }
                }
        }
 }
index 5fd87c1b8212fc04f583dc00731becc64ecd0fe4..fe22469b725631272c2b502c66715ae8a4503661 100644 (file)
@@ -1,14 +1,14 @@
 //
 // System.Globalization.CultureInfo.cs
 //
+// Authors:
 // Miguel de Icaza (miguel@ximian.com)
 // Dick Porter (dick@ximian.com)
+// Marek Safar (marek.safar@gmail.com)
 //
 // (C) 2001, 2002, 2003 Ximian, Inc. (http://www.ximian.com)
-//
-
-//
 // Copyright (C) 2004 Novell, Inc (http://www.novell.com)
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
@@ -46,21 +46,17 @@ namespace System.Globalization
                static object shared_table_lock = new object ();
                internal static int BootstrapCultureID;
 
-               const int NumOptionalCalendars = 5;
-               const int GregorianTypeMask = 0x00FFFFFF;
-               const int CalendarTypeBits = 24;
-
 #pragma warning disable 169, 649
                bool m_isReadOnly;
                int  cultureID;
                [NonSerialized]
                int parent_lcid;
                [NonSerialized]
-               int specific_lcid;
-               [NonSerialized]
                int datetime_index;
                [NonSerialized]
                int number_index;
+               [NonSerialized]
+               int default_calendar_type;
                bool m_useUserOverride;
                [NonSerialized]
                volatile NumberFormatInfo numInfo;
@@ -68,8 +64,6 @@ namespace System.Globalization
                volatile TextInfo textInfo;
                private string m_name;
                
-               [NonSerialized]
-               private string displayname;
                [NonSerialized]
                private string englishname;
                [NonSerialized]
@@ -79,25 +73,24 @@ namespace System.Globalization
                [NonSerialized]
                private string iso2lang;
                [NonSerialized]
-               private string icu_name;
-               [NonSerialized]
                private string win3lang;
                [NonSerialized]
                private string territory;
-               volatile CompareInfo compareInfo;
                [NonSerialized]
-               private unsafe readonly int *calendar_data;
+               string[] native_calendar_names;
+
+               volatile CompareInfo compareInfo;
                [NonSerialized]
                private unsafe readonly void *textinfo_data;
-               [NonSerialized]
-               private Calendar [] optional_calendars;
-               [NonSerialized]
-               CultureInfo parent_culture;
 
                int m_dataItem;         // MS.NET serializes this.
-               Calendar calendar;      // MS.NET serializes this.
 #pragma warning restore 169, 649
 
+               Calendar calendar;
+
+               [NonSerialized]
+               CultureInfo parent_culture;
+
                // Deserialized instances will set this to false
                [NonSerialized]
                bool constructed;
@@ -107,10 +100,11 @@ namespace System.Globalization
                internal byte[] cached_serialized_form;
                
                const int InvariantCultureId = 0x7F;
+               const int CalendarTypeBits = 8;
 
-               private static readonly string MSG_READONLY = "This instance is read only";
+               const string MSG_READONLY = "This instance is read only";
                
-               static public CultureInfo InvariantCulture {
+               public static CultureInfo InvariantCulture {
                        get {
                                return invariant_culture_info;
                        }
@@ -126,7 +120,7 @@ namespace System.Globalization
                                return InvariantCulture;
 
                        CultureInfo ci = new CultureInfo ();
-                       if (!ConstructInternalLocaleFromSpecificName (ci, name.ToLowerInvariant ()))
+                       if (!construct_internal_locale_from_specific_name (ci, name.ToLowerInvariant ()))
                                throw new ArgumentException ("Culture name " + name +
                                                " is not supported.", name);
 
@@ -272,29 +266,35 @@ namespace System.Globalization
                        }
                }
 
-               public virtual string NativeName
-               {
+               public virtual string NativeName {
                        get {
                                if (!constructed) Construct ();
-                               return(nativename);
+                               return nativename;
+                       }
+               }
+
+               internal string NativeCalendarName {
+                       get {
+                               if (!constructed) Construct ();
+                               return native_calendar_names[(default_calendar_type >> CalendarTypeBits) - 1];
                        }
                }
                
-               public virtual Calendar Calendar
-               {
-                       get { return DateTimeFormat.Calendar; }
+               public virtual Calendar Calendar {
+                       get {
+                               if (calendar == null) {
+                                       if (!constructed) Construct ();
+                                       calendar = CreateCalendar (default_calendar_type);
+                               }
+
+                               return calendar;
+                       }
                }
 
-               public virtual Calendar[] OptionalCalendars
-               {
+               [MonoLimitation ("Optional calendars are not supported only default calendar is returned")]
+               public virtual Calendar[] OptionalCalendars {
                        get {
-                               if (optional_calendars == null) {
-                                       lock (this) {
-                                               if (optional_calendars == null)
-                                                       ConstructCalendars ();
-                                       }
-                               }
-                               return optional_calendars;
+                               return new[] { Calendar };
                        }
                }
 
@@ -334,11 +334,10 @@ namespace System.Globalization
                        }
                }
 
-               public virtual string ThreeLetterISOLanguageName
-               {
+               public virtual string ThreeLetterISOLanguageName {
                        get {
                                if (!constructed) Construct ();
-                               return(iso3lang);
+                               return iso3lang;
                        }
                }
 
@@ -350,8 +349,7 @@ namespace System.Globalization
                        }
                }
 
-               public virtual string TwoLetterISOLanguageName
-               {
+               public virtual string TwoLetterISOLanguageName {
                        get {
                                if (!constructed) Construct ();
                                return(iso2lang);
@@ -365,13 +363,6 @@ namespace System.Globalization
                        }
                }
 
-               internal string IcuName {
-                       get {
-                               if (!constructed) Construct ();
-                               return icu_name;
-                       }
-               }
-
                public void ClearCachedData()
                {
                        Thread.CurrentThread.CurrentCulture = null;
@@ -419,9 +410,9 @@ namespace System.Globalization
                }
 #endif
 
-               public override int GetHashCode()
+               public override int GetHashCode ()
                {
-                       return cultureID;
+                       return cultureID.GetHashCode ();
                }
 
                public static CultureInfo ReadOnly(CultureInfo ci)
@@ -439,7 +430,6 @@ namespace System.Globalization
                                        new_ci.numInfo = NumberFormatInfo.ReadOnly (new_ci.numInfo);
                                if (new_ci.dateTimeInfo != null)
                                        new_ci.dateTimeInfo = DateTimeFormatInfo.ReadOnly (new_ci.dateTimeInfo);
-                               // TextInfo doesn't have a ReadOnly method in 1.1...
                                if (new_ci.textInfo != null)
                                        new_ci.textInfo = TextInfo.ReadOnly (new_ci.textInfo);
                                return(new_ci);
@@ -469,22 +459,13 @@ namespace System.Globalization
                        }
                }
 
-               internal static bool IsIDNeutralCulture (int lcid)
-               {
-                       bool ret;
-                       if (!internal_is_lcid_neutral (lcid, out ret))
-                               throw new ArgumentException (String.Format ("Culture id 0x{:x4} is not supported.", lcid));
-                               
-                       return ret;
-               }
-
                public virtual bool IsNeutralCulture {
                        get {
-                               if (!constructed) Construct ();
                                if (cultureID == InvariantCultureId)
                                        return false;
 
-                               return ((cultureID & 0xff00) == 0 || specific_lcid == 0);
+                               if (!constructed) Construct ();
+                               return territory == null;
                        }
                }
 
@@ -527,30 +508,29 @@ namespace System.Globalization
                        }
                }
 
-               public virtual DateTimeFormatInfo DateTimeFormat
-               {
-                       get 
-                       {
+               public virtual DateTimeFormatInfo DateTimeFormat {
+                       get {
+                               if (dateTimeInfo != null)
+                                       return dateTimeInfo;
+
                                if (!constructed) Construct ();
                                CheckNeutral ();
-                               if (dateTimeInfo == null)
-                               {
-                                       lock (this)
-                                       {
-                                               if (dateTimeInfo == null) {
-                                                       dateTimeInfo = new DateTimeFormatInfo(m_isReadOnly);
+
+                               // TODO: Have to lock because construct_datetime_format is not atomic
+                               lock (this) {
+                                       if (cultureID == InvariantCultureId && m_isReadOnly)
+                                               dateTimeInfo = DateTimeFormatInfo.InvariantInfo;
+                                       else if (dateTimeInfo == null) {
+                                               dateTimeInfo = new DateTimeFormatInfo (this, m_isReadOnly);
+                                               if (cultureID != InvariantCultureId)
                                                        construct_datetime_format ();
-                                                       if (optional_calendars != null)
-                                                               dateTimeInfo.Calendar = optional_calendars [0];
-                                               }
                                        }
                                }
 
                                return dateTimeInfo;
                        }
 
-                       set 
-                       {
+                       set {
                                if (!constructed) Construct ();
                                if (m_isReadOnly) throw new InvalidOperationException(MSG_READONLY);
 
@@ -561,19 +541,17 @@ namespace System.Globalization
                        }
                }
 
-               public virtual string DisplayName
-               {
+               public virtual string DisplayName {
                        get {
-                               if (!constructed) Construct ();
-                               return(displayname);
+                               // Mono is not localized and will always return english name regardless of OS locale
+                               return EnglishName;
                        }
                }
 
-               public virtual string EnglishName
-               {
+               public virtual string EnglishName {
                        get {
                                if (!constructed) Construct ();
-                               return(englishname);
+                               return englishname;
                        }
                }
 
@@ -581,10 +559,10 @@ namespace System.Globalization
                {
                        get { return GetCultureInfo (BootstrapCultureID); }
                }
-               public bool IsReadOnly 
-               {
+
+               public bool IsReadOnly {
                        get {
-                               return(m_isReadOnly);
+                               return m_isReadOnly;
                        }
                }
                
@@ -610,43 +588,6 @@ namespace System.Globalization
                        constructed = true;
                }
 
-               bool ConstructInternalLocaleFromName (string locale)
-               {
-                       // It is sort of hack to get those new pseudo-alias
-                       // culture names that are not supported in good old
-                       // Windows.
-#if MOONLIGHT
-                       if (locale == "zh-chs" || locale == "zh-cht")
-                               return false;
-#endif
-                       switch (locale) {
-                       case "zh-hans":
-                               locale = "zh-chs";
-                               break;
-                       case "zh-hant":
-                               locale = "zh-cht";
-                               break;
-                       }
-
-                       if (!construct_internal_locale_from_name (locale))
-                               return false;
-                       return true;
-               }
-
-               bool ConstructInternalLocaleFromLcid (int lcid)
-               {
-                       if (!construct_internal_locale_from_lcid (lcid))
-                               return false;
-                       return true;
-               }
-
-               static bool ConstructInternalLocaleFromSpecificName (CultureInfo ci, string name)
-               {
-                       if (!construct_internal_locale_from_specific_name (ci, name))
-                               return false;
-                       return true;
-               }
-
                static bool ConstructInternalLocaleFromCurrentLocale (CultureInfo ci)
                {
                        if (!construct_internal_locale_from_current_locale (ci))
@@ -676,34 +617,26 @@ namespace System.Globalization
                [MethodImplAttribute (MethodImplOptions.InternalCall)]
                private extern void construct_number_format ();
 
-               // Returns false if the culture can not be found, sets is_neutral if it is
-               [MethodImplAttribute (MethodImplOptions.InternalCall)]
-               private extern static bool internal_is_lcid_neutral (int lcid, out bool is_neutral);
-
                private void ConstructInvariant (bool read_only)
                {
                        cultureID = InvariantCultureId;
 
                        /* NumberFormatInfo defaults to the invariant data */
                        numInfo=NumberFormatInfo.InvariantInfo;
-                       /* DateTimeFormatInfo defaults to the invariant data */
-                       dateTimeInfo=DateTimeFormatInfo.InvariantInfo;
 
                        if (!read_only) {
                                numInfo = (NumberFormatInfo) numInfo.Clone ();
-                               dateTimeInfo = (DateTimeFormatInfo) dateTimeInfo.Clone ();
                        }
 
                        textInfo = CreateTextInfo (read_only);
 
                        m_name=String.Empty;
-                       displayname=
                        englishname=
                        nativename="Invariant Language (Invariant Country)";
                        iso3lang="IVL";
                        iso2lang="iv";
-                       icu_name="en_US_POSIX";
                        win3lang="IVL";
+                       default_calendar_type = 1 << CalendarTypeBits;
                }
 
                private unsafe TextInfo CreateTextInfo (bool readOnly)
@@ -732,7 +665,7 @@ namespace System.Globalization
                                return;
                        }
 
-                       if (!ConstructInternalLocaleFromLcid (culture)) {
+                       if (!construct_internal_locale_from_lcid (culture)) {
 #if NET_4_0
                                throw new CultureNotFoundException ("culture", 
                                        String.Format ("Culture ID {0} (0x{0:X4}) is not a " +
@@ -765,7 +698,7 @@ namespace System.Globalization
                                return;
                        }
 
-                       if (!ConstructInternalLocaleFromName (name.ToLowerInvariant ())) {
+                       if (!construct_internal_locale_from_name (name.ToLowerInvariant ())) {
 #if NET_4_0
                                throw new CultureNotFoundException ("name",
                                                "Culture name " + name + " is not supported.");
@@ -871,35 +804,21 @@ namespace System.Globalization
                        return new CultureInfo (name, use_user_override, read_only);
                }
 
-               unsafe internal void ConstructCalendars ()
+               static Calendar CreateCalendar (int calendarType)
                {
-                       if (calendar_data == null) {
-                               optional_calendars = new Calendar [] {new GregorianCalendar (GregorianCalendarTypes.Localized)};
-                               return;
-                       }
-
-                       optional_calendars = new Calendar [NumOptionalCalendars];
-
-                       for (int i=0; i<NumOptionalCalendars; i++) {
-                               Calendar cal = null;
-                               int caldata = *(calendar_data + i);
-                               int caltype = (caldata >> CalendarTypeBits);
-                               switch (caltype) {
-                               case 0:
-                                       GregorianCalendarTypes greg_type;
-                                       greg_type = (GregorianCalendarTypes) (caldata & GregorianTypeMask);
-                                       cal = new GregorianCalendar (greg_type);
-                                       break;
-                               case 1:
-                                       cal = new HijriCalendar ();
-                                       break;
-                               case 2:
-                                       cal = new ThaiBuddhistCalendar ();
-                                       break;
-                               default:
-                                       throw new Exception ("invalid calendar type:  " + caldata);
-                               }
-                               optional_calendars [i] = cal;
+                       switch (calendarType >> CalendarTypeBits) {
+                       case 1:
+                               GregorianCalendarTypes greg_type;
+                               greg_type = (GregorianCalendarTypes) (calendarType & 0xFF);
+                               return new GregorianCalendar (greg_type);
+                       case 2:
+                               return new ThaiBuddhistCalendar ();
+                       case 3:
+                               return new UmAlQuraCalendar ();
+                       case 4:
+                               return new HijriCalendar ();
+                       default:
+                               throw new NotImplementedException ("Unknown calendar type: " + calendarType);
                        }
                }
        }
index 6ad391d11158438c542f71e8046316a13a644a28..09c21f1fc4e690a846740839dfd1c0e3fe41a82f 100644 (file)
@@ -50,22 +50,20 @@ namespace System.Globalization
        [StructLayout (LayoutKind.Sequential)]
        public sealed class DateTimeFormatInfo : ICloneable, IFormatProvider
        {
-               private static readonly string MSG_READONLY = "This instance is read only";
+               const string MSG_READONLY = "This instance is read only";
                private static readonly string[] INVARIANT_ABBREVIATED_DAY_NAMES
-                       = new string[7] { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"};
+                       = new string[7] { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" };
                private static readonly string[] INVARIANT_DAY_NAMES
-                       = new string[7] { "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"};
+                       = new string[7] { "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" };
                private static readonly string[] INVARIANT_ABBREVIATED_MONTH_NAMES
-                       = new string[13] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", ""};
+                       = new string[13] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" };
                private static readonly string[] INVARIANT_MONTH_NAMES
-                       = new string[13] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", ""};
+                       = new string[13] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" };
 //             private static readonly string[] INVARIANT_ERA_NAMES = {"A.D."};
-               static readonly string [] INVARIANT_SHORT_DAY_NAMES =
-                       new string [7] {"Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"};
+               static readonly string[] INVARIANT_SHORT_DAY_NAMES =
+                       new string[7] { "Su", "Mo", "Tu", "We", "Th", "Fr", "Sa" };
                private static DateTimeFormatInfo theInvariantDateTimeFormatInfo;
 
-               private const string _RoundtripPattern = "yyyy'-'MM'-'dd'T'HH':'mm':'ss.fffffffK";
-
 #pragma warning disable 169
                #region Sync with object-internals.h
                private bool m_isReadOnly;
@@ -79,29 +77,29 @@ namespace System.Globalization
                private string longTimePattern;
                private string monthDayPattern;
                private string yearMonthPattern;
-               private string fullDateTimePattern;
-               private string _RFC1123Pattern;
-               private string _SortableDateTimePattern;
-               private string _UniversalSortableDateTimePattern;
                private int firstDayOfWeek;
-               private Calendar calendar;
                private int calendarWeekRule;
                private string[] abbreviatedDayNames;
                private string[] dayNames;
                private string[] monthNames;
+               private string[] genitiveMonthNames;
                private string[] abbreviatedMonthNames;
+               private string[] m_genitiveAbbreviatedMonthNames;
 
-               // FIXME: not supported other than invariant
-               private string [] allShortDatePatterns;
-               private string [] allLongDatePatterns;
-               private string [] allShortTimePatterns;
-               private string [] allLongTimePatterns;
-               private string [] monthDayPatterns;
-               private string [] yearMonthPatterns;
-               private string [] shortDayNames;
+               private string[] allShortDatePatterns;
+               private string[] allLongDatePatterns;
+               private string[] allShortTimePatterns;
+               private string[] allLongTimePatterns;
+               private string[] monthDayPatterns;
+               private string[] yearMonthPatterns;
+               private string[] shortestDayNames;
                #endregion
 
+               internal readonly CultureInfo culture;
+               Calendar calendar;
+
                // MS Serialization needs this
+               private string fullDateTimePattern;
                private int nDataItem;
                private bool m_useUserOverride;
                private bool m_isDefaultCalendar;
@@ -114,17 +112,19 @@ namespace System.Globalization
                private string[] m_abbrevEnglishEraNames;
                private string[] m_dateWords;
                private int[] optionalCalendars;
-               private string[] m_superShortDayNames;
-               private string[] genitiveMonthNames;
-               private string[] m_genitiveAbbreviatedMonthNames;
                private string[] leapYearMonthNames;
                private DateTimeFormatFlags formatFlags;
                private string m_name; // Unused, but MS.NET serializes this
 #pragma warning restore 169
 
-               internal DateTimeFormatInfo(bool read_only)
+               internal DateTimeFormatInfo (CultureInfo culture, bool read_only)
                {
+                       if (culture == null)
+                               throw new ArgumentNullException ("culture");
+
+                       this.culture = culture;
                        m_isReadOnly = read_only;
+
                        amDesignator = "AM";
                        pmDesignator = "PM";
                        dateSeparator = "/";
@@ -135,24 +135,9 @@ namespace System.Globalization
                        longTimePattern = "HH:mm:ss";
                        monthDayPattern = "MMMM dd";
                        yearMonthPattern = "yyyy MMMM";
-                       fullDateTimePattern = "dddd, dd MMMM yyyy HH:mm:ss";
-
-                       // FIXME: for the following three pattern: "The
-                       // default value of this property is derived
-                       // from the calendar that is set for
-                       // CultureInfo.CurrentCulture or the default
-                       // calendar of CultureInfo.CurrentCulture."
-
-                       // Actually, no predefined culture has different values
-                       // than those default values.
 
-                       _RFC1123Pattern = "ddd, dd MMM yyyy HH':'mm':'ss 'GMT'"; 
-                       _SortableDateTimePattern = "yyyy'-'MM'-'dd'T'HH':'mm':'ss";
-                       _UniversalSortableDateTimePattern = "yyyy'-'MM'-'dd HH':'mm':'ss'Z'";
-
-                       firstDayOfWeek = (int)DayOfWeek.Sunday;
-                       calendar = new GregorianCalendar();
-                       calendarWeekRule = (int)CalendarWeekRule.FirstDay;
+                       firstDayOfWeek = (int) DayOfWeek.Sunday;
+                       calendarWeekRule = (int) CalendarWeekRule.FirstDay;
 
                        abbreviatedDayNames = INVARIANT_ABBREVIATED_DAY_NAMES;
                        dayNames = INVARIANT_DAY_NAMES;
@@ -160,10 +145,11 @@ namespace System.Globalization
                        monthNames = INVARIANT_MONTH_NAMES;
                        m_genitiveAbbreviatedMonthNames = INVARIANT_ABBREVIATED_MONTH_NAMES;
                        genitiveMonthNames = INVARIANT_MONTH_NAMES;
-                       shortDayNames = INVARIANT_SHORT_DAY_NAMES;
+                       shortestDayNames = INVARIANT_SHORT_DAY_NAMES;
                }
 
-               public DateTimeFormatInfo() : this (false)
+               public DateTimeFormatInfo ()
+                       : this (CultureInfo.InvariantCulture, false)
                {
                }
                                
@@ -207,9 +193,9 @@ namespace System.Globalization
 
                public string GetAbbreviatedEraName (int era)
                {
-                       if (era < 0 || era >= calendar.AbbreviatedEraNames.Length)
+                       if (era < 0 || era >= Calendar.AbbreviatedEraNames.Length)
                                throw new ArgumentOutOfRangeException ("era", era.ToString ());
-                       return calendar.AbbreviatedEraNames [era];
+                       return Calendar.AbbreviatedEraNames [era];
                }
 
                public string GetAbbreviatedMonthName(int month)
@@ -222,28 +208,28 @@ namespace System.Globalization
                {
                        if (eraName == null)
                                throw new ArgumentNullException ();
-                       string [] eras = calendar.EraNames;
+                       string [] eras = Calendar.EraNames;
                        for (int i = 0; i < eras.Length; i++)
                                if (CultureInfo.InvariantCulture.CompareInfo
                                        .Compare (eraName, eras [i],
                                        CompareOptions.IgnoreCase) == 0)
-                                       return calendar.Eras [i];
+                                       return Calendar.Eras [i];
                        
-                       eras = calendar.AbbreviatedEraNames;
+                       eras = Calendar.AbbreviatedEraNames;
                        for (int i = 0; i < eras.Length; i++)
                                if (CultureInfo.InvariantCulture.CompareInfo
                                        .Compare (eraName, eras [i],
                                        CompareOptions.IgnoreCase) == 0)
-                                       return calendar.Eras [i];
+                                       return Calendar.Eras [i];
                        
                        return -1;
                }
 
                public string GetEraName (int era)
                {
-                       if (era < 0 || era > calendar.EraNames.Length)
+                       if (era < 0 || era > Calendar.EraNames.Length)
                                throw new ArgumentOutOfRangeException ("era", era.ToString ());
-                       return calendar.EraNames [era - 1];
+                       return Calendar.EraNames [era - 1];
                }
 
                public string GetMonthName(int month)
@@ -251,6 +237,11 @@ namespace System.Globalization
                        if (month < 1 || month > 13) throw new ArgumentOutOfRangeException();
                        return monthNames[month-1];
                }
+               
+               internal string GetMonthGenitiveName (int month)
+               {
+                       return genitiveMonthNames [month - 1];
+               }
 
                public string[] AbbreviatedDayNames
                {
@@ -288,17 +279,9 @@ namespace System.Globalization
                        }
                }
 
-               public string[] DayNames
-               {
-                       get { return (string[]) RawDayNames.Clone (); }
-                       set { RawDayNames = value; }
-               }
-
-               internal string[] RawDayNames
-               {
-                       get
-                       {
-                               return dayNames;
+               public string[] DayNames {
+                       get {
+                               return (string[]) dayNames.Clone ();
                        }
                        set {
                                CheckDaysValue (value);
@@ -306,25 +289,28 @@ namespace System.Globalization
                        }
                }
 
-               public string[] MonthNames
-               {
-                       get { return (string[]) RawMonthNames.Clone (); }
-                       set { RawMonthNames = value; }
+               internal string[] RawDayNames  {
+                       get {
+                               return dayNames;
+                       }
                }
 
-               internal string[] RawMonthNames
-               {
-                       get
-                       {
-                               return monthNames;
+               public string[] MonthNames {
+                       get {
+                               return (string[]) monthNames.Clone ();
                        }
                        set {
                                CheckMonthsValue (value);
                                monthNames = (string[]) value.Clone();
                        }
                }
+
+               internal string[] RawMonthNames {
+                       get {
+                               return monthNames;
+                       }
+               }
                
-               [MonoLimitation ("Returns only the English month abbreviated names")]
                [ComVisible (false)]
                public string[] AbbreviatedMonthGenitiveNames {
                        get {
@@ -336,7 +322,6 @@ namespace System.Globalization
                        }
                }
 
-               [MonoLimitation ("Returns only the English month names")]
                [ComVisible (false)]
                public string[] MonthGenitiveNames {
                        get {
@@ -347,49 +332,46 @@ namespace System.Globalization
                                genitiveMonthNames = value;
                        }
                }
-
-               [MonoLimitation ("Returns an empty string as if the calendar name wasn't available")]
+               
+               [MonoLimitation ("Only default calendar is supported")]
                [ComVisible (false)]
                public string NativeCalendarName {
                        get {
-                               return String.Empty;
+                               if (Calendar != culture.Calendar)
+                                       return "";
+
+                               return culture.NativeCalendarName;
                        }
                }
 
                [ComVisible (false)]
                public string[] ShortestDayNames {
                        get {
-                               return (string[]) shortDayNames.Clone ();
+                               return (string[]) shortestDayNames.Clone ();
                        }
 
                        set {
                                CheckDaysValue (value);
-                               shortDayNames = value;
+                               shortestDayNames = value;
                        }
                }
 
-               public string AMDesignator
-               {
-                       get
-                       {
+               public string AMDesignator {
+                       get {
                                return amDesignator;
                        }
-                       set
-                       {
+                       set {
                                if (IsReadOnly) throw new InvalidOperationException(MSG_READONLY);
                                if (value == null) throw new ArgumentNullException();
                                amDesignator = value;
                        }
                }
 
-               public string PMDesignator
-               {
-                       get
-                       {
+               public string PMDesignator {
+                       get {
                                return pmDesignator;
                        }
-                       set
-                       {
+                       set {
                                if (IsReadOnly) throw new InvalidOperationException(MSG_READONLY);
                                if (value == null) throw new ArgumentNullException();
                                pmDesignator = value;
@@ -510,13 +492,8 @@ namespace System.Globalization
 
                public string FullDateTimePattern
                {
-                       get
-                       {
-                               if(fullDateTimePattern!=null) {
-                                       return fullDateTimePattern;
-                               } else {
-                                       return(longDatePattern + " " + longTimePattern);
-                               }
+                       get {
+                               return fullDateTimePattern ?? (longDatePattern + " " + longTimePattern);
                        }
                        set
                        {
@@ -536,13 +513,13 @@ namespace System.Globalization
 
                public static DateTimeFormatInfo InvariantInfo
                {
-                       get
-                       {
+                       get {
                                if (theInvariantDateTimeFormatInfo == null) {
-                                       theInvariantDateTimeFormatInfo = 
-                                               DateTimeFormatInfo.ReadOnly(new DateTimeFormatInfo());
-                                       theInvariantDateTimeFormatInfo.FillInvariantPatterns ();
+                                       var tmp = new DateTimeFormatInfo (CultureInfo.InvariantCulture, true);
+                                       tmp.FillInvariantPatterns ();
+                                       theInvariantDateTimeFormatInfo = tmp;
                                }
+
                                return theInvariantDateTimeFormatInfo;
                        }
                }
@@ -561,14 +538,13 @@ namespace System.Globalization
                        }
                }
 
-               public Calendar Calendar
-               {
-                       get
-                       {
-                               return calendar;
+               public Calendar Calendar {
+                       get {
+                               return calendar ?? culture.Calendar;
                        }
-                       set
-                       {
+
+                       [MonoLimitation ("Only default calendar specific data are available")]
+                       set {
                                if (IsReadOnly) throw new InvalidOperationException(MSG_READONLY);
                                if (value == null) throw new ArgumentNullException();
                                calendar = value;
@@ -588,35 +564,27 @@ namespace System.Globalization
                        }
                }
 
-               public string RFC1123Pattern
-               {
-                       get
-                       {
-                               return _RFC1123Pattern;
+               public string RFC1123Pattern {
+                       get {
+                               return "ddd, dd MMM yyyy HH':'mm':'ss 'GMT'";
                        }
                }
 
-               internal string RoundtripPattern
-               {
-                       get
-                       {
-                               return _RoundtripPattern;
+               internal string RoundtripPattern {
+                       get {
+                               return "yyyy'-'MM'-'dd'T'HH':'mm':'ss.fffffffK";
                        }
                }
 
-               public string SortableDateTimePattern
-               {
-                       get
-                       {
-                               return _SortableDateTimePattern;
+               public string SortableDateTimePattern {
+                       get {
+                               return "yyyy'-'MM'-'dd'T'HH':'mm':'ss";
                        }
                }
 
-               public string UniversalSortableDateTimePattern
-               {
-                       get
-                       {
-                               return _UniversalSortableDateTimePattern;
+               public string UniversalSortableDateTimePattern {
+                       get {
+                               return "yyyy'-'MM'-'dd HH':'mm':'ss'Z'";
                        }
                }
                
@@ -642,20 +610,17 @@ namespace System.Globalization
                        if (all_date_time_patterns != null)
                                return;
                        
-                       var al = new List<string> ();
+                       var al = new List<string> (16);
                        al.AddRange (GetAllRawDateTimePatterns ('d'));
                        al.AddRange (GetAllRawDateTimePatterns ('D'));
-                       al.AddRange (GetAllRawDateTimePatterns ('g'));
-                       al.AddRange (GetAllRawDateTimePatterns ('G'));
                        al.AddRange (GetAllRawDateTimePatterns ('f'));
                        al.AddRange (GetAllRawDateTimePatterns ('F'));
-                       // Yes, that is very meaningless, but that is what MS
-                       // is doing (LAMESPEC: Since it is documented that
-                       // 'M' and 'm' are equal, they should not cosider
-                       // that there is a possibility that 'M' and 'm' are
-                       // different.)
+                       al.AddRange (GetAllRawDateTimePatterns ('g'));
+                       al.AddRange (GetAllRawDateTimePatterns ('G'));
                        al.AddRange (GetAllRawDateTimePatterns ('m'));
                        al.AddRange (GetAllRawDateTimePatterns ('M'));
+                       al.AddRange (GetAllRawDateTimePatterns ('o'));
+                       al.AddRange (GetAllRawDateTimePatterns ('O'));
                        al.AddRange (GetAllRawDateTimePatterns ('r'));
                        al.AddRange (GetAllRawDateTimePatterns ('R'));
                        al.AddRange (GetAllRawDateTimePatterns ('s'));
@@ -682,7 +647,6 @@ namespace System.Globalization
 
                internal string[] GetAllRawDateTimePatterns (char format)
                {
-                       string [] list;
                        switch (format) {
                        // Date
                        case 'D':
@@ -702,52 +666,50 @@ namespace System.Globalization
                                if (allShortTimePatterns != null && allShortTimePatterns.Length > 0)
                                        return allShortTimePatterns;
                                return new string [] {ShortTimePattern};
-                       // {Short|Long}Date + {Short|Long}Time
-                       // FIXME: they should be the agglegation of the
-                       // combination of the Date patterns and Time patterns.
-                       case 'G':
-                               list = PopulateCombinedList (allShortDatePatterns, allLongTimePatterns);
-                               if (list != null && list.Length > 0)
-                                       return list;
-                               return new string [] {ShortDatePattern + " " + LongTimePattern};
-                       case 'g':
-                               list = PopulateCombinedList (allShortDatePatterns, allShortTimePatterns);
-                               if (list != null && list.Length > 0)
-                                       return list;
-                               return new string [] {ShortDatePattern + " " + ShortTimePattern};
-                       // The 'U' pattern strings are always the same as 'F'.
-                       // (only differs in assuming UTC or not.)
-                       case 'U':
-                       case 'F':
-                               list = PopulateCombinedList (allLongDatePatterns, allLongTimePatterns);
-                               if (list != null && list.Length > 0)
-                                       return list;
-                               return new string [] {LongDatePattern + " " + LongTimePattern};
-                       case 'f':
-                               list = PopulateCombinedList (allLongDatePatterns, allShortTimePatterns);
-                               if (list != null && list.Length > 0)
-                                       return list;
-                               return new string [] {LongDatePattern + " " + ShortTimePattern};
                        // MonthDay
                        case 'm':
                        case 'M':
                                if (monthDayPatterns != null && monthDayPatterns.Length > 0)
                                        return monthDayPatterns;
-                               return new string [] {MonthDayPattern};
+                               return new string[] { MonthDayPattern };
                        // YearMonth
                        case 'Y':
                        case 'y':
                                if (yearMonthPatterns != null && yearMonthPatterns.Length > 0)
                                        return yearMonthPatterns;
-                               return new string [] {YearMonthPattern};
-                       // RFC1123
+                               return new string[] { YearMonthPattern };
                        case 'r':
                        case 'R':
-                               return new string [] {RFC1123Pattern};
+                               return new string[] { RFC1123Pattern };
+                       case 'O':
+                       case 'o':
+                               return new string[] { RoundtripPattern };
                        case 's':
-                               return new string [] {SortableDateTimePattern};
+                               return new string[] { SortableDateTimePattern };
                        case 'u':
-                               return new string [] {UniversalSortableDateTimePattern};
+                               return new string[] { UniversalSortableDateTimePattern };
+
+                       //
+                       // Following patterns are combinations of {Short|Long}Date + {Short|Long}Time. Patters can
+                       // be null for non-readonly invariant culture
+                       //
+                       case 'G':
+                               return allShortDatePatterns == null ?
+                                       new string [] { ShortDatePattern + " " + LongTimePattern } :
+                                       PopulateCombinedList (allShortDatePatterns, allLongTimePatterns);
+                       case 'g':
+                               return allShortDatePatterns == null ?
+                                       new string [] { ShortDatePattern + " " + ShortTimePattern } :
+                                       PopulateCombinedList (allShortDatePatterns, allShortTimePatterns);
+                       case 'U': // The 'U' pattern strings are always the same as 'F' (only differs in assuming UTC or not.)
+                       case 'F':
+                               return allLongDatePatterns == null ?
+                                       new string [] { LongDatePattern + " " + ShortTimePattern } :
+                                       PopulateCombinedList (allLongDatePatterns, allLongTimePatterns);
+                       case 'f':
+                               return allLongDatePatterns == null ?
+                                       new string [] { LongDatePattern + " " + ShortTimePattern } :
+                                       PopulateCombinedList (allLongDatePatterns, allShortTimePatterns);
                        }
                        throw new ArgumentException ("Format specifier was invalid.");
                }
@@ -766,7 +728,7 @@ namespace System.Globalization
                        return abbreviatedDayNames[index];
                }
 
-               private void FillInvariantPatterns ()
+               void FillInvariantPatterns ()
                {
                        allShortDatePatterns = new string [] {"MM/dd/yyyy"};
                        allLongDatePatterns = new string [] {"dddd, dd MMMM yyyy"};
@@ -779,19 +741,18 @@ namespace System.Globalization
                        };
                        monthDayPatterns = new string [] {"MMMM dd"};
                        yearMonthPatterns = new string [] {"yyyy MMMM"};
+
+                       fullDateTimePattern = "dddd, dd MMMM yyyy HH:mm:ss";
                }
 
                static string [] PopulateCombinedList (string [] dates, string [] times)
                {
-                       if (dates != null && times != null) {
-                               string [] list = new string [dates.Length * times.Length];
-                               int i = 0;
-                               foreach (string d in dates)
-                                       foreach (string t in times)
-                                               list [i++] = d + " " + t;
-                               return list;
-                       }
-                       return null;
+                       string[] list = new string[dates.Length * times.Length];
+                       int i = 0;
+                       foreach (string d in dates)
+                               foreach (string t in times)
+                                       list[i++] = d + " " + t;
+                       return list;
                }
 
                [ComVisible (false)]
@@ -799,9 +760,9 @@ namespace System.Globalization
                {
                        int index = (int) dayOfWeek;
                        if (index < 0 || index > 6)
-                               throw new ArgumentOutOfRangeException();
+                               throw new ArgumentOutOfRangeException ("dayOfWeek");
 
-                       return shortDayNames [index];
+                       return shortestDayNames [index];
                }
 
                [ComVisible (false)]
index 888a2d42ffd301fab566116a966dc0e44e03ad25..b6165a661d0ad1f4dac3498c8faa5e154b6df193 100644 (file)
@@ -1,12 +1,12 @@
 //
 // System.Globalization.RegionInfo.cs
 //
-// Author:
+// Authors:
 //     Atsushi Enomoto  <atsushi@ximian.com>
-//
-
+//   Marek Safar (marek.safar@gmail.com)
 //
 // Copyright (C) 2005 Novell, Inc (http://www.novell.com)
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
@@ -68,15 +68,13 @@ namespace System.Globalization
                string iso3Name;
                string win3Name;
                string englishName;
+               string nativeName;
                string currencySymbol;
                string isoCurrencySymbol;
                string currencyEnglishName;
+               string currencyNativeName;
 #pragma warning restore 649
                
-               // new (instance) fields should be added here (and do not have to be duplicated in the runtime)
-               
-               int lcid; // it is used only for Equals() (not even used in GetHashCode()).
-               
                public RegionInfo (int culture)
                {
                        if (!GetByTerritory (CultureInfo.GetCultureInfo (culture)))
@@ -90,7 +88,6 @@ namespace System.Globalization
                                throw new ArgumentNullException ();
 
                        if (construct_internal_region_from_name (name.ToUpperInvariant ())) {
-                               lcid = name.GetHashCode (); // random-ish
                                return;
                        }
                        if (!GetByTerritory (CultureInfo.GetCultureInfo (name)))
@@ -103,7 +100,7 @@ namespace System.Globalization
                                throw new Exception ("INTERNAL ERROR: should not happen.");
                        if (ci.IsNeutralCulture || ci.Territory == null)
                                return false;
-                       this.lcid = ci.LCID;
+
                        return construct_internal_region_from_name (ci.Territory.ToUpperInvariant ());
                }
 
@@ -149,15 +146,14 @@ namespace System.Globalization
                        get { return isoCurrencySymbol; }
                }
 
-               [System.Runtime.InteropServices.ComVisible(false)]
+               [ComVisible(false)]
                public virtual string NativeName {
-                       get { return DisplayName; }
+                       get { return nativeName; }
                }
 
-               [MonoTODO ("Not implemented")]
-               [System.Runtime.InteropServices.ComVisible(false)]
+               [ComVisible(false)]
                public virtual string CurrencyNativeName {
-                       get { throw new NotImplementedException (); }
+                       get { return currencyNativeName; }
                }
 
                public virtual string Name {
@@ -176,18 +172,15 @@ namespace System.Globalization
                        get { return iso2Name; }
                }
 
-               //
-               // methods
-
                public override bool Equals (object value)
                {
                        RegionInfo other = value as RegionInfo;
-                       return other != null && lcid == other.lcid;
+                       return other != null && Name == other.Name;
                }
 
                public override int GetHashCode ()
                {
-                       return (int) (0x80000000 + (regionId << 3) + regionId); // it i still based on regionId
+                       return Name.GetHashCode ();
                }
 
                public override string ToString ()
index 0fa0bf57b30c833b92830160074eb92752d4564a..cd4b95be9875657bbb56e6d47caf9bf9901e97ed 100644 (file)
@@ -53,6 +53,7 @@ namespace System.Globalization {
                        public int ebcdic;
                        public int mac;
                        public int oem;
+                       public bool right_to_left;
                        public byte list_sep;
                }
 
@@ -175,39 +176,7 @@ namespace System.Globalization {
                [ComVisible (false)]
                public bool IsRightToLeft {
                        get {
-                               // hardcoded
-                               switch (m_win32LangID) {
-                               case 1:         // ar
-                               case 13:        // he
-                               case 32:        // ur
-                               case 41:        // fa
-                               case 90:        // syr
-                               case 101:       // div
-                               case 1025:      // ar-SA
-                               case 1037:      // he-IL
-                               case 1056:      // ur-PK
-                               case 1065:      // ra-IR
-                               case 1114:      // syr-SY
-                               case 1125:      // div-MV
-                               case 2049:      // ar-IQ
-                               case 3073:      // ar-EG
-                               case 4097:      // ar-LY
-                               case 5121:      // ar-DZ
-                               case 6145:      // ar-MA
-                               case 7169:      // ar-TN
-                               case 8193:      // ar-OM
-                               case 9217:      // ar-YE
-                               case 10241:     // ar-SY
-                               case 11265:     // ar-JO
-                               case 12289:     // ar-LB
-                               case 13313:     // ar-KW
-                               case 14337:     // ar-AE
-                               case 15361:     // ar-BH
-                               case 16385:     // ar-QA
-                                       return true;
-                               default:
-                                       return false;
-                               }
+                               return data.right_to_left;
                        }
                }
 
index 4bc72182f7679e586aab36bdc8021c1ff7a8f59d..47ce1efaa346a960c5e64e63d8380928ebf6a4af 100644 (file)
@@ -579,7 +579,7 @@ namespace System.IO.IsolatedStorage {
 #endif
                                directory.CreateSubdirectory (dir);
                        } else {
-                               string[] dirs = dir.Split (Path.PathSeparatorChars);
+                               string[] dirs = dir.Split (Path.PathSeparatorChars, StringSplitOptions.RemoveEmptyEntries);
                                DirectoryInfo dinfo = directory;
 
                                for (int i = 0; i < dirs.Length; i++) {
@@ -646,6 +646,8 @@ namespace System.IO.IsolatedStorage {
                public void DeleteDirectory (string dir)
                {
                        try {
+                               if (Path.IsPathRooted (dir))
+                                       dir = dir.Substring (1);
                                DirectoryInfo subdir = directory.CreateSubdirectory (dir);
                                subdir.Delete ();
                        }
index b730b8ceb10818f834671128b02f4ac2777b4232..9650113c9dc24e29471f32a15ce352ef5aa1cf54 100644 (file)
@@ -100,7 +100,7 @@ namespace System.IO {
                        Dispose (true);
                }
 
-#if NET_4_0 || MOONLIGHT
+#if NET_4_0 || NET_2_1
                public void Dispose ()
 #else
                void IDisposable.Dispose() 
index f89218e2bc8aba9743140d565dfe69db4aff81ce..5730a45018c5f92ebae21c0f4477ce471a09d1eb 100644 (file)
@@ -547,19 +547,27 @@ namespace System.IO
                                throw MonoIO.GetException (Path.GetDirectoryName (Path.Combine (path, searchPattern)), (MonoIOError) error);
 
                        try {
+                               bool first = true;
                                if (((rattr & FileAttributes.ReparsePoint) == 0) && ((rattr & kind) != 0))
                                        yield return s;
                                
-                               while ((s = MonoIO.FindNext (handle, out rattr, out error)) != null){
+                               do {
+                                       if (((rattr & FileAttributes.Directory) != 0) && subdirs) {
+                                               foreach (string child in EnumerateKind (s, searchPattern, searchOption, kind))
+                                                       yield return child;
+                                       }
+
+                                       if (first) {
+                                               first = false;
+                                               continue;
+                                       }
+                                       
                                        if ((rattr & FileAttributes.ReparsePoint) != 0)
                                                continue;
+
                                        if ((rattr & kind) != 0)
                                                yield return s;
-                                       
-                                       if (((rattr & FileAttributes.Directory) != 0) && subdirs)
-                                               foreach (string child in EnumerateKind (s, searchPattern, searchOption, kind))
-                                                       yield return child;
-                               }
+                               } while ((s = MonoIO.FindNext (handle, out rattr, out error)) != null);
                        } finally {
                                MonoIO.FindClose (handle);
                        }
index da9e3075c61c9c0e728adecf4a446bca04774dcb..ebedda41ac7e90f152b5fd0e1a4612bbd8112a08 100644 (file)
@@ -27,8 +27,9 @@ namespace System.IO {
 
                public override void Write (string s)
                {
-                       foreach (char c in s)
-                               Write (c);
+                       if (s != null)
+                               foreach (char c in s)
+                                       Write (c);
                }
 
                public override void Write (char value)
index 260168ea7f7528159643337a3d0e32ff1613415b..5b63ce725058477d59e1003d6c58c52de6bba550 100644 (file)
@@ -349,12 +349,14 @@ namespace System.IO {
                                if (!IsPathRooted (path)) {
                                        
                                        // avoid calling expensive CanonicalizePath when possible
-                                       var start = 0;
-                                       while ((start = path.IndexOf ('.', start)) != -1) {
-                                               if (++start == path.Length || path [start] == DirectorySeparatorChar || path [start] == AltDirectorySeparatorChar)
-                                                       break;
+                                       if (!Environment.IsRunningOnWindows) {
+                                               var start = 0;
+                                               while ((start = path.IndexOf ('.', start)) != -1) {
+                                                       if (++start == path.Length || path [start] == DirectorySeparatorChar || path [start] == AltDirectorySeparatorChar)
+                                                               break;
+                                               }
+                                               canonicalize = start > 0;
                                        }
-                                       canonicalize = start > 0;
                                        
                                        path = Directory.GetCurrentDirectory () + DirectorySeparatorStr + path;
                                } else if (DirectorySeparatorChar == '\\' &&
index 31d23b1cb9ac1863ed51de9891bd17c84ad6b3f9..eefeff3ccdfa6e1e273c9544045d2de34e812395 100644 (file)
@@ -37,7 +37,7 @@ using System.Reflection.Emit;
 using System.Security;
 using System.Threading;
 using System.Text;
-
+using System.Diagnostics;
 
 namespace System.Reflection {
        
@@ -186,6 +186,8 @@ namespace System.Reflection {
                [MethodImplAttribute(MethodImplOptions.InternalCall)]
                internal extern Object InternalInvoke (Object obj, Object[] parameters, out Exception exc);
 
+               [DebuggerHidden]
+               [DebuggerStepThrough]
                public override Object Invoke (Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) 
                {
                        if (binder == null)
@@ -241,8 +243,11 @@ namespace System.Reflection {
                }
 
                public override RuntimeMethodHandle MethodHandle { 
-                       get {return new RuntimeMethodHandle (mhandle);} 
+                       get {
+                               return new RuntimeMethodHandle (mhandle);
+                       } 
                }
+               
                public override MethodAttributes Attributes { 
                        get {
                                return MonoMethodInfo.GetAttributes (mhandle);
@@ -486,6 +491,8 @@ namespace System.Reflection {
                [MethodImplAttribute(MethodImplOptions.InternalCall)]
                internal extern Object InternalInvoke (Object obj, Object[] parameters, out Exception exc);
 
+               [DebuggerHidden]
+               [DebuggerStepThrough]
                public override Object Invoke (Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) 
                {
                        if (binder == null)
@@ -539,13 +546,19 @@ namespace System.Reflection {
                        return (obj == null) ? o : null;
                }
 
-               public override Object Invoke (BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) {
+               [DebuggerHidden]
+               [DebuggerStepThrough]
+               public override Object Invoke (BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
+               {
                        return Invoke (null, invokeAttr, binder, parameters, culture);
                }
 
                public override RuntimeMethodHandle MethodHandle { 
-                       get {return new RuntimeMethodHandle (mhandle);} 
+                       get {
+                               return new RuntimeMethodHandle (mhandle);
+                       } 
                }
+               
                public override MethodAttributes Attributes { 
                        get {
                                return MonoMethodInfo.GetAttributes (mhandle);
index fb10ef97c63f305122338a87307883afbcdd254f..197ece5adc9ab9a5c6a9b1f72df9cd16bbd04434 100644 (file)
@@ -76,8 +76,15 @@ namespace System.Runtime.CompilerServices
                
                public void SetException (Exception exception)
                {
-                       if (!task.TrySetException (new AggregateException (exception)))
-                               throw new InvalidOperationException ("The task has already completed");
+                       if (exception is OperationCanceledException) {
+                               if (Task.TrySetCanceled ())
+                                       return;
+                       } else {
+                               if (Task.TrySetException (new AggregateException (exception)))
+                                       return;
+                       }
+
+                       throw new InvalidOperationException ("The task has already completed");
                }
 
                public void SetStateMachine (IAsyncStateMachine stateMachine)
index 71cbb214ce6a5ef2619a12584e7be4c821d24774..f955d6b9fd57a3cfbe4b94965d9635bf5c3d0b4d 100644 (file)
@@ -76,8 +76,15 @@ namespace System.Runtime.CompilerServices
 
                public void SetException (Exception exception)
                {
-                       if (!task.TrySetException (new AggregateException (exception)))
-                               throw new InvalidOperationException ("The task has already completed");
+                       if (exception is OperationCanceledException) {
+                               if (Task.TrySetCanceled ())
+                                       return;
+                       } else {
+                               if (Task.TrySetException (new AggregateException (exception)))
+                                       return;
+                       }
+
+                       throw new InvalidOperationException ("The task has already completed");
                }
 
                public void SetStateMachine (IAsyncStateMachine stateMachine)
diff --git a/mcs/class/corlib/System.Threading.Tasks/EventSlots.cs b/mcs/class/corlib/System.Threading.Tasks/EventSlots.cs
deleted file mode 100644 (file)
index 3da451a..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-//
-// EventSlots.cs
-//
-// Authors:
-//    Jérémie Laval <jeremie dot laval at xamarin dot com>
-//
-// Copyright 2011 Xamarin Inc (http://www.xamarin.com).
-//
-// Permission is hereby granted, free of charge, to any person obtaining a copy
-// of this software and associated documentation files (the "Software"), to deal
-// in the Software without restriction, including without limitation the rights
-// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-// copies of the Software, and to permit persons to whom the Software is
-// furnished to do so, subject to the following conditions:
-//
-// The above copyright notice and this permission notice shall be included in
-// all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-// THE SOFTWARE.
-//
-//
-
-#if NET_4_0 || MOBILE
-
-namespace System.Threading.Tasks
-{
-       class ManualEventSlot : IContinuation
-       {
-               ManualResetEventSlim evt;
-               public ManualEventSlot (ManualResetEventSlim evt)
-               {
-                       this.evt = evt;
-               }
-
-               public void Execute ()
-               {
-                       evt.Set ();
-               }
-       }
-
-       class CountdownEventSlot : IContinuation
-       {
-               CountdownEvent evt;
-               public CountdownEventSlot (CountdownEvent evt)
-               {
-                       this.evt = evt;
-               }
-
-               public void Execute ()
-               {
-                       evt.Signal ();
-               }
-       }
-}
-
-#endif
-
index 92e1e3b05e389bcb7cb0538d27f20b2f50367cc5..9b7597761348a8e49533add84f133df8e1482e80 100644 (file)
@@ -45,12 +45,12 @@ namespace System.Threading.Tasks
                // With this attribute each thread has its own value so that it's correct for our Schedule code
                // and for Parent property.
                [System.ThreadStatic]
-               static Task         current;
+               static Task current;
                [System.ThreadStatic]
                static Action<Task> childWorkAdder;
                
                // parent is the outer task in which this task is created
-               protected readonly Task parent;
+               readonly Task parent;
                // contAncestor is the Task on which this continuation was setup
                readonly Task contAncestor;
                
@@ -137,15 +137,15 @@ namespace System.Threading.Tasks
                }
 
                internal Task (TaskActionInvoker invoker, object state, CancellationToken cancellationToken,
-                              TaskCreationOptions creationOptions, Task parent, Task contAncestor = null)
+                              TaskCreationOptions creationOptions, Task parent = null, Task contAncestor = null)
                {
-                       this.invoker = invoker;
+                       this.invoker             = invoker;
                        this.taskCreationOptions = creationOptions;
                        this.state               = state;
                        this.taskId              = Interlocked.Increment (ref id);
                        this.status              = cancellationToken.IsCancellationRequested ? TaskStatus.Canceled : TaskStatus.Created;
                        this.token               = cancellationToken;
-                       this.parent              = parent;
+                       this.parent              = parent = parent == null ? current : parent;
                        this.contAncestor        = contAncestor;
 
                        // Process taskCreationOptions
@@ -251,7 +251,7 @@ namespace System.Threading.Tasks
 
                internal Task ContinueWith (TaskActionInvoker invoker, CancellationToken cancellationToken, TaskContinuationOptions continuationOptions, TaskScheduler scheduler)
                {
-                       var continuation = new Task (invoker, null, cancellationToken, GetCreationOptions (continuationOptions), parent, this);
+                       var continuation = new Task (invoker, null, cancellationToken, GetCreationOptions (continuationOptions), null, this);
                        ContinueWithCore (continuation, continuationOptions, scheduler);
 
                        return continuation;
@@ -377,6 +377,11 @@ namespace System.Threading.Tasks
                                cancellationRegistration.Value.Dispose ();
                                cancellationRegistration = null;
                        }
+
+                       // If Task are ran inline on the same thread we might trash these values
+                       var saveCurrent = current;
+                       var saveScheduler = TaskScheduler.Current;
+
                        current = this;
                        TaskScheduler.Current = scheduler;
                        
@@ -397,6 +402,11 @@ namespace System.Threading.Tasks
                        } else {
                                CancelReal ();
                        }
+
+                       if (saveCurrent != null)
+                               current = saveCurrent;
+                       if (saveScheduler != null)
+                               TaskScheduler.Current = saveScheduler;
                        Finish ();
                }
 
@@ -433,13 +443,7 @@ namespace System.Threading.Tasks
                        HandleGenericException (aggregate);
                        return true;
                }
-/*
-               internal void Execute (Action<Task> childAdder)
-               {
-                       childWorkAdder = childAdder;
-                       Execute ();
-               }
-*/             
+
                internal void Execute ()
                {
                        ThreadStart ();
@@ -461,8 +465,8 @@ namespace System.Threading.Tasks
                        }
 
                        if (childTasks.Signal () && status == TaskStatus.WaitingForChildrenToComplete) {
-                               Status = TaskStatus.RanToCompletion;
                                ProcessChildExceptions ();
+                               Status = exSlot == null ? TaskStatus.RanToCompletion : TaskStatus.Faulted;
                                ProcessCompleteDelegates ();
                                if (CheckTaskOptions (taskCreationOptions, TaskCreationOptions.AttachedToParent) && parent != null)
                                        parent.ChildCompleted (this.Exception);
@@ -481,8 +485,10 @@ namespace System.Threading.Tasks
                internal void Finish ()
                {
                        // If there was children created and they all finished, we set the countdown
-                       if (childTasks != null)
-                               childTasks.Signal ();
+                       if (childTasks != null) {
+                               if (childTasks.Signal ())
+                                       ProcessChildExceptions (true);
+                       }
                        
                        // Don't override Canceled or Faulted
                        if (status == TaskStatus.Running) {
@@ -497,8 +503,10 @@ namespace System.Threading.Tasks
                                ProcessCompleteDelegates ();
 
                        // Reset the current thingies
-                       current = null;
-                       TaskScheduler.Current = null;
+                       if (current == this)
+                               current = null;
+                       if (TaskScheduler.Current == scheduler)
+                               TaskScheduler.Current = null;
 
                        if (cancellationRegistration.HasValue)
                                cancellationRegistration.Value.Dispose ();
@@ -518,7 +526,7 @@ namespace System.Threading.Tasks
                        }
                }
 
-               void ProcessChildExceptions ()
+               void ProcessChildExceptions (bool isParent = false)
                {
                        if (exSlot == null || exSlot.ChildExceptions == null)
                                return;
@@ -529,6 +537,11 @@ namespace System.Threading.Tasks
                        AggregateException childEx;
                        while (exSlot.ChildExceptions.TryDequeue (out childEx))
                                exSlot.Exception.AddChildException (childEx);
+
+                       if (isParent) {
+                               Status = TaskStatus.Faulted;
+                               ProcessCompleteDelegates ();                    
+                       }
                }
                #endregion
                
@@ -553,10 +566,13 @@ namespace System.Threading.Tasks
                        ProcessCompleteDelegates ();
                }
 
-               internal void WaitOnChildren ()
+               internal bool WaitOnChildren ()
                {
-                       if (Status == TaskStatus.WaitingForChildrenToComplete && childTasks != null)
+                       if (Status == TaskStatus.WaitingForChildrenToComplete && childTasks != null) {
                                childTasks.Wait ();
+                               return true;
+                       }
+                       return false;
                }
                
                public void Wait ()
@@ -587,20 +603,19 @@ namespace System.Threading.Tasks
                        bool result = true;
 
                        if (!IsCompleted) {
-                               // If the task is ready to be run and we were supposed to wait on it indefinitely, just run it
-                               if (Status == TaskStatus.WaitingToRun && millisecondsTimeout == -1 && scheduler != null)
+                               // If the task is ready to be run and we were supposed to wait on it indefinitely without cancellation, just run it
+                               if (Status == TaskStatus.WaitingToRun && millisecondsTimeout == Timeout.Infinite && scheduler != null && !cancellationToken.CanBeCanceled)
                                        Execute ();
 
                                if (!IsCompleted) {
-                                       var evt = new ManualResetEventSlim ();
-                                       var slot = new ManualEventSlot (evt);
+                                       var continuation = new ManualResetContinuation ();
                                        try {
-                                               ContinueWith (slot);
-                                               result = evt.Wait (millisecondsTimeout, cancellationToken);
+                                               ContinueWith (continuation);
+                                               result = continuation.Event.Wait (millisecondsTimeout, cancellationToken);
                                        } finally {
                                                if (!result)
-                                                       RemoveContinuation (slot);
-                                               evt.Dispose ();
+                                                       RemoveContinuation (continuation);
+                                               continuation.Dispose ();
                                        }
                                }
                        }
@@ -646,19 +661,18 @@ namespace System.Threading.Tasks
                        bool result = true;
                        foreach (var t in tasks) {
                                if (t == null)
-                                       throw new ArgumentNullException ("tasks", "the tasks argument contains a null element");
+                                       throw new ArgumentException ("tasks", "the tasks argument contains a null element");
 
                                result &= t.Status == TaskStatus.RanToCompletion;
                        }
 
                        if (!result) {
-                               var evt = new CountdownEvent (tasks.Length);
-                               var slot = new CountdownEventSlot (evt);
+                               var continuation = new CountdownContinuation (tasks.Length);
                                try {
                                        foreach (var t in tasks)
-                                               t.ContinueWith (slot);
+                                               t.ContinueWith (continuation);
 
-                                       result = evt.Wait (millisecondsTimeout, cancellationToken);
+                                       result = continuation.Event.Wait (millisecondsTimeout, cancellationToken);
                                } finally {
                                        List<Exception> exceptions = null;
 
@@ -673,11 +687,11 @@ namespace System.Threading.Tasks
                                                        else
                                                                exceptions.Add (new TaskCanceledException (t));
                                                } else {
-                                                       t.RemoveContinuation (slot);
+                                                       t.RemoveContinuation (continuation);
                                                }
                                        }
 
-                                       evt.Dispose ();
+                                       continuation.Dispose ();
 
                                        if (exceptions != null)
                                                throw new AggregateException (exceptions);
@@ -716,24 +730,23 @@ namespace System.Threading.Tasks
                        CheckForNullTasks (tasks);
 
                        if (tasks.Length > 0) {
-                               var evt = new ManualResetEventSlim ();
-                               var slot = new ManualEventSlot (evt);
+                               var continuation = new ManualResetContinuation ();
                                bool result = false;
                                try {
                                        for (int i = 0; i < tasks.Length; i++) {
                                                var t = tasks[i];
                                                if (t.IsCompleted)
                                                        return i;
-                                               t.ContinueWith (slot);
+                                               t.ContinueWith (continuation);
                                        }
 
-                                       if (!(result = evt.Wait (millisecondsTimeout, cancellationToken)))
+                                       if (!(result = continuation.Event.Wait (millisecondsTimeout, cancellationToken)))
                                                return -1;
                                } finally {
                                        if (!result)
                                                foreach (var t in tasks)
-                                                       t.RemoveContinuation (slot);
-                                       evt.Dispose ();
+                                                       t.RemoveContinuation (continuation);
+                                       continuation.Dispose ();
                                }
                        }
 
@@ -762,7 +775,7 @@ namespace System.Threading.Tasks
                {
                        foreach (var t in tasks)
                                if (t == null)
-                                       throw new ArgumentNullException ("tasks", "the tasks argument contains a null element");
+                                       throw new ArgumentException ("tasks", "the tasks argument contains a null element");
                }
                #endregion
                
@@ -873,6 +886,35 @@ namespace System.Threading.Tasks
                        return t;
                }
 
+               public static Task Delay (int millisecondsDelay)
+               {
+                       return Delay (millisecondsDelay, CancellationToken.None);
+               }
+
+               public static Task Delay (TimeSpan delay)
+               {
+                       return Delay (CheckTimeout (delay), CancellationToken.None);
+               }
+
+               public static Task Delay (TimeSpan delay, CancellationToken cancellationToken)
+               {
+                       return Delay (CheckTimeout (delay), cancellationToken);
+               }
+
+               public static Task Delay (int millisecondsDelay, CancellationToken cancellationToken)
+               {
+                       if (millisecondsDelay < -1)
+                               throw new ArgumentOutOfRangeException ("millisecondsDelay");
+
+                       var task = new Task (TaskActionInvoker.Delay, millisecondsDelay, cancellationToken, TaskCreationOptions.None, null, TaskConstants.Finished);
+                       task.SetupScheduler (TaskScheduler.Current);
+                       
+                       if (millisecondsDelay != Timeout.Infinite)
+                               task.scheduler.QueueTask (task);
+
+                       return task;
+               }
+
                public static Task<TResult> FromResult<TResult> (TResult result)
                {
                        var tcs = new TaskCompletionSource<TResult> ();
@@ -949,14 +991,190 @@ namespace System.Threading.Tasks
                        var r = await task.ConfigureAwait (false);
                        return r.Result;
                }
-               
+
+               public static Task WhenAll (params Task[] tasks)
+               {
+                       if (tasks == null)
+                               throw new ArgumentNullException ("tasks");
+
+                       return WhenAllCore (tasks);
+               }
+
+               public static Task WhenAll (IEnumerable<Task> tasks)
+               {
+                       if (tasks == null)
+                               throw new ArgumentNullException ("tasks");
+
+                       // Call ToList on input enumeration or we end up
+                       // enumerating it more than once
+                       return WhenAllCore (new List<Task> (tasks));
+               }
+
+               public static Task<TResult[]> WhenAll<TResult> (params Task<TResult>[] tasks)
+               {
+                       if (tasks == null)
+                               throw new ArgumentNullException ("tasks");
+
+                       return WhenAllCore<TResult> (tasks);
+               }
+
+               public static Task<TResult[]> WhenAll<TResult> (IEnumerable<Task<TResult>> tasks)
+               {
+                       if (tasks == null)
+                               throw new ArgumentNullException ("tasks");
+
+                       // Call ToList on input enumeration or we end up
+                       // enumerating it more than once
+                       return WhenAllCore<TResult> (new List<Task<TResult>> (tasks));
+               }
+
+               internal static Task<TResult[]> WhenAllCore<TResult> (IList<Task<TResult>> tasks)
+               {
+                       foreach (var t in tasks) {
+                               if (t == null)
+                                       throw new ArgumentException ("tasks", "the tasks argument contains a null element");
+                       }
+
+                       var task = new Task<TResult[]> (TaskActionInvoker.Empty, null, CancellationToken.None, TaskCreationOptions.None, null, TaskConstants.Finished);
+                       task.SetupScheduler (TaskScheduler.Current);
+
+                       var continuation = new WhenAllContinuation<TResult> (task, tasks);
+                       foreach (var t in tasks)
+                               t.ContinueWith (continuation);
+
+                       return task;
+               }
+
+               public static Task<Task> WhenAny (params Task[] tasks)
+               {
+                       if (tasks == null)
+                               throw new ArgumentNullException ("tasks");
+
+                       return WhenAnyCore (tasks);
+               }
+
+               public static Task<Task> WhenAny (IEnumerable<Task> tasks)
+               {
+                       if (tasks == null)
+                               throw new ArgumentNullException ("tasks");
+
+                       return WhenAnyCore (new List<Task> (tasks));
+               }
+
+               public static Task<Task<TResult>> WhenAny<TResult> (params Task<TResult>[] tasks)
+               {
+                       if (tasks == null)
+                               throw new ArgumentNullException ("tasks");
+
+                       return WhenAnyCore<TResult> (tasks);
+               }
+
+               public static Task<Task<TResult>> WhenAny<TResult> (IEnumerable<Task<TResult>> tasks)
+               {
+                       if (tasks == null)
+                               throw new ArgumentNullException ("tasks");
+
+                       return WhenAnyCore<TResult> (new List<Task<TResult>> (tasks));
+               }
+
+               static Task<Task<TResult>> WhenAnyCore<TResult> (IList<Task<TResult>> tasks)
+               {
+                       if (tasks.Count == 0)
+                               throw new ArgumentException ("The tasks argument contains no tasks", "tasks");
+
+                       int completed_index = -1;
+                       for (int i = 0; i < tasks.Count; ++i) {
+                               var t = tasks[i];
+                               if (t == null)
+                                       throw new ArgumentException ("tasks", "the tasks argument contains a null element");
+
+                               if (t.IsCompleted && completed_index < 0)
+                                       completed_index = i;
+                       }
+
+                       var task = new Task<Task<TResult>> (TaskActionInvoker.Empty, null, CancellationToken.None, TaskCreationOptions.None, null, TaskConstants.Finished);
+
+                       if (completed_index > 0) {
+                               task.TrySetResult (tasks[completed_index]);
+                               return task;
+                       }
+
+                       task.SetupScheduler (TaskScheduler.Current);
+
+                       var continuation = new WhenAnyContinuation<Task<TResult>> (task, tasks);
+                       foreach (var t in tasks)
+                               t.ContinueWith (continuation);
+
+                       return task;
+               }
+
                public static YieldAwaitable Yield ()
                {
                        return new YieldAwaitable ();
                }
 #endif
 
+               internal static Task WhenAllCore (IList<Task> tasks)
+               {
+                       bool all_completed = true;
+                       foreach (var t in tasks) {
+                               if (t == null)
+                                       throw new ArgumentException ("tasks", "the tasks argument contains a null element");
+
+                               all_completed &= t.Status == TaskStatus.RanToCompletion;
+                       }
+
+                       if (all_completed)
+                               return TaskConstants.Finished;
+
+                       var task = new Task (TaskActionInvoker.Empty, null, CancellationToken.None, TaskCreationOptions.None, null, TaskConstants.Finished);
+                       task.SetupScheduler (TaskScheduler.Current);
+
+                       var continuation = new WhenAllContinuation (task, tasks);
+                       foreach (var t in tasks)
+                               t.ContinueWith (continuation);
+
+                       return task;
+               }
+
+               internal static Task<Task> WhenAnyCore (IList<Task> tasks)
+               {
+                       if (tasks.Count == 0)
+                               throw new ArgumentException ("The tasks argument contains no tasks", "tasks");
+
+                       int completed_index = -1;
+                       for (int i = 0; i < tasks.Count; ++i) {
+                               var t = tasks [i];
+                               if (t == null)
+                                       throw new ArgumentException ("tasks", "the tasks argument contains a null element");
+
+                               if (t.IsCompleted && completed_index < 0)
+                                       completed_index = i;
+                       }
+
+                       var task = new Task<Task> (TaskActionInvoker.Empty, null, CancellationToken.None, TaskCreationOptions.None, null, TaskConstants.Finished);
+
+                       if (completed_index > 0) {
+                               task.TrySetResult (tasks[completed_index]);
+                               return task;
+                       }
+
+                       task.SetupScheduler (TaskScheduler.Current);
+
+                       var continuation = new WhenAnyContinuation<Task> (task, tasks);
+                       foreach (var t in tasks)
+                               t.ContinueWith (continuation);
+
+                       return task;
+               }
                #region Properties
+
+               internal CancellationToken CancellationToken {
+                       get {
+                               return token;
+                       }
+               }
+
                public static TaskFactory Factory {
                        get {
                                return defaultFactory;
index a6a47a41c17ddc3648bf0a5a46b198f7987c671f..40907671bffcd227ef2ca2bacbfc30117d7cffd9 100644 (file)
 
 #if NET_4_0 || MOBILE
 
+using System.Threading;
+
 namespace System.Threading.Tasks
 {
        abstract class TaskActionInvoker
        {
                public static readonly TaskActionInvoker Empty = new EmptyTaskActionInvoker ();
+               public static readonly TaskActionInvoker Delay = new DelayTaskInvoker ();
                
                sealed class EmptyTaskActionInvoker : TaskActionInvoker
                {
@@ -199,12 +202,10 @@ namespace System.Threading.Tasks
                sealed class ActionTaskSelected : TaskActionInvoker
                {
                        readonly Action<Task> action;
-                       readonly Task[] tasks;
 
-                       public ActionTaskSelected (Action<Task> action, Task[] tasks)
+                       public ActionTaskSelected (Action<Task> action)
                        {
                                this.action = action;
-                               this.tasks = tasks;
                        }
 
                        public override Delegate Action {
@@ -215,8 +216,7 @@ namespace System.Threading.Tasks
 
                        public override void Invoke (Task owner, object state, Task context)
                        {
-                               var result = ((Task<int>) owner).Result;
-                               action (tasks [result]);
+                               action (((Task<Task>)owner).Result);
                        }
                }
 
@@ -393,6 +393,22 @@ namespace System.Threading.Tasks
                        }
                }
 
+               sealed class DelayTaskInvoker : TaskActionInvoker
+               {
+                       public override Delegate Action {
+                               get {
+                                       return null;
+                               }
+                       }
+
+                       public override void Invoke (Task owner, object state, Task context)
+                       {
+                               var mre = new ManualResetEventSlim ();
+                               int timeout = (int) state;
+                               mre.Wait (timeout, context.CancellationToken);
+                       }
+               }
+
                public static TaskActionInvoker Create (Action action)
                {
                        return new ActionInvoke (action);
@@ -465,9 +481,9 @@ namespace System.Threading.Tasks
 
                #region Used by WhenAny
 
-               public static TaskActionInvoker Create (Action<Task> action, Task[] tasks)
+               public static TaskActionInvoker CreateSelected (Action<Task> action)
                {
-                       return new ActionTaskSelected (action, tasks);
+                       return new ActionTaskSelected (action);
                }
 
                public static TaskActionInvoker Create<TResult> (Func<Task, TResult> action, Task[] tasks)
index f7d3b7cdb16b592057791242ac1b7a7a5256c290..2a18adafda8c4e6e7cdc28d7ae8d5c3140b84eb0 100644 (file)
@@ -26,7 +26,7 @@
 //
 //
 
-#if NET_4_5
+#if NET_4_0 || MOBILE
 
 namespace System.Threading.Tasks
 {
index a65ecd0f9ce53da6a770fb2be668607666ef569e..ff13edd6942b64215ff4323656f9d137838f0356 100644 (file)
@@ -29,6 +29,8 @@
 
 #if NET_4_0 || MOBILE
 
+using System.Collections.Generic;
+
 namespace System.Threading.Tasks
 {
        interface IContinuation
@@ -97,6 +99,10 @@ namespace System.Threading.Tasks
                                return;
                        }
 
+                       // The task may have been canceled externally
+                       if (task.IsCompleted)
+                               return;
+
                        if ((continuationOptions & TaskContinuationOptions.ExecuteSynchronously) != 0)
                                task.RunSynchronously (task.scheduler);
                        else
@@ -135,6 +141,225 @@ namespace System.Threading.Tasks
                        ctx.Post (l => ((Action) l) (), action);
                }
        }
+
+       sealed class WhenAllContinuation : IContinuation
+       {
+               readonly Task owner;
+               readonly IList<Task> tasks;
+               int counter;
+
+               public WhenAllContinuation (Task owner, IList<Task> tasks)
+               {
+                       this.owner = owner;
+                       this.counter = tasks.Count;
+                       this.tasks = tasks;
+               }
+
+               public void Execute ()
+               {
+                       if (Interlocked.Decrement (ref counter) != 0)
+                               return;
+
+                       owner.Status = TaskStatus.Running;
+
+                       bool canceled = false;
+                       List<Exception> exceptions = null;
+                       foreach (var task in tasks) {
+                               if (task.IsFaulted) {
+                                       if (exceptions == null)
+                                               exceptions = new List<Exception> ();
+
+                                       exceptions.AddRange (task.Exception.InnerExceptions);
+                                       continue;
+                               }
+
+                               if (task.IsCanceled) {
+                                       canceled = true;
+                               }
+                       }
+
+                       if (exceptions != null) {
+                               owner.TrySetException (new AggregateException (exceptions));
+                               return;
+                       }
+
+                       if (canceled) {
+                               owner.CancelReal ();
+                               return;
+                       }
+
+                       owner.Finish ();
+               }
+       }
+
+       sealed class WhenAllContinuation<TResult> : IContinuation
+       {
+               readonly Task<TResult[]> owner;
+               readonly IList<Task<TResult>> tasks;
+               int counter;
+
+               public WhenAllContinuation (Task<TResult[]> owner, IList<Task<TResult>> tasks)
+               {
+                       this.owner = owner;
+                       this.counter = tasks.Count;
+                       this.tasks = tasks;
+               }
+
+               public void Execute ()
+               {
+                       if (Interlocked.Decrement (ref counter) != 0)
+                               return;
+
+                       bool canceled = false;
+                       List<Exception> exceptions = null;
+                       TResult[] results = null;
+                       for (int i = 0; i < tasks.Count; ++i) {
+                               var task = tasks [i];
+                               if (task.IsFaulted) {
+                                       if (exceptions == null)
+                                               exceptions = new List<Exception> ();
+
+                                       exceptions.AddRange (task.Exception.InnerExceptions);
+                                       continue;
+                               }
+
+                               if (task.IsCanceled) {
+                                       canceled = true;
+                                       continue;
+                               }
+
+                               if (results == null) {
+                                       if (canceled || exceptions != null)
+                                               continue;
+
+                                       results = new TResult[tasks.Count];
+                               }
+
+                               results[i] = task.Result;
+                       }
+
+                       if (exceptions != null) {
+                               owner.TrySetException (new AggregateException (exceptions));
+                               return;
+                       }
+
+                       if (canceled) {
+                               owner.CancelReal ();
+                               return;
+                       }
+
+                       owner.TrySetResult (results);
+               }
+       }
+
+       sealed class WhenAnyContinuation<T> : IContinuation where T : Task
+       {
+               readonly Task<T> owner;
+               readonly IList<T> tasks;
+               AtomicBooleanValue executed = new AtomicBooleanValue ();
+
+               public WhenAnyContinuation (Task<T> owner, IList<T> tasks)
+               {
+                       this.owner = owner;
+                       this.tasks = tasks;
+               }
+
+               public void Execute ()
+               {
+                       if (!executed.TryRelaxedSet ())
+                               return;
+
+                       for (int i = 0; i < tasks.Count; ++i) {
+                               var task = tasks[i];
+                               if (!task.IsCompleted)
+                                       continue;
+
+                               owner.TrySetResult (task);
+                               return;
+                       }
+               }
+       }
+
+       sealed class ManualResetContinuation : IContinuation, IDisposable
+       {
+               readonly ManualResetEventSlim evt;
+
+               public ManualResetContinuation ()
+               {
+                       this.evt = new ManualResetEventSlim ();
+               }
+
+               public ManualResetEventSlim Event {
+                       get {
+                               return evt;
+                       }
+               }
+
+               public void Dispose ()
+               {
+                       evt.Dispose ();
+               }
+
+               public void Execute ()
+               {
+                       evt.Set ();
+               }
+       }
+
+       sealed class DelayContinuation : IContinuation, IDisposable
+       {
+               readonly ManualResetEventSlim evt;
+
+               public DelayContinuation ()
+               {
+                       this.evt = new ManualResetEventSlim ();
+               }
+
+               public ManualResetEventSlim Event
+               {
+                       get
+                       {
+                               return evt;
+                       }
+               }
+
+               public void Dispose ()
+               {
+                       evt.Dispose ();
+               }
+
+               public void Execute ()
+               {
+                       Console.WriteLine ("execute");
+                       evt.Set ();
+               }
+       }
+
+       sealed class CountdownContinuation : IContinuation, IDisposable
+       {
+               readonly CountdownEvent evt;
+
+               public CountdownContinuation (int initialCount)
+               {
+                       this.evt = new CountdownEvent (initialCount);
+               }
+
+               public CountdownEvent Event {
+                       get {
+                               return evt;
+                       }
+               }
+
+               public void Dispose ()
+               {
+                       evt.Dispose ();
+               }
+
+               public void Execute ()
+               {
+                       evt.Signal ();
+               }
+       }
 }
 
 #endif
index 62b66ca66644a7750c425812fd83119a0bfa9d90..5f3dafab164a0dcdd1281799ca8f65659e838259 100644 (file)
@@ -240,28 +240,9 @@ namespace System.Threading.Tasks
 
                public Task ContinueWhenAny (Task[] tasks, Action<Task> continuationAction, CancellationToken cancellationToken, TaskContinuationOptions continuationOptions, TaskScheduler scheduler)
                {
-                       if (tasks == null)
-                               throw new ArgumentNullException ("tasks");
-
-                       if (tasks.Length == 0)
-                               throw new ArgumentException ("The tasks argument contains no tasks", "tasks");
+                       CheckContinueArguments (tasks, continuationAction, continuationOptions, scheduler);
 
-                       foreach (var ta in tasks) {
-                               if (ta == null)
-                                       throw new ArgumentException ("The tasks argument constains a null value", "tasks");
-                       }
-
-                       if (continuationAction == null)
-                               throw new ArgumentNullException ("continuationAction");
-
-                       var t = new Task<int> (l => {
-                               var data = (Tuple<Task[], CancellationToken>) l;
-                               return Task.WaitAny (data.Item1, data.Item2);
-                       }, Tuple.Create (tasks, cancellationToken));
-
-                       var cont = t.ContinueWith (TaskActionInvoker.Create (continuationAction, tasks), cancellationToken, continuationOptions, scheduler);
-
-                       t.Start (scheduler);
+                       var cont = Task.WhenAnyCore (tasks).ContinueWith (TaskActionInvoker.CreateSelected (continuationAction), cancellationToken, continuationOptions, scheduler);
 
                        return cont;
                }
@@ -322,14 +303,9 @@ namespace System.Threading.Tasks
                                                               TaskContinuationOptions continuationOptions,
                                                               TaskScheduler scheduler)
                {
-                       var t = new Task<int> (l => {
-                               var data = (Tuple<Task[], CancellationToken>) l;
-                               return Task.WaitAny (data.Item1, data.Item2);
-                       }, Tuple.Create (tasks, cancellationToken));
+                       CheckContinueArguments (tasks, continuationFunction, continuationOptions, scheduler);
 
-                       var cont = t.ContinueWith<TResult> (TaskActionInvoker.Create (continuationFunction, tasks), cancellationToken, continuationOptions, scheduler);
-
-                       t.Start (scheduler);
+                       var cont = Task.WhenAnyCore (tasks).ContinueWith<TResult> (TaskActionInvoker.Create (continuationFunction, tasks), cancellationToken, continuationOptions, scheduler);
 
                        return cont;
                }
@@ -386,14 +362,9 @@ namespace System.Threading.Tasks
                public Task ContinueWhenAll (Task[] tasks, Action<Task[]> continuationAction, CancellationToken cancellationToken,
                                             TaskContinuationOptions continuationOptions, TaskScheduler scheduler)
                {
-                       var t = new Task (l => {
-                               var data = (Tuple<Task[], CancellationToken>) l;
-                               Task.WaitAll (data.Item1, data.Item2);
-                       }, Tuple.Create (tasks, cancellationToken));
+                       CheckContinueArguments (tasks, continuationAction, continuationOptions, scheduler);
 
-                       var cont = t.ContinueWith (TaskActionInvoker.Create (continuationAction, tasks), cancellationToken, continuationOptions, scheduler);
-
-                       t.Start (scheduler);
+                       var cont = Task.WhenAllCore (tasks).ContinueWith (TaskActionInvoker.Create (continuationAction, tasks), cancellationToken, continuationOptions, scheduler);
 
                        return cont;
                }
@@ -446,14 +417,9 @@ namespace System.Threading.Tasks
                                                               CancellationToken cancellationToken,
                                                               TaskContinuationOptions continuationOptions, TaskScheduler scheduler)
                {
-                       var t = new Task (l => {
-                               var data = (Tuple<Task[], CancellationToken>) l;
-                               Task.WaitAll (data.Item1, data.Item2);
-                       }, Tuple.Create (tasks, cancellationToken));
+                       CheckContinueArguments (tasks, continuationFunction, continuationOptions, scheduler);
 
-                       var cont = t.ContinueWith<TResult> (TaskActionInvoker.Create (continuationFunction, tasks), cancellationToken, continuationOptions, scheduler);
-
-                       t.Start (scheduler);
+                       var cont = Task.WhenAllCore (tasks).ContinueWith<TResult> (TaskActionInvoker.Create (continuationFunction, tasks), cancellationToken, continuationOptions, scheduler);
 
                        return cont;
                }
@@ -656,6 +622,36 @@ namespace System.Threading.Tasks
                {
                        return scheduler ?? TaskScheduler.Current;
                }
+
+               static void CheckContinueArguments (Task[] tasks, object continuationAction, TaskContinuationOptions continuationOptions, TaskScheduler scheduler)
+               {
+                       if (tasks == null)
+                               throw new ArgumentNullException ("tasks");
+
+                       if (tasks.Length == 0)
+                               throw new ArgumentException ("The tasks argument contains no tasks", "tasks");
+
+                       foreach (var ta in tasks) {
+                               if (ta == null)
+                                       throw new ArgumentException ("The tasks argument contains a null value", "tasks");
+                       }
+
+                       if (continuationAction == null)
+                               throw new ArgumentNullException ("continuationAction");
+                       if (scheduler == null)
+                               throw new ArgumentNullException ("scheduler");
+
+                       const TaskContinuationOptions notAllowedOptions = 
+                               TaskContinuationOptions.NotOnRanToCompletion  |
+                               TaskContinuationOptions.NotOnFaulted |
+                               TaskContinuationOptions.NotOnCanceled |
+                               TaskContinuationOptions.OnlyOnRanToCompletion |
+                               TaskContinuationOptions.OnlyOnFaulted |
+                               TaskContinuationOptions.OnlyOnCanceled;
+
+                       if ((continuationOptions & notAllowedOptions) != 0)
+                               throw new ArgumentOutOfRangeException ("continuationOptions");
+               }
        }
 }
 #endif
index 64ae3f9bcdccf23617516b33d46635b2ae37c781..98c5c70327d4a7c445241686ceca3424880bfb25 100644 (file)
@@ -1,10 +1,12 @@
 // 
 // TaskScheduler.cs
 //  
-// Author:
+// Authors:
 //       Jérémie "Garuma" Laval <jeremie.laval@gmail.com>
+//       Marek Safar <marek.safar@gmail.com>
 // 
 // Copyright (c) 2009 Jérémie "Garuma" Laval
+// Copyright 2012 Xamarin, Inc (http://www.xamarin.com)
 // 
 // Permission is hereby granted, free of charge, to any person obtaining a copy
 // of this software and associated documentation files (the "Software"), to deal
 // THE SOFTWARE.
 
 #if NET_4_0 || MOBILE
-using System;
-using System.Threading;
+
 using System.Collections.Generic;
+using System.Diagnostics;
 
 namespace System.Threading.Tasks
 {
-       [System.Diagnostics.DebuggerDisplay ("Id={Id}")]
-       [System.Diagnostics.DebuggerTypeProxy ("System.Threading.Tasks.TaskScheduler+SystemThreadingTasks_TaskSchedulerDebugView")]
+       [DebuggerDisplay ("Id={Id}")]
+       [DebuggerTypeProxy (typeof (TaskSchedulerDebuggerView))]
        public abstract class TaskScheduler
        {
-               static TaskScheduler defaultScheduler = new TpScheduler ();
+               sealed class TaskSchedulerDebuggerView
+               {
+                       readonly TaskScheduler scheduler;
+
+                       public TaskSchedulerDebuggerView (TaskScheduler scheduler)
+                       {
+                               this.scheduler = scheduler;
+                       }
+
+                       public IEnumerable<Task> ScheduledTasks {
+                               get {
+                                       return scheduler.GetScheduledTasks ();
+                               }
+                       }
+               }
+
+               static readonly TaskScheduler defaultScheduler = new TpScheduler ();
                
                [ThreadStatic]
                static TaskScheduler currentScheduler;
@@ -53,6 +71,9 @@ namespace System.Threading.Tasks
                public static TaskScheduler FromCurrentSynchronizationContext ()
                {
                        var syncCtx = SynchronizationContext.Current;
+                       if (syncCtx == null)
+                               throw new InvalidOperationException ("The current SynchronizationContext is null and cannot be used as a TaskScheduler");
+
                        return new SynchronizationContextScheduler (syncCtx);
                }
                
@@ -88,9 +109,10 @@ namespace System.Threading.Tasks
 
                protected abstract IEnumerable<Task> GetScheduledTasks ();
                protected internal abstract void QueueTask (Task task);
+
                protected internal virtual bool TryDequeue (Task task)
                {
-                       throw new NotSupportedException ();
+                       return false;
                }
 
                internal protected bool TryExecuteTask (Task task)
@@ -100,7 +122,8 @@ namespace System.Threading.Tasks
 
                        if (task.Status == TaskStatus.WaitingToRun) {
                                task.Execute ();
-                               task.WaitOnChildren ();
+                               if (task.WaitOnChildren ())
+                                       task.Wait ();
 
                                return true;
                        }
@@ -117,6 +140,7 @@ namespace System.Threading.Tasks
 
                        if (!task.IsCompleted)
                                throw new InvalidOperationException ("The TryExecuteTaskInline call to the underlying scheduler succeeded, but the task body was not invoked");
+
                        return true;
                }
 
index 43414efbce4753fcc50aacaa982793584df80bbc..f02f17bf9d0f4938717ac7103f789e93d2801627 100644 (file)
@@ -91,7 +91,7 @@ namespace System.Threading.Tasks
                }
                
                public Task (Func<TResult> function, CancellationToken cancellationToken, TaskCreationOptions creationOptions)
-                       : base (TaskActionInvoker.Create (function), null, cancellationToken, creationOptions, null)
+                       : base (TaskActionInvoker.Create (function), null, cancellationToken, creationOptions)
                {
                        if (function == null)
                                throw new ArgumentNullException ("function");
@@ -116,7 +116,7 @@ namespace System.Threading.Tasks
                }
 
                public Task (Func<object, TResult> function, object state, CancellationToken cancellationToken, TaskCreationOptions creationOptions)
-                       : base (TaskActionInvoker.Create (function), state, cancellationToken, creationOptions, null)
+                       : base (TaskActionInvoker.Create (function), state, cancellationToken, creationOptions)
                {
                        if (function == null)
                                throw new ArgumentNullException ("function");
@@ -159,7 +159,7 @@ namespace System.Threading.Tasks
                                           null,
                                           cancellationToken,
                                           GetCreationOptions (continuationOptions),
-                                          parent,
+                                          null,
                                           this);
                        ContinueWithCore (t, continuationOptions, scheduler);
                        
@@ -200,7 +200,7 @@ namespace System.Threading.Tasks
                                                      null,
                                                      cancellationToken,
                                                      GetCreationOptions (continuationOptions),
-                                                     parent,
+                                                     null,
                                                      this);
                        ContinueWithCore (t, continuationOptions, scheduler);
                        
@@ -264,7 +264,7 @@ namespace System.Threading.Tasks
                                          state,
                                          cancellationToken,
                                          GetCreationOptions (continuationOptions),
-                                         parent,
+                                         null,
                                          this);
 
                        ContinueWithCore (t, continuationOptions, scheduler);
@@ -306,7 +306,7 @@ namespace System.Threading.Tasks
                                                      state,
                                                      cancellationToken,
                                                      GetCreationOptions (continuationOptions),
-                                                     parent,
+                                                     null,
                                                      this);
 
                        ContinueWithCore (t, continuationOptions, scheduler);
index 0b1788c09a93d68f42b3f60b19c62e617f2a5570..95df5a5b16d9c5ecb60a902cff983f002671a35f 100644 (file)
@@ -1,6 +1,13 @@
+//
 // TpScheduler.cs
 //
+// Authors:
+//    Jérémie Laval <jeremie dot laval at xamarin dot com>
+//    Marek Safar  <marek.safar@gmail.com>
+//
 // Copyright (c) 2011 Jérémie "Garuma" Laval
+// Copyright 2012 Xamarin Inc (http://www.xamarin.com).
+//
 //
 // Permission is hereby granted, free of charge, to any person obtaining a copy
 // of this software and associated documentation files (the "Software"), to deal
 //
 
 #if NET_4_0 || MOBILE
-using System;
-using System.Collections.Concurrent;
 
 namespace System.Threading.Tasks
 {
-       internal class TpScheduler: TaskScheduler
+       sealed class TpScheduler: TaskScheduler
        {
                static readonly WaitCallback callback = TaskExecuterCallback;
 
                protected internal override void QueueTask (Task task)
                {
+                       if ((task.CreationOptions & TaskCreationOptions.LongRunning) != 0) {
+                               var thread = new Thread (l => ((Task)l).Execute ()) {
+                                       IsBackground = true
+                               };
+
+                               thread.Start (task);
+                               return;
+                       }
+
                        ThreadPool.UnsafeQueueUserWorkItem (callback, task);
                }
 
@@ -57,12 +71,6 @@ namespace System.Threading.Tasks
                {
                    return TryExecuteTask(task);
                }
-
-               public override int MaximumConcurrencyLevel {
-                       get {
-                               return base.MaximumConcurrencyLevel;
-                       }
-               }
        }
 }
 #endif
index 96f298de0d0c5f6c19b6cf050565dd9b4b449e52..f89329067c36cb69f94660d204d84e831e9ad02a 100644 (file)
@@ -40,14 +40,12 @@ namespace System.Threading
                        this.id = id;
                        this.source = source;
                }
-               
+
                #region IDisposable implementation
                public void Dispose ()
                {
-                       // Remove the corresponding callback from source
                        source.RemoveCallback (this);
                }
-
                #endregion
 
                #region IEquatable<CancellationTokenRegistration> implementation
@@ -76,7 +74,6 @@ namespace System.Threading
                {
                        return (obj is CancellationTokenRegistration) ? Equals ((CancellationTokenRegistration)obj) : false;
                }
-
        }
 }
 #endif
index 76503e7dc5f3abd780145e24c13c6dff7cc0ecb0..fa9674e06f1b790ee30f962fd1e1736d350335e7 100644 (file)
@@ -28,6 +28,7 @@
 
 #if NET_4_0 || MOBILE
 using System.Collections.Generic;
+using System.Collections.Concurrent;
 
 namespace System.Threading
 {
@@ -37,15 +38,12 @@ namespace System.Threading
        public class CancellationTokenSource : IDisposable
        {
                bool canceled;
-               bool processed;
                bool disposed;
                
                int currId = int.MinValue;
+               ConcurrentDictionary<CancellationTokenRegistration, Action> callbacks;
 
-               Dictionary<CancellationTokenRegistration, Action> callbacks;
-               
                ManualResetEvent handle;
-               readonly object syncRoot = new object ();
                
                internal static readonly CancellationTokenSource NoneSource = new CancellationTokenSource ();
                internal static readonly CancellationTokenSource CanceledSource = new CancellationTokenSource ();
@@ -57,7 +55,6 @@ namespace System.Threading
 
                static CancellationTokenSource ()
                {
-                       CanceledSource.processed = true;
                        CanceledSource.canceled = true;
 
 #if NET_4_5
@@ -70,7 +67,7 @@ namespace System.Threading
 
                public CancellationTokenSource ()
                {
-                       callbacks = new Dictionary<CancellationTokenRegistration, Action> ();
+                       callbacks = new ConcurrentDictionary<CancellationTokenRegistration, Action> ();
                        handle = new ManualResetEvent (false);
                }
 
@@ -126,30 +123,31 @@ namespace System.Threading
                        
                        List<Exception> exceptions = null;
                        
-                       lock (syncRoot) {
-                               try {
-                                       foreach (var item in callbacks) {
-                                               if (throwOnFirstException) {
-                                                       item.Value ();
-                                               } else {
-                                                       try {
-                                                               item.Value ();
-                                                       } catch (Exception e) {
-                                                               if (exceptions == null)
-                                                                       exceptions = new List<Exception> ();
-
-                                                               exceptions.Add (e);
-                                                       }
+                       try {
+                               Action cb;
+                               for (int id = int.MinValue + 1; id <= currId; id++) {
+                                       if (!callbacks.TryRemove (new CancellationTokenRegistration (id, this), out cb))
+                                               continue;
+                                       if (cb == null)
+                                               continue;
+
+                                       if (throwOnFirstException) {
+                                               cb ();
+                                       } else {
+                                               try {
+                                                       cb ();
+                                               } catch (Exception e) {
+                                                       if (exceptions == null)
+                                                               exceptions = new List<Exception> ();
+
+                                                       exceptions.Add (e);
                                                }
                                        }
-                               } finally {
-                                       callbacks.Clear ();
                                }
+                       } finally {
+                               callbacks.Clear ();
                        }
-                       
-                       Thread.MemoryBarrier ();
-                       processed = true;
-                       
+
                        if (exceptions != null)
                                throw new AggregateException (exceptions);
                }
@@ -232,6 +230,7 @@ namespace System.Threading
                {
                        if (disposing && !disposed) {
                                disposed = true;
+                               Thread.MemoryBarrier ();
 
                                callbacks = null;
 #if NET_4_5
@@ -248,36 +247,30 @@ namespace System.Threading
 
                        var tokenReg = new CancellationTokenRegistration (Interlocked.Increment (ref currId), this);
 
-                       if (canceled) {
+                       /* If the source is already canceled we execute the callback immediately
+                        * if not, we try to add it to the queue and if it is currently being processed
+                        * we try to execute it back ourselves to be sure the callback is ran
+                        */
+                       if (canceled)
                                callback ();
-                       } else {
-                               bool temp = false;
-                               lock (syncRoot) {
-                                       if (!(temp = canceled))
-                                               callbacks.Add (tokenReg, callback);
-                               }
-                               if (temp)
+                       else {
+                               callbacks.TryAdd (tokenReg, callback);
+                               if (canceled && callbacks.TryRemove (tokenReg, out callback))
                                        callback ();
                        }
                        
                        return tokenReg;
                }
-               
-               internal void RemoveCallback (CancellationTokenRegistration tokenReg)
+
+               internal void RemoveCallback (CancellationTokenRegistration reg)
                {
-                       if (!canceled) {
-                               lock (syncRoot) {
-                                       if (!canceled) {
-                                               callbacks.Remove (tokenReg);
-                                               return;
-                                       }
-                               }
-                       }
-                       
-                       SpinWait sw = new SpinWait ();
-                       while (!processed)
-                               sw.SpinOnce ();
-                       
+                       // Ignore call if the source has been disposed
+                       if (disposed)
+                               return;
+                       Action dummy;
+                       var cbs = callbacks;
+                       if (cbs != null)
+                               cbs.TryRemove (reg, out dummy);
                }
        }
 }
index e6bf04ab9208caf37eeab25c234734d8f5e44101..0ebe4bb1e837202c13945d0d03476a683757be3d 100644 (file)
@@ -37,8 +37,8 @@ namespace System.Threading
 
                ManualResetEvent handle;
                internal AtomicBooleanValue disposed;
-               bool used;
-               bool set;
+               int used;
+               long state;
 
                public ManualResetEventSlim ()
                        : this (false, 10)
@@ -55,13 +55,13 @@ namespace System.Threading
                        if (spinCount < 0 || spinCount > 2047)
                                throw new ArgumentOutOfRangeException ("spinCount");
 
-                       this.set = initialState;
+                       this.state = initialState ? 1 : 0;
                        this.spinCount = spinCount;
                }
 
                public bool IsSet {
                        get {
-                               return set;
+                               return (state & 1) == 1;
                        }
                }
 
@@ -75,32 +75,62 @@ namespace System.Threading
                {
                        ThrowIfDisposed ();
 
-                       set = false;
-                       Thread.MemoryBarrier ();
-                       if (handle != null) {
-                               used = true;
-                               Thread.MemoryBarrier ();
-                               var tmpHandle = handle;
-                               if (tmpHandle != null)
-                                       tmpHandle.Reset ();
-                               Thread.MemoryBarrier ();
-                               used = false;
-                       }
+                       var stamp = UpdateStateWithOp (false);
+                       if (handle != null)
+                               CommitChangeToHandle (stamp);
                }
 
                public void Set ()
                {
-                       set = true;
-                       Thread.MemoryBarrier ();
-                       if (handle != null) {
-                               used = true;
-                               Thread.MemoryBarrier ();
-                               var tmpHandle = handle;
-                               if (tmpHandle != null)
+                       var stamp = UpdateStateWithOp (true);
+                       if (handle != null)
+                               CommitChangeToHandle (stamp);
+               }
+
+               long UpdateStateWithOp (bool set)
+               {
+                       long oldValue, newValue;
+                       do {
+                               oldValue = state;
+                               newValue = (long)(((oldValue >> 1) + 1) << 1) | (set ? 1u : 0u);
+                       } while (Interlocked.CompareExchange (ref state, newValue, oldValue) != oldValue);
+                       return newValue;
+               }
+
+               void CommitChangeToHandle (long stamp)
+               {
+                       Interlocked.Increment (ref used);
+                       var tmpHandle = handle;
+                       if (tmpHandle != null) {
+                               // First in all case we carry the operation we were called for
+                               if ((stamp & 1) == 1)
                                        tmpHandle.Set ();
-                               Thread.MemoryBarrier ();
-                               used = false;
+                               else
+                                       tmpHandle.Reset ();
+
+                               /* Then what may happen is that the two suboperations (state change and handle change)
+                                * overlapped with others. In our case it doesn't matter if the two suboperations aren't
+                                * executed together at the same time, the only thing we have to make sure of is that both
+                                * state and handle are synchronized on the last visible state change.
+                                *
+                                * For instance if S is state change and H is handle change, for 3 concurrent operations
+                                * we may have the following serialized timeline: S1 S2 H2 S3 H3 H1
+                                * Which is perfectly fine (all S were converted to H at some stage) but in that case
+                                * we have a mismatch between S and H at the end because the last operations done were
+                                * S3/H1. We thus need to repeat H3 to get to the desired final state.
+                                */
+                               long currentState;
+                               do {
+                                       currentState = state;
+                                       if (currentState != stamp && (stamp & 1) != (currentState & 1)) {
+                                               if ((currentState & 1) == 1)
+                                                       tmpHandle.Set ();
+                                               else
+                                                       tmpHandle.Reset ();
+                                       }
+                               } while (currentState != state);
                        }
+                       Interlocked.Decrement (ref used);
                }
 
                public void Wait ()
@@ -130,10 +160,10 @@ namespace System.Threading
 
                        ThrowIfDisposed ();
 
-                       if (!set) {
+                       if (!IsSet) {
                                SpinWait wait = new SpinWait ();
 
-                               while (!set) {
+                               while (!IsSet) {
                                        cancellationToken.ThrowIfCancellationRequested ();
 
                                        if (wait.Count < spinCount) {
@@ -144,16 +174,17 @@ namespace System.Threading
                                        break;
                                }
 
-                               if (set)
+                               if (IsSet)
                                        return true;
 
                                WaitHandle handle = WaitHandle;
 
                                if (cancellationToken.CanBeCanceled) {
-                                       if (WaitHandle.WaitAny (new[] { handle, cancellationToken.WaitHandle }, millisecondsTimeout, false) == 0)
+                                       var result = WaitHandle.WaitAny (new[] { handle, cancellationToken.WaitHandle }, millisecondsTimeout, false);
+                                       if (result == 1)
+                                               throw new OperationCanceledException (cancellationToken);
+                                       if (result == WaitHandle.WaitTimeout)
                                                return false;
-
-                                       cancellationToken.ThrowIfCancellationRequested ();
                                } else {
                                        if (!handle.WaitOne (millisecondsTimeout, false))
                                                return false;
@@ -175,14 +206,14 @@ namespace System.Threading
                                if (handle != null)
                                        return handle;
 
-                               var isSet = set;
-                               var mre = new ManualResetEvent (isSet);
+                               var isSet = IsSet;
+                               var mre = new ManualResetEvent (IsSet);
                                if (Interlocked.CompareExchange (ref handle, mre, null) == null) {
                                        //
                                        // Ensure the Set has not ran meantime
                                        //
-                                       if (isSet != set) {
-                                               if (set) {
+                                       if (isSet != IsSet) {
+                                               if (IsSet) {
                                                        mre.Set ();
                                                } else {
                                                        mre.Reset ();
@@ -211,10 +242,10 @@ namespace System.Threading
 
                        if (handle != null) {
                                var tmpHandle = Interlocked.Exchange (ref handle, null);
-                               if (used) {
+                               if (used > 0) {
                                        // A tiny wait (just a few cycles normally) before releasing
                                        SpinWait wait = new SpinWait ();
-                                       while (used)
+                                       while (used > 0)
                                                wait.SpinOnce ();
                                }
                                tmpHandle.Dispose ();
index b433e4ca8e96b74d8481bba7e5e9e962c3ec7959..857197bda425b584deee603207558872470ab5e7 100644 (file)
@@ -474,6 +474,11 @@ namespace System.Threading {
                private Thread (InternalThread it) {
                        internal_thread = it;
                }
+               
+               // part of ".NETPortable,Version=v4.0,Profile=Profile3" i.e. FX4 and SL4
+               ~Thread ()
+               {
+               }
 
 #if !MOONLIGHT
                [Obsolete ("Deprecated in favor of GetApartmentState, SetApartmentState and TrySetApartmentState.")]
index d46f0a1f8beb0d6f2824939999401309c8d7d981..febaf23e4afaafa3d1bd89dcbd5f31e26f054208 100644 (file)
@@ -190,6 +190,7 @@ namespace System {
                                dfi = inv;
 
                        int i = 0;
+                       bool saw_day_specifier = false;
 
                        while (i < format.Length) {
                                int tokLen;
@@ -320,6 +321,7 @@ namespace System {
                                        else
                                                result.Append (dfi.GetDayName (dfi.Calendar.GetDayOfWeek (dt)));
 
+                                       saw_day_specifier = true;
                                        break;
                                case 'M':
                                        // Month.m(m?) = month # (with leading 0 if two mm)
@@ -331,8 +333,11 @@ namespace System {
                                                DateTimeUtils.ZeroPad (result, month, tokLen);
                                        else if (tokLen == 3)
                                                result.Append (dfi.GetAbbreviatedMonthName (month));
-                                       else
-                                               result.Append (dfi.GetMonthName (month));
+                                       else {
+                                               // NOTE: .NET ignores quoted 'd' and reads it as day specifier but I think 
+                                               // that's wrong
+                                               result.Append (saw_day_specifier ? dfi.GetMonthGenitiveName (month) : dfi.GetMonthName (month));
+                                       }
 
                                        break;
                                case 'y':
index 585e4d09ff9ad6bad566239d873a2e72145d01a4..ab166fc24a59c7c93bcd55f086fbc89d2ec8c420 100644 (file)
@@ -55,7 +55,7 @@ namespace System {
                 * of icalls, do not require an increment.
                 */
 #pragma warning disable 169
-               private const int mono_corlib_version = 100;
+               private const int mono_corlib_version = 101;
 #pragma warning restore 169
 
                [ComVisible (true)]
index 15562c3743bf10f546a5539e215fd4ff2cae2941..6427c28e75a688ca3cec922f446d4007f1c13888 100644 (file)
@@ -5,9 +5,11 @@
 //     Duco Fijma (duco@lorentz.xs4all.nl)
 //     Sebastien Pouliot (sebastien@ximian.com)
 //     Jb Evain (jbevain@novell.com)
+//     Marek Safar (marek.safar@gmail.com)
 //
 // (C) 2002 Duco Fijma
 // Copyright (C) 2004-2010 Novell, Inc (http://www.novell.com)
+// Copyright 2012 Xamarin, Inc (http://www.xamarin.com)
 //
 // References
 // 1.  UUIDs and GUIDs (DRAFT), Section 3.4
@@ -93,7 +95,7 @@ namespace System {
                                get { return _cur >= _length; }
                        }
 
-                       static bool HasHyphen (Format format)
+                       public static bool HasHyphen (Format format)
                        {
                                switch (format) {
                                case Format.D:
@@ -372,12 +374,7 @@ namespace System {
 
                private static int Compare (int x, int y)
                {
-                       if (x < y) {
-                               return -1;
-                       }
-                       else {
-                               return 1;
-                       }
+                       return ((uint)x < (uint)y) ? -1 : 1;
                }
 
                public int CompareTo (object value)
@@ -405,34 +402,34 @@ namespace System {
                        if (_a != value._a) {
                                return Compare (_a, value._a);
                        }
-                       else if (_b != value._b) {
+                       if (_b != value._b) {
                                return Compare (_b, value._b);
                        }
-                       else if (_c != value._c) {
+                       if (_c != value._c) {
                                return Compare (_c, value._c);
                        }
-                       else if (_d != value._d) {
+                       if (_d != value._d) {
                                return Compare (_d, value._d);
                        }
-                       else if (_e != value._e) {
+                       if (_e != value._e) {
                                return Compare (_e, value._e);
                        }
-                       else if (_f != value._f) {
+                       if (_f != value._f) {
                                return Compare (_f, value._f);
                        }
-                       else if (_g != value._g) {
+                       if (_g != value._g) {
                                return Compare (_g, value._g);
                        }
-                       else if (_h != value._h) {
+                       if (_h != value._h) {
                                return Compare (_h, value._h);
                        }
-                       else if (_i != value._i) {
+                       if (_i != value._i) {
                                return Compare (_i, value._i);
                        }
-                       else if (_j != value._j) {
+                       if (_j != value._j) {
                                return Compare (_j, value._j);
                        }
-                       else if (_k != value._k) {
+                       if (_k != value._k) {
                                return Compare (_k, value._k);
                        }
                        return 0;
@@ -573,48 +570,95 @@ namespace System {
                        builder.Append (ToHex (value & 0xf));
                }
 
-               private string BaseToString (bool h, bool p, bool b)
+               string ToString (Format format)
                {
-                       StringBuilder res = new StringBuilder (40);
+                       int length;
+                       switch (format) {
+                       case Format.B:
+                       case Format.P:
+                               length = 38;
+                               break;
+                       case Format.D:
+                               length = 36;
+                               break;
+                       case Format.N:
+                               length = 32;
+                               break;
+                       case Format.X:
+                               length = 68;
+                               break;          
+                       default:
+                               throw new NotImplementedException (format.ToString ());
+                       }
+                       
+                       StringBuilder res = new StringBuilder (length);
+                       bool has_hyphen = GuidParser.HasHyphen (format);
                        
-                       if (p) {
+                       if (format == Format.P) {
                                res.Append ('(');
-                       } else if (b) {
+                       } else if (format == Format.B) {
                                res.Append ('{');
+                       } else if (format == Format.X) {
+                               res.Append ('{').Append ('0').Append ('x');
                        }
                
                        AppendInt (res, _a);
-                       if (h) {
+                       if (has_hyphen) {
                                res.Append ('-');
+                       } else if (format == Format.X) {
+                               res.Append (',').Append ('0').Append ('x');
                        }
+                       
                        AppendShort (res, _b);
-                       if (h) {
+                       if (has_hyphen) {
                                res.Append ('-');
+                       } else if (format == Format.X) {
+                               res.Append (',').Append ('0').Append ('x');
                        }
+
                        AppendShort (res, _c);
-                       if (h) {
+                       if (has_hyphen) {
                                res.Append ('-');
                        }
        
-                       AppendByte (res, _d);
-                       AppendByte (res, _e);
-
-                       if (h) {
-                               res.Append ('-');
-                       }
-
-                       AppendByte (res, _f);
-                       AppendByte (res, _g);
-                       AppendByte (res, _h);
-                       AppendByte (res, _i);
-                       AppendByte (res, _j);
-                       AppendByte (res, _k);
-
+                       if (format == Format.X) {
+                               res.Append (',').Append ('{').Append ('0').Append ('x');
+                               AppendByte (res, _d);
+                               res.Append (',').Append ('0').Append ('x');
+                               AppendByte (res, _e);
+                               res.Append (',').Append ('0').Append ('x');
+                               AppendByte (res, _f);
+                               res.Append (',').Append ('0').Append ('x');
+                               AppendByte (res, _g);
+                               res.Append (',').Append ('0').Append ('x');
+                               AppendByte (res, _h);
+                               res.Append (',').Append ('0').Append ('x');
+                               AppendByte (res, _i);
+                               res.Append (',').Append ('0').Append ('x');
+                               AppendByte (res, _j);
+                               res.Append (',').Append ('0').Append ('x');
+                               AppendByte (res, _k);
+                               res.Append ('}').Append ('}');;
+                       } else {
+                               AppendByte (res, _d);
+                               AppendByte (res, _e);
+       
+                               if (has_hyphen) {
+                                       res.Append ('-');
+                               }
+       
+                               AppendByte (res, _f);
+                               AppendByte (res, _g);
+                               AppendByte (res, _h);
+                               AppendByte (res, _i);
+                               AppendByte (res, _j);
+                               AppendByte (res, _k);
        
-                       if (p) {
-                               res.Append (')');
-                       } else if (b) {
-                               res.Append ('}');
+                               if (format == Format.P) {
+                                       res.Append (')');
+                               } else if (format == Format.B) {
+                                       res.Append ('}');
+                               }
                        }
                
                        return res.ToString ();
@@ -622,36 +666,15 @@ namespace System {
        
                public override string ToString ()
                {
-                       return BaseToString (true, false, false);
+                       return ToString (Format.D);
                }
        
                public string ToString (string format)
                {
-                       bool h = true;
-                       bool p = false;
-                       bool b = false;
-       
-                       if (format != null) {
-                               string f = format.ToLowerInvariant();
-       
-                               if (f == "b") {
-                                       b = true;
-                               }
-                               else if (f == "p") {
-                                       p = true;
-                               }
-                               else if (f == "n") {
-                                       h = false;
-                               }
-                               else if (f != "d" && f != String.Empty) {
-                                       throw new FormatException (Locale.GetText (
-                                               "Argument to Guid.ToString(string format) should be \"b\", \"B\", \"d\", \"D\", \"n\", \"N\", \"p\" or \"P\""));
-                               }
-                       }
-
-                       return BaseToString (h, p, b);
+                       return ToString (ParseFormat (format));
                }
 
+               // provider value is never used
                public string ToString (string format, IFormatProvider provider)
                {
                        return ToString (format);
@@ -705,27 +728,40 @@ namespace System {
                        var parser = new GuidParser (input);
                        return parser.Parse (ParseFormat (format), out result);
                }
+#endif
 
                static Format ParseFormat (string format)
                {
-                       if (format.Length != 1)
-                               throw new ArgumentException ("Wrong format");
-
+                       if (string.IsNullOrEmpty (format))
+                               return Format.D;
+                       
                        switch (format [0]) {
                        case 'N':
+                       case 'n':
                                return Format.N;
                        case 'D':
+                       case 'd':
                                return Format.D;
                        case 'B':
+                       case 'b':
                                return Format.B;
                        case 'P':
+                       case 'p':
                                return Format.P;
+#if NET_4_0 || MOONLIGHT || MOBILE
                        case 'X':
+                       case 'x':
                                return Format.X;
+#endif
                        }
 
-                       throw new ArgumentException ("Wrong format");
-               }
+                       throw new FormatException (
+#if NET_4_0 || MOONLIGHT || MOBILE
+                               "Format String can be only one of \"D\", \"d\", \"N\", \"n\", \"P\", \"p\", \"B\", \"b\", \"X\" or \"x\""
+#else
+                               "Format String can be only one of \"D\", \"d\", \"N\", \"n\", \"P\", \"p\", \"B\" or \"b\""
 #endif
+                               );
+               }
        }
 }
index eebaaef8bc6f0dbd0b1c921ac2deac3519216ba1..13e1e5270db545a275c9b5f4f777e049bfc8edfd 100644 (file)
@@ -278,15 +278,14 @@ namespace System {
                internal static bool FindExponent (ref int pos, string s, ref int exponent, bool tryParse, ref Exception exc)
                {
                                exponent = 0;
-                               long exp = 0; // temp long value
 
-                               int i = s.IndexOfAny(new char [] {'e', 'E'}, pos);
-                               if (i < 0) {
+                               if (pos >= s.Length || (s [pos] != 'e' && s[pos] != 'E')) {
                                        exc = null;
                                        return false;
                                }
 
-                               if (++i == s.Length) {
+                               var i = pos + 1;
+                               if (i == s.Length) {
                                        exc = tryParse ? null : GetFormatException ();
                                        return true;
                                }
@@ -302,6 +301,7 @@ namespace System {
                                        return true;
                                }
 
+                               long exp = 0; // temp long value
                                for (; i < s.Length; i++) {
                                        if (!Char.IsDigit (s [i]))  {
                                                exc = tryParse ? null : GetFormatException ();
index 2e7256dd6d6648eac2e61db57f65f7aa7197202a..1ab450e1c47e01aec936ae25491384e45c2168d5 100644 (file)
@@ -337,7 +337,7 @@ namespace System
                                        char* src_ptr = src;
                                        int len = Length;
 
-                                       do {
+                                       while (len > 0) {
                                                if (char.IsWhiteSpace (*src_ptr++)) {
                                                        if (split_points == null) {
                                                                split_points = new int[8];
@@ -349,7 +349,8 @@ namespace System
                                                        if (total_points == count && !removeEmpty)
                                                                break;
                                                }
-                                       } while (len-- != 0);
+                                               --len;
+                                       }
                                }
                        } else {
                                fixed (char* src = this) {
@@ -357,7 +358,7 @@ namespace System
                                                char* src_ptr = src;
                                                char* sep_ptr_end = sep_src + sep.Length;
                                                int len = Length;
-                                               do {
+                                               while (len > 0) {
                                                        char* sep_ptr = sep_src;
                                                        do {
                                                                if (*sep_ptr++ == *src_ptr) {
@@ -376,7 +377,8 @@ namespace System
                                                        } while (sep_ptr != sep_ptr_end);
 
                                                        ++src_ptr;
-                                               } while (len-- != 0);
+                                                       --len;
+                                               }
                                        }
                                }
                        }
index cb7caeff3f87218bf1e8e17f0685ff05a3bf41e7..e0203f9a65ced062d2302178254a0db488672f3c 100644 (file)
@@ -131,7 +131,7 @@ namespace System
                        if (time.Kind == DateTimeKind.Local)
                                return time;
 
-                       TimeSpan utcOffset = GetUtcOffset (time);
+                       TimeSpan utcOffset = GetUtcOffset (new DateTime (time.Ticks));
                        if (utcOffset.Ticks > 0) {
                                if (DateTime.MaxValue - utcOffset < time)
                                        return DateTime.SpecifyKind (DateTime.MaxValue, DateTimeKind.Local);
@@ -140,7 +140,7 @@ namespace System
                                        return DateTime.SpecifyKind (DateTime.MinValue, DateTimeKind.Local);
                        }
 
-                       DateTime local = time.Add (utcOffset);
+                       DateTime local = DateTime.SpecifyKind (time.Add (utcOffset), DateTimeKind.Local);
                        DaylightTime dlt = GetDaylightChanges (time.Year);
                        if (dlt.Delta.Ticks == 0)
                                return DateTime.SpecifyKind (local, DateTimeKind.Local);
@@ -354,6 +354,9 @@ namespace System
 
                public override TimeSpan GetUtcOffset (DateTime time)
                {
+                       if (time.Kind == DateTimeKind.Utc)
+                               return TimeSpan.Zero;
+
                        if (IsDaylightSavingTime (time))
                                return utcOffsetWithDLS;
 
index 91360a9c218db82906c7a23738cebee7bd955614..be73062900224765b90a0b3a58279a0aa14c8edf 100644 (file)
@@ -99,6 +99,8 @@ namespace System
                        // Guard multiple invocation.
                        if (iunknown != IntPtr.Zero)
                                return;
+
+                       System.Runtime.CompilerServices.RuntimeHelpers.RunClassConstructor (t.TypeHandle);
                        
                        ObjectCreationDelegate ocd = ExtensibleClassFactory.GetObjectCreationCallback (t);
                        if (ocd != null) {
index 91d5c35cef02c353ccd77279104d036c00d630fb..f4808192d03cfbf59d0f35e9fb87b55e3447701f 100644 (file)
@@ -189,6 +189,76 @@ namespace MonoTests.System.Collections.Concurrent
                        }
                        Assert.IsTrue(s == "9876543210", "#1 : " + s);
                }
+
+               [Test]
+               public void TryPopRangeTest ()
+               {
+                       int[] values = new int[3];
+                       Assert.AreEqual (3, stack.TryPopRange (values));
+                       CollectionAssert.AreEquivalent (new int[] { 9, 8, 7 }, values);
+                       Assert.AreEqual (10 - values.Length, stack.Count);
+                       for (int i = 9 - values.Length; i >= 0; i--) {
+                               int outValue;
+                               Assert.IsTrue (stack.TryPop (out outValue));
+                               Assert.AreEqual (i, outValue);
+                       }
+               }
+
+               [Test]
+               public void TryPopRangeTestWithOneElement ()
+               {
+                       int[] values = new int[1];
+                       Assert.AreEqual (1, stack.TryPopRange (values));
+                       CollectionAssert.AreEquivalent (new int[] { 9 }, values);
+                       Assert.AreEqual (10 - values.Length, stack.Count);
+                       for (int i = 9 - values.Length; i >= 0; i--) {
+                               int outValue;
+                               Assert.IsTrue (stack.TryPop (out outValue));
+                               Assert.AreEqual (i, outValue);
+                       }
+               }
+
+               [Test]
+               public void TryPopRangeFullTest ()
+               {
+                       int[] values = new int[10];
+                       Assert.AreEqual (10, stack.TryPopRange (values));
+                       CollectionAssert.AreEquivalent (Enumerable.Range (0, 10).Reverse ().ToArray (), values);
+                       Assert.AreEqual (0, stack.Count);
+               }
+
+               [Test]
+               public void TryPopRangePartialFillTest ()
+               {
+                       int[] values = new int[5];
+                       Assert.AreEqual (2, stack.TryPopRange (values, 3, 2));
+                       CollectionAssert.AreEquivalent (new int[] { 0, 0, 0, 9, 8 }, values);
+                       Assert.AreEqual (8, stack.Count);
+               }
+
+               [Test, ExpectedException (typeof (ArgumentOutOfRangeException))]
+               public void TryPopRange_NegativeIndex ()
+               {
+                       stack.TryPopRange (new int[3], -2, 3);
+               }
+
+               [Test, ExpectedException (typeof (ArgumentOutOfRangeException))]
+               public void TryPopRange_LargeIndex ()
+               {
+                       stack.TryPopRange (new int[3], 200, 3);
+               }
+
+               [Test, ExpectedException (typeof (ArgumentException))]
+               public void TryPopRange_LargeCount ()
+               {
+                       stack.TryPopRange (new int[3], 2, 5);
+               }
+
+               [Test, ExpectedException (typeof (ArgumentNullException))]
+               public void TryPopRange_NullArray ()
+               {
+                       stack.TryPopRange (null);
+               }
        }
 }
 #endif
index 5b9688caa649d15b697e57fa5d78ec21fb628117..ab336ea922d058d3735cd827d9d48d9d582d1979 100644 (file)
@@ -873,8 +873,6 @@ namespace MonoTests.System.Collections
                                        int y;
 
                                        y = arrayList.BinarySearch(i);
-
-                                       Assertion.Equals(y, i);
                                }
                        }
 
diff --git a/mcs/class/corlib/Test/System.Diagnostics/DebugTest.cs b/mcs/class/corlib/Test/System.Diagnostics/DebugTest.cs
deleted file mode 100644 (file)
index 3d7f254..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-//
-// MonoTests.System.Diagnostics.DebugTest.cs
-//
-// Author:
-//     John R. Hicks (angryjohn69@nc.rr.com)
-//
-// (C) 2002
-using System;
-using System.Diagnostics;
-using NUnit.Framework;
-
-namespace MonoTests.System.Diagnostics
-{
-               [TestFixture]
-               public class DebugTest2
-               {
-                       [SetUp]
-                       protected void SetUp()
-                       {
-                               Debug.Listeners.Add(new TextWriterTraceListener(Console.Error));        
-                       }
-                       
-                       [TearDown]
-                       protected void TearDown()
-                       {
-                               
-                       }
-
-                       [Test]
-                       public void TestAssert()
-                       {
-                               Debug.Assert(false, "Testing Assertions");
-                       }
-
-                       [Test]                  
-                       public void TestFail ()
-                       {
-                               Debug.Fail("Testing Fail method");
-                       }
-
-                       [Test]                  
-                       public void TestWrite()
-                       {
-                               Debug.Write("Testing Write", "Testing the output of the Write method");
-                       }
-
-                       [Test]                  
-                       public void TestWriteIf()
-                       {
-                               Debug.WriteIf(true, "Testing WriteIf");
-                               Debug.WriteIf(false, "Testing WriteIf", "Passed false");
-                       }
-
-                       [Test]                  
-                       public void TestWriteLine()
-                       {
-                               Debug.WriteLine("Testing WriteLine method");
-                       }
-
-                       [Test]                  
-                       public void TestWriteLineIf()
-                       {
-                               Debug.WriteLineIf(true, "Testing WriteLineIf");
-                               Debug.WriteLineIf(false, "Testing WriteLineIf", "Passed false");
-                       }
-               }
-}
index 900ecc2d1371129f503c4f1594b24947995750fe..931764742bf35b71523a070ee03266d66b60f0e3 100644 (file)
@@ -205,6 +205,18 @@ namespace MonoTests.System.Globalization
                        Assert.IsTrue (culture.Equals (cultureClone));
                }
 
+               [Test]
+               public void IsNeutral ()
+               {
+                       var ci = new CultureInfo (0x6C1A);
+                       Assert.IsTrue (ci.IsNeutralCulture, "#1");
+                       Assert.AreEqual ("srp", ci.ThreeLetterISOLanguageName, "#2");
+
+                       ci = new CultureInfo ("en-US");
+                       Assert.IsFalse (ci.IsNeutralCulture, "#1a");
+                       Assert.AreEqual ("eng", ci.ThreeLetterISOLanguageName, "#2a");
+               }
+
                [Test] // bug #81930
                public void IsReadOnly ()
                {
@@ -340,7 +352,6 @@ namespace MonoTests.System.Globalization
                        }
                }
 
-#if NET_2_0
                [Test]
                [Category ("NotDotNet")] // On MS, the NumberFormatInfo of the CultureInfo matching the current locale is not read-only
                public void GetCultureInfo_Identifier ()
@@ -438,7 +449,6 @@ namespace MonoTests.System.Globalization
                                Assert.AreEqual ("name", ex.ParamName, "#6");
                        }
                }
-#endif
 
                [Test]
                public void UseUserOverride_CurrentCulture ()
@@ -462,7 +472,6 @@ namespace MonoTests.System.Globalization
                        Assert.AreEqual (expected, ci.UseUserOverride, "#2");
                }
 
-#if NET_2_0
                [Test]
                public void UseUserOverride_GetCultureInfo ()
                {
@@ -476,21 +485,16 @@ namespace MonoTests.System.Globalization
                                Assert.IsFalse (culture.UseUserOverride, "#2: " + cultureMsg);
                        }
                }
-#endif
 
                [Test]
                public void UseUserOverride_GetCultures ()
                {
                        foreach (CultureInfo ci in CultureInfo.GetCultures (CultureTypes.AllCultures)) {
                                string cultureMsg = String.Format ("{0} {1}", ci.LCID, ci.Name);
-#if NET_2_0
                                if (ci.LCID == CultureInfo.InvariantCulture.LCID)
                                        Assert.IsFalse (ci.UseUserOverride, cultureMsg);
                                else
                                        Assert.IsTrue (ci.UseUserOverride, cultureMsg);
-#else
-                               Assert.IsTrue (ci.UseUserOverride, cultureMsg);
-#endif
                        }
                }
 
@@ -519,9 +523,7 @@ namespace MonoTests.System.Globalization
                public void ZhHant ()
                {
                        Assert.AreEqual (31748, new CultureInfo ("zh-Hant").LCID);
-#if NET_2_0
                        Assert.AreEqual (31748, CultureInfo.GetCultureInfo ("zh-Hant").LCID);
-#endif
                }
        }
 }
index 1258f15c9a96f2568b19c6f5175570547e9507e1..0c6a8e247cb1b598d9ed6a5cfe279bcfb51ceaed 100644 (file)
@@ -116,6 +116,13 @@ namespace MonoTests.System.Globalization
                        Assert.AreEqual ("Jan", DateTimeFormatInfo.InvariantInfo.AbbreviatedMonthGenitiveNames[0], "#3");
                }
 
+               [Test]
+               public void MonthGenitiveNames ()
+               {
+                       var dfi = new CultureInfo ("cs-CZ").DateTimeFormat;
+                       Assert.AreEqual ("ledna", dfi.MonthGenitiveNames[0], "#1");
+               }
+
 #if !TARGET_JVM
                [Test]
                public void Bug78569 ()
index dd44a01a33a51640489996ce564cd7f24a55e8e0..4c6104ca173e815ead413f4c846ef8f19bf707dc 100644 (file)
@@ -42,13 +42,15 @@ namespace MonoTests.System.Globalization
                                } catch (ArgumentException) {
                                }
                        }
+
+                       try {
+                               new RegionInfo ("2342#");
+                               Assert.Fail ("#2");
+                       } catch (ArgumentException) {
+                       }
                }
 
                [Test]
-#if NET_2_0
-#else
-               [ExpectedException (typeof (ArgumentException))]
-#endif
                public void RegionByLocaleName ()
                {
                        string [] names = new string [] {
@@ -73,5 +75,13 @@ namespace MonoTests.System.Globalization
                        Assert.IsTrue (hk.ThreeLetterISORegionName.Length <= 3, "ThreeLetterISORegionName");
                        Assert.IsTrue (hk.ThreeLetterWindowsRegionName.Length <= 3, "ThreeLetterWindowsRegionName");
                }
+
+               [Test]
+               public void Equals ()
+               {
+                       var a = new RegionInfo (0x414);
+                       var b = new RegionInfo (0x43B);
+                       Assert.AreEqual (a, b);
+               }
        }
 }
\ No newline at end of file
index 301bcd296b352729acd0e4b08505a2f216ac3b1b..5113cc5e981c7d4b88c367641a700f993237639d 100644 (file)
@@ -86,13 +86,11 @@ public class TextInfoTest {
                Assert.AreEqual (t1.ListSeparator, t2.ListSeparator, "ListSeparator");
                Assert.AreEqual (t1.MacCodePage, t2.MacCodePage, "MacCodePage");
                Assert.AreEqual (t1.OEMCodePage, t2.OEMCodePage, "OEMCodePage");
-#if NET_2_0
                Assert.AreEqual (t1.CultureName, t2.CultureName, "CultureName");
                if (compareReadOnly)
                        Assert.AreEqual (t1.IsReadOnly, t2.IsReadOnly, "IsReadOnly");
 //FIXME                Assert.AreEqual (t1.IsRightToLeft, t2.IsRightToLeft, "IsRightToLeft");
                Assert.AreEqual (t1.LCID, t2.LCID, "LCID");
-#endif
        }
 
        [Test]
@@ -109,7 +107,6 @@ public class TextInfoTest {
                CompareProperties (enus, clone, true);
        }
 
-#if NET_2_0
        [Test]
        public void Clone ()
        {
@@ -148,6 +145,7 @@ public class TextInfoTest {
                        case 13:        // he
                        case 32:        // ur
                        case 41:        // fa
+                       case 0x63:      // ps
                        case 90:        // syr
                        case 101:       // div
                        case 1025:      // ar-SA
@@ -171,6 +169,7 @@ public class TextInfoTest {
                        case 14337:     // ar-AE
                        case 15361:     // ar-BH
                        case 16385:     // ar-QA
+                       case 0x463: // ps-AF
                                Assert.IsTrue (ci.TextInfo.IsRightToLeft, ci.Name);
                                break;
                        default:
@@ -179,7 +178,6 @@ public class TextInfoTest {
                        }
                }
        }
-#endif
 
        [Test]
        public void Deserialization ()
index 224e3058d40f278367ac8af0c60c6719508d4132..10bf9bf136714c5f21bcb07ef21a0697cae110b3 100644 (file)
@@ -1119,5 +1119,25 @@ namespace MonoTests.System.IO.IsolatedStorageTest {
                        }
                }
 #endif
+               [Test]
+               public void RootedDirectory ()
+               {
+                       IsolatedStorageFile isf = IsolatedStorageFile.GetUserStoreForAssembly ();
+                       try {
+                               isf.CreateDirectory ("test/nested/directory/structure/without/root");
+                               isf.CreateDirectory ("/test/nested/directory/structure/with/root");
+                       }
+                       finally {
+                               isf.DeleteDirectory ("test/nested/directory/structure/without/root");
+                               isf.DeleteDirectory ("test/nested/directory/structure/without");
+
+                               isf.DeleteDirectory ("/test/nested/directory/structure/with/root");
+                               isf.DeleteDirectory ("/test/nested/directory/structure/with");
+                               isf.DeleteDirectory ("/test/nested/directory/structure");
+                               isf.DeleteDirectory ("/test/nested/directory");
+                               isf.DeleteDirectory ("/test/nested");
+                               isf.DeleteDirectory ("/test");
+                       }
+               }
        }
 }
index 1eacf815e53ed5b46323a3938203d7ddfb403b28..9891683b995cafc66c2b7bc4a4172b9c7c0a05b2 100644 (file)
@@ -324,11 +324,11 @@ public class DirectoryTest
                string path = TempFolder + DSC + "ExistsAccessDenied";\r
 \r
                Directory.CreateDirectory (path);\r
-               Process.Start ("/bin/chmod", "000 " + path).WaitForExit ();\r
+               Mono.Posix.Syscall.chmod (path, 0);\r
                try {\r
                        Assert.IsFalse (Directory.Exists(path + DSC + "b"));\r
                } finally {\r
-                       Process.Start ("/bin/chmod", "755 " + path).WaitForExit ();\r
+                       Mono.Posix.Syscall.chmod (path, (Mono.Posix.FileMode) 755);\r
                        Directory.Delete (path);\r
                }\r
        }\r
index 59adc02f9db01622b6a3db5132efbc8d6fa6f009..0f481590ffdf154c629f263f938a08261c6a9a8a 100644 (file)
@@ -81,7 +81,7 @@ namespace MonoTests.System.Reflection
                        Bar = 2
                };
 
-               public static void paramMethod (int i, [In] int j, [Out] int k, [Optional] int l, [In,Out] int m, [DefaultParameterValue (ParamEnum.Foo)] ParamEnum n)
+               public static void paramMethod (int i, [In] int j, [Out] int k, [Optional] int l, [In,Out] int m, ParamEnum n = ParamEnum.Foo)
                {
                }
 
index e8b89036c56b9468651a7d8c369c7ce7012e1e9d..861d88787a4278d096cef39859f2ae7a9155b19b 100644 (file)
@@ -207,7 +207,9 @@ namespace MonoTests.System.Runtime.Serialization.Formatters.Binary
 
                private static string Find (string assemblyVersion, string path)
                {
-                       //Console.WriteLine ("Looking in " + path);
+                       return  Path.Combine (Path.Combine (path, assemblyVersion), assemblyFileName);
+/*                     
+                       Console.WriteLine ("Looking in " + path);
                        string test;
 
                        if (!path.Contains(assemblyVersion))
@@ -257,6 +259,7 @@ namespace MonoTests.System.Runtime.Serialization.Formatters.Binary
                                                "The tree is not predictible according to the philosophy of the test. (Stuck in {0})",
                                                path));
                        }
+*/
                }
 
                private void SerializeToFile (string filename)
diff --git a/mcs/class/corlib/Test/System.Security.Cryptography.X509Certificates/X509Cert20Test.cs b/mcs/class/corlib/Test/System.Security.Cryptography.X509Certificates/X509Cert20Test.cs
deleted file mode 100644 (file)
index f230b59..0000000
+++ /dev/null
@@ -1,751 +0,0 @@
-//
-// X509Cert20Test.cs - Unit Tests for new 2.0 features in X509Certificate
-//
-// Author:
-//     Sebastien Pouliot  <sebastien@ximian.com>
-//
-// Copyright (C) 2005-2006 Novell Inc. (http://www.novell.com)
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-// 
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-// 
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
-
-#if NET_2_0
-
-using NUnit.Framework;
-using System;
-using System.IO;
-using System.Runtime.InteropServices;
-using System.Runtime.Serialization;
-using System.Security;
-using System.Security.Cryptography;
-using System.Security.Cryptography.X509Certificates;
-using System.Text;
-
-namespace MonoTests.System.Security.Cryptography.X509Certificates {
-
-       [TestFixture]
-       public class X509Cert20Test {
-
-               static byte[] cert1 = { 0x30,0x82,0x01,0xFF,0x30,0x82,0x01,0x6C,0x02,0x05,0x02,0x72,0x00,0x06,0xE8,0x30,0x0D,0x06,0x09,0x2A,0x86,0x48,0x86,0xF7,0x0D,0x01,0x01,0x02,0x05,0x00,0x30,0x5F,0x31,0x0B,0x30,0x09,0x06,0x03,0x55,0x04,0x06,0x13,0x02,0x55,0x53,0x31,0x20,0x30,0x1E,0x06,0x03,0x55,0x04,0x0A,0x13,0x17,0x52,0x53,0x41,0x20,0x44,0x61,0x74,0x61,0x20,0x53,0x65,0x63,0x75,0x72,0x69,0x74,0x79,0x2C,0x20,0x49,0x6E,0x63,0x2E,0x31,0x2E,0x30,0x2C,0x06,0x03,0x55,0x04,0x0B,0x13,0x25,0x53,0x65,0x63,0x75,0x72,0x65,0x20,0x53,0x65,0x72,0x76,
-                       0x65,0x72,0x20,0x43,0x65,0x72,0x74,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6F,0x6E,0x20,0x41,0x75,0x74,0x68,0x6F,0x72,0x69,0x74,0x79,0x30,0x1E,0x17,0x0D,0x39,0x36,0x30,0x33,0x31,0x32,0x31,0x38,0x33,0x38,0x34,0x37,0x5A,0x17,0x0D,0x39,0x37,0x30,0x33,0x31,0x32,0x31,0x38,0x33,0x38,0x34,0x36,0x5A,0x30,0x61,0x31,0x0B,0x30,0x09,0x06,0x03,0x55,0x04,0x06,0x13,0x02,0x55,0x53,0x31,0x13,0x30,0x11,0x06,0x03,0x55,0x04,0x08,0x13,0x0A,0x43,0x61,0x6C,0x69,0x66,0x6F,0x72,0x6E,0x69,0x61,0x31,0x14,0x30,0x12,0x06,0x03,
-                       0x55,0x04,0x0A,0x13,0x0B,0x43,0x6F,0x6D,0x6D,0x65,0x72,0x63,0x65,0x4E,0x65,0x74,0x31,0x27,0x30,0x25,0x06,0x03,0x55,0x04,0x0B,0x13,0x1E,0x53,0x65,0x72,0x76,0x65,0x72,0x20,0x43,0x65,0x72,0x74,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6F,0x6E,0x20,0x41,0x75,0x74,0x68,0x6F,0x72,0x69,0x74,0x79,0x30,0x70,0x30,0x0D,0x06,0x09,0x2A,0x86,0x48,0x86,0xF7,0x0D,0x01,0x01,0x01,0x05,0x00,0x03,0x5F,0x00,0x30,0x5C,0x02,0x55,0x2D,0x58,0xE9,0xBF,0xF0,0x31,0xCD,0x79,0x06,0x50,0x5A,0xD5,0x9E,0x0E,0x2C,0xE6,0xC2,0xF7,0xF9,
-                       0xD2,0xCE,0x55,0x64,0x85,0xB1,0x90,0x9A,0x92,0xB3,0x36,0xC1,0xBC,0xEA,0xC8,0x23,0xB7,0xAB,0x3A,0xA7,0x64,0x63,0x77,0x5F,0x84,0x22,0x8E,0xE5,0xB6,0x45,0xDD,0x46,0xAE,0x0A,0xDD,0x00,0xC2,0x1F,0xBA,0xD9,0xAD,0xC0,0x75,0x62,0xF8,0x95,0x82,0xA2,0x80,0xB1,0x82,0x69,0xFA,0xE1,0xAF,0x7F,0xBC,0x7D,0xE2,0x7C,0x76,0xD5,0xBC,0x2A,0x80,0xFB,0x02,0x03,0x01,0x00,0x01,0x30,0x0D,0x06,0x09,0x2A,0x86,0x48,0x86,0xF7,0x0D,0x01,0x01,0x02,0x05,0x00,0x03,0x7E,0x00,0x54,0x20,0x67,0x12,0xBB,0x66,0x14,0xC3,0x26,0x6B,0x7F,
-                       0xDA,0x4A,0x25,0x4D,0x8B,0xE0,0xFD,0x1E,0x53,0x6D,0xAC,0xA2,0xD0,0x89,0xB8,0x2E,0x90,0xA0,0x27,0x43,0xA4,0xEE,0x4A,0x26,0x86,0x40,0xFF,0xB8,0x72,0x8D,0x1E,0xE7,0xB7,0x77,0xDC,0x7D,0xD8,0x3F,0x3A,0x6E,0x55,0x10,0xA6,0x1D,0xB5,0x58,0xF2,0xF9,0x0F,0x2E,0xB4,0x10,0x55,0x48,0xDC,0x13,0x5F,0x0D,0x08,0x26,0x88,0xC9,0xAF,0x66,0xF2,0x2C,0x9C,0x6F,0x3D,0xC3,0x2B,0x69,0x28,0x89,0x40,0x6F,0x8F,0x35,0x3B,0x9E,0xF6,0x8E,0xF1,0x11,0x17,0xFB,0x0C,0x98,0x95,0xA1,0xC2,0xBA,0x89,0x48,0xEB,0xB4,0x06,0x6A,0x22,0x54,
-                       0xD7,0xBA,0x18,0x3A,0x48,0xA6,0xCB,0xC2,0xFD,0x20,0x57,0xBC,0x63,0x1C };
-
-               static public byte[] farscape_pfx = { 0x30, 0x82, 0x06, 0xA3, 0x02, 0x01, 0x03, 0x30, 0x82, 0x06, 0x63, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x06, 0x54, 0x04, 0x82, 0x06, 0x50, 0x30, 0x82, 0x06, 0x4C, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
-                       0x0E, 0x04, 0x08, 0x67, 0xFE, 0x3A, 0x52, 0x75, 0xF3, 0x82, 0x1F, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0x31, 0x6B, 0x00, 0xFA, 0x73, 0xE6, 0x8D, 0x3D, 0x62, 0x93, 0x41, 0xA1, 0x44, 0x04, 0x17, 0x8D, 0x66, 0x7A, 0x75, 0x14, 0x89, 0xA8, 0xD1, 0x4D, 0x2A, 0xD7, 0x20, 0x27, 0x71, 0x58, 0x81, 0x16, 0xB5, 0xA6, 0x41, 0x75, 0x92, 0xB2, 0xF4, 0x0C, 0xAA, 0x9B, 0x00, 0x46, 0x85, 0x85, 0x3B, 0x09, 0x2A, 0x62, 0x33, 0x3F, 0x3D, 0x06, 0xC7, 0xE7, 0x16, 0x0C, 0xA7, 0x1D, 0x9C, 0xDA, 0x9D, 0xD3, 0xC9, 0x05, 0x60, 0xA5, 0xBE, 0xF0, 0x07, 0xD5, 0xA9, 0x4F, 0x8A, 0x80, 0xF8, 0x55, 0x7B, 0x7B, 0x3C, 
-                       0xA0, 0x7C, 0x29, 0x29, 0xAB, 0xB1, 0xE1, 0x5A, 0x25, 0xE3, 0x23, 0x6A, 0x56, 0x98, 0x37, 0x68, 0xAF, 0x9C, 0x87, 0xBB, 0x21, 0x6E, 0x68, 0xBE, 0xAE, 0x65, 0x0C, 0x41, 0x8F, 0x5C, 0x3A, 0xB8, 0xB1, 0x9D, 0x42, 0x37, 0xE4, 0xA0, 0x37, 0xA6, 0xB8, 0xAC, 0x85, 0xD7, 0x85, 0x27, 0x68, 0xD0, 0xB6, 0x3D, 0xC7, 0x39, 0x92, 0x41, 0x46, 0x24, 0xDD, 0x08, 0x57, 0x22, 0x6A, 0xC0, 0xB7, 0xAD, 0x52, 0xC6, 0x7F, 0xE5, 0x74, 0x6A, 0x5E, 0x28, 0xA3, 0x85, 0xBD, 0xE8, 0xAD, 0x5D, 0xA3, 0x55, 0xE6, 0x63, 0x15, 0x56, 0x7B, 0x01, 0x26, 0x68, 0x5F, 0x11, 0xA3, 0x12, 0x37, 0x02, 0xA5, 0xD0, 0xB7, 0x73, 0x0C, 0x7C, 
-                       0x97, 0xE1, 0xC6, 0x2F, 0x98, 0x82, 0x67, 0x2F, 0x5F, 0x3F, 0xBE, 0x32, 0x16, 0x25, 0x9D, 0x51, 0x48, 0x32, 0xCB, 0x42, 0xD1, 0x31, 0x07, 0xBE, 0x5D, 0xF8, 0xCD, 0x2C, 0x38, 0x0A, 0x33, 0x3B, 0x7B, 0x04, 0x84, 0xAE, 0x9C, 0xA7, 0x6B, 0x36, 0x39, 0x12, 0x87, 0x9D, 0x5B, 0x56, 0x00, 0x44, 0x11, 0xB1, 0xE2, 0x78, 0x14, 0x60, 0xF3, 0xE4, 0x1A, 0x08, 0x14, 0xC0, 0x9E, 0x49, 0x9F, 0xE0, 0x4C, 0xEC, 0x95, 0x15, 0x18, 0x48, 0x0E, 0xB9, 0x0B, 0x3A, 0xFE, 0x45, 0xB0, 0x2D, 0x0D, 0x4F, 0x94, 0x5A, 0x3C, 0x43, 0xB7, 0x40, 0x8E, 0x7B, 0xA2, 0x8E, 0x23, 0x9F, 0x75, 0x97, 0xE7, 0x21, 0x0D, 0xEB, 0xA3, 0x9D, 
-                       0x6C, 0xC0, 0xDC, 0x73, 0xED, 0x15, 0x98, 0xE3, 0xE8, 0x32, 0x2C, 0x12, 0x92, 0x45, 0x25, 0x45, 0x76, 0x18, 0xF5, 0x97, 0x7F, 0xAC, 0xCE, 0xCF, 0x23, 0xF7, 0xD1, 0xCF, 0x06, 0xAB, 0x82, 0x96, 0x1F, 0xF8, 0x68, 0x4F, 0x5D, 0xE1, 0x09, 0xAA, 0xCB, 0xB3, 0x50, 0x85, 0x46, 0x72, 0x14, 0x6C, 0x49, 0x84, 0x57, 0x55, 0x00, 0x78, 0x3E, 0xD9, 0xAA, 0xBD, 0xCC, 0xE2, 0x7B, 0x18, 0xAA, 0x2E, 0x5D, 0xB9, 0x28, 0xEA, 0x8F, 0x8C, 0xFA, 0xB7, 0x06, 0x27, 0x07, 0x89, 0x41, 0x3F, 0x66, 0x1A, 0x91, 0xCA, 0xE9, 0xEC, 0x09, 0x12, 0x1C, 0x67, 0xB2, 0x2A, 0x8B, 0x4A, 0xF0, 0x97, 0x17, 0xDC, 0x3E, 0xCD, 0x9F, 0x03, 
-                       0x15, 0xEF, 0x03, 0x84, 0x08, 0x4A, 0x73, 0xAE, 0xE4, 0x07, 0x30, 0x27, 0xF7, 0x25, 0x69, 0x9D, 0x6C, 0x7D, 0x81, 0x88, 0xCC, 0xFA, 0xD4, 0xC7, 0x64, 0x11, 0xC0, 0xC8, 0x2C, 0x23, 0xF6, 0xFF, 0x9B, 0xE3, 0xC8, 0x89, 0x85, 0x0B, 0x3E, 0x81, 0xD8, 0x9C, 0xBD, 0xD0, 0x2D, 0xCD, 0x15, 0xA9, 0x30, 0x84, 0xF7, 0x6D, 0xEF, 0x62, 0x3B, 0xA7, 0x8C, 0xC2, 0x93, 0x90, 0x6F, 0x91, 0xB4, 0x8A, 0x71, 0x4E, 0x41, 0x4E, 0x5C, 0x67, 0xB5, 0x49, 0xF8, 0x56, 0x3A, 0x83, 0x03, 0x4F, 0xB1, 0xF6, 0xB7, 0x31, 0x5B, 0x68, 0x26, 0x70, 0x89, 0xB1, 0x1E, 0x67, 0x4F, 0xBA, 0xE7, 0xD9, 0xDF, 0x91, 0xD8, 0xFB, 0x8A, 0xDD, 
-                       0xB2, 0xD3, 0x4B, 0xBB, 0x9F, 0x5C, 0xA3, 0x04, 0x2C, 0x87, 0xBC, 0xD5, 0xBE, 0x8C, 0xD7, 0xCF, 0x9B, 0x72, 0x82, 0xA6, 0x99, 0xDA, 0xD7, 0x66, 0x48, 0xE7, 0x8F, 0xE9, 0x48, 0x56, 0x9D, 0xD2, 0xB9, 0x28, 0x84, 0x4F, 0x6A, 0x83, 0xB2, 0xB9, 0x4D, 0x91, 0x10, 0x58, 0x22, 0x4C, 0xE7, 0x9D, 0xC6, 0x0C, 0x74, 0xF4, 0x16, 0x58, 0x30, 0xB7, 0xB7, 0x96, 0x39, 0x6C, 0x5D, 0xFA, 0xB2, 0x03, 0x8C, 0x98, 0xD2, 0xC0, 0x64, 0xB8, 0x05, 0x29, 0x4F, 0xF0, 0x4C, 0x43, 0x48, 0xD3, 0xD8, 0xBD, 0xC7, 0xC1, 0xEA, 0x39, 0x2A, 0xDF, 0xD4, 0xDA, 0x79, 0x7C, 0xB9, 0x06, 0xC7, 0x10, 0x8D, 0x8B, 0xF1, 0xA8, 0x8E, 0x44, 
-                       0x9E, 0x99, 0xFF, 0x81, 0x84, 0x8F, 0xD0, 0x38, 0xE1, 0xF0, 0x5A, 0x12, 0x5F, 0xC5, 0xA6, 0xED, 0x6D, 0xEE, 0xE7, 0x69, 0xC0, 0xA2, 0xB4, 0x13, 0xCA, 0x7A, 0x5D, 0xDE, 0x88, 0x75, 0xE7, 0xE2, 0x6D, 0x8A, 0xEC, 0x0F, 0x88, 0x3F, 0xE2, 0xCB, 0x60, 0xF0, 0x6A, 0xEC, 0xD0, 0xF4, 0x0D, 0x11, 0xC2, 0x84, 0x19, 0x67, 0x52, 0xAD, 0xC0, 0xC0, 0x20, 0x84, 0x6D, 0x7D, 0xEA, 0xD2, 0xF9, 0x3F, 0xE5, 0x58, 0x00, 0xED, 0x24, 0xD6, 0x50, 0x9B, 0x80, 0x80, 0x0A, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
-                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
-                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x02, 0xB7, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x02, 0xA8, 0x30, 0x82, 0x02, 0xA4, 0x02, 0x01, 0x00, 0x30, 0x82, 0x02, 0x9D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
-                       0x06, 0x30, 0x0E, 0x04, 0x08, 0xB8, 0x22, 0xEA, 0x3C, 0x70, 0x6A, 0xFC, 0x39, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x02, 0x70, 0x76, 0xBE, 0x5B, 0xD5, 0x3D, 0x05, 0xC1, 0xDB, 0x10, 0xA3, 0x02, 0xBB, 0x7F, 0x0A, 0x8B, 0x54, 0xC1, 0x7D, 0x19, 0xDA, 0x7E, 0x82, 0xDF, 0xAD, 0x6B, 0x42, 0xC2, 0x95, 0x95, 0x00, 0x6E, 0x82, 0x77, 0xD5, 0x42, 0x6E, 0x21, 0xA2, 0x95, 0xB4, 0x98, 0xF5, 0xDD, 0x18, 0x6F, 0xC4, 0xF3, 0xB6, 0x93, 0xA0, 0x6C, 0xF4, 0x34, 0x7A, 0x48, 0x72, 0x08, 0xB1, 0x28, 0x51, 0x54, 0x10, 0x7F, 0x35, 0xB2, 0xE5, 0x89, 0x5C, 0x0A, 0x14, 0x31, 0x1C, 0x9D, 0xA9, 0xE4, 0x94, 0x91, 0x28, 0x65, 
-                       0xC4, 0xE7, 0x5E, 0xA9, 0x37, 0x08, 0x3D, 0xB1, 0x16, 0x61, 0x9D, 0xA9, 0x44, 0x6F, 0x20, 0x0C, 0x55, 0xD7, 0xCC, 0x48, 0x82, 0x13, 0x5D, 0xE1, 0xBD, 0x9D, 0xCE, 0x64, 0x28, 0x6D, 0x69, 0x4E, 0x08, 0x53, 0x09, 0xE0, 0xCC, 0xA8, 0x79, 0x04, 0xCF, 0xFA, 0x35, 0x1C, 0xA6, 0x70, 0x37, 0x64, 0x70, 0x74, 0xF8, 0xD0, 0xC4, 0x34, 0x0F, 0x71, 0xEF, 0x57, 0xC2, 0x43, 0x7D, 0xFA, 0xE5, 0x1B, 0x8C, 0x15, 0xA5, 0x08, 0x60, 0x78, 0xAF, 0xDA, 0x36, 0xDF, 0x79, 0x2D, 0xD7, 0x54, 0x35, 0xD7, 0x8D, 0x99, 0xD5, 0x81, 0xEC, 0x6D, 0x9F, 0x2D, 0x5E, 0xF8, 0x48, 0x85, 0x50, 0x20, 0x7D, 0xBB, 0x16, 0x4E, 0x39, 0x64, 
-                       0xB7, 0xBC, 0xED, 0xA9, 0x6A, 0x7A, 0x06, 0x09, 0x6B, 0xBC, 0x2C, 0x5A, 0xE1, 0x4F, 0xD4, 0xA9, 0x82, 0x83, 0x5B, 0xBD, 0xCE, 0x14, 0x31, 0x89, 0x66, 0xB3, 0x9C, 0x31, 0x23, 0x00, 0x4B, 0x02, 0x34, 0x85, 0x30, 0x39, 0x77, 0x80, 0x5D, 0x72, 0x0A, 0xCE, 0x43, 0x2A, 0x1F, 0x02, 0x09, 0xAB, 0x2D, 0x46, 0x3A, 0x1C, 0xD2, 0x7B, 0xF6, 0x02, 0x92, 0xCA, 0xDA, 0x26, 0x0C, 0xF8, 0xE2, 0x67, 0x7E, 0xE2, 0x55, 0xB1, 0x3F, 0x6A, 0x06, 0x65, 0x6D, 0x74, 0x98, 0x59, 0xE2, 0x8A, 0x1E, 0x61, 0x03, 0x4D, 0xFC, 0x68, 0x31, 0x6A, 0xE7, 0xCF, 0x52, 0x88, 0x8E, 0x06, 0x97, 0x77, 0xB3, 0x20, 0x7E, 0x09, 0x5D, 0x3B, 
-                       0xAF, 0x56, 0xF4, 0xE8, 0x4C, 0x69, 0x09, 0xB9, 0x80, 0x38, 0xDC, 0x66, 0x2E, 0x06, 0xF6, 0xCB, 0x1F, 0x1B, 0xAD, 0x51, 0xFF, 0xFD, 0x38, 0x8D, 0x03, 0x90, 0xCF, 0x31, 0x01, 0x30, 0xEA, 0x48, 0x4C, 0xBB, 0x40, 0x87, 0x1D, 0x97, 0x6A, 0x56, 0x4C, 0xED, 0x07, 0x23, 0x45, 0x50, 0x2F, 0x56, 0xC9, 0x90, 0x79, 0x09, 0xC5, 0x45, 0xB9, 0xAD, 0x58, 0x2B, 0x4C, 0xA3, 0x01, 0xE0, 0x2D, 0xE5, 0x30, 0xBC, 0x54, 0xEC, 0x65, 0xB4, 0x79, 0x22, 0x7D, 0x15, 0xF6, 0x28, 0xCD, 0x84, 0x7E, 0x27, 0x95, 0xA1, 0xC7, 0x82, 0x6D, 0xFB, 0xDF, 0x03, 0xD9, 0x14, 0xFE, 0x0A, 0x06, 0x6F, 0x14, 0xFF, 0x8A, 0x27, 0x80, 0x36, 
-                       0xDC, 0xBA, 0xAE, 0xDD, 0x44, 0x15, 0xA5, 0x6E, 0x64, 0x73, 0xBD, 0xFB, 0xAE, 0x6D, 0x6F, 0x42, 0x96, 0xDF, 0x90, 0xE5, 0x6A, 0x9B, 0x05, 0xAE, 0xD5, 0x0A, 0x22, 0x88, 0xD6, 0x5D, 0x4C, 0x7B, 0xB1, 0x3A, 0xFC, 0x0C, 0x32, 0x02, 0xB1, 0x18, 0x0D, 0xAF, 0xE0, 0xFE, 0x7E, 0x07, 0x96, 0x85, 0xBB, 0xC8, 0x21, 0x68, 0x12, 0xD4, 0xC8, 0xBF, 0x91, 0x47, 0xE2, 0xF3, 0xA5, 0xA3, 0x86, 0xE6, 0x30, 0x42, 0xF5, 0xA9, 0xB9, 0x48, 0xCB, 0x18, 0xE6, 0x64, 0x3B, 0xE0, 0x8E, 0xC3, 0x03, 0x45, 0xA0, 0xED, 0x1A, 0x09, 0xFF, 0xB3, 0x99, 0x14, 0x5F, 0xDA, 0x90, 0x58, 0x61, 0x8E, 0xF7, 0x0A, 0x00, 0xC7, 0x44, 0xE7, 
-                       0x73, 0x78, 0xC4, 0x8B, 0x39, 0xCE, 0x70, 0x0E, 0x24, 0x03, 0x95, 0x94, 0x73, 0x76, 0x10, 0x7E, 0x4C, 0xFF, 0xCA, 0x49, 0x93, 0x89, 0xD4, 0x3E, 0x1A, 0x88, 0xCC, 0x48, 0xA7, 0x78, 0x2F, 0x83, 0x4F, 0x6C, 0x33, 0x55, 0xDD, 0x7F, 0x7D, 0x4D, 0xE5, 0xCD, 0x9C, 0x3D, 0x04, 0x1E, 0xC1, 0x9B, 0x6D, 0x7E, 0x7A, 0xAC, 0x93, 0x5E, 0x2B, 0xC3, 0x85, 0x36, 0x07, 0x66, 0xE8, 0xC9, 0xC0, 0xD1, 0x54, 0xF4, 0x4C, 0x6A, 0x02, 0x24, 0x9A, 0x7D, 0x10, 0xD9, 0x79, 0x94, 0x00, 0x64, 0x63, 0x36, 0xDC, 0x35, 0x0C, 0x8F, 0x79, 0xBA, 0xC7, 0x10, 0x76, 0xF8, 0x4A, 0xD3, 0x69, 0x95, 0x23, 0x89, 0x66, 0xC4, 0x5A, 0xE7, 
-                       0xCE, 0x21, 0xBC, 0xCB, 0xF2, 0x4F, 0x92, 0x33, 0xE7, 0x89, 0xD6, 0x23, 0xF7, 0x67, 0x5B, 0x20, 0xD9, 0xDA, 0x1A, 0xD1, 0xF6, 0x9E, 0x01, 0x83, 0x51, 0xAF, 0x35, 0x43, 0xDD, 0x3A, 0xAB, 0xCA, 0x0E, 0xED, 0x2E, 0x4D, 0x1E, 0x91, 0xCF, 0x2E, 0xA9, 0x4D, 0x08, 0xD9, 0x48, 0x30, 0x37, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0xA2, 0xED, 0x05, 0x50, 0x89, 0x91, 0x1D, 0xEB, 0xF6, 0x57, 0x66, 0xAF, 0x70, 0x15, 0xDD, 0x1A, 0xA1, 0x94, 0xB7, 0xB2, 0x04, 0x14, 0x09, 0xE4, 0x0B, 0xEC, 0x1D, 0x93, 0x3E, 0x32, 0x94, 0x6A, 0x95, 0x36, 0xDD, 0xBA, 0x93, 0x9D, 0x75, 0xB6, 
-                       0x3E, 0xF5 };
-
-               static public byte[] farscape_nopwd_pfx = { 0x30, 0x82, 0x06, 0xA3, 0x02, 0x01, 0x03, 0x30, 0x82, 0x06, 0x63, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x06, 0x54, 0x04, 0x82, 0x06, 0x50, 0x30, 0x82, 0x06, 0x4C, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
-                       0x0E, 0x04, 0x08, 0x31, 0xB9, 0x22, 0x7A, 0x73, 0xB6, 0x67, 0x3E, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0x05, 0x3F, 0x9B, 0x6F, 0x4D, 0xE2, 0x97, 0xC0, 0x71, 0x61, 0xDC, 0x39, 0x33, 0x9B, 0x45, 0x36, 0xD1, 0xC2, 0xC1, 0x2E, 0xE3, 0x22, 0x88, 0xE2, 0x54, 0x18, 0xE8, 0xC9, 0x0E, 0xA7, 0xBB, 0x1B, 0xC6, 0xC8, 0x32, 0xD9, 0x47, 0x64, 0x40, 0xC2, 0x40, 0xDC, 0x34, 0xB5, 0x34, 0x5D, 0x8A, 0x56, 0xD9, 0xF6, 0x0A, 0x03, 0x93, 0x5D, 0xE5, 0x04, 0xDC, 0x5B, 0xBA, 0x49, 0x22, 0x0A, 0x51, 0x33, 0xFF, 0xF0, 0xAF, 0x5D, 0x1F, 0x97, 0x6A, 0x11, 0x1C, 0x6B, 0x1A, 0xCF, 0x2E, 0x41, 0xA1, 0xD0, 0x31, 
-                       0xC2, 0x2D, 0xDD, 0x83, 0xAA, 0x21, 0x0C, 0x0E, 0x78, 0xEE, 0x9C, 0x25, 0x74, 0xC5, 0x4F, 0xE4, 0x94, 0x84, 0xA8, 0xD9, 0x2F, 0x96, 0xF5, 0x06, 0x05, 0xAE, 0x99, 0xBF, 0x8B, 0xD6, 0x67, 0x5E, 0xCB, 0x61, 0x03, 0xCC, 0x5A, 0x5F, 0xAB, 0x82, 0x55, 0xB1, 0x8D, 0xCD, 0xFE, 0x1C, 0x25, 0x48, 0xA7, 0x1D, 0xFF, 0x2E, 0xC0, 0x23, 0x80, 0xF7, 0xE4, 0x22, 0x68, 0x07, 0xFF, 0x58, 0xA5, 0xAA, 0x71, 0x7A, 0xAB, 0x48, 0x2D, 0xE6, 0xDF, 0xB5, 0x3C, 0x90, 0x15, 0xE3, 0x55, 0x4A, 0xB4, 0x37, 0xFE, 0x7F, 0xE1, 0x5B, 0x0C, 0xF1, 0x01, 0x4C, 0x60, 0x2F, 0x6F, 0x59, 0x09, 0x2B, 0x96, 0xDC, 0xE2, 0x2C, 0xF0, 0xB9, 
-                       0xF3, 0x3E, 0x46, 0x5B, 0x68, 0xA9, 0xBB, 0x42, 0x8B, 0xAB, 0xA9, 0x68, 0x56, 0xF9, 0xB2, 0x2E, 0x93, 0xDD, 0xE9, 0xBB, 0x70, 0x9E, 0x2E, 0x48, 0xB9, 0xDB, 0x1C, 0x95, 0x0F, 0x67, 0xD4, 0x13, 0x02, 0x62, 0xE0, 0xFA, 0x18, 0x48, 0xAE, 0x31, 0xB6, 0x1F, 0x68, 0x7D, 0xB2, 0x16, 0x61, 0xCD, 0x04, 0x91, 0x50, 0xBF, 0x35, 0xBF, 0x76, 0xA3, 0x5B, 0x76, 0xFE, 0x3F, 0xAB, 0xB2, 0x59, 0x8B, 0xD0, 0xB7, 0xC6, 0x36, 0x0E, 0x2C, 0x31, 0x48, 0xFB, 0x69, 0x6F, 0x90, 0x37, 0x3F, 0xE1, 0x53, 0x36, 0x5A, 0x60, 0x53, 0x93, 0x46, 0xC4, 0x31, 0x92, 0x3B, 0x11, 0x9F, 0x67, 0xC3, 0xD0, 0x2E, 0x9F, 0x7D, 0xA8, 0xBE, 
-                       0xA3, 0xB2, 0xCF, 0x60, 0xA3, 0xCE, 0x9F, 0x4B, 0x72, 0xCD, 0x44, 0x26, 0x4C, 0x66, 0xF8, 0x75, 0x80, 0xFC, 0x23, 0xBC, 0xA1, 0x3A, 0xCA, 0xC9, 0xE7, 0x50, 0xA3, 0x79, 0x21, 0x2B, 0x2D, 0x09, 0x8C, 0x45, 0x89, 0xB6, 0xAF, 0x66, 0x3E, 0xF7, 0xFD, 0xA5, 0x69, 0x96, 0xB4, 0x65, 0xB5, 0xFE, 0x35, 0x1F, 0x80, 0xA7, 0x41, 0x90, 0xBA, 0x92, 0x8D, 0x3B, 0xC0, 0x37, 0xDE, 0x95, 0xA8, 0x0D, 0xF1, 0x1A, 0x9F, 0xD2, 0x70, 0xED, 0x38, 0x1E, 0xA2, 0xF1, 0x2B, 0x63, 0x62, 0xC5, 0xAE, 0x5D, 0x0F, 0xFC, 0x80, 0xFA, 0x0E, 0xE4, 0xE7, 0x6C, 0x62, 0x3B, 0x19, 0xBB, 0xA8, 0xE5, 0x1D, 0x3E, 0x06, 0x30, 0x0B, 0xE1, 
-                       0xCF, 0xB6, 0xB4, 0x87, 0x96, 0xA2, 0x5E, 0xF8, 0x0F, 0x13, 0xAE, 0x04, 0xAF, 0xB2, 0x6C, 0x9E, 0xA0, 0x28, 0x1C, 0x46, 0xE5, 0xA8, 0x25, 0x62, 0x51, 0x95, 0xB0, 0x70, 0x60, 0xB6, 0xD9, 0xBB, 0xE3, 0xD1, 0xF0, 0x1D, 0x25, 0xBD, 0x93, 0x5E, 0xB6, 0x47, 0x50, 0xCD, 0x77, 0x7A, 0xFF, 0xC5, 0xFF, 0x4A, 0x7A, 0x9A, 0x27, 0x22, 0xEB, 0x7C, 0x12, 0xE5, 0x59, 0x1F, 0x60, 0xEA, 0xC3, 0x93, 0x4D, 0x28, 0x49, 0x2D, 0xF9, 0xC0, 0x13, 0x12, 0x89, 0x96, 0xED, 0x78, 0xB0, 0x1C, 0x82, 0xDE, 0xEE, 0x40, 0xDE, 0x68, 0x2B, 0x45, 0x16, 0xBE, 0xBF, 0xD5, 0x85, 0x6A, 0xDB, 0xD9, 0x1E, 0xEE, 0xFA, 0x6C, 0x95, 0x19, 
-                       0xF3, 0x76, 0x61, 0x72, 0x21, 0x69, 0x77, 0x18, 0x2C, 0xFA, 0x99, 0x7A, 0xD7, 0x58, 0xC4, 0xD6, 0x1D, 0x8B, 0xE8, 0x0B, 0xEC, 0x0F, 0x0F, 0xFA, 0xCE, 0xE2, 0x6F, 0xB1, 0xF5, 0x4F, 0xC3, 0xF7, 0x4A, 0xE4, 0x79, 0xB0, 0xFC, 0x62, 0x88, 0xC0, 0x49, 0xEC, 0xDB, 0xC8, 0xCD, 0xBE, 0x25, 0x00, 0x68, 0xB6, 0x5E, 0x89, 0x78, 0xE6, 0x92, 0xA5, 0x5D, 0x55, 0xA7, 0xAD, 0xFF, 0x3D, 0xC7, 0xF9, 0x95, 0x8D, 0xCF, 0x6E, 0x37, 0x1D, 0x79, 0x74, 0xE1, 0xDE, 0x22, 0x07, 0x6B, 0xE6, 0xB7, 0x7D, 0xD1, 0x0F, 0xB6, 0xA4, 0x3F, 0x0F, 0x31, 0x81, 0x09, 0xAD, 0xFD, 0x5F, 0xA4, 0xF4, 0x8F, 0x3C, 0x02, 0xB8, 0xB0, 0x04, 
-                       0x70, 0x44, 0x2C, 0x73, 0x42, 0xEE, 0xFF, 0xBA, 0x45, 0x50, 0xC0, 0x95, 0xFF, 0x62, 0x14, 0x91, 0x23, 0xF2, 0x8A, 0x65, 0x40, 0x20, 0xEB, 0x4B, 0x7B, 0x66, 0xF2, 0xC2, 0xC8, 0xD7, 0x16, 0x93, 0x0A, 0xBD, 0x5C, 0xCC, 0x11, 0x38, 0xEA, 0x90, 0x9C, 0x37, 0xDA, 0xB2, 0x80, 0xBF, 0x5C, 0x41, 0xC8, 0x3B, 0x16, 0x81, 0x83, 0xF7, 0xE4, 0x16, 0x12, 0x6C, 0x5F, 0x05, 0xBE, 0x2B, 0x04, 0x62, 0x36, 0x13, 0x8F, 0xF1, 0xC2, 0x5A, 0xCB, 0xFB, 0x26, 0x04, 0xE0, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
-                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
-                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x02, 0xB7, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x02, 0xA8, 0x30, 0x82, 0x02, 0xA4, 0x02, 0x01, 0x00, 0x30, 0x82, 0x02, 0x9D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
-                       0x06, 0x30, 0x0E, 0x04, 0x08, 0x37, 0xAE, 0x94, 0x2A, 0x4C, 0x78, 0xA2, 0x9A, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x02, 0x70, 0x49, 0xB9, 0xA3, 0x6E, 0xC7, 0x96, 0xCF, 0x92, 0x12, 0x43, 0x69, 0x57, 0xAD, 0x4B, 0x88, 0xA8, 0x3F, 0xEA, 0x25, 0xB6, 0xE4, 0x16, 0x74, 0x4E, 0xF5, 0xF8, 0xF2, 0xEC, 0xC0, 0xB7, 0xC2, 0x6A, 0x6E, 0xC0, 0x67, 0x5A, 0x5D, 0xFE, 0x0A, 0x7C, 0xBD, 0x06, 0xFF, 0x2F, 0x34, 0xFD, 0xE4, 0x06, 0x70, 0x23, 0xA3, 0x28, 0x27, 0xCA, 0x91, 0xD0, 0xC7, 0xA1, 0x08, 0x4F, 0x78, 0x0E, 0x89, 0xED, 0x29, 0x8F, 0xD6, 0x8E, 0x1C, 0xE0, 0x30, 0x08, 0x77, 0xA0, 0x3F, 0x18, 0xF1, 0x81, 0xD5, 
-                       0x73, 0xD7, 0x1A, 0xCA, 0xD4, 0x6D, 0x56, 0x7D, 0xFD, 0x30, 0xB5, 0xA0, 0x5D, 0x59, 0x82, 0xB9, 0xF7, 0x02, 0x19, 0x83, 0x68, 0x19, 0x08, 0x5E, 0x26, 0xCF, 0x06, 0xFA, 0xA0, 0xB4, 0x85, 0x95, 0x10, 0x6F, 0x91, 0x82, 0x89, 0xE8, 0x46, 0xEE, 0x51, 0xEB, 0x2A, 0x45, 0xAC, 0x93, 0x87, 0x48, 0x8C, 0xB6, 0x02, 0xB4, 0x4D, 0xC6, 0xFC, 0x51, 0x4C, 0x75, 0x9D, 0x5A, 0xE7, 0x46, 0x5B, 0x0A, 0x9D, 0x75, 0xA3, 0x0C, 0xB2, 0x54, 0x2A, 0x3E, 0x3A, 0x25, 0xA3, 0x75, 0x66, 0x52, 0x61, 0x7A, 0x78, 0xED, 0xDD, 0x7E, 0xF2, 0x4A, 0xA6, 0xB6, 0x3D, 0xEA, 0x62, 0xE4, 0x68, 0x95, 0x74, 0x3D, 0x45, 0xC1, 0x6E, 0x6B, 
-                       0xB6, 0x6E, 0x8F, 0x97, 0x39, 0xB5, 0x4F, 0xAA, 0x8E, 0xBB, 0x55, 0x10, 0x19, 0xCB, 0x66, 0xA0, 0xBF, 0xAE, 0x8B, 0xE6, 0xBC, 0x92, 0x8D, 0x2D, 0xC1, 0x83, 0x87, 0x53, 0x81, 0x32, 0x3B, 0x8E, 0x80, 0x76, 0xF9, 0xDE, 0x60, 0x8F, 0x99, 0x02, 0x4F, 0x97, 0x73, 0x3D, 0xE3, 0xC7, 0xBA, 0xBD, 0x4C, 0x3F, 0x8A, 0x9B, 0xE3, 0xFE, 0x24, 0xC3, 0x3E, 0xDE, 0x02, 0x0F, 0x46, 0x84, 0x79, 0xDF, 0x5E, 0xC9, 0xA3, 0x7C, 0x58, 0x62, 0xFC, 0x1D, 0x9F, 0x5E, 0x9A, 0xDB, 0x3C, 0x45, 0x96, 0x91, 0xFD, 0xD9, 0xD0, 0xE7, 0x7F, 0x72, 0xBA, 0x2D, 0xC5, 0x3A, 0x54, 0xBC, 0xA0, 0xAE, 0xAA, 0xFF, 0xE9, 0x18, 0x0C, 0x1B, 
-                       0x9A, 0xD4, 0xDA, 0x82, 0xBF, 0x51, 0x23, 0xB3, 0x6E, 0xEF, 0xDB, 0x85, 0xE5, 0xBF, 0x02, 0xCC, 0xFB, 0x79, 0xA6, 0x45, 0x86, 0xDC, 0xDF, 0xF0, 0x2C, 0x15, 0x0B, 0xD1, 0xE5, 0x80, 0xBB, 0x3F, 0x65, 0x94, 0xE5, 0xAB, 0x76, 0xE4, 0xA5, 0x92, 0x7D, 0x0E, 0x8C, 0xC0, 0x92, 0x83, 0x40, 0x9D, 0x2F, 0xBD, 0x30, 0xE1, 0x7B, 0xB5, 0x91, 0xB2, 0x5E, 0xD9, 0xC6, 0xB7, 0xA4, 0x30, 0x06, 0x18, 0xED, 0x33, 0x95, 0x7B, 0xA6, 0xE3, 0xE5, 0xC0, 0x4B, 0xF5, 0x0B, 0x6A, 0x3A, 0xF5, 0xAC, 0x77, 0x22, 0xC0, 0x84, 0x3C, 0x5B, 0xE5, 0x55, 0xD5, 0xDC, 0x7E, 0xFE, 0x08, 0x02, 0x37, 0x69, 0x52, 0xB8, 0x44, 0x29, 0x16, 
-                       0xB5, 0xE8, 0x8A, 0xA4, 0xAC, 0x24, 0x58, 0xC3, 0x53, 0xAC, 0x37, 0xE2, 0xD4, 0x0F, 0x21, 0xC1, 0x54, 0x62, 0x28, 0xCA, 0xA3, 0x8C, 0x01, 0x26, 0x97, 0xFF, 0xAD, 0x0E, 0x5F, 0xB1, 0x86, 0x96, 0xD1, 0xFA, 0xE5, 0x9F, 0x38, 0x42, 0x4D, 0x32, 0xEB, 0xC8, 0x4B, 0x4A, 0x01, 0x91, 0x5C, 0xCE, 0xC8, 0x89, 0x0A, 0x7C, 0x32, 0x6D, 0x08, 0x3E, 0x7D, 0xB0, 0x3D, 0x16, 0x99, 0x52, 0xB0, 0xE0, 0xBE, 0xFF, 0x42, 0x61, 0xC3, 0x56, 0xE1, 0x9A, 0xA3, 0xFB, 0x72, 0xBB, 0x3B, 0x4C, 0xA3, 0xFC, 0x5E, 0xFE, 0xC7, 0xF2, 0xBB, 0x17, 0x96, 0x00, 0xB6, 0x02, 0xD1, 0x58, 0xF0, 0xDA, 0x63, 0xD2, 0x4C, 0x91, 0xDF, 0xFA, 
-                       0xB5, 0xAF, 0x1E, 0xDA, 0xD7, 0x02, 0x85, 0xFE, 0x80, 0x94, 0x77, 0x92, 0x84, 0x9A, 0x2F, 0x1C, 0xC2, 0x71, 0xA7, 0x3F, 0xFA, 0x00, 0xFC, 0x7E, 0x4B, 0xE2, 0xD2, 0x7B, 0xC8, 0xB9, 0x26, 0xEC, 0xD4, 0x7A, 0x3D, 0x6F, 0x89, 0xB4, 0x22, 0x2F, 0xE9, 0x41, 0xA9, 0x97, 0x8C, 0x76, 0xCE, 0xCD, 0xA6, 0x94, 0xA9, 0x1D, 0x25, 0x7C, 0x4D, 0xCF, 0x2E, 0x51, 0x59, 0xE9, 0xE3, 0xDB, 0x84, 0x28, 0x2E, 0x31, 0x24, 0xF9, 0xA7, 0xC0, 0xA7, 0x77, 0xD0, 0xB5, 0x19, 0x1C, 0xC9, 0x22, 0x28, 0x94, 0x39, 0xF5, 0xC3, 0xAA, 0x78, 0x3A, 0xE6, 0x1D, 0xB3, 0xCA, 0x95, 0x7F, 0x7D, 0xBD, 0xFA, 0x7F, 0xCD, 0x09, 0xA5, 0x77, 
-                       0x8E, 0xC8, 0xEB, 0x03, 0x26, 0xAF, 0x38, 0x5A, 0x9A, 0xFB, 0xDC, 0x90, 0xBD, 0xD7, 0x46, 0xA7, 0xB4, 0x71, 0x8F, 0xF7, 0x66, 0x4A, 0x07, 0x66, 0xE4, 0xD7, 0x3E, 0xC4, 0xD4, 0x2B, 0x15, 0x1F, 0xC8, 0x9C, 0x3A, 0x47, 0x5E, 0x6F, 0x84, 0xE3, 0x02, 0x62, 0x05, 0x86, 0x63, 0x30, 0x37, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0x62, 0x54, 0xAE, 0x53, 0x8C, 0x33, 0xEC, 0x3E, 0x2D, 0x73, 0xE6, 0xEB, 0x9A, 0xDD, 0x31, 0xEE, 0x06, 0x83, 0x4B, 0xBA, 0x04, 0x14, 0x60, 0x9B, 0x73, 0xDD, 0x3F, 0x8F, 0x2E, 0x52, 0x1C, 0x4C, 0xB9, 0x8E, 0x7A, 0xC0, 0xCD, 0x52, 0xB4, 0xBA, 
-                       0xBD, 0x8C };
-
-               static public byte[] farscape_path_pfx = { 0x30, 0x82, 0x0B, 0x53, 0x02, 0x01, 0x03, 0x30, 0x82, 0x0B, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x0B, 0x04, 0x04, 0x82, 0x0B, 0x00, 0x30, 0x82, 0x0A, 0xFC, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
-                       0x0E, 0x04, 0x08, 0x38, 0xE0, 0x5B, 0xD2, 0xF6, 0x07, 0x19, 0xE1, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0x1B, 0xCB, 0x34, 0x7D, 0x3A, 0x5F, 0x9A, 0xA9, 0x87, 0xD7, 0x17, 0xCF, 0x5D, 0xAD, 0x94, 0xB8, 0x36, 0xCD, 0xEC, 0x1B, 0xDF, 0x58, 0xA9, 0x99, 0x18, 0x75, 0xC8, 0x9D, 0x4F, 0x2D, 0xED, 0x82, 0x10, 0x18, 0xFC, 0x9A, 0x89, 0x3D, 0xAC, 0x3C, 0xC3, 0x26, 0x5F, 0x2B, 0x72, 0x48, 0xD5, 0xA3, 0xFA, 0x12, 0x57, 0x7E, 0x60, 0x05, 0xA1, 0x2B, 0x20, 0xAF, 0xB4, 0x3B, 0x1A, 0x38, 0xA4, 0xED, 0x0A, 0x25, 0xA3, 0x4B, 0xBF, 0xAB, 0x64, 0x26, 0xE9, 0xB5, 0x6E, 0xE1, 0x94, 0x44, 0xFA, 0x13, 0x14, 
-                       0x0B, 0x49, 0x76, 0xCB, 0xB8, 0x68, 0xD0, 0x64, 0xEE, 0xB6, 0xBC, 0xA4, 0xD1, 0x30, 0x8C, 0xEF, 0xC9, 0xA7, 0x07, 0x6F, 0x0E, 0xAA, 0xF7, 0x48, 0xA7, 0xE1, 0x7A, 0x3B, 0x85, 0x75, 0x79, 0x65, 0x51, 0xE9, 0xA7, 0x1A, 0x6C, 0xE3, 0x08, 0x99, 0x48, 0x4B, 0xC5, 0x66, 0xC5, 0x73, 0xB3, 0x5B, 0x99, 0x60, 0xDF, 0x8E, 0x3D, 0xB8, 0x04, 0x09, 0xA2, 0x2D, 0x70, 0xBF, 0x6F, 0x00, 0x9D, 0x1B, 0x3F, 0xE0, 0xE7, 0xDE, 0x05, 0x71, 0x54, 0x3F, 0x2D, 0x29, 0x3A, 0xFD, 0x44, 0xE6, 0x7F, 0x30, 0x9B, 0x71, 0x43, 0x55, 0x78, 0x40, 0x74, 0x6D, 0x11, 0x64, 0xBB, 0x04, 0xB7, 0x36, 0xE0, 0xA4, 0x45, 0x74, 0xBC, 0xC4, 
-                       0xC2, 0x40, 0xA5, 0xF1, 0x62, 0x9D, 0x59, 0x18, 0xAD, 0x3D, 0xD6, 0xDB, 0x9A, 0xF3, 0x34, 0x36, 0x8B, 0x0C, 0xAF, 0xC8, 0x72, 0x82, 0x9F, 0x34, 0xC2, 0xE0, 0x96, 0xB4, 0x57, 0xB9, 0x02, 0x8E, 0x00, 0x3F, 0xC6, 0x8A, 0x62, 0x02, 0xFE, 0x15, 0xCB, 0xAE, 0x49, 0xD7, 0x06, 0x4F, 0xFC, 0xF3, 0x93, 0xC1, 0x0F, 0x78, 0x8F, 0xD6, 0xEE, 0xD7, 0xB4, 0x6F, 0xA4, 0xD8, 0x62, 0x13, 0x27, 0x81, 0x58, 0xEC, 0x04, 0x44, 0xB6, 0x47, 0xBB, 0xAA, 0xEA, 0x51, 0x44, 0xF1, 0xD3, 0x2D, 0x7E, 0x79, 0xED, 0xF0, 0x3D, 0x05, 0xA0, 0xC5, 0x61, 0x05, 0x2A, 0xE3, 0x08, 0xF1, 0xD9, 0xFC, 0x85, 0x18, 0xF7, 0x49, 0xEE, 0x33, 
-                       0x01, 0xD8, 0xE1, 0x3C, 0x69, 0xC5, 0x99, 0xE4, 0xA3, 0xCE, 0xBE, 0xA8, 0x19, 0x6A, 0x76, 0x63, 0x09, 0xD3, 0xD3, 0x3B, 0x56, 0x5A, 0xEA, 0x90, 0x6F, 0x2A, 0xA9, 0x24, 0x6C, 0x30, 0x2F, 0x89, 0x8C, 0x77, 0x79, 0xC1, 0x5A, 0x6A, 0xFD, 0xEC, 0x42, 0x5E, 0xAF, 0x75, 0xDE, 0xC9, 0x08, 0x26, 0xCE, 0x2C, 0xF2, 0xBD, 0x86, 0x92, 0x1B, 0xBB, 0x51, 0x84, 0x56, 0xB7, 0x9D, 0x1C, 0x21, 0x31, 0x02, 0xFC, 0xCA, 0x6F, 0xDB, 0x71, 0xC2, 0x5B, 0x13, 0x5C, 0x96, 0x50, 0x14, 0x3B, 0x80, 0x0B, 0x23, 0xB1, 0x21, 0xCE, 0x63, 0x76, 0x7F, 0x0C, 0x00, 0x32, 0xE7, 0x7E, 0x60, 0x6E, 0x76, 0x61, 0xF5, 0xAC, 0xCF, 0xA2, 
-                       0xDC, 0xE6, 0x65, 0xD3, 0x01, 0xD4, 0x9C, 0x26, 0xDA, 0xF3, 0xAD, 0x00, 0xE2, 0x56, 0x24, 0xF2, 0x3F, 0x75, 0x7B, 0xEE, 0x2D, 0xB2, 0xCC, 0xF2, 0x0A, 0x14, 0x90, 0xC4, 0x2A, 0x79, 0xDE, 0x2A, 0x35, 0x66, 0xBC, 0xC2, 0x55, 0xDC, 0xB9, 0x0F, 0xC8, 0x08, 0x51, 0xCE, 0x40, 0xAD, 0x5E, 0xB8, 0xDD, 0xA0, 0x2C, 0x4C, 0x96, 0x99, 0x3B, 0x8F, 0x0B, 0xCC, 0x00, 0xA1, 0x37, 0xF5, 0xDB, 0xE2, 0xF8, 0x15, 0xA1, 0xC3, 0xCE, 0x6B, 0xDE, 0x3F, 0xE9, 0x52, 0x9D, 0x07, 0x2E, 0xBC, 0x7A, 0x67, 0x94, 0x19, 0x50, 0x32, 0xFC, 0x1E, 0x6E, 0x9A, 0x94, 0xDD, 0xB6, 0x87, 0x3D, 0x44, 0xA1, 0xA4, 0x95, 0x7A, 0x10, 0x3E, 
-                       0xAD, 0x73, 0x5E, 0xA8, 0xCF, 0x35, 0x0E, 0x6D, 0x48, 0xE7, 0xC5, 0x2D, 0x91, 0xAB, 0x56, 0xF5, 0x6B, 0x4B, 0xBC, 0x65, 0xB9, 0x3A, 0x7D, 0x46, 0x8E, 0xD0, 0xC0, 0x71, 0x0F, 0x12, 0x0D, 0xFD, 0x50, 0x49, 0xFF, 0x23, 0x0A, 0xC2, 0xA0, 0xB1, 0xD9, 0x5D, 0x08, 0xFE, 0xDB, 0x52, 0x91, 0xD0, 0x8D, 0x60, 0x7D, 0xDC, 0x77, 0x0A, 0x99, 0xBF, 0xC5, 0x42, 0xFB, 0x0D, 0x44, 0x38, 0xF4, 0xC4, 0xB1, 0xF2, 0x87, 0x8B, 0x26, 0x3C, 0x2D, 0x1C, 0xE2, 0x67, 0xEE, 0xF6, 0x84, 0xB8, 0x04, 0xE8, 0x2B, 0x8D, 0x7C, 0x59, 0x0F, 0x70, 0xF5, 0x60, 0xEA, 0x44, 0x1F, 0xB8, 0xB8, 0xCB, 0xEB, 0xFC, 0xBE, 0xBE, 0x82, 0xA6, 
-                       0xBB, 0x1B, 0x77, 0x26, 0x58, 0x45, 0xA6, 0x4B, 0x0A, 0x92, 0x86, 0xC4, 0x52, 0xEA, 0x72, 0xA4, 0xCF, 0x72, 0xB8, 0x98, 0x40, 0x76, 0x2D, 0x2D, 0xB2, 0xCD, 0xC0, 0x0D, 0x0F, 0x96, 0x8A, 0xA0, 0x39, 0xD2, 0xF0, 0x79, 0xD9, 0x19, 0xE3, 0x12, 0x40, 0xAB, 0x49, 0x3F, 0xC9, 0x97, 0x3D, 0x25, 0xFF, 0xCF, 0xEC, 0x01, 0xBF, 0xE3, 0x4E, 0xB4, 0x3B, 0x8F, 0x64, 0xDC, 0x70, 0xDA, 0xA0, 0xE6, 0x1C, 0x09, 0x95, 0x6B, 0xCF, 0x16, 0xBF, 0x44, 0xA5, 0xFA, 0x36, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
-                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
-                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x07, 0x67, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x07, 0x58, 0x30, 0x82, 0x07, 0x54, 0x02, 0x01, 0x00, 0x30, 0x82, 0x07, 0x4D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
-                       0x06, 0x30, 0x0E, 0x04, 0x08, 0xB7, 0xF8, 0xA2, 0x70, 0xCF, 0xB6, 0x51, 0x48, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x07, 0x20, 0x5E, 0x23, 0x13, 0x6E, 0x0A, 0x69, 0x00, 0x0C, 0xDA, 0xAD, 0xA8, 0xC8, 0xF8, 0xAC, 0xDC, 0x31, 0x49, 0xB8, 0x96, 0xF3, 0x75, 0x0F, 0x1C, 0xEF, 0x68, 0xA2, 0x9F, 0xB3, 0xE3, 0xB0, 0x39, 0x81, 0x61, 0x95, 0x86, 0x5A, 0x99, 0x6C, 0x6C, 0x84, 0xE6, 0x8D, 0x8D, 0xD9, 0x2E, 0xA8, 0xE9, 0x3B, 0xC6, 0x74, 0xB1, 0xD1, 0xCA, 0xC2, 0x38, 0x8C, 0x0C, 0xB4, 0x06, 0x29, 0x26, 0x52, 0x35, 0x68, 0x28, 0xA6, 0xF4, 0x7B, 0x0A, 0xE0, 0xBC, 0xA9, 0xBD, 0xAC, 0x5F, 0xFF, 0x06, 0x56, 0x70, 
-                       0xE1, 0xB0, 0x11, 0x2B, 0x17, 0x4B, 0x0A, 0x8C, 0x42, 0x77, 0xD1, 0xF8, 0x08, 0x28, 0x73, 0x60, 0x5A, 0xC1, 0xD9, 0x3F, 0x60, 0x40, 0x21, 0xC6, 0x33, 0x9D, 0x44, 0xF6, 0x98, 0xF4, 0x52, 0xFB, 0x57, 0x6D, 0x1E, 0x9A, 0x52, 0xF6, 0x11, 0xAD, 0xA0, 0xE4, 0xFE, 0x0E, 0xEB, 0x3F, 0xDE, 0x7C, 0xB7, 0x82, 0x04, 0x1C, 0x78, 0xFD, 0xEB, 0x99, 0x4D, 0x8E, 0xEE, 0xCA, 0xB2, 0x4F, 0xD1, 0x47, 0x5B, 0xAA, 0x4A, 0xEB, 0x16, 0xBF, 0x50, 0x93, 0xBF, 0xDF, 0x57, 0x6A, 0x8A, 0xBD, 0x4E, 0xED, 0x72, 0x5D, 0x50, 0x59, 0xC7, 0x4F, 0x4F, 0xB5, 0x7E, 0x4F, 0xA3, 0xC2, 0x51, 0x3B, 0x31, 0x12, 0x14, 0xCC, 0x2E, 0x1C, 
-                       0xC4, 0xD3, 0xC2, 0x89, 0xD3, 0x6A, 0xC4, 0x16, 0xAA, 0x13, 0x83, 0xD6, 0x30, 0xD6, 0x76, 0xE0, 0x16, 0xCF, 0x28, 0x25, 0xA8, 0xFB, 0x25, 0xBC, 0x82, 0xEF, 0xD4, 0xC4, 0x64, 0x3B, 0xE0, 0xC0, 0x91, 0xC0, 0x21, 0x17, 0x43, 0x8F, 0xCB, 0xCE, 0xD3, 0x2B, 0x7B, 0x11, 0x5E, 0x73, 0x62, 0x17, 0x9E, 0xB4, 0x00, 0xF7, 0xB3, 0x7E, 0x24, 0xC9, 0x21, 0xB8, 0xF7, 0x33, 0x02, 0x04, 0xB9, 0xDE, 0x6C, 0x97, 0xC4, 0x3B, 0xCF, 0xDE, 0xC4, 0xF7, 0x2A, 0x68, 0x8A, 0x82, 0x22, 0xA1, 0x95, 0xBB, 0x9E, 0xF6, 0x6C, 0xBB, 0x0E, 0x69, 0x83, 0x55, 0xE2, 0x5A, 0x5F, 0x60, 0x2E, 0x43, 0x41, 0xD1, 0xB8, 0xAB, 0x17, 0x3A, 
-                       0x4C, 0xA8, 0xB9, 0x81, 0xFF, 0x40, 0x28, 0x50, 0x67, 0xCF, 0x3A, 0x01, 0x5D, 0xCC, 0x09, 0xD2, 0x2D, 0x2A, 0x7D, 0x4E, 0xDA, 0x88, 0x85, 0x26, 0x03, 0x05, 0x41, 0x2B, 0x7A, 0x4B, 0xEC, 0x1A, 0xBC, 0xDF, 0xD6, 0x98, 0xFA, 0x22, 0x9D, 0xFA, 0xE3, 0x7D, 0x37, 0x5B, 0x5E, 0xFF, 0x54, 0xB3, 0x48, 0x50, 0x0D, 0xDC, 0x93, 0xD4, 0xF8, 0xC7, 0x05, 0x66, 0xC7, 0xAC, 0x9C, 0x87, 0x4A, 0x90, 0xCE, 0x2E, 0xF3, 0x4C, 0x7E, 0x90, 0xC5, 0xE5, 0x20, 0x2C, 0xD9, 0x24, 0xB4, 0x2C, 0x51, 0x57, 0x1F, 0xD9, 0x24, 0x3C, 0xFA, 0x94, 0x0E, 0xAB, 0xAA, 0x6A, 0x42, 0xFE, 0x9D, 0xE7, 0x53, 0xD6, 0xC2, 0x1D, 0x5F, 0x2E, 
-                       0x79, 0x86, 0x02, 0xDB, 0xD0, 0x8B, 0x0C, 0xD7, 0x43, 0x96, 0x60, 0x2B, 0x4A, 0x8F, 0xEE, 0xE3, 0x19, 0x61, 0x47, 0x82, 0x87, 0x6F, 0x70, 0xB6, 0xE2, 0x3F, 0x17, 0x66, 0x21, 0xE1, 0x53, 0x61, 0xC2, 0xD3, 0xE8, 0x26, 0x02, 0x68, 0x2A, 0x80, 0xC8, 0xFD, 0x8A, 0xA8, 0xCC, 0xD5, 0xAA, 0xCB, 0x14, 0xDD, 0x5A, 0x7D, 0x4A, 0xCA, 0x39, 0xE1, 0x51, 0x8A, 0x26, 0x8A, 0xDA, 0xE2, 0x54, 0x92, 0x28, 0x6E, 0x63, 0x3F, 0x9A, 0x50, 0xC0, 0x5C, 0x76, 0xE2, 0x98, 0x94, 0xFB, 0xBC, 0xAD, 0x93, 0x2C, 0x97, 0xDF, 0x15, 0x20, 0x7D, 0x4F, 0x28, 0xD5, 0xD1, 0x5D, 0x35, 0x8B, 0x5B, 0x96, 0x77, 0x34, 0xDD, 0xA3, 0x07, 
-                       0x44, 0xFB, 0xCD, 0x72, 0x2B, 0x12, 0xD5, 0x1D, 0x23, 0xA1, 0x51, 0x04, 0xF8, 0x9D, 0xF8, 0xFF, 0x0F, 0x39, 0x0F, 0x05, 0x33, 0x24, 0x0A, 0x1F, 0xD1, 0xB5, 0xA8, 0x75, 0x39, 0x41, 0xE8, 0xD5, 0x99, 0x1D, 0x9B, 0x45, 0xFC, 0x32, 0x20, 0x6E, 0xFA, 0x96, 0x80, 0xDD, 0x88, 0x5D, 0x3B, 0x12, 0x1C, 0xC6, 0x86, 0xFA, 0x27, 0x4A, 0x78, 0x46, 0xE2, 0xC0, 0xCC, 0x66, 0x01, 0xE8, 0x30, 0x32, 0x26, 0x42, 0xDE, 0x8B, 0x71, 0xE8, 0x09, 0x9C, 0xF4, 0x90, 0x71, 0x17, 0x66, 0xFE, 0x0A, 0x0F, 0xD4, 0x84, 0x13, 0xFB, 0x66, 0x99, 0x98, 0xAF, 0xD8, 0x16, 0x13, 0x15, 0xAD, 0x18, 0xBE, 0x49, 0x02, 0xAB, 0x42, 0x50, 
-                       0x14, 0xB7, 0x3B, 0x33, 0x3C, 0x22, 0xA9, 0xE1, 0xC5, 0x32, 0xCD, 0x8D, 0xB4, 0x31, 0xF9, 0x27, 0x6C, 0x50, 0x0B, 0x40, 0x5E, 0xBE, 0x02, 0xB5, 0x27, 0xC4, 0x0D, 0x2C, 0xD5, 0xAB, 0x8A, 0x58, 0x5E, 0x53, 0xAD, 0x9C, 0x0D, 0x5B, 0x06, 0xE8, 0x77, 0x24, 0x94, 0xAD, 0xC0, 0x2C, 0x17, 0x8F, 0x20, 0x70, 0xC8, 0x29, 0xEB, 0x9B, 0x84, 0x4A, 0x91, 0xA5, 0xEC, 0x85, 0x2C, 0xCF, 0x68, 0xC9, 0x72, 0xEB, 0x3D, 0x63, 0xE9, 0xDB, 0x7D, 0xBB, 0x3D, 0xBE, 0x9A, 0x37, 0x91, 0x07, 0xE5, 0x95, 0x39, 0x63, 0xB0, 0x3F, 0x46, 0xEA, 0xB7, 0x76, 0x82, 0x05, 0xE1, 0xFF, 0x7C, 0x14, 0x41, 0x0F, 0x74, 0x3E, 0x43, 0xCD, 
-                       0x87, 0x5A, 0xA7, 0x30, 0x61, 0x29, 0xE2, 0xBA, 0x59, 0x7F, 0xF3, 0xBF, 0x78, 0x1C, 0x4A, 0xB8, 0x59, 0xEF, 0x9D, 0xE3, 0xFD, 0xEB, 0xE9, 0x39, 0xA9, 0xDF, 0x3D, 0xC9, 0xD4, 0x42, 0x5F, 0x79, 0xCA, 0xFC, 0xEE, 0xFE, 0xA0, 0x88, 0x30, 0x78, 0x69, 0x37, 0xA0, 0xC2, 0x64, 0xBC, 0x41, 0x65, 0xDB, 0xB8, 0xB0, 0x99, 0xC7, 0xD5, 0xF9, 0x03, 0x05, 0x98, 0x5A, 0xAB, 0x76, 0xB5, 0x0D, 0x7B, 0xDF, 0x9B, 0xFA, 0x92, 0x5D, 0xBD, 0x52, 0x30, 0xB7, 0x0F, 0xE8, 0x60, 0x97, 0xCC, 0xF5, 0x66, 0xA2, 0xD0, 0x77, 0x9E, 0x6B, 0x5C, 0xF2, 0x41, 0x20, 0x21, 0x6D, 0x0C, 0xE1, 0xB6, 0x26, 0xD8, 0xD9, 0x66, 0x94, 0xC0, 
-                       0x55, 0x4E, 0xCC, 0xBC, 0x2D, 0xDC, 0xC3, 0x23, 0x17, 0x9C, 0x7F, 0xA6, 0x75, 0x38, 0x33, 0xBB, 0x49, 0xBE, 0xF0, 0x77, 0xCB, 0xE7, 0xB2, 0xF5, 0x40, 0xE3, 0xD5, 0xCC, 0x1F, 0x83, 0x50, 0xA5, 0x2E, 0x1B, 0x17, 0xBD, 0x63, 0x8C, 0x9F, 0x99, 0x30, 0x41, 0xC8, 0x0D, 0x8B, 0x05, 0x80, 0x67, 0x03, 0x60, 0xCF, 0x2A, 0xA0, 0x55, 0x14, 0x74, 0xA7, 0xEA, 0x43, 0x3F, 0x5A, 0x03, 0x0B, 0xEF, 0x3F, 0xC8, 0xAA, 0x03, 0xB9, 0x1B, 0xC6, 0xB9, 0x63, 0xD4, 0x9C, 0xA1, 0x42, 0x18, 0x32, 0x12, 0x87, 0xEA, 0x44, 0xB9, 0xA8, 0x72, 0xA8, 0x75, 0xB4, 0x09, 0xEB, 0x90, 0x7F, 0xB5, 0x00, 0x39, 0xDE, 0x2C, 0x07, 0x87, 
-                       0xB5, 0x35, 0xDD, 0x44, 0x03, 0x09, 0xA9, 0xA0, 0xD6, 0x40, 0x69, 0x88, 0xC9, 0x2A, 0xDB, 0x3E, 0x56, 0xEF, 0x42, 0x23, 0xB7, 0x4D, 0x62, 0xDA, 0x56, 0x1C, 0xC5, 0xC1, 0x4D, 0x07, 0x02, 0x14, 0x7E, 0xE7, 0x6D, 0x38, 0x05, 0x70, 0x19, 0x77, 0xA6, 0x46, 0xE9, 0x18, 0x3E, 0x06, 0xEE, 0x5A, 0xCA, 0x35, 0xE3, 0xCD, 0xAA, 0x4C, 0x89, 0x5D, 0x41, 0x85, 0x17, 0x53, 0x18, 0x86, 0x3D, 0x20, 0x18, 0x53, 0x1D, 0xF8, 0x4C, 0x09, 0x2C, 0x48, 0x75, 0x00, 0xF8, 0xD1, 0xF4, 0xA5, 0xD7, 0x29, 0xB5, 0xFF, 0x42, 0xFA, 0x6B, 0xCB, 0x47, 0x0F, 0x33, 0x00, 0x59, 0x54, 0x07, 0x62, 0x5C, 0xC7, 0x57, 0x63, 0xB4, 0x32, 
-                       0x5C, 0xF1, 0x8E, 0xBA, 0x6D, 0x0E, 0x85, 0x3B, 0x3D, 0xE7, 0xAA, 0x31, 0x61, 0x77, 0x3F, 0x77, 0xF4, 0x1F, 0xD7, 0x6C, 0x5F, 0x13, 0xCF, 0xB5, 0x9A, 0xAC, 0x6F, 0x2C, 0x49, 0x2D, 0xDD, 0xED, 0x27, 0xA9, 0x77, 0x1F, 0x38, 0x78, 0x16, 0x82, 0x00, 0xB3, 0xD9, 0x8E, 0xFA, 0x43, 0xE2, 0x54, 0xB7, 0x36, 0xED, 0x20, 0x33, 0x1A, 0x7E, 0x0E, 0xF2, 0xEE, 0x20, 0xE7, 0x10, 0xC4, 0xB6, 0x07, 0x0A, 0x42, 0x26, 0xCA, 0xC1, 0x6C, 0x29, 0xA1, 0xBD, 0x05, 0xE0, 0x70, 0xED, 0x17, 0x7C, 0x21, 0xD3, 0x9F, 0x72, 0xE7, 0x47, 0xA3, 0x5F, 0xCA, 0x50, 0x4C, 0x3C, 0x16, 0x9D, 0x20, 0x49, 0x7B, 0x9A, 0x53, 0xCF, 0x7C, 
-                       0x9B, 0x69, 0x5E, 0xE0, 0x56, 0xB0, 0x60, 0xFB, 0xC6, 0xE8, 0x67, 0x31, 0x18, 0xDB, 0x67, 0xA2, 0x61, 0xE2, 0x8E, 0x35, 0xFA, 0xBD, 0xED, 0x43, 0x32, 0xCA, 0x99, 0xAC, 0xF7, 0xCB, 0xB8, 0x1E, 0x57, 0x2D, 0xC7, 0xB4, 0x2A, 0xEA, 0x53, 0xCE, 0xDB, 0xD7, 0xE6, 0x8F, 0x9A, 0x98, 0x12, 0xE3, 0xB0, 0x7E, 0x85, 0x1B, 0x6B, 0x2F, 0xE3, 0xD0, 0x54, 0x5C, 0x31, 0xC0, 0x96, 0xE8, 0x04, 0xD9, 0x87, 0x8F, 0x8A, 0xC9, 0xC1, 0x95, 0x31, 0x11, 0x66, 0xC3, 0x86, 0x06, 0x93, 0xC4, 0xDC, 0x6F, 0xD7, 0x7C, 0x65, 0xF3, 0xF9, 0xB1, 0x6F, 0x34, 0xD8, 0x25, 0x21, 0x02, 0x1B, 0x12, 0x52, 0x19, 0xD0, 0xED, 0xB8, 0x4A, 
-                       0x67, 0x1E, 0x49, 0x2C, 0xDD, 0x47, 0xA7, 0x0A, 0x1F, 0x21, 0x67, 0x5A, 0x0F, 0x34, 0xDB, 0x6D, 0x1E, 0xFB, 0x71, 0xBC, 0xB9, 0x8F, 0x84, 0xE4, 0x3A, 0xE4, 0x47, 0x93, 0x48, 0xC2, 0xCA, 0xDA, 0x5B, 0x7B, 0xA0, 0x3F, 0x2F, 0x9C, 0x68, 0xDC, 0x72, 0x15, 0x18, 0x57, 0xBA, 0x32, 0x6B, 0x92, 0x08, 0x08, 0x65, 0xA5, 0x30, 0xA4, 0xED, 0x35, 0x80, 0xC5, 0xD3, 0x93, 0x01, 0x36, 0x53, 0x8E, 0xC9, 0xF6, 0x2D, 0xCA, 0xB9, 0xE6, 0xE9, 0x94, 0x89, 0xE3, 0x05, 0x81, 0x9B, 0x69, 0x0B, 0xD7, 0xD2, 0x55, 0x0A, 0xFE, 0xAF, 0x98, 0x97, 0xB9, 0xCB, 0xB8, 0xCB, 0xB6, 0x48, 0xD1, 0xB4, 0xF1, 0xD2, 0x19, 0x53, 0xB1, 
-                       0xCE, 0x4E, 0x3D, 0x11, 0xF3, 0xC6, 0x89, 0xFC, 0x68, 0x48, 0x4C, 0xF9, 0x11, 0x1B, 0xDF, 0x10, 0x21, 0x44, 0x2C, 0x43, 0xCC, 0x00, 0x0D, 0xC8, 0x40, 0x6D, 0xDB, 0xCE, 0xC7, 0xBF, 0xA4, 0xCF, 0x6C, 0xAF, 0x71, 0xF4, 0x72, 0xB8, 0xF4, 0x32, 0x19, 0xD2, 0xFC, 0xFE, 0x28, 0xC8, 0x00, 0x44, 0xB9, 0xEC, 0x70, 0x5B, 0xF5, 0x39, 0xDC, 0xBD, 0xF4, 0xEF, 0xC3, 0x8A, 0xF1, 0x06, 0x52, 0x90, 0xAF, 0x18, 0x45, 0xF1, 0xC7, 0x10, 0x0C, 0xD2, 0xB3, 0xBC, 0xE5, 0xF1, 0x32, 0x6A, 0x0C, 0x55, 0x3E, 0x28, 0x62, 0xC9, 0xC1, 0x12, 0x1F, 0x6E, 0x30, 0x6A, 0x4C, 0x9B, 0x6D, 0x32, 0x18, 0x2D, 0xDD, 0xE6, 0x0F, 0xA5, 
-                       0x0B, 0xBE, 0xBB, 0xF8, 0x8D, 0xF7, 0x40, 0x9F, 0x24, 0xB1, 0x85, 0x17, 0x9F, 0x38, 0x2C, 0xEE, 0x2F, 0x50, 0x99, 0x30, 0x75, 0x95, 0x85, 0xA2, 0xB7, 0xA2, 0x7C, 0x42, 0x58, 0xD9, 0x7D, 0x52, 0xB8, 0x0D, 0xF2, 0x68, 0x57, 0x75, 0xEC, 0x5A, 0xFF, 0xBE, 0xC3, 0xB4, 0x21, 0xE2, 0xA1, 0xCB, 0x60, 0x5F, 0x2A, 0x3A, 0xEE, 0xE0, 0xC3, 0xFB, 0x9A, 0x21, 0x02, 0x86, 0x10, 0xA1, 0xCF, 0x2F, 0x6D, 0x83, 0xBC, 0x09, 0xCE, 0x97, 0x08, 0xDB, 0x6E, 0x17, 0x90, 0xEF, 0x06, 0x2E, 0x19, 0x27, 0xC2, 0x1A, 0x9E, 0xB4, 0xB7, 0x16, 0x1A, 0xF6, 0x92, 0x81, 0x5C, 0xF3, 0x8D, 0x52, 0x87, 0xD1, 0x50, 0x23, 0x78, 0xE5, 
-                       0x81, 0x16, 0x24, 0x12, 0x21, 0xD8, 0x70, 0x30, 0xB4, 0x38, 0x40, 0x7B, 0xBC, 0x21, 0x51, 0xDB, 0x66, 0x15, 0x4C, 0x21, 0x8E, 0xF5, 0x5B, 0x78, 0x65, 0x29, 0x7C, 0xEF, 0x5D, 0xE0, 0x7E, 0x4D, 0xF9, 0x35, 0xC6, 0x97, 0xEA, 0x4A, 0x56, 0xB5, 0xA2, 0x38, 0xAE, 0xF1, 0x50, 0x1A, 0xBE, 0xE8, 0xB1, 0x68, 0xBA, 0xB6, 0x4D, 0x67, 0x63, 0x52, 0x07, 0xBC, 0x4E, 0x68, 0x7C, 0x30, 0x75, 0x16, 0x97, 0x99, 0xD5, 0x8E, 0x14, 0xD9, 0x35, 0x80, 0x35, 0x48, 0xA3, 0x42, 0x3B, 0x60, 0xC0, 0xF7, 0xC5, 0x4E, 0x40, 0xEF, 0x1D, 0xA4, 0x2A, 0x43, 0xD3, 0xA9, 0xB5, 0x3D, 0x72, 0x4D, 0x51, 0x17, 0xFC, 0x92, 0x2F, 0xAC, 
-                       0xC8, 0x81, 0xE1, 0x01, 0x25, 0xBE, 0x89, 0xA9, 0x13, 0x9B, 0xE6, 0xBF, 0x60, 0x9E, 0x43, 0x68, 0x65, 0x34, 0x7A, 0x9C, 0x01, 0x9F, 0xA5, 0x32, 0xFC, 0x06, 0x38, 0x93, 0x4F, 0x15, 0x35, 0x42, 0xAB, 0xB0, 0x36, 0x67, 0x06, 0x4F, 0x2C, 0x70, 0x64, 0x41, 0x31, 0x20, 0x90, 0xA6, 0x3B, 0xC9, 0x99, 0xD8, 0x47, 0x42, 0x64, 0xB6, 0x2B, 0x08, 0xD3, 0x0E, 0x41, 0x19, 0x77, 0xF3, 0x5D, 0x56, 0x05, 0xF2, 0xBC, 0xF9, 0x9A, 0x92, 0x43, 0xD9, 0x18, 0x83, 0x90, 0x13, 0xD8, 0xA1, 0x42, 0x2A, 0x18, 0x2D, 0xD8, 0x1D, 0xE8, 0x50, 0xC5, 0xE8, 0x6F, 0x4F, 0x05, 0x45, 0x74, 0x06, 0x2A, 0x8B, 0x24, 0x33, 0xC0, 0xAA, 
-                       0xAA, 0x84, 0x8A, 0xE2, 0xE8, 0xB0, 0x7E, 0x2D, 0xBD, 0x0C, 0x20, 0xD1, 0x44, 0xAA, 0xCA, 0xC4, 0x83, 0x8C, 0x08, 0xA3, 0x17, 0x36, 0xA1, 0xA1, 0xC2, 0x04, 0xA7, 0x06, 0xCB, 0xB7, 0xF2, 0x64, 0x28, 0x0C, 0xC4, 0x91, 0x0B, 0xDF, 0x93, 0xCB, 0xBE, 0x85, 0x07, 0x11, 0xBB, 0xD8, 0x8A, 0xB1, 0xAB, 0xDC, 0x91, 0x02, 0xDE, 0x4F, 0xE5, 0x6E, 0xC7, 0x96, 0xAB, 0x7E, 0x4A, 0xAA, 0xCF, 0x05, 0x46, 0xE2, 0xB3, 0x52, 0xCD, 0x93, 0x7E, 0xAE, 0xB1, 0x40, 0x61, 0x7E, 0xCB, 0x43, 0x7F, 0xF4, 0x32, 0x8C, 0xA5, 0x0D, 0x52, 0xF7, 0x7A, 0x76, 0xBA, 0x05, 0x14, 0x65, 0xAD, 0x36, 0x85, 0x46, 0x15, 0x00, 0x01, 0xD7, 
-                       0x04, 0xA3, 0xD3, 0x1A, 0xAE, 0x59, 0xEF, 0x6E, 0xBE, 0x39, 0xDF, 0x0D, 0x78, 0xEF, 0x6F, 0x14, 0x02, 0xEC, 0x04, 0xB9, 0xE7, 0x15, 0x54, 0x51, 0x83, 0x75, 0xE2, 0x06, 0x1F, 0x07, 0xD3, 0x82, 0xCB, 0x01, 0x03, 0xE5, 0x43, 0xAC, 0x62, 0x66, 0xF7, 0xCF, 0x74, 0x1B, 0xCD, 0x30, 0x37, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0x84, 0xA8, 0x88, 0x5F, 0xF6, 0x8E, 0xEC, 0x49, 0x94, 0x28, 0xDD, 0xC1, 0xA3, 0xCB, 0xBD, 0x73, 0x4A, 0x76, 0x0E, 0x6B, 0x04, 0x14, 0x7B, 0x11, 0xA6, 0xD2, 0x27, 0x3F, 0x96, 0xC9, 0xA7, 0xEF, 0x06, 0x6D, 0x03, 0xF9, 0xEA, 0x04, 0x2C, 0xC7, 
-                       0xF7, 0x11 };
-
-               static public byte[] farscape_strong_pfx = { 0x30, 0x82, 0x06, 0xA7, 0x02, 0x01, 0x03, 0x30, 0x82, 0x06, 0x63, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x06, 0x54, 0x04, 0x82, 0x06, 0x50, 0x30, 0x82, 0x06, 0x4C, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
-                       0x0E, 0x04, 0x08, 0x21, 0x53, 0x51, 0xD2, 0xB9, 0x79, 0xA4, 0x4F, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0xA2, 0xBA, 0x47, 0x19, 0xE3, 0x35, 0x0B, 0xA1, 0x71, 0x60, 0x65, 0x1A, 0xB0, 0x94, 0xF2, 0xF1, 0xDE, 0x8E, 0xA4, 0x59, 0xF5, 0x07, 0x1B, 0xDF, 0xD2, 0x9C, 0xF4, 0xA2, 0x5C, 0x8C, 0xA7, 0x3F, 0x7E, 0xD3, 0x93, 0x1B, 0x87, 0xA8, 0x1A, 0xA0, 0xDD, 0xF4, 0x0B, 0x76, 0x30, 0xDF, 0xE5, 0x56, 0xAE, 0x26, 0xF7, 0x6C, 0x72, 0x0A, 0x41, 0x0E, 0xD7, 0x42, 0xC3, 0x99, 0x8D, 0x8B, 0xC2, 0x18, 0xBE, 0x30, 0x12, 0xED, 0x20, 0xD3, 0xB3, 0xAF, 0xCD, 0xBE, 0x62, 0xED, 0x6F, 0x55, 0x79, 0x33, 0xCD, 
-                       0x8F, 0x2C, 0x1E, 0x1C, 0xB8, 0xDC, 0x1C, 0x4D, 0x45, 0xCE, 0xE6, 0x1E, 0x81, 0x46, 0xC1, 0x93, 0x1B, 0x7A, 0x41, 0x19, 0x82, 0xED, 0xBF, 0x8F, 0x0F, 0xB1, 0x39, 0x50, 0x58, 0xA2, 0xD2, 0xFB, 0xE6, 0x9A, 0x86, 0x68, 0x2C, 0x58, 0xF9, 0xB3, 0x7C, 0xAC, 0xCC, 0x02, 0xB0, 0x70, 0xC2, 0x5D, 0x0B, 0x7F, 0xC0, 0xA7, 0x60, 0x66, 0x41, 0xBA, 0x4F, 0xE6, 0x89, 0x16, 0x5C, 0x0D, 0x4B, 0x4F, 0x43, 0xF5, 0xFD, 0x5E, 0x22, 0x93, 0x4B, 0x34, 0xC3, 0xEC, 0xA9, 0xCF, 0x92, 0x6F, 0x0E, 0xD6, 0x01, 0x21, 0x48, 0xF4, 0x35, 0xF2, 0xA0, 0xF9, 0x84, 0xD4, 0x30, 0xE0, 0x69, 0xD2, 0xB2, 0x03, 0x3F, 0x3A, 0x5E, 0xFA, 
-                       0x06, 0xA2, 0x30, 0x1B, 0x93, 0xAC, 0x0D, 0x5D, 0x9E, 0xFA, 0x49, 0x29, 0x82, 0xE9, 0x91, 0x40, 0x87, 0x52, 0xF1, 0xED, 0xC3, 0x00, 0x1F, 0x00, 0x54, 0x9F, 0xB6, 0xC7, 0xDE, 0xF4, 0xFB, 0xCF, 0xE7, 0x9B, 0x40, 0x8B, 0x51, 0xEF, 0xFD, 0x33, 0x1C, 0xD9, 0x64, 0x19, 0x45, 0x89, 0x6C, 0x46, 0xA1, 0x9B, 0xA9, 0x93, 0xFE, 0xF8, 0x4D, 0x20, 0x63, 0x34, 0xFB, 0x1B, 0xB9, 0xC8, 0xFE, 0xD4, 0x63, 0xD1, 0x03, 0x57, 0x63, 0xC2, 0xEA, 0xC2, 0xA7, 0x9A, 0x03, 0xEB, 0xC0, 0xF1, 0xAF, 0xB8, 0xD7, 0x37, 0x76, 0x0C, 0xD3, 0x98, 0x21, 0xD2, 0x84, 0x11, 0xD6, 0xBF, 0x29, 0xC8, 0x03, 0xA1, 0xAA, 0xCB, 0xA6, 0x51, 
-                       0xF5, 0xBB, 0xA8, 0xFA, 0x43, 0xFB, 0x59, 0x51, 0x41, 0x1D, 0x2F, 0xF3, 0xFC, 0xF7, 0xA2, 0x4C, 0xEC, 0x47, 0x20, 0x14, 0xF3, 0x46, 0x8B, 0x41, 0x5E, 0x65, 0x2F, 0x18, 0x99, 0x07, 0x23, 0x6B, 0xEA, 0x55, 0x16, 0xE3, 0xA8, 0xB7, 0x31, 0x5C, 0x23, 0xF3, 0xD4, 0x1E, 0xC3, 0xB6, 0xF8, 0x53, 0x26, 0x7D, 0x42, 0x2D, 0x3E, 0xC2, 0xAE, 0x9F, 0x01, 0x83, 0x90, 0x0D, 0xA6, 0xB0, 0x2D, 0xBD, 0x86, 0x31, 0x5A, 0x15, 0x07, 0x6F, 0xA6, 0xFC, 0x35, 0x30, 0x6A, 0xEF, 0xF6, 0xC1, 0xEB, 0x18, 0x01, 0xE9, 0xE7, 0xAA, 0x87, 0x54, 0x4C, 0xAE, 0x98, 0x67, 0xDB, 0xDF, 0xFF, 0x4E, 0xA5, 0xA9, 0xA4, 0x05, 0x11, 0xE9, 
-                       0xA4, 0x1D, 0xB2, 0xB1, 0xD3, 0xF6, 0x77, 0xB6, 0xB5, 0x01, 0xC3, 0x3B, 0xAF, 0x6A, 0xA1, 0x60, 0xB9, 0x14, 0x62, 0x5E, 0x2D, 0x70, 0x25, 0xDF, 0xD3, 0x21, 0x02, 0x3C, 0xD7, 0xF1, 0xF6, 0x0E, 0xD9, 0x4D, 0x59, 0x1A, 0x41, 0x2E, 0x82, 0x28, 0x5C, 0x12, 0x26, 0x68, 0x77, 0xE0, 0x46, 0xC1, 0x0B, 0x9F, 0x15, 0x75, 0x87, 0xD7, 0x87, 0x3A, 0xF6, 0xB4, 0x57, 0x4B, 0x2C, 0x66, 0xD2, 0xCF, 0x47, 0x28, 0x31, 0x8A, 0xDF, 0x54, 0xC5, 0x16, 0x58, 0x23, 0x4F, 0x9E, 0x8D, 0x31, 0xFC, 0x9C, 0xF5, 0x07, 0x03, 0x0F, 0x63, 0xBD, 0xD7, 0x38, 0x65, 0x85, 0x7B, 0xB1, 0xBC, 0x19, 0x3C, 0xEF, 0x41, 0x55, 0xA6, 0x0D, 
-                       0x50, 0x61, 0xB6, 0xA5, 0x9F, 0xF8, 0xD6, 0x15, 0xBF, 0x40, 0x44, 0x2E, 0xD5, 0x12, 0xAA, 0x29, 0xFE, 0x8A, 0x27, 0x68, 0xC4, 0x83, 0xD5, 0x75, 0x78, 0xF7, 0x38, 0x8F, 0x0D, 0xD3, 0xC9, 0x25, 0xAC, 0xF5, 0x3E, 0x7B, 0x11, 0xCB, 0x45, 0xE0, 0x4E, 0x6A, 0x99, 0xD9, 0x24, 0xBD, 0x68, 0x59, 0x02, 0xF9, 0x0D, 0x32, 0x99, 0x87, 0xEA, 0xFA, 0x4D, 0x73, 0x72, 0x44, 0x10, 0x1B, 0xEC, 0x38, 0x04, 0xD4, 0xCD, 0x13, 0x98, 0x5F, 0x0A, 0x3F, 0x76, 0x80, 0x1E, 0x30, 0x89, 0xFF, 0x5D, 0x03, 0x38, 0x1C, 0x25, 0x9E, 0x79, 0x0A, 0xA8, 0x08, 0xAE, 0xAE, 0x28, 0x7A, 0x74, 0x68, 0x60, 0x13, 0x97, 0x48, 0x4C, 0xFA, 
-                       0xB3, 0x63, 0x3A, 0x66, 0xD0, 0xAB, 0x42, 0x35, 0x9B, 0xE6, 0x9D, 0x5D, 0xED, 0x05, 0xC5, 0x29, 0x11, 0xB2, 0x36, 0x21, 0x21, 0x86, 0x16, 0xFD, 0x81, 0xF6, 0x5D, 0x26, 0x75, 0xB2, 0x74, 0xD4, 0xF6, 0x59, 0x62, 0x7B, 0xC2, 0x6D, 0xB9, 0xF0, 0xA6, 0x5A, 0x47, 0xEC, 0x55, 0xEA, 0x35, 0xE0, 0xCE, 0x68, 0x63, 0x88, 0x2D, 0x9A, 0xCC, 0xDC, 0x0E, 0x02, 0xAB, 0x69, 0xFE, 0x22, 0xEC, 0xF5, 0xED, 0x36, 0x7B, 0xE9, 0xC2, 0xA6, 0xBF, 0x0C, 0x1C, 0x19, 0xE7, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
-                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
-                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x02, 0xB7, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x02, 0xA8, 0x30, 0x82, 0x02, 0xA4, 0x02, 0x01, 0x00, 0x30, 0x82, 0x02, 0x9D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
-                       0x06, 0x30, 0x0E, 0x04, 0x08, 0x02, 0x77, 0x79, 0xCA, 0x9F, 0x4E, 0x06, 0xE3, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x02, 0x70, 0x82, 0xE1, 0x66, 0x48, 0xDB, 0x24, 0x9E, 0x33, 0x70, 0x43, 0xFB, 0x6D, 0xD0, 0x47, 0x90, 0xF6, 0xEF, 0xAD, 0x61, 0x28, 0xBF, 0x71, 0x9F, 0x63, 0x2A, 0x69, 0x6C, 0x04, 0x14, 0x34, 0x8A, 0x92, 0xB6, 0x7E, 0x67, 0x50, 0x82, 0x6D, 0x16, 0x8B, 0xB2, 0x18, 0xA4, 0x74, 0x7C, 0xC4, 0x97, 0x50, 0xCE, 0x0B, 0xDB, 0x76, 0xFF, 0xCB, 0x8F, 0x21, 0x4F, 0x50, 0x52, 0x41, 0x0C, 0xA0, 0x98, 0xFB, 0xA8, 0x7F, 0xC0, 0xB4, 0xE3, 0x81, 0x37, 0x12, 0x55, 0x53, 0x5C, 0x3E, 0x95, 0x53, 0x40, 
-                       0x39, 0xAB, 0xD6, 0x5A, 0xBA, 0xB5, 0x87, 0xCF, 0x60, 0x2A, 0x07, 0x2E, 0xAC, 0x56, 0xC0, 0xD1, 0x75, 0xE2, 0xFC, 0xE3, 0x24, 0xDA, 0x32, 0xED, 0x11, 0xC9, 0x53, 0xED, 0x54, 0xB4, 0xE4, 0x36, 0x1F, 0x72, 0x8B, 0xA2, 0xB1, 0x8D, 0x4B, 0x4C, 0x3F, 0x75, 0x4C, 0x2F, 0xE9, 0x78, 0x97, 0xFC, 0xBA, 0x77, 0x68, 0xE4, 0x65, 0x22, 0x67, 0xE5, 0x4D, 0xE9, 0x6A, 0x63, 0x0C, 0x89, 0x91, 0x12, 0xD5, 0x3B, 0x0D, 0xF4, 0x16, 0xA7, 0xE8, 0x57, 0xA8, 0x88, 0xF4, 0x48, 0x95, 0x71, 0x91, 0xAC, 0x69, 0x67, 0xEB, 0xF0, 0xF3, 0x8C, 0xFB, 0x35, 0x4F, 0x0F, 0xAD, 0x8B, 0xFE, 0x8A, 0xCE, 0xE2, 0x75, 0xDF, 0x63, 0x38, 
-                       0xB2, 0xD0, 0xAD, 0x71, 0x5F, 0x97, 0x8B, 0x0C, 0xA7, 0x43, 0xC6, 0x62, 0xC0, 0x60, 0x0F, 0xE6, 0x6A, 0xE9, 0x23, 0x47, 0xD2, 0xC4, 0x1D, 0x90, 0x75, 0x17, 0x14, 0xF3, 0x1B, 0xB9, 0x3A, 0x11, 0xA6, 0x04, 0x52, 0x2B, 0x6B, 0xCB, 0x01, 0xE4, 0x62, 0xB8, 0xD7, 0xE3, 0xB7, 0x1B, 0x6B, 0xF3, 0x20, 0x37, 0x24, 0x87, 0xFB, 0xF0, 0x46, 0x87, 0xC4, 0xAB, 0x88, 0xAC, 0x53, 0x37, 0xD8, 0x87, 0x0E, 0xBB, 0x39, 0x91, 0x1A, 0x8C, 0x90, 0xF8, 0xB4, 0x2A, 0xE2, 0xA9, 0x25, 0xAD, 0xE9, 0x8A, 0x0E, 0xEA, 0x4B, 0x49, 0xC2, 0xE9, 0x5B, 0x5A, 0x3C, 0xAC, 0xE2, 0xE9, 0x3B, 0x27, 0xE6, 0x60, 0x00, 0x49, 0x62, 0xAF, 
-                       0xED, 0x41, 0x7A, 0x8E, 0x95, 0xD2, 0xC2, 0x27, 0x04, 0x9F, 0xE9, 0xEE, 0x50, 0xB5, 0xDF, 0x17, 0x59, 0x46, 0x83, 0xED, 0xB7, 0xFB, 0xCE, 0xE4, 0x35, 0x6E, 0x85, 0x66, 0xA4, 0xF9, 0x11, 0xB9, 0x33, 0xAE, 0x84, 0x9B, 0x73, 0xCC, 0x5E, 0x1A, 0xBE, 0xC6, 0xF6, 0x71, 0x41, 0x07, 0x3F, 0xAF, 0x24, 0xA7, 0x37, 0x12, 0x65, 0x30, 0x87, 0x23, 0xAB, 0x6D, 0xB1, 0xF1, 0xE4, 0x71, 0xEA, 0x87, 0xF4, 0x9E, 0xC9, 0xCA, 0x4E, 0x34, 0xA4, 0x60, 0x80, 0xE5, 0x5E, 0x4A, 0xDF, 0x2B, 0xA5, 0x12, 0x5E, 0x7A, 0x76, 0x7E, 0x82, 0x8B, 0xF7, 0x55, 0x72, 0x79, 0xDC, 0x2A, 0x4C, 0xC1, 0x2B, 0xCA, 0xA5, 0x9A, 0x2D, 0x98, 
-                       0x6C, 0x51, 0x00, 0x95, 0x1F, 0x4C, 0x04, 0x6A, 0x44, 0x59, 0x7C, 0x5F, 0xE4, 0xA8, 0xAF, 0x66, 0x32, 0x29, 0x1D, 0x07, 0xD4, 0xAE, 0xC1, 0x9E, 0x45, 0x35, 0x6D, 0xE9, 0x7A, 0x92, 0x22, 0x4B, 0x0D, 0x4A, 0xA6, 0x53, 0x17, 0x31, 0x76, 0x1F, 0x60, 0x32, 0x84, 0x18, 0x6B, 0x90, 0xD3, 0x77, 0x9B, 0xF1, 0xF0, 0x95, 0x4D, 0x23, 0x95, 0x90, 0xF5, 0xDD, 0xFA, 0xC1, 0x3F, 0xB3, 0xDD, 0x5E, 0x54, 0xFC, 0x03, 0xFD, 0xDA, 0xC8, 0xEF, 0x78, 0x2E, 0x5F, 0xFF, 0x1D, 0xDB, 0xB7, 0xF8, 0xBF, 0x1A, 0x2A, 0x98, 0xD0, 0x06, 0x04, 0x9B, 0xE0, 0xFD, 0xFB, 0xA2, 0x2E, 0x83, 0x67, 0x38, 0x77, 0x9E, 0x2D, 0x7C, 0xB4, 
-                       0x95, 0xF2, 0x5F, 0xF8, 0x3B, 0x62, 0x41, 0x9C, 0xAA, 0xAA, 0xAB, 0xEB, 0x46, 0x78, 0x5D, 0xF6, 0x88, 0x6C, 0xED, 0x0F, 0x76, 0x3B, 0xD6, 0xFD, 0x13, 0xCE, 0x68, 0xDE, 0x0A, 0x33, 0xA6, 0x68, 0xB5, 0xCA, 0x64, 0x90, 0x16, 0x00, 0xCE, 0x97, 0xC5, 0xED, 0x57, 0xE1, 0x1D, 0xF2, 0xD3, 0xDC, 0xA7, 0x1B, 0xC3, 0xEE, 0x07, 0xBE, 0xE8, 0xC3, 0xE5, 0x77, 0x10, 0x00, 0x48, 0x7D, 0x4F, 0xEC, 0x3B, 0xEC, 0xEF, 0x0F, 0x86, 0xD6, 0x5E, 0xF0, 0x32, 0xE4, 0x3D, 0x4E, 0xB5, 0x48, 0xA7, 0x0E, 0x2C, 0xCA, 0x1C, 0x9E, 0xDA, 0x6F, 0xDD, 0x53, 0x12, 0x0A, 0xBF, 0x65, 0x61, 0xDD, 0xB3, 0xAE, 0x3E, 0xAA, 0x59, 0x8F, 
-                       0xFC, 0xCD, 0x0E, 0xD0, 0x7D, 0xB0, 0x49, 0x5C, 0x85, 0xF4, 0xEF, 0x77, 0xDA, 0x39, 0x9E, 0x21, 0xCE, 0x9B, 0x26, 0x81, 0x6C, 0x13, 0x09, 0x54, 0xBF, 0x2D, 0x20, 0xF6, 0x57, 0x74, 0x94, 0xE0, 0x99, 0x81, 0x08, 0x9E, 0x72, 0xDB, 0x95, 0xAC, 0xB3, 0x4E, 0x08, 0x66, 0x7C, 0x30, 0x3B, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0x08, 0x95, 0xCA, 0x53, 0x3F, 0xBA, 0xFC, 0x96, 0xB1, 0x48, 0x21, 0x06, 0xA4, 0x9E, 0x5A, 0xD6, 0x23, 0x60, 0x4F, 0x3C, 0x04, 0x14, 0x24, 0x98, 0x3B, 0xFC, 0x6E, 0x4B, 0x07, 0xB7, 0xFA, 0xC1, 0xFE, 0xD3, 0x15, 0xBB, 0x7B, 0x70, 0xA7, 0x97, 
-                       0xBC, 0x0A, 0x02, 0x02, 0x07, 0xD0 };
-
-               static public byte[] farscape_strong_path_pfx = { 0x30, 0x82, 0x0B, 0x57, 0x02, 0x01, 0x03, 0x30, 0x82, 0x0B, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x0B, 0x04, 0x04, 0x82, 0x0B, 0x00, 0x30, 0x82, 0x0A, 0xFC, 0x30, 0x82, 0x03, 0x8D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x03, 0x7E, 0x04, 0x82, 0x03, 0x7A, 0x30, 0x82, 0x03, 0x76, 0x30, 0x82, 0x03, 0x72, 0x06, 0x0B, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x0A, 0x01, 0x02, 0xA0, 0x82, 0x02, 0xB6, 0x30, 0x82, 0x02, 0xB2, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 0x03, 0x30, 
-                       0x0E, 0x04, 0x08, 0x32, 0xC5, 0xBA, 0x13, 0xE8, 0x8D, 0xE0, 0x25, 0x02, 0x02, 0x07, 0xD0, 0x04, 0x82, 0x02, 0x90, 0x3C, 0xD2, 0x8F, 0x0F, 0x52, 0x6A, 0x97, 0xA2, 0x5D, 0xDC, 0xFC, 0x82, 0x3D, 0x95, 0xE1, 0x19, 0x02, 0x8E, 0x64, 0xC5, 0x7C, 0x64, 0xFF, 0xA3, 0x4E, 0x00, 0x5B, 0xC0, 0x3C, 0x7C, 0x53, 0xEA, 0xEA, 0xF9, 0xC8, 0xF6, 0xD5, 0xDF, 0x62, 0x94, 0x39, 0xA8, 0xF9, 0xAF, 0x46, 0xAE, 0x40, 0xF8, 0xBE, 0x5E, 0xF5, 0xAB, 0x7A, 0xB2, 0x5B, 0x9F, 0x2D, 0x6E, 0xBA, 0xF9, 0xBE, 0x99, 0x32, 0x4C, 0xBF, 0xC0, 0x2C, 0xFB, 0xC6, 0xBD, 0x24, 0x6E, 0x1B, 0x69, 0xF8, 0xB8, 0xA2, 0x3F, 0x0F, 0x7F, 0x03, 
-                       0x60, 0xC6, 0xA8, 0x10, 0x80, 0x7A, 0xEA, 0x16, 0xE2, 0x2E, 0xBA, 0x60, 0x0A, 0x76, 0x9A, 0x60, 0x5A, 0x50, 0x59, 0x06, 0xD6, 0x76, 0x2C, 0x73, 0x7B, 0x50, 0x6F, 0x55, 0x6E, 0x86, 0xED, 0xC5, 0x35, 0x2C, 0xEF, 0x9F, 0xC8, 0x81, 0xE5, 0xFF, 0xBE, 0xDD, 0x48, 0x20, 0x35, 0x1B, 0x9B, 0xCF, 0x77, 0x13, 0x21, 0x9D, 0xD6, 0x19, 0xFC, 0x08, 0x94, 0xB6, 0xB3, 0xF5, 0x03, 0xAE, 0x8F, 0x10, 0x14, 0x9C, 0x7E, 0x86, 0x43, 0x1D, 0x3D, 0x9D, 0xEA, 0x3A, 0xDD, 0x62, 0x53, 0xFE, 0x92, 0x1F, 0xD1, 0x9B, 0x0D, 0x18, 0x0E, 0xCD, 0x5F, 0xF7, 0xE9, 0x92, 0x5F, 0xFE, 0xF2, 0x14, 0x20, 0x46, 0x9C, 0xED, 0x93, 0x0B, 
-                       0x65, 0xE3, 0xDE, 0x41, 0x53, 0x55, 0x83, 0xEE, 0x83, 0x59, 0x61, 0x74, 0x96, 0x67, 0xDB, 0x26, 0x22, 0x0B, 0x19, 0x01, 0x53, 0xF6, 0xDC, 0x13, 0xD9, 0xF5, 0xCD, 0xB3, 0x98, 0xA0, 0x52, 0x65, 0x69, 0x7B, 0xED, 0x76, 0xED, 0xFA, 0xE0, 0xAD, 0x2F, 0xDC, 0xCA, 0x0D, 0xBA, 0x25, 0xBD, 0x13, 0x5D, 0xCA, 0xFC, 0x4A, 0x22, 0xD9, 0x1D, 0xAC, 0x7F, 0x25, 0x35, 0x0D, 0xF7, 0xB0, 0xD9, 0x36, 0x9F, 0x4F, 0x0D, 0x7C, 0x92, 0x93, 0xD0, 0xA5, 0x3F, 0x64, 0xC1, 0x26, 0x41, 0x73, 0xDC, 0x3E, 0x01, 0xCA, 0xB0, 0xD8, 0xF6, 0x6D, 0x83, 0x08, 0xA3, 0x3D, 0xCE, 0xEF, 0x29, 0x6B, 0x25, 0x3D, 0x65, 0xD9, 0xB0, 0xA3, 
-                       0xA4, 0xDC, 0xC8, 0x21, 0xDF, 0x5E, 0xE8, 0x5B, 0x5D, 0xCF, 0x41, 0x81, 0x28, 0xEE, 0x80, 0xDF, 0x87, 0x0B, 0x06, 0x09, 0x46, 0x61, 0xDC, 0x99, 0xF8, 0xC6, 0xD7, 0xA8, 0x4C, 0x59, 0x37, 0xB3, 0x54, 0x82, 0xE7, 0x4F, 0x36, 0x5D, 0x58, 0x8B, 0x26, 0xE8, 0xF7, 0x76, 0x87, 0x3A, 0x43, 0x61, 0x8B, 0x93, 0xAD, 0xDE, 0x35, 0xED, 0xC5, 0x5B, 0xEC, 0x49, 0x9B, 0xA3, 0x5A, 0xC7, 0x94, 0x50, 0x0E, 0x06, 0x2F, 0xC2, 0xF2, 0x28, 0x71, 0x52, 0xE1, 0x4B, 0x24, 0x97, 0x62, 0x2A, 0x28, 0x25, 0xC5, 0x43, 0x35, 0xF1, 0x9C, 0xDF, 0xFD, 0xAD, 0x7C, 0x7D, 0xED, 0x6F, 0xCC, 0x96, 0xBF, 0x93, 0x97, 0xBA, 0x2C, 0x44, 
-                       0xB7, 0xCD, 0x9C, 0x6E, 0x0D, 0x29, 0x7C, 0x19, 0xC9, 0xA0, 0x40, 0x94, 0x35, 0x66, 0xB6, 0x4C, 0xFB, 0xA8, 0x91, 0xC1, 0x89, 0x31, 0x6E, 0x76, 0x03, 0x94, 0x65, 0xF1, 0xA3, 0x2A, 0x1A, 0xD6, 0x99, 0xB9, 0xFF, 0x2E, 0xCF, 0xC3, 0xE7, 0x80, 0x28, 0x7B, 0xD5, 0x18, 0xA6, 0xD1, 0xEC, 0x1F, 0x28, 0x65, 0xB5, 0xB7, 0x32, 0xC9, 0x3A, 0x22, 0x56, 0x87, 0x61, 0x5C, 0xB0, 0xEC, 0x87, 0xA6, 0xA5, 0x23, 0x14, 0xBA, 0x0E, 0xD1, 0xE7, 0xA2, 0x74, 0x94, 0xC9, 0x74, 0x65, 0x9C, 0x5D, 0xAF, 0x5B, 0xDD, 0x3A, 0x8B, 0x2E, 0x44, 0xDF, 0x8C, 0x7F, 0x10, 0x83, 0x3C, 0xFC, 0x2C, 0x48, 0x4D, 0xF0, 0x20, 0xB8, 0xF8, 
-                       0x63, 0x37, 0x83, 0xB1, 0xDB, 0xA3, 0x51, 0x75, 0xF3, 0xA6, 0x77, 0xAD, 0x4A, 0xAF, 0xF6, 0x0F, 0x57, 0xAB, 0x18, 0x68, 0xD8, 0x42, 0xB1, 0xC3, 0x4D, 0xE9, 0xAA, 0x1A, 0xD5, 0xB9, 0xBD, 0xEB, 0xDB, 0x5B, 0x04, 0x95, 0xC2, 0x4E, 0xE2, 0x74, 0x99, 0x6E, 0x42, 0xF0, 0xCA, 0xC5, 0xA1, 0x71, 0x90, 0xFF, 0xF7, 0x08, 0x1E, 0xDA, 0xD7, 0x53, 0x33, 0x12, 0x0A, 0xC9, 0x10, 0x04, 0x60, 0xDA, 0xC2, 0xC8, 0x73, 0x9C, 0x10, 0x03, 0x20, 0x5A, 0xC2, 0xC5, 0x2E, 0x83, 0x88, 0x72, 0x25, 0xA3, 0x98, 0xC0, 0x35, 0x56, 0x16, 0x7B, 0x8F, 0x17, 0x92, 0x72, 0xF8, 0x8A, 0x4C, 0x65, 0x79, 0x7A, 0xA5, 0xAF, 0xCB, 0x03, 
-                       0x0A, 0xAA, 0xBC, 0xBB, 0xF8, 0x30, 0x16, 0xBA, 0x1D, 0x42, 0x6F, 0xF8, 0xAA, 0xC4, 0x3A, 0x89, 0x29, 0x22, 0x7F, 0x22, 0x1F, 0x87, 0xFE, 0x34, 0x06, 0x6C, 0x0E, 0x13, 0xD0, 0x43, 0x43, 0x59, 0x4F, 0x59, 0xAA, 0x2B, 0x1E, 0xDA, 0x96, 0x06, 0x38, 0x3E, 0x18, 0x97, 0xCF, 0x1D, 0xFE, 0x43, 0xA7, 0x8C, 0xB1, 0x0D, 0x40, 0x9B, 0xC6, 0xDD, 0x79, 0x97, 0xD0, 0x0B, 0x67, 0x0E, 0x2C, 0x2D, 0xBE, 0x4F, 0x9F, 0xBC, 0x6D, 0xD1, 0xAC, 0xA3, 0xB6, 0x38, 0x53, 0x31, 0x81, 0xA8, 0x30, 0x0D, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x02, 0x31, 0x00, 0x30, 0x13, 0x06, 0x09, 0x2A, 0x86, 0x48, 
-                       0x86, 0xF7, 0x0D, 0x01, 0x09, 0x15, 0x31, 0x06, 0x04, 0x04, 0x01, 0x00, 0x00, 0x00, 0x30, 0x17, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x14, 0x31, 0x0A, 0x1E, 0x08, 0x00, 0x4D, 0x00, 0x6F, 0x00, 0x6E, 0x00, 0x6F, 0x30, 0x69, 0x06, 0x09, 0x2B, 0x06, 0x01, 0x04, 0x01, 0x82, 0x37, 0x11, 0x01, 0x31, 0x5C, 0x1E, 0x5A, 0x00, 0x4D, 0x00, 0x69, 0x00, 0x63, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x73, 0x00, 0x6F, 0x00, 0x66, 0x00, 0x74, 0x00, 0x20, 0x00, 0x52, 0x00, 0x53, 0x00, 0x41, 0x00, 0x20, 0x00, 0x53, 0x00, 0x43, 0x00, 0x68, 0x00, 0x61, 0x00, 0x6E, 0x00, 0x6E, 0x00, 0x65, 0x00, 0x6C, 
-                       0x00, 0x20, 0x00, 0x43, 0x00, 0x72, 0x00, 0x79, 0x00, 0x70, 0x00, 0x74, 0x00, 0x6F, 0x00, 0x67, 0x00, 0x72, 0x00, 0x61, 0x00, 0x70, 0x00, 0x68, 0x00, 0x69, 0x00, 0x63, 0x00, 0x20, 0x00, 0x50, 0x00, 0x72, 0x00, 0x6F, 0x00, 0x76, 0x00, 0x69, 0x00, 0x64, 0x00, 0x65, 0x00, 0x72, 0x30, 0x82, 0x07, 0x67, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x06, 0xA0, 0x82, 0x07, 0x58, 0x30, 0x82, 0x07, 0x54, 0x02, 0x01, 0x00, 0x30, 0x82, 0x07, 0x4D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0x30, 0x1C, 0x06, 0x0A, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x0C, 0x01, 
-                       0x06, 0x30, 0x0E, 0x04, 0x08, 0x4E, 0xEC, 0x16, 0x2C, 0x55, 0x4B, 0x1B, 0x3E, 0x02, 0x02, 0x07, 0xD0, 0x80, 0x82, 0x07, 0x20, 0x8A, 0xE2, 0x16, 0x78, 0xEB, 0x9F, 0xF6, 0x25, 0x67, 0x15, 0x21, 0x01, 0x86, 0xC3, 0x2E, 0x27, 0x02, 0xF4, 0x0B, 0x98, 0xD8, 0xF2, 0x44, 0xBB, 0x1A, 0xD4, 0xF2, 0xA6, 0xB8, 0x6B, 0x7B, 0x05, 0xD4, 0x57, 0x3C, 0x77, 0xD5, 0x0C, 0xDC, 0x6B, 0x1A, 0xC4, 0xEA, 0x32, 0xFC, 0x28, 0x48, 0x67, 0xA2, 0xC2, 0x20, 0xCA, 0x58, 0x95, 0x45, 0xAA, 0xE1, 0x69, 0x4B, 0x7D, 0xFD, 0x33, 0x43, 0xF3, 0xD2, 0xDF, 0xEA, 0xF3, 0xAD, 0x7D, 0x8F, 0x05, 0x5A, 0xAB, 0x7B, 0x6E, 0x6C, 0x6F, 0xD7, 
-                       0x49, 0xFC, 0x16, 0x1F, 0x30, 0x5D, 0x68, 0xB9, 0x78, 0x65, 0x12, 0x7C, 0x16, 0x14, 0x95, 0x3C, 0xA3, 0xE9, 0xEF, 0x56, 0x72, 0x07, 0x9B, 0x39, 0xA7, 0xA9, 0x52, 0x68, 0x47, 0x18, 0xED, 0x83, 0xC5, 0xFC, 0x4F, 0xC8, 0xFF, 0x86, 0xA5, 0x85, 0xBF, 0xBF, 0x38, 0xBA, 0x88, 0xA5, 0x91, 0x85, 0xE8, 0x68, 0x04, 0x71, 0x89, 0x8A, 0x0E, 0x33, 0x5A, 0x57, 0x65, 0xCC, 0x3A, 0x1D, 0xE8, 0x29, 0x1F, 0xF3, 0x5E, 0xAE, 0xBE, 0x94, 0x60, 0x79, 0x54, 0x40, 0xF6, 0x15, 0x32, 0xD6, 0x6C, 0xEC, 0x8D, 0x1A, 0x63, 0x98, 0x69, 0x6F, 0x93, 0xB2, 0x6C, 0x3E, 0xF3, 0x35, 0x42, 0x08, 0x2E, 0x7E, 0x44, 0x73, 0xC6, 0xE8, 
-                       0x74, 0x07, 0xBF, 0xD3, 0x75, 0xDE, 0x87, 0x93, 0x8D, 0x4C, 0x3B, 0xB8, 0x23, 0x91, 0x2C, 0x62, 0x99, 0xA8, 0xD6, 0xA6, 0x05, 0xB9, 0xE9, 0x8F, 0x9F, 0x86, 0xD0, 0xE0, 0xF5, 0xE6, 0x1C, 0x92, 0x8D, 0xC9, 0x7A, 0xBA, 0xF8, 0x05, 0x7C, 0x6F, 0xFB, 0x7F, 0x62, 0x4B, 0x8C, 0x9B, 0xC5, 0xDB, 0x24, 0xD0, 0x7D, 0xC6, 0xDF, 0xBB, 0x43, 0xB8, 0x31, 0x3C, 0x52, 0x69, 0xC3, 0xA9, 0x4B, 0x6C, 0xA5, 0x5D, 0xF0, 0x25, 0x90, 0x9B, 0xD8, 0xE4, 0xC2, 0x4C, 0x71, 0x68, 0x17, 0x79, 0x21, 0xB7, 0x14, 0x56, 0xC2, 0x31, 0xB5, 0xEF, 0x4D, 0x86, 0x83, 0x24, 0x78, 0x01, 0x6D, 0x41, 0x19, 0x5B, 0xD3, 0x78, 0xC0, 0xE7, 
-                       0xF4, 0xEE, 0x86, 0xEC, 0x4D, 0x19, 0xB4, 0x2E, 0x65, 0x4C, 0x47, 0xFC, 0x7D, 0xDF, 0x56, 0xE1, 0xC3, 0x65, 0xF2, 0x30, 0xB5, 0x13, 0x93, 0xAD, 0x31, 0x56, 0xF3, 0x77, 0x4D, 0x9B, 0x6A, 0xA6, 0xCC, 0xF0, 0x20, 0x34, 0x11, 0xE7, 0xBD, 0xB1, 0xAD, 0xB9, 0xCB, 0xF3, 0x48, 0x6B, 0xB9, 0xF6, 0xB1, 0x7F, 0x9B, 0x61, 0x4C, 0x09, 0x05, 0xC1, 0x8D, 0xA7, 0x2B, 0xF0, 0xE5, 0x6C, 0x7D, 0xEB, 0xE3, 0x83, 0x6B, 0xA0, 0x77, 0x98, 0x6C, 0x5D, 0x59, 0x5B, 0xE2, 0x69, 0xC6, 0x97, 0x15, 0x60, 0x7A, 0x69, 0x7F, 0xC2, 0xF6, 0xF6, 0xAD, 0x33, 0xAE, 0x7D, 0x06, 0xA1, 0xF4, 0x5B, 0xA4, 0x17, 0xC3, 0xA5, 0xB5, 0xFA, 
-                       0x60, 0xD1, 0x58, 0x30, 0x1F, 0x81, 0x15, 0x49, 0x05, 0x6D, 0x54, 0xD8, 0xE8, 0x9E, 0xBF, 0x61, 0xD2, 0xD0, 0x8A, 0x95, 0xBD, 0x1C, 0x05, 0x6B, 0x15, 0xDC, 0x29, 0x80, 0xB1, 0x91, 0x66, 0xCE, 0x57, 0xCE, 0xFD, 0x5A, 0x3F, 0x18, 0xB9, 0x87, 0x32, 0x92, 0x6E, 0xA3, 0x42, 0x20, 0xC4, 0x36, 0xBD, 0x7E, 0xE2, 0x38, 0xF3, 0xDD, 0x50, 0x00, 0x28, 0x8C, 0x78, 0x2C, 0x94, 0xEC, 0x0F, 0xFE, 0xC2, 0x6F, 0x4D, 0x09, 0xC6, 0xE0, 0xCD, 0x50, 0xC6, 0x3B, 0x1D, 0x81, 0x2C, 0xE5, 0xEA, 0xF8, 0x31, 0x17, 0xCC, 0x37, 0x09, 0xBC, 0x7F, 0x19, 0x46, 0x4D, 0x83, 0x4A, 0xB6, 0x6E, 0x02, 0x10, 0x03, 0xAF, 0xEF, 0xE4, 
-                       0x02, 0x4A, 0x11, 0xC6, 0x11, 0xA6, 0xFC, 0xC3, 0x0E, 0x62, 0xAB, 0x98, 0x71, 0x32, 0x86, 0xA6, 0x22, 0x1B, 0x5F, 0x2C, 0x18, 0x78, 0x0E, 0x21, 0xA5, 0x5C, 0xC4, 0x3D, 0x06, 0x9A, 0x1E, 0x03, 0xAA, 0x7A, 0x49, 0x04, 0x0D, 0x82, 0xAF, 0xDD, 0x02, 0x70, 0x2E, 0x33, 0x10, 0x6F, 0x6A, 0xBF, 0xE4, 0x2F, 0xAA, 0x54, 0x8A, 0x0F, 0xCC, 0x85, 0xE9, 0xD9, 0x7E, 0x43, 0xCF, 0xDC, 0x32, 0x35, 0xA8, 0xEC, 0x87, 0x3D, 0x08, 0xB1, 0x63, 0xE3, 0x48, 0xDC, 0xB9, 0xDB, 0x2C, 0xA6, 0x9F, 0xB9, 0x7D, 0x90, 0xCA, 0xD1, 0x03, 0x76, 0xE6, 0x6D, 0xAD, 0x51, 0x10, 0xED, 0xA1, 0x7E, 0x06, 0x72, 0xC2, 0x12, 0x93, 0x7E, 
-                       0x7A, 0xF0, 0x84, 0xFE, 0x1C, 0x2A, 0xB0, 0xF1, 0x13, 0x2F, 0x68, 0x2B, 0x66, 0xB8, 0xAD, 0x14, 0x28, 0x65, 0x85, 0xC4, 0x92, 0x0F, 0x10, 0x3F, 0x1A, 0xCD, 0x6D, 0x74, 0x39, 0x5E, 0x9D, 0x6F, 0x11, 0xD3, 0xB4, 0xDA, 0xB6, 0x1A, 0x1D, 0x73, 0x29, 0xF3, 0x4A, 0x4F, 0x77, 0x19, 0x53, 0x59, 0x38, 0xF5, 0x58, 0x77, 0xE5, 0x45, 0xBA, 0x03, 0xD4, 0x9C, 0x1B, 0x11, 0x9C, 0xA2, 0x91, 0x80, 0xC7, 0x2C, 0xEB, 0x0C, 0x8D, 0x7E, 0xA1, 0x94, 0x1B, 0x7B, 0x74, 0x0F, 0x21, 0xB5, 0xE5, 0xBA, 0xEA, 0x14, 0x65, 0xAA, 0xFB, 0x5F, 0x91, 0x7A, 0x73, 0xBB, 0x04, 0x4E, 0x74, 0xFE, 0x24, 0xDF, 0x63, 0x18, 0xDF, 0xC2, 
-                       0x74, 0x5F, 0x4C, 0x9C, 0x9D, 0x0C, 0x94, 0x58, 0x89, 0x3F, 0x77, 0x63, 0x03, 0x77, 0x9C, 0x6E, 0xDE, 0x01, 0x13, 0x62, 0xEF, 0xCF, 0x57, 0xAB, 0x15, 0x22, 0xB6, 0x40, 0xFF, 0x0A, 0xFC, 0x91, 0xB8, 0x52, 0xFA, 0xCC, 0x7C, 0xEE, 0xB8, 0xA3, 0x7C, 0x8B, 0x3C, 0x04, 0x2E, 0xAB, 0x00, 0x78, 0x95, 0xD5, 0x0B, 0xC0, 0xF1, 0x5D, 0x52, 0x25, 0x92, 0x6B, 0x99, 0x71, 0x2E, 0x2B, 0x3A, 0x15, 0x2A, 0x15, 0xE8, 0xAC, 0x79, 0x71, 0xAE, 0xC7, 0xDA, 0x7C, 0x9D, 0x7E, 0xD5, 0x75, 0x34, 0xA6, 0x76, 0x46, 0xB1, 0x87, 0x94, 0xAD, 0x1F, 0x75, 0x74, 0x69, 0xE7, 0x26, 0xD6, 0xB1, 0x32, 0xFE, 0x0A, 0xCA, 0x3C, 0x54, 
-                       0x7D, 0x24, 0x95, 0xE1, 0xFD, 0x37, 0xE6, 0x34, 0xA5, 0x8B, 0x42, 0x88, 0x71, 0x22, 0xFE, 0x94, 0x42, 0xD5, 0xF8, 0xEE, 0x1E, 0x57, 0x2A, 0xD4, 0xB7, 0xC8, 0x90, 0xA2, 0x4A, 0xE0, 0xB7, 0xB5, 0x37, 0x72, 0x59, 0xF5, 0xA4, 0x8D, 0x3C, 0xFE, 0x3B, 0xD2, 0x8F, 0xEA, 0xBB, 0x83, 0x77, 0x78, 0xDA, 0x6E, 0xF3, 0x35, 0x03, 0x2E, 0xF1, 0x95, 0x6E, 0x91, 0x25, 0x9B, 0x11, 0x35, 0xBE, 0x08, 0xBB, 0xCB, 0x5C, 0x34, 0x1F, 0x22, 0x02, 0xE3, 0x0E, 0x5E, 0xC4, 0xF8, 0xD1, 0x6C, 0xF9, 0x87, 0x67, 0x0B, 0x33, 0xBD, 0xD3, 0xF0, 0x25, 0x5C, 0x68, 0xD5, 0xD0, 0xA7, 0x4E, 0x2E, 0x8B, 0xB6, 0x45, 0xD9, 0x8A, 0x33, 
-                       0x80, 0x08, 0xBD, 0x8D, 0x17, 0xFD, 0x4C, 0x4C, 0xFD, 0x06, 0x85, 0x5A, 0x4A, 0xDF, 0x4C, 0xD7, 0x16, 0x78, 0xB0, 0x0F, 0xA9, 0x35, 0x4A, 0x71, 0x9F, 0x10, 0xE1, 0x26, 0x09, 0x03, 0x29, 0xE3, 0x11, 0x2A, 0xF4, 0x4F, 0x02, 0xBD, 0x29, 0x54, 0xA8, 0x8F, 0xFE, 0xC4, 0x98, 0xD4, 0x28, 0x86, 0x00, 0x37, 0xC9, 0x2C, 0xCF, 0xB6, 0xA6, 0x0B, 0x98, 0x22, 0xE6, 0xAA, 0x8A, 0x51, 0x45, 0xAF, 0xBB, 0x63, 0x25, 0x42, 0x7F, 0x3E, 0x8C, 0x34, 0x30, 0x86, 0x39, 0x9D, 0x58, 0xC1, 0xC0, 0x1F, 0xA8, 0xEE, 0x2A, 0x42, 0x4C, 0x0C, 0xCA, 0x62, 0xCA, 0xD1, 0xA6, 0x26, 0xA1, 0xB9, 0x3D, 0x6C, 0xDE, 0x72, 0x71, 0xC5, 
-                       0xAB, 0xE2, 0xD6, 0x67, 0x36, 0xDD, 0xD9, 0xFE, 0x32, 0x43, 0x3A, 0x33, 0x0E, 0x4C, 0x25, 0x5A, 0x25, 0x77, 0xFD, 0x0C, 0x7E, 0xE3, 0x8F, 0x9A, 0x12, 0x7F, 0x09, 0x15, 0x92, 0x5D, 0x21, 0xB8, 0x6F, 0x6C, 0xBC, 0xCC, 0x37, 0xEF, 0x32, 0x7D, 0xAF, 0x90, 0x47, 0xAF, 0x54, 0xD9, 0xD6, 0x9E, 0x50, 0xB6, 0x7D, 0x1E, 0x1C, 0xD8, 0x8D, 0x72, 0x64, 0x86, 0x93, 0xDB, 0x2E, 0xCE, 0x1E, 0x95, 0xA8, 0xBF, 0x6B, 0x22, 0x9B, 0x16, 0x72, 0x2A, 0xA2, 0x53, 0x37, 0x8F, 0x81, 0xCE, 0x0B, 0x8E, 0x27, 0x23, 0x73, 0x7C, 0xE7, 0x15, 0x32, 0x20, 0xA1, 0xD4, 0xE9, 0xCD, 0x10, 0xC2, 0xC0, 0xB9, 0x92, 0x8E, 0x8E, 0x0B, 
-                       0x50, 0x79, 0x15, 0xFE, 0x64, 0x90, 0x85, 0xB7, 0x65, 0xAD, 0x6A, 0x80, 0xF3, 0x43, 0x3D, 0x1C, 0xCC, 0xFB, 0xC6, 0x8C, 0x83, 0x23, 0xE3, 0xA7, 0x4C, 0xCE, 0x88, 0x8C, 0x99, 0xED, 0xCE, 0xC8, 0x29, 0xA7, 0x45, 0xA7, 0x3A, 0xC2, 0x24, 0x6C, 0xD7, 0x47, 0x37, 0x06, 0xEE, 0xAE, 0xD7, 0xC7, 0xE6, 0x09, 0x2D, 0xAC, 0x13, 0x5A, 0xE1, 0x83, 0x72, 0x65, 0x60, 0x21, 0x97, 0x1A, 0x56, 0x6B, 0xFA, 0xE4, 0x4B, 0x71, 0x6E, 0x99, 0x1F, 0x09, 0xBF, 0x97, 0x23, 0xC2, 0x1A, 0xEE, 0xEA, 0x82, 0x07, 0x9C, 0x8F, 0x7C, 0x80, 0xBA, 0xC3, 0x68, 0xFC, 0x42, 0xE4, 0x50, 0x80, 0x71, 0x48, 0x74, 0x6A, 0x10, 0x23, 0x7E, 
-                       0x44, 0xD6, 0xA2, 0xB9, 0x3E, 0x95, 0xA0, 0x0E, 0x0B, 0xA6, 0xA8, 0x45, 0xD8, 0xE5, 0x18, 0x17, 0x63, 0xB9, 0xE2, 0x66, 0x88, 0xA4, 0xEC, 0x4A, 0x88, 0x3F, 0x54, 0x2B, 0x7D, 0x89, 0xC3, 0x73, 0x84, 0x83, 0x76, 0x62, 0x6B, 0xD6, 0xDA, 0x76, 0x43, 0xD7, 0xCA, 0xE3, 0x78, 0x45, 0x5A, 0x46, 0xA7, 0x6D, 0x0E, 0x42, 0x41, 0x80, 0xDB, 0x03, 0xDD, 0x11, 0x5F, 0xD1, 0x0F, 0x3F, 0x9C, 0xD3, 0xBB, 0xEF, 0xCC, 0x8C, 0x10, 0x96, 0x6B, 0xA0, 0x86, 0xB9, 0x32, 0xFD, 0xB4, 0xA8, 0x55, 0x90, 0x57, 0x80, 0x30, 0x9A, 0xB3, 0xC0, 0xE1, 0xDE, 0xEC, 0x56, 0x3A, 0x16, 0x2F, 0x9B, 0x04, 0x00, 0x4C, 0x84, 0xC1, 0x42, 
-                       0xBE, 0x3D, 0xC8, 0xD4, 0x8B, 0x86, 0x0B, 0x0A, 0x73, 0x32, 0x50, 0x18, 0x73, 0x3E, 0x96, 0x70, 0xB1, 0x58, 0x96, 0x67, 0x60, 0x36, 0xFA, 0x9F, 0xC5, 0x22, 0xBD, 0x29, 0xEB, 0xFB, 0xA9, 0xDA, 0x16, 0xF0, 0x1C, 0xDE, 0xEB, 0x6E, 0xB7, 0x7D, 0x2F, 0x13, 0xBE, 0x13, 0x34, 0xB3, 0x70, 0x49, 0xEF, 0x15, 0x96, 0xEF, 0x55, 0xF4, 0x39, 0x34, 0x2F, 0xB4, 0x3C, 0x26, 0x2B, 0xEC, 0x66, 0x20, 0x29, 0x14, 0xB6, 0x70, 0xCC, 0x40, 0x11, 0xC1, 0xC4, 0x55, 0xDF, 0x44, 0x62, 0xEA, 0x86, 0x26, 0x7F, 0x70, 0x91, 0x37, 0x1E, 0x35, 0x6A, 0x29, 0x29, 0x1D, 0x4A, 0x38, 0x74, 0x4D, 0x19, 0xF2, 0x8B, 0x02, 0x51, 0xF2, 
-                       0x89, 0xE7, 0xBE, 0xEA, 0xCC, 0x3C, 0x7F, 0x94, 0x14, 0xB1, 0x99, 0x99, 0xCB, 0x19, 0xA8, 0x20, 0x1B, 0x5C, 0xEE, 0xAD, 0x5E, 0x41, 0xA3, 0x13, 0x63, 0xD9, 0x3C, 0x6B, 0x7E, 0x60, 0xBB, 0x26, 0x59, 0x11, 0xD1, 0x85, 0x00, 0x08, 0x68, 0xDC, 0xF3, 0xCD, 0x55, 0xAC, 0x0E, 0xC3, 0x77, 0xDC, 0xED, 0x5A, 0x83, 0x51, 0x4C, 0xCC, 0xAE, 0xBA, 0xF7, 0x60, 0x47, 0x61, 0x01, 0xCC, 0x31, 0x46, 0xF5, 0x2A, 0x06, 0x39, 0x15, 0xCD, 0x1C, 0x2C, 0x32, 0x79, 0x2E, 0x1E, 0x73, 0x80, 0xA6, 0x91, 0x7B, 0xCD, 0xFE, 0x0F, 0x8B, 0x86, 0x91, 0xD3, 0xD2, 0x07, 0xB8, 0x48, 0x1A, 0x63, 0x41, 0xE7, 0x62, 0xDF, 0x1E, 0x59, 
-                       0x9B, 0xFA, 0xC8, 0x25, 0xC3, 0x70, 0x96, 0x8E, 0xEB, 0xA7, 0x5D, 0x0D, 0x6C, 0xBA, 0xB1, 0xDD, 0x8F, 0xB7, 0xA8, 0xBF, 0xBD, 0xBE, 0xFF, 0x86, 0x8A, 0x31, 0x11, 0xAF, 0x33, 0x6A, 0x1E, 0x11, 0xDF, 0x06, 0x0C, 0x16, 0x98, 0x9E, 0x5B, 0xE3, 0x4C, 0x31, 0xF4, 0x5F, 0x61, 0xC0, 0x22, 0xAC, 0x80, 0xA7, 0x05, 0xAA, 0x48, 0x77, 0xCE, 0x2F, 0x2F, 0x93, 0xA6, 0x19, 0x12, 0x6C, 0x40, 0x24, 0xC0, 0xF1, 0xF9, 0xC1, 0x13, 0x99, 0x2A, 0xE7, 0x12, 0xB2, 0xA4, 0x67, 0xCD, 0xC6, 0xA7, 0xE2, 0x59, 0x20, 0x71, 0xB8, 0x5D, 0x3C, 0xAC, 0x8A, 0x30, 0x00, 0xDE, 0xAB, 0x97, 0x94, 0x7E, 0x72, 0xF0, 0xDA, 0x6D, 0x9D, 
-                       0xDF, 0x89, 0x53, 0x06, 0x93, 0x6F, 0xA4, 0x90, 0x30, 0xFA, 0xD3, 0x26, 0xE6, 0x24, 0xBF, 0x3E, 0x22, 0xA2, 0x46, 0x55, 0xF6, 0x6A, 0x16, 0x5D, 0x3E, 0x17, 0x7E, 0x13, 0x02, 0x9C, 0x2D, 0x07, 0x79, 0x58, 0x00, 0x32, 0xD2, 0x10, 0x93, 0x85, 0x98, 0x2D, 0xF8, 0x5D, 0x5B, 0x74, 0xB0, 0x7E, 0x4B, 0x57, 0x64, 0xEA, 0x66, 0xDF, 0xE1, 0x04, 0xCC, 0x35, 0x9F, 0x0E, 0x46, 0x8A, 0xFB, 0x1C, 0x0D, 0x37, 0x8D, 0xC0, 0x13, 0x67, 0xAE, 0xC0, 0xD2, 0x2E, 0x9B, 0xB4, 0x16, 0x1B, 0xA4, 0x9A, 0x23, 0x18, 0xD2, 0x58, 0x9E, 0x3F, 0x4B, 0x83, 0x0D, 0x4A, 0xE4, 0xF3, 0xB3, 0xFC, 0x0A, 0xF9, 0xA5, 0x01, 0x9C, 0x44, 
-                       0x89, 0x53, 0xBD, 0x10, 0xAA, 0x1E, 0xC6, 0x41, 0x7C, 0x71, 0xCA, 0x47, 0x79, 0x60, 0x95, 0x2E, 0xAB, 0xF6, 0x17, 0xBE, 0x1D, 0xF1, 0x05, 0xAD, 0x76, 0xD8, 0xBB, 0xF2, 0xBB, 0x36, 0xEE, 0xCD, 0xAA, 0xBC, 0xBA, 0xBE, 0x94, 0x42, 0x9A, 0xA8, 0xEE, 0xE5, 0x93, 0x5C, 0x3C, 0x23, 0xE2, 0x75, 0xD3, 0x59, 0xB4, 0xB3, 0xC4, 0x01, 0xBB, 0xC9, 0x05, 0xFE, 0xFA, 0x1B, 0x31, 0x7A, 0x15, 0x29, 0x91, 0xE6, 0xB9, 0xB2, 0x1E, 0xF9, 0x36, 0xC5, 0x17, 0xB9, 0x9D, 0x32, 0x0D, 0x0D, 0x80, 0x4A, 0x0D, 0x14, 0xB4, 0xDF, 0x89, 0x3A, 0x4B, 0xCA, 0x4B, 0xDE, 0xF8, 0xC0, 0x1B, 0xA6, 0x6D, 0xD9, 0x19, 0xFB, 0x0E, 0x02, 
-                       0x22, 0x82, 0x8E, 0x25, 0x8E, 0x9F, 0xD5, 0x7B, 0xB6, 0x14, 0x15, 0x08, 0x61, 0xCD, 0xA6, 0xB3, 0x0F, 0xC8, 0xE8, 0xF9, 0xEE, 0xDB, 0xAF, 0x25, 0x40, 0x01, 0x85, 0x0E, 0x89, 0x0D, 0x0D, 0x85, 0xA6, 0xA3, 0xC9, 0x65, 0x64, 0x8A, 0xD1, 0xF7, 0x55, 0xF9, 0x31, 0x24, 0x41, 0x30, 0x3B, 0x30, 0x1F, 0x30, 0x07, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1A, 0x04, 0x14, 0xD4, 0x77, 0x3F, 0x92, 0xB6, 0xA6, 0x1B, 0xD5, 0x7F, 0xC1, 0x1B, 0x93, 0xB3, 0x6E, 0x87, 0x67, 0x80, 0xE7, 0x4C, 0x7C, 0x04, 0x14, 0x58, 0x4C, 0x92, 0xDD, 0x0B, 0xEF, 0x09, 0x35, 0xE0, 0x06, 0x33, 0x54, 0xB2, 0xA8, 0x8E, 0x0C, 0x60, 0x67, 
-                       0xB5, 0x0F, 0x02, 0x02, 0x07, 0xD0 };
-
-               public const string base64_cert = @"-----BEGIN CERTIFICATE-----
-MIIBxTCCATKgAwIBAgIQx3WuSFObHp5EgBXKeBVHaTAJBgUrDgMCHQUAMCUxIzAh
-BgNVBAMeGgBDAEEAUwBUAE8AUgBcAHAAbwB1AHAAbwB1MB4XDTA1MDYwODEzMzg0
-N1oXDTA2MDYwODE5Mzg0N1owJTEjMCEGA1UEAx4aAEMAQQBTAFQATwBSAFwAcABv
-AHUAcABvAHUwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBANrqOTj2OvSL+eLH
-1Sz5GtV1zxess0a9fz+XOC4QQbLE2RQV2Ob5ETiAdePXH8CGpz4CEQTpV7XYV2Un
-e4+6ue+gjxWc7C+FY05Sa6bjM8qGIrr5Bujsy6elqOI+xyF0TsnpBV+ueBJRL/pq
-j3ywZCr7t7JAkSDnMlM/WMqAokHFAgMBAAEwCQYFKw4DAh0FAAOBgQCdV7All4Ei
-PMRhncnb2MfB7fsc3TWY10BYpEOGVPloloW1kby3grJ+e1i9gM40fiKHYjG1Axag
-IBed512qEvWS35Tmac32/IKb3NMwQLFxT0pky9wUyMF/byPO3RkiTyQeJxhmiHqa
-mgk3bWUV6ChegutbguiKrI/DbO7wPiDLxw==
------END CERTIFICATE-----";
-
-               static public byte[] farscape_pkcs7 = { 0x30, 0x82, 0x02, 0x59, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x02, 0xA0, 0x82, 0x02, 0x4A, 0x30, 0x82, 0x02, 0x46, 0x02, 0x01, 0x01, 0x31, 0x00, 0x30, 0x0B, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x07, 0x01, 0xA0, 0x82, 0x02, 0x2E, 0x30, 0x82, 0x02, 0x2A, 0x30, 0x82, 0x01, 0x97, 0xA0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x10, 0x91, 0xC4, 0x4B, 0x0D, 0xB7, 0xD8, 0x10, 0x84, 0x42, 0x26, 0x71, 0xB3, 0x97, 0xB5, 0x00, 0x97, 0x30, 0x09, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x30, 0x28, 0x31, 0x26, 0x30, 0x24, 0x06, 0x03, 
-                       0x55, 0x04, 0x03, 0x13, 0x1D, 0x4D, 0x6F, 0x74, 0x75, 0x73, 0x20, 0x54, 0x65, 0x63, 0x68, 0x6E, 0x6F, 0x6C, 0x6F, 0x67, 0x69, 0x65, 0x73, 0x20, 0x69, 0x6E, 0x63, 0x2E, 0x28, 0x74, 0x65, 0x73, 0x74, 0x29, 0x30, 0x1E, 0x17, 0x0D, 0x30, 0x33, 0x30, 0x38, 0x31, 0x33, 0x30, 0x30, 0x34, 0x33, 0x34, 0x37, 0x5A, 0x17, 0x0D, 0x33, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x35, 0x39, 0x35, 0x39, 0x5A, 0x30, 0x13, 0x31, 0x11, 0x30, 0x0F, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x08, 0x46, 0x41, 0x52, 0x53, 0x43, 0x41, 0x50, 0x45, 0x30, 0x81, 0x9F, 0x30, 0x0D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 
-                       0x01, 0x01, 0x01, 0x05, 0x00, 0x03, 0x81, 0x8D, 0x00, 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xD2, 0xCB, 0x47, 0x21, 0xF5, 0x62, 0xDD, 0x35, 0xBF, 0x1D, 0xEC, 0x9A, 0x4C, 0x07, 0x2C, 0x01, 0xF0, 0x28, 0xC2, 0x82, 0x17, 0x8E, 0x58, 0x32, 0xD5, 0x4C, 0xAC, 0x86, 0xB4, 0xC9, 0xEB, 0x21, 0x26, 0xF3, 0x22, 0x30, 0xC5, 0x7A, 0xA3, 0x5A, 0xDD, 0x53, 0xAB, 0x1C, 0x06, 0x3E, 0xB2, 0x13, 0xC4, 0x05, 0x1D, 0x95, 0x8B, 0x0A, 0x71, 0x71, 0x11, 0xA7, 0x47, 0x26, 0x61, 0xF1, 0x76, 0xBE, 0x35, 0x72, 0x32, 0xC5, 0xCB, 0x47, 0xA4, 0x22, 0x41, 0x1E, 0xAD, 0x29, 0x11, 0x0D, 0x39, 0x22, 0x0C, 0x79, 0x90, 0xC6, 
-                       0x52, 0xA1, 0x10, 0xF6, 0x55, 0x09, 0x4E, 0x51, 0x26, 0x47, 0x0E, 0x94, 0xE6, 0x81, 0xF5, 0x18, 0x6B, 0x99, 0xF0, 0x76, 0xF3, 0xB2, 0x4C, 0x91, 0xE9, 0xBA, 0x3B, 0x3F, 0x6E, 0x63, 0xDA, 0x12, 0xD1, 0x0B, 0x73, 0x0E, 0x12, 0xC7, 0x70, 0x77, 0x22, 0x03, 0x9D, 0x5D, 0x02, 0x03, 0x01, 0x00, 0x01, 0xA3, 0x72, 0x30, 0x70, 0x30, 0x13, 0x06, 0x03, 0x55, 0x1D, 0x25, 0x04, 0x0C, 0x30, 0x0A, 0x06, 0x08, 0x2B, 0x06, 0x01, 0x05, 0x05, 0x07, 0x03, 0x01, 0x30, 0x59, 0x06, 0x03, 0x55, 0x1D, 0x01, 0x04, 0x52, 0x30, 0x50, 0x80, 0x10, 0xAE, 0xD7, 0x80, 0x88, 0xA6, 0x3D, 0xBA, 0x50, 0xA1, 0x7E, 0x57, 0xE5, 0x40, 
-                       0xC9, 0x6F, 0xC5, 0xA1, 0x2A, 0x30, 0x28, 0x31, 0x26, 0x30, 0x24, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x1D, 0x4D, 0x6F, 0x74, 0x75, 0x73, 0x20, 0x54, 0x65, 0x63, 0x68, 0x6E, 0x6F, 0x6C, 0x6F, 0x67, 0x69, 0x65, 0x73, 0x20, 0x69, 0x6E, 0x63, 0x2E, 0x28, 0x74, 0x65, 0x73, 0x74, 0x29, 0x82, 0x10, 0x9D, 0xAE, 0xA3, 0x39, 0x47, 0x0E, 0xD4, 0xA2, 0x49, 0x78, 0xEA, 0x6C, 0xBA, 0x0D, 0xDE, 0x9C, 0x30, 0x09, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x03, 0x81, 0x81, 0x00, 0x32, 0x8A, 0x7E, 0xAD, 0xE7, 0x67, 0x9E, 0x5C, 0x4C, 0xD8, 0x33, 0x59, 0x68, 0xCF, 0x94, 0xC0, 0x36, 0x47, 0x7A, 0xA7, 
-                       0x85, 0xC2, 0xDD, 0xD8, 0xDA, 0x11, 0x3C, 0x66, 0xC1, 0x83, 0xE3, 0xAB, 0x33, 0x06, 0x7C, 0xE3, 0x6A, 0x15, 0x72, 0xB8, 0x83, 0x3D, 0x0B, 0xAB, 0x3C, 0xEE, 0x75, 0x13, 0xBD, 0x5C, 0x96, 0x25, 0x56, 0x36, 0x05, 0xFA, 0xAE, 0xD4, 0xF4, 0xCF, 0x52, 0xEC, 0x11, 0xB5, 0xEA, 0x9F, 0x20, 0xA3, 0xC8, 0x34, 0x72, 0x59, 0x09, 0x51, 0xE7, 0x36, 0x87, 0x86, 0x86, 0x98, 0xB5, 0x30, 0x7B, 0xFB, 0x3D, 0xCC, 0x5E, 0xE8, 0xC9, 0x49, 0xE0, 0xC6, 0xEA, 0x02, 0x76, 0x01, 0xE0, 0xBB, 0x8A, 0x70, 0xEB, 0x07, 0x86, 0xE8, 0x04, 0xE7, 0x48, 0xE4, 0x6C, 0x90, 0xE6, 0x16, 0x42, 0xB4, 0xBB, 0xC0, 0xC4, 0x82, 0x5F, 0xF8, 
-                       0xFB, 0x7E, 0xB2, 0x9E, 0xC2, 0x78, 0x26, 0x86, 0x31, 0x00 };
-
-               [Test]
-               public void Equals ()
-               {
-                       X509Certificate x1 = new X509Certificate (cert1);
-                       Assert.IsTrue (x1.Equals (x1), "Equals-Self-X");
-                       Assert.IsTrue (x1.Equals ((object)x1), "Equals-Self-O");
-                       X509Certificate x2 = new X509Certificate (cert1);
-                       Assert.IsTrue (x1.Equals (x2), "Equals-12-X");
-                       Assert.IsTrue (x1.Equals ((object)x2), "Equals-12-O");
-                       Assert.IsTrue (x2.Equals (x1), "Equals-12-X");
-                       Assert.IsTrue (x2.Equals ((object)x1), "Equals-12-O");
-               }
-
-               [Test]
-               public void Equals_Empty_Source ()
-               {
-                       X509Certificate empty = new X509Certificate ();
-                       Assert.IsFalse (empty.Equals (null), "null");
-                       X509Certificate x = new X509Certificate (cert1);
-                       Assert.IsFalse (empty.Equals (x), "X509Certificate");
-                       Assert.IsFalse (empty.Equals ((object) x), "object");
-                       Assert.IsTrue (empty.Equals (empty), "empty");
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Equals_Empty_Destination ()
-               {
-                       new X509Certificate (cert1).Equals (new X509Certificate ());
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Export_Authenticode ()
-               {
-                       new X509Certificate (cert1).Export (X509ContentType.Authenticode);
-               }
-
-               [Test]
-               public void Export_Cert ()
-               {
-                       X509Certificate cert = new X509Certificate (cert1);
-                       byte[] data = cert.Export (X509ContentType.Cert);
-                       Assert.AreEqual (data, cert1, "original");
-
-                       data = cert.Export (X509ContentType.Cert, (string)null);
-                       Assert.AreEqual (data, cert1, "original/string/null");
-
-                       data = cert.Export (X509ContentType.Cert, (SecureString) null);
-                       Assert.AreEqual (data, cert1, "original/SecureString/null");
-               }
-
-               [Test]
-               [Category ("NotWorking")]
-               public void Export_Pfx ()
-               {
-                       X509Certificate cert = new X509Certificate (cert1);
-                       byte[] data = cert.Export (X509ContentType.Pfx);
-                       // usable
-                       X509Certificate2 c = new X509Certificate2 (data);
-                       Assert.AreEqual (cert1, c.GetRawCertData (), "Equals");
-               }
-
-               [Test]
-               [Category ("NotWorking")]
-               public void Export_Pkcs12 ()
-               {
-                       X509Certificate cert = new X509Certificate (cert1);
-                       byte[] data = cert.Export (X509ContentType.Pkcs12);
-                       // usable
-                       X509Certificate2 c = new X509Certificate2 (data);
-                       Assert.AreEqual (cert1, c.GetRawCertData (), "Equals");
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Export_Pkcs7 ()
-               {
-                       new X509Certificate (cert1).Export (X509ContentType.Pkcs7);
-               }
-
-               [Test]
-               [Category ("NotWorking")]
-               public void Export_SerializedCert ()
-               {
-                       X509Certificate cert = new X509Certificate (cert1);
-                       byte[] data = cert.Export (X509ContentType.SerializedCert);
-                       // usable
-                       X509Certificate2 c = new X509Certificate2 (data);
-                       Assert.AreEqual (cert1, c.GetRawCertData (), "Equals");
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Export_SerializedStore ()
-               {
-                       new X509Certificate (cert1).Export (X509ContentType.SerializedStore);
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Export_Unknown ()
-               {
-                       new X509Certificate (cert1).Export (X509ContentType.Unknown);
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Export_Bad ()
-               {
-                       new X509Certificate (cert1).Export ((X509ContentType) Int32.MinValue);
-               }
-
-               [Test]
-               public void UnrequiredPassword ()
-               {
-                       // MS permits to supply an unrequired password for an (unencrypted) DER certificate
-                       X509Certificate x1 = new X509Certificate (cert1, "mono");
-               }
-
-               [Test]
-               public void Empty ()
-               {
-                       X509Certificate x = new X509Certificate ();
-                       Assert.AreEqual ("X509", x.GetFormat (), "GetFormat");
-                       Assert.AreEqual (0, x.GetHashCode (), "GetHashCode");
-                       Assert.AreEqual (IntPtr.Zero, x.Handle, "Handle");
-                       Assert.AreEqual ("System.Security.Cryptography.X509Certificates.X509Certificate", x.ToString (true), "ToString(true)");
-                       Assert.AreEqual ("System.Security.Cryptography.X509Certificates.X509Certificate", x.ToString (false), "ToString(false)");
-                       Assert.IsTrue (x.Equals (x), "Equals(X509Certificate)");
-                       Assert.IsTrue (x.Equals ((object) x), "Equals(object)");
-                       x.Reset ();
-                       x.Import (cert1);
-                       Assert.AreEqual ("02720006E8", x.GetSerialNumberString (), "GetSerialNumberString");
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_Issuer ()
-               {
-                       X509Certificate x = new X509Certificate ();
-                       Assert.IsNotNull (x.Issuer, "Issuer");
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_Subject ()
-               {
-                       X509Certificate x = new X509Certificate ();
-                       Assert.IsNotNull (x.Subject, "Subject");
-               }
-
-               [Test]
-               [Category ("NotDotNet")] // FatalExecutionEngineError / Crash NUnit
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_Export ()
-               {
-                       new X509Certificate ().Export (X509ContentType.Cert);
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetCertHash ()
-               {
-                       new X509Certificate ().GetCertHash ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetCertHashString ()
-               {
-                       new X509Certificate ().GetCertHashString ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetEffectiveDateString ()
-               {
-                       new X509Certificate ().GetEffectiveDateString ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetExpirationDateString ()
-               {
-                       new X509Certificate ().GetExpirationDateString ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetIssuerName ()
-               {
-                       new X509Certificate ().GetIssuerName ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetKeyAlgorithm ()
-               {
-                       new X509Certificate ().GetKeyAlgorithm ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetKeyAlgorithmParameters ()
-               {
-                       new X509Certificate ().GetKeyAlgorithmParameters ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetKeyAlgorithmParametersString ()
-               {
-                       new X509Certificate ().GetKeyAlgorithmParametersString ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetName ()
-               {
-                       new X509Certificate ().GetName ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetPublicKey ()
-               {
-                       new X509Certificate ().GetPublicKey ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetPublicKeyString ()
-               {
-                       new X509Certificate ().GetPublicKeyString ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetRawCertData ()
-               {
-                       new X509Certificate ().GetRawCertData ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetRawCertDataString ()
-               {
-                       new X509Certificate ().GetRawCertDataString ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetSerialNumber ()
-               {
-                       new X509Certificate ().GetSerialNumber ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Empty_GetSerialNumberString ()
-               {
-                       new X509Certificate ().GetSerialNumberString ();
-               }
-
-               [Test]
-               [ExpectedException (typeof (NullReferenceException))]
-               public void GetObjectData_Null ()
-               {
-                       X509Certificate x = new X509Certificate ();
-                       ISerializable s = (x as ISerializable);
-                       s.GetObjectData (null, new StreamingContext (StreamingContextStates.All));
-               }
-
-               [Test]
-               public void GetObjectData ()
-               {
-                       X509Certificate x = new X509Certificate (cert1);
-                       ISerializable s = (x as ISerializable);
-                       Assert.IsNotNull (s, "ISerializable");
-                       SerializationInfo info = new SerializationInfo (typeof (X509Certificate), new FormatterConverter ());
-                       s.GetObjectData (info, new StreamingContext (StreamingContextStates.All));
-                       Assert.AreEqual (1, info.MemberCount, "MemberCount");
-                       byte[] raw = (byte[]) info.GetValue ("RawData", typeof (byte[]));
-               }
-
-               [Test]
-               [ExpectedException (typeof (NullReferenceException))]
-               public void Ctor_Serialization_Null ()
-               {
-                       new X509Certificate (null, new StreamingContext (StreamingContextStates.All));
-               }
-
-               [Test]
-               public void Ctor_Serialization ()
-               {
-                       SerializationInfo info = new SerializationInfo (typeof (X509Certificate), new FormatterConverter ());
-                       info.AddValue ("RawData", cert1);
-                       X509Certificate x = new X509Certificate (info, new StreamingContext (StreamingContextStates.All));
-                       Assert.AreEqual (cert1, x.GetRawCertData (), "GetRawCertData");
-                       // decoding is done too
-                       Assert.AreEqual ("02720006E8", x.GetSerialNumberString (), "SerialNumber");
-               }
-
-
-               [Test]
-               public void Properties ()
-               {
-                       X509Certificate x = new X509Certificate (cert1);
-                       Assert.AreEqual ("OU=Secure Server Certification Authority, O=\"RSA Data Security, Inc.\", C=US", x.Issuer, "Issuer");
-                       Assert.AreEqual ("OU=Server Certification Authority, O=CommerceNet, S=California, C=US", x.Subject, "Subject");
-               }
-
-               [Test]
-               public void Reset ()
-               {
-                       X509Certificate x = new X509Certificate (cert1);
-                       Assert.AreEqual ("02720006E8", x.GetSerialNumberString (), "GetSerialNumberString");
-                       x.Reset ();
-                       Assert.AreEqual ("X509", x.GetFormat (), "GetFormat");
-                       Assert.AreEqual (0, x.GetHashCode (), "GetHashCode");
-                       Assert.AreEqual (IntPtr.Zero, x.Handle, "Handle");
-                       Assert.AreEqual ("System.Security.Cryptography.X509Certificates.X509Certificate", x.ToString (true), "ToString(true)");
-                       Assert.AreEqual ("System.Security.Cryptography.X509Certificates.X509Certificate", x.ToString (false), "ToString(false)");
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Reset_Issuer ()
-               {
-                       X509Certificate x = new X509Certificate (cert1);
-                       x.Reset ();
-                       Assert.IsNotNull (x.Issuer, "Issuer");
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Reset_Subject ()
-               {
-                       X509Certificate x = new X509Certificate (cert1);
-                       x.Reset ();
-                       Assert.IsNotNull (x.Subject, "Subject");
-               }
-
-               private void CheckPkcs12 (X509Certificate x)
-               {
-                       byte[] cert = { 0x30, 0x82, 0x02, 0x1E, 0x30, 0x82, 0x01, 0x8B, 0xA0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x10, 0x74, 0x8B, 0xCD, 0xD9, 0x86, 0x99, 0x9A, 0x91, 0x4A, 0x0C, 0xC3, 0xF4, 0xE1, 0x2F, 0xF5, 0x95, 0x30, 0x09, 
-                               0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x30, 0x23, 0x31, 0x21, 0x30, 0x1F, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x18, 0x4D, 0x6F, 0x6E, 0x6F, 0x20, 0x53, 0x53, 0x4C, 0x20, 0x49, 0x6E, 0x74, 
-                               0x65, 0x72, 0x6D, 0x65, 0x64, 0x69, 0x61, 0x74, 0x65, 0x20, 0x43, 0x41, 0x30, 0x1E, 0x17, 0x0D, 0x30, 0x33, 0x31, 0x31, 0x32, 0x37, 0x30, 0x32, 0x35, 0x37, 0x34, 0x32, 0x5A, 0x17, 0x0D, 0x33, 0x39, 0x31, 
-                               0x32, 0x33, 0x31, 0x32, 0x33, 0x35, 0x39, 0x35, 0x39, 0x5A, 0x30, 0x13, 0x31, 0x11, 0x30, 0x0F, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x08, 0x46, 0x41, 0x52, 0x53, 0x43, 0x41, 0x50, 0x45, 0x30, 0x81, 0x9F, 
-                               0x30, 0x0D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x01, 0x05, 0x00, 0x03, 0x81, 0x8D, 0x00, 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xC4, 0x26, 0x3B, 0xE9, 0x49, 0x07, 0x39, 0x8C, 
-                               0x51, 0x34, 0x3B, 0x84, 0x4C, 0x27, 0x98, 0x70, 0x15, 0x79, 0xF1, 0xF4, 0x2A, 0x32, 0x82, 0xC3, 0xFA, 0xCF, 0x6E, 0x72, 0x37, 0xCE, 0x37, 0x55, 0x1F, 0xFA, 0x8F, 0x78, 0x4A, 0xA0, 0x0C, 0x9D, 0x44, 0x29, 
-                               0xF2, 0x81, 0xD9, 0x87, 0xD5, 0x94, 0x1A, 0xFC, 0x8D, 0xF8, 0x9D, 0xE0, 0xC5, 0xD2, 0x4A, 0x4F, 0x68, 0xD3, 0xAD, 0x65, 0x23, 0xB2, 0x4F, 0x48, 0x35, 0xB9, 0xFE, 0xE1, 0xDB, 0x6B, 0xE7, 0x41, 0x76, 0xEC, 
-                               0x0C, 0x5B, 0x3A, 0xE3, 0x07, 0xC9, 0x3D, 0x94, 0x48, 0xF2, 0xCF, 0x71, 0xAC, 0x2F, 0x71, 0x60, 0x15, 0x0E, 0xD5, 0x9A, 0xF8, 0x6C, 0x7F, 0xE9, 0xC0, 0x19, 0x18, 0x72, 0x09, 0xA1, 0xD6, 0xB8, 0xA9, 0x60, 
-                               0xD1, 0xC3, 0x18, 0x91, 0x98, 0xCE, 0x9A, 0x44, 0x3D, 0xCF, 0x63, 0x79, 0x41, 0x27, 0x18, 0xB3, 0x8E, 0x05, 0x02, 0x03, 0x01, 0x00, 0x01, 0xA3, 0x6B, 0x30, 0x69, 0x30, 0x13, 0x06, 0x03, 0x55, 0x1D, 0x25, 
-                               0x04, 0x0C, 0x30, 0x0A, 0x06, 0x08, 0x2B, 0x06, 0x01, 0x05, 0x05, 0x07, 0x03, 0x01, 0x30, 0x52, 0x06, 0x03, 0x55, 0x1D, 0x01, 0x04, 0x4B, 0x30, 0x49, 0x80, 0x10, 0x7C, 0x13, 0x05, 0xC9, 0xB9, 0x5A, 0xA3, 
-                               0x19, 0x3E, 0x7C, 0x0D, 0x7C, 0xE3, 0xF2, 0xD3, 0x36, 0xA1, 0x23, 0x30, 0x21, 0x31, 0x1F, 0x30, 0x1D, 0x06, 0x03, 0x55, 0x04, 0x03, 0x13, 0x16, 0x4D, 0x6F, 0x6E, 0x6F, 0x20, 0x55, 0x6E, 0x69, 0x74, 0x20, 
-                               0x54, 0x65, 0x73, 0x74, 0x20, 0x52, 0x6F, 0x6F, 0x74, 0x20, 0x43, 0x41, 0x82, 0x10, 0x1B, 0xFC, 0x61, 0x41, 0xD0, 0xCF, 0x41, 0xB9, 0x47, 0xEF, 0x21, 0x7D, 0x6A, 0x53, 0x32, 0x76, 0x30, 0x09, 0x06, 0x05, 
-                               0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x03, 0x81, 0x81, 0x00, 0x94, 0xF8, 0xDA, 0xEF, 0x93, 0x6A, 0x23, 0x04, 0x6B, 0x2D, 0xC3, 0x1E, 0x57, 0xC9, 0x7E, 0xE1, 0xF6, 0x6C, 0x55, 0xB6, 0xAC, 0xAB, 0xA8, 
-                               0x67, 0x19, 0xCD, 0x1D, 0x32, 0x1C, 0xD7, 0x63, 0x13, 0x4F, 0x41, 0x85, 0xB0, 0x62, 0xB8, 0x04, 0x38, 0xD0, 0xD8, 0x18, 0x36, 0x80, 0xE2, 0x70, 0xE7, 0x11, 0x05, 0x7A, 0x2D, 0x5D, 0xC8, 0xAD, 0x29, 0x2E, 
-                               0x05, 0x54, 0x66, 0xE2, 0x8E, 0xCC, 0xDA, 0xEE, 0x19, 0x10, 0xB9, 0x37, 0x30, 0x83, 0x62, 0x9A, 0x10, 0xDB, 0x19, 0x41, 0x57, 0x37, 0x1A, 0x39, 0x54, 0x59, 0xE6, 0x6D, 0xDF, 0x1B, 0xCE, 0x6E, 0x78, 0x6A, 
-                               0x5F, 0x06, 0x26, 0x8D, 0xE0, 0x94, 0x52, 0xF4, 0x86, 0x9C, 0x42, 0x58, 0xF0, 0xEB, 0x71, 0xEB, 0xB8, 0x8E, 0xC9, 0x20, 0x84, 0xD5, 0x11, 0x58, 0x40, 0x4A, 0xE9, 0xD1, 0x8E, 0x2F, 0x9D, 0xD9, 0x8B, 0xD0, 
-                               0x55, 0xB8, 0x96 };
-                       Assert.AreEqual ("CN=Mono SSL Intermediate CA", x.Issuer, "Issuer");
-                       Assert.AreEqual ("CN=Mono SSL Intermediate CA", x.GetIssuerName (), "GetIssuerName");
-                       Assert.AreEqual ("CN=FARSCAPE", x.Subject, "Subject");
-                       Assert.AreEqual ("CN=FARSCAPE", x.GetName (), "GetName");
-                       byte[] hash = { 0x30, 0x29, 0x69, 0x4B, 0x22, 0xB2, 0xEE, 0x6A, 0xEC, 0x9B, 0x78, 0x44, 0x9E, 0x51, 0x0F, 0x7C, 0x34, 0x8D, 0xBA, 0x33 };
-                       Assert.AreEqual (hash, x.GetCertHash (), "GetCertHash");
-                       Assert.AreEqual ("3029694B22B2EE6AEC9B78449E510F7C348DBA33", x.GetCertHashString (), "GetCertHashString");
-                       long from = DateTime.Parse (x.GetEffectiveDateString ()).ToUniversalTime ().Ticks;
-                       Assert.AreEqual (632054986620000000, from, "GetEffectiveDateString");
-                       long until = DateTime.Parse (x.GetExpirationDateString ()).ToUniversalTime ().Ticks;
-                       Assert.AreEqual (643445855990000000, until, "GetExpirationDateString");
-                       Assert.AreEqual ("X509", x.GetFormat (), "GetFormat");
-                       Assert.AreEqual (808020299, x.GetHashCode (), "GetHashCode");
-                       Assert.AreEqual ("1.2.840.113549.1.1.1", x.GetKeyAlgorithm (), "GetKeyAlgorithm");
-                       byte[] keyparams = { 0x05,0x00 };
-                       Assert.AreEqual (keyparams, x.GetKeyAlgorithmParameters (), "GetKeyAlgorithmParameters");
-                       Assert.AreEqual ("0500", x.GetKeyAlgorithmParametersString (), "GetKeyAlgorithmParametersString");
-                       byte[] pubkey = { 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xC4, 0x26, 0x3B, 0xE9, 0x49, 0x07, 0x39, 0x8C, 0x51, 0x34, 0x3B, 0x84, 0x4C, 0x27, 0x98, 0x70, 0x15, 0x79, 0xF1, 0xF4, 0x2A, 0x32, 0x82, 0xC3, 0xFA, 0xCF, 0x6E, 0x72, 0x37, 0xCE, 0x37, 0x55, 0x1F, 0xFA, 0x8F, 0x78, 0x4A, 0xA0, 0x0C, 0x9D, 0x44, 0x29, 0xF2, 0x81, 0xD9, 0x87, 0xD5, 0x94, 
-                               0x1A, 0xFC, 0x8D, 0xF8, 0x9D, 0xE0, 0xC5, 0xD2, 0x4A, 0x4F, 0x68, 0xD3, 0xAD, 0x65, 0x23, 0xB2, 0x4F, 0x48, 0x35, 0xB9, 0xFE, 0xE1, 0xDB, 0x6B, 0xE7, 0x41, 0x76, 0xEC, 0x0C, 0x5B, 0x3A, 0xE3, 0x07, 0xC9, 0x3D, 0x94, 0x48, 0xF2, 0xCF, 0x71, 0xAC, 0x2F, 0x71, 0x60, 0x15, 0x0E, 0xD5, 0x9A, 0xF8, 0x6C, 0x7F, 0xE9, 0xC0, 0x19, 0x18, 0x72, 
-                               0x09, 0xA1, 0xD6, 0xB8, 0xA9, 0x60, 0xD1, 0xC3, 0x18, 0x91, 0x98, 0xCE, 0x9A, 0x44, 0x3D, 0xCF, 0x63, 0x79, 0x41, 0x27, 0x18, 0xB3, 0x8E, 0x05, 0x02, 0x03, 0x01, 0x00, 0x01 };
-                       Assert.AreEqual (pubkey, x.GetPublicKey (), "GetPublicKey");
-                       Assert.AreEqual ("30818902818100C4263BE94907398C51343B844C2798701579F1F42A3282C3FACF6E7237CE37551FFA8F784AA00C9D4429F281D987D5941AFC8DF89DE0C5D24A4F68D3AD6523B24F4835B9FEE1DB6BE74176EC0C5B3AE307C93D9448F2CF71AC2F7160150ED59AF86C7FE9C019187209A1D6B8A960D1C3189198CE9A443DCF6379412718B38E050203010001", x.GetPublicKeyString (), "GetPublicKeyString");
-                       Assert.AreEqual (cert, x.GetRawCertData (), "GetRawCertData");
-                       byte[] serial = { 0x95, 0xF5, 0x2F, 0xE1, 0xF4, 0xC3, 0x0C, 0x4A, 0x91, 0x9A, 0x99, 0x86, 0xD9, 0xCD, 0x8B, 0x74 };
-                       Assert.AreEqual (serial, x.GetSerialNumber (), "GetSerialNumber");
-                       Assert.AreEqual ("748BCDD986999A914A0CC3F4E12FF595", x.GetSerialNumberString (), "GetSerialNumberString");
-               }
-
-               [Test]
-               public void Pkcs12_1_Properties ()
-               {
-                       CheckPkcs12 (new X509Certificate (farscape_pfx, "farscape"));
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Pkcs12_1_WithoutPassword ()
-               {
-                       new X509Certificate (farscape_pfx);
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Pkcs12_1_BadPassword ()
-               {
-                       new X509Certificate (farscape_pfx, "b4d p4zzw0rd");
-               }
-
-               [Test]
-               public void Pkcs12_2_Properties ()
-               {
-                       CheckPkcs12 (new X509Certificate (farscape_nopwd_pfx));
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Pkcs12_2_WithUnrequiredPassword ()
-               {
-                       new X509Certificate (farscape_nopwd_pfx, "n0t n33d3d");
-               }
-
-               [Test]
-               public void Pkcs12_3_Properties ()
-               {
-                       CheckPkcs12 (new X509Certificate (farscape_path_pfx, "farscape"));
-               }
-
-               [Test]
-               public void Pkcs12_4_Properties ()
-               {
-                       CheckPkcs12 (new X509Certificate (farscape_strong_pfx, "farscape"));
-               }
-
-               [Test]
-               public void Pkcs12_5_Properties ()
-               {
-                       CheckPkcs12 (new X509Certificate (farscape_strong_path_pfx, "farscape"));
-               }
-
-               private void CheckBase64 (X509Certificate x)
-               {
-                       // note: the raw data is still the DER encoded ASN.1 (not the base64 string)
-                       byte[] cert = { 0x30, 0x82, 0x01, 0xC5, 0x30, 0x82, 0x01, 0x32, 0xA0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x10, 0xC7, 0x75, 0xAE, 0x48, 0x53, 0x9B, 0x1E, 0x9E, 0x44, 0x80, 0x15, 0xCA, 0x78, 0x15, 0x47, 0x69, 0x30, 0x09, 
-                               0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x30, 0x25, 0x31, 0x23, 0x30, 0x21, 0x06, 0x03, 0x55, 0x04, 0x03, 0x1E, 0x1A, 0x00, 0x43, 0x00, 0x41, 0x00, 0x53, 0x00, 0x54, 0x00, 0x4F, 0x00, 0x52, 
-                               0x00, 0x5C, 0x00, 0x70, 0x00, 0x6F, 0x00, 0x75, 0x00, 0x70, 0x00, 0x6F, 0x00, 0x75, 0x30, 0x1E, 0x17, 0x0D, 0x30, 0x35, 0x30, 0x36, 0x30, 0x38, 0x31, 0x33, 0x33, 0x38, 0x34, 0x37, 0x5A, 0x17, 0x0D, 0x30, 
-                               0x36, 0x30, 0x36, 0x30, 0x38, 0x31, 0x39, 0x33, 0x38, 0x34, 0x37, 0x5A, 0x30, 0x25, 0x31, 0x23, 0x30, 0x21, 0x06, 0x03, 0x55, 0x04, 0x03, 0x1E, 0x1A, 0x00, 0x43, 0x00, 0x41, 0x00, 0x53, 0x00, 0x54, 0x00, 
-                               0x4F, 0x00, 0x52, 0x00, 0x5C, 0x00, 0x70, 0x00, 0x6F, 0x00, 0x75, 0x00, 0x70, 0x00, 0x6F, 0x00, 0x75, 0x30, 0x81, 0x9F, 0x30, 0x0D, 0x06, 0x09, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x01, 0x05, 
-                               0x00, 0x03, 0x81, 0x8D, 0x00, 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xDA, 0xEA, 0x39, 0x38, 0xF6, 0x3A, 0xF4, 0x8B, 0xF9, 0xE2, 0xC7, 0xD5, 0x2C, 0xF9, 0x1A, 0xD5, 0x75, 0xCF, 0x17, 0xAC, 0xB3, 0x46, 
-                               0xBD, 0x7F, 0x3F, 0x97, 0x38, 0x2E, 0x10, 0x41, 0xB2, 0xC4, 0xD9, 0x14, 0x15, 0xD8, 0xE6, 0xF9, 0x11, 0x38, 0x80, 0x75, 0xE3, 0xD7, 0x1F, 0xC0, 0x86, 0xA7, 0x3E, 0x02, 0x11, 0x04, 0xE9, 0x57, 0xB5, 0xD8, 
-                               0x57, 0x65, 0x27, 0x7B, 0x8F, 0xBA, 0xB9, 0xEF, 0xA0, 0x8F, 0x15, 0x9C, 0xEC, 0x2F, 0x85, 0x63, 0x4E, 0x52, 0x6B, 0xA6, 0xE3, 0x33, 0xCA, 0x86, 0x22, 0xBA, 0xF9, 0x06, 0xE8, 0xEC, 0xCB, 0xA7, 0xA5, 0xA8, 
-                               0xE2, 0x3E, 0xC7, 0x21, 0x74, 0x4E, 0xC9, 0xE9, 0x05, 0x5F, 0xAE, 0x78, 0x12, 0x51, 0x2F, 0xFA, 0x6A, 0x8F, 0x7C, 0xB0, 0x64, 0x2A, 0xFB, 0xB7, 0xB2, 0x40, 0x91, 0x20, 0xE7, 0x32, 0x53, 0x3F, 0x58, 0xCA, 
-                               0x80, 0xA2, 0x41, 0xC5, 0x02, 0x03, 0x01, 0x00, 0x01, 0x30, 0x09, 0x06, 0x05, 0x2B, 0x0E, 0x03, 0x02, 0x1D, 0x05, 0x00, 0x03, 0x81, 0x81, 0x00, 0x9D, 0x57, 0xB0, 0x25, 0x97, 0x81, 0x22, 0x3C, 0xC4, 0x61, 
-                               0x9D, 0xC9, 0xDB, 0xD8, 0xC7, 0xC1, 0xED, 0xFB, 0x1C, 0xDD, 0x35, 0x98, 0xD7, 0x40, 0x58, 0xA4, 0x43, 0x86, 0x54, 0xF9, 0x68, 0x96, 0x85, 0xB5, 0x91, 0xBC, 0xB7, 0x82, 0xB2, 0x7E, 0x7B, 0x58, 0xBD, 0x80, 
-                               0xCE, 0x34, 0x7E, 0x22, 0x87, 0x62, 0x31, 0xB5, 0x03, 0x16, 0xA0, 0x20, 0x17, 0x9D, 0xE7, 0x5D, 0xAA, 0x12, 0xF5, 0x92, 0xDF, 0x94, 0xE6, 0x69, 0xCD, 0xF6, 0xFC, 0x82, 0x9B, 0xDC, 0xD3, 0x30, 0x40, 0xB1, 
-                               0x71, 0x4F, 0x4A, 0x64, 0xCB, 0xDC, 0x14, 0xC8, 0xC1, 0x7F, 0x6F, 0x23, 0xCE, 0xDD, 0x19, 0x22, 0x4F, 0x24, 0x1E, 0x27, 0x18, 0x66, 0x88, 0x7A, 0x9A, 0x9A, 0x09, 0x37, 0x6D, 0x65, 0x15, 0xE8, 0x28, 0x5E, 
-                               0x82, 0xEB, 0x5B, 0x82, 0xE8, 0x8A, 0xAC, 0x8F, 0xC3, 0x6C, 0xEE, 0xF0, 0x3E, 0x20, 0xCB, 0xC7 };
-                       Assert.AreEqual ("CN=CASTOR\\poupou", x.Issuer, "Issuer");
-                       Assert.AreEqual ("CN=CASTOR\\poupou", x.GetIssuerName (), "GetIssuerName");
-                       Assert.AreEqual ("CN=CASTOR\\poupou", x.Subject, "Subject");
-                       Assert.AreEqual ("CN=CASTOR\\poupou", x.GetName (), "GetName");
-                       byte[] hash = { 0x1D, 0x53, 0xCC, 0x89, 0xD0, 0x9F, 0x11, 0x4A, 0x48, 0x7F, 0x7F, 0x52, 0x9E, 0xCB, 0xD1, 0x86, 0xA3, 0xD5, 0x85, 0x29 };
-                       Assert.AreEqual (hash, x.GetCertHash (), "GetCertHash");
-                       Assert.AreEqual ("1D53CC89D09F114A487F7F529ECBD186A3D58529", x.GetCertHashString (), "GetCertHashString");
-                       long from = DateTime.Parse (x.GetEffectiveDateString ()).ToUniversalTime ().Ticks;
-                       Assert.AreEqual (632538347270000000, from, "GetEffectiveDateString");
-                       long until = DateTime.Parse (x.GetExpirationDateString ()).ToUniversalTime ().Ticks;
-                       Assert.AreEqual (632853923270000000, until, "GetExpirationDateString");
-                       Assert.AreEqual ("X509", x.GetFormat (), "GetFormat");
-                       Assert.AreEqual (492031113, x.GetHashCode (), "GetHashCode");
-                       Assert.AreEqual ("1.2.840.113549.1.1.1", x.GetKeyAlgorithm (), "GetKeyAlgorithm");
-                       byte[] keyparams = { 0x05, 0x00 };
-                       Assert.AreEqual (keyparams, x.GetKeyAlgorithmParameters (), "GetKeyAlgorithmParameters");
-                       Assert.AreEqual ("0500", x.GetKeyAlgorithmParametersString (), "GetKeyAlgorithmParametersString");
-                       byte[] pubkey = { 0x30, 0x81, 0x89, 0x02, 0x81, 0x81, 0x00, 0xDA, 0xEA, 0x39, 0x38, 0xF6, 0x3A, 0xF4, 0x8B, 0xF9, 0xE2, 0xC7, 0xD5, 0x2C, 0xF9, 0x1A, 0xD5, 0x75, 0xCF, 0x17, 0xAC, 0xB3, 0x46, 0xBD, 0x7F, 0x3F, 0x97, 0x38, 0x2E, 0x10, 0x41, 0xB2, 0xC4, 0xD9, 0x14, 0x15, 0xD8, 0xE6, 0xF9, 0x11, 0x38, 0x80, 0x75, 0xE3, 0xD7, 0x1F, 0xC0, 0x86, 
-                               0xA7, 0x3E, 0x02, 0x11, 0x04, 0xE9, 0x57, 0xB5, 0xD8, 0x57, 0x65, 0x27, 0x7B, 0x8F, 0xBA, 0xB9, 0xEF, 0xA0, 0x8F, 0x15, 0x9C, 0xEC, 0x2F, 0x85, 0x63, 0x4E, 0x52, 0x6B, 0xA6, 0xE3, 0x33, 0xCA, 0x86, 0x22, 0xBA, 0xF9, 0x06, 0xE8, 0xEC, 0xCB, 0xA7, 0xA5, 0xA8, 0xE2, 0x3E, 0xC7, 0x21, 0x74, 0x4E, 0xC9, 0xE9, 0x05, 0x5F, 0xAE, 0x78, 0x12, 
-                               0x51, 0x2F, 0xFA, 0x6A, 0x8F, 0x7C, 0xB0, 0x64, 0x2A, 0xFB, 0xB7, 0xB2, 0x40, 0x91, 0x20, 0xE7, 0x32, 0x53, 0x3F, 0x58, 0xCA, 0x80, 0xA2, 0x41, 0xC5, 0x02, 0x03, 0x01, 0x00, 0x01 };
-                       Assert.AreEqual (pubkey, x.GetPublicKey (), "GetPublicKey");
-                       Assert.AreEqual ("30818902818100DAEA3938F63AF48BF9E2C7D52CF91AD575CF17ACB346BD7F3F97382E1041B2C4D91415D8E6F911388075E3D71FC086A73E021104E957B5D85765277B8FBAB9EFA08F159CEC2F85634E526BA6E333CA8622BAF906E8ECCBA7A5A8E23EC721744EC9E9055FAE7812512FFA6A8F7CB0642AFBB7B2409120E732533F58CA80A241C50203010001", x.GetPublicKeyString (), "GetPublicKeyString");
-                       Assert.AreEqual (cert, x.GetRawCertData (), "GetRawCertData");
-                       byte[] serial = { 0x69, 0x47, 0x15, 0x78, 0xCA, 0x15, 0x80, 0x44, 0x9E, 0x1E, 0x9B, 0x53, 0x48, 0xAE, 0x75, 0xC7 };
-                       Assert.AreEqual (serial, x.GetSerialNumber (), "GetSerialNumber");
-                       Assert.AreEqual ("C775AE48539B1E9E448015CA78154769", x.GetSerialNumberString (), "GetSerialNumberString");
-               }
-
-               [Test]
-               public void Base64_AsByteArray_Properties ()
-               {
-                       // note: the X509Certificate(string) ctor is used for a filename
-                       byte[] raw = Encoding.ASCII.GetBytes (base64_cert);
-                       CheckBase64 (new X509Certificate (raw));
-               }
-
-               [Test]
-               public void Base64_AsFile_Properties ()
-               {
-                       string temp = Path.GetTempFileName ();
-                       try {
-                               using (StreamWriter sw = new StreamWriter (temp)) {
-                                       sw.Write (base64_cert);
-                               }
-                               CheckBase64 (new X509Certificate (temp));
-                       }
-                       finally {
-                               if (File.Exists (temp))
-                                       File.Delete (temp);
-                       }
-               }
-
-               private bool RunningOnWindows ()
-               {
-                       int i = (int) Environment.OSVersion.Platform;
-                       return ((i != 4) && (i != 128));
-               }
-
-               [Test]
-               public void Base64_AsStringData ()
-               {
-                       try {
-                               new X509Certificate (base64_cert);
-                               Assert.Fail ("Expected ArgumentException(Windows) or PathTooLongException(Linux)");
-                       }
-                       catch (ArgumentException) {
-                               // path is invalid on Windows
-                               if (!RunningOnWindows ())
-                                       throw;
-                       }
-                       catch (PathTooLongException) {
-                               // path is too long on Linux
-                               if (RunningOnWindows ())
-                                       throw;
-                       }
-                   catch (DirectoryNotFoundException) {
-                       }
-                       catch (Exception e) {
-                               Assert.Fail (e.ToString ());
-                       }
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Pkcs7_Ctor ()
-               {
-                       new X509Certificate (farscape_pkcs7);
-               }
-
-               [Test]
-               [ExpectedException (typeof (CryptographicException))]
-               public void Pkcs7_Import ()
-               {
-                       X509Certificate x = new X509Certificate ();
-                       x.Import (farscape_pkcs7);
-               }
-       }
-}
-
-#endif
index db5dc018bf0826b225c46ad3208b716f3a6a883b..b10cbf3693449292ac103b05ea7691685ac44c3b 100644 (file)
@@ -4274,7 +4274,7 @@ namespace MonoTests.System.Security.Cryptography {
        // Note: they are to be called from specifics implementations -
        //   not for the abstract DES. Thats why they are in a separate class
        //   which doesn't have a [TestFixture] attribute
-       public class DESFIPS81Test {
+       public abstract class DESFIPS81Test {
                protected DES des;
 
                // Table B1 - ECB Mode
index e3d455bfe43d46f2be793a66c139ea621a6d1960..1707e49d919dbd8666e47f4f3b19a59508e2ca87 100644 (file)
@@ -40,7 +40,7 @@ namespace MonoTests.System.Security.Cryptography {
 
        // RIPEMD160 is a abstract class - so ALL of the test included here wont be tested
        // on the abstract class but should be tested in ALL its descendants.
-       public class RIPEMD160Test {
+       public abstract class RIPEMD160Test {
 
                protected RIPEMD160 hash;
 
index 3742d1dba9d458cae3c1dec375bf3f9ecc3de20e..e3186127c9dfa19278355774edaf9add0f8e43ae 100644 (file)
@@ -35,7 +35,7 @@ using System.Security.Cryptography;
 namespace MonoTests.System.Security.Cryptography {
 
 [TestFixture]
-public class RSACryptoServiceProviderTest : Assertion {
+public class RSACryptoServiceProviderTest {
 
        protected RSACryptoServiceProvider rsa;
        protected RSACryptoServiceProvider disposed;
@@ -74,15 +74,15 @@ public class RSACryptoServiceProviderTest : Assertion {
        public void AssertEquals (string message, RSAParameters expectedKey, RSAParameters actualKey, bool checkPrivateKey) 
        {
                if (checkPrivateKey) {
-                       AssertEquals (message + " P", expectedKey.P, actualKey.P);
-                       AssertEquals (message + " Q", expectedKey.Q, actualKey.Q);
-                       AssertEquals (message + " D", expectedKey.D, actualKey.D);
-                       AssertEquals (message + " DP", expectedKey.DP, actualKey.DP);
-                       AssertEquals (message + " DQ", expectedKey.DQ, actualKey.DQ);
-                       AssertEquals (message + " InverseQ", expectedKey.InverseQ, actualKey.InverseQ);
+                       Assert.AreEqual (expectedKey.P, actualKey.P, message + " P");
+                       Assert.AreEqual (expectedKey.Q, actualKey.Q, message + " Q");
+                       Assert.AreEqual (expectedKey.D, actualKey.D, message + " D");
+                       Assert.AreEqual (expectedKey.DP, actualKey.DP, message + " DP");
+                       Assert.AreEqual (expectedKey.DQ, actualKey.DQ, message + " DQ");
+                       Assert.AreEqual (expectedKey.InverseQ, actualKey.InverseQ, message + " InverseQ");
                }
-               AssertEquals (message + " Modulus", expectedKey.Modulus, actualKey.Modulus);
-               AssertEquals (message + " Exponent", expectedKey.Exponent, actualKey.Exponent);
+               Assert.AreEqual (expectedKey.Modulus, actualKey.Modulus, message + " Modulus");
+               Assert.AreEqual (expectedKey.Exponent, actualKey.Exponent, message + " Exponent");
        }
 
        [Test]
@@ -91,10 +91,10 @@ public class RSACryptoServiceProviderTest : Assertion {
                // under Mono:: a new key pair isn't generated
                rsa = new RSACryptoServiceProvider ();
                // test default key size
-               AssertEquals ("ConstructorEmpty", 1024, rsa.KeySize);
-               Assert ("PersistKeyInCsp", !rsa.PersistKeyInCsp);
+               Assert.AreEqual (1024, rsa.KeySize, "ConstructorEmpty");
+               Assert.IsFalse (rsa.PersistKeyInCsp, "PersistKeyInCsp");
 #if NET_2_0
-               Assert ("PublicOnly", !rsa.PublicOnly);
+               Assert.IsFalse (rsa.PublicOnly, "PublicOnly");
 #endif
        }
 
@@ -103,10 +103,10 @@ public class RSACryptoServiceProviderTest : Assertion {
        {
                rsa = new RSACryptoServiceProvider (minKeySize);
                // test default key size
-               AssertEquals ("ConstructorKeySize", minKeySize, rsa.KeySize);
-               Assert ("PersistKeyInCsp", !rsa.PersistKeyInCsp);
+               Assert.AreEqual (minKeySize, rsa.KeySize, "ConstructorKeySize");
+               Assert.IsFalse (rsa.PersistKeyInCsp, "PersistKeyInCsp");
 #if NET_2_0
-               Assert ("PublicOnly", !rsa.PublicOnly);
+               Assert.IsFalse (rsa.PublicOnly, "PublicOnly");
 #endif
        }
 
@@ -118,10 +118,10 @@ public class RSACryptoServiceProviderTest : Assertion {
                // under MS a new keypair will only be generated the first time
                rsa = new RSACryptoServiceProvider (csp);
                // test default key size
-               AssertEquals ("ConstructorCspParameters", 1024, rsa.KeySize);
-               Assert ("PersistKeyInCsp", rsa.PersistKeyInCsp);
+               Assert.AreEqual (1024, rsa.KeySize, "ConstructorCspParameters");
+               Assert.IsTrue (rsa.PersistKeyInCsp, "PersistKeyInCsp");
 #if NET_2_0
-               Assert ("PublicOnly", !rsa.PublicOnly);
+               Assert.IsFalse (rsa.PublicOnly, "PublicOnly");
 #endif
        }
 
@@ -132,10 +132,10 @@ public class RSACryptoServiceProviderTest : Assertion {
                int keySize = 512;
                CspParameters csp = new CspParameters (1, null, "Mono512");
                rsa = new RSACryptoServiceProvider (keySize, csp);
-               AssertEquals ("ConstructorCspParameters", keySize, rsa.KeySize);
-               Assert ("PersistKeyInCsp", rsa.PersistKeyInCsp);
+               Assert.AreEqual (keySize, rsa.KeySize, "ConstructorCspParameters");
+               Assert.IsTrue (rsa.PersistKeyInCsp, "PersistKeyInCsp");
 #if NET_2_0
-               Assert ("PublicOnly", !rsa.PublicOnly);
+               Assert.IsFalse (rsa.PublicOnly, "PublicOnly");
 #endif
        }
 
@@ -147,7 +147,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                KeySizes LegalKeySize = rsa.LegalKeySizes [0];
                for (int i = LegalKeySize.MinSize; i <= LegalKeySize.MaxSize; i += LegalKeySize.SkipSize) {
                        rsa = new RSACryptoServiceProvider (i);
-                       AssertEquals ("KeySize", i, rsa.KeySize);
+                       Assert.AreEqual (i, rsa.KeySize, "KeySize");
                }
        }
 
@@ -192,19 +192,19 @@ public class RSACryptoServiceProviderTest : Assertion {
        public void Properties () 
        {
                rsa = new RSACryptoServiceProvider (minKeySize);
-               AssertEquals ("LegalKeySize", 1, rsa.LegalKeySizes.Length);
-               AssertEquals ("LegalKeySize.MinSize", minKeySize, rsa.LegalKeySizes [0].MinSize);
-               AssertEquals ("LegalKeySize.MaxSize", 16384, rsa.LegalKeySizes [0].MaxSize);
-               AssertEquals ("LegalKeySize.SkipSize", 8, rsa.LegalKeySizes [0].SkipSize);
-               AssertEquals ("KeyExchangeAlgorithm", "RSA-PKCS1-KeyEx", rsa.KeyExchangeAlgorithm);
-               AssertEquals ("SignatureAlgorithm", "http://www.w3.org/2000/09/xmldsig#rsa-sha1", rsa.SignatureAlgorithm);
+               Assert.AreEqual (1, rsa.LegalKeySizes.Length, "LegalKeySize");
+               Assert.AreEqual (minKeySize, rsa.LegalKeySizes [0].MinSize, "LegalKeySize.MinSize");
+               Assert.AreEqual (16384, rsa.LegalKeySizes [0].MaxSize, "LegalKeySize.MaxSize");
+               Assert.AreEqual (8, rsa.LegalKeySizes [0].SkipSize, "LegalKeySize.SkipSize");
+               Assert.AreEqual ("RSA-PKCS1-KeyEx", rsa.KeyExchangeAlgorithm, "KeyExchangeAlgorithm");
+               Assert.AreEqual ("http://www.w3.org/2000/09/xmldsig#rsa-sha1", rsa.SignatureAlgorithm, "SignatureAlgorithm");
                rsa.Clear ();
-               AssertEquals ("LegalKeySize(disposed)", 1, rsa.LegalKeySizes.Length);
-               AssertEquals ("LegalKeySize.MinSize(disposed)", minKeySize, rsa.LegalKeySizes [0].MinSize);
-               AssertEquals ("LegalKeySize.MaxSize(disposed)", 16384, rsa.LegalKeySizes [0].MaxSize);
-               AssertEquals ("LegalKeySize.SkipSize(disposed)", 8, rsa.LegalKeySizes [0].SkipSize);
-               AssertEquals ("KeyExchangeAlgorithm(disposed)", "RSA-PKCS1-KeyEx", rsa.KeyExchangeAlgorithm);
-               AssertEquals ("SignatureAlgorithm(disposed)", "http://www.w3.org/2000/09/xmldsig#rsa-sha1", rsa.SignatureAlgorithm);
+               Assert.AreEqual (1, rsa.LegalKeySizes.Length, "LegalKeySize(disposed)");
+               Assert.AreEqual (minKeySize, rsa.LegalKeySizes [0].MinSize, "LegalKeySize.MinSize(disposed)");
+               Assert.AreEqual (16384, rsa.LegalKeySizes [0].MaxSize, "LegalKeySize.MaxSize(disposed)");
+               Assert.AreEqual (8, rsa.LegalKeySizes [0].SkipSize, "LegalKeySize.SkipSize(disposed)");
+               Assert.AreEqual ("RSA-PKCS1-KeyEx", rsa.KeyExchangeAlgorithm, "KeyExchangeAlgorithm(disposed)");
+               Assert.AreEqual ("http://www.w3.org/2000/09/xmldsig#rsa-sha1", rsa.SignatureAlgorithm, "SignatureAlgorithm(disposed)");
        }
 
        [Test]
@@ -217,7 +217,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                int total = 0;
                for (int i=0; i < data.Length; i++)
                        total += data [i];
-               AssertEquals ("DecryptDisposed", 0, total);
+               Assert.AreEqual (0, total, "DecryptDisposed");
        }
 
        [Test]
@@ -276,8 +276,8 @@ public class RSACryptoServiceProviderTest : Assertion {
                byte [] hash = new byte [20];
                rsa = new RSACryptoServiceProvider (minKeySize);
                byte[] signature = rsa.SignHash (hash, null);
-               Assert ("Null OID == SHA1", rsa.VerifyHash (hash, "1.3.14.3.2.26", signature));
-               Assert ("Null OID", rsa.VerifyHash (hash, null, signature));
+               Assert.IsTrue (rsa.VerifyHash (hash, "1.3.14.3.2.26", signature), "Null OID == SHA1");
+               Assert.IsTrue (rsa.VerifyHash (hash, null, signature), "Null OID");
        }
 
        void SignHash (string name, int size)
@@ -286,8 +286,8 @@ public class RSACryptoServiceProviderTest : Assertion {
                byte [] hash = new byte [size];
                rsa = new RSACryptoServiceProvider (1024);
                byte [] signature = rsa.SignHash (hash, oid);
-               Assert (name, rsa.VerifyHash (hash, oid, signature));
-               Assert ("OID", rsa.VerifyHash (hash, oid, signature));
+               Assert.IsTrue (rsa.VerifyHash (hash, oid, signature), name);
+               Assert.IsTrue (rsa.VerifyHash (hash, oid, signature), "OID");
        }
 
        [Test]
@@ -325,7 +325,7 @@ public class RSACryptoServiceProviderTest : Assertion {
        public void SignHashRIPEMD160 ()
        {
                string oid = CryptoConfig.MapNameToOID ("RIPEMD160");
-               AssertNotNull (oid);
+               Assert.IsNotNull (oid);
                byte [] hash = new byte [20];
                rsa = new RSACryptoServiceProvider (minKeySize);
                // OID not supported
@@ -499,43 +499,43 @@ public class RSACryptoServiceProviderTest : Assertion {
                rsa = new RSACryptoServiceProvider ();
 
                rsa.FromXmlString (CapiXml384);
-               AssertEquals ("Capi-Xml384", CapiXml384, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml384, rsa.ToXmlString (true), "Capi-Xml384");
 
                rsa.FromXmlString (CapiXml448);
-               AssertEquals ("Capi-Xml448", CapiXml448, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml448, rsa.ToXmlString (true), "Capi-Xml448");
 
                rsa.FromXmlString (CapiXml512);
-               AssertEquals ("Capi-Xml512", CapiXml512, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml512, rsa.ToXmlString (true), "Capi-Xml512");
 
                rsa.FromXmlString (CapiXml576);
-               AssertEquals ("Capi-Xml576", CapiXml576, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml576, rsa.ToXmlString (true), "Capi-Xml576");
 
                rsa.FromXmlString (CapiXml640);
-               AssertEquals ("Capi-Xml640", CapiXml640, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml640, rsa.ToXmlString (true), "Capi-Xml640");
 
                rsa.FromXmlString (CapiXml704);
-               AssertEquals ("Capi-Xml704", CapiXml704, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml704, rsa.ToXmlString (true), "Capi-Xml704");
 
                rsa.FromXmlString (CapiXml768);
-               AssertEquals ("Capi-Xml768", CapiXml768, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml768, rsa.ToXmlString (true), "Capi-Xml768");
 
                rsa.FromXmlString (CapiXml832);
-               AssertEquals ("Capi-Xml832", CapiXml832, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml832, rsa.ToXmlString (true), "Capi-Xml832");
 
                rsa.FromXmlString (CapiXml896);
-               AssertEquals ("Capi-Xml896", CapiXml896, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml896, rsa.ToXmlString (true), "Capi-Xml896");
 
                rsa.FromXmlString (CapiXml960);
-               AssertEquals ("Capi-Xml960", CapiXml960, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml960, rsa.ToXmlString (true), "Capi-Xml960");
 
                rsa.FromXmlString (CapiXml1024);
-               AssertEquals ("Capi-Xml1024", CapiXml1024, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml1024, rsa.ToXmlString (true), "Capi-Xml1024");
 
                rsa.FromXmlString (CapiXml1536);
-               AssertEquals ("Capi-Xml1536", CapiXml1536, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml1536, rsa.ToXmlString (true), "Capi-Xml1536");
 
                rsa.FromXmlString (CapiXml2048);
-               AssertEquals ("Capi-Xml2048", CapiXml2048, rsa.ToXmlString (true));
+               Assert.AreEqual (CapiXml2048, rsa.ToXmlString (true), "Capi-Xml2048");
        }
 
        [Test]
@@ -571,7 +571,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                // the signature is never the same so the only way to know if 
                // it worked is to verify it ourselve (i.e. can't compare)
                bool ok = key.VerifyHash (hash, sha1OID, sign);
-               Assert (msg + "-SignAndVerify", ok);
+               Assert.IsTrue (ok, msg + "-SignAndVerify");
        }
 
        // Validate that we can sign with every keypair and verify the signature
@@ -648,81 +648,81 @@ public class RSACryptoServiceProviderTest : Assertion {
 
                rsa.FromXmlString (CapiXml384);
                byte[] sign384 = { 0x6D, 0x6F, 0xE1, 0x17, 0x28, 0x88, 0x0C, 0x72, 0x9D, 0x17, 0xBD, 0x06, 0x02, 0xBA, 0x6D, 0xF0, 0x16, 0x2A, 0xE6, 0x19, 0x40, 0x1D, 0x58, 0xD3, 0x44, 0x70, 0xDE, 0x57, 0x4C, 0xC8, 0xE5, 0x9C, 0x5D, 0xA1, 0x84, 0x7E, 0xD4, 0xC3, 0x61, 0xAA, 0x21, 0xC3, 0x83, 0x5B, 0xAF, 0x1C, 0xB7, 0x2B };
-               Assert ("Capi-384-Verify", rsa.VerifyHash (hash, sha1OID, sign384));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign384), "Capi-384-Verify");
                sign384[0] = 0x00;
-               Assert ("Capi-384-VerBad", !rsa.VerifyHash (hash, sha1OID, sign384));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign384), "Capi-384-VerBad");
 
                rsa.FromXmlString (CapiXml448);
                byte[] sign448 = { 0x59, 0xD9, 0x57, 0x80, 0x20, 0x18, 0xF6, 0x23, 0xDB, 0x3A, 0xE3, 0xB0, 0xFD, 0xEA, 0xD3, 0x2A, 0x52, 0x83, 0x41, 0x49, 0x48, 0xD8, 0xD5, 0x4F, 0xE7, 0xDB, 0x7A, 0x97, 0xF9, 0x07, 0x27, 0xD9, 0xAC, 0x60, 0xA2, 0x17, 0x76, 0x70, 0x09, 0x09, 0x23, 0x0E, 0xBF, 0x3D, 0x01, 0x93, 0x91, 0x97, 0xDB, 0xB3, 0x1F, 0x20, 0x78, 0xFA, 0x7E, 0x72 };
-               Assert ("Capi-448-Verify", rsa.VerifyHash (hash, sha1OID, sign448));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign448), "Capi-448-Verify");
                sign448[0] = 0x00;
-               Assert ("Capi-448-VerBad", !rsa.VerifyHash (hash, sha1OID, sign448));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign448), "Capi-448-VerBad");
 
                rsa.FromXmlString (CapiXml512);
                byte[] sign512 = { 0x66, 0x80, 0x40, 0x76, 0x01, 0xDA, 0x66, 0xF2, 0x36, 0x5C, 0xCE, 0x4C, 0x47, 0xA1, 0x02, 0x1C, 0x4F, 0xC8, 0xCE, 0xB2, 0x01, 0xC2, 0xD1, 0x54, 0x55, 0x41, 0xAF, 0x12, 0x60, 0xD7, 0x49, 0x9A, 0x4B, 0x37, 0x20, 0x1A, 0x2A, 0xD8, 0x2B, 0x82, 0xCA, 0x84, 0xAF, 0xB3, 0xB1, 0x4D, 0xA9, 0x0B, 0x70, 0x17, 0x3B, 0xD8, 0x17, 0xAA, 0x51, 0xE7, 0x1F, 0xB7, 0xCF, 0xD8, 0xF9, 0x32, 0x60, 0x01 };
-               Assert ("Capi-512-Verify", rsa.VerifyHash (hash, sha1OID, sign512));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign512), "Capi-512-Verify");
                sign512[0] = 0x00;
-               Assert ("Capi-512-VerBad", !rsa.VerifyHash (hash, sha1OID, sign512));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign512), "Capi-512-VerBad");
 
                rsa.FromXmlString (CapiXml576);
                byte[] sign576 = { 0x25, 0x39, 0x21, 0xDE, 0x34, 0x23, 0xEC, 0xFE, 0xEC, 0x28, 0xB2, 0xEA, 0x8D, 0x5A, 0x6C, 0x4B, 0x86, 0x2B, 0xEA, 0x6E, 0xB7, 0xBA, 0x1A, 0x38, 0x6A, 0x8C, 0xC9, 0xC5, 0xC1, 0x89, 0x84, 0x9F, 0x97, 0x5B, 0xA0, 0x58, 0xD6, 0x08, 0x09, 0x5B, 0x4C, 0x9A, 0x9F, 0xFF, 0x10, 0x8B, 0xD1, 0xEA, 0xED, 0x81, 0x62, 0x2D, 0x09, 0x87, 0x81, 0xED, 0x76, 0xCF, 0x47, 0xB8, 0xF8, 0x06, 0x84, 0x80, 0x8E, 0xBC, 0x8C, 0xDF, 0xF2, 0xEE, 0xAB, 0x47 };
-               Assert ("Capi-576-Verify", rsa.VerifyHash (hash, sha1OID, sign576));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign576), "Capi-576-Verify");
                sign576[0] = 0x00;
-               Assert ("Capi-576-VerBad", !rsa.VerifyHash (hash, sha1OID, sign576));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign576), "Capi-576-VerBad");
 
                rsa.FromXmlString (CapiXml640);
                byte[] sign640 = { 0x7E, 0x58, 0x16, 0x4E, 0xD9, 0xFE, 0x4D, 0x73, 0x2E, 0x6D, 0x5B, 0x62, 0x05, 0x91, 0x43, 0xA4, 0xEF, 0x65, 0xA9, 0x68, 0xA6, 0x19, 0x65, 0x8F, 0x25, 0xBC, 0x2B, 0xE2, 0x93, 0xE2, 0xEF, 0x5E, 0x29, 0x11, 0x0C, 0xCE, 0x17, 0x01, 0x5D, 0xB7, 0x71, 0x79, 0x83, 0xC5, 0xAB, 0x51, 0xBF, 0x87, 0x80, 0x4A, 0x04, 0x7B, 0xB4, 0x46, 0xCA, 0x11, 0x71, 0xB1, 0x67, 0x28, 0x4C, 0x16, 0x82, 0x6B, 0xE3, 0x11, 0x72, 0x6D, 0xA9, 0x07, 0x4A, 0xE6, 0x33, 0x45, 0x30, 0x15, 0x83, 0x23, 0x5E, 0x05 };
-               Assert ("Capi-640-Verify", rsa.VerifyHash (hash, sha1OID, sign640));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign640), "Capi-640-Verify");
                sign640[0] = 0x00;
-               Assert ("Capi-640-VerBad", !rsa.VerifyHash (hash, sha1OID, sign640));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign640), "Capi-640-VerBad");
 
                rsa.FromXmlString (CapiXml704);
                byte[] sign704 = { 0x91, 0x3C, 0x91, 0x7C, 0x2A, 0x26, 0xB1, 0x6F, 0x7C, 0xFD, 0x75, 0xCC, 0xB0, 0x63, 0x03, 0x76, 0xBF, 0x93, 0xAB, 0x3B, 0xD4, 0x71, 0x86, 0x86, 0xEF, 0x10, 0xD6, 0x51, 0x8D, 0x6B, 0xB4, 0xF2, 0xF9, 0xCC, 0x50, 0x3A, 0x63, 0x9A, 0xD2, 0xA2, 0xE2, 0x72, 0x06, 0x88, 0x4E, 0xCD, 0x38, 0x9B, 0x87, 0x72, 0xAD, 0x38, 0xF7, 0xCB, 0x6B, 0x69, 0x43, 0xA0, 0x4C, 0x9B, 0x10, 0x17, 0xAB, 0xE8, 0x50, 0x34, 0x6E, 0x8D, 0x56, 0xBC, 0x6C, 0x00, 0x87, 0x40, 0x05, 0x4A, 0x20, 0x16, 0x49, 0x4F, 0x93, 0x48, 0x5F, 0x7A, 0x10, 0x61, 0xC6, 0xC9 };
-               Assert ("Capi-704-Verify", rsa.VerifyHash (hash, sha1OID, sign704));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign704), "Capi-704-Verify");
                sign704[0] = 0x00;
-               Assert ("Capi-704-VerBad", !rsa.VerifyHash (hash, sha1OID, sign704));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign704), "Capi-704-VerBad");
 
                rsa.FromXmlString (CapiXml768);
                byte[] sign768 = { 0x0D, 0x67, 0x37, 0x00, 0x3E, 0xD5, 0x02, 0x12, 0xF0, 0xF9, 0xC2, 0x63, 0x29, 0xD9, 0xEA, 0x7B, 0xDC, 0x5B, 0xF3, 0xF0, 0xB9, 0x3B, 0x04, 0x98, 0xD9, 0xE7, 0xA3, 0xB2, 0xD2, 0x01, 0x04, 0x7A, 0xF4, 0x11, 0x7F, 0x62, 0xC7, 0x18, 0x14, 0xA0, 0x54, 0x96, 0x51, 0x84, 0xC4, 0x6D, 0x6A, 0xCB, 0x67, 0x07, 0xD0, 0x33, 0x93, 0x99, 0xAD, 0x1F, 0x16, 0xA6, 0x7F, 0xE0, 0x60, 0x8A, 0xDC, 0x95, 0xB9, 0x0E, 0x68, 0xA9, 0x78, 0xE1, 0x0D, 0x47, 0x56, 0xF3, 0x01, 0x42, 0xF6, 0xD7, 0xE4, 0x4A, 0x98, 0x7E, 0xC4, 0x5E, 0x0E, 0x09, 0xC4, 0x92, 0x42, 0x69, 0x74, 0x7A, 0xC9, 0x0E, 0x9F, 0xF2 };
-               Assert ("Capi-768-Verify", rsa.VerifyHash (hash, sha1OID, sign768));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign768), "Capi-768-Verify");
                sign768[0] = 0x00;
-               Assert ("Capi-768-VerBad", !rsa.VerifyHash (hash, sha1OID, sign768));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign768), "Capi-768-VerBad");
 
                rsa.FromXmlString (CapiXml832);
                byte[] sign832 = { 0x7B, 0xBC, 0xE6, 0xEC, 0x8B, 0x11, 0x7C, 0x28, 0x09, 0x3A, 0x06, 0x81, 0x52, 0x20, 0x7B, 0x50, 0x88, 0x74, 0x3C, 0x96, 0xBC, 0x40, 0xAF, 0x8E, 0xD3, 0x60, 0x49, 0xBF, 0x93, 0x6C, 0xF6, 0xE9, 0x34, 0xAB, 0x7E, 0xE7, 0x56, 0x2E, 0x33, 0x5A, 0x75, 0x4E, 0xFE, 0xFF, 0xC8, 0x15, 0x02, 0x8C, 0x30, 0x81, 0xD0, 0x46, 0x68, 0x42, 0x2E, 0xA8, 0x78, 0x5C, 0xDE, 0xEA, 0x98, 0x79, 0x81, 0xBF, 0xEA, 0xC4, 0x8B, 0x2F, 0x50, 0x7A, 0x50, 0x11, 0xAC, 0x01, 0xEB, 0x84, 0xA0, 0x9F, 0x7A, 0x67, 0xFA, 0x33, 0x3A, 0x65, 0x1C, 0xE9, 0xFA, 0xD9, 0x46, 0x06, 0xAF, 0x3E, 0x83, 0x4A, 0x67, 0x11, 0x0B, 0xD5, 0xD2, 0x56, 0x5E, 0x05, 0x69, 0xE8 };
-               Assert ("Capi-832-Verify", rsa.VerifyHash (hash, sha1OID, sign832));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign832), "Capi-832-Verify");
                sign832[0] = 0x00;
-               Assert ("Capi-832-VerBad", !rsa.VerifyHash (hash, sha1OID, sign832));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign832), "Capi-832-VerBad");
 
                rsa.FromXmlString (CapiXml896);
                byte[] sign896 = { 0x60, 0xAA, 0x26, 0x4D, 0xBF, 0x0A, 0x38, 0x5E, 0x7B, 0x66, 0x1E, 0x1D, 0xED, 0x5F, 0xF2, 0x6A, 0xC4, 0xAB, 0x35, 0x43, 0x93, 0x67, 0x26, 0x90, 0xEB, 0x34, 0xC1, 0xCB, 0x22, 0x4C, 0x20, 0x00, 0xE5, 0xEB, 0xA8, 0x14, 0x06, 0x8A, 0xBD, 0x0A, 0x07, 0x02, 0x62, 0xC9, 0x82, 0x27, 0x84, 0x1D, 0x04, 0xC6, 0xFC, 0x20, 0xE4, 0x17, 0x07, 0x33, 0x03, 0xE7, 0x33, 0x8D, 0x4A, 0x69, 0x79, 0x51, 0xA5, 0x20, 0xED, 0xB8, 0x94, 0x02, 0x0B, 0xD2, 0xB9, 0x60, 0x71, 0x56, 0x47, 0x96, 0xE8, 0xA7, 0x1A, 0x4A, 0x71, 0xD8, 0xD1, 0x0C, 0x82, 0x86, 0xF9, 0x1C, 0x07, 0x46, 0xB6, 0x0F, 0xCB, 0x8C, 0x90, 0x95, 0x93, 0xBA, 0xF2, 0xC3, 0xB4, 0x68, 0xE8, 0xE4, 0x55, 0x6C, 0xEA, 0x1D, 0xA7, 0x53 };
-               Assert ("Capi-896-Verify", rsa.VerifyHash (hash, sha1OID, sign896));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign896), "Capi-896-Verify");
                sign896[0] = 0x00;
-               Assert ("Capi-896-VerBad", !rsa.VerifyHash (hash, sha1OID, sign896));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign896), "Capi-896-VerBad");
 
                rsa.FromXmlString (CapiXml960);
                byte[] sign960 = { 0x57, 0x36, 0xBD, 0xF3, 0x5D, 0x99, 0x9A, 0x73, 0xF1, 0xE6, 0xC1, 0x4C, 0xDC, 0xBF, 0x5D, 0xC1, 0xC0, 0x7D, 0x32, 0x46, 0x2B, 0x0B, 0x51, 0xDB, 0x56, 0xA8, 0x25, 0xE7, 0xF9, 0x76, 0xB0, 0x0F, 0xC1, 0xBD, 0x49, 0x5E, 0x14, 0xF8, 0x1F, 0xD9, 0x94, 0x41, 0xA7, 0x4B, 0xF8, 0x9C, 0x4A, 0x9B, 0xA5, 0xF8, 0xDF, 0xE6, 0xF5, 0xF7, 0x6D, 0xFB, 0x59, 0x24, 0x9F, 0xAE, 0xBA, 0xDF, 0x51, 0x2F, 0xB2, 0x68, 0xF1, 0x35, 0xFB, 0xCC, 0xF7, 0x1D, 0x86, 0x2A, 0x2E, 0x53, 0x9F, 0xCA, 0xBC, 0x58, 0xBF, 0x6A, 0xBD, 0x3A, 0xAB, 0xCA, 0x64, 0x92, 0x42, 0x97, 0x87, 0x00, 0xEE, 0x4A, 0x3F, 0xE5, 0xED, 0x20, 0x49, 0xF4, 0x06, 0x53, 0xBA, 0xF8, 0x9D, 0x62, 0xC4, 0xC7, 0x99, 0x3E, 0x9C, 0xF9, 0xF1, 0xA6, 0xF7, 0x0D, 0x21, 0xBC, 0xF2, 0x8D };
-               Assert ("Capi-960-Verify", rsa.VerifyHash (hash, sha1OID, sign960));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign960), "Capi-960-Verify");
                sign960[0] = 0x00;
-               Assert ("Capi-960-VerBad", !rsa.VerifyHash (hash, sha1OID, sign960));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign960), "Capi-960-VerBad");
 
                rsa.FromXmlString (CapiXml1024);
                byte[] sign1024 = { 0x30, 0xB9, 0x7F, 0xBC, 0x72, 0x75, 0xB4, 0xEE, 0x8F, 0x8F, 0xF1, 0xB9, 0xC3, 0xCB, 0xC0, 0xB2, 0x94, 0x8C, 0x1D, 0xB0, 0x60, 0xE8, 0x5E, 0x8D, 0x3F, 0x36, 0xF2, 0x4E, 0x09, 0xCD, 0x48, 0x85, 0xD3, 0x93, 0xEC, 0xEB, 0x08, 0xA6, 0xD1, 0xEF, 0x9F, 0xF5, 0xAB, 0x2D, 0x30, 0x3E, 0x86, 0x64, 0x8F, 0x9B, 0xB4, 0x0F, 0xDB, 0x70, 0x4A, 0x59, 0x8D, 0x6F, 0x14, 0x03, 0xFE, 0x46, 0xFC, 0x81, 0xA8, 0xC9, 0x75, 0x40, 0xEE, 0xB1, 0xED, 0xC4, 0xD0, 0xE5, 0xE5, 0x8F, 0xCD, 0x10, 0x01, 0xB2, 0x9D, 0xFD, 0xE6, 0x1E, 0x43, 0x3A, 0x69, 0xDB, 0xF9, 0x6D, 0xC9, 0xDD, 0x57, 0x9C, 0x84, 0x94, 0x7D, 0x0C, 0xDC, 0xFA, 0xD9, 0xDA, 0xE6, 0x90, 0xBA, 0x8C, 0x15, 0x68, 0xEA, 0x09, 0xEE, 0x8D, 0x5D, 0x5D, 0x73, 0xDE, 0xD1, 0x76, 0xE2, 0xF1, 0x48, 0x23, 0x57, 0xA6, 0xFA, 0x37, 0x57, 0xE7 };
-               Assert ("Capi-1024-Verify", rsa.VerifyHash (hash, sha1OID, sign1024));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign1024), "Capi-1024-Verify");
                sign1024[0] = 0x00;
-               Assert ("Capi-1024-VerBad", !rsa.VerifyHash (hash, sha1OID, sign1024));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign1024), "Capi-1024-VerBad");
 
                rsa.FromXmlString (CapiXml1536);
                byte[] sign1536 = { 0x38, 0x0B, 0x7A, 0xF8, 0x64, 0xEB, 0x21, 0xCA, 0xC6, 0x7F, 0x09, 0x40, 0xD0, 0x92, 0x8C, 0x96, 0xEE, 0x47, 0x05, 0xFE, 0x17, 0xE9, 0x93, 0x97, 0xEF, 0x9F, 0xC0, 0xF1, 0xF5, 0x41, 0x91, 0x83, 0xEA, 0x77, 0x1B, 0x6A, 0x77, 0x4A, 0x14, 0xE2, 0xD9, 0x88, 0x8D, 0x8E, 0x91, 0xAF, 0x26, 0x87, 0xB9, 0xBC, 0x14, 0x52, 0xBD, 0xAD, 0x7E, 0x90, 0x00, 0x33, 0x1B, 0xF0, 0x08, 0x41, 0x7E, 0x77, 0x55, 0x4E, 0xAA, 0xF3, 0xAC, 0x8F, 0x00, 0x76, 0x25, 0xC0, 0x72, 0x88, 0xC0, 0xA4, 0x03, 0x46, 0xCC, 0xBC, 0xFE, 0x5A, 0x44, 0x10, 0x0D, 0x14, 0x7F, 0x65, 0x2E, 0x47, 0x55, 0x85, 0xF6, 0xC9, 0xEB, 0x60, 0x84, 0x09, 0x91, 0x3D, 0xAC, 0x8E, 0x40, 0x44, 0xE5, 0x7C, 0x4F, 0xAE, 0xA4, 0x21, 0x7D, 0x16, 0x27, 0xFC, 0x0E, 0xC5, 0x6B, 0x0C, 0x63, 0xA9, 0x1E, 0x0E, 0xCF, 0x9E, 0x8E, 0xFF, 0xA9, 0xA5, 0xB3, 0x87, 0xDC, 0x80, 0x71, 0xA2, 0x4F, 0x21, 0x80, 0xC2, 0x88, 0xC0, 0xA4, 0x99, 0x46, 0x96, 0x25, 0xFB, 0x73, 0x16, 0xCA, 0x97, 0x25, 0x5A, 0x92, 0x19, 0x50, 0xCD, 0xBA, 0xA0, 0x6D, 0xCA, 0x9F, 0x23, 0x14, 0x71, 0x51, 0xB8, 0x94, 0x47, 0xAC, 0xEE, 0x12, 0x53, 0x24, 0x7E, 0xF4, 0xD0, 0xD9, 0x51, 0x89, 0xDA, 0x1C, 0x6F, 0xDE, 0x51, 0x9A, 0xD9, 0xDA, 0xA0, 0xE5, 0xBE };
-               Assert ("Capi-1536-Verify", rsa.VerifyHash (hash, sha1OID, sign1536));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign1536), "Capi-1536-Verify");
                sign1536[0] = 0x00;
-               Assert ("Capi-1536-VerBad", !rsa.VerifyHash (hash, sha1OID, sign1536));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign1536), "Capi-1536-VerBad");
 
                rsa.FromXmlString (CapiXml2048);
                byte[] sign2048 = { 0x62, 0xB8, 0xE3, 0xD0, 0x8B, 0x8E, 0x00, 0xFA, 0x59, 0x17, 0xC7, 0x0C, 0x81, 0x76, 0x3A, 0x35, 0xAA, 0xC7, 0xE4, 0xFA, 0x7C, 0x96, 0x9C, 0x88, 0x15, 0x88, 0xA5, 0xA6, 0x7C, 0x95, 0x55, 0xC5, 0xDD, 0xA5, 0x83, 0x25, 0x33, 0xFF, 0xEE, 0x9E, 0xDD, 0xF1, 0xF1, 0x85, 0xB3, 0xEE, 0x78, 0x11, 0xC7, 0x83, 0xA6, 0xD8, 0xB4, 0x34, 0xC4, 0x73, 0x2A, 0xE5, 0xC9, 0x2A, 0x5F, 0x5C, 0xF5, 0xAB, 0xB0, 0xB6, 0xAD, 0x52, 0xB3, 0xBA, 0x31, 0x0E, 0x5A, 0x09, 0xB1, 0x74, 0x90, 0xCC, 0xC7, 0x7C, 0x58, 0x2D, 0x49, 0x9F, 0xDC, 0x6F, 0x03, 0x58, 0xB0, 0x1D, 0xFA, 0x7F, 0xE5, 0x8E, 0x09, 0xAC, 0x17, 0xCF, 0xD8, 0x0F, 0xE0, 0x1F, 0x1B, 0xDD, 0x72, 0xA5, 0xCA, 0x5E, 0x51, 0x2F, 0x52, 0xD9, 0x66, 0xE9, 0xA5, 0x78, 0xCE, 0xE4, 0x73, 0x63, 0xCA, 0xE5, 0x58, 0x30, 0xE9, 0xB9, 0x57, 0x07, 0x56, 0x77, 0x67, 0xFC, 0xBC, 0xE2, 0xF6, 0xAF, 0xD6, 0x5D, 0x02, 0xBB, 0x14, 0x47, 0xD2, 0xDF, 0x12, 0xC8, 0x42, 0xF0, 0xA5, 0x42, 0x3B, 0x90, 0xB3, 0xC8, 0x9D, 0xD7, 0xB6, 0x89, 0x25, 0xDA, 0x7D, 0xC2, 0x53, 0x94, 0x1D, 0x20, 0x8E, 0x2C, 0x96, 0x32, 0x43, 0x4C, 0xE1, 0x20, 0x64, 0xEC, 0x15, 0xC5, 0x44, 0xEE, 0xCB, 0xEC, 0x89, 0xBF, 0x84, 0x1E, 0x93, 0x2B, 0x87, 0xEC, 0xE4, 0x97, 0x66, 0xF8, 0xD7, 0xD5, 0x4B, 0xFF, 0x9D, 0x4B, 0x5E, 0x73, 0xFA, 0x11, 0x50, 0xD5, 0xA0, 0xF3, 0x7C, 0x3D, 0xD8, 0x7B, 0x12, 0x04, 0xE8, 0xB7, 0x27, 0x5A, 0x11, 0xF0, 0x65, 0x33, 0x13, 0xC6, 0xDC, 0xC1, 0xFB, 0xD1, 0x7A, 0x93, 0xCF, 0x1B, 0xFB, 0x12, 0x72, 0xF6, 0xD9, 0x6F, 0x38, 0x0B, 0xFE, 0xBE, 0x4D, 0xE0, 0xF8, 0xEB, 0x21, 0xAE, 0x5D, 0xD2, 0x7C, 0x81, 0x74, 0x0A, 0x47, 0x1E };
-               Assert ("Capi-2048-Verify", rsa.VerifyHash (hash, sha1OID, sign2048));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign2048), "Capi-2048-Verify");
                sign2048[0] = 0x00;
-               Assert ("Capi-2048-VerBad", !rsa.VerifyHash (hash, sha1OID, sign2048));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign2048), "Capi-2048-VerBad");
        }
 
        // all keypairs generated by Mono on Windows
@@ -763,43 +763,43 @@ public class RSACryptoServiceProviderTest : Assertion {
                rsa = new RSACryptoServiceProvider ();
 
                rsa.FromXmlString (MonoXml384);
-               AssertEquals ("Mono-Xml384", MonoXml384, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml384, rsa.ToXmlString (true), "Mono-Xml384");
 
                rsa.FromXmlString (MonoXml448);
-               AssertEquals ("Mono-Xml448", MonoXml448, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml448, rsa.ToXmlString (true), "Mono-Xml448");
 
                rsa.FromXmlString (MonoXml512);
-               AssertEquals ("Mono-Xml512", MonoXml512, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml512, rsa.ToXmlString (true), "Mono-Xml512");
 
                rsa.FromXmlString (MonoXml576);
-               AssertEquals ("Mono-Xml576", MonoXml576, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml576, rsa.ToXmlString (true), "Mono-Xml576");
 
                rsa.FromXmlString (MonoXml640);
-               AssertEquals ("Mono-Xml640", MonoXml640, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml640, rsa.ToXmlString (true), "Mono-Xml640");
 
                rsa.FromXmlString (MonoXml704);
-               AssertEquals ("Mono-Xml704", MonoXml704, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml704, rsa.ToXmlString (true), "Mono-Xml704");
 
                rsa.FromXmlString (MonoXml768);
-               AssertEquals ("Mono-Xml768", MonoXml768, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml768, rsa.ToXmlString (true), "Mono-Xml768");
 
                rsa.FromXmlString (MonoXml832);
-               AssertEquals ("Mono-Xml832", MonoXml832, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml832, rsa.ToXmlString (true), "Mono-Xml832");
 
                rsa.FromXmlString (MonoXml896);
-               AssertEquals ("Mono-Xml896", MonoXml896, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml896, rsa.ToXmlString (true), "Mono-Xml896");
 
                rsa.FromXmlString (MonoXml960);
-               AssertEquals ("Mono-Xml960", MonoXml960, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml960, rsa.ToXmlString (true), "Mono-Xml960");
 
                rsa.FromXmlString (MonoXml1024);
-               AssertEquals ("Mono-Xml1024", MonoXml1024, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml1024, rsa.ToXmlString (true), "Mono-Xml1024");
 
                rsa.FromXmlString (MonoXml1536);
-               AssertEquals ("Mono-Xml1536", MonoXml1536, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml1536, rsa.ToXmlString (true), "Mono-Xml1536");
 
                rsa.FromXmlString (MonoXml2048);
-               AssertEquals ("Mono-Xml2048", MonoXml2048, rsa.ToXmlString (true));
+               Assert.AreEqual (MonoXml2048, rsa.ToXmlString (true), "Mono-Xml2048");
        }
 
        [Test]
@@ -896,81 +896,81 @@ public class RSACryptoServiceProviderTest : Assertion {
 
                rsa.FromXmlString (MonoXml384);
                byte[] sign384 = { 0x6B, 0xEF, 0x8A, 0x2E, 0x2E, 0xD5, 0xB6, 0x19, 0x2D, 0x9C, 0x48, 0x75, 0xA8, 0x54, 0xAD, 0x61, 0xD1, 0xCC, 0xF3, 0x9A, 0x3E, 0x4E, 0xE2, 0xF1, 0x44, 0x1D, 0xC4, 0x3A, 0x30, 0xF4, 0x9B, 0x2D, 0x88, 0xA7, 0xB8, 0xEC, 0x2D, 0x17, 0x4E, 0x66, 0x6C, 0x4C, 0x5A, 0xB5, 0x44, 0x4B, 0xAF, 0x06 };
-               Assert ("Mono-384-Verify", rsa.VerifyHash (hash, sha1OID, sign384));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign384), "Mono-384-Verify");
                sign384[0] = 0x00;
-               Assert ("Mono-384-VerBad", !rsa.VerifyHash (hash, sha1OID, sign384));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign384), "Mono-384-VerBad");
 
                rsa.FromXmlString (MonoXml448);
                byte[] sign448 = { 0x9F, 0x62, 0xDF, 0xD4, 0x8B, 0x3E, 0x85, 0xEC, 0xF9, 0xF2, 0x17, 0x1C, 0x2B, 0x18, 0x37, 0xDA, 0xCA, 0x74, 0x5F, 0x85, 0x70, 0x41, 0x44, 0xB3, 0xE5, 0xA3, 0xC8, 0xC7, 0x37, 0x9E, 0x52, 0x16, 0x18, 0x2C, 0xE3, 0x87, 0x1A, 0x34, 0x13, 0x4A, 0x5D, 0xBB, 0x79, 0x27, 0x1C, 0x2A, 0xD2, 0x96, 0x79, 0xC4, 0x26, 0x51, 0x1B, 0x24, 0x12, 0xBC };
-               Assert ("Mono-448-Verify", rsa.VerifyHash (hash, sha1OID, sign448));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign448), "Mono-448-Verify");
                sign448[0] = 0x00;
-               Assert ("Mono-448-VerBad", !rsa.VerifyHash (hash, sha1OID, sign448));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign448), "Mono-448-VerBad");
 
                rsa.FromXmlString (MonoXml512);
                byte[] sign512 = { 0x33, 0xBB, 0x7E, 0x0B, 0xC0, 0xB2, 0x9A, 0xC2, 0x2F, 0xF4, 0xBE, 0x1B, 0xDF, 0xD6, 0x79, 0xC1, 0x38, 0x47, 0xEA, 0x05, 0xB2, 0xC0, 0xFA, 0xF8, 0xC9, 0xDC, 0x6D, 0x56, 0xBF, 0xD3, 0xBF, 0xAA, 0xB8, 0x1E, 0x74, 0xE4, 0xF3, 0x38, 0x45, 0xA9, 0x34, 0xD1, 0x5C, 0x0D, 0x0F, 0x56, 0x70, 0x0C, 0x93, 0x6B, 0xD6, 0x80, 0x17, 0xAD, 0x80, 0xF9, 0xD8, 0xFD, 0x1E, 0x6F, 0xF3, 0x5C, 0xB2, 0x78 };
-               Assert ("Mono-512-Verify", rsa.VerifyHash (hash, sha1OID, sign512));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign512), "Mono-512-Verify");
                sign512[0] = 0x00;
-               Assert ("Mono-512-VerBad", !rsa.VerifyHash (hash, sha1OID, sign512));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign512), "Mono-512-VerBad");
 
                rsa.FromXmlString (MonoXml576);
                byte[] sign576 = { 0x61, 0x8C, 0xD0, 0xE3, 0x63, 0x95, 0x7C, 0xB6, 0xD8, 0x84, 0x4D, 0xD1, 0x04, 0xDF, 0x1F, 0x4A, 0xCF, 0x69, 0x95, 0x7B, 0x69, 0x8E, 0x09, 0x2A, 0x0F, 0x1B, 0x23, 0xA7, 0x20, 0x31, 0x95, 0x93, 0xD1, 0x67, 0xBC, 0x27, 0x80, 0x41, 0x60, 0xD1, 0xFE, 0x62, 0xB2, 0x17, 0xC9, 0x57, 0x4F, 0x03, 0x40, 0xDB, 0xB3, 0x7E, 0xD2, 0x0C, 0xEA, 0x7D, 0x72, 0x76, 0x64, 0x4F, 0x51, 0x79, 0x43, 0xCC, 0x8F, 0x36, 0x1E, 0x81, 0x43, 0x20, 0xB9, 0xAD };
-               Assert ("Mono-576-Verify", rsa.VerifyHash (hash, sha1OID, sign576));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign576), "Mono-576-Verify");
                sign576[0] = 0x00;
-               Assert ("Mono-576-VerBad", !rsa.VerifyHash (hash, sha1OID, sign576));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign576), "Mono-576-VerBad");
 
                rsa.FromXmlString (MonoXml640);
                byte[] sign640 = { 0x4A, 0x6A, 0xED, 0xEC, 0x96, 0x9C, 0x89, 0xD1, 0x41, 0x2E, 0x16, 0x0D, 0xBA, 0xB0, 0x48, 0x92, 0xF9, 0xA6, 0x33, 0x26, 0x0D, 0x6C, 0x99, 0xA9, 0x4E, 0x3B, 0x68, 0x82, 0xAB, 0x94, 0x33, 0x89, 0xEC, 0x8A, 0xCC, 0x32, 0xDD, 0x45, 0x9C, 0x16, 0x5E, 0xCE, 0x5F, 0xF3, 0xDC, 0x5F, 0x09, 0xC7, 0x69, 0xC7, 0xEA, 0x74, 0xAB, 0x79, 0xA7, 0x55, 0xD9, 0xF8, 0xDF, 0x8F, 0x8C, 0x9A, 0xBA, 0xA9, 0x56, 0x86, 0x96, 0x64, 0xE9, 0xC0, 0x21, 0x8C, 0x34, 0x91, 0x31, 0xC2, 0x80, 0xC7, 0x47, 0x6F };
-               Assert ("Mono-640-Verify", rsa.VerifyHash (hash, sha1OID, sign640));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign640), "Mono-640-Verify");
                sign640[0] = 0x00;
-               Assert ("Mono-640-VerBad", !rsa.VerifyHash (hash, sha1OID, sign640));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign640), "Mono-640-VerBad");
 
                rsa.FromXmlString (MonoXml704);
                byte[] sign704 = { 0x94, 0xC5, 0x45, 0xCD, 0x9C, 0xA9, 0xBC, 0xDF, 0x9D, 0x04, 0xCE, 0xFD, 0x21, 0xEB, 0x3F, 0xBE, 0x32, 0x56, 0xC3, 0x6B, 0xEF, 0x4E, 0x8F, 0xA9, 0x02, 0x14, 0xC4, 0xF1, 0xFA, 0x9B, 0x35, 0xFE, 0x36, 0x34, 0x03, 0x31, 0xC1, 0xC8, 0xBF, 0xA1, 0x41, 0x03, 0xCB, 0xE1, 0xB9, 0x81, 0x76, 0x60, 0xC9, 0xD1, 0xB4, 0x04, 0x98, 0xA5, 0xDF, 0x4F, 0x37, 0x60, 0xB8, 0x15, 0xF8, 0x22, 0xB7, 0x54, 0x32, 0x87, 0x19, 0x9B, 0xB9, 0xDF, 0xB9, 0x2D, 0x25, 0xA2, 0xAF, 0x04, 0xC1, 0xE0, 0xF0, 0x0B, 0xF2, 0xCC, 0x0E, 0x1F, 0x40, 0xF6, 0x5C, 0xCD };
-               Assert ("Mono-704-Verify", rsa.VerifyHash (hash, sha1OID, sign704));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign704), "Mono-704-Verify");
                sign704[0] = 0x00;
-               Assert ("Mono-704-VerBad", !rsa.VerifyHash (hash, sha1OID, sign704));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign704), "Mono-704-VerBad");
 
                rsa.FromXmlString (MonoXml768);
                byte[] sign768 = { 0x28, 0x99, 0xE0, 0xD2, 0xCF, 0xD3, 0x2B, 0x1B, 0xA2, 0x06, 0xC5, 0x17, 0x86, 0x07, 0xC8, 0x49, 0x77, 0x33, 0xEC, 0xFE, 0xC9, 0x15, 0x99, 0x90, 0x4C, 0x6C, 0xED, 0x2C, 0x32, 0xF8, 0xAB, 0x0A, 0xB6, 0xEB, 0x15, 0x08, 0x4A, 0xC1, 0xDD, 0xAD, 0x88, 0x47, 0xAD, 0x3D, 0xA2, 0x4B, 0x94, 0x7E, 0x37, 0x1F, 0x33, 0xFC, 0xC3, 0xFE, 0xC2, 0x27, 0x45, 0x74, 0x8E, 0x3C, 0xC8, 0x68, 0x8C, 0xF4, 0x77, 0xCC, 0xD0, 0x79, 0x37, 0x7E, 0x26, 0x1B, 0xDE, 0xBF, 0x16, 0x3E, 0xAE, 0xB9, 0xEB, 0xA0, 0x00, 0xCE, 0x51, 0x8A, 0x69, 0x12, 0xF5, 0xBE, 0x39, 0x1C, 0x0F, 0x0F, 0xD8, 0x13, 0xDD, 0x6B };
-               Assert ("Mono-768-Verify", rsa.VerifyHash (hash, sha1OID, sign768));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign768), "Mono-768-Verify");
                sign768[0] = 0x00;
-               Assert ("Mono-768-VerBad", !rsa.VerifyHash (hash, sha1OID, sign768));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign768), "Mono-768-VerBad");
 
                rsa.FromXmlString (MonoXml832);
                byte[] sign832 = { 0x8D, 0x56, 0xB2, 0x3C, 0x45, 0x47, 0xB8, 0x6F, 0x56, 0x7D, 0x85, 0x4F, 0x3C, 0x14, 0xAC, 0x61, 0x08, 0x8C, 0x6A, 0xF3, 0xAF, 0xCA, 0x65, 0xCC, 0xC3, 0x6F, 0x53, 0x6F, 0x84, 0xC1, 0x9F, 0xFD, 0x66, 0x83, 0xA1, 0x3B, 0xFF, 0x61, 0x41, 0xDB, 0x2C, 0xE5, 0xD5, 0x13, 0x3E, 0x15, 0x7A, 0xBD, 0x1F, 0x44, 0x4C, 0x4F, 0x10, 0xB7, 0x4A, 0x4B, 0x9D, 0xD1, 0xF5, 0xC2, 0x4E, 0x4D, 0xC8, 0xF9, 0x51, 0xC9, 0xF3, 0x04, 0x69, 0x02, 0xAE, 0x7E, 0xC3, 0x76, 0x56, 0x08, 0x8E, 0xF7, 0xA1, 0x25, 0x1B, 0x97, 0x65, 0x8E, 0x3A, 0x98, 0x52, 0xDB, 0x3E, 0xF4, 0x59, 0x5F, 0xEE, 0x6D, 0x78, 0x22, 0x37, 0x2E, 0x79, 0x69, 0x6D, 0x8F, 0xF9, 0xDF };
-               Assert ("Mono-832-Verify", rsa.VerifyHash (hash, sha1OID, sign832));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign832), "Mono-832-Verify");
                sign832[0] = 0x00;
-               Assert ("Mono-832-VerBad", !rsa.VerifyHash (hash, sha1OID, sign832));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign832), "Mono-832-VerBad");
 
                rsa.FromXmlString (MonoXml896);
                byte[] sign896 = { 0xAB, 0xD9, 0xE4, 0x5C, 0xAB, 0xF7, 0xE1, 0x06, 0x7F, 0x0C, 0xD6, 0x03, 0xB5, 0xA1, 0xDB, 0x22, 0x3E, 0x85, 0xBE, 0xCD, 0x54, 0x12, 0xD5, 0x11, 0x71, 0xCC, 0xEE, 0x71, 0x4B, 0xA8, 0xB5, 0xAE, 0x04, 0x82, 0x78, 0x72, 0xE8, 0x7B, 0x77, 0x42, 0x58, 0x14, 0xA3, 0xF0, 0xFC, 0xE9, 0x15, 0x98, 0x2E, 0x34, 0x57, 0xAA, 0x95, 0x6F, 0x2E, 0x9B, 0x5B, 0x88, 0xF0, 0x51, 0x26, 0x35, 0x1F, 0x0C, 0x59, 0x51, 0x73, 0x0E, 0xD3, 0x5D, 0x02, 0xAD, 0xB7, 0x1C, 0x94, 0x57, 0x1E, 0xA6, 0x01, 0x19, 0x73, 0x29, 0xBE, 0xDF, 0x77, 0xF2, 0x13, 0x28, 0xBD, 0x50, 0x89, 0x39, 0x6A, 0x1B, 0xEF, 0x66, 0x29, 0x71, 0x55, 0x44, 0x3A, 0x36, 0x89, 0xC1, 0xFE, 0x25, 0x32, 0x9F, 0x65, 0x76, 0xEA, 0x71 };
-               Assert ("Mono-896-Verify", rsa.VerifyHash (hash, sha1OID, sign896));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign896), "Mono-896-Verify");
                sign896[0] = 0x00;
-               Assert ("Mono-896-VerBad", !rsa.VerifyHash (hash, sha1OID, sign896));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign896), "Mono-896-VerBad");
 
                rsa.FromXmlString (MonoXml960);
                byte[] sign960 = { 0x7A, 0x13, 0x06, 0xF1, 0xB5, 0x14, 0x78, 0x33, 0xA6, 0x14, 0x40, 0xDC, 0x22, 0xB6, 0xF3, 0xBB, 0xDC, 0xCD, 0x53, 0xAF, 0x05, 0xC5, 0x84, 0x0C, 0xD2, 0x15, 0x5A, 0x04, 0xFC, 0x30, 0x57, 0x64, 0xF4, 0x8B, 0xD6, 0x5D, 0x5B, 0x3D, 0xFC, 0x82, 0x6B, 0xB9, 0xE4, 0xB9, 0x56, 0xB3, 0xCF, 0x2A, 0x6D, 0x14, 0x83, 0x31, 0x9E, 0xFD, 0x55, 0x4B, 0x2C, 0xBD, 0x5A, 0xA8, 0xAC, 0xD6, 0x5D, 0xFA, 0x58, 0xF8, 0x3E, 0x60, 0x32, 0x11, 0xA4, 0x09, 0xC2, 0x01, 0xE7, 0x14, 0xEF, 0xBA, 0x51, 0x57, 0x86, 0xA5, 0x86, 0x28, 0x63, 0x68, 0x33, 0xBF, 0x34, 0xF9, 0x1D, 0x36, 0xC3, 0x6E, 0xCF, 0x97, 0xA5, 0x19, 0xB4, 0x5F, 0x7B, 0x70, 0xB0, 0x72, 0xF2, 0xF2, 0xFF, 0x05, 0xB7, 0x31, 0x5A, 0x5D, 0xC6, 0x88, 0x88, 0x21, 0x97, 0x40, 0x0E, 0x0E };
-               Assert ("Mono-960-Verify", rsa.VerifyHash (hash, sha1OID, sign960));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign960), "Mono-960-Verify");
                sign960[0] = 0x00;
-               Assert ("Mono-960-VerBad", !rsa.VerifyHash (hash, sha1OID, sign960));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign960), "Mono-960-VerBad");
 
                rsa.FromXmlString (MonoXml1024);
                byte[] sign1024 = { 0x26, 0x98, 0x40, 0x5F, 0x30, 0x4E, 0x90, 0x20, 0x32, 0x10, 0x64, 0xCF, 0x03, 0xA8, 0x1E, 0x53, 0x20, 0x19, 0x59, 0xCB, 0x08, 0x5F, 0x8D, 0x45, 0x51, 0xEE, 0xDD, 0x71, 0x2E, 0x21, 0x86, 0xB0, 0xC6, 0xE2, 0x6F, 0x2A, 0xF2, 0x8E, 0xBD, 0xDE, 0xAD, 0xA0, 0x56, 0x7E, 0xED, 0x38, 0x4F, 0x8D, 0x3A, 0xC6, 0x8A, 0x15, 0x34, 0x71, 0xDE, 0xC5, 0x60, 0x32, 0x95, 0x38, 0xD7, 0x69, 0x0F, 0x3B, 0xDF, 0xF8, 0x4C, 0x2D, 0x83, 0x58, 0x7E, 0x36, 0x4B, 0x10, 0x4A, 0x8B, 0x23, 0x70, 0x09, 0xBE, 0xCF, 0x02, 0x2E, 0x97, 0xC4, 0x0F, 0x94, 0x42, 0x0B, 0xFA, 0x1F, 0x16, 0x97, 0x25, 0x1C, 0x14, 0x2B, 0x82, 0xD0, 0x7A, 0xC1, 0x2C, 0x2F, 0x72, 0x9C, 0xD9, 0xEE, 0x90, 0x2F, 0x5B, 0xC5, 0xB1, 0x34, 0x73, 0x10, 0xEC, 0x79, 0x97, 0x9A, 0xDA, 0xE2, 0xB4, 0xAE, 0x99, 0xE9, 0xA2, 0xFF, 0xC6 };
-               Assert ("Mono-1024-Verify", rsa.VerifyHash (hash, sha1OID, sign1024));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign1024), "Mono-1024-Verify");
                sign1024[0] = 0x00;
-               Assert ("Mono-1024-VerBad", !rsa.VerifyHash (hash, sha1OID, sign1024));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign1024), "Mono-1024-VerBad");
 
                rsa.FromXmlString (MonoXml1536);
                byte[] sign1536 = { 0x33, 0xE2, 0xA4, 0xCE, 0x18, 0xE6, 0xF3, 0x46, 0x0E, 0x32, 0xD1, 0xA6, 0x8A, 0xC3, 0xCA, 0x4B, 0x36, 0x4E, 0x4C, 0xAE, 0x39, 0x95, 0x5A, 0x05, 0x37, 0xBA, 0x0F, 0x19, 0xDC, 0x94, 0x6A, 0x78, 0xDA, 0xEA, 0xF0, 0xA2, 0x80, 0x47, 0xD5, 0xB9, 0xC3, 0x53, 0xC9, 0xDA, 0x0B, 0x29, 0xCA, 0x61, 0x37, 0x7C, 0xD5, 0x5D, 0x99, 0x58, 0xAD, 0x0F, 0xA8, 0xEF, 0x17, 0xFD, 0xA8, 0x55, 0x79, 0xEF, 0x07, 0xD1, 0x63, 0xE0, 0x2C, 0xEF, 0x14, 0x42, 0x72, 0x2D, 0x71, 0xA3, 0xBB, 0x29, 0x87, 0xF8, 0xCC, 0xFB, 0x70, 0xCC, 0x13, 0x70, 0x24, 0xC3, 0x2A, 0x2B, 0xD2, 0x1C, 0x34, 0xD7, 0x85, 0xBC, 0xA4, 0x4E, 0x7B, 0x7E, 0x1C, 0x5B, 0x03, 0x06, 0xB2, 0x01, 0xBF, 0x73, 0x30, 0x77, 0xEB, 0x03, 0x17, 0x24, 0xFE, 0x46, 0xC7, 0x9B, 0xEB, 0x75, 0xF6, 0x56, 0x43, 0x1E, 0x0D, 0x56, 0x05, 0x37, 0x78, 0xB3, 0x76, 0x93, 0x76, 0xFA, 0x73, 0xCD, 0xE5, 0xB1, 0x3C, 0x60, 0xB7, 0xCC, 0x1E, 0x98, 0x89, 0xD8, 0xB4, 0x0A, 0xD3, 0x52, 0xCD, 0xEF, 0xC1, 0xBE, 0xFC, 0xA8, 0x2C, 0xE6, 0x01, 0xD3, 0xB3, 0x05, 0x5C, 0x12, 0x48, 0xD8, 0x20, 0xF9, 0x3B, 0xAD, 0x97, 0xD4, 0xD1, 0x13, 0xD6, 0xA5, 0x31, 0x4E, 0x52, 0x13, 0xBD, 0x5C, 0x00, 0x5C, 0x2A, 0x86, 0xFC, 0x98, 0x8B, 0x93, 0xAE, 0x5A };
-               Assert ("Mono-1536-Verify", rsa.VerifyHash (hash, sha1OID, sign1536));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign1536), "Mono-1536-Verify");
                sign1536[0] = 0x00;
-               Assert ("Mono-1536-VerBad", !rsa.VerifyHash (hash, sha1OID, sign1536));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign1536), "Mono-1536-VerBad");
 
                rsa.FromXmlString (MonoXml2048);
                byte[] sign2048 = { 0xA5, 0x70, 0x6B, 0x3C, 0x5E, 0x5D, 0x49, 0x7C, 0xCB, 0xEE, 0xE3, 0x23, 0xF5, 0xD7, 0xEE, 0xF3, 0xA8, 0x8A, 0xED, 0x47, 0x5F, 0x2A, 0x03, 0x72, 0x41, 0x02, 0x1E, 0x5D, 0x93, 0x3B, 0x27, 0x4B, 0x2D, 0x7A, 0x21, 0x50, 0x7B, 0xDC, 0xFB, 0x0F, 0xCB, 0xEB, 0x8E, 0xB5, 0x4C, 0x44, 0x90, 0x39, 0xF0, 0xCB, 0x4A, 0x5E, 0xD7, 0x67, 0x5C, 0x46, 0xC3, 0x3C, 0x94, 0xDC, 0x33, 0x36, 0x36, 0xA5, 0xF3, 0xCE, 0x1F, 0xA7, 0x8F, 0x79, 0xB8, 0x60, 0x94, 0x0F, 0x7A, 0x87, 0x18, 0x12, 0xCD, 0x21, 0x54, 0x05, 0x53, 0xA0, 0x88, 0x1F, 0x61, 0x1F, 0xAB, 0xEC, 0x6D, 0xCF, 0x10, 0xE0, 0x8D, 0x14, 0x5C, 0x6A, 0x46, 0x8C, 0xB9, 0xB6, 0x52, 0x38, 0x1F, 0xAE, 0xF1, 0xB8, 0xB5, 0x9B, 0x3C, 0xE1, 0x6E, 0xBE, 0x21, 0x1B, 0x01, 0x1E, 0xD9, 0x1E, 0x97, 0x78, 0x47, 0xC9, 0x86, 0xC4, 0xE7, 0x58, 0xF8, 0xEB, 0xAC, 0x22, 0x38, 0xD4, 0x2A, 0xE8, 0x1B, 0x40, 0x5F, 0xAF, 0x35, 0xFA, 0x13, 0x30, 0x0E, 0x5C, 0x4C, 0xF5, 0xF1, 0xB3, 0x31, 0x6C, 0x1D, 0x96, 0xFD, 0xAB, 0xC4, 0x0E, 0x16, 0x0A, 0xF9, 0x28, 0x49, 0x59, 0xF1, 0xB6, 0x35, 0x2D, 0x21, 0x69, 0x4F, 0xD0, 0x5B, 0xB7, 0x7E, 0xC3, 0x00, 0xC7, 0xDA, 0x56, 0x48, 0xA0, 0x93, 0x05, 0xB4, 0x6D, 0xEE, 0x2D, 0x6A, 0x60, 0xF6, 0x91, 0x7C, 0xDB, 0xD8, 0xC3, 0xFD, 0x33, 0xBC, 0xC9, 0x68, 0x73, 0xC6, 0x64, 0x49, 0x80, 0x3C, 0xD5, 0x4A, 0xE1, 0x28, 0x5F, 0xE9, 0x2A, 0xA7, 0x1B, 0xA6, 0x38, 0x2A, 0xAE, 0x0A, 0xA8, 0xCC, 0x96, 0x9A, 0xEA, 0xE5, 0xAD, 0xB4, 0xD8, 0x70, 0x2F, 0xFA, 0xAD, 0x17, 0x03, 0x4D, 0xDA, 0x2E, 0x1B, 0x4D, 0x88, 0x82, 0x3E, 0x04, 0x6A, 0xAF, 0x38, 0xC1, 0x4F, 0x1B, 0x9D, 0x07, 0x1A, 0x67, 0x6A };
-               Assert ("Mono-2048-Verify", rsa.VerifyHash (hash, sha1OID, sign2048));
+               Assert.IsTrue (rsa.VerifyHash (hash, sha1OID, sign2048), "Mono-2048-Verify");
                sign2048[0] = 0x00;
-               Assert ("Mono-2048-VerBad", !rsa.VerifyHash (hash, sha1OID, sign2048));
+               Assert.IsFalse (rsa.VerifyHash (hash, sha1OID, sign2048), "Mono-2048-VerBad");
        }
 
        // Key Pair Persistence Tests
@@ -992,17 +992,17 @@ public class RSACryptoServiceProviderTest : Assertion {
                string first = rsa1.ToXmlString (true);
 
                // persistance is "on" by default when a CspParameters is supplied
-               Assert ("PersistKeyInCsp", rsa1.PersistKeyInCsp);
+               Assert.IsTrue (rsa1.PersistKeyInCsp, "PersistKeyInCsp");
 
                // this means nothing if we don't call Clear !!!
                rsa1.PersistKeyInCsp = false;
-               Assert ("PersistKeyInCsp", !rsa1.PersistKeyInCsp);
+               Assert.IsFalse (rsa1.PersistKeyInCsp, "PersistKeyInCsp");
 
                // reload using the same container name
                RSACryptoServiceProvider rsa2 = new RSACryptoServiceProvider (minKeySize, csp);
                string second = rsa2.ToXmlString (true);
 
-               AssertEquals ("Key Pair Same Container", first, second);
+               Assert.AreEqual (first, second, "Key Pair Same Container");
        }
 
        [Test]
@@ -1017,13 +1017,13 @@ public class RSACryptoServiceProviderTest : Assertion {
                string first = rsa1.ToXmlString (true);
 
                // persistance is "on" by default
-               Assert ("PersistKeyInCsp", rsa1.PersistKeyInCsp);
+               Assert.IsTrue (rsa1.PersistKeyInCsp, "PersistKeyInCsp");
 
                // reload using the same container name
                RSACryptoServiceProvider rsa2 = new RSACryptoServiceProvider (minKeySize, csp);
                string second = rsa2.ToXmlString (true);
 
-               AssertEquals ("Key Pair Same Container", first, second);
+               Assert.AreEqual (first, second, "Key Pair Same Container");
        }
 
        [Test]
@@ -1046,14 +1046,14 @@ public class RSACryptoServiceProviderTest : Assertion {
                RSACryptoServiceProvider rsa2 = new RSACryptoServiceProvider (minKeySize, csp);
                string newKeyPair = rsa2.ToXmlString (true);
 
-               Assert ("Key Pair Deleted", (original != newKeyPair));
+               Assert.IsTrue ((original != newKeyPair), "Key Pair Deleted");
        }
 
 #if NET_1_1
        [Test]
        public void UseMachineKeyStore_Default ()
        {
-               Assert ("UseMachineKeyStore(Default)", !RSACryptoServiceProvider.UseMachineKeyStore);
+               Assert.IsFalse (RSACryptoServiceProvider.UseMachineKeyStore, "UseMachineKeyStore(Default)");
        }
 
        [Test]
@@ -1075,7 +1075,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                        csp.Flags |= CspProviderFlags.UseMachineKeyStore;
                        rsa = new RSACryptoServiceProvider (csp);
 
-                       Assert ("UseMachineKeyStore", machineKeyPair != rsa.ToXmlString (true));
+                       Assert.IsTrue (machineKeyPair != rsa.ToXmlString (true), "UseMachineKeyStore");
                }
                catch (CryptographicException ce) {
                        // only root can create the required directory (if inexistant)
@@ -1095,7 +1095,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                rsa = new RSACryptoServiceProvider (minKeySize);
                byte[] encdata = rsa.Encrypt (data, false);
                byte[] decdata = rsa.Decrypt (encdata, false);
-               AssertEquals ("PKCS1", BitConverter.ToString (data), BitConverter.ToString (decdata));
+               Assert.AreEqual (BitConverter.ToString (data), BitConverter.ToString (decdata), "PKCS1");
        }
 
        [Test]
@@ -1106,7 +1106,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                try {
                        byte[] encdata = rsa.Encrypt (data, true);
                        byte[] decdata = rsa.Decrypt (encdata, true);
-                       AssertEquals ("PKCS1", BitConverter.ToString (data), BitConverter.ToString (decdata));
+                       Assert.AreEqual (BitConverter.ToString (data), BitConverter.ToString (decdata), "PKCS1");
                }
                catch (CryptographicException) {
                        // will fail on MS runtime before Windows XP
@@ -1120,7 +1120,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                rsa = new RSACryptoServiceProvider ();
                rsa.FromXmlString ("<RSAKeyValue><Modulus>iSObDmmhDgrl4NiLaviFcpv4NdysBWJcqiVz3AQbPdajtXaQQ8VJdfRkixah132yKOFGCWZhHS3EuPMh8dcNwGwta2nh+m2IV6ktzI4+mZ7CSNAsmlDY0JI+H8At1vKvNArlC5jkVGuliYroJeSU/NLPLNYgspi7TtXGy9Rfug8=</Modulus><Exponent>EQ==</Exponent></RSAKeyValue>");
 #if NET_2_0
-               Assert ("PublicOnly", rsa.PublicOnly);
+               Assert.IsTrue (rsa.PublicOnly, "PublicOnly");
 #endif
                string b64 = @"YgyAhscnTTIcDeLJTZcOYYyHVxNhV6d03jeZYjq0sPMEsfCCbE/NcFyYHD9BTuiduqPplCLbGpfZIZYJ6vAP9m5z4Q9eEw79kmEFCsm8wSKEo/gKiptVpwQ78VOPrWd/wEkTTeeg2nVim3JIsTKGFlV7rKxIWQhGN9aAqgP8nZI=";
                byte [] bytes = Convert.FromBase64String (b64);
@@ -1135,7 +1135,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                byte [] bytes = Convert.FromBase64String (s);
                RSACryptoServiceProvider r = new RSACryptoServiceProvider ();
                r.FromXmlString ("<RSAKeyValue><Modulus>iSObDmmhDgrl4NiLaviFcpv4NdysBWJcqiVz3AQbPdajtXaQQ8VJdfRkixah132yKOFGCWZhHS3EuPMh8dcNwGwta2nh+m2IV6ktzI4+mZ7CSNAsmlDY0JI+H8At1vKvNArlC5jkVGuliYroJeSU/NLPLNYgspi7TtXGy9Rfug8=</Modulus><Exponent>EQ==</Exponent><P>pd4svtxrnTWXVSb151/JFgT9szI6dxQ5pAFPd4A4yuxLLEay2W2z7d9LVk5siMFhZ10uTJGWzNP5pSgLT8wdww==</P><Q>06j6m4cGRc3uoKVuFFGA19JG3Bi4tDBEQHebEc/Y3+eThrOasYIRrQmGUfqWnd9eFitO9GOaVJ0muNDV7NOxxQ==</Q><DP>OoqmYXr4zhLqHg3AM4s36adomZlBz6zJDLUrGx4yKYCTAJFsTL1OkDCxLYUXP1NPjeSm7dkIDA6UWGh8doRGvQ==</DP><DQ>PkDCLb5NI5br1OVcnJBxMGsFyEOBnmiMi2545x8DjSX+Nq1LnZ6555ljvcIsTIz9jgy83nel3KaxCS5dCWtwhQ==</DQ><InverseQ>OrFYaG7wTqim/bub4qY0CvIfhsjG4/4MEabg0UFTf/+tekKas7DDKg2TD5BS2q0O3XEt7xIfp0S6dpOAnrlyGQ==</InverseQ><D>IESc9FUW1iCuj0ICr8IBSCSy3383iMvZkXI5YPHoSskXdf3Hl3m27pPbbAVTQcM4+o9bxfn4u5JMZ8C8sV/G/8Cfl4ss1NVMbZOecvVObRqRpqXaveq5fN2X0EklH1wzm5w3O8cMXdbC/hc0gKUqaMjFVn1zpf3zVjpOkY0eGRE=</D></RSAKeyValue>");
-               AssertNotNull (r.Decrypt (bytes, true));
+               Assert.IsNotNull (r.Decrypt (bytes, true));
        }
 
        [Test]
@@ -1146,7 +1146,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                byte [] bytes = Convert.FromBase64String (s);
                RSACryptoServiceProvider r = new RSACryptoServiceProvider ();
                r.FromXmlString ("<RSAKeyValue><Modulus>iSObDmmhDgrl4NiLaviFcpv4NdysBWJcqiVz3AQbPdajtXaQQ8VJdfRkixah132yKOFGCWZhHS3EuPMh8dcNwGwta2nh+m2IV6ktzI4+mZ7CSNAsmlDY0JI+H8At1vKvNArlC5jkVGuliYroJeSU/NLPLNYgspi7TtXGy9Rfug8=</Modulus><Exponent>EQ==</Exponent><P>pd4svtxrnTWXVSb151/JFgT9szI6dxQ5pAFPd4A4yuxLLEay2W2z7d9LVk5siMFhZ10uTJGWzNP5pSgLT8wdww==</P><Q>06j6m4cGRc3uoKVuFFGA19JG3Bi4tDBEQHebEc/Y3+eThrOasYIRrQmGUfqWnd9eFitO9GOaVJ0muNDV7NOxxQ==</Q><DP>OoqmYXr4zhLqHg3AM4s36adomZlBz6zJDLUrGx4yKYCTAJFsTL1OkDCxLYUXP1NPjeSm7dkIDA6UWGh8doRGvQ==</DP><DQ>PkDCLb5NI5br1OVcnJBxMGsFyEOBnmiMi2545x8DjSX+Nq1LnZ6555ljvcIsTIz9jgy83nel3KaxCS5dCWtwhQ==</DQ><InverseQ>OrFYaG7wTqim/bub4qY0CvIfhsjG4/4MEabg0UFTf/+tekKas7DDKg2TD5BS2q0O3XEt7xIfp0S6dpOAnrlyGQ==</InverseQ><D>IESc9FUW1iCuj0ICr8IBSCSy3383iMvZkXI5YPHoSskXdf3Hl3m27pPbbAVTQcM4+o9bxfn4u5JMZ8C8sV/G/8Cfl4ss1NVMbZOecvVObRqRpqXaveq5fN2X0EklH1wzm5w3O8cMXdbC/hc0gKUqaMjFVn1zpf3zVjpOkY0eGRE=</D></RSAKeyValue>");
-               AssertNotNull (r.Decrypt (bytes, true));
+               Assert.IsNotNull (r.Decrypt (bytes, true));
        }
 
 #if NET_2_0
@@ -1157,17 +1157,17 @@ public class RSACryptoServiceProviderTest : Assertion {
        {
                rsa = new RSACryptoServiceProvider (minKeySize);
                CspKeyContainerInfo info = rsa.CspKeyContainerInfo;
-               Assert ("Accessible", info.Accessible);
+               Assert.IsTrue (info.Accessible, "Accessible");
 // FIXME       AssertNotNull ("CryptoKeySecurity", info.CryptoKeySecurity);
-               Assert ("Exportable", info.Exportable);
-               Assert ("HardwareDevice", !info.HardwareDevice);
-               AssertNotNull ("KeyContainerName", info.KeyContainerName);
-               AssertEquals ("KeyNumber", KeyNumber.Exchange, info.KeyNumber);
-               Assert ("MachineKeyStore", !info.MachineKeyStore);
-               Assert ("Protected", !info.Protected);
-               Assert ("RandomlyGenerated", info.RandomlyGenerated);
-               Assert ("Removable", !info.Removable);
-               AssertNotNull ("UniqueKeyContainerName", info.UniqueKeyContainerName);
+               Assert.IsTrue (info.Exportable, "Exportable");
+               Assert.IsFalse (info.HardwareDevice, "HardwareDevice");
+               Assert.IsNotNull (info.KeyContainerName, "KeyContainerName");
+               Assert.AreEqual (KeyNumber.Exchange, info.KeyNumber, "KeyNumber");
+               Assert.IsFalse (info.MachineKeyStore, "MachineKeyStore");
+               Assert.IsFalse (info.Protected, "Protected");
+               Assert.IsTrue (info.RandomlyGenerated, "RandomlyGenerated");
+               Assert.IsFalse (info.Removable, "Removable");
+               Assert.IsNotNull (info.UniqueKeyContainerName, "UniqueKeyContainerName");
        }
 
        [Test]
@@ -1178,17 +1178,17 @@ public class RSACryptoServiceProviderTest : Assertion {
                RSAParameters rsap = AllTests.GetRsaKey (true);
                rsa.ImportParameters (rsap);
                CspKeyContainerInfo info = rsa.CspKeyContainerInfo;
-               Assert ("Accessible", info.Accessible);
+               Assert.IsTrue (info.Accessible, "Accessible");
 // FIXME       AssertNotNull ("CryptoKeySecurity", info.CryptoKeySecurity);
-               Assert ("Exportable", info.Exportable);
-               Assert ("HardwareDevice", !info.HardwareDevice);
-               AssertNotNull ("KeyContainerName", info.KeyContainerName);
-               AssertEquals ("KeyNumber", KeyNumber.Exchange, info.KeyNumber);
-               Assert ("MachineKeyStore", !info.MachineKeyStore);
-               Assert ("Protected", !info.Protected);
-               Assert ("RandomlyGenerated", info.RandomlyGenerated);
-               Assert ("Removable", !info.Removable);
-               AssertNotNull ("UniqueKeyContainerName", info.UniqueKeyContainerName);
+               Assert.IsTrue (info.Exportable, "Exportable");
+               Assert.IsFalse (info.HardwareDevice, "HardwareDevice");
+               Assert.IsNotNull (info.KeyContainerName, "KeyContainerName");
+               Assert.AreEqual (KeyNumber.Exchange, info.KeyNumber, "KeyNumber");
+               Assert.IsFalse (info.MachineKeyStore, "MachineKeyStore");
+               Assert.IsFalse (info.Protected, "Protected");
+               Assert.IsTrue (info.RandomlyGenerated, "RandomlyGenerated");
+               Assert.IsFalse (info.Removable, "Removable");
+               Assert.IsNotNull (info.UniqueKeyContainerName, "UniqueKeyContainerName");
        }
 
        [Test]
@@ -1200,16 +1200,16 @@ public class RSACryptoServiceProviderTest : Assertion {
                RSAParameters rsap = AllTests.GetRsaKey (false);
                rsa.ImportParameters (rsap);
                CspKeyContainerInfo info = rsa.CspKeyContainerInfo;
-               Assert ("Accessible", !info.Accessible);
+               Assert.IsFalse (info.Accessible, "Accessible");
                // info.CryptoKeySecurity throws a CryptographicException at this stage
                // info.Exportable throws a CryptographicException at this stage
-               Assert ("HardwareDevice", !info.HardwareDevice);
-               AssertNotNull ("KeyContainerName", info.KeyContainerName);
-               AssertEquals ("KeyNumber", KeyNumber.Exchange, info.KeyNumber);
-               Assert ("MachineKeyStore", !info.MachineKeyStore);
+               Assert.IsFalse (info.HardwareDevice, "HardwareDevice");
+               Assert.IsNotNull (info.KeyContainerName, "KeyContainerName");
+               Assert.AreEqual (KeyNumber.Exchange, info.KeyNumber, "KeyNumber");
+               Assert.IsFalse (info.MachineKeyStore, "MachineKeyStore");
                // info.Protected throws a CryptographicException at this stage
-               Assert ("RandomlyGenerated", info.RandomlyGenerated);
-               Assert ("Removable", !info.Removable);
+               Assert.IsTrue (info.RandomlyGenerated, "RandomlyGenerated");
+               Assert.IsFalse (info.Removable, "Removable");
                // info.UniqueKeyContainerName throws a CryptographicException at this stage
        }
 #endif
@@ -1221,7 +1221,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                rsa.ImportParameters (rsap);
 
                byte[] keypair = rsa.ExportCspBlob (true);
-               AssertEquals ("07-02-00-00-00-A4-00-00-52-53-41-32-00-04-00-00-11-00-00-00-CB-BD-1D-09-FD-E5-F8-46-59-8F-2A-CA-98-72-53-E2-7F-68-C1-F6-41-9A-7A-52-1F-A5-61-7B-2D-B1-AA-E0-4E-39-98-45-45-B2-34-88-74-53-09-06-9D-64-6A-EE-84-25-3A-D9-B7-B4-E6-3E-72-37-C7-DF-A3-E0-B8-AF-7F-80-8B-5B-8A-9D-71-19-46-EC-E1-60-0D-52-ED-76-48-CD-6F-EB-CE-48-EA-61-AB-02-5C-03-AF-BA-DF-B8-1F-F5-54-74-F0-B6-D6-40-A4-43-10-D4-EE-07-8D-36-F7-71-A8-9D-2B-AC-38-23-9C-CE-82-06-09-2F-F8-BB-99-65-FB-58-2A-BA-41-75-39-1F-9D-45-76-21-25-5B-2D-0A-04-AA-E7-FA-28-7E-3B-1E-5D-6E-23-F0-4E-12-32-F6-84-3D-9E-1A-B8-93-A4-FD-F4-AE-44-9F-EB-99-01-60-B5-A1-10-0B-81-08-C9-B3-B9-B1-81-AE-CF-EE-03-15-46-AF-00-E7-41-A4-A5-16-04-4D-52-52-33-CE-CF-B5-04-32-B4-A3-0D-EA-92-2E-B4-66-16-B4-40-98-86-9D-8B-02-35-20-0F-5A-D0-B1-66-88-D0-42-6C-3F-35-D9-D1-AA-EA-33-12-34-F6-53-F4-27-F0-B1-7F-C9-81-C9-67-1F-3C-C9-AD-74-41-47-0A-91-FC-38-2B-20-2E-9A-2E-69-F7-C1-59-FF-14-74-B7-EA-75-09-49-D9-3E-B1-F2-51-B0-54-9B-AC-D0-A4-83-01-DC-DD-07-EB-5A-9A-D6-FC-23-40-E2-E4-37-03-BA-3E-A6-4C-49-54-3D-DA-36-98-5A-24-F9-39-FE-07-98-84-95-A4-99-1B-0D-22-7A-E4-8A-FD-31-E9-42-E3-8A-6F-8F-3F-80-F9-A7-46-31-4C-A9-56-05-5C-1C-99-7E-8A-3A-BD-AD-61-A9-4C-86-78-F8-B7-51-03-75-F0-0A-FF-90-02-1E-47-F7-39-80-79-25-FB-ED-66-36-EA-98-E6-56-96-0F-2E-9E-4E-2B-40-BF-67-A9-67-B1-83-58-4F-15-32-86-C9-9F-11-E2-39-CD-7F-07-93-50-88-53-34-F7-71-F2-80-B3-23-94-AE-DB-5B-26-8D-19-01-63-BB-DA-4F-6C-B0-C1-B3-1C-5B-C8-4B-3A-46-E4-3F-88-B8-B7-C2-28-94-AF-94-48-CC-CE-A1-E1-FB-DD-3E-A1-74-4F-ED-26-99-93-0A-D2-F5-BE-C3-8D-D3-2C-09-6C-C5-68-AF-6A-E5-44-94-52-A9-F1-76-1C-11-BC-CF-AC-50-59-AD-F3-7F-C9-DA-3E-C9-2E-B8-DC-7F-E3-39-A9-82-C0-A2-0D-87-D6-69-26-39-5C-5E-74-65-C4-6B-8D-99-C7-B3-10-94-B2-41-96-57-01-38-81-84-27-B4-68-06-1E-25-31-3F-F8-CD-C1-30-DB-88-B9-C4-89-F2-FA-41-53-FC-DA-A5", BitConverter.ToString (keypair));
+               Assert.AreEqual ("07-02-00-00-00-A4-00-00-52-53-41-32-00-04-00-00-11-00-00-00-CB-BD-1D-09-FD-E5-F8-46-59-8F-2A-CA-98-72-53-E2-7F-68-C1-F6-41-9A-7A-52-1F-A5-61-7B-2D-B1-AA-E0-4E-39-98-45-45-B2-34-88-74-53-09-06-9D-64-6A-EE-84-25-3A-D9-B7-B4-E6-3E-72-37-C7-DF-A3-E0-B8-AF-7F-80-8B-5B-8A-9D-71-19-46-EC-E1-60-0D-52-ED-76-48-CD-6F-EB-CE-48-EA-61-AB-02-5C-03-AF-BA-DF-B8-1F-F5-54-74-F0-B6-D6-40-A4-43-10-D4-EE-07-8D-36-F7-71-A8-9D-2B-AC-38-23-9C-CE-82-06-09-2F-F8-BB-99-65-FB-58-2A-BA-41-75-39-1F-9D-45-76-21-25-5B-2D-0A-04-AA-E7-FA-28-7E-3B-1E-5D-6E-23-F0-4E-12-32-F6-84-3D-9E-1A-B8-93-A4-FD-F4-AE-44-9F-EB-99-01-60-B5-A1-10-0B-81-08-C9-B3-B9-B1-81-AE-CF-EE-03-15-46-AF-00-E7-41-A4-A5-16-04-4D-52-52-33-CE-CF-B5-04-32-B4-A3-0D-EA-92-2E-B4-66-16-B4-40-98-86-9D-8B-02-35-20-0F-5A-D0-B1-66-88-D0-42-6C-3F-35-D9-D1-AA-EA-33-12-34-F6-53-F4-27-F0-B1-7F-C9-81-C9-67-1F-3C-C9-AD-74-41-47-0A-91-FC-38-2B-20-2E-9A-2E-69-F7-C1-59-FF-14-74-B7-EA-75-09-49-D9-3E-B1-F2-51-B0-54-9B-AC-D0-A4-83-01-DC-DD-07-EB-5A-9A-D6-FC-23-40-E2-E4-37-03-BA-3E-A6-4C-49-54-3D-DA-36-98-5A-24-F9-39-FE-07-98-84-95-A4-99-1B-0D-22-7A-E4-8A-FD-31-E9-42-E3-8A-6F-8F-3F-80-F9-A7-46-31-4C-A9-56-05-5C-1C-99-7E-8A-3A-BD-AD-61-A9-4C-86-78-F8-B7-51-03-75-F0-0A-FF-90-02-1E-47-F7-39-80-79-25-FB-ED-66-36-EA-98-E6-56-96-0F-2E-9E-4E-2B-40-BF-67-A9-67-B1-83-58-4F-15-32-86-C9-9F-11-E2-39-CD-7F-07-93-50-88-53-34-F7-71-F2-80-B3-23-94-AE-DB-5B-26-8D-19-01-63-BB-DA-4F-6C-B0-C1-B3-1C-5B-C8-4B-3A-46-E4-3F-88-B8-B7-C2-28-94-AF-94-48-CC-CE-A1-E1-FB-DD-3E-A1-74-4F-ED-26-99-93-0A-D2-F5-BE-C3-8D-D3-2C-09-6C-C5-68-AF-6A-E5-44-94-52-A9-F1-76-1C-11-BC-CF-AC-50-59-AD-F3-7F-C9-DA-3E-C9-2E-B8-DC-7F-E3-39-A9-82-C0-A2-0D-87-D6-69-26-39-5C-5E-74-65-C4-6B-8D-99-C7-B3-10-94-B2-41-96-57-01-38-81-84-27-B4-68-06-1E-25-31-3F-F8-CD-C1-30-DB-88-B9-C4-89-F2-FA-41-53-FC-DA-A5", BitConverter.ToString (keypair));
        }
 
        [Test]
@@ -1232,7 +1232,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                rsa.ImportParameters (rsap);
 
                byte[] pubkey = rsa.ExportCspBlob (false);
-               AssertEquals ("06-02-00-00-00-A4-00-00-52-53-41-31-00-04-00-00-11-00-00-00-CB-BD-1D-09-FD-E5-F8-46-59-8F-2A-CA-98-72-53-E2-7F-68-C1-F6-41-9A-7A-52-1F-A5-61-7B-2D-B1-AA-E0-4E-39-98-45-45-B2-34-88-74-53-09-06-9D-64-6A-EE-84-25-3A-D9-B7-B4-E6-3E-72-37-C7-DF-A3-E0-B8-AF-7F-80-8B-5B-8A-9D-71-19-46-EC-E1-60-0D-52-ED-76-48-CD-6F-EB-CE-48-EA-61-AB-02-5C-03-AF-BA-DF-B8-1F-F5-54-74-F0-B6-D6-40-A4-43-10-D4-EE-07-8D-36-F7-71-A8-9D-2B-AC-38-23-9C-CE-82-06-09-2F-F8-BB", BitConverter.ToString (pubkey));
+               Assert.AreEqual ("06-02-00-00-00-A4-00-00-52-53-41-31-00-04-00-00-11-00-00-00-CB-BD-1D-09-FD-E5-F8-46-59-8F-2A-CA-98-72-53-E2-7F-68-C1-F6-41-9A-7A-52-1F-A5-61-7B-2D-B1-AA-E0-4E-39-98-45-45-B2-34-88-74-53-09-06-9D-64-6A-EE-84-25-3A-D9-B7-B4-E6-3E-72-37-C7-DF-A3-E0-B8-AF-7F-80-8B-5B-8A-9D-71-19-46-EC-E1-60-0D-52-ED-76-48-CD-6F-EB-CE-48-EA-61-AB-02-5C-03-AF-BA-DF-B8-1F-F5-54-74-F0-B6-D6-40-A4-43-10-D4-EE-07-8D-36-F7-71-A8-9D-2B-AC-38-23-9C-CE-82-06-09-2F-F8-BB", BitConverter.ToString (pubkey));
        }
 
        [Test]
@@ -1254,7 +1254,7 @@ public class RSACryptoServiceProviderTest : Assertion {
                rsa.ImportParameters (rsap);
 
                byte[] pubkey = rsa.ExportCspBlob (false);
-               AssertEquals ("06-02-00-00-00-A4-00-00-52-53-41-31-00-04-00-00-11-00-00-00-CB-BD-1D-09-FD-E5-F8-46-59-8F-2A-CA-98-72-53-E2-7F-68-C1-F6-41-9A-7A-52-1F-A5-61-7B-2D-B1-AA-E0-4E-39-98-45-45-B2-34-88-74-53-09-06-9D-64-6A-EE-84-25-3A-D9-B7-B4-E6-3E-72-37-C7-DF-A3-E0-B8-AF-7F-80-8B-5B-8A-9D-71-19-46-EC-E1-60-0D-52-ED-76-48-CD-6F-EB-CE-48-EA-61-AB-02-5C-03-AF-BA-DF-B8-1F-F5-54-74-F0-B6-D6-40-A4-43-10-D4-EE-07-8D-36-F7-71-A8-9D-2B-AC-38-23-9C-CE-82-06-09-2F-F8-BB", BitConverter.ToString (pubkey));
+               Assert.AreEqual ("06-02-00-00-00-A4-00-00-52-53-41-31-00-04-00-00-11-00-00-00-CB-BD-1D-09-FD-E5-F8-46-59-8F-2A-CA-98-72-53-E2-7F-68-C1-F6-41-9A-7A-52-1F-A5-61-7B-2D-B1-AA-E0-4E-39-98-45-45-B2-34-88-74-53-09-06-9D-64-6A-EE-84-25-3A-D9-B7-B4-E6-3E-72-37-C7-DF-A3-E0-B8-AF-7F-80-8B-5B-8A-9D-71-19-46-EC-E1-60-0D-52-ED-76-48-CD-6F-EB-CE-48-EA-61-AB-02-5C-03-AF-BA-DF-B8-1F-F5-54-74-F0-B6-D6-40-A4-43-10-D4-EE-07-8D-36-F7-71-A8-9D-2B-AC-38-23-9C-CE-82-06-09-2F-F8-BB", BitConverter.ToString (pubkey));
        }
 
        [Test]
@@ -1293,7 +1293,7 @@ public class RSACryptoServiceProviderTest : Assertion {
 
                byte[] keypair = rsa.ExportCspBlob (true);
                for (int i=0; i < blob.Length; i++)
-                       AssertEquals (i.ToString (), blob [i], keypair [i]);
+                       Assert.AreEqual (blob [i], keypair [i], i.ToString ());
        }
 
        [Test]
@@ -1305,7 +1305,7 @@ public class RSACryptoServiceProviderTest : Assertion {
 
                byte[] pubkey = rsa.ExportCspBlob (false);
                for (int i = 0; i < blob.Length; i++)
-                       AssertEquals (i.ToString (), blob [i], pubkey [i]);
+                       Assert.AreEqual (blob [i], pubkey [i], i.ToString ());
        }
 
        [Test]
index dc840c5036c2a9758c546959f8a68af24113fb7e..3ce91cef76ab397ff2082c3d057b07841eb9174b 100644 (file)
@@ -18,7 +18,7 @@ using System.Text;
 namespace MonoTests.System.Security.Cryptography {
 
 [TestFixture]
-public class SymmetricAlgorithmTest : Assertion {
+public class SymmetricAlgorithmTest {
 public void AssertEquals (string msg, byte[] array1, byte[] array2)
 {
        AllTests.AssertEquals (msg, array1, array2);
@@ -3743,7 +3743,7 @@ public void TestRijndael_k128b128_ECB_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k128b128_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k128b128_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -3829,7 +3829,7 @@ public void TestRijndael_k128b128_CBC_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k128b128_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k128b128_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -3934,7 +3934,7 @@ public void TestRijndael_k128b192_ECB_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k128b192_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k128b192_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4020,7 +4020,7 @@ public void TestRijndael_k128b192_CBC_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k128b192_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k128b192_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4125,7 +4125,7 @@ public void TestRijndael_k128b256_ECB_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k128b256_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k128b256_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4211,7 +4211,7 @@ public void TestRijndael_k128b256_CBC_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k128b256_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k128b256_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4316,7 +4316,7 @@ public void TestRijndael_k192b128_ECB_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k192b128_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k192b128_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4402,7 +4402,7 @@ public void TestRijndael_k192b128_CBC_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k192b128_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k192b128_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4507,7 +4507,7 @@ public void TestRijndael_k192b192_ECB_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k192b192_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k192b192_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4593,7 +4593,7 @@ public void TestRijndael_k192b192_CBC_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k192b192_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k192b192_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4698,7 +4698,7 @@ public void TestRijndael_k192b256_ECB_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k192b256_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k192b256_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4784,7 +4784,7 @@ public void TestRijndael_k192b256_CBC_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k192b256_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k192b256_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4889,7 +4889,7 @@ public void TestRijndael_k256b128_ECB_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k256b128_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k256b128_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -4975,7 +4975,7 @@ public void TestRijndael_k256b128_CBC_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k256b128_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k256b128_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -5080,7 +5080,7 @@ public void TestRijndael_k256b192_ECB_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k256b192_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k256b192_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -5166,7 +5166,7 @@ public void TestRijndael_k256b192_CBC_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k256b192_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k256b192_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -5271,7 +5271,7 @@ public void TestRijndael_k256b256_ECB_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k256b256_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k256b256_ECB_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
@@ -5357,7 +5357,7 @@ public void TestRijndael_k256b256_CBC_Zeros ()
        }
        catch (Exception e) {
                if (e.Message != "Input buffer contains insufficient data. ")
-                       Fail ("Rijndael_k256b256_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
+                       Assert.Fail ("Rijndael_k256b256_CBC_Zeros: This isn't the expected exception: " + e.ToString ());
        }
 }
 
index 01ff35d96bf09beb144cb4297831867df699e60d..debf95582e53505e583f99694feae94cc3e8ed9e 100644 (file)
@@ -198,24 +198,24 @@ namespace MonoTests.System.Threading.Tasks
                }
 
                [Test]
+               [Ignore ("#4550, Mono GC is lame")]
                public void SetExceptionAndUnobservedEvent ()
                {
-                       bool wasCalled = false;
                        bool notFromMainThread = false;
+                       var mre = new ManualResetEvent (false);
                        int mainThreadId = Thread.CurrentThread.ManagedThreadId;
                        TaskScheduler.UnobservedTaskException += (o, args) => {
-                               wasCalled = true;
                                notFromMainThread = Thread.CurrentThread.ManagedThreadId != mainThreadId;
                                args.SetObserved ();
+                               mre.Set ();
                        };
                        var inner = new ApplicationException ();
                        CreateFaultedTaskCompletionSource (inner);
-                       Thread.Sleep (1000);
                        GC.Collect ();
                        GC.WaitForPendingFinalizers ();
 
-                       Assert.IsTrue (wasCalled);
-                       Assert.IsTrue (notFromMainThread);
+                       Assert.IsTrue (mre.WaitOne (5000), "#1");
+                       Assert.IsTrue (notFromMainThread, "#2");
                }
 
                void CreateFaultedTaskCompletionSource (Exception inner)
index 2bef86dea404ffac4641c91a88f0cd005133d03c..055ccb9485fe7afec2f819501ec6722fa632a1de 100644 (file)
@@ -173,6 +173,69 @@ namespace MonoTests.System.Threading.Tasks
                        Assert.IsTrue (ran, "#2");
                }
 
+               [Test]
+               public void ContinueWhenAll_WithMixedCompletionState ()
+               {
+                       var mre = new ManualResetEventSlim ();
+                       var task = Task.Factory.StartNew (() => mre.Wait (200));
+                       var contFailed = task.ContinueWith (t => {}, TaskContinuationOptions.OnlyOnFaulted);
+                       var contCanceled = task.ContinueWith (t => {}, TaskContinuationOptions.OnlyOnCanceled);
+                       var contSuccess = task.ContinueWith (t => {}, TaskContinuationOptions.OnlyOnRanToCompletion);
+                       bool ran = false;
+
+                       var cont = Task.Factory.ContinueWhenAll (new Task[] { contFailed, contCanceled, contSuccess }, _ => ran = true);
+
+                       mre.Set ();
+                       cont.Wait (200);
+
+                       Assert.IsTrue (ran);
+                       Assert.AreEqual (TaskStatus.RanToCompletion, cont.Status);
+               }
+
+               [Test]
+               public void ContinueWhenAll_InvalidArguments ()
+               {
+                       try {
+                               factory.ContinueWhenAll (null, delegate { });
+                               Assert.Fail ("#1");
+                       } catch (ArgumentNullException) {
+                       }
+
+                       try {
+                               factory.ContinueWhenAll (new Task[0], delegate { });
+                               Assert.Fail ("#2");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               factory.ContinueWhenAll (new Task[] { null }, delegate { });
+                               Assert.Fail ("#3");
+                       } catch (ArgumentException) {
+                       }
+
+                       var tasks = new Task [] {
+                               factory.StartNew (delegate {})
+                       };
+
+                       try {
+                               factory.ContinueWhenAll (tasks, null);
+                               Assert.Fail ("#4");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               factory.ContinueWhenAll (tasks, delegate { }, CancellationToken.None, TaskContinuationOptions.None, null);
+                               Assert.Fail ("#5");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               factory.ContinueWhenAll (tasks, delegate { }, CancellationToken.None, TaskContinuationOptions.OnlyOnCanceled, null);
+                               Assert.Fail ("#6");
+                       } catch (ArgumentException) {
+                       }
+               }
+
                [Test]
                public void ContinueWhenAny_Simple ()
                {
@@ -237,6 +300,12 @@ namespace MonoTests.System.Threading.Tasks
                                Assert.Fail ("#5");
                        } catch (ArgumentException) {
                        }
+
+                       try {
+                               factory.ContinueWhenAny (tasks, delegate { }, CancellationToken.None, TaskContinuationOptions.OnlyOnCanceled, null);
+                               Assert.Fail ("#6");
+                       } catch (ArgumentException) {
+                       }
                }
 
                [Test]
@@ -280,7 +349,7 @@ namespace MonoTests.System.Threading.Tasks
                        bool result = false;
                        bool continuationTest = false;
 
-                       Func<int, int> func = (i) => { result = true; throw new ApplicationException ("bleh"); return i + 3; };
+                       Func<int, int> func = (i) => { result = true; throw new ApplicationException ("bleh"); };
                        Task<int> task = factory.FromAsync<int, int> (func.BeginInvoke, func.EndInvoke, 1, null);
                        var cont = task.ContinueWith (_ => continuationTest = true, TaskContinuationOptions.ExecuteSynchronously);
                        try {
index 4efa13e34809757e52b6a3c36da7b7f1f0aec128..7c697a528282c92e54940bec39ec0741b4c0a2ca 100644 (file)
@@ -36,22 +36,10 @@ namespace MonoTests.System.Threading.Tasks
        [TestFixture]
        public class TaskSchedulerTests
        {
-               [Test]
-               public void BasicRunSynchronouslyTest ()
-               {
-                       bool ran = false;
-                       var t = new Task (() => ran = true);
-
-                       t.RunSynchronously ();
-                       Assert.IsTrue (t.IsCompleted);
-                       Assert.IsFalse (t.IsFaulted);
-                       Assert.IsFalse (t.IsCanceled);
-                       Assert.IsTrue (ran);
-               }
-
                class LazyCatScheduler : TaskScheduler
                {
-                       public TaskStatus ExecuteInlineStatus {
+                       public TaskStatus ExecuteInlineStatus
+                       {
                                get;
                                set;
                        }
@@ -78,6 +66,56 @@ namespace MonoTests.System.Threading.Tasks
                        }
                }
 
+               class DefaultScheduler : TaskScheduler
+               {
+                       protected override IEnumerable<Task> GetScheduledTasks ()
+                       {
+                               throw new NotImplementedException ();
+                       }
+
+                       protected override void QueueTask (Task task)
+                       {
+                               throw new NotImplementedException ();
+                       }
+
+                       protected override bool TryExecuteTaskInline (Task task, bool taskWasPreviouslyQueued)
+                       {
+                               throw new NotImplementedException ();
+                       }
+
+                       public void TestDefaultMethod ()
+                       {
+                               Assert.IsFalse (TryDequeue (null), "#1");
+                       }
+               }
+
+               [Test]
+               public void FromCurrentSynchronizationContextTest_Invalid()
+               {
+                       var c = SynchronizationContext.Current;
+                       try {
+                               SynchronizationContext.SetSynchronizationContext (null);
+                               TaskScheduler.FromCurrentSynchronizationContext ();
+                               Assert.Fail ("#1");
+                       } catch (InvalidOperationException) {
+                       } finally {
+                               SynchronizationContext.SetSynchronizationContext (c);
+                       }
+               }
+
+               [Test]
+               public void BasicRunSynchronouslyTest ()
+               {
+                       bool ran = false;
+                       var t = new Task (() => ran = true);
+
+                       t.RunSynchronously ();
+                       Assert.IsTrue (t.IsCompleted);
+                       Assert.IsFalse (t.IsFaulted);
+                       Assert.IsFalse (t.IsCanceled);
+                       Assert.IsTrue (ran);
+               }
+
                [Test]
                public void RunSynchronouslyButNoExecutionTest ()
                {
@@ -119,6 +157,13 @@ namespace MonoTests.System.Threading.Tasks
                        }
                }
 
+               [Test]
+               public void DefaultBehaviourTest ()
+               {
+                       var s = new DefaultScheduler ();
+                       s.TestDefaultMethod ();
+               }
+
                // This test doesn't work if the GC uses multiple finalizer thread.
                // For now it's fine since only one thread is used
                [Test]
index 1a53e2b87705ad67d59310671d38b31b0017fe8e..95a19c46e03a7f772173060c17667ba68d58257d 100644 (file)
@@ -187,7 +187,7 @@ namespace MonoTests.System.Threading.Tasks
                }
                
                [Test]
-               public void WaitAllTest()
+               public void WaitAllTest ()
                {
                        ParallelTestHelper.Repeat (delegate {
                                int achieved = 0;
@@ -244,8 +244,8 @@ namespace MonoTests.System.Threading.Tasks
                                Task.Factory.StartNew (delegate { try { throw new ApplicationException (); } finally { cde.Signal (); } })
                        };
 
-                       Assert.IsTrue (cde.Wait (100), "#1");
-                       Assert.IsFalse (Task.WaitAll (tasks, 100), "#2");
+                       Assert.IsTrue (cde.Wait (1000), "#1");
+                       Assert.IsFalse (Task.WaitAll (tasks, 1000), "#2");
 
                        mre.Set ();
 
@@ -268,8 +268,8 @@ namespace MonoTests.System.Threading.Tasks
                                Task.Factory.StartNew (delegate { mre.WaitOne (); })
                        };
 
-                       Assert.IsTrue (cde.Wait (100), "#1");
-                       Assert.IsFalse (Task.WaitAll (tasks, 100), "#2");
+                       Assert.IsTrue (cde.Wait (1000), "#1");
+                       Assert.IsFalse (Task.WaitAll (tasks, 1000), "#2");
 
                        mre.Set ();
 
@@ -534,6 +534,26 @@ namespace MonoTests.System.Threading.Tasks
                        }, 2);
                }
 
+               [Test]
+               public void ContinueWithDifferentOptionsAreCanceledTest ()
+               {
+                       var mre = new ManualResetEventSlim ();
+                       var task = Task.Factory.StartNew (() => mre.Wait (200));
+                       var contFailed = task.ContinueWith (t => {}, TaskContinuationOptions.OnlyOnFaulted);
+                       var contCanceled = task.ContinueWith (t => {}, TaskContinuationOptions.OnlyOnCanceled);
+                       var contSuccess = task.ContinueWith (t => {}, TaskContinuationOptions.OnlyOnRanToCompletion);
+
+                       mre.Set ();
+                       contSuccess.Wait (100);
+
+                       Assert.IsTrue (contSuccess.IsCompleted);
+                       Assert.IsTrue (contFailed.IsCompleted);
+                       Assert.IsTrue (contCanceled.IsCompleted);
+                       Assert.IsFalse (contSuccess.IsCanceled);
+                       Assert.IsTrue (contFailed.IsCanceled);
+                       Assert.IsTrue (contCanceled.IsCanceled);
+               }
+
                [Test]
                public void MultipleTasks()
                {
@@ -565,26 +585,27 @@ namespace MonoTests.System.Threading.Tasks
                {
                        ParallelTestHelper.Repeat (delegate {
                                bool r1 = false, r2 = false, r3 = false;
-                               var mre = new ManualResetEvent (false);
+                               var mre = new ManualResetEventSlim (false);
+                               var mreStart = new ManualResetEventSlim (false);
                                
                                Task t = Task.Factory.StartNew(delegate {
                                        Task.Factory.StartNew(delegate {
+                                               mre.Wait (300);
                                                r1 = true;
-                                               mre.Set ();
                                        }, TaskCreationOptions.AttachedToParent);
                                        Task.Factory.StartNew(delegate {
-                                               Assert.IsTrue (mre.WaitOne (1000), "#0");
-                                               
                                                r2 = true;
                                        }, TaskCreationOptions.AttachedToParent);
                                        Task.Factory.StartNew(delegate {
-                                               Assert.IsTrue (mre.WaitOne (1000), "#0");
-                                               
                                                r3 = true;
                                        }, TaskCreationOptions.AttachedToParent);
+                                       mreStart.Set ();
                                });
                                
-                               Assert.IsTrue (t.Wait(2000), "#0");
+                               mreStart.Wait (300);
+                               Assert.IsFalse (t.Wait (10), "#0a");
+                               mre.Set ();
+                               Assert.IsTrue (t.Wait (500), "#0b");
                                Assert.IsTrue(r2, "#1");
                                Assert.IsTrue(r3, "#2");
                                Assert.IsTrue(r1, "#3");
@@ -768,7 +789,206 @@ namespace MonoTests.System.Threading.Tasks
                        Assert.IsFalse (t.IsCanceled);
                }
 
+               [Test]
+               public void CanceledContinuationExecuteSynchronouslyTest ()
+               {
+                       var source = new CancellationTokenSource();
+                       var token = source.Token;
+                       var evt = new ManualResetEventSlim ();
+                       bool result = false;
+                       bool thrown = false;
+
+                       var task = Task.Factory.StartNew (() => evt.Wait (100));
+                       var cont = task.ContinueWith (t => result = true, token, TaskContinuationOptions.ExecuteSynchronously, TaskScheduler.Default);
+
+                       source.Cancel();
+                       evt.Set ();
+                       task.Wait (100);
+                       try {
+                               cont.Wait (100);
+                       } catch (Exception ex) {
+                               thrown = true;
+                       }
+
+                       Assert.IsTrue (task.IsCompleted);
+                       Assert.IsTrue (cont.IsCanceled);
+                       Assert.IsFalse (result);
+                       Assert.IsTrue (thrown);
+               }
+
+               [Test]
+               public void WhenChildTaskErrorIsThrownParentTaskShouldBeFaulted ()
+               {
+                       Task innerTask = null;
+                       var testTask = new Task (() =>
+                       {
+                               innerTask = new Task (() => 
+                               {
+                                       throw new InvalidOperationException ();
+                               }, TaskCreationOptions.AttachedToParent);
+                               innerTask.RunSynchronously ();
+                       });
+                       testTask.RunSynchronously ();
+
+                       Assert.AreNotEqual (TaskStatus.Running, testTask.Status);
+                       Assert.IsNotNull (innerTask);
+                       Assert.IsTrue (innerTask.IsFaulted);
+                       Assert.IsNotNull (testTask.Exception);
+                       Assert.IsTrue (testTask.IsFaulted);
+                       Assert.IsNotNull (innerTask.Exception);
+               }
+               
+               [Test]
+               public void WhenChildTaskErrorIsThrownOnlyOnFaultedContinuationShouldExecute ()
+               {
+                       var continuationRan = false;
+                       var testTask = new Task (() =>
+                       {
+                               var task = new Task (() => 
+                               {
+                                       throw new InvalidOperationException();
+                               }, TaskCreationOptions.AttachedToParent);
+                               task.RunSynchronously ();
+                       });
+                       var onErrorTask = testTask.ContinueWith (x => continuationRan = true, TaskContinuationOptions.OnlyOnFaulted);
+                       testTask.RunSynchronously ();
+                       onErrorTask.Wait (100);
+                       Assert.IsTrue (continuationRan);
+               }
+               
+               [Test]
+               public void WhenChildTaskErrorIsThrownNotOnFaultedContinuationShouldNotBeExecuted ()
+               {
+                       var continuationRan = false;
+                       var testTask = new Task (() =>
+                       {
+                               var task = new Task (() => 
+                               {
+                                       throw new InvalidOperationException();
+                               }, TaskCreationOptions.AttachedToParent);
+                               task.RunSynchronously();
+                       });
+                       var onErrorTask = testTask.ContinueWith (x => continuationRan = true, TaskContinuationOptions.NotOnFaulted);
+                       testTask.RunSynchronously ();
+                       Assert.IsTrue (onErrorTask.IsCompleted);
+                       Assert.IsFalse (onErrorTask.IsFaulted);
+                       Assert.IsFalse (continuationRan);
+               }       
+               
+               [Test]
+               public void WhenChildTaskSeveralLevelsDeepHandlesAggregateExceptionErrorStillBubblesToParent ()
+               {
+                       var continuationRan = false;
+                       AggregateException e = null;
+                       var testTask = new Task (() =>
+                       {
+                               var child1 = new Task (() =>
+                               {
+                                       var child2 = new Task (() => 
+                                       {
+                                               throw new InvalidOperationException();
+                                       }, TaskCreationOptions.AttachedToParent);
+                                       child2.RunSynchronously ();
+                               }, TaskCreationOptions.AttachedToParent);
+                               
+                               child1.RunSynchronously();
+                               e = child1.Exception;
+                               child1.Exception.Handle (ex => true);
+                       });
+                       var onErrorTask = testTask.ContinueWith (x => continuationRan = true, TaskContinuationOptions.OnlyOnFaulted);
+                       testTask.RunSynchronously ();
+                       onErrorTask.Wait (100);
+                       Assert.IsNotNull (e);
+                       Assert.IsTrue (continuationRan);
+               }
+               
+               [Test]
+               public void AlreadyCompletedChildTaskShouldRunContinuationImmediately ()
+               {
+                       string result = "Failed";
+                       var testTask = new Task (() => 
+                       {
+                               var child = new Task<string> (() =>
+                               {
+                                       return "Success";
+                               }, TaskCreationOptions.AttachedToParent);
+                               child.RunSynchronously ();
+                               child.ContinueWith (x => { Thread.Sleep (50); result = x.Result; }, TaskContinuationOptions.AttachedToParent | TaskContinuationOptions.NotOnFaulted);
+                       });
+                       testTask.RunSynchronously ();
+
+                       Assert.AreEqual ("Success", result);
+               }
+
+               [Test]
+               public void InlineNotTrashingParentRelationship ()
+               {
+                       bool r1 = false, r2 = false;
+                       var t = new Task (() => {
+                               new Task (() => { r1 = true; }, TaskCreationOptions.AttachedToParent).RunSynchronously ();
+                               Task.Factory.StartNew (() => { Thread.Sleep (100); r2 = true; }, TaskCreationOptions.AttachedToParent);
+                   });
+                       t.RunSynchronously ();
+
+                       Assert.IsTrue (r1);
+                       Assert.IsTrue (r2);
+               }
+
 #if NET_4_5
+               [Test]
+               public void Delay_Invalid ()
+               {
+                       try {
+                               Task.Delay (-100);
+                       } catch (ArgumentOutOfRangeException) {
+                       }
+               }
+
+               [Test]
+               public void Delay_Start ()
+               {
+                       var t = Task.Delay (5000);
+                       try {
+                               t.Start ();
+                       } catch (InvalidOperationException) {
+                       }
+               }
+
+               [Test]
+               public void Delay_Simple ()
+               {
+                       var t = Task.Delay (300);
+                       Assert.IsTrue (TaskStatus.WaitingForActivation == t.Status || TaskStatus.Running == t.Status, "#1");
+                       Assert.IsTrue (t.Wait (400), "#2");
+               }
+
+               [Test]
+               public void Delay_Cancelled ()
+               {
+                       var cancelation = new CancellationTokenSource ();
+
+                       var t = Task.Delay (5000, cancelation.Token);
+                       Assert.IsTrue (TaskStatus.WaitingForActivation == t.Status || TaskStatus.Running == t.Status, "#1");
+                       cancelation.Cancel ();
+                       try {
+                               t.Wait (1000);
+                               Assert.Fail ("#2");
+                       } catch (AggregateException) {
+                               Assert.AreEqual (TaskStatus.Canceled, t.Status, "#3");
+                       }
+                       
+                       cancelation = new CancellationTokenSource ();
+                       t = Task.Delay (Timeout.Infinite, cancelation.Token);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#11");
+                       cancelation.Cancel ();
+                       try {
+                               t.Wait (1000);
+                               Assert.Fail ("#12");
+                       } catch (AggregateException) {
+                               Assert.AreEqual (TaskStatus.Canceled, t.Status, "#13");
+                       }
+               }
+
                [Test]
                public void WaitAny_WithNull ()
                {
@@ -784,6 +1004,468 @@ namespace MonoTests.System.Threading.Tasks
                        }
                }
 
+               [Test]
+               public void WhenAll_WithNull ()
+               {
+                       var tasks = new[] {
+                               Task.FromResult (2),
+                               null
+                       };
+
+                       try {
+                               Task.WhenAll (tasks);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentException) {
+                       }
+
+                       tasks = null;
+                       try {
+                               Task.WhenAll (tasks);
+                               Assert.Fail ("#2");
+                       } catch (ArgumentException) {
+                       }
+               }
+
+               [Test]
+               public void WhenAll_Start ()
+               {
+                       Task[] tasks = new[] {
+                               Task.FromResult (2),
+                       };
+
+                       var t = Task.WhenAll (tasks);
+                       Assert.AreEqual (TaskStatus.RanToCompletion, t.Status, "#1");
+
+                       try {
+                               t.Start ();
+                               Assert.Fail ("#2");
+                       } catch (InvalidOperationException) {
+                       }
+
+                       tasks = new [] {
+                               new Task (delegate { }),
+                       };
+
+                       t = Task.WhenAll (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#11");
+
+                       try {
+                               t.Start ();
+                               Assert.Fail ("#12");
+                       } catch (InvalidOperationException) {
+                       }
+               }
+
+               [Test]
+               public void WhenAll_Cancelled ()
+               {
+                       var cancelation = new CancellationTokenSource ();
+                       var tasks = new Task[] {
+                               new Task (delegate { }),
+                               new Task (delegate { }, cancelation.Token)
+                       };
+
+                       cancelation.Cancel ();
+
+                       var t = Task.WhenAll (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#1");
+                       tasks[0].Start ();
+
+                       try {
+                               Assert.IsTrue (t.Wait (1000), "#2");
+                               Assert.Fail ("#2a");
+                       } catch (AggregateException e) {
+                               Assert.IsInstanceOfType (typeof (TaskCanceledException), e.InnerException, "#3");
+                       }
+               }
+
+               [Test]
+               public void WhenAll_Faulted ()
+               {
+                       var tcs = new TaskCompletionSource<object> ();
+                       tcs.SetException (new ApplicationException ());
+
+                       var tcs2 = new TaskCompletionSource<object> ();
+                       tcs2.SetException (new InvalidTimeZoneException ());
+
+                       var cancelation = new CancellationTokenSource ();
+                       var tasks = new Task[] {
+                               new Task (delegate { }),
+                               new Task (delegate { }, cancelation.Token),
+                               tcs.Task,
+                               tcs2.Task
+                       };
+
+                       cancelation.Cancel ();
+
+                       var t = Task.WhenAll (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#1");
+                       tasks[0].Start ();
+
+                       try {
+                               Assert.IsTrue (t.Wait (1000), "#2");
+                               Assert.Fail ("#2a");
+                       } catch (AggregateException e) {
+                               Assert.IsInstanceOfType (typeof (ApplicationException), e.InnerException, "#3");
+                               Assert.IsInstanceOfType (typeof (InvalidTimeZoneException), e.InnerExceptions[1], "#4");
+                       }
+               }
+
+               [Test]
+               public void WhenAll ()
+               {
+                       var t1 = new Task (delegate { });
+                       var t2 = new Task (delegate { t1.Start (); });
+
+                       var tasks = new Task[] {
+                               t1,
+                               t2,
+                       };
+
+                       var t = Task.WhenAll (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#1");
+                       t2.Start ();
+
+                       Assert.IsTrue (t.Wait (1000), "#2");
+               }
+
+               [Test]
+               public void WhenAllResult_WithNull ()
+               {
+                       var tasks = new[] {
+                               Task.FromResult (2),
+                               null
+                       };
+
+                       try {
+                               Task.WhenAll<int> (tasks);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentException) {
+                       }
+
+                       tasks = null;
+                       try {
+                               Task.WhenAll<int> (tasks);
+                               Assert.Fail ("#2");
+                       } catch (ArgumentException) {
+                       }
+               }
+
+               [Test]
+               public void WhenAllResult_Cancelled ()
+               {
+                       var cancelation = new CancellationTokenSource ();
+                       var tasks = new [] {
+                               new Task<int> (delegate { return 9; }),
+                               new Task<int> (delegate { return 1; }, cancelation.Token)
+                       };
+
+                       cancelation.Cancel ();
+
+                       var t = Task.WhenAll (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#1");
+                       tasks[0].Start ();
+
+                       try {
+                               Assert.IsTrue (t.Wait (1000), "#2");
+                               Assert.Fail ("#2a");
+                       } catch (AggregateException e) {
+                               Assert.IsInstanceOfType (typeof (TaskCanceledException), e.InnerException, "#3");
+                       }
+
+                       try {
+                               var r = t.Result;
+                               Assert.Fail ("#4");
+                       } catch (AggregateException) {
+                       }
+               }
+
+               [Test]
+               public void WhenAllResult ()
+               {
+                       var t1 = new Task<string> (delegate { return "a"; });
+                       var t2 = new Task<string> (delegate { t1.Start (); return "b"; });
+
+                       var tasks = new [] {
+                               t1,
+                               t2,
+                       };
+
+                       var t = Task.WhenAll<string> (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#1");
+                       t2.Start ();
+
+                       Assert.IsTrue (t.Wait (1000), "#2");
+                       Assert.AreEqual (2, t.Result.Length, "#3");
+                       Assert.AreEqual ("a", t.Result[0], "#3a");
+                       Assert.AreEqual ("b", t.Result[1], "#3b");
+               }
+
+               [Test]
+               public void WhenAllResult_Completed ()
+               {
+                       var tasks = new[] {
+                               Task.FromResult (1),
+                               Task.FromResult (2)
+                       };
+
+                       var t = Task.WhenAll<int> (tasks);
+                       Assert.AreEqual (TaskStatus.RanToCompletion, t.Status, "#1");
+                       Assert.AreEqual (2, t.Result.Length, "#2");
+                       Assert.AreEqual (1, t.Result[0], "#2a");
+                       Assert.AreEqual (2, t.Result[1], "#2b");
+               }
+
+               [Test]
+               public void WhenAny_WithNull ()
+               {
+                       var tasks = new Task[] {
+                               Task.FromResult (2),
+                               null
+                       };
+
+                       try {
+                               Task.WhenAny (tasks);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentException) {
+                       }
+
+                       tasks = null;
+                       try {
+                               Task.WhenAny (tasks);
+                               Assert.Fail ("#2");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               Task.WhenAny (new Task[0]);
+                               Assert.Fail ("#3");
+                       } catch (ArgumentException) {
+                       }
+               }
+
+               [Test]
+               public void WhenAny_Start ()
+               {
+                       Task[] tasks = new[] {
+                               Task.FromResult (2),
+                       };
+
+                       var t = Task.WhenAny (tasks);
+                       Assert.AreEqual (TaskStatus.RanToCompletion, t.Status, "#1");
+
+                       try {
+                               t.Start ();
+                               Assert.Fail ("#2");
+                       } catch (InvalidOperationException) {
+                       }
+
+                       tasks = new[] {
+                               new Task (delegate { }),
+                       };
+
+                       t = Task.WhenAny (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#11");
+
+                       try {
+                               t.Start ();
+                               Assert.Fail ("#12");
+                       } catch (InvalidOperationException) {
+                       }
+               }
+
+               [Test]
+               public void WhenAny_Cancelled ()
+               {
+                       var cancelation = new CancellationTokenSource ();
+                       var tasks = new Task[] {
+                               new Task (delegate { }),
+                               new Task (delegate { }, cancelation.Token)
+                       };
+
+                       cancelation.Cancel ();
+
+                       var t = Task.WhenAny (tasks);
+                       Assert.AreEqual (TaskStatus.RanToCompletion, t.Status, "#1");
+                       tasks[0].Start ();
+
+                       Assert.IsTrue (t.Wait (1000), "#2");
+                       Assert.AreEqual (TaskStatus.Canceled, t.Result.Status, "#3");
+               }
+
+               [Test]
+               public void WhenAny_Faulted ()
+               {
+                       var tcs = new TaskCompletionSource<object> ();
+                       tcs.SetException (new ApplicationException ());
+
+                       var tcs2 = new TaskCompletionSource<object> ();
+                       tcs2.SetException (new InvalidTimeZoneException ());
+
+                       var cancelation = new CancellationTokenSource ();
+                       var tasks = new Task[] {
+                               new Task (delegate { }),
+                               tcs.Task,
+                               new Task (delegate { }, cancelation.Token),
+                               tcs2.Task
+                       };
+
+                       cancelation.Cancel ();
+
+                       var t = Task.WhenAny (tasks);
+                       Assert.AreEqual (TaskStatus.RanToCompletion, t.Status, "#1");
+                       tasks[0].Start ();
+
+                       Assert.IsTrue (t.Wait (1000), "#2");
+                       Assert.IsNull (t.Exception, "#3");
+
+                       Assert.IsInstanceOfType (typeof (ApplicationException), t.Result.Exception.InnerException, "#4");
+               }
+
+               [Test]
+               public void WhenAny ()
+               {
+                       var t1 = new Task (delegate { });
+                       var t2 = new Task (delegate { t1.Start (); });
+
+                       var tasks = new Task[] {
+                               t1,
+                               t2,
+                       };
+
+                       var t = Task.WhenAny (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#1");
+                       t2.Start ();
+
+                       Assert.IsTrue (t.Wait (1000), "#2");
+                       Assert.IsNotNull (t.Result, "#3");
+               }
+
+               [Test]
+               public void WhenAnyResult_WithNull ()
+               {
+                       var tasks = new [] {
+                               Task.FromResult (2),
+                               null
+                       };
+
+                       try {
+                               Task.WhenAny<int> (tasks);
+                               Assert.Fail ("#1");
+                       } catch (ArgumentException) {
+                       }
+
+                       tasks = null;
+                       try {
+                               Task.WhenAny<int> (tasks);
+                               Assert.Fail ("#2");
+                       } catch (ArgumentException) {
+                       }
+
+                       try {
+                               Task.WhenAny<short> (new Task<short>[0]);
+                               Assert.Fail ("#3");
+                       } catch (ArgumentException) {
+                       }
+               }
+
+               [Test]
+               public void WhenAnyResult_Start ()
+               {
+                       var tasks = new[] {
+                               Task.FromResult (2),
+                       };
+
+                       var t = Task.WhenAny<int> (tasks);
+                       Assert.AreEqual (TaskStatus.RanToCompletion, t.Status, "#1");
+
+                       try {
+                               t.Start ();
+                               Assert.Fail ("#2");
+                       } catch (InvalidOperationException) {
+                       }
+
+                       tasks = new[] {
+                               new Task<int> (delegate { return 55; }),
+                       };
+
+                       t = Task.WhenAny<int> (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#11");
+
+                       try {
+                               t.Start ();
+                               Assert.Fail ("#12");
+                       } catch (InvalidOperationException) {
+                       }
+               }
+
+               [Test]
+               public void WhenAnyResult_Cancelled ()
+               {
+                       var cancelation = new CancellationTokenSource ();
+                       var tasks = new [] {
+                               new Task<double> (delegate { return 1.1; }),
+                               new Task<double> (delegate { return -4.4; }, cancelation.Token)
+                       };
+
+                       cancelation.Cancel ();
+
+                       var t = Task.WhenAny<double> (tasks);
+                       Assert.AreEqual (TaskStatus.RanToCompletion, t.Status, "#1");
+                       tasks[0].Start ();
+
+                       Assert.IsTrue (t.Wait (1000), "#2");
+                       Assert.AreEqual (TaskStatus.Canceled, t.Result.Status, "#3");
+               }
+
+               [Test]
+               public void WhenAnyResult_Faulted ()
+               {
+                       var tcs = new TaskCompletionSource<object> ();
+                       tcs.SetException (new ApplicationException ());
+
+                       var tcs2 = new TaskCompletionSource<object> ();
+                       tcs2.SetException (new InvalidTimeZoneException ());
+
+                       var cancelation = new CancellationTokenSource ();
+                       var tasks = new Task<object>[] {
+                               new Task<object> (delegate { return null; }),
+                               tcs.Task,
+                               new Task<object> (delegate { return ""; }, cancelation.Token),
+                               tcs2.Task
+                       };
+
+                       cancelation.Cancel ();
+
+                       var t = Task.WhenAny<object> (tasks);
+                       Assert.AreEqual (TaskStatus.RanToCompletion, t.Status, "#1");
+                       tasks[0].Start ();
+
+                       Assert.IsTrue (t.Wait (1000), "#2");
+                       Assert.IsNull (t.Exception, "#3");
+
+                       Assert.IsInstanceOfType (typeof (ApplicationException), t.Result.Exception.InnerException, "#4");
+               }
+
+               [Test]
+               public void WhenAnyResult ()
+               {
+                       var t1 = new Task<byte> (delegate { return 3; });
+                       var t2 = new Task<byte> (delegate { t1.Start (); return 2; });
+
+                       var tasks = new [] {
+                               t1,
+                               t2,
+                       };
+
+                       var t = Task.WhenAny<byte> (tasks);
+                       Assert.AreEqual (TaskStatus.WaitingForActivation, t.Status, "#1");
+                       t2.Start ();
+
+                       Assert.IsTrue (t.Wait (1000), "#2");
+                       Assert.IsTrue (t.Result.Result > 1, "#3");
+               }
+
                [Test]
                public void ContinueWith_StateValue ()
                {
@@ -849,6 +1531,27 @@ namespace MonoTests.System.Threading.Tasks
                        t.Dispose ();
                }
 
+               [Test]
+               public void LongRunning ()
+               {
+                       bool? is_tp = null;
+                       bool? is_bg = null;
+                       var t = new Task (() => { is_tp = Thread.CurrentThread.IsThreadPoolThread; is_bg = Thread.CurrentThread.IsBackground; });
+                       t.Start ();
+                       Assert.IsTrue (t.Wait (100));
+                       Assert.IsTrue ((bool)is_tp, "#1");
+                       Assert.IsTrue ((bool)is_bg, "#2");
+
+                       is_tp = null;
+                       is_bg = null;
+                       t = new Task (() => { is_tp = Thread.CurrentThread.IsThreadPoolThread; is_bg = Thread.CurrentThread.IsBackground; }, TaskCreationOptions.LongRunning);
+                       t.Start ();
+
+                       Assert.IsTrue (t.Wait (100));
+                       Assert.IsFalse ((bool) is_tp, "#11");
+                       Assert.IsTrue ((bool) is_bg, "#12");
+               }
+
                [Test]
                public void Run_ArgumentCheck ()
                {
index 48543fbc3c195aabe3f0b005f3ef5a721002f12b..d6bc2e774d933f7095626b68d5adf58be308b9c9 100644 (file)
@@ -91,7 +91,7 @@ namespace MonoTests.System.Threading.Tasks
                public void FaultedFutureTest ()
                {
                        var thrown = new ApplicationException ();
-                       var f = Task<int>.Factory.StartNew (() => { throw thrown; return 42; });
+                       var f = Task<int>.Factory.StartNew (() => { throw thrown; });
                        AggregateException ex = null;
                        try {
                                f.Wait ();
index 45d9ba9a90359a1309bfe8271a335bdb17d40b1b..5d8d855ed2f72fe443f7b82767107ae278a48c1d 100644 (file)
@@ -3,6 +3,7 @@
 //
 // Authors:
 //       Marek Safar (marek.safar@gmail.com)
+//       Jeremie Laval (jeremie.laval@gmail.com)
 //
 // Copyright 2011 Xamarin, Inc (http://www.xamarin.com)
 //
@@ -320,6 +321,36 @@ namespace MonoTests.System.Threading
                        Assert.IsTrue (t.Wait (1000), "#3");
                        Assert.AreEqual (12, called, "#4");
                }
+
+               [Test]
+               public void ReEntrantRegistrationTest ()
+               {
+                       bool unregister = false;
+                       bool register = false;
+                       var source = new CancellationTokenSource ();
+                       var token = source.Token;
+
+                       var reg = new CancellationTokenRegistration ();
+                       Console.WriteLine ("Test1");
+                       token.Register (() => reg.Dispose ());
+                       reg = token.Register (() => unregister = true);
+                       token.Register (() => { Console.WriteLine ("Gnyah"); token.Register (() => register = true); });
+                       source.Cancel ();
+
+                       Assert.IsFalse (unregister);
+                       Assert.IsTrue (register);
+               }
+
+               [Test]
+               public void DisposeAfterRegistrationTest ()
+               {
+                       var source = new CancellationTokenSource ();
+                       bool ran = false;
+                       var req = source.Token.Register (() => ran = true);
+                       source.Dispose ();
+                       req.Dispose ();
+                       Assert.IsFalse (ran);
+               }
        }
 }
 
index 75b124c06117fac041468af9406112dd6a0480fd..0694ef80b63ee7808bf39187837f2dcbd9c59f8f 100644 (file)
@@ -1,7 +1,11 @@
-#if NET_4_0
 // ManualResetEventSlimTests.cs
 //
+// Authors:
+//       Marek Safar (marek.safar@gmail.com)
+//       Jeremie Laval (jeremie.laval@gmail.com)
+//
 // Copyright (c) 2008 Jérémie "Garuma" Laval
+// Copyright (c) 2012 Xamarin, Inc (http://www.xamarin.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining a copy
 // of this software and associated documentation files (the "Software"), to deal
@@ -23,6 +27,8 @@
 //
 //
 
+#if NET_4_0
+
 using System;
 using System.Threading;
 
@@ -214,6 +220,55 @@ namespace MonoTests.System.Threading
                        Assert.IsTrue (mre.WaitHandle.WaitOne (0), "#2");
                }
 
+               [Test]
+               public void WaitHandleConsistencyTest ()
+               {
+                       var mre = new ManualResetEventSlim ();
+                       mre.WaitHandle.WaitOne (0);
+
+                       for (int i = 0; i < 10000; i++) {
+                               int count = 2;
+                               SpinWait wait = new SpinWait ();
+
+                               ThreadPool.QueueUserWorkItem (_ => { mre.Set (); Interlocked.Decrement (ref count); });
+                               ThreadPool.QueueUserWorkItem (_ => { mre.Reset (); Interlocked.Decrement (ref count); });
+
+                               while (count > 0)
+                                       wait.SpinOnce ();
+                               Assert.AreEqual (mre.IsSet, mre.WaitHandle.WaitOne (0));
+                       }
+               }
+
+               [Test]
+               public void WaitWithCancellationTokenAndNotImmediateSetTest ()
+               {
+                       var mres = new ManualResetEventSlim ();
+                       var cts = new CancellationTokenSource ();
+                       ThreadPool.QueueUserWorkItem(x => { Thread.Sleep (1000); mres.Set (); });
+                       Assert.IsTrue (mres.Wait (TimeSpan.FromSeconds (10), cts.Token), "Wait returned false despite event was set.");
+               }
+
+               [Test]
+               public void WaitWithCancellationTokenAndCancel ()
+               {
+                       var mres = new ManualResetEventSlim ();
+                       var cts = new CancellationTokenSource ();
+                       ThreadPool.QueueUserWorkItem(x => { Thread.Sleep (1000); cts.Cancel (); });
+                       try {
+                               mres.Wait (TimeSpan.FromSeconds (10), cts.Token);
+                               Assert.Fail ("Wait did not throw an exception despite cancellation token was cancelled.");
+                       } catch (OperationCanceledException) {
+                       }
+               }
+
+               [Test]
+               public void WaitWithCancellationTokenAndTimeout ()
+               {
+                       var mres = new ManualResetEventSlim ();
+                       var cts = new CancellationTokenSource ();
+                       Assert.IsFalse (mres.Wait (TimeSpan.FromSeconds (1), cts.Token), "Wait returned true despite timeout.");
+               }
+
                [Test]
                public void Dispose ()
                {
index 58cdf99446e8f702894c61a0d5f5c194c4931bb5..0603d278b71fde56798d87045a3dcb4e6cf928b0 100644 (file)
@@ -1125,6 +1125,15 @@ namespace MonoTests.System.Threading
                        Thread.VolatileWrite (ref v4, float.MaxValue);
                        Assert.AreEqual (v4, float.MaxValue);
                }
+
+               [Test]
+               public void SetNameTpThread () {
+                       ThreadPool.QueueUserWorkItem(new WaitCallback(ThreadProc));
+               }
+
+               static void ThreadProc(Object stateInfo) {
+                       Thread.CurrentThread.Name = "My Worker";
+               }
        }
 
        public class TestUtil
index 3b54f990666f0a6730b17d6d9910f433ec1680aa..4954c9bf918aab60fd5a4edc214588bc811e0b49 100644 (file)
@@ -355,6 +355,18 @@ namespace MonoTests.System
                        Assert.AreEqual ("0999", t3.ToString ("yyyy"), "#B33");
                }
 
+               [Test]
+               public void TestToStringGenitive ()
+               {
+                       DateTime dt = new DateTime (2010, 1, 2, 3, 4, 5);
+                       var dtf = new CultureInfo ("cs-cz").DateTimeFormat;
+
+                       Assert.AreEqual ("2 ledna", dt.ToString ("d MMMM", dtf), "#A1");
+                       Assert.AreEqual ("2. ledna", dt.ToString ("d. MMMM", dtf), "#A2");
+                       Assert.AreEqual ("leden", dt.ToString ("MMMM", dtf), "#A4");
+                       Assert.AreEqual ("leden", dt.ToString ("MMMMMMM", dtf), "#A5");
+               }
+
                [Test]
                public void ParseExact_Format_Empty ()
                {
@@ -852,12 +864,23 @@ namespace MonoTests.System
                }
 
                [Test]
-               [Ignore ("need to fix tests that run on different timezones")]
                public void TestParse2 ()
                {
                        DateTime t1 = DateTime.Parse ("Mon, 25 Feb 2002 04:25:13 GMT");
                        t1 = TimeZone.CurrentTimeZone.ToUniversalTime(t1);
-                       Assert.AreEqual (04 - TimeZone.CurrentTimeZone.GetUtcOffset (t1).Hours, t1.Hour);
+                       Assert.AreEqual (4, t1.Hour);
+               }
+
+               [Test]
+               public void TestUtcOffset_Novell710512 ()
+               {
+                       // test for bug Novell #710512
+                       if (TimeZoneInfo.Local.BaseUtcOffset == TimeSpan.Zero)
+                               Assert.Ignore("Test doesn't apply with current time zone");
+
+                       var localTime = DateTime.Parse ("Mon, 25 Feb 2002 04:25:13 GMT");
+                       var utcTime = TimeZone.CurrentTimeZone.ToUniversalTime(localTime);
+                       Assert.AreEqual (TimeSpan.Zero, TimeZone.CurrentTimeZone.GetUtcOffset (utcTime));
                }
 
                [Test]
@@ -1235,80 +1258,6 @@ namespace MonoTests.System
                        Assert.AreEqual (0, dt.Millisecond, "#B7");
                }
 
-               [Test]
-#if NET_4_0
-               [Ignore ("Current-culture dependent test, which is not valid in 4.0 anymore")]
-#else
-               // FIXME: This test doesn't work on cultures like es-DO which have patterns
-               // for both dd/MM/yyyy & MM/dd/yyyy
-               [Category ("NotWorking")]
-#endif
-               public void Parse_Bug53023a ()
-               {
-                       foreach (CultureInfo ci in CultureInfo.GetCultures (CultureTypes.SpecificCultures)) {
-                               FormatException e = null;
-                               try {
-                                       // this fails for MOST culture under MS 1.1 SP1
-                                       DateTime.Parse ("8/16/2005", ci);
-                               }
-                               catch (FormatException fe) {
-                                       e = fe;
-                               }
-                               string c = ci.ToString ();
-                               switch (c) {
-                               case "af-ZA":
-                               case "en-CB":
-                               case "en-PH":
-                               case "en-US":
-                               case "en-ZA":
-                               case "en-ZW":
-                               case "es-PA":
-                               case "eu-ES":
-                               case "fa-IR":
-                               case "fr-CA":
-                               case "hu-HU":
-                               case "ja-JP":
-                               case "ko-KR":
-                               case "lv-LV":
-                               case "lt-LT":
-                               case "mn-MN":
-                               case "pl-PL":
-                               case "sq-AL":
-                               case "sv-SE":
-                               case "sw-KE":
-                               case "zh-CN":
-                               case "zh-TW":
-
-                               case "bo-CN": // new in 3.5?
-                               case "en-029": // new in 3.5...WTF is it?
-                               case "es-US": // new in 3.5?
-                               case "fil-PH": // new in 3.5?
-                               case "ii-CN": // new in 3.5?
-                               case "km-KH": // new in 3.5?
-                               case "mn-Mong-CN": // new in 3.5?
-                               case "moh-CA": // new in 3.5?
-                               case "ne-NP": // new in 3.5?
-                               case "ns-ZA":
-                               case "nso-ZA":
-                               case "rw-RW": // new in 3.5?
-                               case "sah-RU": // new in 3.5?
-                               case "se-SE":
-                               case "si-LK": // new in 3.5?
-                               case "sma-SE":
-                               case "smj-SE":
-                               case "tn-ZA":
-                               case "ug-CN": // new in 3.5?
-                               case "xh-ZA":
-                               case "zu-ZA":
-                                       Assert.IsNull (e, c);
-                                       break;
-                               default:
-                                       Assert.IsNotNull (e, c);
-                                       break;
-                               }
-                       }
-               }
-
                [Test]
                public void Parse_Bug53023b ()
                {
@@ -1656,12 +1605,12 @@ namespace MonoTests.System
                                        // X509Certificate pattern is _always_ accepted.
                                        stage = "1";
                                        dt = DateTime.ParseExact ("19960312183847Z", "yyyyMMddHHmmssZ", null);
-#if NET_1_1
+
                                        stage = "2";
                                        // fails with many cultures on .NET.
        //                              if (i != 127)
        //                                      dt = DateTime.Parse ("19960312183847Z");
-#endif
+
                                        stage = "3";
                                        dt = DateTime.Parse ("2004-05-26T03:29:01.1234567");
                                        stage = "4";
@@ -1716,7 +1665,7 @@ namespace MonoTests.System
                                                break;
                                        }
 
-#if NET_1_1
+
                                        // ka-GE rejects these formats under MS.NET. 
                                        // I wonder why. Also, those tests fail under .NET 1.0.
                                        if (ci.LCID != 1079) {
@@ -1732,24 +1681,10 @@ namespace MonoTests.System
                                                case 1078: // MS does not pass this culture. Dunno why.
                                                        break;
                                                default:
-#if ONLY_1_1
-                                                       // bug #58938
-                                                       stage = "12";
-                                                       dt = DateTime.Parse ("2002#02#25 19:20:00");
-                                                       // this stage fails under MS 2.0
-                                                       stage = "13";
-                                                       Assert.AreEqual (19, dt.Hour, String.Format ("bug #58938 on culture {0} {1}", ci.LCID, ci));
-#endif
                                                        break;
                                                }
                                                stage = "14";
                                                dt = DateTime.Parse ("2002-02-25 12:01:03");
-#if ONLY_1_1
-                                               stage = "15";
-                                               dt = DateTime.Parse ("2002#02#25 12:01:03");
-                                               stage = "16";
-                                               dt = DateTime.Parse ("2002%02%25 12:01:03");
-#endif
                                                stage = "17";
                                                if (ci.DateTimeFormat.TimeSeparator != ".")
                                                        dt = DateTime.Parse ("2002.02.25 12:01:03");
@@ -1768,7 +1703,6 @@ namespace MonoTests.System
                                                if (i != 1078)
                                                        Assert.AreEqual (12, dt.Hour, String.Format ("stage 18.1 RFC1123 UTC {0} {1}", i, ci));
                                        }
-#endif
                                } catch (FormatException ex) {
                                        Assert.Fail (String.Format ("stage {3}: Culture {0} {1} failed: {2}", i, ci, ex.Message, stage));
                                }
@@ -2299,8 +2233,6 @@ namespace MonoTests.System
                }
 
                [Test]
-               [Category ("NotDotNet")]
-               [Category ("NotWorking")] // wrt bug #352210
                public void KindPattern ()
                {
                        // no matter how the format string contains 'K' and the
@@ -2315,7 +2247,7 @@ namespace MonoTests.System
                        DateTime d1 = DateTime.ParseExact (s, format, ci); // d1 is parsed as a local time.
                        Assert.AreEqual (dt.Ticks, d1.ToUniversalTime ().Ticks, "#1");
                        // .NET expects Local here, while s ends with 'Z' and should be parsed as UTC.
-                       Assert.AreEqual (DateTimeKind.Utc, d1.Kind, "#2");
+                       Assert.AreEqual (DateTimeKind.Local, d1.Kind, "#2");
 
                        format = "yyyy-MM-dd'T'HH:mm:ssK";
                        ci = CultureInfo.CurrentCulture;
@@ -2459,10 +2391,10 @@ namespace MonoTests.System
                }
 
                [Test]
-               [Ignore ("This test is not international ready, probably only succeeds in the U.S.")]
                public void Parse_InvalidShortDate ()
                {
-                       DateTime expected = new DateTime (2011, 03, 22, 08, 32, 00);
+                       DateTime expected = new DateTime (2011, 03, 22, 07, 32, 00, DateTimeKind.Utc).ToLocalTime();
+                       DateTime expected2 = new DateTime (2011, 03, 22, 08, 32, 00, DateTimeKind.Utc);
 
                        string [] cultures = new string [] {"es-ES", "en-US", "en-GB", "de-DE", "fr-FR"
 #if NET_4_0
@@ -2474,21 +2406,21 @@ namespace MonoTests.System
                                CultureInfo ci = new CultureInfo (culture);
                                ci.DateTimeFormat.ShortDatePattern = "d";
 
-                               Assert.AreEqual (DateTime.Parse ("2011-03-22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), expected, "#a01 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("2011/03/22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), expected, "#a02 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("2011-03-22T08:32:00", ci, DateTimeStyles.RoundtripKind), expected, "#a03 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("2011/03/22T08:32:00", ci, DateTimeStyles.RoundtripKind), expected, "#a04 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("03/2011/22T08:32:00", ci, DateTimeStyles.RoundtripKind), expected, "#a05 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("03-2011-22T08:32:00", ci, DateTimeStyles.RoundtripKind), expected, "#a06 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("03/2011/22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), expected, "#a07 - " + culture);
+                               Assert.AreEqual (expected,  DateTime.Parse ("2011-03-22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), "#a01 - " + culture);
+                               Assert.AreEqual (expected,  DateTime.Parse ("2011/03/22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), "#a02 - " + culture);
+                               Assert.AreEqual (expected2, DateTime.Parse ("2011-03-22T08:32:00", ci, DateTimeStyles.RoundtripKind), "#a03 - " + culture);
+                               Assert.AreEqual (expected2, DateTime.Parse ("2011/03/22T08:32:00", ci, DateTimeStyles.RoundtripKind), "#a04 - " + culture);
+                               Assert.AreEqual (expected2, DateTime.Parse ("03/2011/22T08:32:00", ci, DateTimeStyles.RoundtripKind), "#a05 - " + culture);
+                               Assert.AreEqual (expected2, DateTime.Parse ("03-2011-22T08:32:00", ci, DateTimeStyles.RoundtripKind), "#a06 - " + culture);
+                               Assert.AreEqual (expected,  DateTime.Parse ("03/2011/22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), "#a07 - " + culture);
                                ci.DateTimeFormat.DateSeparator = "%";
-                               Assert.AreEqual (DateTime.Parse ("2011-03-22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), expected, "#b01 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("2011/03/22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), expected, "#b02 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("2011-03-22T08:32:00", ci, DateTimeStyles.RoundtripKind), expected, "#b03 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("2011/03/22T08:32:00", ci, DateTimeStyles.RoundtripKind), expected, "#b04 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("03/2011/22T08:32:00", ci, DateTimeStyles.RoundtripKind), expected, "#b05 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("03-2011-22T08:32:00", ci, DateTimeStyles.RoundtripKind), expected, "#b06 - " + culture);
-                               Assert.AreEqual (DateTime.Parse ("03/2011/22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), expected, "#b07 - " + culture);
+                               Assert.AreEqual (expected,  DateTime.Parse ("2011-03-22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), "#b01 - " + culture);
+                               Assert.AreEqual (expected,  DateTime.Parse ("2011/03/22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), "#b02 - " + culture);
+                               Assert.AreEqual (expected2, DateTime.Parse ("2011-03-22T08:32:00", ci, DateTimeStyles.RoundtripKind), "#b03 - " + culture);
+                               Assert.AreEqual (expected2, DateTime.Parse ("2011/03/22T08:32:00", ci, DateTimeStyles.RoundtripKind), "#b04 - " + culture);
+                               Assert.AreEqual (expected2, DateTime.Parse ("03/2011/22T08:32:00", ci, DateTimeStyles.RoundtripKind), "#b05 - " + culture);
+                               Assert.AreEqual (expected2, DateTime.Parse ("03-2011-22T08:32:00", ci, DateTimeStyles.RoundtripKind), "#b06 - " + culture);
+                               Assert.AreEqual (expected,  DateTime.Parse ("03/2011/22 08:32:00+01:00", ci, DateTimeStyles.RoundtripKind), "#b07 - " + culture);
                        }
                }
 
index dd6d8db1edf8826b943451fe346cfcc63102c773..3133ebf8d06684f892b186ced974e783e3ac163f 100644 (file)
@@ -629,6 +629,7 @@ namespace MonoTests.System
                }
 
                [Test]
+               [SetCulture("en-US")]
                public void TestConstructDouble ()
                {
                        Decimal d;
@@ -1067,6 +1068,7 @@ namespace MonoTests.System
                }
 
                [Test]
+               [SetCulture("en-US")]
                public void ToString_Defaults ()
                {
                        Decimal d = 254.9m;
@@ -1110,8 +1112,23 @@ namespace MonoTests.System
                        decimal d = Decimal.Parse ("9223372036854775808.0000000009", CultureInfo.InvariantCulture);
                        long l = (long) d;
                }
-
-#if NET_2_0
+/* Not yet fixed
+               [Test]
+               public void ParseEmptyNumberGroupSeparator ()
+               {
+                       CultureInfo originalCulture = CultureInfo.CurrentCulture;
+                       Thread.CurrentThread.CurrentCulture = new CultureInfo ("en-US");
+                       try {
+                               var nf = new NumberFormatInfo ();
+                               nf.NumberDecimalSeparator = ".";
+                               nf.NumberGroupSeparator = "";
+                               decimal d = decimal.Parse ("4.5", nf);
+                               Assert.AreEqual (4.5, d);
+                       } finally {
+                               Thread.CurrentThread.CurrentCulture = originalCulture;
+                       }
+               }
+*/
                [Test]
                [Category ("TargetJvmNotWorking")]
                public void TryParse ()
@@ -1130,7 +1147,6 @@ namespace MonoTests.System
                                        NumberFormatInfo.InvariantInfo, out r));
                        }
                }
-#endif
 
                [Test]
                [ExpectedException (typeof (DivideByZeroException))]
@@ -1156,17 +1172,11 @@ namespace MonoTests.System
                        Assert.AreEqual (-12.1m, Decimal.Remainder (n2, p1), "-12.1 % 254.9");
                        Assert.AreEqual (12.1m, Decimal.Remainder (p2, n1), "12.1 % -254.9");
                        Assert.AreEqual (-12.1m, Decimal.Remainder (n2, n1), "-12.1 % -254.9");
-#if NET_2_0
+
                        Assert.AreEqual (0.0m, Decimal.Remainder (p1, p1), "12.1 % 12.1");
                        Assert.AreEqual (0.0m, Decimal.Remainder (n1, p1), "-12.1 % 12.1");
                        Assert.AreEqual (0.0m, Decimal.Remainder (p1, n1), "12.1 % -12.1");
                        Assert.AreEqual (0.0m, Decimal.Remainder (n1, n1), "-12.1 % -12.1");
-#else
-                       Assert.AreEqual (0, Decimal.Remainder (p1, p1), "12.1 % 12.1");
-                       Assert.AreEqual (0, Decimal.Remainder (n1, p1), "-12.1 % 12.1");
-                       Assert.AreEqual (0, Decimal.Remainder (p1, n1), "12.1 % -12.1");
-                       Assert.AreEqual (0, Decimal.Remainder (n1, n1), "-12.1 % -12.1");
-#endif
                }
 
                [Test]
@@ -1367,6 +1377,7 @@ namespace MonoTests.System
                }
 
                [Test] // bug #59425
+               [SetCulture("en-US")]
                public void ParseAndKeepPrecision ()
                {
                        string value = "5";
@@ -1387,6 +1398,7 @@ namespace MonoTests.System
                }
 
                [Test]
+               [SetCulture("en-US")]
                public void ToString_G ()
                {
                        Assert.AreEqual ("1.0", (1.0m).ToString (), "00");
@@ -1420,7 +1432,6 @@ namespace MonoTests.System
                        Assert.AreEqual ("0.0000000000000000000000000001", (0.0000000000000000000000000001m).ToString (), "28");
                }
 
-#if NET_2_0
                [Test]
                public void MidpointRoundingAwayFromZero ()
                {
@@ -1443,6 +1454,5 @@ namespace MonoTests.System
                        Assert.AreEqual (-2.1M, Math.Round (-2.08M, 1, m), "#15");
                        Assert.AreEqual (-3.1M, Math.Round (-3.05M, 1, m), "#16");
                }
-#endif
        }
 }
index b9b852e800022722eaf61e032ce44018e5b097a3..edd94252d1266fc950897c7b6ac2fe444746eb7d 100644 (file)
@@ -46,7 +46,7 @@ namespace MonoTests.System
                };
 
                [SetUp]
-               public void GetReady ()
+               public void Setup ()
                {
                        string sep = NumberFormatInfo.CurrentInfo.NumberDecimalSeparator;
                        string_values = new string [15];
@@ -224,11 +224,12 @@ namespace MonoTests.System
                [Test]
                public void ParseAllowWhitespaces ()
                {
+                       var nf = CultureInfo.CurrentCulture.NumberFormat;
                        NumberStyles style = NumberStyles.Float;
                        double.Parse (" 32 ");
-                       double.Parse ("  Infinity  ");
-                       double.Parse ("  -Infinity  ");
-                       double.Parse ("  NaN  ");
+                       double.Parse (string.Format ("  {0}  ", nf.PositiveInfinitySymbol));
+                       double.Parse (string.Format ("  {0}  ", nf.NegativeInfinitySymbol));
+                       double.Parse (string.Format ("  {0}  ", nf.NaNSymbol));
                }
 
                [Test] // bug #81630
@@ -552,13 +553,7 @@ namespace MonoTests.System
                }
 
                [Test]
-#if NET_2_0
                [ExpectedException (typeof (ArgumentException))]
-#else
-               [Category ("NotWorking")]
-               // MS accept hex values under 1.x but the results neither match the long value
-               // nor the value of a 64bits double
-#endif
                public void HexNumber_WithHexToParse ()
                {
                        // from bug #72221
@@ -568,13 +563,7 @@ namespace MonoTests.System
                }
 
                [Test]
-#if NET_2_0
                [ExpectedException (typeof (ArgumentException))]
-#else
-               [Category ("NotWorking")]
-               // MS accept hex values under 1.x but the results neither match the long value
-               // nor the value of a 64bits double
-#endif
                public void HexNumber_NoHexToParse ()
                {
                        double d;
@@ -597,10 +586,8 @@ namespace MonoTests.System
                        Assert.IsFalse (Double.TryParse ("string", NumberStyles.Any, null, out value), "#1");
                        Assert.IsFalse (Double.TryParse ("with whitespace", NumberStyles.Any, null, out value), "#2");
                        
-#if NET_2_0
                        Assert.IsFalse (Double.TryParse ("string", out value), "#3");
                        Assert.IsFalse (Double.TryParse ("with whitespace", out value), "#4");
-#endif
                }
 
                                        
@@ -614,10 +601,24 @@ namespace MonoTests.System
                                double d = double.Parse ("$4.56", NumberStyles.Currency, f);
                                Assert.AreEqual (4.56, d);
                        } finally {
-                               // restore original culture
                                Thread.CurrentThread.CurrentCulture = originalCulture;
                        }
+               }
 
+               [Test]
+               public void ParseEmptyNumberGroupSeparator ()
+               {
+                       CultureInfo originalCulture = CultureInfo.CurrentCulture;
+                       Thread.CurrentThread.CurrentCulture = new CultureInfo ("en-US");
+                       try {
+                               var nf = new NumberFormatInfo ();
+                               nf.NumberDecimalSeparator = ".";
+                               nf.NumberGroupSeparator = "";
+                               double d = double.Parse ("4.5", nf);
+                               Assert.AreEqual (4.5, d);
+                       } finally {
+                               Thread.CurrentThread.CurrentCulture = originalCulture;
+                       }
                }
        }
 }
index ea8219572b80b649eea4268ccbee87d119292f26..b2d596b551eb543afa8732795308f05096f01c5f 100644 (file)
@@ -180,7 +180,7 @@ namespace MonoTests.System {
                        Assert.IsFalse (g1.Equals ((object)"This is not a Guid!"), "A5");
                }
 
-#if NET_2_0
+
                [Test]
                public void EqualsGuid ()
                {
@@ -194,7 +194,6 @@ namespace MonoTests.System {
                        Assert.IsFalse (g1.Equals (null), "A4");
                        Assert.IsFalse (g1.Equals ("This is not a Guid!"), "A5");
                }
-#endif
 
                [Test]
                public void CompareToObject ()
@@ -221,7 +220,6 @@ namespace MonoTests.System {
                        Guid.Empty.CompareTo ("Say what?");
                }
 
-#if NET_2_0
                [Test]
                public void CompareToGuid ()
                {
@@ -238,7 +236,18 @@ namespace MonoTests.System {
                        Assert.IsTrue (g4.CompareTo (g1) > 0, "A6");
                        Assert.IsTrue (g1.CompareTo (g1) == 0, "A7");
                }
-#endif
+
+               [Test]
+               public void CompareToGuid_2 ()
+               {
+                       var g1 = new Guid ("d1c5088bc188464fb77b0fd2be2d005e");
+                       var g2 = new Guid ("d2c5088bc188464fb77b0fd2be2d005e");
+                       var g3 = new Guid ("00c5088bc188464fb77b0fd2be2d005e");
+
+                       Assert.AreEqual (-1, g1.CompareTo (g2), "#1");
+                       Assert.AreEqual (1, g1.CompareTo (g3), "#2");
+                       Assert.AreEqual (1, g1.CompareTo (Guid.Empty), "#3");
+               }
 
                [Test]
                public void GetHashCode_Same ()
@@ -274,14 +283,20 @@ namespace MonoTests.System {
                        Assert.AreEqual ("00010203-0405-0607-0809-0a0b0c0d0e0f", g.ToString (""), "A6");
                        Assert.AreEqual ("00010203-0405-0607-0809-0a0b0c0d0e0f", g.ToString ((string)null), "A7");
                        Assert.AreEqual ("{00010203-0405-0607-0809-0a0b0c0d0e0f}", g.ToString ("B", null), "A10");
+#if NET_4_0
+                       Assert.AreEqual ("{0x00010203,0x0405,0x0607,{0x08,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f}}", g.ToString ("x"), "A11");
+                       Assert.AreEqual ("{0x00010203,0x0405,0x0607,{0x08,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f}}", g.ToString ("X"), "A11");
+#endif
                }
 
+#if !NET_4_0
                [Test]
                [ExpectedException (typeof (FormatException))]
                public void ToString_UnsupportedFormat ()
                {
                        new Guid (0x00010203, 0x0405, 0x0607, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f).ToString ("X");
                }
+#endif
 
                [Test]
                [ExpectedException (typeof (FormatException))]
@@ -348,9 +363,15 @@ namespace MonoTests.System {
                        guid = Guid.ParseExact ("00010203-0405-0607-0809-0a0b0c0d0e0f", "D");
                        Assert.AreEqual (expected, guid.ToString ());
 
+                       guid = Guid.ParseExact ("00010203-0405-0607-0809-0a0b0c0d0e0f", "d");
+                       Assert.AreEqual (expected, guid.ToString ());
+
                        guid = Guid.ParseExact ("{00010203-0405-0607-0809-0A0B0C0D0E0F}", "B");
                        Assert.AreEqual (expected, guid.ToString ());
 
+                       guid = Guid.ParseExact ("{00010203-0405-0607-0809-0A0B0C0D0E0F}", "b");
+                       Assert.AreEqual (expected, guid.ToString ());
+
                        guid = Guid.ParseExact ("(00010203-0405-0607-0809-0A0B0C0D0E0F)", "P");
                        Assert.AreEqual (expected, guid.ToString ());
 
index eefee47f55e6904e19f8e5e66e0276928ce23758..126c46917b0db515fafb610e55475457de61a674 100644 (file)
@@ -178,6 +178,7 @@ public class Int16Test
                Assert.AreEqual (20, Int16.Parse ("2E1", NumberStyles.AllowExponent), "A#2");
                Assert.AreEqual (200, Int16.Parse ("2E2", NumberStyles.AllowExponent), "A#3");
                Assert.AreEqual (200, Int16.Parse ("2E+2", NumberStyles.AllowExponent), "A#4");
+               Assert.AreEqual (2, Int16.Parse ("2", NumberStyles.AllowExponent), "A#5");
 
                try {
                        Int16.Parse ("2E");
@@ -221,6 +222,12 @@ public class Int16Test
                        Assert.Fail ("B#7");
                } catch (OverflowException) {
                }
+               
+               try {
+                       Int16.Parse ("2 math e1", NumberStyles.AllowExponent);
+                       Assert.Fail ("B#8");
+               } catch (FormatException) {
+               }
        }
 
        [Test]
index e8aada6dd665a716a889afb9da0f4c332aad72a9..60c756a903431d66a9a99774520b7b700833cad2 100644 (file)
@@ -273,6 +273,7 @@ public class Int32Test
                Assert.AreEqual (200, Int32.Parse ("2E2", NumberStyles.AllowExponent), "A#3");
                Assert.AreEqual (2000000, Int32.Parse ("2E6", NumberStyles.AllowExponent), "A#4");
                Assert.AreEqual (200, Int32.Parse ("2E+2", NumberStyles.AllowExponent), "A#5");
+               Assert.AreEqual (2, Int32.Parse ("2", NumberStyles.AllowExponent), "A#6");
 
                try {
                        Int32.Parse ("2E");
@@ -316,6 +317,12 @@ public class Int32Test
                        Assert.Fail ("B#7");
                } catch (OverflowException) {
                }
+
+               try {
+                       Int32.Parse ("2 math e1", NumberStyles.AllowExponent);
+                       Assert.Fail ("B#8");
+               } catch (FormatException) {
+               }
        }
 
        [Test]
index 428757d64b167260ab73df9aefcdb4a65ecc3877..b1b6b079b40e13beb8f68e50c98b76e32af8576e 100644 (file)
@@ -329,6 +329,7 @@ public class Int64Test
                Assert.AreEqual (200, long.Parse ("2E2", NumberStyles.AllowExponent), "A#3");
                Assert.AreEqual (2000000, long.Parse ("2E6", NumberStyles.AllowExponent), "A#4");
                Assert.AreEqual (200, long.Parse ("2E+2", NumberStyles.AllowExponent), "A#5");
+               Assert.AreEqual (2, long.Parse ("2", NumberStyles.AllowExponent), "A#6");
 
                try {
                        long.Parse ("2E");
@@ -372,6 +373,12 @@ public class Int64Test
                        Assert.Fail ("B#7");
                } catch (OverflowException) {
                }
+               
+               try {
+                       long.Parse ("2 math e1", NumberStyles.AllowExponent);
+                       Assert.Fail ("B#8");
+               } catch (FormatException) {
+               }
        }
 
        [Test]
index 521f41f1bbcfe68ace1f4bcc9e7874ccf1afa283..4aaa735e6631332a3d3a0f4b71b492bc68375a2a 100644 (file)
@@ -2954,19 +2954,20 @@ namespace MonoTests.System
                [Test]
                public void TestNaNToString ()
                {
-                       Assert.AreEqual ("Infinity", Double.PositiveInfinity.ToString(), "#01");
-                       Assert.AreEqual ("-Infinity", Double.NegativeInfinity.ToString(), "#02");
-                       Assert.AreEqual ("NaN", Double.NaN.ToString(), "#03");
-                       Assert.AreEqual ("Infinity", Single.PositiveInfinity.ToString(), "#04");
-                       Assert.AreEqual ("-Infinity", Single.NegativeInfinity.ToString(), "#05");
-                       Assert.AreEqual ("NaN", Single.NaN.ToString(), "#06");
-
-                       Assert.AreEqual ("Infinity", Double.PositiveInfinity.ToString("R"), "#07");
-                       Assert.AreEqual ("-Infinity", Double.NegativeInfinity.ToString("R"), "#08");
-                       Assert.AreEqual ("NaN", Double.NaN.ToString("R"), "#09");
-                       Assert.AreEqual ("Infinity", Single.PositiveInfinity.ToString("R"), "#10");
-                       Assert.AreEqual ("-Infinity", Single.NegativeInfinity.ToString("R"), "#11");
-                       Assert.AreEqual ("NaN", Single.NaN.ToString("R"), "#12");
+                       var nfi = CultureInfo.CurrentCulture.NumberFormat;
+                       Assert.AreEqual (nfi.PositiveInfinitySymbol, Double.PositiveInfinity.ToString(), "#01");
+                       Assert.AreEqual (nfi.NegativeInfinitySymbol, Double.NegativeInfinity.ToString(), "#02");
+                       Assert.AreEqual (nfi.NaNSymbol, Double.NaN.ToString(), "#03");
+                       Assert.AreEqual (nfi.PositiveInfinitySymbol, Single.PositiveInfinity.ToString(), "#04");
+                       Assert.AreEqual (nfi.NegativeInfinitySymbol, Single.NegativeInfinity.ToString(), "#05");
+                       Assert.AreEqual (nfi.NaNSymbol, Single.NaN.ToString(), "#06");
+
+                       Assert.AreEqual (nfi.PositiveInfinitySymbol, Double.PositiveInfinity.ToString("R"), "#07");
+                       Assert.AreEqual (nfi.NegativeInfinitySymbol, Double.NegativeInfinity.ToString("R"), "#08");
+                       Assert.AreEqual (nfi.NaNSymbol, Double.NaN.ToString("R"), "#09");
+                       Assert.AreEqual (nfi.PositiveInfinitySymbol, Single.PositiveInfinity.ToString("R"), "#10");
+                       Assert.AreEqual (nfi.NegativeInfinitySymbol, Single.NegativeInfinity.ToString("R"), "#11");
+                       Assert.AreEqual (nfi.NaNSymbol, Single.NaN.ToString("R"), "#12");
                }
 
                [Test]
index 80be31b69fe839edb0b57cbd7ac017c1ab5c00c1..1ae388d1f3697b5ef9db1055b19bc348eb67cded 100644 (file)
@@ -118,18 +118,18 @@ namespace MonoTests.System
                        string posInf = float.PositiveInfinity.ToString ("r");
 
                        float result;
-                       Assert.IsTrue (float.TryParse (maxVal, NumberStyles.Float, CultureInfo.InvariantCulture, out result), "MaxValue#1a");
+                       Assert.IsTrue (float.TryParse (maxVal, NumberStyles.Float, CultureInfo.CurrentCulture, out result), "MaxValue#1a");
                        Assert.AreEqual (float.MaxValue, result, "MaxValue#1b");
-                       Assert.IsTrue (float.TryParse (minVal, NumberStyles.Float, CultureInfo.InvariantCulture, out result), "MinValue#1a");
+                       Assert.IsTrue (float.TryParse (minVal, NumberStyles.Float, CultureInfo.CurrentCulture, out result), "MinValue#1a");
                        Assert.AreEqual (float.MinValue, result, "MinValue#1b");
-                       Assert.IsTrue (float.TryParse (epsilon, NumberStyles.Float, CultureInfo.InvariantCulture, out result), "Epsilon#1a");
+                       Assert.IsTrue (float.TryParse (epsilon, NumberStyles.Float, CultureInfo.CurrentCulture, out result), "Epsilon#1a");
                        Assert.AreEqual (float.Epsilon, result, "Epsilon#1b");
-                       Assert.IsTrue (float.TryParse (nan, NumberStyles.Float, CultureInfo.InvariantCulture, out result), "NaN#1a");
+                       Assert.IsTrue (float.TryParse (nan, NumberStyles.Float, CultureInfo.CurrentCulture, out result), "NaN#1a");
                        Assert.AreEqual (float.NaN, result, "NaN#1b");
                        Assert.IsNaN (result, "NaN#1c");
-                       Assert.IsTrue (float.TryParse (negInf, NumberStyles.Float, CultureInfo.InvariantCulture, out result), "-Inf#1a");
+                       Assert.IsTrue (float.TryParse (negInf, NumberStyles.Float, CultureInfo.CurrentCulture, out result), "-Inf#1a");
                        Assert.AreEqual (float.NegativeInfinity, result, "-Inf#1b");
-                       Assert.IsTrue (float.TryParse (posInf, NumberStyles.Float, CultureInfo.InvariantCulture, out result), "+Inf#1a");
+                       Assert.IsTrue (float.TryParse (posInf, NumberStyles.Float, CultureInfo.CurrentCulture, out result), "+Inf#1a");
                        Assert.AreEqual (float.PositiveInfinity, result, "+Inf#1b");
 
                        Assert.AreEqual (float.MaxValue, float.Parse (maxVal), "MaxValue#2");
@@ -140,13 +140,13 @@ namespace MonoTests.System
                        Assert.AreEqual (float.NegativeInfinity, float.Parse (negInf), "-Inf#2");
                        Assert.AreEqual (float.PositiveInfinity, float.Parse (posInf), "+Inf#2");
 
-                       Assert.AreEqual (float.MaxValue, float.Parse (maxVal, CultureInfo.InvariantCulture), "MaxValue#3");
-                       Assert.AreEqual (float.MinValue, float.Parse (minVal, CultureInfo.InvariantCulture), "MinValue#3");
-                       Assert.AreEqual (float.Epsilon, float.Parse (epsilon, CultureInfo.InvariantCulture), "Epsilon#3");
-                       Assert.AreEqual (float.NaN, float.Parse (nan, CultureInfo.InvariantCulture), "NaN#3a");
-                       Assert.IsNaN (float.Parse (nan, CultureInfo.InvariantCulture), "NaN#3b");
-                       Assert.AreEqual (float.NegativeInfinity, float.Parse (negInf, CultureInfo.InvariantCulture), "-Inf#3");
-                       Assert.AreEqual (float.PositiveInfinity, float.Parse (posInf, CultureInfo.InvariantCulture), "+Inf#3");
+                       Assert.AreEqual (float.MaxValue, float.Parse (maxVal, CultureInfo.CurrentCulture), "MaxValue#3");
+                       Assert.AreEqual (float.MinValue, float.Parse (minVal, CultureInfo.CurrentCulture), "MinValue#3");
+                       Assert.AreEqual (float.Epsilon, float.Parse (epsilon, CultureInfo.CurrentCulture), "Epsilon#3");
+                       Assert.AreEqual (float.NaN, float.Parse (nan, CultureInfo.CurrentCulture), "NaN#3a");
+                       Assert.IsNaN (float.Parse (nan, CultureInfo.CurrentCulture), "NaN#3b");
+                       Assert.AreEqual (float.NegativeInfinity, float.Parse (negInf, CultureInfo.CurrentCulture), "-Inf#3");
+                       Assert.AreEqual (float.PositiveInfinity, float.Parse (posInf, CultureInfo.CurrentCulture), "+Inf#3");
 
                        Assert.AreEqual (float.MaxValue, float.Parse (maxVal, NumberStyles.Float), "MaxValue#4");
                        Assert.AreEqual (float.MinValue, float.Parse (minVal, NumberStyles.Float), "MinValue#4");
@@ -156,13 +156,13 @@ namespace MonoTests.System
                        Assert.AreEqual (float.NegativeInfinity, float.Parse (negInf, NumberStyles.Float), "-Inf#4");
                        Assert.AreEqual (float.PositiveInfinity, float.Parse (posInf, NumberStyles.Float), "+Inf#4");
 
-                       Assert.AreEqual (float.MaxValue, float.Parse (maxVal, NumberStyles.Float, CultureInfo.InvariantCulture), "MaxValue#5");
-                       Assert.AreEqual (float.MinValue, float.Parse (minVal, NumberStyles.Float, CultureInfo.InvariantCulture), "MinValue#5");
-                       Assert.AreEqual (float.Epsilon, float.Parse (epsilon, NumberStyles.Float, CultureInfo.InvariantCulture), "Epsilon#5");
-                       Assert.AreEqual (float.NaN, float.Parse (nan, NumberStyles.Float, CultureInfo.InvariantCulture), "NaN#5a");
-                       Assert.IsNaN (float.Parse (nan, NumberStyles.Float, CultureInfo.InvariantCulture), "NaN#5b");
-                       Assert.AreEqual (float.NegativeInfinity, float.Parse (negInf, NumberStyles.Float, CultureInfo.InvariantCulture), "-Inf#5");
-                       Assert.AreEqual (float.PositiveInfinity, float.Parse (posInf, NumberStyles.Float, CultureInfo.InvariantCulture), "+Inf#5");
+                       Assert.AreEqual (float.MaxValue, float.Parse (maxVal, NumberStyles.Float, CultureInfo.CurrentCulture), "MaxValue#5");
+                       Assert.AreEqual (float.MinValue, float.Parse (minVal, NumberStyles.Float, CultureInfo.CurrentCulture), "MinValue#5");
+                       Assert.AreEqual (float.Epsilon, float.Parse (epsilon, NumberStyles.Float, CultureInfo.CurrentCulture), "Epsilon#5");
+                       Assert.AreEqual (float.NaN, float.Parse (nan, NumberStyles.Float, CultureInfo.CurrentCulture), "NaN#5a");
+                       Assert.IsNaN (float.Parse (nan, NumberStyles.Float, CultureInfo.CurrentCulture), "NaN#5b");
+                       Assert.AreEqual (float.NegativeInfinity, float.Parse (negInf, NumberStyles.Float, CultureInfo.CurrentCulture), "-Inf#5");
+                       Assert.AreEqual (float.PositiveInfinity, float.Parse (posInf, NumberStyles.Float, CultureInfo.CurrentCulture), "+Inf#5");
                }
 
 #if NET_2_0
index f2c23ac6a6268568fadb44c0aaebefe8fd0cccda..402c6d88c1b567bdc09db4b1c3943b3e7a37da91 100644 (file)
@@ -4133,6 +4133,10 @@ public class StringTest
                Assert.AreEqual (2, res.Length, "#11-09-3");
 
                Assert.AreEqual (0, "    ".Split ((char[]) null, 2, StringSplitOptions.RemoveEmptyEntries).Length, "#12-00-0");
+               
+               res = "not found".Split (new char[2]);
+               Assert.AreEqual ("not found", res[0], "#12-04-27");
+               Assert.AreEqual (1, res.Length, "#12-04-27-A");
        }
        
        [Test]
index 593010f203bb57ca58ae22fa86bf466f884215bd..16037987260b263bf88a4ecd80c85b836171e50b 100644 (file)
@@ -115,7 +115,7 @@ public class TimeZoneTest {
                // we change our implementation to match theirs?
                
                Assert.AreEqual("GMT", t1.StandardName, "D01");
-               Assert.AreEqual("BST", t1.DaylightName, "D02");
+               Assert.IsTrue("BST" == t1.DaylightName || "IST" == t1.DaylightName, "D02");
        
                DaylightTime d1 = t1.GetDaylightChanges (2002);
                Assert.AreEqual("03/31/2002 01:00:00", d1.Start.ToString ("G"), "D03");
index 0c55f99e7362b297e355337ed983bf159533d6c6..154f085d71436b10d26fdb0394eae89dfb638a77 100644 (file)
@@ -178,6 +178,7 @@ public class UInt16Test
                Assert.AreEqual (20, UInt16.Parse ("2E1", NumberStyles.AllowExponent), "A#2");
                Assert.AreEqual (200, UInt16.Parse ("2E2", NumberStyles.AllowExponent), "A#3");
                Assert.AreEqual (200, UInt16.Parse ("2E+2", NumberStyles.AllowExponent), "A#4");
+               Assert.AreEqual (2, UInt16.Parse ("2", NumberStyles.AllowExponent), "A#5");
 
                try {
                        UInt16.Parse ("2E");
@@ -221,6 +222,12 @@ public class UInt16Test
                        Assert.Fail ("B#7");
                } catch (OverflowException) {
                }
+               
+               try {
+                       UInt16.Parse ("2 math e1", NumberStyles.AllowExponent);
+                       Assert.Fail ("B#8");
+               } catch (FormatException) {
+               }
        }
 
        [Test]
index 3a97250cf5295ab3e4d58e654070026d1921cdf9..24396d72484c3aaea7f35c6788e60daa206d71a3 100644 (file)
@@ -213,6 +213,7 @@ public class UInt32Test
                Assert.AreEqual (200, uint.Parse ("2E2", NumberStyles.AllowExponent), "A#3");
                Assert.AreEqual (2000000, uint.Parse ("2E6", NumberStyles.AllowExponent), "A#4");
                Assert.AreEqual (200, uint.Parse ("2E+2", NumberStyles.AllowExponent), "A#5");
+               Assert.AreEqual (2, uint.Parse ("2", NumberStyles.AllowExponent), "A#6");
 
                try {
                        uint.Parse ("2E");
@@ -256,6 +257,12 @@ public class UInt32Test
                        Assert.Fail ("B#7");
                } catch (OverflowException) {
                }
+               
+               try {
+                       uint.Parse ("2 math e1", NumberStyles.AllowExponent);
+                       Assert.Fail ("B#8");
+               } catch (FormatException) {
+               }
        }
 
        [Test]
index c1713b08ec72dfe391b841f57f753421182e813e..335d216a4fc2b0b67666bf14c6188d79b154b352 100644 (file)
@@ -202,6 +202,7 @@ public class UInt64Test
                Assert.AreEqual (200, ulong.Parse ("2E2", NumberStyles.AllowExponent), "A#3");
                Assert.AreEqual (2000000, ulong.Parse ("2E6", NumberStyles.AllowExponent), "A#4");
                Assert.AreEqual (200, ulong.Parse ("2E+2", NumberStyles.AllowExponent), "A#5");
+               Assert.AreEqual (2, ulong.Parse ("2", NumberStyles.AllowExponent), "A#6");
 
                try {
                        ulong.Parse ("2E");
@@ -245,6 +246,12 @@ public class UInt64Test
                        Assert.Fail ("B#7");
                } catch (OverflowException) {
                }
+               
+               try {
+                       ulong.Parse ("2 math e1", NumberStyles.AllowExponent);
+                       Assert.Fail ("B#8");
+               } catch (FormatException) {
+               }
        }
 
        [Test]
diff --git a/mcs/class/corlib/Test/ms_run_test.sh b/mcs/class/corlib/Test/ms_run_test.sh
deleted file mode 100755 (executable)
index a8c81e3..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/bin/sh
-
-if [ $# -eq 0 ]; then
-       echo "You should give a list of test names such as: "
-       echo "$0 System.IO.FileTest System.Text.StringBuilderTest"
-       echo "or"
-       echo "$0 System.AllTests"
-       echo "and so on..."
-       exit 1
-fi
-
-topdir=../../..
-NUNITCONSOLE=$topdir/nunit20/nunit-console.exe
-MONO_PATH=$topdir/nunit20:.
-
-for i in $@; do
-       MONO_PATH=$MONO_PATH \
-               ${NUNITCONSOLE} corlib_reference.dll /fixture:MonoTests.${i}
-done
-
diff --git a/mcs/class/corlib/Test/run_test.sh b/mcs/class/corlib/Test/run_test.sh
deleted file mode 100755 (executable)
index 4a5fd5e..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/bin/sh
-
-if [ $# -eq 0 ]; then
-       echo "You should give a list of test names such as: "
-       echo "$0 System.IO.FileTest System.Text.StringBuilderTest"
-       echo "or"
-       echo "$0 System.AllTests"
-       echo "or"
-       echo "$0 all"
-       echo "and so on..."
-       exit 1
-fi
-
-topdir=../../..
-NUNITCONSOLE=$topdir/class/lib/net_2_0/nunit-console.exe
-MONO_PATH=$topdir/nunit20:$topdir/class/lib:.
-
-for i in $@; do
-       if [ "$i" = "all" ]; then
-               fixture=""
-       else
-               fixture="/fixture:MonoTests.${i}"
-       fi
-       MONO_PATH=$MONO_PATH \
-               mono --debug ${NUNITCONSOLE} corlib_test.dll $fixture
-done
-
index c56aab37f6e5b2cae18fb5b6e7efc4c3dc5c986a..b3b5f8e08e1321b67dea207a32685dad28d20141 100644 (file)
    <Compile Include="System.Globalization\NumberStyles.cs" />
    <Compile Include="System.Globalization\PersianCalendar.cs" />
    <Compile Include="System.Globalization\RegionInfo.cs" />
+   <Compile Include="System.Globalization\RegionInfo.MonoTouch.cs" />
    <Compile Include="System.Globalization\StringInfo.cs" />
    <Compile Include="System.Globalization\TaiwanCalendar.cs" />
    <Compile Include="System.Globalization\TaiwanLunisolarCalendar.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvFastcall.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvThiscall.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvStdcall.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerFilePathAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerLineNumberAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerMemberNameAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilationRelaxations.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilationRelaxationsAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilerGeneratedAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\FixedAddressValueTypeAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\FixedBufferAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\HasCopySemanticsAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\IAsyncStateMachine.cs" />
+   <Compile Include="System.Runtime.CompilerServices\ICriticalNotifyCompletion.cs" />
    <Compile Include="System.Runtime.CompilerServices\IDispatchConstantAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IUnknownConstantAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IndexerNameAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\INotifyCompletion.cs" />
    <Compile Include="System.Runtime.CompilerServices\InternalsVisibleToAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IsBoxed.cs" />
    <Compile Include="System.Runtime.CompilerServices\IsByValue.cs" />
    <Compile Include="System.Threading.Tasks\Task_T.cs" />
    <Compile Include="System.Threading.Tasks\Task.cs" />
    <Compile Include="System.Threading.Tasks\TaskCompletionQueue.cs" />
-   <Compile Include="System.Threading.Tasks\EventSlots.cs" />
    <Compile Include="System.Threading.Tasks\TaskExceptionSlot.cs" />
    <Compile Include="System.Threading.Tasks\TaskActionInvoker.cs" />
    <Compile Include="System.Threading.Tasks\TaskDebuggerView.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-    \r
+\r
   </ItemGroup>\r
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
index f1f6bb91007f5765bd918a2fe4e40468fdb09abe..d98cf16dc328d6ef94e11848b67dcf04453f88ff 100644 (file)
    <Compile Include="System.Globalization\NumberStyles.cs" />
    <Compile Include="System.Globalization\PersianCalendar.cs" />
    <Compile Include="System.Globalization\RegionInfo.cs" />
+   <Compile Include="System.Globalization\RegionInfo.MonoTouch.cs" />
    <Compile Include="System.Globalization\StringInfo.cs" />
    <Compile Include="System.Globalization\TaiwanCalendar.cs" />
    <Compile Include="System.Globalization\TaiwanLunisolarCalendar.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvFastcall.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvThiscall.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvStdcall.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerFilePathAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerLineNumberAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerMemberNameAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilationRelaxations.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilationRelaxationsAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilerGeneratedAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\FixedAddressValueTypeAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\FixedBufferAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\HasCopySemanticsAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\IAsyncStateMachine.cs" />
+   <Compile Include="System.Runtime.CompilerServices\ICriticalNotifyCompletion.cs" />
    <Compile Include="System.Runtime.CompilerServices\IDispatchConstantAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IUnknownConstantAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IndexerNameAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\INotifyCompletion.cs" />
    <Compile Include="System.Runtime.CompilerServices\InternalsVisibleToAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IsBoxed.cs" />
    <Compile Include="System.Runtime.CompilerServices\IsByValue.cs" />
    <Compile Include="System.Threading.Tasks\Task_T.cs" />
    <Compile Include="System.Threading.Tasks\Task.cs" />
    <Compile Include="System.Threading.Tasks\TaskCompletionQueue.cs" />
-   <Compile Include="System.Threading.Tasks\EventSlots.cs" />
    <Compile Include="System.Threading.Tasks\TaskExceptionSlot.cs" />
    <Compile Include="System.Threading.Tasks\TaskActionInvoker.cs" />
    <Compile Include="System.Threading.Tasks\TaskDebuggerView.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-    \r
+\r
   </ItemGroup>\r
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
index bf7418a01ea96af04a19554b723a20b7531df382..22c4076028237e81e069d8407a997ba5370bdb6d 100644 (file)
    <Compile Include="System.Globalization\NumberStyles.cs" />
    <Compile Include="System.Globalization\PersianCalendar.cs" />
    <Compile Include="System.Globalization\RegionInfo.cs" />
+   <Compile Include="System.Globalization\RegionInfo.MonoTouch.cs" />
    <Compile Include="System.Globalization\StringInfo.cs" />
    <Compile Include="System.Globalization\TaiwanCalendar.cs" />
    <Compile Include="System.Globalization\TaiwanLunisolarCalendar.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvFastcall.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvThiscall.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvStdcall.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerFilePathAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerLineNumberAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerMemberNameAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilationRelaxations.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilationRelaxationsAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilerGeneratedAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\FixedAddressValueTypeAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\FixedBufferAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\HasCopySemanticsAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\IAsyncStateMachine.cs" />
+   <Compile Include="System.Runtime.CompilerServices\ICriticalNotifyCompletion.cs" />
    <Compile Include="System.Runtime.CompilerServices\IDispatchConstantAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IUnknownConstantAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IndexerNameAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\INotifyCompletion.cs" />
    <Compile Include="System.Runtime.CompilerServices\InternalsVisibleToAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IsBoxed.cs" />
    <Compile Include="System.Runtime.CompilerServices\IsByValue.cs" />
    <Compile Include="System.Threading.Tasks\Task_T.cs" />
    <Compile Include="System.Threading.Tasks\Task.cs" />
    <Compile Include="System.Threading.Tasks\TaskCompletionQueue.cs" />
-   <Compile Include="System.Threading.Tasks\EventSlots.cs" />
    <Compile Include="System.Threading.Tasks\TaskExceptionSlot.cs" />
    <Compile Include="System.Threading.Tasks\TaskActionInvoker.cs" />
    <Compile Include="System.Threading.Tasks\TaskDebuggerView.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-    \r
+\r
   </ItemGroup>\r
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
index ed0cfbb97a24a198025fb5611f765f472c8c0ac9..de034957b89a2932ef48a42fd0dd6fd6d482e0ec 100644 (file)
    <Compile Include="System.Globalization\NumberStyles.cs" />
    <Compile Include="System.Globalization\PersianCalendar.cs" />
    <Compile Include="System.Globalization\RegionInfo.cs" />
+   <Compile Include="System.Globalization\RegionInfo.MonoTouch.cs" />
    <Compile Include="System.Globalization\StringInfo.cs" />
    <Compile Include="System.Globalization\TaiwanCalendar.cs" />
    <Compile Include="System.Globalization\TaiwanLunisolarCalendar.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvFastcall.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvThiscall.cs" />
    <Compile Include="System.Runtime.CompilerServices\CallConvStdcall.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerFilePathAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerLineNumberAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\CallerMemberNameAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilationRelaxations.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilationRelaxationsAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\CompilerGeneratedAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\FixedAddressValueTypeAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\FixedBufferAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\HasCopySemanticsAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\IAsyncStateMachine.cs" />
+   <Compile Include="System.Runtime.CompilerServices\ICriticalNotifyCompletion.cs" />
    <Compile Include="System.Runtime.CompilerServices\IDispatchConstantAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IUnknownConstantAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IndexerNameAttribute.cs" />
+   <Compile Include="System.Runtime.CompilerServices\INotifyCompletion.cs" />
    <Compile Include="System.Runtime.CompilerServices\InternalsVisibleToAttribute.cs" />
    <Compile Include="System.Runtime.CompilerServices\IsBoxed.cs" />
    <Compile Include="System.Runtime.CompilerServices\IsByValue.cs" />
    <Compile Include="System.Threading.Tasks\Task_T.cs" />
    <Compile Include="System.Threading.Tasks\Task.cs" />
    <Compile Include="System.Threading.Tasks\TaskCompletionQueue.cs" />
-   <Compile Include="System.Threading.Tasks\EventSlots.cs" />
    <Compile Include="System.Threading.Tasks\TaskExceptionSlot.cs" />
    <Compile Include="System.Threading.Tasks\TaskActionInvoker.cs" />
    <Compile Include="System.Threading.Tasks\TaskDebuggerView.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-    \r
+\r
   </ItemGroup>\r
   <ItemGroup>\r
     <Folder Include="Properties\" />\r
index aec6f833dbbf5decb8d297f1b5efe6b3ee621f16..0d4b62688d2d7db46fbc567f3be556b1ac04ea4f 100644 (file)
@@ -96,7 +96,6 @@
    <Compile Include="Test\System\DecimalTest2.cs" />
    <Compile Include="Test\System\DecimalTest.cs" />
    <Compile Include="Test\System.Diagnostics\DebuggerDisplayAttributeTest.cs" />
-   <Compile Include="Test\System.Diagnostics\DebugTest.cs" />
    <Compile Include="Test\System.Diagnostics\StackFrameTest.cs" />
    <Compile Include="Test\System.Diagnostics\StackTraceTest.cs" />
    <Compile Include="Test\System.Diagnostics.Contracts\ContractAssertTest.cs" />
    <Compile Include="Test\System.Security.Cryptography\TripleDESTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509CapiTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509CertificateTest.cs" />
-   <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Cert20Test.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509SpcTest.cs" />
    <Compile Include="Test\System.Security\HostSecurityManagerTest.cs" />
    <Compile Include="Test\System.Security\NamedPermissionSetTest.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="./../../class/lib/net_2_0/mscorlib.dll">
+    <Reference Include="./../../class/lib/net_2_0/mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_2_0/mscorlib.dll</HintPath>
     </Reference>
-    <Reference Include="./../../class/lib/net_2_0/Mono.Posix.dll">
+    <Reference Include="Mono.Posix.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>./../../class/lib/net_2_0/Mono.Posix.dll</HintPath>
+      <HintPath>Mono.Posix.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="nunit.framework" />
 \r
index 1f4944d72b2794295d85efe7456abb6ae22569dd..ac2578eeacd7e4eb462097f0f9c6872ed3fa4c2a 100644 (file)
@@ -96,7 +96,6 @@
    <Compile Include="Test\System\DecimalTest2.cs" />
    <Compile Include="Test\System\DecimalTest.cs" />
    <Compile Include="Test\System.Diagnostics\DebuggerDisplayAttributeTest.cs" />
-   <Compile Include="Test\System.Diagnostics\DebugTest.cs" />
    <Compile Include="Test\System.Diagnostics\StackFrameTest.cs" />
    <Compile Include="Test\System.Diagnostics\StackTraceTest.cs" />
    <Compile Include="Test\System.Diagnostics.Contracts\ContractAssertTest.cs" />
    <Compile Include="Test\System.Security.Cryptography\TripleDESTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509CapiTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509CertificateTest.cs" />
-   <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Cert20Test.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509SpcTest.cs" />
    <Compile Include="Test\System.Security\HostSecurityManagerTest.cs" />
    <Compile Include="Test\System.Security\NamedPermissionSetTest.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="./../../class/lib/net_4_0/mscorlib.dll">
+    <Reference Include="./../../class/lib/net_4_0/mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_0/mscorlib.dll</HintPath>
     </Reference>
-    <Reference Include="./../../class/lib/net_4_0/Mono.Posix.dll">
+    <Reference Include="Mono.Posix.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>./../../class/lib/net_4_0/Mono.Posix.dll</HintPath>
+      <HintPath>Mono.Posix.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="nunit.framework" />
 \r
index a6374a6ae8717055e82c39296a48f62903c7f644..211d47884653cce011f2ad73ba7f6d7d188aa569 100644 (file)
@@ -96,7 +96,6 @@
    <Compile Include="Test\System\DecimalTest2.cs" />
    <Compile Include="Test\System\DecimalTest.cs" />
    <Compile Include="Test\System.Diagnostics\DebuggerDisplayAttributeTest.cs" />
-   <Compile Include="Test\System.Diagnostics\DebugTest.cs" />
    <Compile Include="Test\System.Diagnostics\StackFrameTest.cs" />
    <Compile Include="Test\System.Diagnostics\StackTraceTest.cs" />
    <Compile Include="Test\System.Diagnostics.Contracts\ContractAssertTest.cs" />
    <Compile Include="Test\System.Security.Cryptography\TripleDESTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509CapiTest.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509CertificateTest.cs" />
-   <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509Cert20Test.cs" />
    <Compile Include="Test\System.Security.Cryptography.X509Certificates\X509SpcTest.cs" />
    <Compile Include="Test\System.Security\HostSecurityManagerTest.cs" />
    <Compile Include="Test\System.Security\NamedPermissionSetTest.cs" />
     <PreBuildEvent></PreBuildEvent>\r
   </PropertyGroup>\r
   <ItemGroup>\r
-        <Reference Include="./../../class/lib/net_4_5/mscorlib.dll">
+    <Reference Include="./../../class/lib/net_4_5/mscorlib.dll">
       <SpecificVersion>False</SpecificVersion>
       <HintPath>./../../class/lib/net_4_5/mscorlib.dll</HintPath>
     </Reference>
-    <Reference Include="./../../class/lib/net_4_5/Mono.Posix.dll">
+    <Reference Include="Mono.Posix.dll">
       <SpecificVersion>False</SpecificVersion>
-      <HintPath>./../../class/lib/net_4_5/Mono.Posix.dll</HintPath>
+      <HintPath>Mono.Posix.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Core.dll">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>System.Core.dll</HintPath>
     </Reference>
     <Reference Include="nunit.framework" />
 \r
index fdb8dbfe09392fc4b8007fa0d3293564b895e449..0da21c0a27fd586fcff0db62d6477a354fc15352 100644 (file)
@@ -1573,7 +1573,6 @@ System.Threading.Tasks/TaskCanceledException.cs
 System.Threading.Tasks/Task_T.cs
 System.Threading.Tasks/Task.cs
 System.Threading.Tasks/TaskCompletionQueue.cs
-System.Threading.Tasks/EventSlots.cs
 System.Threading.Tasks/TaskExceptionSlot.cs
 System.Threading.Tasks/TaskActionInvoker.cs
 System.Threading.Tasks/TaskDebuggerView.cs
index da2f57c46a1d810932922bea328bd786d8bb5814..66997062e59d43228a68e279b85edab76e949df9 100644 (file)
@@ -56,7 +56,6 @@ System/DecimalFormatterTest.cs
 System/DecimalTest2.cs
 System/DecimalTest.cs
 System.Diagnostics/DebuggerDisplayAttributeTest.cs
-System.Diagnostics/DebugTest.cs
 System.Diagnostics/StackFrameTest.cs
 System.Diagnostics/StackTraceTest.cs
 System.Diagnostics.Contracts/ContractAssertTest.cs
@@ -268,7 +267,6 @@ System.Security.Cryptography/TripleDESCryptoServiceProviderTest.cs
 System.Security.Cryptography/TripleDESTest.cs
 System.Security.Cryptography.X509Certificates/X509CapiTest.cs
 System.Security.Cryptography.X509Certificates/X509CertificateTest.cs
-System.Security.Cryptography.X509Certificates/X509Cert20Test.cs
 System.Security.Cryptography.X509Certificates/X509SpcTest.cs
 System.Security/HostSecurityManagerTest.cs
 System.Security/NamedPermissionSetTest.cs
diff --git a/mcs/errors/CS0012-14-lib.il b/mcs/errors/CS0012-14-lib.il
new file mode 100644 (file)
index 0000000..4a3d3ea
--- /dev/null
@@ -0,0 +1,36 @@
+.assembly extern mscorlib
+{
+}
+
+.assembly extern 'CS0012-lib-missing'
+{
+}
+
+.assembly 'CS0012-14-lib'
+{
+  .hash algorithm 0x00008004
+  .ver 0:0:0:0
+}
+
+.module 'CS0012-14-lib.dll'
+
+.class public auto ansi beforefieldinit B
+       extends [mscorlib]System.Object
+{
+  .method public hidebysig static void  Foo(object o) cil managed
+  {
+    ret
+  }
+
+  .method public hidebysig static void  Foo<(['CS0012-lib-missing']AA) T>(!!T t) cil managed
+  {
+    ret
+  }
+
+  .method public hidebysig specialname rtspecialname 
+          instance void  .ctor() cil managed
+  {
+    ret
+  }
+
+}
diff --git a/mcs/errors/CS0012-15-lib.il b/mcs/errors/CS0012-15-lib.il
new file mode 100644 (file)
index 0000000..c920670
--- /dev/null
@@ -0,0 +1,31 @@
+.assembly extern mscorlib
+{
+}
+
+.assembly extern 'CS0012-lib-missing'
+{
+}
+
+.assembly 'CS0012-15-lib'
+{
+  .hash algorithm 0x00008004
+  .ver 0:0:0:0
+}
+
+.module 'CS0012-15-lib.dll'
+
+.class public auto ansi beforefieldinit B
+       extends [mscorlib]System.Object
+{
+  .method public hidebysig static void  Foo<(['CS0012-lib-missing']AA) T>(!!T t) cil managed
+  {
+    ret
+  }
+
+  .method public hidebysig specialname rtspecialname 
+          instance void  .ctor() cil managed
+  {
+    ret
+  }
+
+}
diff --git a/mcs/errors/CS0012-16-lib.il b/mcs/errors/CS0012-16-lib.il
new file mode 100644 (file)
index 0000000..fc95fe3
--- /dev/null
@@ -0,0 +1,36 @@
+.assembly extern mscorlib
+{
+}
+
+.assembly extern 'CS0012-lib-missing'
+{
+}
+
+.assembly 'CS0012-16-lib'
+{
+  .hash algorithm 0x00008004
+  .ver 0:0:0:0
+}
+
+.module 'CS0012-16-lib.dll'
+
+.class public auto ansi beforefieldinit B
+       extends [mscorlib]System.Object
+{
+  .method public hidebysig static void  Foo(object o) cil managed
+  {
+    ret
+  }
+
+  .method public hidebysig static void  Foo(class ['CS0012-lib-missing']AA t) cil managed
+  {
+    ret
+  }
+
+  .method public hidebysig specialname rtspecialname 
+          instance void  .ctor() cil managed
+  {
+    ret
+  }
+
+}
diff --git a/mcs/errors/CS0101-7-2.cs b/mcs/errors/CS0101-7-2.cs
new file mode 100644 (file)
index 0000000..ef22a69
--- /dev/null
@@ -0,0 +1 @@
+class Test {}
index f4a9efb5c117716927aa06dabe6d916c82eaea03..57ff9ef44909738d6632f1a0b9f7145c014f8eeb 100644 (file)
@@ -21,7 +21,7 @@ DISTFILES = \
        $(wildcard dlls/second/*.cs)
 
 TEST_SUPPORT_FILES = \
-       CS0012-lib.dll CS0012-2-lib.dll CS0012-3-lib.dll CS0012-4-lib.dll CS0012-5-lib.dll CS0012-6-lib.dll CS0012-9-lib.dll CS0012-10-lib.dll CS0012-11-lib.dll CS0012-12-lib.dll CS0012-13-lib.dll CS0029-26-lib.dll \
+       CS0012-lib.dll CS0012-2-lib.dll CS0012-3-lib.dll CS0012-4-lib.dll CS0012-5-lib.dll CS0012-6-lib.dll CS0012-9-lib.dll CS0012-10-lib.dll CS0012-11-lib.dll CS0012-12-lib.dll CS0012-13-lib.dll CS0012-14-lib.dll CS0012-15-lib.dll CS0012-16-lib.dll CS0029-26-lib.dll \
        CS0103-2-lib.dll CS0118-2-lib.dll CS0122-10-lib.dll CS0122-14-lib.dll CS0122-15-lib.dll CS0122-19-lib.dll CS0122-35-lib.dll CS0122-36-lib.dll CS0143-lib.dll CS0144-3-lib.dll CS0165-19-lib.dll \
        CS0205-3-lib.dll CS0229-3-lib.dll CS0229-4-lib.dll CS0266-25-lib.dll \
        CS0315-2-lib.dll \
diff --git a/mcs/errors/cs0012-14.cs b/mcs/errors/cs0012-14.cs
new file mode 100644 (file)
index 0000000..d6c858a
--- /dev/null
@@ -0,0 +1,11 @@
+// CS0012: The type `AA' is defined in an assembly that is not referenced. Consider adding a reference to assembly `CS0012-lib-missing, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'
+// Line: 9
+// Compiler options: -r:CS0012-14-lib.dll
+
+class Test
+{
+       public static void Main ()
+       {
+               B.Foo (new Test ());
+       }
+}
diff --git a/mcs/errors/cs0012-15.cs b/mcs/errors/cs0012-15.cs
new file mode 100644 (file)
index 0000000..1428df2
--- /dev/null
@@ -0,0 +1,11 @@
+// CS0012: The type `AA' is defined in an assembly that is not referenced. Consider adding a reference to assembly `CS0012-lib-missing, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'
+// Line: 9
+// Compiler options: -r:CS0012-15-lib.dll
+
+class Test
+{
+       public static void Main ()
+       {
+               B.Foo<long> (1);
+       }
+}
diff --git a/mcs/errors/cs0012-16.cs b/mcs/errors/cs0012-16.cs
new file mode 100644 (file)
index 0000000..bf71e94
--- /dev/null
@@ -0,0 +1,11 @@
+// CS0012: The type `AA' is defined in an assembly that is not referenced. Consider adding a reference to assembly `CS0012-lib-missing, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'
+// Line: 9
+// Compiler options: -r:CS0012-16-lib.dll
+
+class Test
+{
+       public static void Main ()
+       {
+               B.Foo (new Test ());
+       }
+}
diff --git a/mcs/errors/cs0023-18.cs b/mcs/errors/cs0023-18.cs
new file mode 100644 (file)
index 0000000..be5a73d
--- /dev/null
@@ -0,0 +1,10 @@
+// CS0023: The `-' operator cannot be applied to operand of type `ulong'
+// Line: 8
+
+class X
+{
+       public static void Main ()
+       {
+               object o = -(9223372036854775808);
+       }
+}
diff --git a/mcs/errors/cs0101-7.cs b/mcs/errors/cs0101-7.cs
new file mode 100644 (file)
index 0000000..90cf116
--- /dev/null
@@ -0,0 +1,5 @@
+// CS0101: The namespace `global::' already contains a definition for `Test'
+// Line: 5
+// Compiler options: CS0101-7-2.cs
+
+class Test {}
diff --git a/mcs/errors/cs0118-16.cs b/mcs/errors/cs0118-16.cs
new file mode 100644 (file)
index 0000000..7b4d857
--- /dev/null
@@ -0,0 +1,14 @@
+// CS0118: `X.Foo' is a `property' but a `method group' was expected
+// Line: 12
+
+class X
+{
+       static int Foo {
+               get { return 1; }
+       }
+
+       static void Main ()
+       {
+               Foo (1);
+       }
+}
diff --git a/mcs/errors/cs0120-18.cs b/mcs/errors/cs0120-18.cs
new file mode 100644 (file)
index 0000000..a4aefc7
--- /dev/null
@@ -0,0 +1,23 @@
+// CS0120: An object reference is required to access non-static member `Derived.Foo()'
+// Line: 16
+
+using System;
+
+public class Base
+{
+       public Base (Action a)
+       {
+       }
+}
+
+public class Derived : Base
+{
+       public Derived ()
+               : base (() => Foo ())
+       {
+       }
+
+       void Foo ()
+       {
+       }
+}
\ No newline at end of file
diff --git a/mcs/errors/cs0453-8.cs b/mcs/errors/cs0453-8.cs
new file mode 100644 (file)
index 0000000..f94f320
--- /dev/null
@@ -0,0 +1,16 @@
+// CS0453: The type `dynamic' must be a non-nullable value type in order to use it as type parameter `T' in the generic type or method `Tester.Foo<T>(T)'
+// Line: 10
+
+class Tester
+{
+       static void Foo<T> (T t) where T : struct
+       {
+       }
+       
+       public static int Main ()
+       {
+               dynamic d = 1;
+               Foo<dynamic>(d);
+               return 0;
+       }
+}
diff --git a/mcs/errors/cs0516-2.cs b/mcs/errors/cs0516-2.cs
new file mode 100644 (file)
index 0000000..ed6f4d7
--- /dev/null
@@ -0,0 +1,10 @@
+// CS0516: Constructor `A<T>.A(T)' cannot call itself
+// Line: 7
+
+public class A<T>
+{
+       public A (T i)
+               : this (i)
+       {
+       }
+}
diff --git a/mcs/errors/cs0649-5.cs b/mcs/errors/cs0649-5.cs
new file mode 100644 (file)
index 0000000..2077869
--- /dev/null
@@ -0,0 +1,25 @@
+// CS0649: Field `TestClass.b' is never assigned to, and will always have its default value
+// Line: 12
+// Compiler options: -warnaserror -warn:4
+
+public struct Bar
+{
+       public int x;
+}
+
+public class TestClass
+{
+       Bar b;
+
+       public bool Foo ()
+       {
+               if (b.x == 0)
+                       return false;
+
+               return true;
+       }
+
+       public static void Main ()
+       {
+       }
+}
diff --git a/mcs/errors/cs0839.cs b/mcs/errors/cs0839.cs
deleted file mode 100644 (file)
index 76285fc..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-// CS0839: An argument is missing
-// Line: 12
-
-class Test
-{
-       static void Foo (int a, bool b)
-       {
-       }
-
-       static void Main ()
-       {
-               Foo (1, );
-       }
-}
diff --git a/mcs/errors/cs1525-43.cs b/mcs/errors/cs1525-43.cs
new file mode 100644 (file)
index 0000000..a43ae1d
--- /dev/null
@@ -0,0 +1,9 @@
+// CS1525: Unexpected symbol `)', expecting `[', `out', `params', `ref', `this', or `type'
+// Line: 6
+
+class TestClass
+{
+       TestClass ([attr])
+       {
+       }
+}
diff --git a/mcs/errors/cs1525-44.cs b/mcs/errors/cs1525-44.cs
new file mode 100644 (file)
index 0000000..d2bb1d2
--- /dev/null
@@ -0,0 +1,12 @@
+// CS1525: Unexpected symbol `}'
+// Line: 10
+
+using System;
+
+class Foo
+{
+       void Bar ()
+       {
+               throw new Exception ("e",
+       }
+}
diff --git a/mcs/errors/cs1525-45.cs b/mcs/errors/cs1525-45.cs
new file mode 100644 (file)
index 0000000..f18b770
--- /dev/null
@@ -0,0 +1,14 @@
+// CS1525: Unexpected symbol `)'
+// Line: 12
+
+class Test
+{
+       static void Foo (int a, bool b)
+       {
+       }
+
+       static void Main ()
+       {
+               Foo (1, );
+       }
+}
diff --git a/mcs/errors/cs1525-46.cs b/mcs/errors/cs1525-46.cs
new file mode 100644 (file)
index 0000000..87e31f3
--- /dev/null
@@ -0,0 +1,9 @@
+// CS1525: Unexpected symbol `;', expecting `(', `[', or `{'
+// Line: 7
+
+class X {
+       static void Main ()
+       {
+               X x = new X;
+       }
+}
diff --git a/mcs/errors/cs1525-47.cs b/mcs/errors/cs1525-47.cs
new file mode 100644 (file)
index 0000000..81bc9ec
--- /dev/null
@@ -0,0 +1,10 @@
+// CS1525: Unexpected symbol `}', expecting `:'
+// Line: 8
+
+class Test
+{
+       void Foo ()
+       {
+               a = cond ? expr
+       }
+}
diff --git a/mcs/errors/cs1526.cs b/mcs/errors/cs1526.cs
deleted file mode 100644 (file)
index 4005ace..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-// CS1526: Unexpected symbol `;', expecting `(', `[', or `{'
-// Line: 7
-
-class X {
-       static void Main ()
-       {
-               X x = new X;
-       }
-}
diff --git a/mcs/errors/cs1691-4.cs b/mcs/errors/cs1691-4.cs
new file mode 100644 (file)
index 0000000..cd9ce64
--- /dev/null
@@ -0,0 +1,4 @@
+// CS1691: `20' is not a valid warning number
+// Line: 0
+// Compiler options: -warnaserror -nowarn:20
+
diff --git a/mcs/errors/cs2021-2.cs b/mcs/errors/cs2021-2.cs
new file mode 100644 (file)
index 0000000..3ecec8e
--- /dev/null
@@ -0,0 +1,3 @@
+// CS2021: Output file name is not valid
+// Line: 0
+// Compiler options: -out:/
diff --git a/mcs/errors/cs2021.cs b/mcs/errors/cs2021.cs
new file mode 100644 (file)
index 0000000..b9547af
--- /dev/null
@@ -0,0 +1,3 @@
+// CS2021: Output file name is not valid
+// Line: 0
+// Compiler options: -out:.dll
index 730ef09dd696d544d91c1bdd4f0dd9b7c0725048..74609852fe32e3009e4eb7271ed9506894839499 100644 (file)
@@ -46,7 +46,7 @@ dist-local: dist-default
 test-local run-test-local run-test-ondotnet-local doc-update-local:
 
 jay: $(sources:.c=.o)
-       $(CCOMPILE) -o $@ $^
+       $(CCOMPILE) $(LDFLAGS) -o $@ $^
 
 %.o: %.c
        $(CCOMPILE) -c -o $@ $^
index b419da06762f81cd77fb75cf8ca9e35e433efc07..0b7a645c46140a6ff2aa97c978754c8d0fd0f954 100644 (file)
@@ -219,6 +219,7 @@ namespace Mono.CSharp {
 
                // A list of hoisted parameters
                protected List<HoistedParameter> hoisted_params;
+               List<HoistedParameter> hoisted_local_params;
                protected List<HoistedVariable> hoisted_locals;
 
                // Hoisted this
@@ -227,6 +228,8 @@ namespace Mono.CSharp {
                // Local variable which holds this storey instance
                public Expression Instance;
 
+               bool initialize_hoisted_this;
+
                public AnonymousMethodStorey (ExplicitBlock block, TypeDefinition parent, MemberBase host, TypeParameters tparams, string name, MemberKind kind)
                        : base (parent, MakeMemberName (host, name, parent.Module.CounterAnonymousContainers, tparams, block.StartLocation),
                                tparams, 0, kind)
@@ -239,17 +242,9 @@ namespace Mono.CSharp {
                {
                        TypeExpr type_expr = new TypeExpression (ec.CurrentType, Location);
                        Field f = AddCompilerGeneratedField ("$this", type_expr);
-                       f.Define ();
                        hoisted_this = new HoistedThis (this, f);
 
-                       // Inflated type instance has to be updated manually
-                       if (Instance.Type is InflatedTypeSpec) {
-                               var inflator = new TypeParameterInflator (this, Instance.Type, TypeParameterSpec.EmptyTypes, TypeSpec.EmptyTypes);
-                               Instance.Type.MemberCache.AddMember (f.Spec.InflateMember (inflator));
-
-                               inflator = new TypeParameterInflator (this, f.Parent.CurrentType, TypeParameterSpec.EmptyTypes, TypeSpec.EmptyTypes);
-                               f.Parent.CurrentType.MemberCache.AddMember (f.Spec.InflateMember (inflator));
-                       }
+                       initialize_hoisted_this = true;
                }
 
                public Field AddCapturedVariable (string name, TypeSpec type)
@@ -319,6 +314,12 @@ namespace Mono.CSharp {
                        }
 
                        var hoisted = localVariable.HoistedVariant;
+                       if (hoisted != null && hoisted.Storey != this && hoisted.Storey is StateMachine) {
+                               // TODO: It's too late the field is defined in HoistedLocalVariable ctor
+                               hoisted.Storey.hoisted_locals.Remove (hoisted);
+                               hoisted = null;
+                       }
+
                        if (hoisted == null) {
                                hoisted = new HoistedLocalVariable (this, localVariable, GetVariableMangledName (localVariable));
                                localVariable.HoistedVariant = hoisted;
@@ -329,7 +330,7 @@ namespace Mono.CSharp {
                                hoisted_locals.Add (hoisted);
                        }
 
-                       if (ec.CurrentBlock.Explicit != localVariable.Block.Explicit)
+                       if (ec.CurrentBlock.Explicit != localVariable.Block.Explicit && !(hoisted.Storey is StateMachine))
                                hoisted.Storey.AddReferenceFromChildrenBlock (ec.CurrentBlock.Explicit);
                }
 
@@ -340,16 +341,46 @@ namespace Mono.CSharp {
                        }
 
                        var hoisted = parameterInfo.Parameter.HoistedVariant;
+
+                       if (parameterInfo.Block.StateMachine != null) {
+                               //
+                               // Another storey in same block exists but state machine does not
+                               // have parameter captured. We need to add it there as well to
+                               // proxy parameter value correctly.
+                               //
+                               if (hoisted == null && parameterInfo.Block.StateMachine != this) {
+                                       var storey = parameterInfo.Block.StateMachine;
+
+                                       hoisted = new HoistedParameter (storey, parameterReference);
+                                       parameterInfo.Parameter.HoistedVariant = hoisted;
+
+                                       if (storey.hoisted_params == null)
+                                               storey.hoisted_params = new List<HoistedParameter> ();
+
+                                       storey.hoisted_params.Add (hoisted);
+                               }
+
+                               //
+                               // Lift captured parameter from value type storey to reference type one. Otherwise
+                               // any side effects would be done on a copy
+                               //
+                               if (hoisted != null && hoisted.Storey != this && hoisted.Storey is StateMachine) {
+                                       if (hoisted_local_params == null)
+                                               hoisted_local_params = new List<HoistedParameter> ();
+
+                                       hoisted_local_params.Add (hoisted);
+                                       hoisted = null;
+                               }
+                       }
+
                        if (hoisted == null) {
-                               var storey = parameterInfo.Block.StateMachine ?? this;
-                               var hp = new HoistedParameter (storey, parameterReference);
-                               hoisted = hp;
+                               hoisted = new HoistedParameter (this, parameterReference);
                                parameterInfo.Parameter.HoistedVariant = hoisted;
 
-                               if (storey.hoisted_params == null)
-                                       storey.hoisted_params = new List<HoistedParameter> (2);
+                               if (hoisted_params == null)
+                                       hoisted_params = new List<HoistedParameter> ();
 
-                               storey.hoisted_params.Add (hp);
+                               hoisted_params.Add (hoisted);
                        }
 
                        //
@@ -456,7 +487,7 @@ namespace Mono.CSharp {
                        // When the current context is async (or iterator) lift local storey
                        // instantiation to the currect storey
                        //
-                       if (ec.CurrentAnonymousMethod is StateMachineInitializer) {
+                       if (ec.CurrentAnonymousMethod is StateMachineInitializer && (block.HasYield || block.HasAwait)) {
                                //
                                // Unfortunately, normal capture mechanism could not be used because we are
                                // too late in the pipeline and standart assign cannot be used either due to
@@ -515,10 +546,10 @@ namespace Mono.CSharp {
                        }
 
                        //
-                       // Define hoisted `this' in top-level storey only 
+                       // Initialize hoisted `this' only once, everywhere else will be
+                       // referenced indirectly
                        //
-                       if (OriginalSourceBlock.HasCapturedThis && !(Parent is AnonymousMethodStorey)) {
-                               AddCapturedThisField (ec);
+                       if (initialize_hoisted_this) {
                                rc.CurrentBlock.AddScopeStatement (new ThisInitializer (hoisted_this));
                        }
 
@@ -535,9 +566,20 @@ namespace Mono.CSharp {
                        ec.CurrentAnonymousMethod = ae;
                }
 
-               protected virtual void EmitHoistedParameters (EmitContext ec, IList<HoistedParameter> hoisted)
+               protected virtual void EmitHoistedParameters (EmitContext ec, List<HoistedParameter> hoisted)
                {
                        foreach (HoistedParameter hp in hoisted) {
+                               //
+                               // Parameters could be proxied via local fields for value type storey
+                               //
+                               if (hoisted_local_params != null) {
+                                       var local_param = hoisted_local_params.Find (l => l.Parameter.Parameter == hp.Parameter.Parameter);
+                                       var source = new FieldExpr (local_param.Field, Location);
+                                       source.InstanceExpression = new CompilerGeneratedThis (CurrentType, Location);
+                                       hp.EmitAssign (ec, source, false, false);
+                                       continue;
+                               }
+
                                hp.EmitHoistingAssignment (ec);
                        }
                }
@@ -610,7 +652,12 @@ namespace Mono.CSharp {
                }
 
                public HoistedThis HoistedThis {
-                       get { return hoisted_this; }
+                       get {
+                               return hoisted_this;
+                       }
+                       set {
+                               hoisted_this = value;
+                       }
                }
 
                public IList<ExplicitBlock> ReferencesFromChildrenBlock {
@@ -654,7 +701,7 @@ namespace Mono.CSharp {
                        public override void Emit (EmitContext ec)
                        {
                                ResolveContext rc = new ResolveContext (ec.MemberContext);
-                               Expression e = hv.GetFieldExpression (ec).CreateExpressionTree (rc);
+                               Expression e = hv.GetFieldExpression (ec).CreateExpressionTree (rc, false);
                                // This should never fail
                                e = e.Resolve (rc);
                                if (e != null)
@@ -765,7 +812,7 @@ namespace Mono.CSharp {
 
        public class HoistedParameter : HoistedVariable
        {
-               sealed class HoistedFieldAssign : Assign
+               sealed class HoistedFieldAssign : CompilerAssign
                {
                        public HoistedFieldAssign (Expression target, Expression source)
                                : base (target, source, source.Location)
@@ -796,23 +843,32 @@ namespace Mono.CSharp {
                        this.parameter = hp.parameter;
                }
 
+               #region Properties
+
                public Field Field {
                        get {
                                return field;
                        }
                }
 
+               public ParameterReference Parameter {
+                       get {
+                               return parameter;
+                       }
+               }
+
+               #endregion
+
                public void EmitHoistingAssignment (EmitContext ec)
                {
                        //
                        // Remove hoisted redirection to emit assignment from original parameter
                        //
-                       HoistedVariable temp = parameter.Parameter.HoistedVariant;
+                       var temp = parameter.Parameter.HoistedVariant;
                        parameter.Parameter.HoistedVariant = null;
 
-                       Assign a = new HoistedFieldAssign (GetFieldExpression (ec), parameter);
-                       if (a.Resolve (new ResolveContext (ec.MemberContext)) != null)
-                               a.EmitStatement (ec);
+                       var a = new HoistedFieldAssign (GetFieldExpression (ec), parameter);
+                       a.EmitStatement (ec);
 
                        parameter.Parameter.HoistedVariant = temp;
                }
@@ -904,6 +960,10 @@ namespace Mono.CSharp {
                        }
                }
 
+               public ReportPrinter TypeInferenceReportPrinter {
+                       get; set;
+               }
+
                #endregion
 
                //
@@ -914,7 +974,13 @@ namespace Mono.CSharp {
                {
                        using (ec.With (ResolveContext.Options.InferReturnType, false)) {
                                using (ec.Set (ResolveContext.Options.ProbingMode)) {
-                                       return Compatible (ec, delegate_type) != null;
+                                       var prev = ec.Report.SetPrinter (TypeInferenceReportPrinter ?? new NullReportPrinter ());
+
+                                       var res = Compatible (ec, delegate_type) != null;
+
+                                       ec.Report.SetPrinter (prev);
+
+                                       return res;
                                }
                        }
                }
@@ -1048,12 +1114,23 @@ namespace Mono.CSharp {
                        }
 
                        using (ec.Set (ResolveContext.Options.ProbingMode | ResolveContext.Options.InferReturnType)) {
+                               ReportPrinter prev;
+                               if (TypeInferenceReportPrinter != null) {
+                                       prev = ec.Report.SetPrinter (TypeInferenceReportPrinter);
+                               } else {
+                                       prev = null;
+                               }
+
                                var body = CompatibleMethodBody (ec, tic, null, delegate_type);
                                if (body != null) {
                                        am = body.Compatible (ec, body);
                                } else {
                                        am = null;
                                }
+
+                               if (TypeInferenceReportPrinter != null) {
+                                       ec.Report.SetPrinter (prev);
+                               }
                        }
 
                        if (am == null)
@@ -1415,6 +1492,9 @@ namespace Mono.CSharp {
                        if (ec.HasSet (ResolveContext.Options.ExpressionTreeConversion))
                                flags |= ResolveContext.Options.ExpressionTreeConversion;
 
+                       if (ec.HasSet (ResolveContext.Options.BaseInitializer))
+                               flags |= ResolveContext.Options.BaseInitializer;
+
                        aec.Set (flags);
 
                        var errors = ec.Report.Errors;
@@ -1544,25 +1624,47 @@ namespace Mono.CSharp {
                        //
 
                        Modifiers modifiers;
+                       TypeDefinition parent = null;
+
                        var src_block = Block.Original.Explicit;
                        if (src_block.HasCapturedVariable || src_block.HasCapturedThis) {
-                               storey = FindBestMethodStorey ();
+                               parent = storey = FindBestMethodStorey ();
 
-                               //
-                               // For iterators we can host everything in one class
-                               //
-                               if (storey == null && Block.TopBlock.StateMachine is IteratorStorey)
-                                       storey = block.TopBlock.StateMachine;
+                               if (storey == null) {
+                                       var sm = src_block.ParametersBlock.TopBlock.StateMachine;
+
+                                       //
+                                       // Remove hoisted this demand when simple instance method is enough
+                                       //
+                                       if (src_block.HasCapturedThis) {
+                                               src_block.ParametersBlock.TopBlock.RemoveThisReferenceFromChildrenBlock (src_block);
+
+                                               //
+                                               // Special case where parent class is used to emit instance method
+                                               // because currect storey is of value type (async host) and we don't
+                                               // want to create another childer storey to host this reference only
+                                               //
+                                               if (sm != null && sm.Kind == MemberKind.Struct)
+                                                       parent = sm.Parent.PartialContainer;
+                                       }
+
+                                       //
+                                       // For iterators we can host everything in one class
+                                       //
+                                       if (sm is IteratorStorey)
+                                               parent = storey = sm;
+                               }
 
                                modifiers = storey != null ? Modifiers.INTERNAL : Modifiers.PRIVATE;
                        } else {
                                if (ec.CurrentAnonymousMethod != null)
-                                       storey = ec.CurrentAnonymousMethod.Storey;
+                                       parent = storey = ec.CurrentAnonymousMethod.Storey;
 
                                modifiers = Modifiers.STATIC | Modifiers.PRIVATE;
                        }
 
-                       var parent = storey != null ? storey : ec.CurrentTypeDefinition.Parent.PartialContainer;
+                       if (parent == null)
+                               parent = ec.CurrentTypeDefinition.Parent.PartialContainer;
 
                        string name = CompilerGeneratedContainer.MakeName (parent != storey ? block_name : null,
                                "m", null, ec.Module.CounterAnonymousMethods++);
@@ -1667,6 +1769,17 @@ namespace Mono.CSharp {
                                }
                        } else {
                                ec.EmitThis ();
+
+                               //
+                               // Special case for value type storey where this is not lifted but
+                               // droped off to parent class
+                               //
+                               for (var b = Block.Parent; b != null; b = b.Parent) {
+                                       if (b.ParametersBlock.StateMachine != null) {
+                                               ec.Emit (OpCodes.Ldfld, b.ParametersBlock.StateMachine.HoistedThis.Field.Spec);
+                                               break;
+                                       }
+                               }
                        }
 
                        var delegate_method = method.Spec;
index d8d3a8813863a6c5a6574cf58d0007927f8170a9..1822ac65eeaa239b90d8de0cb3fa6151b3313b41 100644 (file)
@@ -343,7 +343,7 @@ namespace Mono.CSharp {
                        type = target_type;
 
                        if (!(target is IAssignMethod)) {
-                               Error_ValueAssignment (ec, source);
+                               target.Error_ValueAssignment (ec, source);
                                return null;
                        }
 
@@ -815,7 +815,7 @@ namespace Mono.CSharp {
                                return new SimpleAssign (target, new DynamicConversion (target_type, CSharpBinderFlags.ConvertExplicit, arg, loc), loc).Resolve (ec);
                        }
 
-                       right.Error_ValueCannotBeConverted (ec, loc, target_type, false);
+                       right.Error_ValueCannotBeConverted (ec, target_type, false);
                        return null;
                }
 
index fba2704ebd0630361806217b082da9b2034e0f3c..c2885de8e0b1350a76c2a137ffa70c73b0831d1a 100644 (file)
@@ -464,7 +464,7 @@ namespace Mono.CSharp
                Dictionary<TypeSpec, List<Field>> awaiter_fields;
 
                public AsyncTaskStorey (ParametersBlock block, IMemberContext context, AsyncInitializer initializer, TypeSpec type)
-                       : base (block, initializer.Host, context.CurrentMemberDefinition as MemberBase, context.CurrentTypeParameters, "async", MemberKind.Class)
+                       : base (block, initializer.Host, context.CurrentMemberDefinition as MemberBase, context.CurrentTypeParameters, "async", MemberKind.Struct)
                {
                        return_type = type;
                        awaiter_fields = new Dictionary<TypeSpec, List<Field>> ();
@@ -749,16 +749,10 @@ namespace Mono.CSharp
                                InstanceExpression = new CompilerGeneratedThis (ec.CurrentType, Location)
                        };
 
-                       // TODO: CompilerGeneratedThis is enough for structs
-                       var temp_this = new LocalTemporary (CurrentType);
-                       temp_this.EmitAssign (ec, new CompilerGeneratedThis (CurrentType, Location), false, false);
-
                        var args = new Arguments (2);
                        args.Add (new Argument (awaiter, Argument.AType.Ref));
-                       args.Add (new Argument (temp_this, Argument.AType.Ref));
+                       args.Add (new Argument (new CompilerGeneratedThis (CurrentType, Location), Argument.AType.Ref));
                        mg.EmitCall (ec, args);
-
-                       temp_this.Release (ec);
                }
 
                public void EmitInitializer (EmitContext ec)
@@ -788,14 +782,14 @@ namespace Mono.CSharp
                        //
                        // stateMachine.$builder = AsyncTaskMethodBuilder<{task-type}>.Create();
                        //
-                       instance.Emit (ec); // .AddressOf (ec, AddressOp.Store);
+                       instance.AddressOf (ec, AddressOp.Store);
                        ec.Emit (OpCodes.Call, builder_factory);
                        ec.Emit (OpCodes.Stfld, builder_field);
 
                        //
                        // stateMachine.$builder.Start<{storey-type}>(ref stateMachine);
                        //
-                       instance.Emit (ec); //.AddressOf (ec, AddressOp.Store);
+                       instance.AddressOf (ec, AddressOp.Store);
                        ec.Emit (OpCodes.Ldflda, builder_field);
                        if (Task != null)
                                ec.Emit (OpCodes.Dup);
@@ -861,7 +855,7 @@ namespace Mono.CSharp
 
                protected override TypeSpec[] ResolveBaseTypes (out FullNamedExpression base_class)
                {
-                       base_type = Compiler.BuiltinTypes.Object; // ValueType;
+                       base_type = Compiler.BuiltinTypes.ValueType;
                        base_class = null;
 
                        var istate_machine = Module.PredefinedTypes.IAsyncStateMachine;
index 7580124ceead35f46cd9af384fdc17b2fe99dcb8..9e2cfc8b96c8704aadcd828986d007581c55b2db 100644 (file)
@@ -149,7 +149,7 @@ namespace Mono.CSharp {
                                        case Binary.Operator.ExclusiveOr:
                                                result = BinaryFold (ec, oper, ((EnumConstant)left).Child, ((EnumConstant)right).Child, loc);
                                                if (result != null)
-                                                       result = result.TryReduce (ec, lt, loc);
+                                                       result = result.TryReduce (ec, lt);
                                                return result;
 
                                        ///
@@ -158,7 +158,7 @@ namespace Mono.CSharp {
                                        case Binary.Operator.Subtraction:
                                                result = BinaryFold (ec, oper, ((EnumConstant)left).Child, ((EnumConstant)right).Child, loc);
                                                if (result != null)
-                                                       result = result.TryReduce (ec, EnumSpec.GetUnderlyingType (lt), loc);
+                                                       result = result.TryReduce (ec, EnumSpec.GetUnderlyingType (lt));
                                                return result;
 
                                        ///
@@ -340,7 +340,7 @@ namespace Mono.CSharp {
                                        if (result == null)
                                                return null;
 
-                                       result = result.TryReduce (ec, lt, loc);
+                                       result = result.TryReduce (ec, lt);
                                        if (result == null)
                                                return null;
 
@@ -459,7 +459,7 @@ namespace Mono.CSharp {
                                        if (result == null)
                                                return null;
 
-                                       result = result.TryReduce (ec, lt, loc);
+                                       result = result.TryReduce (ec, lt);
                                        if (result == null)
                                                return null;
 
index 2ea5321014f631280908668e7a2f1131ef2ce626..216548b0c5c2e5c0ec50920dc29a642cf8c3ba9b 100644 (file)
@@ -70,6 +70,12 @@ namespace Mono.CSharp
                        }
                }
 
+               public Dictionary<string, MemberCore> DefinedNames {
+                       get {
+                               return defined_names;
+                       }
+               }
+
                public TypeDefinition PartialContainer {
                        get {
                                return main_container;
@@ -1899,7 +1905,7 @@ namespace Mono.CSharp
                                                continue;
 
                                        //
-                                       // Don't be pendatic over serializable attributes
+                                       // Don't be pedantic when type requires specific layout
                                        //
                                        if (f.OptAttributes != null || PartialContainer.HasStructLayout)
                                                continue;
@@ -1911,10 +1917,6 @@ namespace Mono.CSharp
                                        } else if (TypeSpec.IsReferenceType (f.MemberType)) {
                                                value = "null";
                                        } else {
-                                               // Ignore this warning for struct value fields (they are always initialized)
-                                               if (f.MemberType.IsStruct)
-                                                       continue;
-
                                                value = null;
                                        }
 
@@ -2380,16 +2382,6 @@ namespace Mono.CSharp
                        base.AddNameToContainer (symbol, name);
                }
 
-               public override void VerifyMembers ()
-               {
-                       base.VerifyMembers ();
-
-                       if (containers != null) {
-                               foreach (var t in containers)
-                                       t.VerifyMembers ();
-                       }
-               }
-
                public override void ApplyAttributeBuilder (Attribute a, MethodSpec ctor, byte[] cdata, PredefinedAttributes pa)
                {
                        if (a.IsValidSecurityAttribute ()) {
index 465da5a3af1a66a080f9f07ecfa1e18564907c8e..026d410698090f7787a29c75c996c60dbc15026d 100644 (file)
@@ -1096,9 +1096,11 @@ namespace Mono.CSharp
                                return false;
 
                        //
-                       // It's non-virtual and will never be null
+                       // It's non-virtual and will never be null and it can be determined
+                       // whether it's known value or reference type by verifier
                        //
-                       if (!method.IsVirtual && (instance is This || instance is New || instance is ArrayCreation || instance is DelegateCreation))
+                       if (!method.IsVirtual && (instance is This || instance is New || instance is ArrayCreation || instance is DelegateCreation) &&
+                               !instance.Type.IsGenericParameter)
                                return false;
 
                        return true;
index 7d42bde35498a4dddfa0acce6618db024777636a..883b0d2c23fe1efd45e1a5b61e4fe73317a3b251 100644 (file)
@@ -200,7 +200,7 @@ namespace Mono.CSharp {
                                        else if (!(expr is Constant))
                                                Error_ExpressionMustBeConstant (rc, expr.Location, GetSignatureForError ());
                                        else
-                                               expr.Error_ValueCannotBeConverted (rc, expr.Location, field.MemberType, false);
+                                               expr.Error_ValueCannotBeConverted (rc, field.MemberType, false);
                                }
 
                                expr = c;
index beb9512e6e5a5b7e31e432333e0b5fd8ff16e7ca..3cf689ddd81fc60b9fbafbda936eb4733fb4fc43 100644 (file)
@@ -58,7 +58,7 @@ namespace Mono.CSharp {
                }
 #endif
 
-               public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl)
+               public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl)
                {
                        if (!expl && IsLiteral && 
                                BuiltinTypeSpec.IsPrimitiveTypeOrDecimal (target) &&
@@ -66,7 +66,7 @@ namespace Mono.CSharp {
                                ec.Report.Error (31, loc, "Constant value `{0}' cannot be converted to a `{1}'",
                                        GetValueAsLiteral (), TypeManager.CSharpName (target));
                        } else {
-                               base.Error_ValueCannotBeConverted (ec, loc, target, expl);
+                               base.Error_ValueCannotBeConverted (ec, target, expl);
                        }
                }
 
@@ -74,7 +74,7 @@ namespace Mono.CSharp {
                {
                        Constant c = ConvertImplicitly (type);
                        if (c == null)
-                               Error_ValueCannotBeConverted (ec, loc, type, false);
+                               Error_ValueCannotBeConverted (ec, type, false);
 
                        return c;
                }
@@ -254,32 +254,38 @@ namespace Mono.CSharp {
                /// <summary>
                ///   Attempts to do a compile-time folding of a constant cast.
                /// </summary>
-               public Constant TryReduce (ResolveContext ec, TypeSpec target_type, Location loc)
+               public Constant TryReduce (ResolveContext ec, TypeSpec target_type)
                {
                        try {
-                               return TryReduce (ec, target_type);
-                       }
-                       catch (OverflowException) {
+                               return TryReduceConstant (ec, target_type);
+                       } catch (OverflowException) {
                                if (ec.ConstantCheckState && Type.BuiltinType != BuiltinTypeSpec.Type.Decimal) {
                                        ec.Report.Error (221, loc,
                                                "Constant value `{0}' cannot be converted to a `{1}' (use `unchecked' syntax to override)",
                                                GetValueAsLiteral (), target_type.GetSignatureForError ());
                                } else {
-                                       Error_ValueCannotBeConverted (ec, loc, target_type, false);
+                                       Error_ValueCannotBeConverted (ec, target_type, false);
                                }
 
                                return New.Constantify (target_type, loc);
                        }
                }
 
-               Constant TryReduce (ResolveContext ec, TypeSpec target_type)
+               Constant TryReduceConstant (ResolveContext ec, TypeSpec target_type)
                {
-                       if (Type == target_type)
+                       if (Type == target_type) {
+                               //
+                               // Reducing literal value produces a new constant. Syntactically 10 is not same as (int)10 
+                               //
+                               if (IsLiteral)
+                                       return CreateConstantFromValue (target_type, GetValue (), loc);
+
                                return this;
+                       }
 
                        Constant c;
                        if (target_type.IsEnum) {
-                               c = TryReduce (ec, EnumSpec.GetUnderlyingType (target_type));
+                               c = TryReduceConstant (ec, EnumSpec.GetUnderlyingType (target_type));
                                if (c == null)
                                        return null;
 
@@ -375,11 +381,11 @@ namespace Mono.CSharp {
                        eclass = ExprClass.Value;
                }
 
-               public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl)
+               public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl)
                {
                        try {
                                ConvertExplicitly (true, target);
-                               base.Error_ValueCannotBeConverted (ec, loc, target, expl);
+                               base.Error_ValueCannotBeConverted (ec, target, expl);
                        }
                        catch
                        {
index d28cc0dd06a2bed0ff0a4bab11e5b9e2ce611285..3020c8814c54ce37961edf1950b9e89c7db791e4 100644 (file)
@@ -1195,7 +1195,7 @@ namespace Mono.CSharp {
                        if (s_x != source_type) {
                                var c = source as Constant;
                                if (c != null) {
-                                       source = c.TryReduce (ec, s_x, loc);
+                                       source = c.TryReduce (ec, s_x);
                                } else {
                                        source = implicitOnly ?
                                                ImplicitConversionStandard (ec, source_type_expr, s_x, loc) :
@@ -1337,8 +1337,7 @@ namespace Mono.CSharp {
                                try {
                                        c = c.ConvertImplicitly (target_type);
                                } catch {
-                                       Console.WriteLine ("Conversion error happened in line {0}", loc);
-                                       throw;
+                                       throw new InternalErrorException ("Conversion error", loc);
                                }
                                if (c != null)
                                        return c;
@@ -1423,7 +1422,7 @@ namespace Mono.CSharp {
                        if (e != null)
                                return e;
 
-                       source.Error_ValueCannotBeConverted (ec, loc, target_type, false);
+                       source.Error_ValueCannotBeConverted (ec, target_type, false);
                        return null;
                }
 
@@ -2103,7 +2102,7 @@ namespace Mono.CSharp {
                        if (ec.IsUnsafe && expr.Type.IsPointer && target_type.IsPointer && ((PointerContainer)expr.Type).Element.Kind == MemberKind.Void)
                                return EmptyCast.Create (expr, target_type);
 
-                       expr.Error_ValueCannotBeConverted (ec, l, target_type, true);
+                       expr.Error_ValueCannotBeConverted (ec, target_type, true);
                        return null;
                }
 
@@ -2166,7 +2165,7 @@ namespace Mono.CSharp {
                        if (e != null)
                                return e;                       
 
-                       expr.Error_ValueCannotBeConverted (ec, loc, target_type, true);
+                       expr.Error_ValueCannotBeConverted (ec, target_type, true);
                        return null;
                }
        }
index b17c4ca0563dcf3704059afeed18b77fb22de142..f0a98c2dc2f110b7576b6226e92546f93149b624 100644 (file)
 //
 // (C) 2001 Ximian, Inc (http://www.ximian.com)
 // (C) 2004-2011 Novell, Inc
-// Copyright 2011 Xamarin Inc.
-//
-// TODO:
-//   (1) Figure out why error productions dont work.  `type-declaration' is a
-//       great spot to put an `error' because you can reproduce it with this input:
-//      "public X { }"
+// Copyright 2011-2012 Xamarin Inc.
 //
 
 using System.Text;
@@ -1452,12 +1447,18 @@ fixed_parameter
                report.Error (1552, lt.Location, "Array type specifier, [], must appear before parameter name");
                $$ = new Parameter ((FullNamedExpression) $3, lt.Value, (Parameter.Modifier) $2, (Attributes) $1, lt.Location);
          }
+       | attribute_sections error
+         {
+               Error_SyntaxError (yyToken);
+               Location l = GetLocation ($2);
+               $$ = new Parameter (null, null, Parameter.Modifier.NONE, (Attributes) $1, l);
+         }
        | opt_attributes
          opt_parameter_modifier
          parameter_type
          error
          {
-               Error_SyntaxError (yyToken);      
+               Error_SyntaxError (yyToken);
                Location l = GetLocation ($4);
                $$ = new Parameter ((FullNamedExpression) $3, null, (Parameter.Modifier) $2, (Attributes) $1, l);
          }
@@ -2477,7 +2478,7 @@ enum_declaration
                        report.Error (1675, name.Location, "Enums cannot have type parameters");
                }
                
-               push_current_container (new Enum (current_container, (TypeExpression) $5, (Modifiers) $2, name, (Attributes) $1), null);
+               push_current_container (new Enum (current_container, (FullNamedExpression) $5, (Modifiers) $2, name, (Attributes) $1), null);
          }
          opt_enum_member_declarations
          {
@@ -2507,10 +2508,8 @@ opt_enum_base
                var te = $2 as TypeExpression;
                if (te == null || !EnumSpec.IsValidUnderlyingType (te.Type)) {
                        Enum.Error_1008 (GetLocation ($2), report);
-                       $$ = null;
-               } else {
-                       $$ = $2;
                }
+               $$ = $2;
         }
        | COLON error
         {
@@ -2573,6 +2572,7 @@ enum_member_declaration
 
                $$ = em;
          }
+       | attributes_without_members
        ;
 
 delegate_declaration
@@ -3086,6 +3086,14 @@ invocation_expression
                $$ = new Invocation ((Expression) $1, (Arguments) $3);
                lbag.AddLocation ($$, GetLocation ($2), GetLocation ($4));
          }
+       | primary_expression open_parens_any argument_list error
+         {
+               Error_SyntaxError (yyToken);
+
+               $$ = new Invocation ((Expression) $1, (Arguments) $3);
+               lbag.AddLocation ($$, GetLocation ($2));
+         }
+       
        ;
 
 opt_object_or_collection_initializer
@@ -3210,10 +3218,11 @@ argument_list
                list.Add (a);
                $$ = list;
          }
-       | argument_list COMMA
+       | argument_list COMMA error
          {
-               report.Error (839, GetLocation ($2), "An argument is missing");
-               $$ = $1;
+               lexer.putback (')'); // TODO: Wrong but what can I do
+               Error_SyntaxError (yyToken);
+               $$ = $1;
          }
        | COMMA error
          {
@@ -3270,10 +3279,12 @@ element_access
          }
        | primary_expression OPEN_BRACKET_EXPR expression_list_arguments error
          {
+               Error_SyntaxError (yyToken);
                $$ = new ElementAccess ((Expression) $1, (Arguments) $3, GetLocation ($2));
          }
        | primary_expression OPEN_BRACKET_EXPR error
          {
+               Error_SyntaxError (yyToken);
                $$ = new ElementAccess ((Expression) $1, null, GetLocation ($2));
          }
        ;
@@ -3412,8 +3423,9 @@ array_creation_expression
          }
        | NEW new_expr_type error
          {
-               Error_SyntaxError (1526, yyToken, "Unexpected symbol");
-               $$ = new ArrayCreation ((FullNamedExpression) $2, null, GetLocation ($1));
+               Error_SyntaxError (yyToken);
+               // It can be any of new expression, create the most common one
+               $$ = new New ((FullNamedExpression) $2, null, GetLocation ($1));
          }
        ;
 
@@ -3969,6 +3981,11 @@ conditional_expression
                $$ = new Conditional (new BooleanExpression ((Expression) $1), (Expression) $3, (Expression) $5, GetLocation ($2));
                lbag.AddLocation ($$, GetLocation ($4));
          }
+       | null_coalescing_expression INTERR expression error
+         {
+               Error_SyntaxError (yyToken);
+               $$ = new Conditional (new BooleanExpression ((Expression) $1), (Expression) $3, null, GetLocation ($2));
+         }
        ;
 
 assignment_expression
@@ -5106,6 +5123,11 @@ switch_label
                $$ = new SwitchLabel ((Expression) $2, GetLocation ($1));
                lbag.AddLocation ($$, GetLocation ($3));
         }
+       | CASE constant_expression error
+         {
+               Error_SyntaxError (yyToken);
+               $$ = new SwitchLabel ((Expression) $2, GetLocation ($1));
+         }
        | DEFAULT_COLON
          {
                $$ = new SwitchLabel (null, GetLocation ($1));
@@ -5177,23 +5199,21 @@ for_statement_cont
        : opt_for_initializer SEMICOLON
          {
                ((For) $0).Initializer = (Statement) $1;
+
+               // Pass the "For" object to the iterator_part4
+               oob_stack.Push ($0);
          }
-         opt_for_condition SEMICOLON
-         {
-               ((For) $0).Condition = (BooleanExpression) $4;
-         }
-         opt_for_iterator CLOSE_PARENS
-         {
-               ((For) $0).Iterator = (Statement) $7;
-         }
+         for_condition_and_iterator_part
          embedded_statement
          {
-               if ($10 is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE)
-                       Warning_EmptyStatement (GetLocation ($10));
+               var locations = (Tuple<Location,Location>) $4;
+               oob_stack.Pop ();
+               if ($5 is EmptyStatement && lexer.peek_token () == Token.OPEN_BRACE)
+                       Warning_EmptyStatement (GetLocation ($5));
          
                For f = ((For) $0);
-               f.Statement = (Statement) $10;
-               lbag.AddStatement (f, current_block.StartLocation, GetLocation ($2), GetLocation ($5), GetLocation ($8));
+               f.Statement = (Statement) $5;
+               lbag.AddStatement (f, current_block.StartLocation, GetLocation ($2), GetLocation (locations.Item1), GetLocation (locations.Item2));
 
                $$ = end_block (GetLocation ($2));
          }
@@ -5204,6 +5224,45 @@ for_statement_cont
          }
        ;
 
+for_condition_and_iterator_part
+       : opt_for_condition SEMICOLON
+         {
+               For f = (For) oob_stack.Peek ();
+               f.Condition = (BooleanExpression) $1;
+         }
+         for_iterator_part {
+               $$ = new Tuple<Location,Location> (GetLocation ($2), (Location) $4);
+         }
+
+       // Handle errors in the case of opt_for_condition being followed by
+       // a close parenthesis
+       | opt_for_condition close_parens_close_brace {
+               report.Error (1525, GetLocation ($2), "Unexpected symbol `}'");
+               For f = (For) oob_stack.Peek ();
+               f.Condition = (BooleanExpression) $1;
+               $$ = new Tuple<Location,Location> (GetLocation ($2), GetLocation ($2));
+         }
+       ;
+
+for_iterator_part
+       : opt_for_iterator CLOSE_PARENS {
+               For f = (For) oob_stack.Peek ();
+               f.Iterator = (Statement) $1;
+               $$ = GetLocation ($2);
+         }
+       | opt_for_iterator CLOSE_BRACE {
+               report.Error (1525, GetLocation ($2), "Unexpected symbol expected ')'");
+               For f = (For) oob_stack.Peek ();
+               f.Iterator = (Statement) $1;
+               $$ = GetLocation ($2);
+         }
+       ; 
+
+close_parens_close_brace 
+       : CLOSE_PARENS
+       | CLOSE_BRACE { lexer.putback ('}'); }
+       ;
+
 opt_for_initializer
        : /* empty */           { $$ = new EmptyStatement (lexer.Location); }
        | for_initializer       
@@ -5333,6 +5392,11 @@ continue_statement
                $$ = new Continue (GetLocation ($1));
                lbag.AddStatement ($$, GetLocation ($2));
          }
+       | CONTINUE error
+         {
+               Error_SyntaxError (yyToken);
+               $$ = new Continue (GetLocation ($1));
+         }
        ;
 
 goto_statement
@@ -5360,6 +5424,11 @@ return_statement
                $$ = new Return ((Expression) $2, GetLocation ($1));
                lbag.AddStatement ($$, GetLocation ($3));
          }
+       | RETURN error
+         {
+               Error_SyntaxError (yyToken);
+               $$ = new Return (null, GetLocation ($1));
+         }
        ;
 
 throw_statement
@@ -5368,6 +5437,11 @@ throw_statement
                $$ = new Throw ((Expression) $2, GetLocation ($1));
                lbag.AddStatement ($$, GetLocation ($3));
          }
+       | THROW error
+         {
+               Error_SyntaxError (yyToken);
+               $$ = new Throw (null, GetLocation ($1));
+         }
        ;
 
 yield_statement 
@@ -6523,10 +6597,10 @@ public void parse ()
                        report.Error (-25, lexer.Location, "Parsing error");
                } else {
                        // Used by compiler-tester to test internal errors
-                       if (yacc_verbose_flag > 0)
+                       if (yacc_verbose_flag > 0 || e is FatalException)
                                throw;
                
-                       report.Error (589, lexer.Location, "Internal compiler error during parsing");
+                       report.Error (589, lexer.Location, "Internal compiler error during parsing" + e);
                }
        }
 }
index 8a9103bcb38797834317672ea73d6ca38f2b2892..6bec5b51d51e0e17506b43764136c0139caee2c6 100644 (file)
@@ -139,6 +139,11 @@ namespace Mono.CSharp
                                pos = 0;
                        }
 
+                       public override string ToString ()
+                       {
+                               return string.Format ("Token '{0}' at {1},{2}", Value, row, column);
+                       }
+                       
                        public Location Location {
                                get { return new Location (row, column); }
                        }
@@ -1265,10 +1270,24 @@ namespace Mono.CSharp
                                        int ntoken;
                                        int interrs = 1;
                                        int colons = 0;
+                                       int braces = 0;
                                        //
                                        // All shorcuts failed, do it hard way
                                        //
                                        while ((ntoken = xtoken ()) != Token.EOF) {
+                                               if (ntoken == Token.OPEN_BRACE) {
+                                                       ++braces;
+                                                       continue;
+                                               }
+
+                                               if (ntoken == Token.CLOSE_BRACE) {
+                                                       --braces;
+                                                       continue;
+                                               }
+
+                                               if (braces != 0)
+                                                       continue;
+
                                                if (ntoken == Token.SEMICOLON)
                                                        break;
                                                
@@ -1284,7 +1303,7 @@ namespace Mono.CSharp
                                                }
                                        }
                                        
-                                       next_token = colons != interrs ? Token.INTERR_NULLABLE : Token.INTERR;
+                                       next_token = colons != interrs && braces == 0 ? Token.INTERR_NULLABLE : Token.INTERR;
                                        break;
                                }
                        }
@@ -1796,13 +1815,10 @@ namespace Mono.CSharp
                
                public void putback (int c)
                {
-                       if (putback_char != -1){
-                               Console.WriteLine ("Col: " + col);
-                               Console.WriteLine ("Row: " + line);
-                               Console.WriteLine ("Name: " + current_source.Name);
-                               Console.WriteLine ("Current [{0}] putting back [{1}]  ", putback_char, c);
-                               throw new Exception ("This should not happen putback on putback");
+                       if (putback_char != -1) {
+                               throw new InternalErrorException (string.Format ("Secondary putback [{0}] putting back [{1}] is not allowed", (char)putback_char, (char) c), Location);
                        }
+
                        if (c == '\n' || col == 0) {
                                // It won't happen though.
                                line--;
index fdfb20c59cf6c9833e580bbf1e64dc03b6a2aaf3..703cd949bf75bf2756949d4690fdc95de07285b4 100644 (file)
@@ -939,6 +939,15 @@ namespace Mono.CSharp {
                        GenericTask = 1 << 22
                }
 
+               //
+               // Some flags can be copied directly from other member
+               //
+               protected const StateFlags SharedStateFlags =
+                       StateFlags.CLSCompliant | StateFlags.CLSCompliant_Undetected |
+                       StateFlags.Obsolete | StateFlags.Obsolete_Undetected |
+                       StateFlags.MissingDependency | StateFlags.MissingDependency_Undetected |
+                       StateFlags.HasDynamicElement;
+
                protected Modifiers modifiers;
                public StateFlags state;
                protected IMemberDefinition definition;
index 30c199f82e8e378f2e6ed4d5f08aeaf39869e53c..e988178c4343c6bf818d263cd83aee1ba5a83a4b 100644 (file)
@@ -397,10 +397,15 @@ namespace Mono.CSharp
 
                                if (ParsedParameters != null) {
                                        var old_printer = mc.Module.Compiler.Report.SetPrinter (new NullReportPrinter ());
-                                       foreach (var pp in ParsedParameters) {
-                                               pp.Resolve (mc);
+                                       try {
+                                               var context = new DocumentationMemberContext (mc, ParsedName ?? MemberName.Null);
+
+                                               foreach (var pp in ParsedParameters) {
+                                                       pp.Resolve (context);
+                                               }
+                                       } finally {
+                                               mc.Module.Compiler.Report.SetPrinter (old_printer);
                                        }
-                                       mc.Module.Compiler.Report.SetPrinter (old_printer);
                                }
 
                                if (type != null) {
@@ -433,13 +438,15 @@ namespace Mono.CSharp
                                                                        if (m.Kind == MemberKind.Operator && !ParsedOperator.HasValue)
                                                                                continue;
 
+                                                                       var pm_params = pm.Parameters;
+
                                                                        int i;
                                                                        for (i = 0; i < parsed_param_count; ++i) {
                                                                                var pparam = ParsedParameters[i];
 
-                                                                               if (i >= pm.Parameters.Count || pparam == null ||
-                                                                                       pparam.TypeSpec != pm.Parameters.Types[i] ||
-                                                                                       (pparam.Modifier & Parameter.Modifier.RefOutMask) != (pm.Parameters.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask)) {
+                                                                               if (i >= pm_params.Count || pparam == null || pparam.TypeSpec == null ||
+                                                                                       !TypeSpecComparer.Override.IsEqual (pparam.TypeSpec, pm_params.Types[i]) ||
+                                                                                       (pparam.Modifier & Parameter.Modifier.RefOutMask) != (pm_params.FixedParameters[i].ModFlags & Parameter.Modifier.RefOutMask)) {
 
                                                                                        if (i > parameters_match) {
                                                                                                parameters_match = i;
@@ -459,7 +466,7 @@ namespace Mono.CSharp
                                                                                        continue;
                                                                                }
                                                                        } else {
-                                                                               if (parsed_param_count != pm.Parameters.Count)
+                                                                               if (parsed_param_count != pm_params.Count)
                                                                                        continue;
                                                                        }
                                                                }
@@ -612,6 +619,97 @@ namespace Mono.CSharp
                }
        }
 
+       //
+       // Type lookup of documentation references uses context of type where
+       // the reference is used but type parameters from cref value
+       //
+       sealed class DocumentationMemberContext : IMemberContext
+       {
+               readonly MemberCore host;
+               MemberName contextName;
+
+               public DocumentationMemberContext (MemberCore host, MemberName contextName)
+               {
+                       this.host = host;
+                       this.contextName = contextName;
+               }
+
+               public TypeSpec CurrentType {
+                       get {
+                               return host.CurrentType;
+                       }
+               }
+
+               public TypeParameters CurrentTypeParameters {
+                       get {
+                               return contextName.TypeParameters;
+                       }
+               }
+
+               public MemberCore CurrentMemberDefinition {
+                       get {
+                               return host.CurrentMemberDefinition;
+                       }
+               }
+
+               public bool IsObsolete {
+                       get {
+                               return false;
+                       }
+               }
+
+               public bool IsUnsafe {
+                       get {
+                               return host.IsStatic;
+                       }
+               }
+
+               public bool IsStatic {
+                       get {
+                               return host.IsStatic;
+                       }
+               }
+
+               public ModuleContainer Module {
+                       get {
+                               return host.Module;
+                       }
+               }
+
+               public string GetSignatureForError ()
+               {
+                       return host.GetSignatureForError ();
+               }
+
+               public ExtensionMethodCandidates LookupExtensionMethod (TypeSpec extensionType, string name, int arity)
+               {
+                       return null;
+               }
+
+               public FullNamedExpression LookupNamespaceOrType (string name, int arity, LookupMode mode, Location loc)
+               {
+                       if (arity == 0) {
+                               var tp = CurrentTypeParameters;
+                               if (tp != null) {
+                                       for (int i = 0; i < tp.Count; ++i) {
+                                               var t = tp[i];
+                                               if (t.Name == name) {
+                                                       t.Type.DeclaredPosition = i;
+                                                       return new TypeParameterExpr (t, loc);
+                                               }
+                                       }
+                               }
+                       }
+
+                       return host.Parent.LookupNamespaceOrType (name, arity, mode, loc);
+               }
+
+               public FullNamedExpression LookupNamespaceAlias (string name)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+
        class DocumentationParameter
        {
                public readonly Parameter.Modifier Modifier;
index d3e2f2fad09f57090cad658bab5c3dce09bcaf1d..cd42b8974c631cd7efc4a86f15b8153f2090933b 100644 (file)
@@ -256,6 +256,12 @@ namespace Mono.CSharp
                                output_file = output_file_name;
                        } else {
                                output_file_name = Path.GetFileName (output_file);
+
+                               if (string.IsNullOrEmpty (Path.GetFileNameWithoutExtension (output_file_name)) ||
+                                       output_file_name.IndexOfAny (Path.GetInvalidFileNameChars ()) >= 0) {
+                                       Report.Error (2021, "Output file name is not valid");
+                                       return false;
+                               }
                        }
 
 #if STATIC
index b245b559fc3c96320022b2f27ff24179b9be38ab..2a4bee32c4a43cac8f2848f91dbbf24ea7e5c115 100644 (file)
@@ -240,7 +240,7 @@ namespace Mono.CSharp {
                        Report.Error (1547, loc, "Keyword `void' cannot be used in this context");
                }
 
-               public virtual void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl)
+               public virtual void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl)
                {
                        Error_ValueCannotBeConvertedCore (ec, loc, target, expl);
                }
@@ -320,7 +320,7 @@ namespace Mono.CSharp {
                                TypeManager.CSharpName (type), name);
                }
 
-               public void Error_ValueAssignment (ResolveContext rc, Expression rhs)
+               public virtual void Error_ValueAssignment (ResolveContext rc, Expression rhs)
                {
                        if (rhs == EmptyExpression.LValueMemberAccess || rhs == EmptyExpression.LValueMemberOutAccess) {
                                rc.Report.SymbolRelatedToPreviousError (type);
@@ -915,7 +915,7 @@ namespace Mono.CSharp {
                                        converted = Convert.ImplicitConversion (ec, source, btypes.ULong, source.loc);
 
                                if (converted == null) {
-                                       source.Error_ValueCannotBeConverted (ec, source.loc, btypes.Int, false);
+                                       source.Error_ValueCannotBeConverted (ec, btypes.Int, false);
                                        return null;
                                }
                        }
@@ -2401,7 +2401,7 @@ namespace Mono.CSharp {
                                                        } else {
                                                                break;
                                                        }
-                                               } else if (me is MethodGroupExpr) {
+                                               } else if (me is MethodGroupExpr || me is PropertyExpr || me is IndexerExpr) {
                                                        // Leave it to overload resolution to report correct error
                                                } else {
                                                        // TODO: rc.Report.SymbolRelatedToPreviousError ()
@@ -2496,6 +2496,12 @@ namespace Mono.CSharp {
                                                                ErrorIsInaccesible (rc, e.GetSignatureForError (), loc);
                                                                return e;
                                                        }
+                                               } else {
+                                                       var me = MemberLookup (rc, false, rc.CurrentType, Name, Arity, restrictions & ~MemberLookupRestrictions.InvocableOnly, loc) as MemberExpr;
+                                                       if (me != null) {
+                                                               me.Error_UnexpectedKind (rc, me, "method group", me.KindName, loc);
+                                                               return ErrorExpression.Instance;
+                                                       }
                                                }
 
                                                e = rc.LookupNamespaceOrType (Name, -System.Math.Max (1, Arity), LookupMode.Probing, loc);
@@ -2766,8 +2772,14 @@ namespace Mono.CSharp {
                                        }
                                }
 
-                               // TODO: For now we do it for any hoisted call even if it's needed for
-                               // hoisted stories only but that requires a new expression wrapper
+                               //
+                               // When base access is used inside anonymous method/iterator/etc we need to
+                               // get back to the context of original type. We do it by emiting proxy
+                               // method in original class and rewriting base call to this compiler
+                               // generated method call which does the actual base invocation. This may
+                               // introduce redundant storey but with `this' only but it's tricky to avoid
+                               // at this stage as we don't know what expressions follow base
+                               //
                                if (rc.CurrentAnonymousMethod != null) {
                                        if (targs == null && method.IsGeneric) {
                                                targs = method.TypeArguments;
@@ -2781,8 +2793,9 @@ namespace Mono.CSharp {
 
                                        // Ideally this should apply to any proxy rewrite but in the case of unary mutators on
                                        // get/set member expressions second call would fail to proxy because left expression
-                                       // would be of 'this' and not 'base'
-                                       if (rc.CurrentType.IsStruct)
+                                       // would be of 'this' and not 'base' because we share InstanceExpression for get/set
+                                       // FIXME: The async check is another hack but will probably fail with mutators
+                                       if (rc.CurrentType.IsStruct || rc.CurrentAnonymousMethod.Storey is AsyncTaskStorey)
                                                InstanceExpression = new This (loc).Resolve (rc);
                                }
 
@@ -2956,7 +2969,7 @@ namespace Mono.CSharp {
                                                        "An object reference is required to access non-static member `{0}'",
                                                        GetSignatureForError ());
 
-                                       InstanceExpression = new CompilerGeneratedThis (type, loc).Resolve (rc);
+                                       InstanceExpression = new CompilerGeneratedThis (rc.CurrentType, loc).Resolve (rc);
                                        return false;
                                }
 
@@ -2982,12 +2995,15 @@ namespace Mono.CSharp {
                        if (me != null) {
                                me.ResolveInstanceExpression (rc, rhs);
 
-                               var fe = me as FieldExpr;
-                               if (fe != null && fe.IsMarshalByRefAccess (rc)) {
-                                       rc.Report.SymbolRelatedToPreviousError (me.DeclaringType);
-                                       rc.Report.Warning (1690, 1, loc,
-                                               "Cannot call methods, properties, or indexers on `{0}' because it is a value type member of a marshal-by-reference class",
-                                               me.GetSignatureForError ());
+                               // Using this check to detect probing instance expression resolve
+                               if (!rc.OmitStructFlowAnalysis) {
+                                       var fe = me as FieldExpr;
+                                       if (fe != null && fe.IsMarshalByRefAccess (rc)) {
+                                               rc.Report.SymbolRelatedToPreviousError (me.DeclaringType);
+                                               rc.Report.Warning (1690, 1, loc,
+                                                       "Cannot call methods, properties, or indexers on `{0}' because it is a value type member of a marshal-by-reference class",
+                                                       me.GetSignatureForError ());
+                                       }
                                }
 
                                return true;
@@ -3348,7 +3364,7 @@ namespace Mono.CSharp {
                        call.Emit (ec, best_candidate, arguments, loc);                 
                }
 
-               public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl)
+               public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl)
                {
                        ec.Report.Error (428, loc, "Cannot convert method group `{0}' to non-delegate type `{1}'. Consider using parentheses to invoke the method",
                                Name, TypeManager.CSharpName (target));
@@ -3431,6 +3447,15 @@ namespace Mono.CSharp {
 
                public override MemberExpr ResolveMemberAccess (ResolveContext ec, Expression left, SimpleName original)
                {
+                       var fe = left as FieldExpr;
+                       if (fe != null) {
+                               //
+                               // Using method-group on struct fields makes the struct assigned. I am not sure
+                               // why but that's what .net does
+                               //
+                               fe.Spec.MemberDefinition.SetIsAssigned ();
+                       }
+
                        simple_name = original;
                        return base.ResolveMemberAccess (ec, left, original);
                }
@@ -3576,7 +3601,6 @@ namespace Mono.CSharp {
                TypeSpec best_candidate_return_type;
 
                SessionReportPrinter lambda_conv_msgs;
-               ReportPrinter prev_recorder;
 
                public OverloadResolver (IList<MemberSpec> members, Restrictions restrictions, Location loc)
                        : this (members, null, restrictions, loc)
@@ -4034,6 +4058,7 @@ namespace Mono.CSharp {
                //
                // A return value rates candidate method compatibility,
                // 0 = the best, int.MaxValue = the worst
+               // -1 = fatal error
                //
                int IsApplicable (ResolveContext ec, ref Arguments arguments, int arg_count, ref MemberSpec candidate, IParametersMember pm, ref bool params_expanded_form, ref bool dynamicArgument, ref TypeSpec returnType)
                {
@@ -4155,6 +4180,18 @@ namespace Mono.CSharp {
                                arg_count = arguments.Count;
                        }
 
+                       //
+                       // Don't do any expensive checks when the candidate cannot succeed
+                       //
+                       if (arg_count != param_count && !cpd.HasParams)
+                               return (param_count - arg_count) * 2 + 1;
+
+                       var dep = candidate.GetMissingDependencies ();
+                       if (dep != null) {
+                               ImportedTypeDefinition.Error_MissingDependency (ec, dep, loc);
+                               return -1;
+                       }
+
                        //
                        // 1. Handle generic method using type arguments when specified or type inference
                        //
@@ -4171,20 +4208,41 @@ namespace Mono.CSharp {
 
                                        ms = ms.MakeGenericMethod (ec, type_arguments.Arguments);
                                } else {
-                                       // TODO: It should not be here (we don't know yet whether any argument is lambda) but
-                                       // for now it simplifies things. I should probably add a callback to ResolveContext
+                                       //
+                                       // Deploy custom error reporting for infered anonymous expression or lambda methods. When
+                                       // probing lambda methods keep all errors reported in separate set and once we are done and no best
+                                       // candidate was found use the set to report more details about what was wrong with lambda body.
+                                       // The general idea is to distinguish between code errors and errors caused by
+                                       // trial-and-error type inference
+                                       //
                                        if (lambda_conv_msgs == null) {
-                                               lambda_conv_msgs = new SessionReportPrinter ();
-                                               prev_recorder = ec.Report.SetPrinter (lambda_conv_msgs);
+                                               for (int i = 0; i < arg_count; i++) {
+                                                       Argument a = arguments[i];
+                                                       if (a == null)
+                                                               continue;
+
+                                                       var am = a.Expr as AnonymousMethodExpression;
+                                                       if (am != null) {
+                                                               if (lambda_conv_msgs == null)
+                                                                       lambda_conv_msgs = new SessionReportPrinter ();
+
+                                                               am.TypeInferenceReportPrinter = lambda_conv_msgs;
+                                                       }
+                                               }
                                        }
 
                                        var ti = new TypeInference (arguments);
                                        TypeSpec[] i_args = ti.InferMethodArguments (ec, ms);
-                                       lambda_conv_msgs.EndSession ();
 
                                        if (i_args == null)
                                                return ti.InferenceScore - 20000;
 
+                                       //
+                                       // Clear any error messages when the result was success
+                                       //
+                                       if (lambda_conv_msgs != null)
+                                               lambda_conv_msgs.ClearSession ();
+
                                        if (i_args.Length != 0) {
                                                ms = ms.MakeGenericMethod (ec, i_args);
                                        }
@@ -4392,28 +4450,11 @@ namespace Mono.CSharp {
                                if (argument.Type.BuiltinType == BuiltinTypeSpec.Type.Dynamic && (restrictions & Restrictions.CovariantDelegate) == 0)
                                        return -1;
 
-                               //
-                               // Deploy custom error reporting for lambda methods. When probing lambda methods
-                               // keep all errors reported in separate set and once we are done and no best
-                               // candidate was found, this set is used to report more details about what was wrong
-                               // with lambda body
-                               //
-                               if (argument.Expr.Type == InternalType.AnonymousMethod) {
-                                       if (lambda_conv_msgs == null) {
-                                               lambda_conv_msgs = new SessionReportPrinter ();
-                                               prev_recorder = ec.Report.SetPrinter (lambda_conv_msgs);
-                                       }
-                               }
-
                                //
                                // Use implicit conversion in all modes to return same candidates when the expression
                                // is used as argument or delegate conversion
                                //
                                if (!Convert.ImplicitConversionExists (ec, argument.Expr, parameter)) {
-                                       if (lambda_conv_msgs != null) {
-                                               lambda_conv_msgs.EndSession ();
-                                       }
-
                                        return 2;
                                }
                        }
@@ -4483,147 +4524,148 @@ namespace Mono.CSharp {
                        bool error_mode = false;
                        MemberSpec invocable_member = null;
 
-                       // Be careful, cannot return until error reporter is restored
                        while (true) {
                                best_candidate = null;
                                best_candidate_rate = int.MaxValue;
 
                                var type_members = members;
-                               try {
+                               do {
+                                       for (int i = 0; i < type_members.Count; ++i) {
+                                               var member = type_members[i];
 
-                                       do {
-                                               for (int i = 0; i < type_members.Count; ++i) {
-                                                       var member = type_members[i];
+                                               //
+                                               // Methods in a base class are not candidates if any method in a derived
+                                               // class is applicable
+                                               //
+                                               if ((member.Modifiers & Modifiers.OVERRIDE) != 0)
+                                                       continue;
+
+                                               if (!error_mode) {
+                                                       if (!member.IsAccessible (rc))
+                                                               continue;
+
+                                                       if (rc.IsRuntimeBinder && !member.DeclaringType.IsAccessible (rc))
+                                                               continue;
 
+                                                       if ((member.Modifiers & (Modifiers.PROTECTED | Modifiers.STATIC)) == Modifiers.PROTECTED &&
+                                                               instance_qualifier != null && !instance_qualifier.CheckProtectedMemberAccess (rc, member)) {
+                                                               continue;
+                                                       }
+                                               }
+
+                                               IParametersMember pm = member as IParametersMember;
+                                               if (pm == null) {
                                                        //
-                                                       // Methods in a base class are not candidates if any method in a derived
-                                                       // class is applicable
+                                                       // Will use it later to report ambiguity between best method and invocable member
                                                        //
-                                                       if ((member.Modifiers & Modifiers.OVERRIDE) != 0)
-                                                               continue;
+                                                       if (Invocation.IsMemberInvocable (member))
+                                                               invocable_member = member;
 
-                                                       if (!error_mode) {
-                                                               if (!member.IsAccessible (rc))
-                                                                       continue;
+                                                       continue;
+                                               }
 
-                                                               if (rc.IsRuntimeBinder && !member.DeclaringType.IsAccessible (rc))
-                                                                       continue;
+                                               //
+                                               // Overload resolution is looking for base member but using parameter names
+                                               // and default values from the closest member. That means to do expensive lookup
+                                               // for the closest override for virtual or abstract members
+                                               //
+                                               if ((member.Modifiers & (Modifiers.VIRTUAL | Modifiers.ABSTRACT)) != 0) {
+                                                       var override_params = base_provider.GetOverrideMemberParameters (member);
+                                                       if (override_params != null)
+                                                               pm = override_params;
+                                               }
+
+                                               //
+                                               // Check if the member candidate is applicable
+                                               //
+                                               bool params_expanded_form = false;
+                                               bool dynamic_argument = false;
+                                               TypeSpec rt = pm.MemberType;
+                                               int candidate_rate = IsApplicable (rc, ref candidate_args, args_count, ref member, pm, ref params_expanded_form, ref dynamic_argument, ref rt);
 
-                                                               if ((member.Modifiers & (Modifiers.PROTECTED | Modifiers.STATIC)) == Modifiers.PROTECTED &&
-                                                                       instance_qualifier != null && !instance_qualifier.CheckProtectedMemberAccess (rc, member)) {
+                                               if (lambda_conv_msgs != null)
+                                                       lambda_conv_msgs.EndSession ();
+
+                                               //
+                                               // How does it score compare to others
+                                               //
+                                               if (candidate_rate < best_candidate_rate) {
+
+                                                       // Fatal error (missing dependency), cannot continue
+                                                       if (candidate_rate < 0)
+                                                               return null;
+
+                                                       best_candidate_rate = candidate_rate;
+                                                       best_candidate = member;
+                                                       best_candidate_args = candidate_args;
+                                                       best_candidate_params = params_expanded_form;
+                                                       best_candidate_dynamic = dynamic_argument;
+                                                       best_parameter_member = pm;
+                                                       best_candidate_return_type = rt;
+                                               } else if (candidate_rate == 0) {
+                                                       //
+                                                       // The member look is done per type for most operations but sometimes
+                                                       // it's not possible like for binary operators overload because they
+                                                       // are unioned between 2 sides
+                                                       //
+                                                       if ((restrictions & Restrictions.BaseMembersIncluded) != 0) {
+                                                               if (TypeSpec.IsBaseClass (best_candidate.DeclaringType, member.DeclaringType, true))
                                                                        continue;
-                                                               }
                                                        }
 
-                                                       IParametersMember pm = member as IParametersMember;
-                                                       if (pm == null) {
+                                                       bool is_better;
+                                                       if (best_candidate.DeclaringType.IsInterface && member.DeclaringType.ImplementsInterface (best_candidate.DeclaringType, false)) {
+                                                               //
+                                                               // We pack all interface members into top level type which makes the overload resolution
+                                                               // more complicated for interfaces. We compensate it by removing methods with same
+                                                               // signature when building the cache hence this path should not really be hit often
                                                                //
-                                                               // Will use it later to report ambiguity between best method and invocable member
+                                                               // Example:
+                                                               // interface IA { void Foo (int arg); }
+                                                               // interface IB : IA { void Foo (params int[] args); }
                                                                //
-                                                               if (Invocation.IsMemberInvocable (member))
-                                                                       invocable_member = member;
+                                                               // IB::Foo is the best overload when calling IB.Foo (1)
+                                                               //
+                                                               is_better = true;
+                                                               if (ambiguous_candidates != null) {
+                                                                       foreach (var amb_cand in ambiguous_candidates) {
+                                                                               if (member.DeclaringType.ImplementsInterface (best_candidate.DeclaringType, false)) {
+                                                                                       continue;
+                                                                               }
 
-                                                               continue;
-                                                       }
+                                                                               is_better = false;
+                                                                               break;
+                                                                       }
 
-                                                       //
-                                                       // Overload resolution is looking for base member but using parameter names
-                                                       // and default values from the closest member. That means to do expensive lookup
-                                                       // for the closest override for virtual or abstract members
-                                                       //
-                                                       if ((member.Modifiers & (Modifiers.VIRTUAL | Modifiers.ABSTRACT)) != 0) {
-                                                               var override_params = base_provider.GetOverrideMemberParameters (member);
-                                                               if (override_params != null)
-                                                                       pm = override_params;
+                                                                       if (is_better)
+                                                                               ambiguous_candidates = null;
+                                                               }
+                                                       } else {
+                                                               // Is the new candidate better
+                                                               is_better = BetterFunction (rc, candidate_args, member, pm.Parameters, params_expanded_form, best_candidate, best_parameter_member.Parameters, best_candidate_params);
                                                        }
 
-                                                       //
-                                                       // Check if the member candidate is applicable
-                                                       //
-                                                       bool params_expanded_form = false;
-                                                       bool dynamic_argument = false;
-                                                       TypeSpec rt = pm.MemberType;
-                                                       int candidate_rate = IsApplicable (rc, ref candidate_args, args_count, ref member, pm, ref params_expanded_form, ref dynamic_argument, ref rt);
-
-                                                       //
-                                                       // How does it score compare to others
-                                                       //
-                                                       if (candidate_rate < best_candidate_rate) {
-                                                               best_candidate_rate = candidate_rate;
+                                                       if (is_better) {
                                                                best_candidate = member;
                                                                best_candidate_args = candidate_args;
                                                                best_candidate_params = params_expanded_form;
                                                                best_candidate_dynamic = dynamic_argument;
                                                                best_parameter_member = pm;
                                                                best_candidate_return_type = rt;
-                                                       } else if (candidate_rate == 0) {
-                                                               //
-                                                               // The member look is done per type for most operations but sometimes
-                                                               // it's not possible like for binary operators overload because they
-                                                               // are unioned between 2 sides
-                                                               //
-                                                               if ((restrictions & Restrictions.BaseMembersIncluded) != 0) {
-                                                                       if (TypeSpec.IsBaseClass (best_candidate.DeclaringType, member.DeclaringType, true))
-                                                                               continue;
-                                                               }
-
-                                                               bool is_better;
-                                                               if (best_candidate.DeclaringType.IsInterface && member.DeclaringType.ImplementsInterface (best_candidate.DeclaringType, false)) {
-                                                                       //
-                                                                       // We pack all interface members into top level type which makes the overload resolution
-                                                                       // more complicated for interfaces. We compensate it by removing methods with same
-                                                                       // signature when building the cache hence this path should not really be hit often
-                                                                       //
-                                                                       // Example:
-                                                                       // interface IA { void Foo (int arg); }
-                                                                       // interface IB : IA { void Foo (params int[] args); }
-                                                                       //
-                                                                       // IB::Foo is the best overload when calling IB.Foo (1)
-                                                                       //
-                                                                       is_better = true;
-                                                                       if (ambiguous_candidates != null) {
-                                                                               foreach (var amb_cand in ambiguous_candidates) {
-                                                                                       if (member.DeclaringType.ImplementsInterface (best_candidate.DeclaringType, false)) {
-                                                                                               continue;
-                                                                                       }
-
-                                                                                       is_better = false;
-                                                                                       break;
-                                                                               }
-
-                                                                               if (is_better)
-                                                                                       ambiguous_candidates = null;
-                                                                       }
-                                                               } else {
-                                                                       // Is the new candidate better
-                                                                       is_better = BetterFunction (rc, candidate_args, member, pm.Parameters, params_expanded_form, best_candidate, best_parameter_member.Parameters, best_candidate_params);
-                                                               }
+                                                       } else {
+                                                               // It's not better but any other found later could be but we are not sure yet
+                                                               if (ambiguous_candidates == null)
+                                                                       ambiguous_candidates = new List<AmbiguousCandidate> ();
 
-                                                               if (is_better) {
-                                                                       best_candidate = member;
-                                                                       best_candidate_args = candidate_args;
-                                                                       best_candidate_params = params_expanded_form;
-                                                                       best_candidate_dynamic = dynamic_argument;
-                                                                       best_parameter_member = pm;
-                                                                       best_candidate_return_type = rt;
-                                                               } else {
-                                                                       // It's not better but any other found later could be but we are not sure yet
-                                                                       if (ambiguous_candidates == null)
-                                                                               ambiguous_candidates = new List<AmbiguousCandidate> ();
-
-                                                                       ambiguous_candidates.Add (new AmbiguousCandidate (member, pm.Parameters, params_expanded_form));
-                                                               }
+                                                               ambiguous_candidates.Add (new AmbiguousCandidate (member, pm.Parameters, params_expanded_form));
                                                        }
-
-                                                       // Restore expanded arguments
-                                                       if (candidate_args != args)
-                                                               candidate_args = args;
                                                }
-                                       } while (best_candidate_rate != 0 && (type_members = base_provider.GetBaseMembers (type_members[0].DeclaringType.BaseType)) != null);
-                               } finally {
-                                       if (prev_recorder != null)
-                                               rc.Report.SetPrinter (prev_recorder);
-                               }
+
+                                               // Restore expanded arguments
+                                               if (candidate_args != args)
+                                                       candidate_args = args;
+                                       }
+                               } while (best_candidate_rate != 0 && (type_members = base_provider.GetBaseMembers (type_members[0].DeclaringType.BaseType)) != null);
 
                                //
                                // We've found exact match
@@ -4733,11 +4775,6 @@ namespace Mono.CSharp {
                        if (oa != null && !rc.IsObsolete)
                                AttributeTester.Report_ObsoleteMessage (oa, best_candidate.GetSignatureForError (), loc, rc.Report);
 
-                       var dep = best_candidate.GetMissingDependencies ();
-                       if (dep != null) {
-                               ImportedTypeDefinition.Error_MissingDependency (rc, dep, loc);
-                       }
-
                        best_candidate.MemberDefinition.SetIsUsed ();
 
                        args = best_candidate_args;
@@ -4814,9 +4851,8 @@ namespace Mono.CSharp {
                                return;
                        }
 
-                       if (lambda_conv_msgs != null) {
-                               if (lambda_conv_msgs.Merge (rc.Report.Printer))
-                                       return;
+                       if (lambda_conv_msgs != null && lambda_conv_msgs.Merge (rc.Report.Printer)) {
+                               return;
                        }
 
 
@@ -5206,14 +5242,25 @@ namespace Mono.CSharp {
 
                public override Expression CreateExpressionTree (ResolveContext ec)
                {
+                       return CreateExpressionTree (ec, true);
+               }
+
+               public Expression CreateExpressionTree (ResolveContext ec, bool convertInstance)
+               {
+                       Arguments args;
                        Expression instance;
+
                        if (InstanceExpression == null) {
                                instance = new NullLiteral (loc);
-                       } else {
+                       } else if (convertInstance) {
                                instance = InstanceExpression.CreateExpressionTree (ec);
+                       } else {
+                               args = new Arguments (1);
+                               args.Add (new Argument (InstanceExpression));
+                               instance = CreateExpressionFactoryCall (ec, "Constant", args);
                        }
 
-                       Arguments args = Arguments.CreateForExpressionTree (ec, null,
+                       args = Arguments.CreateForExpressionTree (ec, null,
                                instance,
                                CreateTypeOfExpression ());
 
@@ -5268,7 +5315,7 @@ namespace Mono.CSharp {
                        if (lvalue_instance && var != null && var.VariableInfo != null) {
                                var.VariableInfo.SetStructFieldAssigned (ec, Name);
                        }
-                       
+
                        if (fb != null) {
                                IFixedExpression fe = InstanceExpression as IFixedExpression;
                                if (!ec.HasSet (ResolveContext.Options.FixedInitializerScope) && (fe == null || !fe.IsFixed)) {
@@ -6035,7 +6082,7 @@ namespace Mono.CSharp {
                                                GetSignatureForError ());
                                } else {
                                        rc.Report.SymbolRelatedToPreviousError (best_candidate.Set);
-                                       ErrorIsInaccesible (rc, best_candidate.Set.GetSignatureForError (), loc);
+                                       ErrorIsInaccesible (rc, best_candidate.GetSignatureForError (), loc);
                                }
                        }
 
index 847a98d87e32136ced4968f13dd800729e62f932..7a025bb6c347e4a2574a788aa94744c8650aa9ec 100644 (file)
@@ -162,9 +162,9 @@ namespace Mono.CSharp {
                        Modifiers.INTERNAL |
                        Modifiers.PRIVATE;
 
-               readonly TypeExpr underlying_type_expr;
+               readonly FullNamedExpression underlying_type_expr;
 
-               public Enum (TypeContainer parent, TypeExpression type, Modifiers mod_flags, MemberName name, Attributes attrs)
+               public Enum (TypeContainer parent, FullNamedExpression type, Modifiers mod_flags, MemberName name, Attributes attrs)
                        : base (parent, name, attrs, MemberKind.Enum)
                {
                        underlying_type_expr = type;
@@ -181,7 +181,7 @@ namespace Mono.CSharp {
                        }
                }
 
-               public TypeExpr BaseTypeExpression {
+               public FullNamedExpression BaseTypeExpression {
                        get {
                                return underlying_type_expr;
                        }
index 54293eb40d4446cd68eacd776fc3aeea8b482abc..e1cb5f19ac60993bce6fe3812cd788ad308e1f55 100644 (file)
@@ -103,7 +103,12 @@ namespace Mono.CSharp
 
                protected override Expression DoResolve (ResolveContext ec)
                {
-                       return expr.Resolve (ec);
+                       var res = expr.Resolve (ec);
+                       var constant = res as Constant;
+                       if (constant != null && constant.IsLiteral)
+                               return Constant.CreateConstantFromValue (res.Type, constant.GetValue (), expr.Location);
+
+                       return res;
                }
 
                public override Expression DoResolveLValue (ResolveContext ec, Expression right_side)
@@ -142,10 +147,12 @@ namespace Mono.CSharp
                //   This routine will attempt to simplify the unary expression when the
                //   argument is a constant.
                // </summary>
-               Constant TryReduceConstant (ResolveContext ec, Constant e)
+               Constant TryReduceConstant (ResolveContext ec, Constant constant)
                {
-                       if (e is EmptyConstantCast)
-                               return TryReduceConstant (ec, ((EmptyConstantCast) e).child);
+                       var e = constant;
+
+                       while (e is EmptyConstantCast)
+                               e = ((EmptyConstantCast) e).child;
                        
                        if (e is SideEffectConstant) {
                                Constant r = TryReduceConstant (ec, ((SideEffectConstant) e).value);
@@ -220,7 +227,7 @@ namespace Mono.CSharp
                                        return new LongConstant (ec.BuiltinTypes, -lvalue, e.Location);
 
                                case BuiltinTypeSpec.Type.UInt:
-                                       UIntLiteral uil = e as UIntLiteral;
+                                       UIntLiteral uil = constant as UIntLiteral;
                                        if (uil != null) {
                                                if (uil.Value == int.MaxValue + (uint) 1)
                                                        return new IntLiteral (ec.BuiltinTypes, int.MinValue, e.Location);
@@ -230,13 +237,13 @@ namespace Mono.CSharp
 
 
                                case BuiltinTypeSpec.Type.ULong:
-                                       ULongLiteral ull = e as ULongLiteral;
+                                       ULongLiteral ull = constant as ULongLiteral;
                                        if (ull != null && ull.Value == 9223372036854775808)
                                                return new LongLiteral (ec.BuiltinTypes, long.MinValue, e.Location);
                                        return null;
 
                                case BuiltinTypeSpec.Type.Float:
-                                       FloatLiteral fl = e as FloatLiteral;
+                                       FloatLiteral fl = constant as FloatLiteral;
                                        // For better error reporting
                                        if (fl != null)
                                                return new FloatLiteral (ec.BuiltinTypes, -fl.Value, e.Location);
@@ -244,7 +251,7 @@ namespace Mono.CSharp
                                        return new FloatConstant (ec.BuiltinTypes, -((FloatConstant) e).Value, e.Location);
 
                                case BuiltinTypeSpec.Type.Double:
-                                       DoubleLiteral dl = e as DoubleLiteral;
+                                       DoubleLiteral dl = constant as DoubleLiteral;
                                        // For better error reporting
                                        if (dl != null)
                                                return new DoubleLiteral (ec.BuiltinTypes, -dl.Value, e.Location);
@@ -1687,19 +1694,19 @@ namespace Mono.CSharp
                                return null;
                        }
 
-                       eclass = ExprClass.Value;
+                       if (type.IsPointer && !ec.IsUnsafe) {
+                               UnsafeError (ec, loc);
+                       }
 
+                       eclass = ExprClass.Value;
+                       
                        Constant c = expr as Constant;
                        if (c != null) {
-                               c = c.TryReduce (ec, type, loc);
+                               c = c.TryReduce (ec, type);
                                if (c != null)
                                        return c;
                        }
 
-                       if (type.IsPointer && !ec.IsUnsafe) {
-                               UnsafeError (ec, loc);
-                       }
-
                        var res = Convert.ExplicitConversion (ec, expr, type, loc);
                        if (res == expr)
                                return EmptyCast.Create (res, type);
@@ -2654,7 +2661,7 @@ namespace Mono.CSharp
                                        return left;
                                
                                if (left.IsZeroInteger)
-                                       return left.TryReduce (ec, right.Type, loc);
+                                       return left.TryReduce (ec, right.Type);
                                
                                break;
                                
@@ -4497,7 +4504,7 @@ namespace Mono.CSharp
                        //
                        converted = GetOperatorTrue (ec, expr, loc);
                        if (converted == null) {
-                               expr.Error_ValueCannotBeConverted (ec, loc, type, false);
+                               expr.Error_ValueCannotBeConverted (ec, type, false);
                                return null;
                        }
 
@@ -4977,22 +4984,25 @@ namespace Mono.CSharp
                        return this;
                }
 
-               public override Expression DoResolveLValue (ResolveContext ec, Expression right_side)
+               public override Expression DoResolveLValue (ResolveContext ec, Expression rhs)
                {
-                       // is out param
-                       if (right_side == EmptyExpression.OutAccess)
+                       //
+                       // Don't be too pedantic when variable is used as out param or for some broken code
+                       // which uses property/indexer access to run some initialization
+                       //
+                       if (rhs == EmptyExpression.OutAccess || rhs.eclass == ExprClass.PropertyAccess || rhs.eclass == ExprClass.IndexerAccess)
                                local_info.SetIsUsed ();
 
                        if (local_info.IsReadonly && !ec.HasAny (ResolveContext.Options.FieldInitializerScope | ResolveContext.Options.UsingInitializerScope)) {
                                int code;
                                string msg;
-                               if (right_side == EmptyExpression.OutAccess) {
+                               if (rhs == EmptyExpression.OutAccess) {
                                        code = 1657; msg = "Cannot pass `{0}' as a ref or out argument because it is a `{1}'";
-                               } else if (right_side == EmptyExpression.LValueMemberAccess) {
+                               } else if (rhs == EmptyExpression.LValueMemberAccess) {
                                        code = 1654; msg = "Cannot assign to members of `{0}' because it is a `{1}'";
-                               } else if (right_side == EmptyExpression.LValueMemberOutAccess) {
+                               } else if (rhs == EmptyExpression.LValueMemberOutAccess) {
                                        code = 1655; msg = "Cannot pass members of `{0}' as ref or out arguments because it is a `{1}'";
-                               } else if (right_side == EmptyExpression.UnaryAddress) {
+                               } else if (rhs == EmptyExpression.UnaryAddress) {
                                        code = 459; msg = "Cannot take the address of {1} `{0}'";
                                } else {
                                        code = 1656; msg = "Cannot assign to `{0}' because it is a `{1}'";
@@ -5005,7 +5015,7 @@ namespace Mono.CSharp
                        if (eclass == ExprClass.Unresolved)
                                DoResolveBase (ec);
 
-                       return base.DoResolveLValue (ec, right_side);
+                       return base.DoResolveLValue (ec, rhs);
                }
 
                public override int GetHashCode ()
@@ -6954,7 +6964,7 @@ namespace Mono.CSharp
                        if (variable_info == null)
                                return;
 
-                       if (rc.HasSet (ResolveContext.Options.OmitStructFlowAnalysis))
+                       if (rc.OmitStructFlowAnalysis)
                                return;
 
                        if (!variable_info.IsAssigned (rc)) {
@@ -6982,15 +6992,7 @@ namespace Mono.CSharp
                                return null;
 
                        AnonymousMethodStorey storey = ae.Storey;
-                       while (storey != null) {
-                               AnonymousMethodStorey temp = storey.Parent as AnonymousMethodStorey;
-                               if (temp == null)
-                                       return storey.HoistedThis;
-
-                               storey = temp;
-                       }
-
-                       return null;
+                       return storey != null ? storey.HoistedThis : null;
                }
 
                public static bool IsThisAvailable (ResolveContext ec, bool ignoreAnonymous)
@@ -7019,11 +7021,20 @@ namespace Mono.CSharp
 
                        var block = ec.CurrentBlock;
                        if (block != null) {
-                               if (block.ParametersBlock.TopBlock.ThisVariable != null)
-                                       variable_info = block.ParametersBlock.TopBlock.ThisVariable.VariableInfo;
+                               var top = block.ParametersBlock.TopBlock;
+                               if (top.ThisVariable != null)
+                                       variable_info = top.ThisVariable.VariableInfo;
 
                                AnonymousExpression am = ec.CurrentAnonymousMethod;
-                               if (am != null && ec.IsVariableCapturingRequired) {
+                               if (am != null && ec.IsVariableCapturingRequired && !block.Explicit.HasCapturedThis) {
+                                       //
+                                       // Hoisted this is almost like hoisted variable but not exactly. When
+                                       // there is no variable hoisted we can simply emit an instance method
+                                       // without lifting this into a storey. Unfotunatelly this complicates
+                                       // this in other cases because we don't know where this will be hoisted
+                                       // until top-level block is fully resolved
+                                       //
+                                       top.AddThisReferenceFromChildrenBlock (block.Explicit);
                                        am.SetHasThisAccess ();
                                }
                        }
@@ -9228,11 +9239,15 @@ namespace Mono.CSharp
                        return this;
                }
 
+               public override void Error_ValueAssignment (ResolveContext rc, Expression rhs)
+               {
+               }
+
                public override void Error_UnexpectedKind (ResolveContext ec, ResolveFlags flags, Location loc)
                {
                }
 
-               public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl)
+               public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl)
                {
                }
 
index 633b834ebec7e538487acedc538eda8955c3f775..ee40532d258940fdcebd8e33eafb874913774beb 100644 (file)
@@ -1482,7 +1482,9 @@ namespace Mono.CSharp {
                        if (targs == null)
                                throw new ArgumentNullException ("targs");
 
-//                     this.state = openType.state;
+                       this.state &= ~SharedStateFlags;
+                       this.state |= (openType.state & SharedStateFlags);
+
                        this.context = context;
                        this.open_type = openType;
                        this.targs = targs;
@@ -2279,7 +2281,7 @@ namespace Mono.CSharp {
 
                //
                // Checks all type arguments againts type parameters constraints
-               // NOTE: It can run in probing mode when `mc' is null
+               // NOTE: It can run in probing mode when `this.mc' is null
                //
                public bool CheckAll (MemberSpec context, TypeSpec[] targs, TypeParameterSpec[] tparams, Location loc)
                {
@@ -2332,15 +2334,6 @@ namespace Mono.CSharp {
                        // Check the class constraint
                        //
                        if (tparam.HasTypeConstraint) {
-                               var dep = tparam.BaseType.GetMissingDependencies ();
-                               if (dep != null) {
-                                       if (mc == null)
-                                               return false;
-
-                                       ImportedTypeDefinition.Error_MissingDependency (mc, dep, loc);
-                                       ok = false;
-                               }
-
                                if (!CheckConversion (mc, context, atype, tparam, tparam.BaseType, loc)) {
                                        if (mc == null)
                                                return false;
@@ -2354,19 +2347,6 @@ namespace Mono.CSharp {
                        //
                        if (tparam.Interfaces != null) {
                                foreach (TypeSpec iface in tparam.Interfaces) {
-                                       var dep = iface.GetMissingDependencies ();
-                                       if (dep != null) {
-                                               if (mc == null)
-                                                       return false;
-
-                                               ImportedTypeDefinition.Error_MissingDependency (mc, dep, loc);
-                                               ok = false;
-
-                                               // return immediately to avoid duplicate errors because we are scanning
-                                               // expanded interface list
-                                               return false;
-                                       }
-
                                        if (!CheckConversion (mc, context, atype, tparam, iface, loc)) {
                                                if (mc == null)
                                                        return false;
index 541a407fa0444fc6efa4d3467444d6bd5ed358cf..da3e3d7c708b58de7621518b23a541139a05049d 100644 (file)
@@ -835,6 +835,13 @@ namespace Mono.CSharp
 
                        import_cache.Add (type, spec);
 
+                       if (kind == MemberKind.TypeParameter) {
+                               if (canImportBaseType)
+                                       ImportTypeParameterTypeConstraints ((TypeParameterSpec) spec, type);
+
+                               return spec;
+                       }
+
                        //
                        // Two stage setup as the base type can be inflated declaring type or
                        // another nested type inside same declaring type which has not been
@@ -992,7 +999,6 @@ namespace Mono.CSharp
                                        ImportTypeParameterTypeConstraints (tp, tp.GetMetaInfo ());
                                }
                        }
-
                }
 
                protected void ImportTypes (MetaType[] types, Namespace targetNamespace, bool hasExtensionTypes)
@@ -1796,7 +1802,15 @@ namespace Mono.CSharp
                        // or referenced from the user core in which case compilation error has to
                        // be reported because compiler cannot continue anyway
                        //
-                       foreach (var t in types) {
+                       for (int i = 0; i < types.Count; ++i) {
+                               var t = types [i];
+
+                               //
+                               // Report missing types only once per type
+                               //
+                               if (i > 0 && types.IndexOf (t) < i)
+                                       continue;
+
                                string name = t.GetSignatureForError ();
 
                                if (t.MemberDefinition.DeclaringAssembly == ctx.Module.DeclaringAssembly) {
index 6b078103ac64ee5ce28163f2ce778bb23f655761..9334ec1e6b242da394e30aef0a76c1d959504d6f 100644 (file)
 // Copyright 2011 Xamarin Inc.
 //
 
-// TODO:
-//    Flow analysis for Yield.
-//
-
 using System;
 using System.Collections.Generic;
 using Mono.CompilerServices.SymbolWriter;
@@ -566,7 +562,7 @@ namespace Mono.CSharp
                        reset.Block.AddStatement (new Throw (new New (new TypeExpression (ex_type, Location), null, Location), Location));
                }
 
-               protected override void EmitHoistedParameters (EmitContext ec, IList<HoistedParameter> hoisted)
+               protected override void EmitHoistedParameters (EmitContext ec, List<HoistedParameter> hoisted)
                {
                        base.EmitHoistedParameters (ec, hoisted);
                        base.EmitHoistedParameters (ec, hoisted_params_copy);
@@ -976,7 +972,9 @@ namespace Mono.CSharp
                        method.Block.IsCompilerGenerated = true;
                        method.Block.AddStatement (new TryFinallyBlockProxyStatement (this, block));
 
-                       storey.AddMember (method);
+                       // Cannot it add to storey because it'd be emitted before nested
+                       // anonoymous methods which could capture shared variable
+
                        return method;
                }
 
index bb0370914bed2af3e6603091c0f9f528910a520e..bdbd57a4f7d168e9337bac99e60d757be243f1db 100644 (file)
@@ -50,7 +50,7 @@ namespace Mono.CSharp
                {
                }
 
-               public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec t, bool expl)
+               public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec t, bool expl)
                {
                        if (t.IsGenericParameter) {
                                ec.Report.Error(403, loc,
@@ -65,7 +65,7 @@ namespace Mono.CSharp
                                return;
                        }
 
-                       base.Error_ValueCannotBeConverted (ec, loc, t, expl);
+                       base.Error_ValueCannotBeConverted (ec, t, expl);
                }
 
                public override string GetValueAsLiteral ()
@@ -253,7 +253,7 @@ namespace Mono.CSharp
                {
                }
 
-               public override void Error_ValueCannotBeConverted (ResolveContext ec, Location loc, TypeSpec target, bool expl)
+               public override void Error_ValueCannotBeConverted (ResolveContext ec, TypeSpec target, bool expl)
                {
                        if (target.BuiltinType == BuiltinTypeSpec.Type.Float) {
                                Error_664 (ec, loc, "float", "f");
@@ -265,7 +265,7 @@ namespace Mono.CSharp
                                return;
                        }
 
-                       base.Error_ValueCannotBeConverted (ec, loc, target, expl);
+                       base.Error_ValueCannotBeConverted (ec, target, expl);
                }
 
                static void Error_664 (ResolveContext ec, Location loc, string type, string suffix)
index b00f3f0bc070abffdff2e929894e7c3ac819c229..a6b3d1f2088cb949daa5e392bc8bccb583bba76d 100644 (file)
@@ -496,6 +496,20 @@ namespace Mono.CSharp {
                                missing.AddRange (m);
                        }
 
+                       if (Arity > 0) {
+                               foreach (var tp in GenericDefinition.TypeParameters) {
+                                       var m = tp.GetMissingDependencies ();
+
+                                       if (m == null)
+                                               continue;
+
+                                       if (missing == null)
+                                               missing = new List<TypeSpec> ();
+
+                                       missing.AddRange (m);
+                               }
+                       }
+
                        return missing;                 
                }
 
@@ -1418,8 +1432,7 @@ namespace Mono.CSharp {
                                base_ctor = ConstructorLookup (ec, type, ref argument_list, loc);
                        }
        
-                       // TODO MemberCache: Does it work for inflated types ?
-                       if (base_ctor == caller_builder.Spec){
+                       if (base_ctor != null && base_ctor.MemberDefinition == caller_builder.Spec.MemberDefinition) {
                                ec.Report.Error (516, loc, "Constructor `{0}' cannot call itself",
                                        caller_builder.GetSignatureForError ());
                        }
@@ -1951,7 +1964,7 @@ namespace Mono.CSharp {
                                                //
                                                if ((flags & MethodAttributes.MemberAccessMask) != MethodAttributes.Public) {
                                                        implementing = null;
-                                               } else if (optional && (container.Interfaces == null || Array.IndexOf (container.Interfaces, implementing.DeclaringType) < 0)) {
+                                               } else if (optional && (container.Interfaces == null || !container.Definition.Interfaces.Contains (implementing.DeclaringType))) {
                                                        //
                                                        // We are not implementing interface when base class already implemented it
                                                        //
index 02f1f2159eaa6386a3fa003dc3f461c8a6d207b8..7004013267c9e047de183e4d984ac1aaeadad42c 100644 (file)
@@ -799,8 +799,10 @@ namespace Mono.CSharp {
                                name = mn.Name;
                        }
 
+                       var names_container = Parent == null ? Module : (TypeContainer) this;
+
                        MemberCore mc;
-                       if (defined_names.TryGetValue (name, out mc)) {
+                       if (names_container.DefinedNames.TryGetValue (name, out mc)) {
                                if (tc is NamespaceContainer && mc is NamespaceContainer) {
                                        containers.Add (tc);
                                        return;
@@ -814,7 +816,7 @@ namespace Mono.CSharp {
                                                GetSignatureForError (), mn.GetSignatureForError ());
                                }
                        } else {
-                               defined_names.Add (name, tc);
+                               names_container.DefinedNames.Add (name, tc);
                        }
 
                        base.AddTypeContainer (tc);
@@ -1178,11 +1180,23 @@ namespace Mono.CSharp {
 
                                        entry.Define (this);
 
+                                       //
+                                       // It's needed for repl only, when using clause cannot be resolved don't hold it in
+                                       // global list which is resolved for each evaluation
+                                       //
+                                       if (entry.ResolvedExpression == null) {
+                                               clauses.RemoveAt (i--);
+                                               continue;
+                                       }
+
                                        Namespace using_ns = entry.ResolvedExpression as Namespace;
                                        if (using_ns == null)
                                                continue;
 
                                        if (list.Contains (using_ns)) {
+                                               // Ensure we don't report the warning multiple times in repl
+                                               clauses.RemoveAt (i--);
+
                                                Compiler.Report.Warning (105, 3, entry.Location,
                                                        "The using directive for `{0}' appeared previously in this namespace", using_ns.GetSignatureForError ());
                                        } else {
index 5afa7ea447e0d39fa86ad88254a9849a85118753..9397486a3362a1fe46b522f0300eb379c2a3d5a1 100644 (file)
@@ -860,7 +860,7 @@ namespace Mono.CSharp.Nullable
                                if (lifted_type == null)
                                        return null;
 
-                               if (left is UserCast || left is TypeCast)
+                               if (left is UserCast || left is EmptyCast || left is OpcodeCast)
                                        left.Type = lifted_type;
                                else
                                        left = EmptyCast.Create (left, lifted_type);
@@ -875,7 +875,7 @@ namespace Mono.CSharp.Nullable
                                if (r is ReducedExpression)
                                        r = ((ReducedExpression) r).OriginalExpression;
 
-                               if (r is UserCast || r is TypeCast)
+                               if (r is UserCast || r is EmptyCast || r is OpcodeCast)
                                        r.Type = lifted_type;
                                else
                                        right = EmptyCast.Create (right, lifted_type);
index e0292b6c5f4627fd020537db7612b269caf81970..365f876f0aa4f318f21cd34f114b7a1703dd8d66 100644 (file)
@@ -235,7 +235,7 @@ namespace Mono.CSharp {
 
                TemporaryVariableReference expr_tree_variable;
 
-               HoistedVariable hoisted_variant;
+               HoistedParameter hoisted_variant;
 
                public Parameter (FullNamedExpression type, string name, Modifier mod, Attributes attrs, Location loc)
                {
@@ -549,7 +549,7 @@ namespace Mono.CSharp {
                //
                // Hoisted parameter variant
                //
-               public HoistedVariable HoistedVariant {
+               public HoistedParameter HoistedVariant {
                        get {
                                return hoisted_variant;
                        }
index f4c668b88f88310c0a1d188d091dc78ae5f2b74c..c74b12739bff6300eb37fdc4b284ad213373542c 100644 (file)
@@ -1440,7 +1440,14 @@ namespace Mono.CSharp
 
                        public override MethodBuilder Define (TypeContainer parent)
                        {
-                               parameters.Resolve (this);
+                               // Disable reporting, parameters are resolved twice
+                               Report.DisableReporting ();
+                               try {
+                                       parameters.Resolve (this);
+                               } finally {
+                                       Report.EnableReporting ();
+                               }
+
                                return base.Define (parent);
                        }
 
index 50d78f0071c39faa0b7e26e8ab8c871173a859d5..26e3f4101c8764b9636b87d3e0c46200ea98433b 100644 (file)
@@ -170,12 +170,6 @@ namespace Mono.CSharp {
                        extra_information.Add (msg);
                }
 
-               public bool CheckWarningCode (string code, Location loc)
-               {
-                       Warning (1691, 1, loc, "`{0}' is not a valid warning number", code);
-                       return false;
-               }
-
                public bool CheckWarningCode (int code, Location loc)
                {
                        if (AllWarningsHashSet == null)
@@ -184,7 +178,8 @@ namespace Mono.CSharp {
                        if (AllWarningsHashSet.Contains (code))
                                return true;
 
-                       return CheckWarningCode (code.ToString (), loc);
+                       Warning (1691, 1, loc, "`{0}' is not a valid warning number", code);
+                       return false;
                }
 
                public void ExtraInformation (Location loc, string msg)
@@ -644,6 +639,11 @@ namespace Mono.CSharp {
 
                bool showFullPaths;
 
+               public void ClearSession ()
+               {
+                       session_messages = null;
+               }
+
                public override void Print (AbstractMessage msg, bool showFullPath)
                {
                        //
index 679a3ab1fe5dd3a3e27e07f107ae5556550e3def..5c5a34b9ed39df581f3ed77368e3d23da6d43828 100644 (file)
@@ -565,36 +565,22 @@ namespace Mono.CSharp {
                        source_file_index.Add (path, unit.Index);
                }
 
-               void AddWarningAsError (string warningId, CompilerSettings settings)
+               public bool ProcessWarningsList (string text, Action<int> action)
                {
-                       int id;
-                       try {
-                               id = int.Parse (warningId);
-                       } catch {
-                               report.CheckWarningCode (warningId, Location.Null);
-                               return;
-                       }
-
-                       if (!report.CheckWarningCode (id, Location.Null))
-                               return;
-
-                       settings.AddWarningAsError (id);
-               }
+                       bool valid = true;
+                       foreach (string wid in text.Split (numeric_value_separator)) {
+                               int id;
+                               if (!int.TryParse (wid, NumberStyles.AllowLeadingWhite, CultureInfo.InvariantCulture, out id)) {
+                                       report.Error (1904, "`{0}' is not a valid warning number", wid);
+                                       valid = false;
+                                       continue;
+                               }
 
-               void RemoveWarningAsError (string warningId, CompilerSettings settings)
-               {
-                       int id;
-                       try {
-                               id = int.Parse (warningId);
-                       } catch {
-                               report.CheckWarningCode (warningId, Location.Null);
-                               return;
+                               if (report.CheckWarningCode (id, Location.Null))
+                                       action (id);
                        }
 
-                       if (!report.CheckWarningCode (id, Location.Null))
-                               return;
-
-                       settings.AddWarningOnly (id);
+                       return valid;
                }
 
                void Error_RequiresArgument (string option)
@@ -997,8 +983,8 @@ namespace Mono.CSharp {
                                        settings.WarningsAreErrors = true;
                                        parser_settings.WarningsAreErrors = true;
                                } else {
-                                       foreach (string wid in value.Split (numeric_value_separator))
-                                               AddWarningAsError (wid, settings);
+                                       if (!ProcessWarningsList (value, v => settings.AddWarningAsError (v)))
+                                               return ParseResult.Error;
                                }
                                return ParseResult.Success;
 
@@ -1006,12 +992,13 @@ namespace Mono.CSharp {
                                if (value.Length == 0) {
                                        settings.WarningsAreErrors = false;
                                } else {
-                                       foreach (string wid in value.Split (numeric_value_separator))
-                                               RemoveWarningAsError (wid, settings);
+                                       if (!ProcessWarningsList (value, v => settings.AddWarningOnly (v)))
+                                               return ParseResult.Error;
                                }
                                return ParseResult.Success;
 
                        case "/warn":
+                       case "/w":
                                if (value.Length == 0) {
                                        Error_RequiresArgument (option);
                                        return ParseResult.Error;
@@ -1021,28 +1008,15 @@ namespace Mono.CSharp {
                                return ParseResult.Success;
 
                        case "/nowarn":
-                                       if (value.Length == 0) {
-                                               Error_RequiresArgument (option);
-                                               return ParseResult.Error;
-                                       }
+                               if (value.Length == 0) {
+                                       Error_RequiresArgument (option);
+                                       return ParseResult.Error;
+                               }
 
-                                       var warns = value.Split (numeric_value_separator);
-                                       foreach (string wc in warns) {
-                                               try {
-                                                       if (wc.Trim ().Length == 0)
-                                                               continue;
+                               if (!ProcessWarningsList (value, v => settings.SetIgnoreWarning (v)))
+                                       return ParseResult.Error;
 
-                                                       int warn = Int32.Parse (wc);
-                                                       if (warn < 1) {
-                                                               throw new ArgumentOutOfRangeException ("warn");
-                                                       }
-                                                       settings.SetIgnoreWarning (warn);
-                                               } catch {
-                                                       report.Error (1904, "`{0}' is not a valid warning number", wc);
-                                                       return ParseResult.Error;
-                                               }
-                                       }
-                                       return ParseResult.Success;
+                               return ParseResult.Success;
 
                        case "/noconfig":
                                settings.LoadDefaultReferences = false;
@@ -1565,7 +1539,7 @@ namespace Mono.CSharp {
                                "   -reference:A1[,An]   Imports metadata from the specified assembly (short: -r)\n" +
                                "   -reference:ALIAS=A   Imports metadata using specified extern alias (short: -r)\n" +
                                "   -sdk:VERSION         Specifies SDK version of referenced assemblies\n" +
-                               "                        VERSION can be one of: 2, 4 (default) or custom value\n" +
+                               "                        VERSION can be one of: 2, 4, 4.5 (default) or a custom value\n" +
                                "   -target:KIND         Specifies the format of the output assembly (short: -t)\n" +
                                "                        KIND can be one of: exe, winexe, library, module\n" +
                                "   -unsafe[+|-]         Allows to compile code which uses unsafe keyword\n" +
index 32ee15b003447e48a3f309ac75e311bdb7aab62e..8588c373427814f47cbc8d88f9a90a72aef3138f 100644 (file)
@@ -784,12 +784,10 @@ namespace Mono.CSharp {
 
                public sealed override bool Resolve (BlockContext ec)
                {
-                       if (!DoResolve (ec))
-                               return false;
-
+                       var res = DoResolve (ec);
                        unwind_protect = ec.CurrentBranching.AddReturnOrigin (ec.CurrentBranching.CurrentUsageVector, this);
                        ec.CurrentBranching.CurrentUsageVector.Goto ();
-                       return true;
+                       return res;
                }
        }
 
@@ -952,10 +950,9 @@ namespace Mono.CSharp {
                                                async_return.EmitAssign (ec);
 
                                                ec.EmitEpilogue ();
-
-                                               ec.Emit (unwind_protect ? OpCodes.Leave : OpCodes.Br, async_body.BodyEnd);
                                        }
 
+                                       ec.Emit (unwind_protect ? OpCodes.Leave : OpCodes.Br, async_body.BodyEnd);
                                        return;
                                }
 
@@ -1215,9 +1212,9 @@ namespace Mono.CSharp {
                                res = c;
                        } else {
                                TypeSpec type = ec.Switch.SwitchType;
-                               res = c.TryReduce (ec, type, c.Location);
+                               res = c.TryReduce (ec, type);
                                if (res == null) {
-                                       c.Error_ValueCannotBeConverted (ec, loc, type, true);
+                                       c.Error_ValueCannotBeConverted (ec, type, true);
                                        return false;
                                }
 
@@ -1438,6 +1435,7 @@ namespace Mono.CSharp {
                protected FullNamedExpression type_expr;
                protected LocalVariable li;
                protected List<Declarator> declarators;
+               TypeSpec type;
 
                public BlockVariableDeclaration (FullNamedExpression type, LocalVariable li)
                {
@@ -1514,8 +1512,7 @@ namespace Mono.CSharp {
 
                public bool Resolve (BlockContext bc, bool resolveDeclaratorInitializers)
                {
-                       if (li.Type == null) {
-                               TypeSpec type = null;
+                       if (type == null && !li.IsCompilerGenerated) {
                                var vexpr = type_expr as VarExpr;
 
                                //
@@ -1681,7 +1678,7 @@ namespace Mono.CSharp {
                                if (TypeSpec.IsReferenceType (li.Type))
                                        initializer.Error_ConstantCanBeInitializedWithNullOnly (bc, li.Type, initializer.Location, li.Name);
                                else
-                                       initializer.Error_ValueCannotBeConverted (bc, initializer.Location, li.Type, false);
+                                       initializer.Error_ValueCannotBeConverted (bc, li.Type, false);
 
                                return null;
                        }
@@ -2464,15 +2461,6 @@ namespace Mono.CSharp {
                        if (ec.CurrentAnonymousMethod is StateMachineInitializer && ParametersBlock.Original == ec.CurrentAnonymousMethod.Block.Original)
                                return ec.CurrentAnonymousMethod.Storey;
 
-                       //
-                       // When referencing a variable inside iterator where all
-                       // variables are already captured and we don't need to create
-                       // another storey context
-                       //
-                       if (ParametersBlock.am_storey is StateMachine) {
-                               return ParametersBlock.am_storey;
-                       }
-
                        if (am_storey == null) {
                                MemberBase mc = ec.MemberContext as MemberBase;
 
@@ -2487,8 +2475,7 @@ namespace Mono.CSharp {
 
                public override void Emit (EmitContext ec)
                {
-                       // TODO: The is check should go once state machine is fully separated
-                       if (am_storey != null && !(am_storey is StateMachine)) {
+                       if (am_storey != null) {
                                DefineStoreyContainer (ec, am_storey);
                                am_storey.EmitStoreyInstantiation (ec, this);
                        }
@@ -2516,22 +2503,6 @@ namespace Mono.CSharp {
                protected void DefineStoreyContainer (EmitContext ec, AnonymousMethodStorey storey)
                {
                        if (ec.CurrentAnonymousMethod != null && ec.CurrentAnonymousMethod.Storey != null) {
-                               //
-                               // Creates parent storey reference when access to hoisted this is required
-                               //
-                               var block = storey.OriginalSourceBlock;
-                               if (block.HasCapturedThis && block.Parent != null) {
-                                       var parent = block.Parent.Explicit;
-
-                                       //
-                                       // Hoisted this variable lives in top-level storey only
-                                       //
-                                       while (parent.AnonymousMethodStorey == null || parent.AnonymousMethodStorey.Parent is AnonymousMethodStorey)
-                                               parent = parent.Parent.Explicit;
-
-                                       storey.AddParentStoreyReference (ec, parent.AnonymousMethodStorey);
-                               }
-
                                storey.SetNestedStoryParent (ec.CurrentAnonymousMethod.Storey);
                                storey.Mutator = ec.CurrentAnonymousMethod.Storey.Mutator;
                        }
@@ -2542,10 +2513,72 @@ namespace Mono.CSharp {
                        storey.CreateContainer ();
                        storey.DefineContainer ();
 
+                       if (Original.Explicit.HasCapturedThis && Original.ParametersBlock.TopBlock.ThisReferencesFromChildrenBlock != null) {
+
+                               //
+                               // Only first storey in path will hold this reference. All children blocks will
+                               // reference it indirectly using $ref field
+                               //
+                               for (Block b = Original.Explicit.Parent; b != null; b = b.Parent) {
+                                       var s = b.Explicit.AnonymousMethodStorey;
+                                       if (s != null) {
+                                               storey.HoistedThis = s.HoistedThis;
+                                               break;
+                                       }
+                               }
+
+                               //
+                               // We are the first storey on path and this has to be hoisted
+                               //
+                               if (storey.HoistedThis == null) {
+                                       foreach (ExplicitBlock ref_block in Original.ParametersBlock.TopBlock.ThisReferencesFromChildrenBlock) {
+                                               //
+                                               // ThisReferencesFromChildrenBlock holds all reference even if they
+                                               // are not on this path. It saves some memory otherwise it'd have to
+                                               // be in every explicit block. We run this check to see if the reference
+                                               // is valid for this storey
+                                               //
+                                               Block block_on_path = ref_block;
+                                               for (; block_on_path != null && block_on_path != Original; block_on_path = block_on_path.Parent);
+
+                                               if (block_on_path == null)
+                                                       continue;
+
+                                               if (storey.HoistedThis == null)
+                                                       storey.AddCapturedThisField (ec);
+
+                                               for (ExplicitBlock b = ref_block; b.AnonymousMethodStorey != storey; b = b.Parent.Explicit) {
+                                                       if (b.AnonymousMethodStorey != null) {
+                                                               b.AnonymousMethodStorey.AddParentStoreyReference (ec, storey);
+                                                               b.AnonymousMethodStorey.HoistedThis = storey.HoistedThis;
+
+                                                               //
+                                                               // Stop propagation inside same top block
+                                                               //
+                                                               if (b.ParametersBlock == ParametersBlock.Original)
+                                                                       break;
+
+                                                               b = b.ParametersBlock;
+                                                       }
+
+                                                       var pb = b as ParametersBlock;
+                                                       if (pb != null && pb.StateMachine != null) {
+                                                               if (pb.StateMachine == storey)
+                                                                       break;
+
+                                                               pb.StateMachine.AddParentStoreyReference (ec, storey);
+                                                       }
+
+                                                       b.HasCapturedVariable = true;
+                                               }
+                                       }
+                               }
+                       }
+
                        var ref_blocks = storey.ReferencesFromChildrenBlock;
                        if (ref_blocks != null) {
                                foreach (ExplicitBlock ref_block in ref_blocks) {
-                                       for (ExplicitBlock b = ref_block.Explicit; b.AnonymousMethodStorey != storey; b = b.Parent.Explicit) {
+                                       for (ExplicitBlock b = ref_block; b.AnonymousMethodStorey != storey; b = b.Parent.Explicit) {
                                                if (b.AnonymousMethodStorey != null) {
                                                        b.AnonymousMethodStorey.AddParentStoreyReference (ec, storey);
 
@@ -2882,7 +2915,7 @@ namespace Mono.CSharp {
 
                public override void Emit (EmitContext ec)
                {
-                       if (state_machine != null) {
+                       if (state_machine != null && state_machine.OriginalSourceBlock != this) {
                                DefineStoreyContainer (ec, state_machine);
                                state_machine.EmitStoreyInstantiation (ec, this);
                        }
@@ -2892,7 +2925,7 @@ namespace Mono.CSharp {
 
                public void EmitEmbedded (EmitContext ec)
                {
-                       if (state_machine != null) {
+                       if (state_machine != null && state_machine.OriginalSourceBlock != this) {
                                DefineStoreyContainer (ec, state_machine);
                                state_machine.EmitStoreyInstantiation (ec, this);
                        }
@@ -3027,7 +3060,7 @@ namespace Mono.CSharp {
                        var iterator = new Iterator (this, method, host, iterator_type, is_enumerable);
                        var stateMachine = new IteratorStorey (iterator);
 
-                       am_storey = stateMachine;
+                       state_machine = stateMachine;
                        iterator.SetStateMachine (stateMachine);
 
                        var tlb = new ToplevelBlock (host.Compiler, Parameters, Location.Null);
@@ -3073,7 +3106,7 @@ namespace Mono.CSharp {
 
                        var stateMachine = new AsyncTaskStorey (this, context, initializer, returnType);
 
-                       am_storey = stateMachine;
+                       state_machine = stateMachine;
                        initializer.SetStateMachine (stateMachine);
 
                        var b = this is ToplevelBlock ?
@@ -3100,11 +3133,7 @@ namespace Mono.CSharp {
                Dictionary<string, object> names;
                Dictionary<string, object> labels;
 
-               public HoistedVariable HoistedThisVariable;
-
-               public Report Report {
-                       get { return compiler.Report; }
-               }
+               List<ExplicitBlock> this_references;
 
                public ToplevelBlock (CompilerContext ctx, Location loc)
                        : this (ctx, ParametersCompiled.EmptyReadOnlyParameters, loc)
@@ -3141,6 +3170,31 @@ namespace Mono.CSharp {
                        }
                }
 
+               public Report Report {
+                       get {
+                               return compiler.Report;
+                       }
+               }
+
+               //
+               // Used by anonymous blocks to track references of `this' variable
+               //
+               public List<ExplicitBlock> ThisReferencesFromChildrenBlock {
+                       get {
+                               return this_references;
+                       }
+               }
+
+               //
+               // Returns the "this" instance variable of this block.
+               // See AddThisVariable() for more information.
+               //
+               public LocalVariable ThisVariable {
+                       get {
+                               return this_variable;
+                       }
+               }
+
                public void AddLocalName (string name, INamedBlockVariable li, bool ignoreChildrenBlocks)
                {
                        if (names == null)
@@ -3261,6 +3315,20 @@ namespace Mono.CSharp {
                        existing_list.Add (label);
                }
 
+               public void AddThisReferenceFromChildrenBlock (ExplicitBlock block)
+               {
+                       if (this_references == null)
+                               this_references = new List<ExplicitBlock> ();
+
+                       if (!this_references.Contains (block))
+                               this_references.Add (block);
+               }
+
+               public void RemoveThisReferenceFromChildrenBlock (ExplicitBlock block)
+               {
+                       this_references.Remove (block);
+               }
+
                //
                // Creates an arguments set from all parameters, useful for method proxy calls
                //
@@ -3371,14 +3439,6 @@ namespace Mono.CSharp {
                        return null;
                }
 
-               // <summary>
-               //   Returns the "this" instance variable of this block.
-               //   See AddThisVariable() for more information.
-               // </summary>
-               public LocalVariable ThisVariable {
-                       get { return this_variable; }
-               }
-
                // <summary>
                //   This is used by non-static `struct' constructors which do not have an
                //   initializer - in this case, the constructor must initialize all of the
@@ -4469,6 +4529,12 @@ namespace Mono.CSharp {
                        ec.MarkLabel (start_finally);
 
                        if (finally_host != null) {
+                               finally_host.Define ();
+                               finally_host.Emit ();
+
+                               // Now it's safe to add, to close it properly and emit sequence points
+                               finally_host.Parent.AddMember (finally_host);
+
                                var ce = new CallEmitter ();
                                ce.InstanceExpression = new CompilerGeneratedThis (ec.CurrentType, loc);
                                ce.EmitPredefined (ec, finally_host.Spec, new Arguments (0));
@@ -4683,21 +4749,9 @@ namespace Mono.CSharp {
                                locked = false;
                        }
 
-                       using (ec.Set (ResolveContext.Options.LockScope)) {
-                               ec.StartFlowBranching (this);
-                               Statement.Resolve (ec);
-                               ec.EndFlowBranching ();
-                       }
-
-                       if (lv != null) {
-                               lv.IsLockedByStatement = locked;
-                       }
-
-                       base.Resolve (ec);
-
                        //
                        // Have to keep original lock value around to unlock same location
-                       // in the case the original has changed or is null
+                       // in the case of original value has changed or is null
                        //
                        expr_copy = TemporaryVariableReference.Create (ec.BuiltinTypes.Object, ec.CurrentBlock, loc);
                        expr_copy.Resolve (ec);
@@ -4710,6 +4764,18 @@ namespace Mono.CSharp {
                                lock_taken.Resolve (ec);
                        }
 
+                       using (ec.Set (ResolveContext.Options.LockScope)) {
+                               ec.StartFlowBranching (this);
+                               Statement.Resolve (ec);
+                               ec.EndFlowBranching ();
+                       }
+
+                       if (lv != null) {
+                               lv.IsLockedByStatement = locked;
+                       }
+
+                       base.Resolve (ec);
+
                        return true;
                }
                
@@ -6347,6 +6413,7 @@ namespace Mono.CSharp {
                        target.type = type.Clone (clonectx);
                        target.expr = expr.Clone (clonectx);
                        target.body = (Block) body.Clone (clonectx);
+                       target.statement = statement.Clone (clonectx);
                }
                
                public override object Accept (StructuralVisitor visitor)
index 7ad55a4be453bc8664a28c5ff286a488994a9e48..5df85f770f981db1648a67ee55becf6fe0aa5c4d 100644 (file)
@@ -721,6 +721,18 @@ namespace Mono.CSharp
                                }
                        }
 
+                       if (MemberDefinition.TypeParametersCount > 0) {
+                               foreach (var tp in MemberDefinition.TypeParameters) {
+                                       var tp_missing = tp.GetMissingDependencies ();
+                                       if (tp_missing != null) {
+                                               if (missing == null)
+                                                       missing = new List<TypeSpec> ();
+
+                                               missing.AddRange (tp_missing);
+                                       }
+                               }
+                       }
+
                        if (missing != null || BaseType == null)
                                return missing;
 
@@ -1333,7 +1345,7 @@ namespace Mono.CSharp
                        cache = MemberCache.Empty;
 
                        // Make all internal types CLS-compliant, non-obsolete
-                       state = (state & ~(StateFlags.CLSCompliant_Undetected | StateFlags.Obsolete_Undetected)) | StateFlags.CLSCompliant;
+                       state = (state & ~(StateFlags.CLSCompliant_Undetected | StateFlags.Obsolete_Undetected | StateFlags.MissingDependency_Undetected)) | StateFlags.CLSCompliant;
                }
 
                #region Properties
@@ -1454,11 +1466,8 @@ namespace Mono.CSharp
                {
                        this.Element = element;
 
-                       // Some flags can be copied directly from the element
-                       const StateFlags shared_flags = StateFlags.CLSCompliant | StateFlags.CLSCompliant_Undetected
-                               | StateFlags.Obsolete | StateFlags.Obsolete_Undetected | StateFlags.HasDynamicElement;
-                       state &= ~shared_flags;
-                       state |= (element.state & shared_flags);
+                       state &= ~SharedStateFlags;
+                       state |= (element.state & SharedStateFlags);
 
                        if (element.BuiltinType == BuiltinTypeSpec.Type.Dynamic)
                                state |= StateFlags.HasDynamicElement;
index 7fa0a3045dbe383ff053edeecbdf07f207ab50a1..f7ea686a46bf866445d13fa9d2784c5baf82a496 100644 (file)
@@ -2,7 +2,7 @@
 // visit.cs: Visitors for parsed dom
 //
 // Authors: Mike Krüger (mkrueger@novell.com)
-//                     Marek Safar (marek.safar@gmail.com)
+//          Marek Safar (marek.safar@gmail.com)
 //
 // Dual licensed under the terms of the MIT X11 or GNU GPL
 //
@@ -11,6 +11,7 @@
 //
 
 using System;
+using System.Diagnostics;
 
 namespace Mono.CSharp
 {
@@ -18,14 +19,21 @@ namespace Mono.CSharp
        {
                public virtual void Visit (MemberCore member)
                {
-                       Console.WriteLine ("unknown member type: " + member.GetType ());
+                       Debug.Fail ("unknown member type: " + member.GetType ());
                }
 
                void VisitTypeContainer (TypeContainer tc)
                {
-                       //foreach (var member in tc.OrderedAllMembers) {
-                       //    member.Accept (this);
-                       //}
+                       foreach (var container in tc.Containers) {
+                               container.Accept (this);
+                       }
+               }
+
+               void VisitTypeContainer (TypeDefinition tc)
+               {
+                       foreach (var member in tc.Members) {
+                               member.Accept (this);
+                       }
                }
 
                public virtual void Visit (ModuleContainer module)
@@ -33,6 +41,18 @@ namespace Mono.CSharp
                        VisitTypeContainer (module);
                }
 
+               public virtual void Visit (UsingNamespace un)
+               {
+               }
+
+               public virtual void Visit (UsingAliasNamespace uan)
+               {
+               }
+               
+               public virtual void Visit (UsingExternAlias uea)
+               {
+               }
+
                public virtual void Visit (NamespaceContainer ns)
                {
                        VisitTypeContainer (ns);
@@ -112,7 +132,7 @@ namespace Mono.CSharp
 
                public virtual object Visit (Statement stmt)
                {
-                       Console.WriteLine ("unknown statement:" + stmt);
+                       Debug.Fail ("unknown statement:" + stmt);
                        return null;
                }
                
@@ -291,7 +311,7 @@ namespace Mono.CSharp
 
                public virtual object Visit (Expression expression)
                {
-                       Console.WriteLine ("Visit unknown expression:" + expression);
+                       Debug.Fail ("Visit unknown expression:" + expression);
                        return null;
                }
 
index f6f3f8c4727912dfdb5ec05567b4ce3bfcefe06c..a17f9c284ff1b1823c39a3fc2ace622f8389947e 100644 (file)
@@ -95,6 +95,16 @@ public class ConditionalParsing
        {
                int a = (int)(A<int>.Value);
        }
+       
+       static int Test_12 (bool arg)
+       {
+               return arg ? Foo (() => { return 1; }) : 1;
+       }
+       
+       static int Foo (Func<int> arg)
+       {
+               return 1;
+       }
 
        public static void Main ()
        {
diff --git a/mcs/tests/gtest-437.cs b/mcs/tests/gtest-437.cs
deleted file mode 100644 (file)
index 45e4aba..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-// Compiler options: -unsafe
-
-using System;
-using System.Reflection;
-
-class C
-{
-       public static int Main ()
-       {
-               object[] o = Assembly.GetExecutingAssembly ().GetCustomAttributes (typeof (System.Security.Permissions.SecurityPermissionAttribute), false);
-               if (o.Length != 1)
-                       return 1;
-
-               System.Security.Permissions.SecurityPermissionAttribute a = (System.Security.Permissions.SecurityPermissionAttribute) o[0];
-
-               if (a.Action != System.Security.Permissions.SecurityAction.RequestMinimum)
-                       return 2;
-
-               if (!a.SkipVerification)
-                       return 3;
-
-               Console.WriteLine (a);
-               return 0;
-       }
-}
\ No newline at end of file
diff --git a/mcs/tests/gtest-567.cs b/mcs/tests/gtest-567.cs
new file mode 100644 (file)
index 0000000..9c1dac2
--- /dev/null
@@ -0,0 +1,26 @@
+using System;
+
+class C
+{
+       public static void Main ()
+       {
+               G<C>.Foo ();
+               G2<C>.Foo ();
+       }
+}
+
+class G<T> where T : new ()
+{
+       public static void Foo ()
+       {
+               Console.WriteLine ((new T ()).GetType ().ToString ());
+       }
+}
+
+class G2<T> where T : class, new ()
+{
+       public static void Foo ()
+       {
+               Console.WriteLine ((new T ()).GetType ().ToString ());
+       }
+}
diff --git a/mcs/tests/gtest-568.cs b/mcs/tests/gtest-568.cs
new file mode 100644 (file)
index 0000000..9fb73a4
--- /dev/null
@@ -0,0 +1,20 @@
+using System;
+
+class X
+{
+       static int Main ()
+       {
+               object o = 10;
+               int? x = 3;
+
+               if ((int) o < x) {
+                       return 1;
+               }
+               
+               if (x > (int) o) {
+                       return 2;
+               }
+               
+               return 0;
+       }
+}
index 18854ead8dbe9a07fdc39eb41d197d028ed72f5c..c511e8580617eb6c0a8312dd2109422878ec9267 100644 (file)
@@ -1557,6 +1557,15 @@ class Tester
                Assert (false, e8.Compile ().Invoke (MyEnum.Value_2, MyEnum.Value_2));
        }
 
+       void LessThanTest_9 ()
+       {
+               Expression<Func<object, int?, bool>> e = (a, b) => (int) a < b;
+               AssertNodeType (e, ExpressionType.LessThan);
+               Assert (false, e.Compile ().Invoke (1, null));
+               Assert (false, e.Compile ().Invoke (3, 3));
+               Assert (true, e.Compile ().Invoke (1, 3));
+       }
+
        void LessThanOrEqualTest ()
        {
                Expression<Func<int, int, bool>> e = (int a, int b) => a <= b;
diff --git a/mcs/tests/gtest-exmethod-43.cs b/mcs/tests/gtest-exmethod-43.cs
new file mode 100644 (file)
index 0000000..ea4de7c
--- /dev/null
@@ -0,0 +1,28 @@
+public class AdapterType
+{
+       protected virtual void DoSomething ()
+       {
+       }
+}
+
+public static class Extensions
+{
+       public static void DoSomething (this AdapterType obj)
+       {
+       }
+}
+
+public abstract class Dummy : AdapterType
+{
+       public virtual bool Refresh ()
+       {
+               AdapterType someObj = null;
+               someObj.DoSomething ();
+               return true;
+       }
+
+       public static void Main ()
+       {
+
+       }
+}
\ No newline at end of file
diff --git a/mcs/tests/gtest-iter-23.cs b/mcs/tests/gtest-iter-23.cs
new file mode 100644 (file)
index 0000000..98ae94b
--- /dev/null
@@ -0,0 +1,55 @@
+using System;
+using System.Collections.Generic;
+
+class C
+{
+       static IEnumerable<int> Test ()
+       {
+               List<Func<int>> lambdas = new List<Func<int>> ();
+               for (int i = 0; i < 4; ++i) {
+                       int h = i;
+                       lambdas.Add (() => h);
+                       yield return 2;
+               }
+
+               for (int i = 0; i < 4; ++i) {
+                       yield return lambdas[i] ();
+               }
+       }
+
+       static IEnumerable<int> Test_2 ()
+       {
+               List<Func<int>> lambdas = new List<Func<int>> ();
+               for (int i = 0; i < 4; ++i) {
+                       int h = i;
+                       lambdas.Add (() => h);
+               }
+
+               for (int i = 0; i < 4; ++i) {
+                       yield return lambdas[i] ();
+               }
+       }
+
+       public static int Main ()
+       {
+               int t = 0;
+               foreach (var a in Test ()) {
+                       t += a;
+               }
+
+               Console.WriteLine (t);
+               if (t != 14)
+                       return 1;
+
+               t = 0;
+               foreach (var a in Test_2 ()) {
+                       t += a;
+               }
+
+               Console.WriteLine (t);
+               if (t != 6)
+                       return 2;
+
+               return 0;
+       }
+}
\ No newline at end of file
diff --git a/mcs/tests/gtest-iter-24.cs b/mcs/tests/gtest-iter-24.cs
new file mode 100644 (file)
index 0000000..3fee4f7
--- /dev/null
@@ -0,0 +1,35 @@
+using System;
+using System.Collections.Generic;
+
+public class B : IDisposable
+{
+       public void Dispose ()
+       {
+       }
+
+       public void DoSomething ()
+       {
+       }
+}
+
+public class C
+{
+       public static IEnumerable<int> Test ()
+       {
+               using (var b = new B ()) {
+                       Action a = () => b.DoSomething ();
+                       a ();
+
+                       yield return 1;
+               }
+       }
+       
+       public static int Main ()
+       {
+               foreach (var e in Test ()) {
+                       Console.WriteLine (e);
+               }
+               
+               return 0;
+       }
+}
diff --git a/mcs/tests/gtest-iter-25.cs b/mcs/tests/gtest-iter-25.cs
new file mode 100644 (file)
index 0000000..4d039a0
--- /dev/null
@@ -0,0 +1,21 @@
+using System.Collections.Generic;
+
+namespace Test
+{
+       public static class Program
+       {
+               public static void Main ()
+               {
+                       foreach (var a in Test ())
+                               Test ();
+               }
+
+               public static IEnumerable<object> Test ()
+               {
+                       lock (new object ()) {
+                               yield return null;
+                               yield break;
+                       }
+               }
+       }
+}
\ No newline at end of file
index 05ff2071ba225390dab0c3de1a4ccf9d4a9e66c2..51d0b2086fda73f48a672f0c03f5224f8d26104f 100644 (file)
@@ -5,6 +5,3 @@
 # csXXXX.cs IGNORE     : adds test to ignore list
 
 gtest-230.cs
-gtest-437.cs
-
-test-106.cs bug #628662
diff --git a/mcs/tests/test-106.cs b/mcs/tests/test-106.cs
deleted file mode 100644 (file)
index c4d7a77..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-using System;
-using System.Threading;
-using System.Runtime.InteropServices;
-
-class Test
-{
-       delegate int SimpleDelegate (int a);
-
-       static int cb_state = 0;
-
-       static int F (int a)
-       {
-               Console.WriteLine ("Test.F from delegate: " + a);
-               throw new NotImplementedException ("F");
-       }
-
-       static void async_callback (IAsyncResult ar)
-       {
-               Console.WriteLine ("Async Callback " + ar.AsyncState);
-               cb_state = 1;
-       }
-
-       static int Main ()
-       {
-               SimpleDelegate d = new SimpleDelegate (F);
-               AsyncCallback ac = new AsyncCallback (async_callback);
-               string state1 = "STATE1";
-               int res = 0;
-
-               // Call delegate via ThreadPool and check that the exception is rethrown correctly
-               IAsyncResult ar1 = d.BeginInvoke (1, ac, state1);
-
-               while (cb_state == 0)
-                       Thread.Sleep (0);
-
-               try {
-                       res = d.EndInvoke (ar1);
-                       Console.WriteLine ("NO EXCEPTION");
-                       return 1;
-               } catch (NotImplementedException) {
-                       Console.WriteLine ("received exception ... OK");
-               }
-
-               return 0;
-       }
-}
index 11cf4b70e2c20654cba3f5511e36de535c997986..92fd6914b4518969ea02a0da30d313bafaebd5a5 100644 (file)
@@ -11,7 +11,20 @@ class X {
                int b = -2147483648;
                long c = -9223372036854775808;
                sbyte d = -128;
+               
+               object o = -(2147483648);
+               if (o.GetType () != typeof (long))
+                       return 1;
 
+               o = -(uint)2147483648;
+               Console.WriteLine (o.GetType ());
+               if (o.GetType () != typeof (long))
+                       return 2;
+
+               uint ui = (1);
+               byte b1 = (int)(0x30);
+               byte b2 = (int)0x30;
+               
                return 0;
        }
 }
index 70d1edd01f9fab31f699c490ee2b5f693eab40b2..9ce875854eb10f6f3bc5a5347b87e4b51c95f88d 100644 (file)
@@ -1,4 +1,4 @@
-// Compiler options: -warnaserror -warn:2
+// Compiler options: -warnaserror -w:2
 
 using System;
 class X {
index 85d97c4a3ace25cf08c0abeb8091ab070af352b5..209b938b1df0444cbacfb82fbc01f5ddad2212b8 100644 (file)
@@ -50,7 +50,7 @@
   .method private hidebysig specialname
           instance void  PrivateMissing(class ['missing-lib']XX p) cil managed
   {
-    IL_0000:  ret
+    ret
   }
 }
 
   } 
 }
 
+.class public auto ansi beforefieldinit Overload
+       extends [mscorlib]System.Object
+{
+  .method public hidebysig static void  Test(object o) cil managed
+  {
+    ret
+  }
+
+  .method public hidebysig static void  Test(object o, class ['missing-lib']XX arg) cil managed
+  {
+    ret
+  }
+
+  .method public hidebysig specialname rtspecialname 
+          instance void  .ctor() cil managed
+  {
+    ret
+  }
+
+}
+
index be77f30e8461eb2876ae42ed523c0b4c07990bf0..bab6bbe28809d1b2b63c6a5d859e3793e8e99fe1 100644 (file)
@@ -10,6 +10,8 @@ class Program
                
                var s = new MultipleSameNames ();
                s.AA = "1";
+               
+               Overload.Test (1);
        }
        
        void Test2 (IMemberDelayed md)
index ba533cee22545449439f8e255171239147b1b588..9654d6dc6e6c1c77a907f80a41048a01cd2c1ab5 100644 (file)
@@ -1,3 +1,5 @@
+// Compiler options: -warnaserror
+
 using System;
 using System.Reflection;
 
index cba7b21db668751891304313b0169b3d735b605b..b77d98d7290aa96168dd4197bcbb6809df7fe9c8 100644 (file)
@@ -8,6 +8,17 @@ struct S
 {
 }
 
+class C2
+{
+       S s;
+       
+       void Foo ()
+       {
+               Func<string> f = s.ToString;
+               Console.WriteLine (f);
+       }
+}
+
 [Foo (Product = "Mono")]
 class Program
 {
diff --git a/mcs/tests/test-844.cs b/mcs/tests/test-844.cs
new file mode 100644 (file)
index 0000000..1f7e5fa
--- /dev/null
@@ -0,0 +1,27 @@
+// Compiler options: -warn:4 -warnaserror
+
+// Checks no CS0219 warning is issued
+
+class C
+{
+       int Prop { get { return 4; } }
+
+       int this[char arg] { get { return 2; } }
+
+       static void Foo (ref int arg)
+       {
+       }
+
+       public void Method (int i)
+       {
+               long p1 = Prop;
+               long p2 = new C ()['h'];
+
+               int arg = 1;
+               Foo (ref arg);
+       }
+
+       public static void Main ()
+       {
+       }
+}
diff --git a/mcs/tests/test-845.cs b/mcs/tests/test-845.cs
new file mode 100644 (file)
index 0000000..cab9004
--- /dev/null
@@ -0,0 +1,51 @@
+interface IA
+{
+}
+
+interface IB
+{
+       int Foo ();
+       int Foo2 ();
+}
+
+interface IC : IA, IB
+{
+}
+
+class C1 : IA, IB
+{
+       public int Foo ()
+       {
+               return 5;
+       }
+       
+       public int Foo2 ()
+       {
+               return 55;
+       }
+}
+
+class C2 : C1, IC
+{
+       public new int Foo ()
+       {
+               return 2;
+       }
+       
+       public int Foo2 ()
+       {
+               return 2;
+       }
+
+       public static int Main ()
+       {
+               IC ic = new C2 ();
+               if (ic.Foo () != 2)
+                       return 1;
+
+               if (ic.Foo2 () != 2)
+                       return 2;
+               
+               return 0;
+       }
+}
\ No newline at end of file
diff --git a/mcs/tests/test-anon-170.cs b/mcs/tests/test-anon-170.cs
new file mode 100644 (file)
index 0000000..ef239d3
--- /dev/null
@@ -0,0 +1,48 @@
+using System;
+
+public class MyClass
+{
+       Func<int> ll;
+
+       int Test (int a)
+       {
+               return 1;
+       }
+
+       public void Run ()
+       {
+               Action<int> a = l => {
+                       ll = () => l;
+               };
+
+               a (1);
+
+               Action<int> a2 = l => {
+                       ll = () => l;
+               };
+
+               a2 (2);
+       }
+
+       public void Run2 ()
+       {
+               Action<int> a = l => {
+                       ll = () => Test (l);
+               };
+
+               a (1);
+
+               Action<int> a2 = l => {
+                       ll = () => Test (l);
+               };
+
+               a2 (1);
+       }
+
+       public static void Main ()
+       {
+               var mc = new MyClass ();
+               mc.Run ();
+               mc.Run2 ();
+       }
+}
\ No newline at end of file
index ed5d3ebe448767636cafda848b3c13dd36de51f6..c702827bba35e8ec1a81ec6425e1efb859a8a766 100644 (file)
@@ -1,5 +1,3 @@
-// Compiler options: -langversion:future
-
 using System;
 using System.Threading;
 using System.Threading.Tasks;
@@ -10,6 +8,12 @@ class MyContext : SynchronizationContext
        public int Completed;
        public int PostCounter;
        public int SendCounter;
+       ManualResetEvent mre;
+       
+       public MyContext (ManualResetEvent mre)
+       {
+               this.mre = mre;
+       }
 
        public override void OperationStarted ()
        {
@@ -26,6 +30,7 @@ class MyContext : SynchronizationContext
        public override void Post (SendOrPostCallback d, object state)
        {
                ++PostCounter;
+               mre.Set ();
                base.Post (d, state);
        }
 
@@ -39,19 +44,28 @@ class MyContext : SynchronizationContext
 
 public class TestPostContext
 {
+       static ManualResetEvent await_mre;
+       
        static async Task<int> Test ()
        {
-               return await Task.Factory.StartNew (() => 1);
+               return await Task.Factory.StartNew (() => { await_mre.WaitOne(); return 1; });
        }
 
        public static int Main ()
        {
-               var context = new MyContext ();
+               var mre = new ManualResetEvent (false);
+               await_mre = new ManualResetEvent (false);
+               var context = new MyContext (mre);
                try {
                        SynchronizationContext.SetSynchronizationContext (context);
                        var t = Test ();
-                       if (!t.Wait (1000))
+                       await_mre.Set ();
+                       if (!t.Wait (3000))
                                return 3;
+                               
+                       // Wait is needed because synchronization is executed as continuation (once task finished)
+                       if (!mre.WaitOne (3000))
+                               return 2;
                } finally {
                        SynchronizationContext.SetSynchronizationContext (null);
                }
@@ -59,9 +73,6 @@ public class TestPostContext
                if (context.Started != 0 || context.Completed != 0 || context.SendCounter != 0)
                        return 1;
 
-               if (context.PostCounter != 1)
-                       return 2;
-
                Console.WriteLine ("ok");
                return 0;
        }
diff --git a/mcs/tests/test-async-31.cs b/mcs/tests/test-async-31.cs
new file mode 100644 (file)
index 0000000..bbff8e3
--- /dev/null
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Threading.Tasks;
+
+class C
+{
+       async Task<int> M(int v)
+       {
+               {
+                       await Task.Yield();
+                       int vv = 0;
+                       Func<int> a = () => vv;
+                       vv = 3;
+                       Func<int> a2 = () => v + vv;
+                       if (a() != vv)
+                               return 1;
+
+                       if (a2() != 58)
+                               return 2;
+               }
+               return 0;
+       }
+
+       async Task<int> M2(int v, int o)
+       {
+               await Task.Yield();
+               var xo = await Task.FromResult(v);
+               int vv = v;
+               Action a2;
+               int b = o;
+               {
+                       a2 = () => {
+                               v = 500;
+                               b = 2;
+                       };
+               }
+
+               await Task.Yield();
+               a2 ();
+               if (v != 500)
+                       return 1;
+
+               return 0;
+       }
+       
+       public static int Main()
+       {
+               var c = new C();
+               if (c.M(55).Result != 0)
+                       return 1;
+
+               if (c.M2(55, 22).Result != 0)
+                       return 2;
+
+               return 0;
+       }
+}
diff --git a/mcs/tests/test-async-32.cs b/mcs/tests/test-async-32.cs
new file mode 100644 (file)
index 0000000..f0e3fc6
--- /dev/null
@@ -0,0 +1,74 @@
+using System;
+using System.Threading;
+using System.Threading.Tasks;
+
+class Program
+{
+       static async Task<int> TestCanceled()
+       {
+               await Task.FromResult(1);
+               throw new OperationCanceledException();
+       }
+
+       static async Task TestCanceled_2()
+       {
+               await Task.FromResult(1);
+               throw new OperationCanceledException();
+       }
+
+       static async Task<int> TestException()
+       {
+               await Task.FromResult(1);
+               throw new ApplicationException();
+       }
+
+       static int Main()
+       {
+               bool canceled = false;
+               var t = TestCanceled().ContinueWith(l =>
+               {
+                       canceled = l.IsCanceled;
+               }, TaskContinuationOptions.ExecuteSynchronously);
+
+               t.Wait();
+
+               if (!canceled)
+                       return 1;
+
+               if (t.Exception != null)
+                       return 2;
+
+               t = TestCanceled_2().ContinueWith(l =>
+               {
+                       canceled = l.IsCanceled;
+               }, TaskContinuationOptions.ExecuteSynchronously);
+
+               t.Wait();
+
+               if (!canceled)
+                       return 11;
+
+               if (t.Exception != null)
+                       return 12;
+
+               bool faulted = false;
+               bool has_exception = false;
+               t = TestException().ContinueWith(l =>
+               {
+                       faulted = l.IsFaulted;
+                       has_exception = l.Exception != null; // Has to observe it or will throw on shutdown
+               }, TaskContinuationOptions.ExecuteSynchronously);
+
+               if (!faulted)
+                       return 21;
+                       
+               if (!has_exception)
+                       return 22;
+
+               if (t.Exception != null)
+                       return 23;
+
+               Console.WriteLine("ok");
+               return 0;
+       }
+}
diff --git a/mcs/tests/test-async-33.cs b/mcs/tests/test-async-33.cs
new file mode 100644 (file)
index 0000000..f43a3fe
--- /dev/null
@@ -0,0 +1,52 @@
+using System;
+using System.Threading;
+using System.Threading.Tasks;
+
+class A
+{
+       public virtual Task<int> Foo (int value)
+       {
+               return Task.FromResult (value);
+       }
+       
+       public virtual Task<int> Prop { get; set; }
+}
+
+class B : A
+{
+       public override Task<int> Prop {
+               get {
+                       throw new ApplicationException ();
+               }
+               set {
+                       throw new ApplicationException ();
+               }
+       }
+       
+       public override async Task<int> Foo (int value)
+       {
+               return await base.Foo (value) + 1;
+       }
+       
+       public async Task<int> Foo2 (int value)
+       {
+               base.Prop = Task.FromResult (value);
+               return await base.Prop;
+       }
+}
+
+class Program
+{
+       static int Main()
+       {
+               var b = new B ();
+               if (b.Foo (3).Result != 4)
+                       return 1;
+               
+               if (b.Foo2 (5).Result != 5)
+                       return 2;
+               
+               Console.WriteLine("ok");
+               return 0;
+       }
+}
diff --git a/mcs/tests/test-async-34.cs b/mcs/tests/test-async-34.cs
new file mode 100644 (file)
index 0000000..c40f750
--- /dev/null
@@ -0,0 +1,38 @@
+using System;
+using System.Threading.Tasks;
+
+class C
+{
+       static int called;
+       
+       public static async Task Test (bool arg)
+       {
+               if (arg)
+                       return;
+               
+               called++;
+               await Task.FromResult (1);
+       }
+       
+       
+       public static async Task Test2 (bool arg)
+       {
+               if (arg)
+                       return;
+               
+               called++;
+       }
+
+       public static int Main ()
+       {
+               Test (true).Wait ();
+               if (called != 0)
+                       return 1;
+               
+               Test2 (true).Wait ();
+               if (called != 0)
+                       return 2;
+               
+               return 0;
+       }
+}
\ No newline at end of file
index bc55a4be9a7950f53d76ab9398f724b36a395872..ae145805f9210a277fd98ac950cafb6b38cb4806 100644 (file)
@@ -69,7 +69,7 @@
       <sequencepoints>
         <entry il="0x21" row="11" file_ref="1" hidden="false" />
         <entry il="0x22" row="12" file_ref="1" hidden="false" />
-        <entry il="0x8c" row="13" file_ref="1" hidden="false" />
+        <entry il="0x89" row="13" file_ref="1" hidden="false" />
       </sequencepoints>
       <locals />
       <scopes />
       <scopes />
     </method>
     <method token="0x600000c">
-      <sequencepoints />
-      <locals />
-      <scopes />
-    </method>
-    <method token="0x600000d">
       <sequencepoints>
         <entry il="0x21" row="24" file_ref="1" hidden="false" />
         <entry il="0x22" row="25" file_ref="1" hidden="false" />
-        <entry il="0x92" row="26" file_ref="1" hidden="false" />
+        <entry il="0x8f" row="26" file_ref="1" hidden="false" />
       </sequencepoints>
       <locals />
       <scopes />
     </method>
-    <method token="0x600000e">
-      <sequencepoints />
-      <locals />
-      <scopes />
-    </method>
-    <method token="0x600000f">
+    <method token="0x600000d">
       <sequencepoints />
       <locals />
       <scopes />
     </method>
-    <method token="0x6000010">
+    <method token="0x600000e">
       <sequencepoints>
         <entry il="0x21" row="34" file_ref="1" hidden="false" />
         <entry il="0x22" row="35" file_ref="1" hidden="false" />
         <entry il="0x2d" row="36" file_ref="1" hidden="false" />
         <entry il="0x8b" row="37" file_ref="1" hidden="false" />
-        <entry il="0x3b1" row="38" file_ref="1" hidden="false" />
-        <entry il="0x4c1" row="39" file_ref="1" hidden="false" />
+        <entry il="0x3ab" row="38" file_ref="1" hidden="false" />
+        <entry il="0x4b9" row="39" file_ref="1" hidden="false" />
       </sequencepoints>
       <locals />
       <scopes />
     </method>
-    <method token="0x6000011">
-      <sequencepoints />
-      <locals />
-      <scopes />
-    </method>
-    <method token="0x6000012">
+    <method token="0x600000f">
       <sequencepoints />
       <locals />
       <scopes />
     </method>
-    <method token="0x6000013">
+    <method token="0x6000010">
       <sequencepoints>
         <entry il="0x0" row="37" file_ref="1" hidden="false" />
       </sequencepoints>
index ce4fbe37afe106209e602ec08b492dfbc5a31721..4db6d5a0f4de8d20be2894c4fca21a7d358e53f5 100644 (file)
       <scopes />
     </method>
     <method token="0x6000008">
-      <sequencepoints>
-        <entry il="0x0" row="14" file_ref="1" hidden="false" />
-        <entry il="0x1" row="15" file_ref="1" hidden="false" />
-        <entry il="0xb" row="16" file_ref="1" hidden="false" />
-      </sequencepoints>
-      <locals />
-      <scopes>
-        <entry index="0" start="0x1" end="0xb" />
-      </scopes>
-    </method>
-    <method token="0x6000009">
       <sequencepoints>
         <entry il="0x27" row="7" file_ref="1" hidden="false" />
         <entry il="0x28" row="8" file_ref="1" hidden="false" />
         <entry index="0" start="0x42" end="0x5f" />
       </scopes>
     </method>
+    <method token="0x6000009">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
     <method token="0x600000a">
       <sequencepoints />
       <locals />
       <scopes />
     </method>
     <method token="0x600000c">
-      <sequencepoints />
+      <sequencepoints>
+        <entry il="0x0" row="14" file_ref="1" hidden="false" />
+        <entry il="0x1" row="15" file_ref="1" hidden="false" />
+        <entry il="0xb" row="16" file_ref="1" hidden="false" />
+      </sequencepoints>
       <locals />
-      <scopes />
+      <scopes>
+        <entry index="0" start="0x1" end="0xb" />
+      </scopes>
     </method>
   </methods>
 </symbols>
\ No newline at end of file
diff --git a/mcs/tests/test-debug-22-ref.xml b/mcs/tests/test-debug-22-ref.xml
new file mode 100644 (file)
index 0000000..2c5302f
--- /dev/null
@@ -0,0 +1,97 @@
+<?xml version="1.0" encoding="utf-8"?>
+<symbols>
+  <files>
+    <file id="1" name="test-debug-22.cs" checksum="99a9229428607a7f60b12ec05c5c17bb" />
+  </files>
+  <methods>
+    <method token="0x6000001">
+      <sequencepoints>
+        <entry il="0x0" row="7" file_ref="1" hidden="false" />
+        <entry il="0x1" row="8" file_ref="1" hidden="false" />
+        <entry il="0x8" row="9" file_ref="1" hidden="false" />
+      </sequencepoints>
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x6000002">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x6000003">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x6000004">
+      <sequencepoints>
+        <entry il="0x0" row="20" file_ref="1" hidden="false" />
+        <entry il="0x1" row="21" file_ref="1" hidden="false" />
+      </sequencepoints>
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x6000005">
+      <sequencepoints>
+        <entry il="0x0" row="25" file_ref="1" hidden="false" />
+        <entry il="0x1" row="26" file_ref="1" hidden="false" />
+      </sequencepoints>
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x6000006">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x6000007">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x6000008">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x6000009">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x600000a">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x600000b">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x600000c">
+      <sequencepoints>
+        <entry il="0x21" row="15" file_ref="1" hidden="false" />
+        <entry il="0x22" row="16" file_ref="1" hidden="false" />
+        <entry il="0x47" row="17" file_ref="1" hidden="false" />
+      </sequencepoints>
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x600000d">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x600000e">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+    <method token="0x600000f">
+      <sequencepoints />
+      <locals />
+      <scopes />
+    </method>
+  </methods>
+</symbols>
\ No newline at end of file
diff --git a/mcs/tests/test-debug-22.cs b/mcs/tests/test-debug-22.cs
new file mode 100644 (file)
index 0000000..fb45dcc
--- /dev/null
@@ -0,0 +1,27 @@
+using System;
+using System.Collections.Generic;
+
+class A
+{
+       public virtual int Foo ()
+       {
+               return 4;
+       }
+}
+
+class C : A
+{
+       public IEnumerable<int> GetIter ()
+       {
+               yield return base.Foo ();
+       }
+
+       public override int Foo ()
+       {
+               throw new ApplicationException ();
+       }
+
+       public static void Main ()
+       {
+       }
+}
\ No newline at end of file
diff --git a/mcs/tests/test-xml-066-ref.xml b/mcs/tests/test-xml-066-ref.xml
new file mode 100644 (file)
index 0000000..946b754
--- /dev/null
@@ -0,0 +1,10 @@
+<?xml version="1.0"?>\r
+<doc>\r
+    <assembly>\r
+        <name>test-xml-066</name>\r
+    </assembly>\r
+    <members>\r
+        <member name="M:C.Foo2``1(System.Int32,``0)">\r
+            <seealso cref="M:C.Foo``2(System.Int32,``0,``1[])" /></member>\r
+    </members>\r
+</doc>\r
diff --git a/mcs/tests/test-xml-066.cs b/mcs/tests/test-xml-066.cs
new file mode 100644 (file)
index 0000000..be2256e
--- /dev/null
@@ -0,0 +1,17 @@
+// Compiler options: -doc:xml-066.xml
+
+static class C
+{
+       static void Foo<T, U> (this int a, T t, U[] u)
+       {
+       }
+       
+       /// <seealso cref="Foo{T0,U2}(int,T0,U2[])"/>
+       static void Foo2<T> (this int a, T t)
+       {
+       }
+       
+       public static void Main ()
+       {
+       }
+}
\ No newline at end of file
index 7aa220511e56dbdf0d20743ee8f379d8b44e7e0e..ccbfe8523fb47fbf9ee9967771f6c5bfc123e6ce 100644 (file)
         <size>7</size>
       </method>
     </type>
+    <type name="ConditionalParsing">
+      <method name="Int32 Test_12(Boolean)" attrs="145">
+        <size>55</size>
+      </method>
+      <method name="Int32 Foo(System.Func`1[System.Int32])" attrs="145">
+        <size>10</size>
+      </method>
+      <method name="Int32 &lt;Test_12&gt;m__0()" attrs="145">
+        <size>10</size>
+      </method>
+    </type>
   </test>
   <test name="gtest-410.cs">
     <type name="Program">
       </method>
     </type>
   </test>
+  <test name="gtest-567.cs">
+    <type name="C">
+      <method name="Void Main()" attrs="150">
+        <size>12</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="G`1[T]">
+      <method name="Void Foo()" attrs="150">
+        <size>61</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="G2`1[T]">
+      <method name="Void Foo()" attrs="150">
+        <size>31</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
+  <test name="gtest-568.cs">
+    <type name="X">
+      <method name="Int32 Main()" attrs="145">
+        <size>111</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
   <test name="gtest-anontype-01.cs">
     <type name="Test">
       <method name="Int32 Main()" attrs="145">
         <size>21</size>
       </method>
     </type>
+    <type name="Tester">
+      <method name="Void LessThanTest_9()" attrs="129">
+        <size>199</size>
+      </method>
+    </type>
   </test>
   <test name="gtest-etree-02.cs">
     <type name="M">
         <size>40</size>
       </method>
       <method name="Boolean MoveNext()" attrs="486">
-        <size>115</size>
+        <size>148</size>
       </method>
       <method name="Void Dispose()" attrs="486">
         <size>15</size>
         <size>7</size>
       </method>
     </type>
+    <type name="Program+&lt;Test&gt;c__Iterator0`1+&lt;Test&gt;c__AnonStorey1`1[T]">
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
   </test>
   <test name="gtest-etree-14.cs">
     <type name="Person">
         <size>52</size>
       </method>
       <method name="Boolean MoveNext()" attrs="486">
-        <size>303</size>
+        <size>336</size>
       </method>
       <method name="Void Dispose()" attrs="486">
         <size>69</size>
         <size>7</size>
       </method>
     </type>
+    <type name="Repro+&lt;GetPersons&gt;c__Iterator0`1+&lt;GetPersons&gt;c__AnonStorey1`1[T]">
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
   </test>
   <test name="gtest-etree-15.cs">
     <type name="Foo">
       </method>
     </type>
   </test>
+  <test name="gtest-exmethod-43.cs">
+    <type name="AdapterType">
+      <method name="Void DoSomething()" attrs="452">
+        <size>2</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Extensions">
+      <method name="Void DoSomething(AdapterType)" attrs="150">
+        <size>2</size>
+      </method>
+    </type>
+    <type name="Dummy">
+      <method name="Boolean Refresh()" attrs="454">
+        <size>18</size>
+      </method>
+      <method name="Void Main()" attrs="150">
+        <size>2</size>
+      </method>
+      <method name="Void .ctor()" attrs="6276">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
   <test name="gtest-fixedbuffer-01.cs">
     <type name="TestNew">
       <method name="Void SetTest()" attrs="134">
         <size>26</size>
       </method>
       <method name="Void &lt;&gt;__Finally0()" attrs="129">
-        <size>23</size>
+        <size>29</size>
       </method>
       <method name="Boolean MoveNext()" attrs="486">
         <size>150</size>
       <method name="Void Reset()" attrs="486">
         <size>6</size>
       </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test&gt;c__Iterator0+&lt;Test&gt;c__AnonStorey1">
       <method name="Void &lt;&gt;m__0()" attrs="131">
         <size>12</size>
       </method>
       </method>
     </type>
   </test>
+  <test name="gtest-iter-23.cs">
+    <type name="C">
+      <method name="IEnumerable`1 Test()" attrs="145">
+        <size>23</size>
+      </method>
+      <method name="IEnumerable`1 Test_2()" attrs="145">
+        <size>23</size>
+      </method>
+      <method name="Int32 Main()" attrs="150">
+        <size>180</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test&gt;c__Iterator0">
+      <method name="Int32 System.Collections.Generic.IEnumerator&lt;int&gt;.get_Current()" attrs="2529">
+        <size>14</size>
+      </method>
+      <method name="System.Object System.Collections.IEnumerator.get_Current()" attrs="2529">
+        <size>19</size>
+      </method>
+      <method name="IEnumerator System.Collections.IEnumerable.GetEnumerator()" attrs="481">
+        <size>14</size>
+      </method>
+      <method name="IEnumerator`1 System.Collections.Generic.IEnumerable&lt;int&gt;.GetEnumerator()" attrs="481">
+        <size>26</size>
+      </method>
+      <method name="Boolean MoveNext()" attrs="486">
+        <size>271</size>
+      </method>
+      <method name="Void Dispose()" attrs="486">
+        <size>15</size>
+      </method>
+      <method name="Void Reset()" attrs="486">
+        <size>6</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test_2&gt;c__Iterator1">
+      <method name="Int32 System.Collections.Generic.IEnumerator&lt;int&gt;.get_Current()" attrs="2529">
+        <size>14</size>
+      </method>
+      <method name="System.Object System.Collections.IEnumerator.get_Current()" attrs="2529">
+        <size>19</size>
+      </method>
+      <method name="IEnumerator System.Collections.IEnumerable.GetEnumerator()" attrs="481">
+        <size>14</size>
+      </method>
+      <method name="IEnumerator`1 System.Collections.Generic.IEnumerable&lt;int&gt;.GetEnumerator()" attrs="481">
+        <size>26</size>
+      </method>
+      <method name="Boolean MoveNext()" attrs="486">
+        <size>200</size>
+      </method>
+      <method name="Void Dispose()" attrs="486">
+        <size>15</size>
+      </method>
+      <method name="Void Reset()" attrs="486">
+        <size>6</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test&gt;c__Iterator0+&lt;Test&gt;c__AnonStorey2">
+      <method name="Int32 &lt;&gt;m__0()" attrs="131">
+        <size>14</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test_2&gt;c__Iterator1+&lt;Test_2&gt;c__AnonStorey3">
+      <method name="Int32 &lt;&gt;m__1()" attrs="131">
+        <size>14</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
+  <test name="gtest-iter-24.cs">
+    <type name="B">
+      <method name="Void Dispose()" attrs="486">
+        <size>2</size>
+      </method>
+      <method name="Void DoSomething()" attrs="134">
+        <size>2</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C">
+      <method name="IEnumerable`1 Test()" attrs="150">
+        <size>23</size>
+      </method>
+      <method name="Int32 Main()" attrs="150">
+        <size>71</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test&gt;c__Iterator0">
+      <method name="Int32 System.Collections.Generic.IEnumerator&lt;int&gt;.get_Current()" attrs="2529">
+        <size>14</size>
+      </method>
+      <method name="System.Object System.Collections.IEnumerator.get_Current()" attrs="2529">
+        <size>19</size>
+      </method>
+      <method name="IEnumerator System.Collections.IEnumerable.GetEnumerator()" attrs="481">
+        <size>14</size>
+      </method>
+      <method name="IEnumerator`1 System.Collections.Generic.IEnumerable&lt;int&gt;.GetEnumerator()" attrs="481">
+        <size>26</size>
+      </method>
+      <method name="Boolean MoveNext()" attrs="486">
+        <size>170</size>
+      </method>
+      <method name="Void Dispose()" attrs="486">
+        <size>53</size>
+      </method>
+      <method name="Void Reset()" attrs="486">
+        <size>6</size>
+      </method>
+      <method name="Void &lt;&gt;__Finally0()" attrs="129">
+        <size>33</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test&gt;c__Iterator0+&lt;Test&gt;c__AnonStorey1">
+      <method name="Void &lt;&gt;m__0()" attrs="131">
+        <size>12</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
+  <test name="gtest-iter-25.cs">
+    <type name="Test.Program">
+      <method name="Void Main()" attrs="150">
+        <size>61</size>
+      </method>
+      <method name="IEnumerable`1 Test()" attrs="150">
+        <size>23</size>
+      </method>
+    </type>
+    <type name="Test.Program+&lt;Test&gt;c__Iterator0">
+      <method name="System.Object System.Collections.Generic.IEnumerator&lt;object&gt;.get_Current()" attrs="2529">
+        <size>14</size>
+      </method>
+      <method name="System.Object System.Collections.IEnumerator.get_Current()" attrs="2529">
+        <size>14</size>
+      </method>
+      <method name="IEnumerator System.Collections.IEnumerable.GetEnumerator()" attrs="481">
+        <size>14</size>
+      </method>
+      <method name="IEnumerator`1 System.Collections.Generic.IEnumerable&lt;object&gt;.GetEnumerator()" attrs="481">
+        <size>26</size>
+      </method>
+      <method name="Boolean MoveNext()" attrs="486">
+        <size>143</size>
+      </method>
+      <method name="Void Dispose()" attrs="486">
+        <size>53</size>
+      </method>
+      <method name="Void Reset()" attrs="486">
+        <size>6</size>
+      </method>
+      <method name="Void &lt;&gt;__Finally0()" attrs="129">
+        <size>20</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
   <test name="gtest-lambda-01.cs">
     <type name="IntFunc">
       <method name="Int32 Invoke(Int32)" attrs="454">
   <test name="test-129.cs">
     <type name="X">
       <method name="Int32 Main()" attrs="145">
-        <size>37</size>
+        <size>156</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
   <test name="test-792.cs">
     <type name="Program">
       <method name="Void Test()" attrs="129">
-        <size>25</size>
+        <size>36</size>
       </method>
       <method name="Void Test2(IMemberDelayed)" attrs="129">
         <size>20</size>
         <size>8</size>
       </method>
     </type>
+    <type name="C2">
+      <method name="Void Foo()" attrs="129">
+        <size>32</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
   </test>
   <test name="test-797.cs">
     <type name="C">
       </method>
     </type>
   </test>
+  <test name="test-844.cs">
+    <type name="C">
+      <method name="Int32 get_Prop()" attrs="2177">
+        <size>10</size>
+      </method>
+      <method name="Int32 get_Item(Char)" attrs="2177">
+        <size>10</size>
+      </method>
+      <method name="Void Foo(Int32 ByRef)" attrs="145">
+        <size>2</size>
+      </method>
+      <method name="Void Method(Int32)" attrs="134">
+        <size>33</size>
+      </method>
+      <method name="Void Main()" attrs="150">
+        <size>2</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
+  <test name="test-845.cs">
+    <type name="C1">
+      <method name="Int32 Foo()" attrs="486">
+        <size>10</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C2">
+      <method name="Int32 Foo()" attrs="486">
+        <size>10</size>
+      </method>
+      <method name="Int32 Main()" attrs="150">
+        <size>54</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C1">
+      <method name="Int32 Foo2()" attrs="486">
+        <size>11</size>
+      </method>
+    </type>
+    <type name="C2">
+      <method name="Int32 Foo2()" attrs="486">
+        <size>10</size>
+      </method>
+    </type>
+  </test>
   <test name="test-85.cs">
     <type name="X">
       <method name="Int32 Main()" attrs="145">
   <test name="test-anon-10.cs">
     <type name="S">
       <method name="Void Test()" attrs="134">
-        <size>108</size>
+        <size>101</size>
       </method>
       <method name="Int32 Main()" attrs="145">
         <size>79</size>
     </type>
     <type name="S+&lt;Test&gt;c__AnonStorey1">
       <method name="Void &lt;&gt;m__0()" attrs="131">
-        <size>77</size>
+        <size>87</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
     </type>
     <type name="T+&lt;GetD&gt;c__AnonStorey2`1[T]">
       <method name="Void &lt;&gt;m__0(System.Object)" attrs="131">
-        <size>82</size>
+        <size>75</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
       </method>
     </type>
   </test>
+  <test name="test-anon-170.cs">
+    <type name="MyClass">
+      <method name="Int32 Test(Int32)" attrs="129">
+        <size>10</size>
+      </method>
+      <method name="Void Run()" attrs="134">
+        <size>42</size>
+      </method>
+      <method name="Void Run2()" attrs="134">
+        <size>42</size>
+      </method>
+      <method name="Void Main()" attrs="150">
+        <size>20</size>
+      </method>
+      <method name="Void &lt;Run&gt;m__0(Int32)" attrs="129">
+        <size>33</size>
+      </method>
+      <method name="Void &lt;Run&gt;m__1(Int32)" attrs="129">
+        <size>33</size>
+      </method>
+      <method name="Void &lt;Run2&gt;m__2(Int32)" attrs="129">
+        <size>40</size>
+      </method>
+      <method name="Void &lt;Run2&gt;m__3(Int32)" attrs="129">
+        <size>40</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="MyClass+&lt;Run&gt;c__AnonStorey0">
+      <method name="Int32 &lt;&gt;m__4()" attrs="131">
+        <size>14</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="MyClass+&lt;Run&gt;c__AnonStorey1">
+      <method name="Int32 &lt;&gt;m__5()" attrs="131">
+        <size>14</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="MyClass+&lt;Run2&gt;c__AnonStorey2">
+      <method name="Int32 &lt;&gt;m__6()" attrs="131">
+        <size>25</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="MyClass+&lt;Run2&gt;c__AnonStorey3">
+      <method name="Int32 &lt;&gt;m__7()" attrs="131">
+        <size>25</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
   <test name="test-anon-18.cs">
     <type name="A">
       <method name="Void Invoke()" attrs="454">
         <size>2</size>
       </method>
       <method name="Void Test(Int32)" attrs="134">
-        <size>156</size>
+        <size>142</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
     </type>
     <type name="World+&lt;Test&gt;c__AnonStorey2">
       <method name="Void &lt;&gt;m__0()" attrs="131">
-        <size>46</size>
+        <size>51</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
         <size>2</size>
       </method>
       <method name="Void Test(Int32)" attrs="134">
-        <size>204</size>
+        <size>190</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
     </type>
     <type name="World+&lt;Test&gt;c__AnonStorey0">
       <method name="Void &lt;&gt;m__0()" attrs="131">
-        <size>64</size>
+        <size>79</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
         <size>14</size>
       </method>
       <method name="Boolean MoveNext()" attrs="486">
-        <size>211</size>
+        <size>242</size>
       </method>
       <method name="Void Dispose()" attrs="486">
         <size>15</size>
       <method name="Void Reset()" attrs="486">
         <size>6</size>
       </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="X+&lt;GetIt&gt;c__Iterator0+&lt;GetIt&gt;c__AnonStorey1">
       <method name="Void &lt;&gt;m__0()" attrs="131">
         <size>28</size>
       </method>
   <test name="test-anon-61.cs">
     <type name="X">
       <method name="Int32 Test()" attrs="134">
-        <size>381</size>
+        <size>374</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>67</size>
     </type>
     <type name="X+&lt;Test&gt;c__AnonStorey1">
       <method name="Void &lt;&gt;m__0()" attrs="131">
-        <size>158</size>
+        <size>173</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
         <size>14</size>
       </method>
       <method name="Boolean MoveNext()" attrs="486">
-        <size>205</size>
+        <size>281</size>
       </method>
       <method name="Void Dispose()" attrs="486">
         <size>15</size>
       <method name="Void Reset()" attrs="486">
         <size>6</size>
       </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="X+&lt;GetIt&gt;c__Iterator0+&lt;GetIt&gt;c__AnonStorey2">
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="X+&lt;GetIt&gt;c__Iterator0+&lt;GetIt&gt;c__AnonStorey1">
       <method name="Int32 &lt;&gt;m__0()" attrs="131">
-        <size>52</size>
+        <size>57</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
         <size>2</size>
       </method>
       <method name="Void TestMe()" attrs="129">
-        <size>159</size>
+        <size>152</size>
       </method>
       <method name="Boolean &lt;TestMe&gt;m__0()" attrs="145">
         <size>10</size>
     </type>
     <type name="Test+&lt;TestMe&gt;c__AnonStorey0">
       <method name="Boolean &lt;&gt;m__1()" attrs="131">
-        <size>62</size>
+        <size>67</size>
       </method>
       <method name="Boolean &lt;&gt;m__2()" attrs="131">
         <size>22</size>
   <test name="test-anon-97.cs">
     <type name="Space">
       <method name="Void Leak(Boolean, Int32)" attrs="134">
-        <size>88</size>
+        <size>81</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>14</size>
     </type>
     <type name="Space+&lt;Leak&gt;c__AnonStorey0">
       <method name="Void &lt;&gt;m__0()" attrs="131">
-        <size>19</size>
+        <size>24</size>
       </method>
       <method name="Void &lt;&gt;m__1()" attrs="131">
         <size>70</size>
         <size>131</size>
       </method>
       <method name="Void TestAsync()" attrs="145">
-        <size>31</size>
+        <size>27</size>
       </method>
       <method name="System.Threading.Tasks.Task RunAsync()" attrs="145">
         <size>48</size>
     </type>
     <type name="Program+&lt;TestAsync&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>215</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>212</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
   <test name="test-async-02.cs">
     <type name="C">
       <method name="System.Threading.Tasks.Task TestTask()" attrs="134">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task TestTask2()" attrs="134">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task Call()" attrs="129">
         <size>31</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestTaskGeneric()" attrs="134">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] CallGeneric()" attrs="129">
         <size>31</size>
     </type>
     <type name="C+&lt;TestTask&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>165</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>162</size>
       </method>
     </type>
     <type name="C+&lt;TestTask2&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>165</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>167</size>
       </method>
     </type>
     <type name="C+&lt;TestTaskGeneric&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>172</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>169</size>
       </method>
     </type>
     <type name="C+&lt;TestTask&gt;c__async0">
         <size>10</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] Test1()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] Test2()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task Test3()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>88</size>
     </type>
     <type name="A+&lt;Test1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>239</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>233</size>
       </method>
     </type>
     <type name="A+&lt;Test2&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>164</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>161</size>
       </method>
     </type>
     <type name="A+&lt;Test3&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>156</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>153</size>
       </method>
     </type>
     <type name="A">
   <test name="test-async-04.cs">
     <type name="C">
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestTaskGeneric()" attrs="134">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>141</size>
     </type>
     <type name="C+&lt;TestTaskGeneric&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>185</size>
-      </method>
-      <method name="Int32 &lt;&gt;m__0()" attrs="131">
-        <size>49</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>187</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
     </type>
+    <type name="C">
+      <method name="Int32 &lt;TestTaskGeneric&gt;m__0()" attrs="129">
+        <size>39</size>
+      </method>
+    </type>
   </test>
   <test name="test-async-05.cs">
     <type name="C">
         <size>7</size>
       </method>
       <method name="System.Threading.Tasks.Task SynchronousCall(Int32)" attrs="134">
-        <size>51</size>
+        <size>49</size>
       </method>
       <method name="System.Threading.Tasks.Task AnotherTask(Int32)" attrs="129">
         <size>15</size>
       <method name="Void MoveNext()" attrs="486">
         <size>49</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
         <size>482</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Decimal] &lt;Main&gt;m__4(Decimal)" attrs="145">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
     </type>
     <type name="Program+&lt;Main&gt;c__AnonStorey1">
       <method name="Void &lt;&gt;m__0()" attrs="131">
-        <size>38</size>
+        <size>35</size>
       </method>
       <method name="Void &lt;&gt;m__1()" attrs="131">
-        <size>38</size>
+        <size>35</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.String] &lt;&gt;m__2(System.String)" attrs="131">
-        <size>51</size>
+        <size>49</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Decimal] &lt;&gt;m__3(Decimal)" attrs="131">
-        <size>51</size>
+        <size>49</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
     </type>
     <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>215</size>
-      </method>
-      <method name="Void &lt;&gt;m__5()" attrs="131">
-        <size>39</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>217</size>
       </method>
     </type>
     <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>215</size>
-      </method>
-      <method name="Void &lt;&gt;m__6()" attrs="131">
-        <size>39</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>217</size>
       </method>
     </type>
     <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async3">
       <method name="Void MoveNext()" attrs="486">
-        <size>195</size>
-      </method>
-      <method name="System.String &lt;&gt;m__7()" attrs="131">
-        <size>52</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
-    </type>
-    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async4">
-      <method name="Void MoveNext()" attrs="486">
-        <size>195</size>
-      </method>
-      <method name="Decimal &lt;&gt;m__8()" attrs="131">
-        <size>52</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
-    </type>
-    <type name="Program+&lt;Main&gt;c__async5">
-      <method name="Void MoveNext()" attrs="486">
-        <size>44</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>242</size>
       </method>
     </type>
     <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async0">
         <size>13</size>
       </method>
     </type>
-    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async4">
+    <type name="Program+&lt;Main&gt;c__AnonStorey1">
+      <method name="Void &lt;&gt;m__5()" attrs="131">
+        <size>34</size>
+      </method>
+      <method name="Void &lt;&gt;m__6()" attrs="131">
+        <size>34</size>
+      </method>
+    </type>
+    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async5">
+      <method name="Void MoveNext()" attrs="486">
+        <size>242</size>
+      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
     </type>
-    <type name="Program+&lt;Main&gt;c__async5">
+    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async3+&lt;Main&gt;c__AnonStorey4">
+      <method name="System.String &lt;&gt;m__7()" attrs="131">
+        <size>52</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async5+&lt;Main&gt;c__AnonStorey6">
+      <method name="Decimal &lt;&gt;m__8()" attrs="131">
+        <size>52</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Program+&lt;Main&gt;c__async7">
+      <method name="Void MoveNext()" attrs="486">
+        <size>44</size>
+      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
         <size>358</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int16] &lt;Main&gt;m__2(Int16)" attrs="145">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
     </type>
     <type name="Program+&lt;Main&gt;c__AnonStorey1">
       <method name="System.Threading.Tasks.Task`1[System.String] &lt;&gt;m__0(System.String)" attrs="131">
-        <size>51</size>
+        <size>49</size>
       </method>
       <method name="System.Threading.Tasks.Task &lt;&gt;m__1()" attrs="131">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="Void &lt;&gt;m__3()" attrs="131">
-        <size>38</size>
+        <size>35</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
     </type>
     <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>182</size>
-      </method>
-      <method name="System.String &lt;&gt;m__4()" attrs="131">
-        <size>52</size>
+        <size>229</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
       </method>
     </type>
-    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async2">
-      <method name="Void MoveNext()" attrs="486">
-        <size>175</size>
-      </method>
+    <type name="Program+&lt;Main&gt;c__AnonStorey1">
       <method name="Void &lt;&gt;m__5()" attrs="131">
-        <size>39</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
-    </type>
-    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async4">
-      <method name="Void MoveNext()" attrs="486">
-        <size>180</size>
+        <size>34</size>
       </method>
       <method name="Void &lt;&gt;m__6()" attrs="131">
-        <size>56</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>46</size>
       </method>
     </type>
-    <type name="Program+&lt;Main&gt;c__async3">
+    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async3">
       <method name="Void MoveNext()" attrs="486">
-        <size>43</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>182</size>
       </method>
-    </type>
-    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async0">
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
     </type>
-    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async2">
+    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async5">
+      <method name="Void MoveNext()" attrs="486">
+        <size>182</size>
+      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
     </type>
-    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async4">
-      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
-        <size>13</size>
+    <type name="Program+&lt;Main&gt;c__AnonStorey1+&lt;Main&gt;c__async0+&lt;Main&gt;c__AnonStorey2">
+      <method name="System.String &lt;&gt;m__4()" attrs="131">
+        <size>52</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
       </method>
     </type>
-    <type name="Program+&lt;Main&gt;c__async3">
+    <type name="Program+&lt;Main&gt;c__async4">
+      <method name="Void MoveNext()" attrs="486">
+        <size>43</size>
+      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
         <size>10</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] &lt;Main&gt;m__0(Int32)" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] &lt;Main&gt;m__1(Int32)" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task &lt;Main&gt;m__2(Int32)" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task &lt;Main&gt;m__3(Int32)" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 &lt;TT&gt;m__4()" attrs="145">
         <size>9</size>
     </type>
     <type name="AsyncTypeInference+&lt;Main&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>199</size>
+        <size>196</size>
       </method>
       <method name="Int32 &lt;&gt;m__5()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="AsyncTypeInference+&lt;Main&gt;c__async5">
       <method name="Void MoveNext()" attrs="486">
-        <size>200</size>
+        <size>197</size>
       </method>
       <method name="Int32 &lt;&gt;m__6()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="AsyncTypeInference+&lt;Main&gt;c__async8">
       <method name="Void MoveNext()" attrs="486">
-        <size>160</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>157</size>
       </method>
     </type>
     <type name="AsyncTypeInference+&lt;Main&gt;c__asyncB">
       <method name="Void MoveNext()" attrs="486">
         <size>38</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="AsyncTypeInference+&lt;Main&gt;c__async2">
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>57</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int16] &lt;Main&gt;m__0(System.String)" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
       <method name="Void MoveNext()" attrs="486">
         <size>38</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
   <test name="test-async-10.cs">
     <type name="C">
       <method name="System.Threading.Tasks.Task`1[System.String] TestCompositionCall_1()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.String] TestCompositionCall_2()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestCompositionCall_3()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestCompositionPair_1()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestCompositionPair_2()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestCompositionPair_3()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestCompositionPair_4()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Byte] M(Byte)" attrs="145">
         <size>44</size>
     </type>
     <type name="C+&lt;TestCompositionCall_1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>324</size>
+        <size>318</size>
       </method>
       <method name="System.String &lt;&gt;m__1()" attrs="145">
         <size>21</size>
       <method name="System.String &lt;&gt;m__2()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestCompositionCall_2&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>251</size>
+        <size>246</size>
       </method>
       <method name="System.String &lt;&gt;m__3()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestCompositionCall_3&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>296</size>
+        <size>288</size>
       </method>
       <method name="Byte &lt;&gt;m__4()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestCompositionPair_1&gt;c__async3">
       <method name="Void MoveNext()" attrs="486">
-        <size>202</size>
+        <size>199</size>
       </method>
       <method name="Int32 &lt;&gt;m__5()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestCompositionPair_2&gt;c__async4">
       <method name="Void MoveNext()" attrs="486">
-        <size>315</size>
+        <size>309</size>
       </method>
       <method name="Int32 &lt;&gt;m__6()" attrs="145">
         <size>17</size>
       <method name="Int32 &lt;&gt;m__7()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestCompositionPair_3&gt;c__async5">
       <method name="Void MoveNext()" attrs="486">
-        <size>203</size>
+        <size>200</size>
       </method>
       <method name="Int32 &lt;&gt;m__8()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestCompositionPair_4&gt;c__async6">
       <method name="Void MoveNext()" attrs="486">
-        <size>446</size>
+        <size>435</size>
       </method>
       <method name="Int32 &lt;&gt;m__9()" attrs="145">
         <size>9</size>
       <method name="Int32 &lt;&gt;m__B()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;M&gt;c__AnonStorey7">
       <method name="Byte &lt;&gt;m__0()" attrs="131">
   <test name="test-async-11.cs">
     <type name="G`1[T]">
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestStack_1(T)" attrs="134">
-        <size>51</size>
+        <size>49</size>
       </method>
       <method name="Int32 Call(T, T, T ByRef, Int32)" attrs="129">
         <size>17</size>
         <size>90</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestStack_1()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 TestCall2[T1,T2,T3,T4,T5,T6,T7](T1, T2, T3, T4, T5, T6, T7)" attrs="129">
         <size>10</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestStack_2(UInt64)" attrs="145">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestStack_3()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 TestCall3(S ByRef, S ByRef, Int32, Int32)" attrs="145">
         <size>26</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestStack_4()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 TestCall4(E, S, C, Int32)" attrs="145">
         <size>61</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestStack_5()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>370</size>
     </type>
     <type name="G`1+&lt;TestStack_1&gt;c__async0[T]">
       <method name="Void MoveNext()" attrs="486">
-        <size>260</size>
+        <size>257</size>
       </method>
       <method name="Int32 &lt;&gt;m__0()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestStack_1&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>321</size>
+        <size>316</size>
       </method>
       <method name="Int32 &lt;&gt;m__1()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestStack_2&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>296</size>
+        <size>291</size>
       </method>
       <method name="Int32 &lt;&gt;m__2()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestStack_3&gt;c__async3">
       <method name="Void MoveNext()" attrs="486">
-        <size>461</size>
+        <size>457</size>
       </method>
       <method name="Int32 &lt;&gt;m__3()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestStack_4&gt;c__async4">
       <method name="Void MoveNext()" attrs="486">
-        <size>317</size>
+        <size>312</size>
       </method>
       <method name="Int32 &lt;&gt;m__4()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestStack_5&gt;c__async5">
       <method name="Void MoveNext()" attrs="486">
-        <size>295</size>
-      </method>
-      <method name="Int32 &lt;&gt;m__5()" attrs="131">
-        <size>48</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>336</size>
       </method>
     </type>
     <type name="G`1+&lt;TestStack_1&gt;c__async0[T]">
         <size>13</size>
       </method>
     </type>
+    <type name="C+&lt;TestStack_5&gt;c__async5+&lt;TestStack_5&gt;c__AnonStorey6">
+      <method name="Int32 &lt;&gt;m__5()" attrs="131">
+        <size>48</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
   </test>
   <test name="test-async-12.cs">
     <type name="C">
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestNested_1()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Call(Int32, Int32, Int32)" attrs="145">
         <size>53</size>
     </type>
     <type name="C+&lt;TestNested_1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>433</size>
+        <size>424</size>
       </method>
       <method name="Int32 &lt;&gt;m__0()" attrs="145">
         <size>17</size>
       <method name="Int32 &lt;&gt;m__2()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
     </type>
     <type name="Tester">
       <method name="System.Threading.Tasks.Task`1[System.Boolean] ArrayAccessTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] ArrayAccessTest_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] ArrayAccessTest_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] ArrayAccessTest_4()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] ArrayAccessTest_5()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] ArrayAccessTest_6()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] ArrayAccessTest_7()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] ArrayAccessTest_8()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] ArrayAccessTest_9()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] AssignTest_1()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] AssignTest_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] AssignTest_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] BinaryTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] BinaryTest_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] BinaryTest_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] BinaryTest_4()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] CallTest_1()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] CallTest_2()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] CallTest_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] CallTest_4()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] CallTest_5()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] CastTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] CastTest_2()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] CoalescingTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] CoalescingTest_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] ConditionalTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] ConditionalTest_2()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] ConditionalTest_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] ConditionalTest_4()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] DelegateInvoke_4()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] EventInvoke_1()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] FieldTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] IndexerTest_1()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] IndexerTest_2()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] IndexerTest_3()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] IndexerTest_4()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] IndexerTest_5()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] IndexerTest_6()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] IndexerTest_7()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] IsTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] IsTest_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] LogicalUserOperator_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] LogicalUserOperator_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] LogicalUserOperator_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] NewTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] NewTest_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] NewInitTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] NewInitTest_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] NewArrayInitTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] NewArrayInitTest_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] NewArrayInitTest_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] NewArrayInitTest_4()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] NewArrayInitTest_5()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] NewArrayInitTest_6()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] PropertyTest_1()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] PropertyTest_2()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] PropertyTest_3()" attrs="129">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] StringConcatTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] UnaryTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] UnaryTest_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] UnaryTest_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] VariableInitializer_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Boolean RunTest(System.Reflection.MethodInfo)" attrs="145">
         <size>247</size>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>341</size>
+        <size>335</size>
       </method>
       <method name="Boolean &lt;&gt;m__4()" attrs="145">
         <size>9</size>
       <method name="Int32 &lt;&gt;m__5()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_2&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>754</size>
+        <size>740</size>
       </method>
       <method name="Int32 &lt;&gt;m__6()" attrs="145">
         <size>9</size>
       <method name="Double &lt;&gt;m__9()" attrs="145">
         <size>17</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_3&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>1117</size>
+        <size>1090</size>
       </method>
       <method name="Int32 &lt;&gt;m__A()" attrs="145">
         <size>9</size>
       <method name="Decimal &lt;&gt;m__E()" attrs="145">
         <size>19</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_4&gt;c__async3">
       <method name="Void MoveNext()" attrs="486">
-        <size>429</size>
+        <size>421</size>
       </method>
       <method name="Int32 &lt;&gt;m__F()" attrs="145">
         <size>9</size>
       <method name="System.String &lt;&gt;m__10()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_5&gt;c__async4">
       <method name="Void MoveNext()" attrs="486">
-        <size>413</size>
+        <size>428</size>
       </method>
       <method name="Int32 &lt;&gt;m__11()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Int32 &lt;&gt;m__12()" attrs="131">
-        <size>25</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_6&gt;c__async5">
       <method name="Void MoveNext()" attrs="486">
-        <size>262</size>
+        <size>257</size>
       </method>
       <method name="Int64 &lt;&gt;m__13()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_7&gt;c__async6">
       <method name="Void MoveNext()" attrs="486">
-        <size>392</size>
+        <size>385</size>
       </method>
       <method name="Int32 &lt;&gt;m__14()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_8&gt;c__async7">
       <method name="Void MoveNext()" attrs="486">
-        <size>678</size>
+        <size>670</size>
       </method>
       <method name="Int32 &lt;&gt;m__15()" attrs="145">
         <size>9</size>
       <method name="Byte &lt;&gt;m__16()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_9&gt;c__async8">
       <method name="Void MoveNext()" attrs="486">
-        <size>1233</size>
+        <size>1209</size>
       </method>
       <method name="Int32 &lt;&gt;m__17()" attrs="145">
         <size>9</size>
       <method name="S &lt;&gt;m__1D()" attrs="145">
         <size>25</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;AssignTest_1&gt;c__async9">
       <method name="Void MoveNext()" attrs="486">
-        <size>226</size>
+        <size>223</size>
       </method>
       <method name="Int32 &lt;&gt;m__1E()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;AssignTest_2&gt;c__asyncA">
       <method name="Void MoveNext()" attrs="486">
-        <size>278</size>
+        <size>273</size>
       </method>
       <method name="Nullable`1 &lt;&gt;m__1F()" attrs="145">
         <size>17</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;AssignTest_3&gt;c__asyncB">
       <method name="Void MoveNext()" attrs="486">
-        <size>370</size>
+        <size>364</size>
       </method>
       <method name="Int32 &lt;&gt;m__20()" attrs="145">
         <size>9</size>
       <method name="Int32 &lt;&gt;m__21()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;BinaryTest_1&gt;c__asyncC">
       <method name="Void MoveNext()" attrs="486">
-        <size>446</size>
+        <size>435</size>
       </method>
       <method name="Int32 &lt;&gt;m__22()" attrs="145">
         <size>17</size>
       <method name="Int32 &lt;&gt;m__24()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;BinaryTest_2&gt;c__asyncD">
       <method name="Void MoveNext()" attrs="486">
-        <size>477</size>
-      </method>
-      <method name="Boolean &lt;&gt;m__25()" attrs="131">
-        <size>24</size>
-      </method>
-      <method name="Boolean &lt;&gt;m__26()" attrs="131">
-        <size>24</size>
-      </method>
-      <method name="Boolean &lt;&gt;m__27()" attrs="131">
-        <size>24</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>507</size>
       </method>
     </type>
     <type name="Tester+&lt;BinaryTest_3&gt;c__asyncE">
       <method name="Void MoveNext()" attrs="486">
-        <size>1104</size>
+        <size>1082</size>
       </method>
       <method name="Nullable`1 &lt;&gt;m__28()" attrs="145">
         <size>14</size>
       <method name="Nullable`1 &lt;&gt;m__2D()" attrs="145">
         <size>14</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;BinaryTest_4&gt;c__asyncF">
       <method name="Void MoveNext()" attrs="486">
-        <size>825</size>
+        <size>809</size>
       </method>
       <method name="Nullable`1 &lt;&gt;m__2E()" attrs="145">
         <size>14</size>
       <method name="Nullable`1 &lt;&gt;m__31()" attrs="145">
         <size>17</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ArrayAccessTest_1&gt;c__async0">
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
     </type>
     <type name="Tester">
       <method name="System.Threading.Tasks.Task`1[System.Int32] BinaryTest_5()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
     </type>
     <type name="Tester+&lt;BinaryTest_5&gt;c__async10">
       <method name="Void MoveNext()" attrs="486">
-        <size>304</size>
+        <size>298</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;CallTest_1&gt;c__async11">
       <method name="Void MoveNext()" attrs="486">
-        <size>439</size>
+        <size>430</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__34()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;CallTest_2&gt;c__async12">
       <method name="Void MoveNext()" attrs="486">
-        <size>272</size>
+        <size>267</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__35()" attrs="145">
         <size>17</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;CallTest_3&gt;c__async13">
       <method name="Void MoveNext()" attrs="486">
-        <size>242</size>
+        <size>237</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__36()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;CallTest_4&gt;c__async14">
       <method name="Void MoveNext()" attrs="486">
-        <size>239</size>
+        <size>234</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="E &lt;&gt;m__37()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;CallTest_5&gt;c__async15">
       <method name="Void MoveNext()" attrs="486">
-        <size>210</size>
+        <size>250</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Int32 &lt;&gt;m__38()" attrs="131">
-        <size>25</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;CastTest_1&gt;c__async16">
       <method name="Void MoveNext()" attrs="486">
-        <size>251</size>
+        <size>246</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Decimal &lt;&gt;m__39()" attrs="145">
         <size>15</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;CastTest_2&gt;c__async17">
       <method name="Void MoveNext()" attrs="486">
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Tester &lt;&gt;m__3A()" attrs="131">
-        <size>14</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;CoalescingTest_1&gt;c__async18">
       <method name="Void MoveNext()" attrs="486">
-        <size>366</size>
+        <size>358</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="System.String &lt;&gt;m__3C()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;CoalescingTest_2&gt;c__async19">
       <method name="Void MoveNext()" attrs="486">
-        <size>372</size>
+        <size>364</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Byte &lt;&gt;m__3E()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ConditionalTest_1&gt;c__async1A">
       <method name="Void MoveNext()" attrs="486">
-        <size>200</size>
+        <size>197</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__3F()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ConditionalTest_2&gt;c__async1B">
       <method name="Void MoveNext()" attrs="486">
-        <size>335</size>
+        <size>329</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__41()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ConditionalTest_3&gt;c__async1C">
       <method name="Void MoveNext()" attrs="486">
-        <size>355</size>
+        <size>347</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__43()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;ConditionalTest_4&gt;c__async1D">
       <method name="Void MoveNext()" attrs="486">
-        <size>248</size>
+        <size>243</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__44()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;DelegateInvoke_4&gt;c__async1E">
       <method name="Void MoveNext()" attrs="486">
-        <size>276</size>
+        <size>271</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__46()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;EventInvoke_1&gt;c__async1F">
       <method name="Void MoveNext()" attrs="486">
-        <size>220</size>
+        <size>260</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="System.Action &lt;&gt;m__47()" attrs="131">
-        <size>23</size>
-      </method>
-      <method name="Void &lt;&gt;m__48()" attrs="131">
-        <size>9</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;FieldTest_1&gt;c__async20">
       <method name="Void MoveNext()" attrs="486">
-        <size>543</size>
+        <size>535</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__4A()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;IndexerTest_1&gt;c__async21">
       <method name="Void MoveNext()" attrs="486">
-        <size>228</size>
+        <size>225</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__4B()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;IndexerTest_2&gt;c__async22">
       <method name="Void MoveNext()" attrs="486">
-        <size>341</size>
+        <size>335</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__4D()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;IndexerTest_3&gt;c__async23">
       <method name="Void MoveNext()" attrs="486">
-        <size>372</size>
+        <size>402</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Int32 &lt;&gt;m__4E()" attrs="131">
-        <size>25</size>
-      </method>
       <method name="Int32 &lt;&gt;m__4F()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;IndexerTest_4&gt;c__async24">
       <method name="Void MoveNext()" attrs="486">
-        <size>407</size>
+        <size>442</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Int32 &lt;&gt;m__50()" attrs="131">
-        <size>25</size>
-      </method>
       <method name="Int32 &lt;&gt;m__51()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;IndexerTest_5&gt;c__async25">
       <method name="Void MoveNext()" attrs="486">
-        <size>520</size>
+        <size>548</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Int32 &lt;&gt;m__52()" attrs="131">
-        <size>25</size>
-      </method>
       <method name="Int32 &lt;&gt;m__53()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;IndexerTest_6&gt;c__async26">
       <method name="Void MoveNext()" attrs="486">
-        <size>555</size>
+        <size>544</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__56()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;IndexerTest_7&gt;c__async27">
       <method name="Void MoveNext()" attrs="486">
-        <size>262</size>
+        <size>295</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Int32 &lt;&gt;m__57()" attrs="131">
-        <size>25</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;IsTest_1&gt;c__async28">
       <method name="Void MoveNext()" attrs="486">
-        <size>236</size>
+        <size>233</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Tester &lt;&gt;m__58()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;IsTest_2&gt;c__async29">
       <method name="Void MoveNext()" attrs="486">
-        <size>238</size>
+        <size>233</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Nullable`1 &lt;&gt;m__59()" attrs="145">
         <size>14</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;LogicalUserOperator_1&gt;c__async2A">
       <method name="Void MoveNext()" attrs="486">
-        <size>399</size>
+        <size>391</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Base &lt;&gt;m__5B()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;LogicalUserOperator_2&gt;c__async2B">
       <method name="Void MoveNext()" attrs="486">
-        <size>304</size>
+        <size>299</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Base &lt;&gt;m__5C()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;LogicalUserOperator_3&gt;c__async2C">
       <method name="Void MoveNext()" attrs="486">
-        <size>398</size>
+        <size>390</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Base &lt;&gt;m__5E()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewTest_1&gt;c__async2D">
       <method name="Void MoveNext()" attrs="486">
-        <size>265</size>
+        <size>260</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__5F()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewTest_2&gt;c__async2E">
       <method name="Void MoveNext()" attrs="486">
-        <size>356</size>
+        <size>348</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="System.String &lt;&gt;m__61()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewInitTest_1&gt;c__async2F">
       <method name="Void MoveNext()" attrs="486">
-        <size>1046</size>
+        <size>1026</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__67()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewInitTest_2&gt;c__async30">
       <method name="Void MoveNext()" attrs="486">
-        <size>753</size>
+        <size>739</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__6B()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewArrayInitTest_1&gt;c__async31">
       <method name="Void MoveNext()" attrs="486">
-        <size>245</size>
+        <size>240</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__6C()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewArrayInitTest_2&gt;c__async32">
       <method name="Void MoveNext()" attrs="486">
-        <size>363</size>
+        <size>355</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__6E()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewArrayInitTest_3&gt;c__async33">
       <method name="Void MoveNext()" attrs="486">
-        <size>249</size>
+        <size>246</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Byte &lt;&gt;m__6F()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewArrayInitTest_4&gt;c__async34">
       <method name="Void MoveNext()" attrs="486">
-        <size>433</size>
+        <size>427</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="UInt16 &lt;&gt;m__71()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewArrayInitTest_5&gt;c__async35">
       <method name="Void MoveNext()" attrs="486">
-        <size>267</size>
+        <size>264</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="S &lt;&gt;m__72()" attrs="145">
         <size>25</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;NewArrayInitTest_6&gt;c__async36">
       <method name="Void MoveNext()" attrs="486">
-        <size>269</size>
+        <size>266</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__73()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;PropertyTest_1&gt;c__async37">
       <method name="Void MoveNext()" attrs="486">
-        <size>225</size>
+        <size>222</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__74()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;PropertyTest_2&gt;c__async38">
       <method name="Void MoveNext()" attrs="486">
-        <size>300</size>
+        <size>295</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__75()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;PropertyTest_3&gt;c__async39">
       <method name="Void MoveNext()" attrs="486">
-        <size>656</size>
+        <size>645</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__78()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;StringConcatTest_1&gt;c__async3A">
       <method name="Void MoveNext()" attrs="486">
-        <size>466</size>
+        <size>455</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="System.String &lt;&gt;m__7B()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;UnaryTest_1&gt;c__async3B">
       <method name="Void MoveNext()" attrs="486">
-        <size>238</size>
+        <size>233</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__7C()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;UnaryTest_2&gt;c__async3C">
       <method name="Void MoveNext()" attrs="486">
-        <size>338</size>
+        <size>354</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Nullable`1 &lt;&gt;m__7D()" attrs="131">
-        <size>14</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;UnaryTest_3&gt;c__async3D">
       <method name="Void MoveNext()" attrs="486">
-        <size>378</size>
+        <size>369</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__7E()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;VariableInitializer_1&gt;c__async3E">
       <method name="Void MoveNext()" attrs="486">
-        <size>354</size>
+        <size>348</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Int32 &lt;&gt;m__80()" attrs="145">
         <size>9</size>
       </method>
+    </type>
+    <type name="Tester">
+      <method name="Tester &lt;CastTest_2&gt;m__3A()" attrs="129">
+        <size>9</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;ArrayAccessTest_5&gt;c__async4+&lt;ArrayAccessTest_5&gt;c__AnonStorey3F">
+      <method name="Int32 &lt;&gt;m__12()" attrs="131">
+        <size>25</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;BinaryTest_2&gt;c__asyncD+&lt;BinaryTest_2&gt;c__AnonStorey40">
+      <method name="Boolean &lt;&gt;m__25()" attrs="131">
+        <size>24</size>
+      </method>
+      <method name="Boolean &lt;&gt;m__26()" attrs="131">
+        <size>24</size>
+      </method>
+      <method name="Boolean &lt;&gt;m__27()" attrs="131">
+        <size>24</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;CallTest_5&gt;c__async15+&lt;CallTest_5&gt;c__AnonStorey41">
+      <method name="Int32 &lt;&gt;m__38()" attrs="131">
+        <size>25</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;EventInvoke_1&gt;c__async1F+&lt;EventInvoke_1&gt;c__AnonStorey42">
+      <method name="System.Action &lt;&gt;m__47()" attrs="131">
+        <size>23</size>
+      </method>
+      <method name="Void &lt;&gt;m__48()" attrs="131">
+        <size>9</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;IndexerTest_3&gt;c__async23+&lt;IndexerTest_3&gt;c__AnonStorey43">
+      <method name="Int32 &lt;&gt;m__4E()" attrs="131">
+        <size>25</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;IndexerTest_4&gt;c__async24+&lt;IndexerTest_4&gt;c__AnonStorey44">
+      <method name="Int32 &lt;&gt;m__50()" attrs="131">
+        <size>25</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;IndexerTest_5&gt;c__async25+&lt;IndexerTest_5&gt;c__AnonStorey45">
+      <method name="Int32 &lt;&gt;m__52()" attrs="131">
+        <size>25</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;IndexerTest_7&gt;c__async27+&lt;IndexerTest_7&gt;c__AnonStorey46">
+      <method name="Int32 &lt;&gt;m__57()" attrs="131">
+        <size>25</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;UnaryTest_2&gt;c__async3C+&lt;UnaryTest_2&gt;c__AnonStorey47">
+      <method name="Nullable`1 &lt;&gt;m__7D()" attrs="131">
+        <size>14</size>
+      </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
       </method>
   <test name="test-async-14.cs">
     <type name="C">
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestResult()" attrs="134">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>214</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] &lt;Main&gt;m__0()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
     </type>
     <type name="C+&lt;TestResult&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>216</size>
+        <size>213</size>
       </method>
       <method name="Int32 &lt;&gt;m__1()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;Main&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>226</size>
+        <size>223</size>
       </method>
       <method name="Int32 &lt;&gt;m__2()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;TestResult&gt;c__async0">
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
     </type>
     <type name="Tester">
       <method name="System.Threading.Tasks.Task`1[T] NewInitTestGen[T]()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>82</size>
     </type>
     <type name="Tester+&lt;NewInitTestGen&gt;c__async0`1[T]">
       <method name="Void MoveNext()" attrs="486">
-        <size>300</size>
+        <size>294</size>
       </method>
       <method name="Int32 &lt;&gt;m__0()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
     </type>
     <type name="Tester">
       <method name="System.Threading.Tasks.Task`1[System.Int32] SwitchTest_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] Using_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] Foreach_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Boolean RunTest(System.Reflection.MethodInfo)" attrs="145">
         <size>247</size>
     </type>
     <type name="Tester+&lt;SwitchTest_1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>340</size>
+        <size>335</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="System.String &lt;&gt;m__4()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;Using_1&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>780</size>
+        <size>766</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="Base &lt;&gt;m__8()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;Foreach_1&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>325</size>
+        <size>320</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       <method name="System.Collections.Generic.List`1[System.Int32] &lt;&gt;m__9()" attrs="145">
         <size>36</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
   </test>
   <test name="test-async-17.cs">
     <type name="Tester">
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestException_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task TestException_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task TestException_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestException_4()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestException_5()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] TestException_6()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Boolean RunTest(System.Reflection.MethodInfo)" attrs="145">
         <size>223</size>
     </type>
     <type name="Tester+&lt;TestException_1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>201</size>
+        <size>198</size>
       </method>
       <method name="Void &lt;&gt;m__4()" attrs="145">
         <size>7</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;TestException_2&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>193</size>
+        <size>190</size>
       </method>
       <method name="Void &lt;&gt;m__5()" attrs="145">
         <size>7</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;TestException_3&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>200</size>
+        <size>197</size>
       </method>
       <method name="System.Threading.Tasks.Task &lt;&gt;m__6()" attrs="145">
-        <size>37</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>33</size>
       </method>
     </type>
     <type name="Tester+&lt;TestException_4&gt;c__async3">
       <method name="Void MoveNext()" attrs="486">
-        <size>234</size>
+        <size>229</size>
       </method>
       <method name="Int32 &lt;&gt;m__8()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;TestException_5&gt;c__async4">
       <method name="Void MoveNext()" attrs="486">
-        <size>283</size>
+        <size>278</size>
       </method>
       <method name="Void &lt;&gt;m__9()" attrs="145">
         <size>7</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;TestException_6&gt;c__async5">
       <method name="Void MoveNext()" attrs="486">
-        <size>237</size>
+        <size>232</size>
       </method>
       <method name="Void &lt;&gt;m__A()" attrs="145">
         <size>7</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;TestException_3&gt;c__async2+&lt;TestException_3&gt;c__async6">
       <method name="Void MoveNext()" attrs="486">
-        <size>192</size>
+        <size>194</size>
       </method>
       <method name="Void &lt;&gt;m__7()" attrs="145">
         <size>7</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;TestException_1&gt;c__async0">
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
   <test name="test-async-18.cs">
     <type name="Tester">
       <method name="System.Threading.Tasks.Task`1[System.Int32] Lambda_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] Lambda_2()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] Lambda_3[T]()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>203</size>
     </type>
     <type name="Tester+&lt;Lambda_1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>250</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>268</size>
       </method>
     </type>
     <type name="Tester+&lt;Lambda_2&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>250</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>321</size>
       </method>
     </type>
     <type name="Tester+&lt;Lambda_3&gt;c__async2`1[T]">
       <method name="Void MoveNext()" attrs="486">
-        <size>250</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>268</size>
       </method>
     </type>
     <type name="Tester+&lt;Lambda_1&gt;c__async0">
         <size>13</size>
       </method>
     </type>
-    <type name="Tester+&lt;Lambda_1&gt;c__async0">
+    <type name="Tester+&lt;Lambda_1&gt;c__async0+&lt;Lambda_1&gt;c__AnonStorey3">
       <method name="Int32 &lt;&gt;m__0()" attrs="131">
         <size>14</size>
       </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
     </type>
-    <type name="Tester+&lt;Lambda_2&gt;c__async1">
+    <type name="Tester+&lt;Lambda_2&gt;c__async1+&lt;Lambda_2&gt;c__AnonStorey5">
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Tester+&lt;Lambda_2&gt;c__async1+&lt;Lambda_2&gt;c__AnonStorey4">
       <method name="Int32 &lt;&gt;m__1()" attrs="131">
-        <size>21</size>
+        <size>26</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
       </method>
     </type>
-    <type name="Tester+&lt;Lambda_3&gt;c__async2`1[T]">
+    <type name="Tester+&lt;Lambda_3&gt;c__async2`1+&lt;Lambda_3&gt;c__AnonStorey6`1[T]">
       <method name="Int32 &lt;&gt;m__2()" attrs="131">
         <size>14</size>
       </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
     </type>
   </test>
   <test name="test-async-19.cs">
     <type name="C">
       <method name="Void Test(System.Threading.ManualResetEvent)" attrs="145">
-        <size>38</size>
+        <size>35</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>96</size>
     </type>
     <type name="C+&lt;Test&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>188</size>
+        <size>218</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
       </method>
+    </type>
+    <type name="C+&lt;Test&gt;c__async0+&lt;Test&gt;c__AnonStorey1">
       <method name="Void &lt;&gt;m__0()" attrs="131">
         <size>29</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
       </method>
-      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
-        <size>13</size>
-      </method>
     </type>
   </test>
   <test name="test-async-20.cs">
     </type>
     <type name="Tester">
       <method name="System.Threading.Tasks.Task`1[System.Boolean] Add_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] AssignCompound_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] Convert_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] Invocation_1()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Boolean RunTest(System.Reflection.MethodInfo)" attrs="145">
         <size>183</size>
     </type>
     <type name="Tester+&lt;Add_1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>497</size>
+        <size>492</size>
       </method>
       <method name="Int32 &lt;&gt;m__4()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;AssignCompound_1&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>1237</size>
+        <size>1229</size>
       </method>
       <method name="Int32 &lt;&gt;m__5()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;Convert_1&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>349</size>
+        <size>344</size>
       </method>
       <method name="System.Object &lt;&gt;m__6()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;Invocation_1&gt;c__async3">
       <method name="Void MoveNext()" attrs="486">
-        <size>601</size>
+        <size>596</size>
       </method>
       <method name="System.Object &lt;&gt;m__7()" attrs="145">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="Tester+&lt;Add_1&gt;c__async0">
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>10</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] Test1()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>58</size>
     </type>
     <type name="A+&lt;Test1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>612</size>
+        <size>604</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
   </test>
   <test name="test-async-22.cs">
     <type name="A">
       <method name="System.Threading.Tasks.Task`1[System.Int32] async()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task async(Int32)" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>10</size>
       <method name="Void MoveNext()" attrs="486">
         <size>38</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="A+&lt;async&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
         <size>37</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="A">
       <method name="Void CastTest()" attrs="129">
-        <size>38</size>
+        <size>35</size>
       </method>
     </type>
     <type name="A+&lt;CastTest&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>291</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>285</size>
       </method>
     </type>
     <type name="A+&lt;async&gt;c__async0">
         <size>22</size>
       </method>
       <method name="Void Post(System.Threading.SendOrPostCallback, System.Object)" attrs="198">
-        <size>24</size>
+        <size>36</size>
       </method>
       <method name="Void Send(System.Threading.SendOrPostCallback, System.Object)" attrs="198">
         <size>24</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="TestPostContext">
       <method name="System.Threading.Tasks.Task`1[System.Int32] Test()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Main()" attrs="150">
-        <size>136</size>
+        <size>170</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
     </type>
     <type name="TestPostContext+&lt;Test&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>200</size>
-      </method>
-      <method name="Int32 &lt;&gt;m__0()" attrs="145">
-        <size>9</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>197</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
+      <method name="Int32 &lt;&gt;m__0()" attrs="145">
+        <size>21</size>
+      </method>
+    </type>
+    <type name="MyContext">
+      <method name="Void .ctor(ManualResetEvent)" attrs="6278">
+        <size>15</size>
+      </method>
     </type>
   </test>
   <test name="test-async-24.cs">
     <type name="Struct">
       <method name="System.Threading.Tasks.Task`1[System.Boolean] AsyncMethod()" attrs="134">
-        <size>49</size>
+        <size>46</size>
       </method>
       <method name="Void .ctor(Object)" attrs="6278">
         <size>9</size>
     </type>
     <type name="Struct+&lt;AsyncMethod&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>278</size>
+        <size>275</size>
       </method>
       <method name="Int32 &lt;&gt;m__0()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
         <size>27</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[TResult] GetTaskResult[TResult](System.Threading.Tasks.Task`1[System.Threading.Tasks.Task`1[TResult]])" attrs="145">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="Int32 Main()" attrs="145">
         <size>95</size>
     </type>
     <type name="ConsoleApplication1.Program+&lt;GetTaskResult&gt;c__async0`1[TResult]">
       <method name="Void MoveNext()" attrs="486">
-        <size>172</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>169</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
   <test name="test-async-27.cs">
     <type name="MainClass">
       <method name="System.Threading.Tasks.Task AsyncTest()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Void Main(System.String[])" attrs="150">
         <size>31</size>
     </type>
     <type name="MainClass+&lt;AsyncTest&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>199</size>
+        <size>196</size>
       </method>
       <method name="Int32 &lt;&gt;m__0()" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
   <test name="test-async-28.cs">
     <type name="C">
       <method name="System.Threading.Tasks.Task Test()" attrs="150">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Void Main()" attrs="150">
         <size>12</size>
     </type>
     <type name="C+&lt;Test&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>285</size>
+        <size>282</size>
       </method>
       <method name="Int32 &lt;&gt;m__0(Int32)" attrs="145">
         <size>10</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
   <test name="test-async-29.cs">
     <type name="C">
       <method name="System.Threading.Tasks.Task`1[System.Int32] Test()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Int32 Main()" attrs="150">
         <size>20</size>
     </type>
     <type name="C+&lt;Test&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>341</size>
+        <size>331</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
   </test>
   <test name="test-async-30.cs">
         <size>40</size>
       </method>
       <method name="Boolean MoveNext()" attrs="486">
-        <size>105</size>
+        <size>138</size>
       </method>
       <method name="Void Dispose()" attrs="486">
         <size>15</size>
       <method name="Void Reset()" attrs="486">
         <size>6</size>
       </method>
-      <method name="System.Threading.Tasks.Task`1[System.String] &lt;&gt;m__0()" attrs="131">
-        <size>44</size>
-      </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
       </method>
         <size>26</size>
       </method>
       <method name="Boolean MoveNext()" attrs="486">
-        <size>116</size>
+        <size>137</size>
       </method>
       <method name="Void Dispose()" attrs="486">
         <size>15</size>
       <method name="Void Reset()" attrs="486">
         <size>6</size>
       </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test&gt;c__Iterator0+&lt;Test&gt;c__AnonStorey3">
+      <method name="System.Threading.Tasks.Task`1[System.String] &lt;&gt;m__0()" attrs="131">
+        <size>41</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test&gt;c__Iterator0+&lt;Test&gt;c__AnonStorey3+&lt;Test&gt;c__async2">
+      <method name="Void MoveNext()" attrs="486">
+        <size>183</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test2&gt;c__Iterator1+&lt;Test2&gt;c__AnonStorey5">
       <method name="System.Threading.Tasks.Task`1[System.String] &lt;&gt;m__1()" attrs="131">
-        <size>44</size>
+        <size>41</size>
       </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
       </method>
     </type>
-    <type name="C+&lt;Test&gt;c__Iterator0+&lt;Test&gt;c__async2">
+    <type name="C+&lt;Test2&gt;c__Iterator1+&lt;Test2&gt;c__AnonStorey5+&lt;Test2&gt;c__async4">
       <method name="Void MoveNext()" attrs="486">
-        <size>186</size>
+        <size>183</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
+    </type>
+  </test>
+  <test name="test-async-31.cs">
+    <type name="C">
+      <method name="System.Threading.Tasks.Task`1[System.Int32] M(Int32)" attrs="129">
+        <size>41</size>
+      </method>
+      <method name="System.Threading.Tasks.Task`1[System.Int32] M2(Int32, Int32)" attrs="129">
+        <size>49</size>
+      </method>
+      <method name="Int32 Main()" attrs="150">
+        <size>68</size>
+      </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
       </method>
     </type>
-    <type name="C+&lt;Test2&gt;c__Iterator1+&lt;Test2&gt;c__async3">
+    <type name="C+&lt;M&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>186</size>
+        <size>354</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
+      </method>
+    </type>
+    <type name="C+&lt;M2&gt;c__async1">
+      <method name="Void MoveNext()" attrs="486">
+        <size>469</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
+      </method>
+    </type>
+    <type name="C+&lt;M&gt;c__async0+&lt;M&gt;c__AnonStorey3">
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;M&gt;c__async0+&lt;M&gt;c__AnonStorey2">
+      <method name="Int32 &lt;&gt;m__0()" attrs="131">
+        <size>14</size>
+      </method>
+      <method name="Int32 &lt;&gt;m__1()" attrs="131">
+        <size>26</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;M2&gt;c__async1+&lt;M2&gt;c__AnonStorey4">
+      <method name="Void &lt;&gt;m__2()" attrs="131">
+        <size>20</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
+  <test name="test-async-32.cs">
+    <type name="Program">
+      <method name="System.Threading.Tasks.Task`1[System.Int32] TestCanceled()" attrs="145">
+        <size>33</size>
+      </method>
+      <method name="System.Threading.Tasks.Task TestCanceled_2()" attrs="145">
+        <size>33</size>
+      </method>
+      <method name="System.Threading.Tasks.Task`1[System.Int32] TestException()" attrs="145">
+        <size>33</size>
+      </method>
+      <method name="Int32 Main()" attrs="145">
+        <size>274</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Program+&lt;TestCanceled&gt;c__async0">
+      <method name="Void MoveNext()" attrs="486">
+        <size>160</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
+      </method>
+    </type>
+    <type name="Program+&lt;TestCanceled_2&gt;c__async1">
+      <method name="Void MoveNext()" attrs="486">
+        <size>159</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
+      </method>
+    </type>
+    <type name="Program+&lt;TestException&gt;c__async2">
+      <method name="Void MoveNext()" attrs="486">
+        <size>160</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
+      </method>
+    </type>
+    <type name="Program+&lt;Main&gt;c__AnonStorey3">
+      <method name="Void &lt;&gt;m__0(System.Threading.Tasks.Task`1[System.Int32])" attrs="131">
+        <size>14</size>
+      </method>
+      <method name="Void &lt;&gt;m__1(System.Threading.Tasks.Task)" attrs="131">
+        <size>14</size>
+      </method>
+      <method name="Void &lt;&gt;m__2(System.Threading.Tasks.Task`1[System.Int32])" attrs="131">
+        <size>32</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
+  <test name="test-async-33.cs">
+    <type name="A">
+      <method name="System.Threading.Tasks.Task`1[System.Int32] Foo(Int32)" attrs="454">
+        <size>15</size>
+      </method>
+      <method name="System.Threading.Tasks.Task`1[System.Int32] get_Prop()" attrs="2502">
+        <size>14</size>
+      </method>
+      <method name="Void set_Prop(System.Threading.Tasks.Task`1[System.Int32])" attrs="2502">
+        <size>8</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="B">
+      <method name="System.Threading.Tasks.Task`1[System.Int32] get_Prop()" attrs="2246">
+        <size>7</size>
+      </method>
+      <method name="Void set_Prop(System.Threading.Tasks.Task`1[System.Int32])" attrs="2246">
+        <size>7</size>
+      </method>
+      <method name="System.Threading.Tasks.Task`1[System.Int32] Foo(Int32)" attrs="198">
+        <size>49</size>
+      </method>
+      <method name="System.Threading.Tasks.Task`1[System.Int32] Foo2(Int32)" attrs="134">
+        <size>49</size>
+      </method>
+      <method name="System.Threading.Tasks.Task`1[System.Int32] &lt;Foo&gt;__BaseCallProxy0(Int32)" attrs="129">
+        <size>15</size>
+      </method>
+      <method name="Void &lt;set_Prop&gt;__BaseCallProxy1(System.Threading.Tasks.Task`1[System.Int32])" attrs="129">
+        <size>8</size>
+      </method>
+      <method name="System.Threading.Tasks.Task`1[System.Int32] &lt;get_Prop&gt;__BaseCallProxy2()" attrs="129">
+        <size>14</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="Program">
+      <method name="Int32 Main()" attrs="145">
+        <size>76</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="B+&lt;Foo&gt;c__async0">
+      <method name="Void MoveNext()" attrs="486">
+        <size>177</size>
       </method>
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
         <size>13</size>
       </method>
+    </type>
+    <type name="B+&lt;Foo2&gt;c__async1">
+      <method name="Void MoveNext()" attrs="486">
+        <size>191</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
+      </method>
+    </type>
+  </test>
+  <test name="test-async-34.cs">
+    <type name="C">
+      <method name="System.Threading.Tasks.Task Test(Boolean)" attrs="150">
+        <size>41</size>
+      </method>
+      <method name="System.Threading.Tasks.Task Test2(Boolean)" attrs="150">
+        <size>41</size>
+      </method>
+      <method name="Int32 Main()" attrs="150">
+        <size>66</size>
+      </method>
       <method name="Void .ctor()" attrs="6278">
         <size>7</size>
       </method>
     </type>
+    <type name="C+&lt;Test&gt;c__async0">
+      <method name="Void MoveNext()" attrs="486">
+        <size>186</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
+      </method>
+    </type>
+    <type name="C+&lt;Test2&gt;c__async1">
+      <method name="Void MoveNext()" attrs="486">
+        <size>59</size>
+      </method>
+      <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
+        <size>13</size>
+      </method>
+    </type>
   </test>
   <test name="test-cls-00.cs">
     <type name="CLSCLass_6">
         <size>2</size>
       </method>
       <method name="Void Test_1()" attrs="145">
-        <size>31</size>
+        <size>27</size>
       </method>
       <method name="System.Threading.Tasks.Task RunAsync()" attrs="145">
         <size>48</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] Test_2()" attrs="145">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Int32] RunAsync_2()" attrs="145">
         <size>48</size>
       </method>
       <method name="System.Threading.Tasks.Task`1[System.Boolean] Test_3()" attrs="129">
-        <size>37</size>
+        <size>33</size>
       </method>
       <method name="Void &lt;RunAsync&gt;m__0()" attrs="145">
         <size>2</size>
     </type>
     <type name="C+&lt;Test_1&gt;c__async0">
       <method name="Void MoveNext()" attrs="486">
-        <size>159</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>156</size>
       </method>
     </type>
     <type name="C+&lt;Test_2&gt;c__async1">
       <method name="Void MoveNext()" attrs="486">
-        <size>166</size>
-      </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
+        <size>163</size>
       </method>
     </type>
     <type name="C+&lt;Test_3&gt;c__async2">
       <method name="Void MoveNext()" attrs="486">
-        <size>1237</size>
+        <size>1229</size>
       </method>
       <method name="Int32 &lt;&gt;m__2()" attrs="145">
         <size>9</size>
       </method>
-      <method name="Void .ctor()" attrs="6278">
-        <size>7</size>
-      </method>
     </type>
     <type name="C+&lt;Test_1&gt;c__async0">
       <method name="Void SetStateMachine(IAsyncStateMachine)" attrs="486">
       </method>
     </type>
   </test>
+  <test name="test-debug-22.cs">
+    <type name="A">
+      <method name="Int32 Foo()" attrs="454">
+        <size>10</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C">
+      <method name="IEnumerable`1 GetIter()" attrs="134">
+        <size>30</size>
+      </method>
+      <method name="Int32 Foo()" attrs="198">
+        <size>7</size>
+      </method>
+      <method name="Void Main()" attrs="150">
+        <size>2</size>
+      </method>
+      <method name="Int32 &lt;Foo&gt;__BaseCallProxy0()" attrs="129">
+        <size>14</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="C+&lt;GetIter&gt;c__Iterator0">
+      <method name="Int32 System.Collections.Generic.IEnumerator&lt;int&gt;.get_Current()" attrs="2529">
+        <size>14</size>
+      </method>
+      <method name="System.Object System.Collections.IEnumerator.get_Current()" attrs="2529">
+        <size>19</size>
+      </method>
+      <method name="IEnumerator System.Collections.IEnumerable.GetEnumerator()" attrs="481">
+        <size>14</size>
+      </method>
+      <method name="IEnumerator`1 System.Collections.Generic.IEnumerable&lt;int&gt;.GetEnumerator()" attrs="481">
+        <size>40</size>
+      </method>
+      <method name="Boolean MoveNext()" attrs="486">
+        <size>82</size>
+      </method>
+      <method name="Void Dispose()" attrs="486">
+        <size>15</size>
+      </method>
+      <method name="Void Reset()" attrs="486">
+        <size>6</size>
+      </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+  </test>
   <test name="test-externalias-01.cs">
     <type name="Test">
       <method name="Int32 Main()" attrs="145">
         <size>40</size>
       </method>
       <method name="Boolean MoveNext()" attrs="486">
-        <size>211</size>
+        <size>242</size>
       </method>
       <method name="Void Dispose()" attrs="486">
         <size>15</size>
       <method name="Void Reset()" attrs="486">
         <size>6</size>
       </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="X+&lt;GetIt&gt;c__Iterator0+&lt;GetIt&gt;c__AnonStorey1">
       <method name="Void &lt;&gt;m__0()" attrs="131">
         <size>28</size>
       </method>
         <size>26</size>
       </method>
       <method name="Boolean MoveNext()" attrs="486">
-        <size>54</size>
+        <size>75</size>
       </method>
       <method name="Void Dispose()" attrs="486">
         <size>1</size>
       <method name="Void Reset()" attrs="486">
         <size>6</size>
       </method>
+      <method name="Void .ctor()" attrs="6278">
+        <size>7</size>
+      </method>
+    </type>
+    <type name="UploadAction+&lt;TagsError&gt;c__Iterator0+&lt;TagsError&gt;c__AnonStorey1">
       <method name="Void &lt;&gt;m__0()" attrs="131">
         <size>44</size>
       </method>
index 25ebbf497c166b2ff4562a952eefa56366661c6d..0eda031a4bdbbc352e42fd3a89f94df6056c23cb 100755 (executable)
@@ -265,7 +265,7 @@ $net_4_0 = [
        "System.WorkflowServices",
        "System.Xaml",
        "System.Xaml.Hosting",
-       "System.XML",
+       "System.Xml",
        "System.Xml.Linq",
 
        "WindowsBase",
@@ -392,7 +392,7 @@ $net_4_5 = [
        "System.WorkflowServices",
        "System.Xaml",
        "System.Xaml.Hosting",
-       "System.XML",
+       "System.Xml",
        "System.Xml.Linq"
 ]
 
@@ -516,7 +516,6 @@ end
 
 delete("*.tar.gz")
 
-process("1.1", $net_1_1, [$fx1_1])
 process("2.0", $net_2_0, [$fx2_0])
 process("3.0", $net_3_0, [$fx3_0, $fx2_0])
 process("3.5", $net_3_5, [$fx3_5, $fx2_0])
index a7f63d0a1b73d5528546c75ce2cf6acb99f5f62e..4ace2b363f34286047c3d09a29faa8725a72b53e 100644 (file)
@@ -797,9 +797,11 @@ namespace CorCompare
                                return;
                        }
 
-                       string parms = Parameters.GetSignature (methods [0].Parameters);
-                       if (!string.IsNullOrEmpty (parms))
-                               AddAttribute (p, "params", parms);
+                       if (haveGet || _set.Parameters.Count > 1) {
+                               string parms = Parameters.GetSignature (methods [0].Parameters);
+                               if (!string.IsNullOrEmpty (parms))
+                                       AddAttribute (p, "params", parms);
+                       }
 
                        MethodData data = new MethodData (document, p, methods);
                        //data.NoMemberAttributes = true;
index 237d503305d7ce26a847ac734bd026f4a261b4a2..6b19f8b9d5c671ee2eedc7a2b174d661e1412d9d 100755 (executable)
@@ -1,7 +1,7 @@
 #!/usr/bin/env ruby
 
-CURRENT = "2.6"
+CURRENT = "2.8"
 
 Dir["*.tar.gz"].each { |file|
-       system("scp #{file} mono-web@mono.ximian.com:go-mono/masterinfos/#{CURRENT}")
+       system("scp #{file} mono-web@go-mono.com:go-mono/masterinfos/#{CURRENT}")
 }
index d65d7053bb7a6afe546466bdb3f64717eeba53e4..ec9d5a2a87d37a997decf3aa5b6dd288b4957cf5 100644 (file)
@@ -12,8 +12,6 @@ EXTRA_DISTFILES = test.cs
 
 include ../../build/executable.make
 
-test-local: $(PROGRAM) $(TEST_INPUT)
-
 clean-local: cleanup
 
 cleanup:
@@ -21,9 +19,8 @@ cleanup:
 
 run-test-local: run-mono-shlib-cop-test
 
-run-mono-shlib-cop-test: $(PROGRAM) $(TEST_INPUT)
-       $(RUNTIME) $(PROGRAM) $(TEST_INPUT) | diff - test.dll.out
+run-mono-shlib-cop-test: $(the_lib) $(TEST_INPUT)
+       $(RUNTIME) $(the_lib) $(TEST_INPUT) | diff - test.dll.out
 
 $(TEST_INPUT) : test.cs
        $(CSCOMPILE) -target:library $< -out:$@
-
index 757f39a86f76ff641c8e1c1037d02a13c2ebdf92..700a975405bab740c709b3ce974b3d5d627996b8 100644 (file)
@@ -114,10 +114,9 @@ LIB_MCS_FLAGS = \
        /r:$(corlib)                                                      \
        /r:System.dll                                                     \
        /r:System.Core.dll                                                \
-       /r:System.Web                                                     \
-       /r:System.Web.Services                                            \
-       /r:System.Xml.dll                                                 \
-       /r:System.Configuration.dll
+       /r:System.Configuration.dll                                       \
+       /r:System.Web.Services.dll                                        \
+       /r:System.Xml.dll
 
 include ../../build/library.make
 
index 8e890e50a2a1b8ae64a32cd892ff848a19b5061d..2f4cd08f11af3ee4e39b045793f3f57abc3366dd 100644 (file)
@@ -193,7 +193,7 @@ namespace Mono.Documentation {
                public static string GetCachedFileName (string cacheDir, string url)
                {
                        return Path.Combine (cacheDir,
-                                       HttpUtility.UrlEncode (url).Replace ('/', '+').Replace ("*", "%2a"));
+                                            Uri.EscapeUriString (url).Replace ('/', '+').Replace ("*", "%2a"));
                }
        }
 }
index db7ecd7a9951006ad5213b6cb2f539a795645836..0033472a8ad0104c41c6f9922d1100770d22c7cc 100644 (file)
@@ -26,7 +26,9 @@ using System.Xml;
 using System.Xml.XPath;
 using System.Xml.Xsl;
 using System.Text;
+using System.Linq;
 using System.Collections;
+using System.Collections.Generic;
 using Mono.Lucene.Net.Index;
 using Mono.Lucene.Net.Documents;
 
@@ -135,6 +137,73 @@ public static class EcmaDoc {
                return type;
        }
 
+       // Lala
+       static bool IsItReallyAGenericType (string type)
+       {
+               switch (type) {
+               case "Type":
+               case "TimeZone":
+               case "TimeZoneInfo":
+               case "TimeSpan":
+               case "TypeReference":
+               case "TypeCode":
+               case "TimeZoneInfo+AdjustmentRule":
+               case "TimeZoneInfo+TransitionTime":
+                       return false;
+               }
+               if (type.StartsWith ("Tuple"))
+                       return false;
+               return true;
+       }
+
+       public static string ConvertFromCTSName (string ctsType)
+       {
+               if (string.IsNullOrEmpty (ctsType))
+                       return string.Empty;
+
+               // Most normal type should have a namespace part and thus a point in their name
+               if (ctsType.IndexOf ('.') != -1)
+                       return ctsType;
+
+               if (ctsType.EndsWith ("*"))
+                       return ConvertFromCTSName(ctsType.Substring(0, ctsType.Length - 1)) + "*";
+               if (ctsType.EndsWith ("&"))
+                       return ConvertFromCTSName(ctsType.Substring(0, ctsType.Length - 1)) + "&";
+               if (ctsType.EndsWith ("]")) { // Array may be multidimensional
+                       var idx = ctsType.LastIndexOf ('[');
+                       return ConvertFromCTSName (ctsType.Substring (0, idx)) + ctsType.Substring (idx);
+               }
+
+               // Big hack here, we tentatively try to say if a type is a generic when it starts with a upper case T
+               if ((char.IsUpper (ctsType, 0) && ctsType.Length == 1) || (ctsType[0] == 'T' && IsItReallyAGenericType (ctsType)))
+                       return ctsType;
+
+               switch (ctsType) {
+               case "byte": return "System.Byte";
+               case "sbyte": return "System.SByte";
+               case "short": return "System.Int16";
+               case "int": return "System.Int32";
+               case "long": return "System.Int64";
+                       
+               case "ushort": return "System.UInt16";
+               case "uint": return "System.UInt32";
+               case "ulong": return "System.UInt64";
+                       
+               case "float":  return "System.Single";
+               case "double":  return "System.Double";
+               case "decimal": return "System.Decimal";
+               case "bool": return "System.Boolean";
+               case "char":    return "System.Char";
+               case "string":  return "System.String";
+                       
+               case "object":  return "System.Object";
+               case "void":  return "System.Void";
+               }
+
+               // If we arrive here, the type was probably stripped of its 'System.'
+               return "System." + ctsType;
+       }
+
        internal static string GetNamespaceFile (string dir, string ns)
        {
                string nsxml = Path.Combine (dir, "ns-" + ns + ".xml");
@@ -179,7 +248,7 @@ public static class EcmaDoc {
        {
                XmlNodeList parameters = member.SelectNodes ("Parameters/Parameter");
                if (parameters.Count == 0)
-                       return "";
+                       return member.SelectSingleNode ("MemberType").InnerText != "Property" ? "()" : "";
                StringBuilder args = new StringBuilder ();
                args.Append ("(");
                args.Append (XmlDocUtils.ToTypeName (parameters [0].Attributes ["Type"].Value, member));
@@ -1125,7 +1194,7 @@ public class EcmaHelpSource : HelpSource {
 
        static string ToEscapedMemberName (string membername)
        {
-               return ToEscapedName (membername, "``");
+               return ToEscapedName (membername, "`");
        }
        
        public override string GetNodeXPath (XPathNavigator n)
@@ -1563,7 +1632,7 @@ public class EcmaHelpSource : HelpSource {
                        return name.Replace("+", ".");
                }
 
-               public string MonoImpInfo(string assemblyname, string typename, string membername, string arglist, bool strlong)
+               string MonoImpInfo(string assemblyname, string typename, string membername, string arglist, bool strlong)
                {
                        if (quiet)
                                return "";
@@ -1573,7 +1642,7 @@ public class EcmaHelpSource : HelpSource {
                        return MonoImpInfo(assemblyname, typename, membername, a, strlong);
                }
 
-               public string MonoImpInfo(string assemblyname, string typename, string membername, XPathNodeIterator itr, bool strlong)
+               string MonoImpInfo(string assemblyname, string typename, string membername, XPathNodeIterator itr, bool strlong)
                {
                        if (quiet)
                                return "";
@@ -1585,7 +1654,7 @@ public class EcmaHelpSource : HelpSource {
                        return MonoImpInfo (assemblyname, typename, membername, rgs, strlong);
                }
                
-               public string MonoImpInfo(string assemblyname, string typename, string membername, ArrayList arglist, bool strlong)
+               string MonoImpInfo(string assemblyname, string typename, string membername, ArrayList arglist, bool strlong)
                {
                        try {
                                Assembly assembly = null;
@@ -1648,7 +1717,7 @@ public class EcmaHelpSource : HelpSource {
                        }
                }
                
-               public string MonoImpInfo(System.Reflection.MemberInfo mi, string itemtype, bool strlong)
+               string MonoImpInfo(System.Reflection.MemberInfo mi, string itemtype, bool strlong)
                {
                        if (quiet)
                                return "";
@@ -1998,6 +2067,63 @@ public class EcmaHelpSource : HelpSource {
                        }
                }
        }
+
+       IEnumerable<string> ExtractArguments (string rawArgList)
+       {
+               var sb = new System.Text.StringBuilder ();
+               int genericDepth = 0;
+               int arrayDepth = 0;
+
+               for (int i = 0; i < rawArgList.Length; i++) {
+                       char c = rawArgList[i];
+
+                       switch (c) {
+                       case ',':
+                               if (genericDepth == 0 && arrayDepth == 0) {
+                                       yield return sb.ToString ();
+                                       sb.Clear ();
+                                       continue;
+                               }
+                               break;
+                       case '<':
+                               genericDepth++;
+                               break;
+                       case '>':
+                               genericDepth--;
+                               break;
+                       case '[':
+                               arrayDepth++;
+                               break;
+                       case ']':
+                               arrayDepth--;
+                               break;
+                       }
+                       sb.Append (c);
+               }
+               if (sb.Length > 0)
+                       yield return sb.ToString ();
+       }
+
+       // Caption is what you see on a tree node, either SomeName or SomeName(ArgList)
+       void TryCreateXPathPredicateFragment (string caption, out string name, out string argListPredicate)
+       {
+               name = argListPredicate = null;
+               int parenIdx = caption.IndexOf ('(');
+               // In case of simple name, there is no need for processing
+               if (parenIdx == -1) {
+                       name = caption;
+                       return;
+               }
+               name = caption.Substring (0, parenIdx);
+               // Now we create a xpath predicate which will check for all the args in the argsList
+               var rawArgList = caption.Substring (parenIdx + 1, caption.Length - parenIdx - 2); // Only take what's inside the parens
+               if (string.IsNullOrEmpty (rawArgList))
+                       return;
+
+               var argList = ExtractArguments (rawArgList).Select (arg => arg.Trim ()).Select (type => EcmaDoc.ConvertFromCTSName (type));
+               argListPredicate = "and " + argList.Select (type => string.Format ("Parameters/Parameter[@Type='{0}']", type)).Aggregate ((e1, e2) => e1 + " and " + e2);
+       }
+
        //
        // Create list of documents for searching
        //
@@ -2046,22 +2172,50 @@ public class EcmaHelpSource : HelpSource {
                                                
                                                if (c.Element == "*")
                                                        continue;
-                                               int i = 1;
                                                const float innerTypeBoost = 0.2f;
 
-                                               foreach (Node nc in c.Nodes) {
-                                                       // Disable constructors indexing as it's often "polluting" search queries
-                                                       // because it has the same hottext than standard types
-                                                       if (c.Caption == "Constructors")
-                                                               continue;
+                                               var ncnodes = c.Nodes.Cast<Node> ();
+                                               // The rationale is that we need to properly handle method overloads
+                                               // so for those method node which have children, flatten them
+                                               if (c.Caption == "Methods") {
+                                                       ncnodes = ncnodes
+                                                               .Where (n => n.Nodes == null || n.Nodes.Count == 0)
+                                                               .Concat (ncnodes.Where (n => n.Nodes.Count > 0).SelectMany (n => n.Nodes.Cast<Node> ()));
+                                               } else if (c.Caption == "Operators") {
+                                                       ncnodes = ncnodes
+                                                               .Where (n => n.Caption != "Conversion")
+                                                               .Concat (ncnodes.Where (n => n.Caption == "Conversion").SelectMany (n => n.Nodes.Cast<Node> ()));
+                                               }
+                                               foreach (Node nc in ncnodes) {
                                                        //xpath to the docs xml node
                                                        string xpath;
-                                                       if (c.Caption == "Constructors")
-                                                               xpath = String.Format ("/Type/Members/Member[{0}]/Docs", i++);
-                                                       else if (c.Caption == "Operators")
-                                                               xpath = String.Format ("/Type/Members/Member[@MemberName='op_{0}']/Docs", nc.Caption);
-                                                       else
+                                                       string name, argListPredicate;
+
+                                                       switch (c.Caption) {
+                                                       case "Constructors":
+                                                               TryCreateXPathPredicateFragment (nc.Caption, out name, out argListPredicate);
+                                                               xpath = String.Format ("/Type/Members/Member[@MemberName='.ctor'{0}]/Docs", argListPredicate ?? string.Empty);
+                                                               break;
+                                                       case "Operators":
+                                                               // The first case are explicit and implicit conversion operators which are grouped specifically
+                                                               if (nc.Caption.IndexOf (" to ") != -1) {
+                                                                       var convArgs = nc.Caption.Split (new[] { " to " }, StringSplitOptions.None);
+                                                                       xpath = String.Format ("/Type/Members/Member[(@MemberName='op_Explicit' or @MemberName='op_Implicit')" +
+                                                                                              " and ReturnValue/ReturnType='{0}'" +
+                                                                                              " and Parameters/Parameter[@Type='{1}']]/Docs",
+                                                                                              EcmaDoc.ConvertFromCTSName (convArgs[1]), EcmaDoc.ConvertFromCTSName (convArgs[0]));
+                                                               } else {
+                                                                       xpath = String.Format ("/Type/Members/Member[@MemberName='op_{0}']/Docs", nc.Caption);
+                                                               }
+                                                               break;
+                                                       case "Methods":
+                                                               TryCreateXPathPredicateFragment (nc.Caption, out name, out argListPredicate);
+                                                               xpath = String.Format ("/Type/Members/Member[@MemberName='{0}'{1}]/Docs", name, argListPredicate ?? string.Empty);
+                                                               break;
+                                                       default:
                                                                xpath = String.Format ("/Type/Members/Member[@MemberName='{0}']/Docs", nc.Caption);
+                                                               break;
+                                                       }
                                                        //construct url of the form M:Array.Sort
                                                        string urlnc;
                                                        if (c.Caption == "Constructors")
@@ -2085,16 +2239,25 @@ public class EcmaHelpSource : HelpSource {
                                                        case 'O':
                                                                doc_nod.title += " Operator";
                                                                break;
+                                                       case 'C':
+                                                               doc_nod.title += " Constructor";
+                                                               break;
                                                        default:
                                                                break;
                                                        }
                                                        doc_nod.fulltitle = string.Format ("{0}.{1}::{2}", ns_node.Caption, typename, nc.Caption);
-                                                       //dont add the parameters to the hottext
-                                                       int ppos = nc.Caption.IndexOf ('(');
-                                                       if (ppos != -1)
-                                                               doc_nod.hottext =  nc.Caption.Substring (0, ppos);
-                                                       else
-                                                               doc_nod.hottext = nc.Caption;
+                                                       // Disable constructors hottext indexing as it's often "polluting" search queries
+                                                       // because it has the same hottext than standard types
+                                                       if (c.Caption != "Constructors") {
+                                                               //dont add the parameters to the hottext
+                                                               int ppos = nc.Caption.IndexOf ('(');
+                                                               if (ppos != -1)
+                                                                       doc_nod.hottext =  nc.Caption.Substring (0, ppos);
+                                                               else
+                                                                       doc_nod.hottext = nc.Caption;
+                                                       } else {
+                                                               doc_nod.hottext = string.Empty;
+                                                       }
 
                                                        doc_nod.url = urlnc;
 
@@ -2108,7 +2271,7 @@ public class EcmaHelpSource : HelpSource {
                                                        GetTextFromNode (xmln, text);
                                                        doc_nod.text = text.ToString ();
 
-                                                       text = new StringBuilder ();
+                                                       text.Clear ();
                                                        GetExamples (xmln, text);
                                                        doc_nod.examples = text.ToString ();
 
index c8b2383cbab6134ad15d712c48f538656b506324..fd7a4b3c147be1a359fe604dd923c046e4620546 100644 (file)
@@ -22,8 +22,8 @@ namespace Monodoc {
                
                public static string FormatEditUri (string document_identifier, string xpath)
                {
-                       return String.Format ("edit:{0}@{1}", HttpUtility.UrlEncode (document_identifier),
-                               HttpUtility.UrlEncode (xpath));
+                       return String.Format ("edit:{0}@{1}", Uri.EscapeUriString (document_identifier),
+                               Uri.EscapeUriString (xpath));
                }
                
                public static string GetXPath (XPathNavigator n)
@@ -157,8 +157,8 @@ namespace Monodoc {
                        if (parts.Length != 2)
                                throw new Exception (String.Format ("invalid editing url {0}", parts.Length));
                        
-                       string xp = HttpUtility.UrlDecode (parts [1]);
-                       parts = HttpUtility.UrlDecode (parts [0]).Substring ("edit:".Length).Split ('@');
+                       string xp = Uri.UnescapeDataString (parts [1]);
+                       parts = Uri.UnescapeDataString (parts [0]).Substring ("edit:".Length).Split ('@');
                        if (parts.Length == 1) {
                                string p = parts[0];
                                parts = new string[2];
index 38db7012efeec287ac428c0b89155613840748ec..9d33338ad8ea340692caca9eedf98ee5e3315410 100644 (file)
@@ -557,7 +557,7 @@ public class HelpSource {
        {
                if (nozip) {
                        Stream s = File.OpenRead (XmlDocUtils.GetCachedFileName (base_dir, id));
-                       string url = "monodoc:///" + SourceID + "@" + System.Web.HttpUtility.UrlEncode (id) + "@";
+                       string url = "monodoc:///" + SourceID + "@" + Uri.EscapeUriString (id) + "@";
                        return new XmlTextReader (url, s);
                }
 
@@ -567,7 +567,7 @@ public class HelpSource {
                ZipEntry entry = zip_file.GetEntry (id);
                if (entry != null) {
                        Stream s = zip_file.GetInputStream (entry);
-                       string url = "monodoc:///" + SourceID + "@" + System.Web.HttpUtility.UrlEncode (id) + "@";
+                       string url = "monodoc:///" + SourceID + "@" + Uri.EscapeUriString (id) + "@";
                        return new XmlTextReader (url, s);
                }
                return null;
@@ -577,7 +577,7 @@ public class HelpSource {
        {
                if (nozip) {
                        Stream s = File.OpenRead (XmlDocUtils.GetCachedFileName (base_dir, id));
-                       string url = "monodoc:///" + SourceID + "@" + System.Web.HttpUtility.UrlEncode (id) + "@";
+                       string url = "monodoc:///" + SourceID + "@" + Uri.EscapeUriString (id) + "@";
                        XmlReader r = new XmlTextReader (url, s);
                        XmlDocument ret = new XmlDocument ();
                        ret.Load (r);
@@ -590,7 +590,7 @@ public class HelpSource {
                ZipEntry entry = zip_file.GetEntry (id);
                if (entry != null) {
                        Stream s = zip_file.GetInputStream (entry);
-                       string url = "monodoc:///" + SourceID + "@" + System.Web.HttpUtility.UrlEncode (id) + "@";
+                       string url = "monodoc:///" + SourceID + "@" + Uri.EscapeUriString (id) + "@";
                        XmlReader r = new XmlTextReader (url, s);
                        XmlDocument ret = new XmlDocument ();
                        ret.Load (r);
index 5c580d7a0dd98cc9164075bcb5da8702c86e9d70..c8a84a84634bc15ed1c6b75661af05d95a4e6f22 100644 (file)
        </xsl:template>
 
        <xsl:template name="CreateTypeSignature">
-                       <xsl:attribute name="id">
-                               <xsl:text>T:</xsl:text>
-                               <xsl:call-template name="GetEscapedTypeName">
-                                       <xsl:with-param name="typename" select="@FullName" />
-                               </xsl:call-template>
-                               <xsl:text>:Signature</xsl:text>
-                       </xsl:attribute>
-                       <!-- signature -->
                        <xsl:call-template name="CreateSignature">
+                           <xsl:with-param name="id">
+                                 <xsl:text>T:</xsl:text>
+                                 <xsl:call-template name="GetEscapedTypeName">
+                                       <xsl:with-param name="typename" select="@FullName" />
+                                 </xsl:call-template>
+                                 <xsl:text>:Signature</xsl:text>
+                               </xsl:with-param>
                                <xsl:with-param name="content">
+                       <!-- signature -->
                                        <xsl:choose>
                                        <xsl:when test="$language='C#'">
 
                <h3 class="{$type}"><xsl:value-of select="$section" /></h3>
                <ul class="{$type}">
                  <xsl:for-each select="Docs/related[@type=$type]">
-                       <li><a href="{@href}"><xsl:value-of select="." /></a></li>
+                       <li><a href="{@href}" target="_blank"><xsl:value-of select="." /></a></li>
                  </xsl:for-each>
                </ul>
          </xsl:if>
                                  <xsl:with-param name="type" select="'recipe'" />
                                </xsl:call-template>
                                <xsl:call-template name="CreateRelatedSection">
-                                 <xsl:with-param name="section" select="'Available Samples'" />
+                                 <xsl:with-param name="section" select="'Samples'" />
                                  <xsl:with-param name="type" select="'sample'" />
                                </xsl:call-template>
                                <xsl:call-template name="CreateRelatedSection">
@@ -2551,7 +2551,7 @@ SkipGenericArgument: invalid type substring '<xsl:value-of select="$s" />'
                        <xsl:with-param name="type" select="$type" />
                        <xsl:with-param name="member" select="$member" />
                </xsl:call-template>
-               <xsl:if test="count($member/Parameters/Parameter) &gt; 0 or $member/MemberType='Method'">
+               <xsl:if test="count($member/Parameters/Parameter) &gt; 0 or $member/MemberType='Method' or $member/MemberType='Constructor'">
                        <xsl:text>(</xsl:text>
                        <xsl:for-each select="Parameters/Parameter">
                                <xsl:if test="not(position()=1)">,</xsl:if>
index ab310431088658a1916d0c9d099c5166b20cd0c2..11772ee344b7784d70a2b8f181c0a7d900c23da1 100644 (file)
 
        <xsl:template name="CreateSignature">
                <xsl:param name="content" />
+               <xsl:param name="id" />
                <h2>Syntax</h2>
                <div class="Signature">
+                       <xsl:attribute name="id">
+                         <xsl:copy-of select="$id" />
+                       </xsl:attribute>
                        <xsl:copy-of select="$content" />
                </div>
        </xsl:template>
index 03d8383cf2b18e2a8e3fc99311fcb9393c66b766..894faeaf9ee5768a26e5a457bf191ec142394ce5 100644 (file)
 
        <xsl:template name="CreateSignature">
                <xsl:param name="content" />
+               <xsl:param name="id" />
                <table class="SignatureTable" bgcolor="#c0c0c0" cellspacing="0" width="100%">
+                 <xsl:attribute name="id">
+                       <xsl:copy-of select="$id" />
+                 </xsl:attribute>
                <tr><td>
                        <table class="InnerSignatureTable" cellpadding="10" cellspacing="0" width="100%">
                        <tr bgcolor="#f2f2f2">
index 2d09ad1d285b83d97082cd7db68119b3ae40cc9a..5fbba9ff068c10c7858f8e62d7cba7a60493a761 100644 (file)
@@ -6,7 +6,8 @@ LOCAL_MCS_FLAGS = \
        -r:System.Core.dll \
        -r:System.Runtime.Serialization.dll \
        -r:System.ServiceModel.dll \
-       -r:System.Web.Services.dll
+       -r:System.Web.Services.dll \
+       -r:System.Configuration.dll
 PROGRAM = svcutil.exe
 
 include ../../build/executable.make
index d06b6b25447b2076b47a32869362dfb092fb4d0a..3d53996a826d2453368a623272447021b60035dd 100644 (file)
@@ -1,7 +1,7 @@
 thisdir = tools/xbuild
 SUBDIRS = 
 include ../../build/rules.make
-HAS_NUNIT_TEST = yes
+NO_TESTS = yes
 
 BUILD_FRAMEWORK = Microsoft.Build.Framework.dll
 BUILD_ENGINE = Microsoft.Build.Engine.dll
@@ -25,8 +25,6 @@ PROGRAM = xbuild.exe
 
 include ../../build/executable.make
 
-CLEAN_FILES= xbuild.exe xbuild.exe.mdb
-
 XBUILD_DIR=.
 XBUILD_FRAMEWORKS_DIR=$(mono_libdir)/mono/xbuild-frameworks/.NETFramework/
 REDISTLIST_DIR=$(XBUILD_FRAMEWORKS_DIR)/v$(FRAMEWORK_VERSION)/RedistList
@@ -36,6 +34,7 @@ install-local:        install-extras
 
 WEBAPP_DIR = Microsoft/VisualStudio/v9.0/WebApplications
 SILVERLIGHT_DIR = $(mono_libdir)/mono/xbuild/Microsoft/Silverlight
+PORTABLE_DIR = $(mono_libdir)/mono/xbuild/Microsoft/Portable
 EXTRAS_DIR = $(mono_libdir)/mono/$(INSTALL_FRAMEWORK_VERSION)
 install-extras: 
        $(MKINSTALLDIRS) $(DESTDIR)$(EXTRAS_DIR) $(DESTDIR)$(REDISTLIST_DIR) $(DESTDIR)$(XBUILD_FRAMEWORKS_DIR)/v3.0/RedistList $(DESTDIR)$(XBUILD_FRAMEWORKS_DIR)/v4.0/RedistList
@@ -62,6 +61,8 @@ install-extras:
        $(INSTALL_DATA) xbuild/Microsoft.Silverlight.VisualBasic.targets $(DESTDIR)$(SILVERLIGHT_DIR)/v3.0
        sed -e 's/@SILVERLIGHT_VERSION@/2.0/g' xbuild/Microsoft.Silverlight.Common.targets > $(DESTDIR)$(SILVERLIGHT_DIR)/v2.0/Microsoft.Silverlight.Common.targets
        sed -e 's/@SILVERLIGHT_VERSION@/3.0/g' xbuild/Microsoft.Silverlight.Common.targets > $(DESTDIR)$(SILVERLIGHT_DIR)/v3.0/Microsoft.Silverlight.Common.targets
+       $(MKINSTALLDIRS) $(DESTDIR)$(PORTABLE_DIR)/v4.0
+       $(INSTALL_DATA) xbuild/Microsoft.Portable.CSharp.targets $(DESTDIR)$(PORTABLE_DIR)/v4.0
 
 EXTRA_DISTFILES = \
        xbuild/xbuild.rsp \
@@ -87,4 +88,5 @@ EXTRA_DISTFILES = \
        xbuild/Microsoft.Silverlight.Common.targets \
        xbuild/Microsoft.Silverlight.CSharp.targets \
        xbuild/Microsoft.Silverlight.VisualBasic.targets \
+       xbuild/Microsoft.Portable.CSharp.targets \
        xbuild_targets.make
diff --git a/mcs/tools/xbuild/xbuild/Microsoft.Portable.CSharp.targets b/mcs/tools/xbuild/xbuild/Microsoft.Portable.CSharp.targets
new file mode 100644 (file)
index 0000000..91e546f
--- /dev/null
@@ -0,0 +1,35 @@
+<!-- Note: This is a dummy CSharp.targets file that tries to map Portable Library Project targets to something available in Mono on Mac -->
+
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+       
+       <PropertyGroup>
+               <TargetFrameworkIdentifier>.NETFramework</TargetFrameworkIdentifier>
+               <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
+               <TargetFrameworkProfile></TargetFrameworkProfile>
+       </PropertyGroup>
+       
+       <PropertyGroup Condition = "Exists ('/Developer/MonoTouch/License.rtf')">
+               <TargetFrameworkIdentifier>MonoTouch</TargetFrameworkIdentifier>
+               <TargetFrameworkVersion>v1.0</TargetFrameworkVersion>
+               <TargetFrameworkProfile></TargetFrameworkProfile>
+       </PropertyGroup>
+       
+       <PropertyGroup Condition = "Exists ('/Developer/MonoAndroid/License.rtf') And !Exists ('/Developer/MonoTouch/License.rtf')">
+               <TargetFrameworkVersion>v1.0</TargetFrameworkVersion>
+       </PropertyGroup>
+       
+       <Import Project="$(MSBuildToolsPath)\Novell\Novell.MonoDroid.CSharp.targets" Condition = "Exists ('/Developer/MonoAndroid/License.rtf') And !Exists ('/Developer/MonoTouch/License.rtf')"/>
+       <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.Targets" Condition = "Exists ('/Developer/MonoTouch/License.rtf') Or !Exists ('/Developer/MonoAndroid/License.rtf')"/>
+       
+       <PropertyGroup>
+               <BuildDependsOn>
+                       PortableCompatWarning;
+                       $(BuildDependsOn);
+               </BuildDependsOn>
+       </PropertyGroup>
+       
+       <Target Name="PortableCompatWarning">
+               <Warning Text="This Portable Library Project has been built against the $(TargetFrameworkIdentifier) framework."/>
+       </Target>
+       
+</Project>
index 6d44358bf327b3d0dd2bb9f48073f314af2e8809..3ae00a3446f293a11ff76a3d0727e50c07ffd478 100644 (file)
@@ -103,7 +103,9 @@ export PATH=/opt/novell/llvm-mono/bin:$PATH
 %endif
   --with-ikvm=yes \
   --with-moonlight=no
-make # We are not -jN safe! %{?jobs:-j%jobs}
+#make # We are not -jN safe! %{?jobs:-j%jobs}
+# We are now !
+make %{?_smp_mflags}
 
 %install
 make install DESTDIR=%buildroot
@@ -848,6 +850,7 @@ Mono implementation of ASP.NET, Remoting and Web Services.
 %_bindir/wsdl
 %_bindir/wsdl2
 %_bindir/xsd
+%_libdir/pkgconfig/aspnetwebstack.pc
 %_libdir/pkgconfig/mono.web.pc
 %_mandir/man1/disco.1%ext_man
 %_mandir/man1/mconfig.1%ext_man
@@ -881,12 +884,18 @@ Mono implementation of ASP.NET, Remoting and Web Services.
 %_prefix/lib/mono/4.5/Mono.Web.dll
 %_prefix/lib/mono/4.5/System.ComponentModel.Composition.dll
 %_prefix/lib/mono/4.5/System.ComponentModel.DataAnnotations.dll
+%_prefix/lib/mono/4.5/System.Net.Http.Formatting.dll
 %_prefix/lib/mono/4.5/System.Runtime.Remoting.dll
 %_prefix/lib/mono/4.5/System.Runtime.Serialization.Formatters.Soap.dll
 %_prefix/lib/mono/4.5/System.Web.Abstractions.dll
 %_prefix/lib/mono/4.5/System.Web.ApplicationServices.dll
+%_prefix/lib/mono/4.5/System.Web.Http.dll
 %_prefix/lib/mono/4.5/System.Web.Routing.dll
+%_prefix/lib/mono/4.5/System.Web.Razor.dll
 %_prefix/lib/mono/4.5/System.Web.Services.dll
+%_prefix/lib/mono/4.5/System.Web.WebPages.Deployment.dll
+%_prefix/lib/mono/4.5/System.Web.WebPages.Razor.dll
+%_prefix/lib/mono/4.5/System.Web.WebPages.dll
 %_prefix/lib/mono/4.5/System.Web.dll
 %_prefix/lib/mono/4.5/disco.exe*
 %_prefix/lib/mono/4.5/mconfig.exe*
@@ -899,13 +908,19 @@ Mono implementation of ASP.NET, Remoting and Web Services.
 %_prefix/lib/mono/gac/Mono.Web
 %_prefix/lib/mono/gac/System.ComponentModel.Composition
 %_prefix/lib/mono/gac/System.ComponentModel.DataAnnotations
+%_prefix/lib/mono/gac/System.Net.Http.Formatting
 %_prefix/lib/mono/gac/System.Runtime.Remoting
 %_prefix/lib/mono/gac/System.Runtime.Serialization.Formatters.Soap
 %_prefix/lib/mono/gac/System.Web
 %_prefix/lib/mono/gac/System.Web.Abstractions
 %_prefix/lib/mono/gac/System.Web.ApplicationServices
+%_prefix/lib/mono/gac/System.Web.Http
 %_prefix/lib/mono/gac/System.Web.Routing
+%_prefix/lib/mono/gac/System.Web.Razor
 %_prefix/lib/mono/gac/System.Web.Services
+%_prefix/lib/mono/gac/System.Web.WebPages.Deployment
+%_prefix/lib/mono/gac/System.Web.WebPages.Razor
+%_prefix/lib/mono/gac/System.Web.WebPages
 
 %package -n mono-mvc
 License:        MIT License (or similar) ; Ms-Pl
@@ -928,6 +943,7 @@ Mono implementation of ASP.NET MVC.
 %_libdir/pkgconfig/system.web.extensions_1.0.pc
 %_libdir/pkgconfig/system.web.mvc.pc
 %_libdir/pkgconfig/system.web.mvc2.pc
+%_libdir/pkgconfig/system.web.mvc3.pc
 %_prefix/lib/mono/2.0/System.Web.DynamicData.dll
 %_prefix/lib/mono/2.0/System.Web.Extensions.Design.dll
 %_prefix/lib/mono/2.0/System.Web.Extensions.dll
@@ -938,6 +954,7 @@ Mono implementation of ASP.NET MVC.
 %_prefix/lib/mono/4.5/System.Web.DynamicData.dll
 %_prefix/lib/mono/4.5/System.Web.Extensions.Design.dll
 %_prefix/lib/mono/4.5/System.Web.Extensions.dll
+%_prefix/lib/mono/4.5/System.Web.Mvc.dll
 %_prefix/lib/mono/compat-2.0/System.Web.Extensions.Design.dll
 %_prefix/lib/mono/compat-2.0/System.Web.Extensions.dll
 %_prefix/lib/mono/compat-2.0/System.Web.Mvc.dll
@@ -1201,7 +1218,6 @@ Mono development tools.
 %_prefix/lib/mono/4.0/Microsoft.Common.tasks
 %_prefix/lib/mono/4.0/Microsoft.VisualBasic.targets
 %_prefix/lib/mono/4.0/Mono.Debugger.Soft.dll
-%_prefix/lib/mono/4.0/Mono.CodeContracts.dll
 %_prefix/lib/mono/4.0/PEAPI.dll
 %_prefix/lib/mono/4.5/Microsoft.Build.dll
 %_prefix/lib/mono/4.5/Microsoft.Build.Engine.dll
index 0a478bc9f6bb1941876a44e5ff91050540e64b47..5074f260d89a39f10839f877f6b2b54212440922 100644 (file)
@@ -95,7 +95,7 @@ void dump_reg(ARMDis* dis, int reg) {
        if (!use_reg_alias || (reg > 3 && reg < 11)) {
                fprintf(dis->dis_out, "r%d", reg);
        } else {
-               fprintf(dis->dis_out, reg_alias[reg]);
+               fprintf(dis->dis_out, "%s", reg_alias[reg]);
        }
 }
 
@@ -137,7 +137,7 @@ void dump_reglist(ARMDis* dis, int reg_list) {
 
 
 void dump_br(ARMDis* dis, ARMInstr i) {
-       fprintf(dis->dis_out, "b%s%s\t%x\t; %p -> %p",
+       fprintf(dis->dis_out, "b%s%s\t%x\t; %p -> %#x",
            (i.br.link == 1) ? "l" : "",
            cond[i.br.cond], i.br.offset, dis->pi, (int)dis->pi + 4*2 + ((int)(i.br.offset << 8) >> 6));
 }
@@ -376,7 +376,7 @@ void dump_swi(ARMDis* dis, ARMInstr i) {
 
 
 void dump_clz(ARMDis* dis, ARMInstr i) {
-       fprintf(dis->dis_out, "clz%s\t");
+       fprintf(dis->dis_out, "clz\t");
        dump_reg(dis, i.clz.rd);
        fprintf(dis->dis_out, ", ");
        dump_reg(dis, i.clz.rm);
index 7f74e3d740d4e2175c9c7af43310046d6ee81d5a..d3292bffb907295510f3f20f3602fc1955d63153 100644 (file)
@@ -146,6 +146,8 @@ typedef enum {
 #define s390_is_uimm12(val)            ((glong)val >= 0 && (glong)val <= 4095)
 
 #define STK_BASE                       s390_r15
+#define S390_SP                                s390_r15
+#define S390_FP                                s390_r11
 #define S390_MINIMAL_STACK_SIZE                160
 #define S390_REG_SAVE_OFFSET           48
 #define S390_PARM_SAVE_OFFSET          16
index 24fcd94f81b2ff0e05e950af183fccc0428d7d7f..9c397f4e41bb1c6c689dc5efe2ee8404efc33aaa 100644 (file)
@@ -10,9 +10,13 @@ else
 runtime_lib=../interpreter/libmint.la
 endif
 
+if DISABLE_EXECUTABLES
+bin_PROGRAMS =
+else
 if SUPPORT_BOEHM
 bin_PROGRAMS = monodis
 endif
+endif
 
 noinst_LIBRARIES = libmonodis.a
 
index 630a1c3be3a0fcefcb0e9fef3769a6ea6a1af3d7..62d36a88785bf6ae534b4affd97f6d032d310338 100644 (file)
@@ -60,7 +60,11 @@ moon-do-clean:
        -test -z "libmonoruntimemoon.la" || rm -f libmonoruntimemoon.la
 endif
 
+if DISABLE_EXECUTABLES
+noinst_LTLIBRARIES = $(shared_sgen_libraries) $(shared_boehm_libraries)
+else
 noinst_LTLIBRARIES = $(boehm_libraries) $(sgen_libraries) $(moonlight_libraries)
+endif
 
 INCLUDES = -I$(top_srcdir) -I$(top_srcdir)/mono $(LIBGC_CPPFLAGS) $(GLIB_CFLAGS) -DMONO_BINDIR=\"$(bindir)/\" -DMONO_ASSEMBLIES=\"$(assembliesdir)\" -DMONO_CFG_DIR=\"$(confdir)\"
 
@@ -216,7 +220,10 @@ libmonoruntime_la_SOURCES = \
        sgen-gray.c     \
        sgen-gray.h     \
        sgen-major-copy-object.h \
+       sgen-minor-copy-object.h \
+       sgen-copy-object.h \
        sgen-major-scan-object.h \
+       sgen-minor-scan-object.h \
        sgen-protocol.h         \
        sgen-scan-object.h      \
        sgen-nursery-allocator.c        \
@@ -225,6 +232,8 @@ libmonoruntime_la_SOURCES = \
        sgen-descriptor.h               \
        sgen-alloc.c            \
        sgen-debug.c            \
+       sgen-simple-nursery.c   \
+       sgen-split-nursery.c    \
        string-icalls.c         \
        string-icalls.h         \
        sysmath.h               \
index 70f9bfa569d59d97d10c2fbd7efe01d241aa1de0..9b12e7b0f86571f6d47f2e0aa5fc4879704d8d06 100644 (file)
@@ -74,7 +74,7 @@
  * Changes which are already detected at runtime, like the addition
  * of icalls, do not require an increment.
  */
-#define MONO_CORLIB_VERSION 100
+#define MONO_CORLIB_VERSION 101
 
 typedef struct
 {
index 278ca22ebc3887dc912eaff9f3cdfb58a3ee514b..bcb23082d9eb104e5ad71db191eaf53059fa6c30 100644 (file)
@@ -1278,4 +1278,18 @@ mono_gc_get_vtable_bits (MonoClass *class)
        return 0;
 }
 
+/*
+ * mono_gc_register_altstack:
+ *
+ *   Register the dimensions of the normal stack and altstack with the collector.
+ * Currently, STACK/STACK_SIZE is only used when the thread is suspended while it is on an altstack.
+ */
+void
+mono_gc_register_altstack (gpointer stack, gint32 stack_size, gpointer altstack, gint32 altstack_size)
+{
+#ifdef USE_INCLUDED_LIBGC
+       GC_register_altstack (stack, stack_size, altstack, altstack_size);
+#endif
+}
+
 #endif /* no Boehm GC */
index 602c9b534cbb0395c6357e5b0c87f900183170b6..8b559e274cb9a39631b0e01e7b371f37ea016bd3 100644 (file)
@@ -318,6 +318,7 @@ struct _MonoClass {
        guint is_inflated : 1; /* class is a generic instance */
        /* next byte */
        guint has_finalize_inited    : 1; /* has_finalize is initialized */
+       guint fields_inited : 1; /* fields is initialized */
 
        guint8     exception_type;      /* MONO_EXCEPTION_* */
 
@@ -643,6 +644,9 @@ typedef struct {
 void
 mono_class_setup_supertypes (MonoClass *klass) MONO_INTERNAL;
 
+void
+mono_class_setup_fields_locking (MonoClass *class) MONO_INTERNAL;
+
 /* WARNING
  * Only call this function if you can ensure both @klass and @parent
  * have supertype information initialized.
index f6e175e7a4639632b4b270c2d8f5909ea6b9f401..cc1cf0799f357c198adf586f99dc1dadc5c121bf 100644 (file)
@@ -1388,7 +1388,11 @@ mono_class_setup_fields (MonoClass *class)
        explicit_size = mono_metadata_packing_from_typedef (class->image, class->type_token, &packing_size, &real_size);
 
        if (explicit_size) {
-               g_assert ((packing_size & 0xfffffff0) == 0);
+               if ((packing_size & 0xfffffff0) != 0) {
+                       char *err_msg = g_strdup_printf ("Could not load struct '%s' with packing size %d >= 16", class->name, packing_size);
+                       mono_class_set_failure (class, MONO_EXCEPTION_TYPE_LOAD, err_msg);
+                       return;
+               }
                class->packing_size = packing_size;
                real_size += class->instance_size;
        }
@@ -1399,6 +1403,8 @@ mono_class_setup_fields (MonoClass *class)
                }
                class->size_inited = 1;
                class->blittable = blittable;
+               mono_memory_barrier ();
+               class->fields_inited = 1;
                return;
        }
 
@@ -1514,6 +1520,9 @@ mono_class_setup_fields (MonoClass *class)
        /*valuetypes can't be neither bigger than 1Mb or empty. */
        if (class->valuetype && (class->instance_size <= 0 || class->instance_size > (0x100000 + sizeof (MonoObject))))
                mono_class_set_failure (class, MONO_EXCEPTION_TYPE_LOAD, NULL);
+
+       mono_memory_barrier ();
+       class->fields_inited = 1;
 }
 
 /** 
@@ -1523,9 +1532,12 @@ mono_class_setup_fields (MonoClass *class)
  * Initializes the class->fields array of fields.
  * Aquires the loader lock.
  */
-static void
+void
 mono_class_setup_fields_locking (MonoClass *class)
 {
+       /* This can be checked without locks */
+       if (class->fields_inited)
+               return;
        mono_loader_lock ();
        mono_class_setup_fields (class);
        mono_loader_unlock ();
@@ -2407,7 +2419,7 @@ mono_unload_interface_ids (MonoBitSet *bitset)
 void
 mono_unload_interface_id (MonoClass *class)
 {
-       if (class->interface_id) {
+       if (global_interface_bitset && class->interface_id) {
                mono_loader_lock ();
                mono_bitset_clear (global_interface_bitset, class->interface_id);
                mono_loader_unlock ();
@@ -2718,7 +2730,8 @@ get_implicit_generic_array_interfaces (MonoClass *class, int *num, int *is_enume
                         */
                        eclass = mono_class_from_mono_type (class->generic_class->context.class_inst->type_argv [0]);
                        original_rank = eclass->rank;
-                       eclass = eclass->element_class;
+                       if (!eclass->rank)
+                               eclass = eclass->element_class;
                        internal_enumerator = TRUE;
                        *is_enumerator = TRUE;
                } else {
@@ -3094,7 +3107,7 @@ mono_class_interface_match (const uint8_t *bitmap, int id)
  * Return -1 on failure and set exception_type
  */
 static int
-setup_interface_offsets (MonoClass *class, int cur_slot)
+setup_interface_offsets (MonoClass *class, int cur_slot, gboolean overwrite)
 {
        MonoError error;
        MonoClass *k, *ic;
@@ -3261,10 +3274,14 @@ setup_interface_offsets (MonoClass *class, int cur_slot)
        }
 
        /*
-        * We might get called twice: once from mono_class_init () then once from 
-        * mono_class_setup_vtable ().
+        * We might get called multiple times:
+        * - mono_class_init ()
+        * - mono_class_setup_vtable ().
+        * - mono_class_setup_interface_offsets ().
+        * mono_class_setup_interface_offsets () passes 0 as CUR_SLOT, so the computed interface offsets will be invalid. This
+        * means we have to overwrite those when called from other places (#4440).
         */
-       if (class->interfaces_packed) {
+       if (class->interfaces_packed && !overwrite) {
                g_assert (class->interface_offsets_count == interface_offsets_count);
        } else {
                uint8_t *bitmap;
@@ -3329,7 +3346,7 @@ mono_class_setup_interface_offsets (MonoClass *class)
 {
        mono_loader_lock ();
 
-       setup_interface_offsets (class, 0);
+       setup_interface_offsets (class, 0, FALSE);
 
        mono_loader_unlock ();
 }
@@ -3979,7 +3996,7 @@ mono_class_setup_vtable_general (MonoClass *class, MonoMethod **overrides, int o
 
        /* printf ("METAINIT %s.%s\n", class->name_space, class->name); */
 
-       cur_slot = setup_interface_offsets (class, cur_slot);
+       cur_slot = setup_interface_offsets (class, cur_slot, TRUE);
        if (cur_slot == -1) /*setup_interface_offsets fails the type.*/
                return;
 
@@ -4911,9 +4928,9 @@ mono_class_init (MonoClass *class)
                first_iface_slot = class->parent->vtable_size;
                if (mono_class_need_stelemref_method (class))
                        ++first_iface_slot;
-               setup_interface_offsets (class, first_iface_slot);
+               setup_interface_offsets (class, first_iface_slot, TRUE);
        } else {
-               setup_interface_offsets (class, 0);
+               setup_interface_offsets (class, 0, TRUE);
        }
 
        if (mono_security_get_mode () == MONO_SECURITY_MODE_CORE_CLR)
@@ -5715,7 +5732,7 @@ make_generic_param_class (MonoGenericParam *param, MonoImage *image, gboolean is
                if (klass->parent->exception_type)
                        mono_class_set_failure (klass, MONO_EXCEPTION_TYPE_LOAD, g_strdup ("Failed to setup parent interfaces"));
                else
-                       setup_interface_offsets (klass, klass->parent->vtable_size);
+                       setup_interface_offsets (klass, klass->parent->vtable_size, TRUE);
        }
 
        return klass;
@@ -9021,6 +9038,7 @@ mono_classes_cleanup (void)
 {
        if (global_interface_bitset)
                mono_bitset_free (global_interface_bitset);
+       global_interface_bitset = NULL;
 }
 
 /**
index 7527d598c238de91c39a08c17655e3cdc6e34d88..f6adfcd1ce07c3ca3923a3a0db0de8237d5a4fa4 100644 (file)
@@ -392,7 +392,7 @@ cominterop_com_visible (MonoClass* klass)
        MonoError error;
        MonoCustomAttrInfo *cinfo;
        GPtrArray *ifaces;
-       MonoBoolean visible = 0;
+       MonoBoolean visible = 1;
 
        /* Handle the ComVisibleAttribute */
        if (!ComVisibleAttribute)
@@ -831,7 +831,7 @@ cominterop_get_native_wrapper_adjusted (MonoMethod *method)
                }
        }
 
-       mono_marshal_emit_native_wrapper (method->klass->image, mb_native, sig_native, piinfo, mspecs, piinfo->addr, FALSE, TRUE);
+       mono_marshal_emit_native_wrapper (method->klass->image, mb_native, sig_native, piinfo, mspecs, piinfo->addr, FALSE, TRUE, FALSE);
 
        res = mono_mb_create_method (mb_native, sig_native, sig_native->param_count + 16);      
 
index 4a737b26637ee1c9f29ba081176c1f92c869d14a..8f634f2833239ee59158745c75983dd685ba8afe 100644 (file)
 #define MONO_METADATA_CULTURE_INFO_TABLES 1
 
 
-#define NUM_CULTURE_ENTRIES 167
-#define NUM_REGION_ENTRIES 230
+#define NUM_CULTURE_ENTRIES 283
+#define NUM_REGION_ENTRIES 120
 
 
 static const DateTimeFormatEntry datetime_format_entries [] = {
-       {1, 24, 37, 46, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37},{357,24},{370,56},{376,46}},
-       {387, 409, 422, 438, 370, 447, 457, 465, 468, {471, 484, 505, 520, 531, 550, 561}, {574, 582, 590, 596, 602, 612, 620}, {628, 641, 658, 667, 678, 685, 692, 699, 712, 731, 748, 763, 343}, {780, 786, 658, 794, 678, 685, 692, 802, 810, 818, 826, 836, 343}, 0, 1, 844, 346, {348,846,422},{357,409},{370},{376,438}},
-       {855, 878, 890, 376, 370, 447, 457, 465, 468, {899, 908, 916, 924, 933, 940, 950}, {959, 963, 967, 971, 975, 979, 983}, {987, 993, 1000, 1006, 1012, 1017, 1022, 1029, 1035, 1044, 1052, 1061, 343}, {1070, 1075, 1000, 1080, 1012, 1017, 1085, 1090, 1094, 1099, 1104, 1109, 343}, 0, 0, 344, 346, {348,890},{357,878},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 1156, 1163, {1170, 1180, 1190, 1200, 1210, 1220, 1230}, {1240, 1244, 1248, 1252, 1256, 1260, 1264}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {1358, 1381, 1394, 1401, 1411, 447, 1416, 1424, 1429, {1434, 1442, 1452, 1460, 1468, 1477, 1484}, {1491, 1494, 1497, 1501, 1504, 1508, 1512}, {1515, 1521, 1527, 1535, 1541, 1549, 1557, 1567, 1573, 1581, 1589, 1598, 343}, {1607, 1609, 1612, 1616, 1619, 1621, 1624, 1628, 1633, 1636, 1638, 1641, 343}, 0, 1, 344, 346, {348,1394},{357,1381},{370,1411},{376,1401}},
-       {1645, 1666, 1678, 438, 370, 447, 1689, 465, 468, {1698, 1706, 1713, 1721, 1728, 1736, 1743}, {1751, 1756, 1760, 1764, 1768, 1772, 1776}, {1781, 1788, 1796, 1802, 1808, 1812, 1817, 1822, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 1873, 1877, 1808, 1881, 1885, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 1909, 346, {348,1911,1678},{357,1666},{370},{376,438}},
-       {1920, 1381, 1942, 438, 370, 447, 1416, 1953, 1959, {1966, 1974, 1981, 1990, 1999, 2010, 2018}, {2026, 2029, 2032, 2035, 2038, 2041, 2044}, {2047, 2054, 2062, 2068, 2074, 2078, 2083, 2088, 2095, 2105, 2113, 2122, 343}, {2131, 2135, 2139, 2143, 2074, 2147, 2151, 2155, 2159, 2163, 2167, 2171, 343}, 0, 1, 844, 346, {348,846,1942},{357,1381},{370},{376,438}},
-       {2175, 409, 37, 2199, 56, 447, 457, 2210, 2215, {2220, 2235, 2250, 2261, 2276, 2289, 2308}, {2323, 2330, 2337, 2344, 2351, 2358, 2365}, {2372, 2393, 2416, 2431, 2448, 2459, 2474, 2489, 2508, 2531, 2550, 2569, 343}, {2590, 2597, 2604, 2611, 2618, 2625, 2634, 2643, 2650, 2657, 2664, 2671, 343}, 0, 1, 344, 346, {348,2678,37},{357,409},{370,56},{376,2689,2199}},
-       {2701, 2732, 2752, 2199, 2759, 447, 2767, 465, 468, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {348,2752},{2732,2732,2925,2939,2959},{2759,2759,2974,1411,370},{2199,2199,2983,2995,438}},
-       {3003, 3037, 3059, 2983, 370, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059},{357,3037},{370},{376,2983}},
-       {3285, 3310, 3327, 2995, 370, 3336, 3349, 465, 468, {3361, 3371, 3381, 3389, 3401, 3409, 3419}, {3428, 3431, 3434, 3437, 3440, 3443, 3446}, {3449, 3458, 3467, 3477, 3486, 3495, 3504, 3514, 3521, 3529, 3537, 3547, 343}, {3556, 3562, 3568, 3575, 3581, 3587, 3593, 3600, 3604, 3609, 3614, 3621, 343}, 0, 1, 844, 346, {348,3327},{357,3310},{370},{376,2995}},
-       {3627, 3653, 890, 438, 370, 447, 74, 465, 468, {3670, 3679, 3685, 3691, 3700, 3706, 3715}, {3722, 3727, 3732, 3737, 3742, 3747, 3752}, {3757, 3765, 3774, 3779, 3785, 3789, 3794, 3802, 3808, 3818, 1052, 3826, 343}, {3836, 3842, 3774, 3849, 3785, 3789, 3854, 3802, 3860, 1099, 1104, 3866, 343}, 0, 0, 344, 346, {890,3872,3277},{357,878,3653},{370},{376,438}},
-       {3882, 878, 2678, 438, 370, 447, 74, 465, 468, {3903, 3921, 3935, 3953, 3971, 3989, 4005}, {4012, 4015, 4018, 4021, 4024, 4027, 4030}, {4033, 4044, 4057, 4064, 4075, 4082, 4091, 4100, 4113, 4126, 4141, 4154, 343}, {4165, 4172, 4057, 4179, 4075, 4186, 4193, 4200, 4207, 4214, 4221, 4228, 343}, 0, 0, 344, 346, {348,890,2678},{357,878},{370},{376,438}},
-       {4235, 4257, 4271, 2995, 1411, 4285, 4296, 4304, 4307, {4310, 4320, 4328, 4333, 4340, 4353, 4361}, {1619, 4369, 4371, 4373, 4377, 4380, 4382}, {4386, 4394, 4403, 4412, 4421, 4428, 4436, 4444, 4454, 4465, 1847, 1856, 343}, {4474, 4479, 4485, 4492, 4498, 4504, 4510, 4516, 4521, 4528, 1104, 4533, 343}, 0, 1, 4538, 346, {348,4541,4271},{357,4257},{370,1411},{376,1401,2995}},
-       {1920, 1381, 3327, 438, 370, 447, 1416, 465, 468, {4553, 4564, 4575, 4589, 4603, 4615, 4627}, {4639, 4643, 4648, 4653, 4658, 4662, 4667}, {4671, 4679, 3774, 4688, 4695, 4700, 4707, 4714, 1829, 4465, 4722, 4732, 343}, {1865, 1869, 1873, 1877, 4695, 4741, 4746, 4751, 1893, 1897, 4757, 4762, 343}, 0, 0, 844, 346, {348,3327},{357,1381},{370},{376,438}},
-       {4766, 409, 890, 376, 370, 447, 74, 4790, 4793, {4796, 4805, 4813, 4822, 4833, 4842, 4851}, {3152, 3156, 1873, 4858, 4862, 4866, 4870}, {4874, 4882, 3192, 4891, 4898, 4905, 4912, 3215, 4919, 4929, 1052, 4937, 343}, {4946, 1869, 1873, 1877, 4950, 4954, 4958, 3265, 4962, 4966, 1901, 3273, 343}, 0, 1, 344, 346, {348,890},{357,409},{370},{376}},
-       {4970, 5000, 5022, 2995, 1411, 5033, 5049, 5062, 5069, {5076, 5086, 5096, 5106, 5116, 5126, 5136}, {1240, 5146, 5150, 5154, 5158, 5162, 5166}, {5170, 5175, 5180, 5185, 5190, 5195, 5200, 5205, 5210, 5215, 5221, 5227, 343}, {5233, 5235, 5237, 5239, 5241, 5243, 5245, 5247, 5249, 5251, 5254, 5257, 343}, 0, 0, 344, 346, {5022,5022,348,5260,5267,5276,5295,5312},{5000,5000,5331,5355,5382},{1411,1411,370,5411,5419},{2995,438,5428,5439}},
-       {5451, 5504, 5531, 5540, 5566, 5584, 5601, 5615, 5622, {5629, 5639, 5649, 5659, 5669, 5679, 5689}, {5699, 5703, 5707, 5711, 5715, 5719, 5723}, {5727, 5732, 5737, 5742, 5747, 5752, 5757, 5762, 5767, 5772, 5778, 5784, 343}, {5727, 5732, 5737, 5742, 5747, 5752, 5757, 5762, 5767, 5772, 5778, 5784, 343}, 0, 0, 344, 346, {348,5531},{357,5504},{370,5566},{376,5540}},
-       {5790, 878, 5812, 1401, 1411, 447, 74, 465, 468, {5819, 5826, 5834, 5842, 5851, 5861, 5869}, {5878, 3431, 5881, 5884, 5887, 5890, 5893}, {5896, 5904, 5913, 1802, 5919, 1812, 1817, 5923, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 5932, 1877, 5919, 1881, 1885, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 344, 346, {348,5812},{357,878},{370,1411},{376,1401}},
-       {5936, 1381, 846, 5960, 5971, 447, 1416, 465, 468, {1698, 1706, 1713, 1721, 1728, 1736, 1743}, {5977, 3431, 3434, 5981, 3440, 5984, 5987}, {1781, 1788, 3774, 1802, 3785, 1812, 1817, 1822, 1829, 1839, 1847, 4732, 343}, {1865, 1869, 1873, 1877, 3785, 1881, 1885, 1889, 1893, 1897, 1901, 4762, 343}, 0, 1, 344, 346, {348,846},{357,1381},{370,5971},{376,5960}},
-       {5991, 878, 6012, 438, 370, 447, 74, 465, 468, {6023, 6033, 6047, 6054, 6061, 6070, 1484}, {6078, 6080, 6083, 6086, 6090, 6093, 2026}, {6096, 6105, 6110, 6117, 1808, 6127, 6136, 6143, 6153, 6163, 1589, 6176, 343}, {6186, 6190, 1873, 6194, 1808, 6198, 6202, 6206, 6210, 6214, 6219, 6223, 343}, 0, 1, 1909, 346, {348,5531,6012},{357,878},{370},{376,438}},
-       {6227, 3037, 1678, 376, 370, 3070, 3075, 465, 468, {3097, 6260, 6274, 6287, 6300, 6313, 3144}, {3152, 6325, 6329, 6333, 6337, 6341, 3173}, {6345, 6353, 6363, 1006, 6370, 6375, 6381, 3215, 6387, 6396, 6404, 6413, 343}, {1865, 6422, 1873, 3257, 3785, 1881, 1885, 3265, 4962, 6426, 1901, 6430, 343}, 0, 0, 344, 346, {348,1678},{357,3037},{370},{376}},
-       {5991, 878, 1942, 438, 370, 447, 74, 465, 468, {6434, 6444, 6449, 6456, 6465, 6469, 6476}, {6487, 6489, 6491, 2035, 6494, 1619, 6496}, {6498, 6507, 6517, 6524, 3785, 6532, 6538, 1822, 6544, 6555, 6565, 6575, 343}, {6585, 2135, 2913, 2143, 2074, 6589, 6593, 2155, 2159, 2917, 2167, 2921, 343}, 0, 1, 844, 346, {348,1942},{357,878},{370},{376,438}},
-       {6597, 6623, 1942, 2995, 1411, 6641, 74, 465, 468, {6657, 6680, 505, 6703, 6714, 6729, 6744}, {6759, 6764, 6769, 6774, 6779, 6784, 6789}, {6794, 6807, 6822, 6831, 6844, 6851, 6860, 6869, 6882, 6899, 6914, 6927, 343}, {6942, 6949, 6956, 6963, 678, 6970, 6977, 6984, 6991, 6998, 7005, 7012, 343}, 0, 1, 844, 346, {348,846,1942},{357,6623},{370,1411},{376,1401,2995}},
-       {7019, 7041, 3327, 2995, 370, 4285, 1148, 465, 468, {7055, 7064, 7076, 7083, 7091, 7101, 7107}, {7114, 7118, 7122, 7126, 7130, 7135, 7139}, {7143, 7153, 7162, 7170, 7178, 7186, 7193, 7200, 7208, 1589, 7214, 7222, 343}, {7231, 7235, 7239, 7244, 7248, 6202, 7252, 7256, 7260, 6219, 7264, 7268, 343}, 0, 1, 844, 346, {348,7272,3327},{357,7041},{370},{376,2995}},
-       {7283, 1381, 7304, 2995, 1411, 447, 1416, 465, 468, {7315, 7323, 7332, 7339, 7346, 7355, 7362}, {7369, 7372, 7375, 7378, 7381, 7385, 2026}, {4386, 4394, 7388, 4688, 7394, 4741, 4746, 1822, 1829, 4465, 1847, 1856, 343}, {1865, 1869, 1873, 1877, 7394, 4741, 4746, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 4538, 346, {348,3327,7304},{357,1381},{370,1411},{376,1401,2995}},
-       {7399, 409, 6012, 7423, 7434, 447, 457, 7441, 7444, {7447, 7454, 7463, 7472, 7484, 7492, 7501}, {7511, 7515, 2913, 7520, 7525, 7529, 7533}, {7537, 7543, 3774, 7550, 1808, 7556, 7564, 7571, 7577, 7585, 7591, 7599, 343}, {2131, 7607, 2913, 7611, 7615, 7619, 7623, 7627, 7533, 7631, 7635, 7640, 343}, 0, 1, 1909, 346, {348,5531,6012},{357,409},{370,7434},{376,7644,7423}},
-       {7656, 7684, 6012, 5960, 5971, 447, 74, 7701, 7704, {7707, 7715, 7723, 1721, 1728, 1736, 7730}, {7738, 7742, 3434, 5981, 3440, 5984, 7746}, {5896, 5904, 3774, 1802, 1808, 1812, 1817, 7750, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 1873, 1877, 1808, 1881, 1885, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 344, 346, {348,6012},{357,7684},{370,5971},{376,5960}},
-       {7758, 878, 37, 2995, 1411, 447, 74, 7779, 7810, {7841, 7872, 7900, 7928, 7947, 7981, 8006}, {8031, 8039, 8044, 8049, 8054, 8062, 8067}, {8072, 8091, 8122, 8141, 8160, 8182, 8207, 8229, 8251, 8273, 8292, 8320, 343}, {8342, 8351, 8360, 8372, 8384, 8393, 8405, 8414, 8423, 8432, 8441, 8450, 343}, 0, 0, 344, 346, {348,37},{357,878},{370,1411},{376,8459,2995}},
-       {8499, 8526, 1942, 438, 370, 447, 457, 465, 468, {8544, 8550, 8560, 8566, 8577, 8587, 8592}, {8602, 8606, 8610, 8614, 8619, 8623, 8627}, {8631, 8636, 8643, 8648, 8654, 8661, 8669, 8676, 8685, 8692, 8697, 8704, 343}, {8712, 8716, 2913, 8721, 2882, 8725, 8729, 8733, 8738, 8742, 8746, 8750, 343}, 0, 1, 844, 346, {348,1942},{357,8526},{370},{376,438}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 465, 468, {8754, 8761, 8767, 8774, 8779, 8785, 8791}, {8797, 8801, 8805, 8809, 8813, 8817, 8821}, {8825, 8833, 8842, 2068, 8848, 2078, 2083, 8852, 2095, 2105, 2113, 8860, 343}, {2131, 2135, 2913, 2143, 8848, 2147, 2151, 8869, 2159, 2163, 2167, 8873, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {8877, 878, 1942, 2995, 370, 8897, 74, 465, 468, {8913, 8926, 8945, 8962, 8975, 8988, 9004}, {9017, 6764, 6769, 6774, 6779, 6784, 6789}, {9022, 9033, 9046, 9061, 9074, 9087, 9100, 9111, 9124, 9139, 9152, 9171, 343}, {9184, 9191, 9198, 9205, 9214, 9223, 9232, 9239, 9248, 9255, 9264, 9273, 343}, 0, 1, 844, 346, {348,846,1942},{357,878},{370},{376,2995}},
-       {9282, 878, 1394, 5960, 5971, 447, 74, 465, 468, {9305, 9320, 9341, 9356, 9369, 9382, 9397}, {9410, 9415, 9420, 9425, 9430, 9435, 9440}, {9445, 9462, 9471, 9486, 678, 9503, 9518, 9531, 9546, 9563, 9584, 9601, 343}, {9616, 9191, 9623, 9630, 678, 9637, 9644, 9651, 9248, 9658, 9665, 9672, 343}, 0, 1, 344, 346, {348,1394},{357,878},{370,5971},{376,5960}},
-       {9679, 9701, 3327, 2995, 1411, 447, 1689, 465, 468, {9715, 9723, 9734, 9740, 9746, 9755, 1484}, {7114, 7118, 1768, 9761, 7130, 7135, 9765}, {1781, 1788, 7388, 1802, 1808, 9769, 9775, 9781, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 1873, 1877, 1808, 1881, 1885, 9788, 1893, 1897, 1901, 1905, 343}, 0, 1, 844, 346, {348,9792,3327},{357,9701},{370,1411},{376,1401,2995}},
-       {8877, 878, 9799, 2995, 1411, 447, 9809, 465, 468, {9817, 9828, 9839, 9850, 9861, 9872, 9878}, {4380, 9887, 9889, 4371, 6078, 9891, 6489}, {9893, 9901, 9910, 9917, 3785, 9924, 9930, 1822, 1829, 9936, 1847, 9945, 343}, {9955, 9960, 9910, 1877, 3785, 9924, 9930, 1889, 9966, 1897, 1901, 9971, 343}, 0, 1, 844, 346, {348,846,9799},{357,878},{370,1411},{376,1401,2995}},
-       {9976, 10005, 4541, 2995, 370, 10026, 1416, 465, 468, {10044, 10055, 10065, 10074, 10085, 10097, 10108}, {10118, 4380, 10121, 9889, 10123, 10125, 6496}, {10128, 10138, 1796, 10149, 10158, 10164, 10172, 10180, 10188, 10199, 10208, 10218, 343}, {2131, 2135, 2913, 2143, 2074, 10228, 10233, 2155, 2159, 2163, 2167, 2921, 343}, 0, 1, 844, 346, {348,10238,4541},{357,10005},{370},{376,2995}},
-       {10245, 10278, 7272, 376, 370, 10300, 10315, 465, 468, {10327, 10339, 10351, 10363, 10377, 10392, 10405}, {10419, 10422, 10425, 10428, 10431, 6080, 7381}, {10434, 10441, 10449, 10454, 10465, 10475, 10485, 10492, 10504, 10513, 10520, 10531, 343}, {10541, 10545, 10549, 10553, 10557, 10561, 10565, 10569, 10573, 10577, 10581, 10585, 343}, 0, 1, 344, 346, {348,7272},{357,10278},{370},{376}},
-       {10589, 878, 10613, 2983, 370, 447, 74, 10622, 10629, {10636, 10652, 10665, 10681, 10698, 10716, 10725}, {10734, 10738, 10742, 10746, 10750, 10754, 10758}, {10762, 10775, 229, 10786, 10797, 10802, 10811, 10822, 10829, 10844, 10855, 10868, 343}, {10881, 10888, 10895, 10902, 10909, 10916, 10923, 10822, 10930, 10937, 10944, 10951, 343}, 0, 0, 344, 346, {348,10958,10613},{357,878},{370},{376,10968,2983}},
-       {10981, 409, 2678, 2199, 370, 447, 457, 11005, 11008, {11011, 11024, 11034, 11043, 11053, 11064, 11075}, {11087, 11090, 11095, 11100, 11105, 11110, 11115}, {11120, 11133, 11144, 11154, 11165, 11177, 11189, 11202, 11214, 11227, 11242, 11263, 343}, {11282, 11288, 11294, 11300, 11306, 11312, 11318, 11324, 11330, 11336, 11343, 11350, 343}, 0, 1, 344, 346, {348,2678},{357,409},{370},{376,2199}},
-       {11357, 2925, 1942, 2995, 370, 447, 2767, 11379, 11387, {11395, 11408, 11429, 11448, 11469, 11488, 11501}, {11512, 11519, 11526, 11533, 11540, 11547, 11554}, {11561, 11578, 11595, 11604, 11615, 11626, 11639, 11652, 11667, 11686, 11705, 11722, 343}, {11741, 11748, 11755, 11762, 11769, 11776, 11783, 11790, 11797, 11804, 11811, 11818, 343}, 0, 1, 844, 346, {348,11825,1942},{357,2925},{370},{376,2995}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 465, 468, {11834, 11842, 11853, 11863, 11874, 11883, 11892}, {11902, 11905, 11908, 11911, 11914, 11917, 11920}, {11923, 11933, 11941, 11949, 11957, 11965, 11972, 11980, 11988, 11995, 12001, 12008, 343}, {12016, 12020, 1873, 12024, 3785, 12028, 12032, 12036, 12040, 12044, 12048, 12052, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {387, 409, 1942, 438, 370, 447, 457, 465, 468, {12056, 484, 505, 6703, 12069, 12086, 12097}, {574, 582, 590, 12110, 12118, 612, 12126}, {12134, 641, 658, 667, 12149, 12156, 12165, 699, 712, 731, 748, 763, 343}, {12174, 786, 12182, 794, 12190, 12198, 12206, 802, 12214, 818, 826, 12224, 343}, 0, 1, 844, 346, {348,12236,1942},{357,409},{370},{376,438}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 12244, 12247, {12250, 12257, 12265, 12273, 12282, 12292, 12299}, {2026, 6491, 2032, 12308, 2038, 12311, 2044}, {12314, 12323, 12333, 2068, 8848, 12339, 12345, 12351, 2095, 2105, 2113, 8860, 343}, {2131, 2135, 2913, 2143, 8848, 2147, 2151, 2155, 2159, 2163, 2167, 8873, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {12360, 12380, 348, 376, 370, 12389, 1148, 12396, 12412, {5233, 5235, 5237, 5239, 5241, 5243, 5245}, {5233, 5235, 5237, 5239, 5241, 5243, 5245}, {5233, 5235, 5237, 5239, 5241, 5243, 5245, 5247, 5249, 5251, 5254, 5257, 343}, {5233, 5235, 5237, 5239, 5241, 5243, 5245, 5247, 5249, 5251, 5254, 5257, 343}, 0, 0, 344, 346, {348},{357,12380},{370},{376}},
-       {12434, 1666, 1911, 376, 370, 447, 457, 465, 468, {4553, 12457, 12468, 12478, 12488, 12498, 12512}, {4639, 4643, 12524, 12529, 12533, 12538, 12543}, {1781, 1788, 3774, 4688, 3785, 1812, 1817, 1822, 1829, 1839, 1847, 4732, 343}, {1865, 1869, 1873, 1877, 3785, 1881, 1885, 1889, 1893, 1897, 1901, 4762, 343}, 0, 0, 344, 346, {348,1911},{357,1666},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 12547, 12575, {12597, 12616, 12635, 12657, 12676, 12698, 12723}, {12742, 12752, 12762, 12775, 12785, 12798, 12814}, {12824, 12840, 12856, 12872, 12891, 12898, 12908, 12924, 12940, 12962, 12984, 13003, 343}, {12824, 12840, 12856, 12872, 12891, 12898, 12908, 12924, 12940, 12962, 12984, 13003, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 465, 468, {13025, 13034, 13043, 13051, 13060, 13069, 13076}, {13085, 13089, 13093, 13097, 13101, 13105, 13109}, {8825, 8833, 13113, 13119, 8848, 2078, 13126, 13132, 13139, 13148, 13155, 13163, 343}, {2131, 2135, 2913, 2143, 8848, 2147, 2151, 13171, 2159, 2163, 2167, 8873, 343}, 0, 6, 344, 346, {348},{357},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 13175, 13217, {13259, 13278, 13297, 13319, 13338, 13360, 13385}, {13404, 13414, 13424, 13437, 13447, 13460, 13476}, {13486, 13514, 13542, 13558, 13577, 13584, 13594, 13610, 13626, 13654, 13676, 13698, 343}, {13723, 13742, 13542, 13558, 13577, 13584, 13594, 13610, 13761, 13777, 13793, 13803, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 13816, 13829, {13842, 13861, 13883, 13908, 13924, 13946, 13965}, {13975, 13982, 13989, 13996, 14003, 14010, 14017}, {14021, 14037, 14062, 14081, 14100, 14107, 14120, 14133, 14152, 14183, 14208, 14230, 343}, {14255, 14263, 14277, 14291, 14100, 14107, 14120, 14302, 14310, 14324, 14335, 14343, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 14354, 14382, {14404, 14426, 14448, 14473, 14495, 14520, 14548}, {14570, 14580, 14590, 14603, 14613, 14626, 14642}, {14652, 14668, 14693, 14712, 14734, 14741, 14754, 14767, 14786, 14817, 14842, 14861, 343}, {14652, 14668, 14693, 14712, 14734, 14741, 14754, 14767, 14786, 14817, 14842, 14861, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 14886, 14914, {14936, 14955, 14974, 14996, 15015, 15037, 15062}, {15081, 15086, 15094, 15102, 15110, 15118, 15126}, {15137, 15153, 15178, 15197, 15219, 15226, 15239, 15252, 15271, 15299, 15324, 15346, 343}, {15137, 15153, 15178, 15197, 15219, 15226, 15239, 15252, 15271, 15299, 15324, 15346, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 15371, 15383, {12597, 12616, 15395, 12657, 12676, 12698, 12723}, {12742, 12752, 15417, 12775, 12785, 12798, 12814}, {15430, 15455, 12856, 15480, 15499, 12898, 15506, 15519, 15535, 15563, 15585, 15613, 343}, {15430, 15455, 12856, 15480, 15499, 12898, 15506, 15519, 15535, 15563, 15585, 15613, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 465, 468, {15635, 15643, 15648, 15655, 15665, 15671, 15678}, {15686, 15690, 2913, 15694, 15699, 15703, 15707}, {15712, 15720, 15729, 15735, 15741, 15746, 15752, 15758, 15765, 15774, 15782, 15791, 343}, {15800, 2135, 2913, 15804, 2074, 15808, 15813, 13171, 15817, 15821, 2167, 2921, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 15371, 15383, {15825, 12616, 15853, 12657, 12676, 12698, 12723}, {12742, 12752, 15417, 12775, 12785, 12798, 12814}, {15430, 15872, 12856, 15480, 15499, 12898, 15506, 15519, 15535, 15563, 15585, 15613, 343}, {15430, 15455, 12856, 15480, 15499, 12898, 15506, 15519, 15535, 15563, 15585, 15613, 343}, 0, 0, 344, 346, {348},{357},{370},{376}},
-       {1, 24, 37, 46, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {87, 98, 113, 130, 147, 160, 173}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37},{357,24},{370,56},{376,46}},
-       {387, 409, 422, 438, 370, 447, 457, 465, 468, {471, 484, 505, 520, 531, 550, 561}, {574, 582, 590, 596, 602, 612, 620}, {628, 641, 658, 667, 678, 685, 692, 699, 712, 731, 748, 763, 343}, {780, 786, 658, 794, 678, 685, 692, 802, 810, 818, 826, 836, 343}, 0, 1, 844, 346, {348,846,422},{357,409},{370},{376,438}},
-       {5991, 878, 2678, 438, 370, 447, 457, 465, 468, {899, 908, 916, 924, 933, 940, 950}, {959, 963, 967, 971, 975, 979, 983}, {987, 993, 1000, 1006, 1012, 1017, 1022, 1029, 1035, 1044, 1052, 1061, 343}, {1070, 1075, 1000, 1080, 1012, 1017, 1085, 1090, 1094, 1099, 1104, 1109, 343}, 0, 1, 344, 346, {348,890,2678},{357,878},{370},{376,438}},
-       {15903, 5000, 5267, 15948, 15971, 5033, 5049, 1156, 1163, {1170, 1180, 1190, 1200, 1210, 1220, 1230}, {1240, 1244, 1248, 1252, 1256, 1260, 1264}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, 0, 0, 344, 346, {348,5267},{357,5000},{370,15971},{376,15948}},
-       {7283, 1381, 3327, 2995, 1411, 447, 1416, 1424, 1429, {1434, 1442, 1452, 1460, 1468, 1477, 1484}, {1491, 1494, 1497, 1501, 1504, 1508, 1512}, {1515, 1521, 1527, 1535, 1541, 1549, 1557, 1567, 1573, 1581, 1589, 1598, 343}, {1607, 1609, 1612, 1616, 1619, 1621, 1624, 1628, 1633, 1636, 1638, 1641, 343}, 0, 1, 844, 346, {348,1394,3327},{357,1381},{370,1411},{376,1401,2995}},
-       {1645, 1666, 1678, 438, 370, 447, 1689, 465, 468, {1698, 1706, 1713, 1721, 1728, 1736, 1743}, {1751, 1756, 1760, 1764, 1768, 1772, 1776}, {1781, 1788, 1796, 1802, 1808, 1812, 1817, 1822, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 1873, 1877, 1808, 1881, 1885, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 1909, 346, {348,1911,1678},{357,1666},{370},{376,438}},
-       {1920, 1381, 1942, 438, 370, 447, 1416, 1953, 1959, {1966, 1974, 1981, 1990, 1999, 2010, 2018}, {2026, 2029, 2032, 2035, 2038, 2041, 2044}, {2047, 2054, 2062, 2068, 2074, 2078, 2083, 2088, 2095, 2105, 2113, 2122, 343}, {2131, 2135, 2139, 2143, 2074, 2147, 2151, 2155, 2159, 2163, 2167, 2171, 343}, 0, 1, 844, 346, {348,846,1942},{357,1381},{370},{376,438}},
-       {2175, 409, 37, 2199, 56, 447, 457, 2210, 2215, {2220, 2235, 2250, 2261, 2276, 2289, 2308}, {2323, 2330, 2337, 2344, 2351, 2358, 2365}, {2372, 2393, 2416, 2431, 2448, 2459, 2474, 2489, 2508, 2531, 2550, 2569, 343}, {2590, 2597, 2604, 2611, 2618, 2625, 2634, 2643, 2650, 2657, 2664, 2671, 343}, 0, 1, 344, 346, {348,2678,37},{357,409},{370,56},{376,2689,2199}},
-       {2701, 2732, 10613, 2199, 2759, 63, 2767, 465, 468, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {10613,10613,2752,2752,11825,3059,348,6012,15978},{2732,2732,2925,2939,2959},{2759,2759,2974,1411,370},{2199,2199,2983,2995,438}},
-       {3285, 3310, 3327, 2995, 370, 3336, 3349, 465, 468, {3361, 3371, 3381, 3389, 3401, 3409, 3419}, {3428, 3431, 3434, 3437, 3440, 3443, 3446}, {3449, 3458, 3467, 3477, 3486, 3495, 3504, 3514, 3521, 3529, 3537, 3547, 343}, {3556, 3562, 3568, 3575, 3581, 3587, 3593, 3600, 3604, 3609, 3614, 3621, 343}, 0, 1, 844, 346, {348,3327},{357,3310},{370},{376,2995}},
-       {3627, 3653, 2678, 438, 370, 447, 74, 465, 468, {3670, 3679, 3685, 3691, 3700, 3706, 3715}, {3722, 3727, 3732, 3737, 3742, 3747, 3752}, {3757, 3765, 3774, 3779, 3785, 3789, 3794, 3802, 3808, 3818, 1052, 3826, 343}, {3836, 3842, 3774, 3849, 3785, 3789, 3854, 3802, 3860, 1099, 1104, 3866, 343}, 0, 1, 344, 346, {890,3872,3277,2678},{357,878,3653},{370},{376,438}},
-       {3882, 878, 2678, 438, 370, 447, 74, 465, 468, {3903, 3921, 3935, 3953, 3971, 3989, 4005}, {4012, 4015, 4018, 4021, 4024, 4027, 4030}, {4033, 4044, 4057, 4064, 4075, 4082, 4091, 4100, 4113, 4126, 4141, 4154, 343}, {4165, 4172, 4057, 4179, 4075, 4186, 4193, 4200, 4207, 4214, 4221, 4228, 343}, 0, 0, 344, 346, {348,890,2678},{357,878},{370},{376,438}},
-       {4235, 4257, 4271, 2995, 1411, 4285, 4296, 4304, 4307, {4310, 4320, 4328, 4333, 4340, 4353, 4361}, {1619, 4369, 4371, 4373, 4377, 4380, 4382}, {4386, 4394, 4403, 4412, 4421, 4428, 4436, 4444, 4454, 4465, 1847, 1856, 343}, {4474, 4479, 4485, 4492, 4498, 4504, 4510, 4516, 4521, 4528, 1104, 4533, 343}, 0, 1, 4538, 346, {348,4541,4271},{357,4257},{370,1411},{376,1401,2995}},
-       {1920, 1381, 3327, 438, 370, 447, 1416, 465, 468, {4553, 4564, 4575, 4589, 4603, 4615, 4627}, {4639, 4643, 4648, 4653, 4658, 4662, 4667}, {4671, 4679, 3774, 4688, 4695, 4700, 4707, 4714, 1829, 4465, 4722, 4732, 343}, {1865, 1869, 1873, 1877, 4695, 4741, 4746, 4751, 1893, 1897, 4757, 4762, 343}, 0, 0, 844, 346, {348,3327},{357,1381},{370},{376,438}},
-       {15988, 409, 2678, 16009, 370, 447, 74, 4790, 4793, {4796, 4805, 4813, 4822, 4833, 4842, 4851}, {3152, 3156, 1873, 4858, 4862, 4866, 4870}, {4874, 4882, 3192, 4891, 4898, 4905, 4912, 3215, 4919, 4929, 1052, 4937, 343}, {4946, 1869, 1873, 1877, 4950, 4954, 4958, 3265, 4962, 4966, 1901, 3273, 343}, 0, 1, 344, 346, {348,890,2678},{357,409},{370},{376,1401,16009}},
-       {4970, 5000, 5022, 2995, 1411, 5033, 5049, 5062, 5069, {5076, 5086, 5096, 5106, 5116, 5126, 5136}, {1240, 5146, 5150, 5154, 5158, 5162, 5166}, {5170, 5175, 5180, 5185, 5190, 5195, 5200, 5205, 5210, 5215, 5221, 5227, 343}, {5233, 5235, 5237, 5239, 5241, 5243, 5245, 5247, 5249, 5251, 5254, 5257, 343}, 0, 0, 344, 346, {5022,5022,348,5260,5267,5276,5295,5312},{5000,5000,5331,5355,5382},{1411,1411,370,5411,5419},{2995,438,5428,5439}},
-       {16017, 16067, 5022, 16091, 5411, 5584, 5601, 5615, 5622, {5629, 5639, 5649, 5659, 5669, 5679, 5689}, {5699, 5703, 5707, 5711, 5715, 5719, 5723}, {5727, 5732, 5737, 5742, 5747, 5752, 5757, 5762, 5767, 5772, 5778, 5784, 343}, {5727, 5732, 5737, 5742, 5747, 5752, 5757, 5762, 5767, 5772, 5778, 5784, 343}, 0, 0, 344, 346, {5022,5022,348,5260,5267,16117,16130},{16067,16067,16141,16167,16189},{5411,1411,370,16213,16227,16242,5411,5419,16258,16275,16293},{16091,16091,16312,16334,2995,438,16358,16383,5428,5439}},
-       {8877, 878, 16410, 2995, 1411, 447, 74, 465, 468, {5819, 5826, 5834, 5842, 5851, 5861, 5869}, {5878, 3431, 5881, 5884, 5887, 5890, 5893}, {5896, 5904, 5913, 1802, 5919, 1812, 1817, 5923, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 5932, 1877, 5919, 1881, 1885, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 1909, 346, {348,5812,16410},{357,878},{370,1411},{376,1401,2995}},
-       {5936, 1381, 846, 5960, 5971, 447, 1416, 465, 468, {1698, 1706, 1713, 1721, 1728, 1736, 1743}, {5977, 3431, 3434, 5981, 3440, 5984, 5987}, {1781, 1788, 3774, 1802, 3785, 1812, 1817, 1822, 1829, 1839, 1847, 4732, 343}, {1865, 1869, 1873, 1877, 3785, 1881, 1885, 1889, 1893, 1897, 1901, 4762, 343}, 0, 1, 344, 346, {348,846},{357,1381},{370,5971},{376,5960}},
-       {5991, 878, 6012, 438, 370, 447, 74, 465, 468, {6023, 6033, 6047, 6054, 6061, 6070, 1484}, {6078, 6080, 6083, 6086, 6090, 6093, 2026}, {6096, 6105, 6110, 6117, 1808, 6127, 6136, 6143, 6153, 6163, 1589, 6176, 343}, {6186, 6190, 1873, 6194, 1808, 6198, 6202, 6206, 6210, 6214, 6219, 6223, 343}, 0, 1, 1909, 346, {348,5531,6012},{357,878},{370},{376,438}},
-       {16419, 3037, 37, 438, 370, 3070, 3075, 465, 468, {3097, 6260, 6274, 6287, 6300, 6313, 3144}, {3152, 6325, 6329, 6333, 6337, 6341, 3173}, {6345, 6353, 6363, 1006, 6370, 6375, 6381, 3215, 6387, 6396, 6404, 6413, 343}, {1865, 6422, 1873, 3257, 3785, 1881, 1885, 3265, 4962, 6426, 1901, 6430, 343}, 0, 0, 344, 346, {348,1678,890,37},{357,3037},{370},{376,16450,438}},
-       {5991, 878, 1942, 438, 370, 447, 74, 465, 468, {6434, 6444, 6449, 6456, 6465, 6469, 6476}, {6487, 6489, 6491, 2035, 6494, 1619, 6496}, {6498, 6507, 6517, 6524, 3785, 6532, 6538, 1822, 6544, 6555, 6565, 6575, 343}, {6585, 2135, 2913, 2143, 2074, 6589, 6593, 2155, 2159, 2917, 2167, 2921, 343}, 0, 1, 844, 346, {348,1942},{357,878},{370},{376,438}},
-       {6597, 6623, 1942, 2995, 1411, 6641, 74, 465, 468, {6657, 6680, 505, 6703, 6714, 6729, 6744}, {6759, 6764, 6769, 6774, 6779, 6784, 6789}, {6794, 6807, 6822, 6831, 6844, 6851, 6860, 6869, 6882, 6899, 6914, 6927, 343}, {6942, 6949, 6956, 6963, 678, 6970, 6977, 6984, 6991, 6998, 7005, 7012, 343}, 0, 1, 844, 346, {348,846,1942},{357,6623},{370,1411},{376,1401,2995}},
-       {7019, 7041, 3327, 2995, 370, 4285, 1148, 465, 468, {7055, 7064, 7076, 7083, 7091, 7101, 7107}, {7114, 7118, 7122, 7126, 7130, 7135, 7139}, {7143, 7153, 7162, 7170, 7178, 7186, 7193, 7200, 7208, 1589, 7214, 7222, 343}, {7231, 7235, 7239, 7244, 7248, 6202, 7252, 7256, 7260, 6219, 7264, 7268, 343}, 0, 1, 844, 346, {348,7272,3327},{357,7041},{370},{376,2995}},
-       {7283, 1381, 7304, 2995, 1411, 447, 1416, 465, 468, {7315, 7323, 7332, 7339, 7346, 7355, 7362}, {7369, 7372, 7375, 7378, 7381, 7385, 2026}, {4386, 4394, 7388, 4688, 7394, 4741, 4746, 1822, 1829, 4465, 1847, 1856, 343}, {1865, 1869, 1873, 1877, 7394, 4741, 4746, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 4538, 346, {348,3327,7304},{357,1381},{370,1411},{376,1401,2995}},
-       {7399, 409, 6012, 7423, 7434, 447, 457, 7441, 7444, {7447, 7454, 7463, 7472, 7484, 7492, 7501}, {7511, 7515, 2913, 7520, 7525, 7529, 7533}, {7537, 7543, 3774, 7550, 1808, 7556, 7564, 7571, 7577, 7585, 7591, 7599, 343}, {2131, 7607, 2913, 7611, 7615, 7619, 7623, 7627, 7533, 7631, 7635, 7640, 343}, 0, 1, 1909, 346, {348,5531,6012},{357,409},{370,7434},{376,7644,7423}},
-       {16467, 7684, 6012, 438, 370, 447, 74, 7701, 7704, {7707, 7715, 7723, 1721, 1728, 1736, 7730}, {7738, 7742, 3434, 5981, 3440, 5984, 7746}, {5896, 5904, 3774, 1802, 1808, 1812, 1817, 7750, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 1873, 1877, 1808, 1881, 1885, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 1909, 346, {348,6012},{357,7684},{370,5971},{376,5960,438}},
-       {7758, 878, 37, 2995, 1411, 447, 74, 7779, 7810, {7841, 7872, 7900, 7928, 7947, 7981, 8006}, {8031, 8039, 8044, 8049, 8054, 8062, 8067}, {8072, 8091, 8122, 8141, 8160, 8182, 8207, 8229, 8251, 8273, 8292, 8320, 343}, {8342, 8351, 8360, 8372, 8384, 8393, 8405, 8414, 8423, 8432, 8441, 8450, 343}, 0, 0, 344, 346, {348,37},{357,878},{370,1411},{376,8459,2995}},
-       {8499, 8526, 1942, 438, 370, 447, 457, 465, 468, {8544, 8550, 8560, 8566, 8577, 8587, 8592}, {8602, 8606, 8610, 8614, 8619, 8623, 8627}, {8631, 8636, 8643, 8648, 8654, 8661, 8669, 8676, 8685, 8692, 8697, 8704, 343}, {8712, 8716, 2913, 8721, 2882, 8725, 8729, 8733, 8738, 8742, 8746, 8750, 343}, 0, 1, 844, 346, {348,1942},{357,8526},{370},{376,438}},
-       {16493, 409, 2678, 2995, 1411, 447, 457, 465, 468, {8754, 8761, 8767, 8774, 8779, 8785, 8791}, {8797, 8801, 8805, 8809, 8813, 8817, 8821}, {8825, 8833, 8842, 2068, 8848, 2078, 2083, 8852, 2095, 2105, 2113, 8860, 343}, {2131, 2135, 2913, 2143, 8848, 2147, 2151, 8869, 2159, 2163, 2167, 8873, 343}, 0, 0, 344, 346, {348,890,2678},{357,409},{370,1411},{376,2995}},
-       {8877, 878, 1942, 2995, 370, 8897, 74, 465, 468, {8913, 8926, 8945, 8962, 8975, 8988, 9004}, {9017, 6764, 6769, 6774, 6779, 6784, 6789}, {9022, 9033, 9046, 9061, 9074, 9087, 9100, 9111, 9124, 9139, 9152, 9171, 343}, {9184, 9191, 9198, 9205, 9214, 9223, 9232, 9239, 9248, 9255, 9264, 9273, 343}, 0, 1, 844, 346, {348,846,1942},{357,878},{370},{376,2995}},
-       {8877, 878, 1942, 2995, 5971, 447, 74, 465, 468, {9305, 9320, 9341, 9356, 9369, 9382, 9397}, {9410, 9415, 9420, 9425, 9430, 9435, 9440}, {9445, 9462, 9471, 9486, 678, 9503, 9518, 9531, 9546, 9563, 9584, 9601, 343}, {9616, 9191, 9623, 9630, 678, 9637, 9644, 9651, 9248, 9658, 9665, 9672, 343}, 0, 1, 844, 346, {348,1394,1942},{357,878},{370,5971},{376,5960,2995}},
-       {9679, 9701, 3327, 2995, 1411, 447, 1689, 465, 468, {9715, 9723, 9734, 9740, 9746, 9755, 1484}, {7114, 7118, 1768, 9761, 7130, 7135, 9765}, {1781, 1788, 7388, 1802, 1808, 9769, 9775, 9781, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 1873, 1877, 1808, 1881, 1885, 9788, 1893, 1897, 1901, 1905, 343}, 0, 1, 844, 346, {348,9792,3327},{357,9701},{370,1411},{376,1401,2995}},
-       {8877, 878, 9799, 2995, 1411, 447, 9809, 465, 468, {9817, 9828, 9839, 9850, 9861, 9872, 9878}, {4380, 9887, 9889, 4371, 6078, 9891, 6489}, {9893, 9901, 9910, 9917, 3785, 9924, 9930, 1822, 1829, 9936, 1847, 9945, 343}, {9955, 9960, 9910, 1877, 3785, 9924, 9930, 1889, 9966, 1897, 1901, 9971, 343}, 0, 1, 844, 346, {348,846,9799},{357,878},{370,1411},{376,1401,2995}},
-       {9976, 10005, 4541, 2995, 370, 10026, 1416, 465, 468, {10044, 10055, 10065, 10074, 10085, 10097, 10108}, {10118, 4380, 10121, 9889, 10123, 10125, 6496}, {10128, 10138, 1796, 10149, 10158, 10164, 10172, 10180, 10188, 10199, 10208, 10218, 343}, {2131, 2135, 2913, 2143, 2074, 10228, 10233, 2155, 2159, 2163, 2167, 2921, 343}, 0, 1, 844, 346, {348,10238,4541},{357,10005},{370},{376,2995}},
-       {16514, 10278, 7272, 438, 370, 10300, 10315, 465, 468, {10327, 10339, 10351, 10363, 10377, 10392, 10405}, {10419, 10422, 10425, 10428, 10431, 6080, 7381}, {10434, 10441, 10449, 10454, 10465, 10475, 10485, 10492, 10504, 10513, 10520, 10531, 343}, {10541, 10545, 10549, 10553, 10557, 10561, 10565, 10569, 10573, 10577, 10581, 10585, 343}, 0, 1, 844, 346, {348,7272},{357,10278},{370},{376,438}},
-       {10589, 878, 10613, 2983, 370, 447, 74, 10622, 10629, {10636, 10652, 10665, 10681, 10698, 10716, 10725}, {10734, 10738, 10742, 10746, 10750, 10754, 10758}, {10762, 10775, 229, 10786, 10797, 10802, 10811, 10822, 10829, 10844, 10855, 10868, 343}, {10881, 10888, 10895, 10902, 10909, 10916, 10923, 10822, 10930, 10937, 10944, 10951, 343}, 0, 6, 344, 346, {348,10958,10613},{357,878},{370},{376,10968,2983}},
-       {10981, 409, 2678, 2199, 370, 447, 457, 11005, 11008, {11011, 11024, 11034, 11043, 11053, 11064, 11075}, {11087, 11090, 11095, 11100, 11105, 11110, 11115}, {11120, 11133, 11144, 11154, 11165, 11177, 11189, 11202, 11214, 11227, 11242, 11263, 343}, {11282, 11288, 11294, 11300, 11306, 11312, 11318, 11324, 11330, 11336, 11343, 11350, 343}, 0, 1, 344, 346, {348,2678},{357,409},{370},{376,2199}},
-       {11357, 2925, 1942, 2995, 370, 447, 2767, 11379, 16545, {11395, 11408, 11429, 11448, 11469, 11488, 11501}, {11512, 11519, 11526, 11533, 11540, 11547, 11554}, {16553, 16568, 11595, 11604, 11615, 16583, 16596, 11652, 11667, 11686, 11705, 11722, 343}, {16609, 16616, 11755, 11762, 11769, 16623, 16630, 11790, 11797, 11804, 11811, 11818, 343}, 0, 1, 844, 346, {348,11825,1942},{357,2925},{370},{376,2995}},
-       {16637, 16676, 5022, 438, 370, 16706, 1148, 465, 468, {11834, 11842, 11853, 11863, 11874, 11883, 11892}, {11902, 11905, 11908, 11911, 11914, 11917, 11920}, {11923, 11933, 11941, 11949, 11957, 11965, 11972, 11980, 11988, 11995, 12001, 12008, 343}, {12016, 12020, 1873, 12024, 3785, 12028, 12032, 12036, 12040, 12044, 12048, 12052, 343}, 0, 1, 344, 346, {348,16721,5022},{357,16676},{370},{376,438}},
-       {387, 409, 1942, 438, 370, 447, 457, 465, 468, {12056, 484, 505, 6703, 12069, 12086, 12097}, {574, 582, 590, 12110, 12118, 612, 12126}, {12134, 641, 658, 667, 12149, 12156, 12165, 699, 712, 731, 748, 763, 343}, {12174, 786, 12182, 794, 12190, 12198, 12206, 802, 12214, 818, 826, 12224, 343}, 0, 1, 844, 346, {348,12236,1942},{357,409},{370},{376,438}},
-       {16734, 409, 5022, 2983, 56, 447, 457, 343, 343, {12250, 12257, 12265, 12273, 12282, 12292, 12299}, {2026, 6491, 2032, 12308, 2038, 12311, 2044}, {12314, 12323, 12333, 2068, 8848, 12339, 12345, 12351, 2095, 2105, 2113, 8860, 343}, {2131, 2135, 2913, 2143, 8848, 2147, 2151, 2155, 2159, 2163, 2167, 8873, 343}, 0, 0, 344, 346, {348,5022},{357,409},{370,56},{376,46,2983}},
-       {16759, 16799, 1942, 2995, 1411, 12389, 1148, 12396, 12412, {5233, 5235, 5237, 5239, 5241, 5243, 5245}, {5233, 5235, 5237, 5239, 5241, 5243, 5245}, {5233, 5235, 5237, 5239, 5241, 5243, 5245, 5247, 5249, 5251, 5254, 5257, 343}, {5233, 5235, 5237, 5239, 5241, 5243, 5245, 5247, 5249, 5251, 5254, 5257, 343}, 0, 0, 844, 346, {348,1942},{357,12380,16799},{370,1411},{376,2995}},
-       {16831, 1666, 1678, 16852, 370, 447, 457, 465, 468, {4553, 12457, 12468, 12478, 12488, 12498, 12512}, {4639, 4643, 12524, 12529, 12533, 12538, 12543}, {1781, 1788, 3774, 4688, 3785, 1812, 1817, 1822, 1829, 1839, 1847, 4732, 343}, {1865, 1869, 1873, 1877, 3785, 1881, 1885, 1889, 1893, 1897, 1901, 4762, 343}, 0, 0, 1909, 346, {348,1911,1678},{357,1666},{370},{376,16852}},
-       {5991, 878, 1678, 438, 56, 447, 74, 12547, 12575, {12597, 12616, 12635, 12657, 12676, 12698, 12723}, {12742, 12752, 12762, 12775, 12785, 12798, 12814}, {12824, 12840, 12856, 12872, 12891, 12898, 12908, 12924, 12940, 12962, 12984, 13003, 343}, {12824, 12840, 12856, 12872, 12891, 12898, 12908, 12924, 12940, 12962, 12984, 13003, 343}, 0, 0, 1909, 346, {348,5812,1678},{357,878},{370,56},{376,2689,438}},
-       {16861, 357, 10613, 16885, 370, 1138, 1148, 465, 468, {13025, 13034, 13043, 13051, 13060, 13069, 13076}, {13085, 13089, 13093, 13097, 13101, 13105, 13109}, {8825, 8833, 13113, 13119, 8848, 2078, 13126, 13132, 13139, 13148, 13155, 13163, 343}, {2131, 2135, 2913, 2143, 8848, 2147, 2151, 13171, 2159, 2163, 2167, 8873, 343}, 0, 6, 344, 346, {348,10613},{357},{370},{376,16885}},
-       {16896, 878, 16921, 16929, 16942, 447, 74, 13175, 13217, {13259, 13278, 13297, 13319, 13338, 13360, 13385}, {13404, 13414, 13424, 13437, 13447, 13460, 13476}, {13486, 13514, 13542, 13558, 13577, 13584, 13594, 13610, 13626, 13654, 13676, 13698, 343}, {13723, 13742, 13542, 13558, 13577, 13584, 13594, 13610, 13761, 13777, 13793, 13803, 343}, 0, 0, 344, 346, {348,16921},{357,878},{370,16942},{376,16929}},
-       {16950, 878, 5812, 2689, 56, 447, 74, 13816, 13829, {13842, 13861, 13883, 13908, 13924, 13946, 13965}, {13975, 13982, 13989, 13996, 14003, 14010, 14017}, {14021, 14037, 14062, 14081, 14100, 14107, 14120, 14133, 14152, 14183, 14208, 14230, 343}, {14255, 14263, 14277, 14291, 14100, 14107, 14120, 14302, 14310, 14324, 14335, 14343, 343}, 0, 0, 344, 346, {348,5812},{357,878},{370,56},{376,2689}},
-       {16950, 878, 1911, 2689, 56, 447, 74, 14354, 14382, {14404, 14426, 14448, 14473, 14495, 14520, 14548}, {14570, 14580, 14590, 14603, 14613, 14626, 14642}, {14652, 14668, 14693, 14712, 14734, 14741, 14754, 14767, 14786, 14817, 14842, 14861, 343}, {14652, 14668, 14693, 14712, 14734, 14741, 14754, 14767, 14786, 14817, 14842, 14861, 343}, 0, 0, 344, 346, {348,1911},{357,878},{370,56},{376,2689}},
-       {16896, 878, 5812, 16929, 16942, 447, 74, 14886, 14914, {14936, 14955, 14974, 14996, 15015, 15037, 15062}, {15081, 15086, 15094, 15102, 15110, 15118, 15126}, {15137, 15153, 15178, 15197, 15219, 15226, 15239, 15252, 15271, 15299, 15324, 15346, 343}, {15137, 15153, 15178, 15197, 15219, 15226, 15239, 15252, 15271, 15299, 15324, 15346, 343}, 0, 0, 344, 346, {348,5812},{357,878},{370,16942},{376,16929}},
-       {16950, 878, 5812, 2689, 56, 447, 74, 15371, 15383, {12597, 12616, 15395, 12657, 12676, 12698, 12723}, {12742, 12752, 15417, 12775, 12785, 12798, 12814}, {15430, 15455, 12856, 15480, 15499, 12898, 15506, 15519, 15535, 15563, 15585, 15613, 343}, {15430, 15455, 12856, 15480, 15499, 12898, 15506, 15519, 15535, 15563, 15585, 15613, 343}, 0, 0, 344, 346, {348,5812},{357,878},{370,56},{376,2689}},
-       {4766, 409, 890, 376, 370, 447, 457, 465, 468, {15635, 15643, 15648, 15655, 15665, 15671, 15678}, {15686, 15690, 2913, 15694, 15699, 15703, 15707}, {15712, 15720, 15729, 15735, 15741, 15746, 15752, 15758, 15765, 15774, 15782, 15791, 343}, {15800, 2135, 2913, 15804, 2074, 15808, 15813, 13171, 15817, 15821, 2167, 2921, 343}, 0, 1, 344, 346, {348,890},{357,409},{370},{376}},
-       {16950, 878, 5812, 2689, 56, 447, 74, 15371, 15383, {15825, 12616, 15853, 12657, 12676, 12698, 12723}, {12742, 12752, 15417, 12775, 12785, 12798, 12814}, {15430, 15872, 12856, 15480, 15499, 12898, 15506, 15519, 15535, 15563, 15585, 15613, 343}, {15430, 15455, 12856, 15480, 15499, 12898, 15506, 15519, 15535, 15563, 15585, 15613, 343}, 0, 0, 344, 346, {348,5812},{357,878},{370,56},{376,2689}},
-       {1, 24, 37, 46, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37},{357,24},{370,56},{376,46}},
-       {16974, 5000, 17019, 17026, 17049, 5033, 5049, 1156, 1163, {1170, 1180, 1190, 1200, 1210, 1220, 1230}, {1240, 1244, 1248, 1252, 1256, 1260, 1264}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, 0, 0, 344, 346, {348,17019},{357,5000},{370,17049},{376,17026}},
-       {1920, 1381, 1942, 438, 370, 447, 1416, 1953, 1959, {1966, 1974, 1981, 1990, 1999, 2010, 2018}, {2026, 2029, 2032, 2035, 2038, 2041, 2044}, {2047, 2054, 2062, 2068, 2074, 2078, 2083, 2088, 2095, 2105, 2113, 2122, 343}, {2131, 2135, 2139, 2143, 2074, 2147, 2151, 2155, 2159, 2163, 2167, 2171, 343}, 0, 1, 844, 346, {348,846,1942},{357,1381},{370},{376,438}},
-       {5991, 878, 2678, 438, 370, 447, 74, 465, 468, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 1, 344, 346, {348,2752,2678},{2732,2732,2925,2939,2959,878},{2759,2759,2974,1411,370},{2199,2199,2983,2995,438,376}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {8877, 878, 3872, 2995, 370, 447, 74, 465, 468, {3670, 3679, 3685, 3691, 3700, 3706, 3715}, {3722, 3727, 3732, 3737, 3742, 3747, 3752}, {3757, 3765, 3774, 3779, 3785, 3789, 3794, 3802, 3808, 3818, 1052, 3826, 343}, {3836, 3842, 3774, 3849, 3785, 3789, 3854, 3802, 3860, 1099, 1104, 3866, 343}, 0, 1, 344, 346, {890,3872,3277},{357,878,3653},{370},{376,438,2995}},
-       {5991, 878, 1942, 438, 370, 447, 74, 4790, 4793, {4796, 4805, 4813, 4822, 4833, 4842, 4851}, {3152, 3156, 1873, 4858, 4862, 4866, 4870}, {4874, 4882, 3192, 4891, 4898, 4905, 4912, 3215, 4919, 4929, 1052, 4937, 343}, {4946, 1869, 1873, 1877, 4950, 4954, 4958, 3265, 4962, 4966, 1901, 3273, 343}, 0, 1, 844, 346, {348,890,846,1942},{357,409,878},{370},{376,438}},
-       {8877, 878, 3872, 2995, 370, 447, 74, 465, 468, {5819, 5826, 5834, 5842, 5851, 5861, 5869}, {5878, 3431, 5881, 5884, 5887, 5890, 5893}, {5896, 5904, 5913, 1802, 5919, 1812, 1817, 5923, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 5932, 1877, 5919, 1881, 1885, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 344, 346, {348,5812,3277,3872},{357,878},{370,1411},{376,1401,2995}},
-       {5936, 1381, 846, 5960, 5971, 447, 1416, 465, 468, {1698, 1706, 1713, 1721, 1728, 1736, 1743}, {5977, 3431, 3434, 5981, 3440, 5984, 5987}, {1781, 1788, 3774, 1802, 3785, 1812, 1817, 1822, 1829, 1839, 1847, 4732, 343}, {1865, 1869, 1873, 1877, 3785, 1881, 1885, 1889, 1893, 1897, 1901, 4762, 343}, 0, 1, 344, 346, {348,846},{357,1381},{370,5971},{376,5960}},
-       {17055, 3037, 1678, 2995, 370, 3070, 3075, 465, 468, {3097, 6260, 6274, 6287, 6300, 6313, 3144}, {3152, 6325, 6329, 6333, 6337, 6341, 3173}, {6345, 6353, 6363, 1006, 6370, 6375, 6381, 3215, 6387, 6396, 6404, 6413, 343}, {1865, 6422, 1873, 3257, 3785, 1881, 1885, 3265, 4962, 6426, 1901, 6430, 343}, 0, 1, 1909, 346, {348,1678},{357,3037},{370},{376,2995}},
-       {16467, 7684, 3327, 438, 5971, 447, 74, 7701, 7704, {7707, 7715, 7723, 1721, 1728, 1736, 7730}, {7738, 7742, 3434, 5981, 3440, 5984, 7746}, {5896, 5904, 3774, 1802, 1808, 1812, 1817, 7750, 1829, 1839, 1847, 1856, 343}, {1865, 1869, 1873, 1877, 1808, 1881, 1885, 1889, 1893, 1897, 1901, 1905, 343}, 0, 1, 844, 346, {348,6012,3327},{357,7684},{370,5971},{376,5960,438}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {17110, 5331, 17157, 15948, 17049, 17177, 17194, 1156, 1163, {1170, 1180, 1190, 1200, 1210, 1220, 1230}, {1240, 1244, 1248, 1252, 1256, 1260, 1264}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, {5170, 5175, 5180, 5185, 5190, 5195, 5200, 5205, 5210, 5215, 5221, 5227, 343}, 0, 0, 344, 346, {348,17157},{357,5331},{370,17049},{376,15948}},
-       {17209, 9701, 1942, 438, 370, 447, 1689, 1953, 1959, {1966, 1974, 1981, 1990, 1999, 2010, 2018}, {2026, 2029, 2032, 2035, 2038, 2041, 2044}, {17232, 2054, 2062, 2068, 2074, 2078, 2083, 2088, 2095, 2105, 2113, 2122, 343}, {17240, 2135, 17245, 2143, 2074, 2147, 2151, 2155, 2159, 2163, 2167, 2171, 343}, 0, 1, 844, 346, {348,846,1942},{357,1381,9701},{370},{376,438}},
-       {17250, 878, 3872, 2199, 56, 447, 74, 465, 468, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {348,2752,3277,3872},{2732,2732,2925,2939,2959,878},{2759,2759,2974,1411,370,56},{2199,2199,2983,2995,438,46}},
-       {17273, 17310, 2678, 2995, 1411, 17339, 457, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037,17310},{370,1411},{376,2983,2995}},
-       {5991, 878, 6012, 438, 370, 447, 74, 465, 468, {3670, 3679, 3685, 3691, 3700, 3706, 3715}, {3722, 3727, 3732, 3737, 3742, 3747, 3752}, {3757, 3765, 3774, 3779, 3785, 3789, 3794, 3802, 3808, 3818, 1052, 3826, 343}, {3836, 3842, 3774, 3849, 3785, 3789, 3854, 3802, 3860, 1099, 1104, 3866, 343}, 0, 0, 1909, 346, {890,3872,3277,5531,6012},{357,878,3653},{370},{376,438}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {17354, 17377, 890, 17389, 17400, 447, 457, 1156, 1163, {1170, 1180, 1190, 1200, 1210, 1220, 1230}, {1240, 1244, 1248, 1252, 1256, 1260, 1264}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, 0, 0, 344, 346, {348,890},{357,17377},{370,17400},{376,17389}},
-       {1920, 1381, 1942, 438, 370, 447, 1416, 1953, 1959, {1966, 1974, 1981, 1990, 1999, 2010, 2018}, {2026, 2029, 2032, 2035, 2038, 2041, 2044}, {2047, 2054, 2062, 2068, 2074, 2078, 2083, 2088, 2095, 2105, 2113, 2122, 343}, {2131, 2135, 2139, 2143, 2074, 2147, 2151, 2155, 2159, 2163, 2167, 2171, 343}, 0, 1, 844, 346, {348,846,1942},{357,1381},{370},{376,438}},
-       {17408, 17432, 2678, 2199, 56, 447, 2767, 465, 468, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {348,2752,890,2678},{2732,2732,2925,2939,2959,17432},{2759,2759,2974,1411,370,56},{2199,2199,2983,2995,438,2689}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {5991, 878, 1942, 438, 370, 447, 74, 465, 468, {3670, 3679, 3685, 3691, 3700, 3706, 3715}, {3722, 3727, 3732, 3737, 3742, 3747, 3752}, {3757, 3765, 3774, 3779, 3785, 3789, 3794, 3802, 3808, 3818, 1052, 3826, 343}, {3836, 3842, 3774, 3849, 3785, 3789, 3854, 3802, 3860, 1099, 1104, 3866, 343}, 0, 1, 844, 346, {890,3872,3277,846,1942},{357,878,3653},{370},{376,438}},
-       {17445, 24, 1678, 2995, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 1909, 346, {348,37,1678},{357,24},{370,56},{376,46,2995}},
-       {17110, 5331, 17157, 15948, 17049, 17177, 17194, 1156, 1163, {1170, 1180, 1190, 1200, 1210, 1220, 1230}, {1240, 1244, 1248, 1252, 1256, 1260, 1264}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, {5170, 5175, 5180, 5185, 5190, 5195, 5200, 5205, 5210, 5215, 5221, 5227, 343}, 0, 0, 344, 346, {348,17157},{357,5331},{370,17049},{376,15948}},
-       {17250, 878, 3872, 2199, 56, 447, 74, 3087, 3092, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {348,2752,3277,3872},{2732,2732,2925,2939,2959,878},{2759,2759,2974,1411,370,56},{2199,2199,2983,2995,438,46}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {3627, 3653, 2678, 438, 370, 447, 74, 465, 468, {3670, 3679, 3685, 3691, 3700, 3706, 3715}, {3722, 3727, 3732, 3737, 3742, 3747, 3752}, {3757, 3765, 3774, 3779, 3785, 3789, 3794, 3802, 3808, 3818, 1052, 3826, 343}, {3836, 3842, 3774, 3849, 3785, 3789, 3854, 3802, 3860, 1099, 1104, 3866, 343}, 0, 1, 344, 346, {890,3872,3277,2678},{357,878,3653},{370},{376,438}},
-       {17445, 24, 1678, 2995, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 1909, 346, {348,37,1678},{357,24},{370,56},{376,46,2995}},
-       {5991, 878, 2678, 438, 370, 447, 74, 3087, 3092, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {348,2752,2678},{2732,2732,2925,2939,2959,878},{2759,2759,2974,1411,370},{2199,2199,2983,2995,438,376}},
-       {3003, 3037, 3059, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,11825},{357,3037},{370,16942},{376,2983,16929}},
-       {17445, 24, 1678, 2995, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {87, 98, 113, 130, 147, 160, 173}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 1909, 346, {348,37,1678},{357,24},{370,56},{376,46,2995}},
-       {16734, 409, 5022, 2983, 56, 447, 457, 465, 468, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {348,2752,5022},{2732,2732,2925,2939,2959,409},{2759,2759,2974,1411,370,56},{2199,2199,2983,2995,438,46}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {87, 98, 113, 130, 147, 160, 173}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {3003, 3037, 2678, 2983, 1411, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,2678},{357,3037},{370,1411},{376,2983,1401}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {87, 98, 113, 130, 147, 160, 173}, {17466, 17490, 17499, 17508, 17519, 17528, 17541, 17550, 17555, 17566, 17588, 17612, 343}, {17466, 17490, 17499, 17508, 17519, 17528, 17541, 17550, 17555, 17566, 17588, 17612, 343}, 0, 4, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {87, 98, 113, 130, 147, 160, 173}, {17466, 17490, 17499, 17508, 17634, 17528, 17541, 17550, 17555, 17566, 17588, 17612, 343}, {17466, 17490, 17499, 17508, 17634, 17528, 17541, 17550, 17555, 17566, 17588, 17612, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {17643, 17674, 2678, 2983, 2759, 447, 2767, 465, 468, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {2678,6012},{2732,2732,2925,2939,2959,17674},{2759,2759,2974,1411,370},{2983,438}},
-       {3003, 3037, 2678, 2983, 370, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370},{376,2983,1401}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {87, 98, 113, 130, 147, 160, 173}, {17466, 17490, 17499, 17508, 17519, 17528, 17541, 17550, 17555, 17566, 17588, 17612, 343}, {17466, 17490, 17499, 17508, 17519, 17528, 17541, 17550, 17555, 17566, 17588, 17612, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {2175, 409, 10613, 2199, 56, 447, 457, 465, 468, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {348,2752,37,10613},{2732,2732,2925,2939,2959,409},{2759,2759,2974,1411,370,56},{2199,2199,2983,2995,438,46}},
-       {17055, 3037, 2678, 2995, 1411, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,1411},{376,2983,1401,2995}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {17408, 17432, 10613, 2199, 56, 447, 2767, 465, 468, {2774, 2781, 2788, 2796, 2806, 2815, 2822}, {2831, 2835, 2839, 2843, 2847, 2851, 2855}, {2859, 2867, 2876, 2068, 2882, 2886, 2891, 2088, 2095, 2896, 2113, 2904, 343}, {2131, 2135, 2913, 2143, 2882, 2147, 2151, 2155, 2159, 2917, 2167, 2921, 343}, 0, 0, 344, 346, {348,2752,10613},{2732,2732,2925,2939,2959,17432},{2759,2759,2974,1411,370,56},{2199,2199,2983,2995,438,2689}},
-       {17055, 3037, 1678, 2995, 1411, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 1909, 346, {348,3277,3059,1911,1678},{357,3037},{370,1411},{376,2983,1401,2995}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {184, 187, 190, 193, 196, 199, 202}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {17085, 24, 2678, 2983, 56, 63, 74, 81, 84, {87, 98, 113, 130, 147, 160, 173}, {87, 98, 113, 130, 147, 160, 173}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, {205, 216, 229, 238, 249, 258, 269, 280, 291, 304, 317, 330, 343}, 0, 6, 344, 346, {348,37,2678},{357,24},{370,56},{376,46,2983}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {17693, 17728, 2678, 2983, 16942, 3070, 17751, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037,17728},{370,16942},{376,2983,16929}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,890,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {3003, 3037, 2678, 2983, 16942, 3070, 3075, 3087, 3092, {3097, 3105, 3111, 3118, 3129, 3136, 3144}, {3152, 3156, 1873, 3160, 3165, 3169, 3173}, {3178, 3184, 3192, 1006, 3198, 3203, 3209, 3215, 3222, 1044, 3233, 3243, 343}, {3253, 1869, 1873, 3257, 3261, 1881, 1885, 3265, 1893, 3269, 1901, 3273, 343}, 0, 1, 344, 346, {348,3277,3059,11825,2678},{357,3037},{370,16942},{376,2983,16929}},
-       {1114, 357, 348, 376, 370, 1138, 1148, 1156, 1163, {1170, 1180, 1190, 1200, 1210, 1220, 1230}, {1240, 1244, 1248, 1252, 1256, 1260, 1264}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, {1268, 1275, 1282, 1289, 1296, 1303, 1310, 1317, 1324, 1331, 1338, 1348, 343}, 0, 0, 344, 346, {348},{357},{370},{376}}
+       {1, 14, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {14,270,0,0,0,0,0,0,0,0,0,0,0,0},{1,281,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {316, 335, 350, 365, 377, 55, 393, 405, {417, 430, 451, 466, 477, 496, 507}, {520, 525, 530, 535, 540, 545, 550}, {555, 558, 561, 564, 567, 558, 564}, {570, 583, 600, 609, 620, 627, 634, 641, 654, 673, 690, 705, 0}, {570, 583, 600, 609, 620, 627, 634, 641, 654, 673, 690, 705, 0}, {722, 728, 600, 738, 620, 627, 634, 746, 754, 764, 772, 782, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {335,792,808,824,0,0,0,0,0,0,0,0,0,0},{316,841,859,884,0,0,0,0},{365,908,0,0,0,0,0,0,0,0,0,0},{350,919,0,0,0,0,0,0,0}},
+       {933, 270, 307, 301, 959, 55, 973, 978, {983, 992, 1000, 1008, 1017, 1024, 1034}, {1043, 1046, 1049, 1052, 1055, 1058, 1061}, {1064, 1066, 1068, 1070, 1072, 1074, 1076}, {1078, 1084, 1091, 1097, 1103, 1108, 1113, 1120, 1126, 1135, 1143, 1152, 0}, {1161, 1170, 1180, 1189, 1199, 1207, 1215, 1225, 1235, 1247, 1259, 1271, 0}, {1283, 1288, 1091, 1294, 1103, 1108, 1299, 1304, 1308, 1313, 1318, 1323, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1328,1339,1347,1354,1363,0,0,0,0,0,0,0},{933,1372,1388,0,0,0,0,0},{301,1404,1409,0,0,0,0,0,0,0,0,0},{307,1420,1428,0,0,0,0,0,0}},
+       {1445, 1467, 1420, 1404, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {1589, 1596, 1603, 1610, 1617, 1624, 1631}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1328,1837,1848,1859,1866,1873,1880,0,0,0,0},{1445,1889,1916,0,0,0,0,0},{1404,301,1943,1951,0,0,0,0,0,0,0,0},{1420,307,1960,1971,0,0,0,0,0}},
+       {1445, 1467, 1420, 1404, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {1589, 1596, 1603, 1610, 1617, 1624, 1631}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1328,1837,1848,1859,1866,1873,1880,0,0,0,0},{1445,1889,1916,0,0,0,0,0},{1404,301,1943,1951,0,0,0,0,0,0,0,0},{1420,307,1960,1971,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 55, 2015, 2020, {2025, 2033, 2043, 2051, 2059, 2068, 2075}, {2082, 2085, 2088, 2092, 2095, 2099, 2103}, {2106, 2108, 2110, 2113, 2115, 2108, 2113}, {2118, 2124, 2130, 2138, 2144, 2152, 2160, 2170, 2176, 2184, 2192, 2201, 0}, {2210, 2216, 2223, 2231, 2237, 2245, 2253, 2263, 2176, 2269, 2277, 2287, 0}, {2296, 2299, 2302, 2305, 2308, 2311, 2314, 2317, 2320, 2323, 2327, 2331, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1996,2335,1328,1819,1859,0,0,0,0,0,0,0,0,0},{1983,0,0,0,0,0,0,0},{1404,301,2342,2350,0,0,0,0,0,0,0,0},{1420,307,2355,2366,0,0,0,0,0}},
+       {1983, 2374, 307, 301, 2005, 2385, 2393, 2398, {2403, 2411, 2418, 2426, 2433, 2441, 2448}, {2456, 2461, 2465, 2469, 2473, 2477, 2481}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {2496, 2503, 2511, 2517, 2523, 2527, 2532, 2537, 2544, 2554, 2562, 2571, 0}, {2496, 2503, 2511, 2517, 2523, 2527, 2532, 2537, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {2374,1354,1328,2626,0,0,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {2651, 2670, 307, 301, 2005, 55, 2681, 2687, {2694, 2702, 2709, 2718, 2727, 2738, 2746}, {2754, 2757, 2760, 2763, 2766, 2769, 2772}, {2113, 2486, 2775, 2486, 2775, 2492, 2113}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2861, 2865, 2869, 2874, 2804, 2878, 2882, 2886, 2890, 2894, 2898, 2902, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,2906,1363,2918,2926,1996,1328,0,0,0,0,0,0,0},{2651,1983,2933,0,0,0,0,0},{301,1404,2350,2945,0,0,0,0,0,0,0,0},{307,2956,2970,2985,0,0,0,0,0}},
+       {2992, 3010, 3019, 3030, 2005, 55, 3038, 3045, {3052, 3067, 3082, 3093, 3108, 3121, 3140}, {3155, 3162, 3169, 3176, 3183, 3190, 3197}, {3204, 3207, 3210, 3210, 3213, 3213, 3216}, {3219, 3240, 3263, 3278, 3295, 3306, 3321, 3336, 3355, 3378, 3397, 3416, 0}, {3437, 3458, 3481, 3496, 3513, 3524, 3539, 3554, 3573, 3596, 3615, 3634, 0}, {3655, 3662, 3669, 3676, 3683, 3690, 3699, 3708, 3715, 3722, 3729, 3736, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {3010,270,1347,14,3743,1328,0,0,0,0,0,0,0,0},{2992,3755,0,0,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {4028, 270, 1420, 1404, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1339,1347,1354,1363,1328,2906,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{1404,301,1409,0,0,0,0,0,0,0,0,0},{1420,307,1428,0,0,0,0,0,0}},
+       {4303, 1996, 1420, 1404, 2005, 4320, 4332, 4336, {4340, 4352, 4364, 4374, 4388, 4398, 4410}, {4421, 4424, 4427, 4430, 4433, 4436, 4439}, {2113, 2486, 2488, 4442, 2488, 2108, 2494}, {4444, 4453, 4462, 4472, 4481, 4490, 4499, 4509, 4516, 4524, 4532, 4542, 0}, {4551, 4562, 4573, 4585, 4596, 4607, 4618, 4630, 4639, 4649, 4659, 4671, 0}, {4682, 4688, 4694, 4701, 4707, 4713, 4719, 4726, 4730, 4735, 4740, 4747, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1996,2670,2926,1328,0,0,0,0,0,0,0,0,0,0},{4303,4753,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4771, 270, 307, 301, 2005, 4788, 3804, 3807, {4795, 4804, 4810, 4816, 4825, 4831, 4840}, {4847, 4852, 4857, 4862, 4867, 4872, 4877}, {2775, 2494, 2486, 2486, 4155, 4157, 2113}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4961, 4967, 4899, 4974, 4910, 4914, 4979, 4927, 4985, 1313, 1318, 4991, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1363,1354,1328,0,0,0,0,0,0,0,0,0},{4771,4997,3755,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {5030, 270, 307, 301, 2005, 55, 5048, 5061, {5072, 5090, 5104, 5122, 5140, 5158, 5174}, {5188, 5200, 5212, 5224, 5236, 5248, 5260}, {5267, 5270, 5273, 5276, 5279, 5282, 5285}, {5288, 5299, 5312, 5319, 5330, 5337, 5346, 5355, 5368, 5381, 5396, 5409, 0}, {5288, 5299, 5312, 5319, 5330, 5337, 5346, 5355, 5368, 5381, 5396, 5409, 0}, {5420, 5429, 5312, 5438, 5330, 5447, 5456, 5465, 5474, 5483, 5492, 5501, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,5510,14,1,1354,2374,5523,1328,5536,5553,0,0,0,0},{5030,5510,5563,5585,5536,0,0,0},{301,35,0,0,0,0,0,0,0,0,0,0},{307,23,0,0,0,0,0,0,0}},
+       {5606, 5620, 1420, 1404, 5632, 5643, 5651, 5655, {5659, 5669, 5677, 5682, 5689, 5702, 5710}, {4157, 5718, 4442, 5720, 5724, 2108, 5727}, {4157, 5718, 4442, 5731, 5724, 2108, 5731}, {5734, 5742, 5751, 5760, 5769, 5776, 5784, 5792, 5802, 5813, 2562, 2571, 0}, {5734, 5742, 5751, 5760, 5769, 5776, 5784, 5792, 5802, 5813, 2562, 2571, 0}, {5822, 1288, 5827, 5834, 5840, 5846, 5852, 5858, 5863, 5870, 1318, 5875, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {5620,5880,1328,5894,0,0,0,0,0,0,0,0,0,0},{5606,0,0,0,0,0,0,0},{1404,301,3030,0,0,0,0,0,0,0,0,0},{1420,307,3019,0,0,0,0,0,0}},
+       {1983, 1996, 307, 301, 2005, 2385, 5903, 5908, {5913, 5924, 5935, 5949, 5963, 5975, 5987}, {5999, 6003, 6008, 6013, 6018, 6022, 6027}, {1076, 6031, 6033, 6031, 6036, 6036, 1066}, {6038, 6046, 4899, 6055, 6062, 6067, 6074, 6081, 2544, 5813, 6089, 6099, 0}, {6038, 6046, 4899, 6055, 6062, 6067, 6074, 6081, 2544, 5813, 6089, 6099, 0}, {2580, 2584, 2588, 2592, 6062, 6108, 6113, 6118, 2608, 2612, 6124, 6129, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1996,1363,6133,6145,1328,6158,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {4771, 270, 307, 301, 2005, 55, 6167, 6170, {6173, 6182, 6190, 6199, 6210, 6219, 6228}, {4127, 4131, 2588, 6235, 6239, 6243, 6247}, {2775, 2494, 2486, 2486, 6251, 4157, 2113}, {6253, 6261, 6270, 6276, 6283, 6290, 6297, 6304, 6311, 6321, 6329, 6338, 0}, {6347, 6355, 4173, 6364, 6371, 6378, 6385, 4196, 6392, 6402, 1143, 6410, 0}, {6419, 2584, 2588, 2592, 6423, 6427, 6431, 4242, 6435, 6439, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,3743,14,6443,1347,1328,0,0,0,0,0,0,0,0},{4771,6451,3755,0,0,0,0,0},{301,1404,2350,5006,0,0,0,0,0,0,0,0},{307,2366,6460,0,0,0,0,0,0}},
+       {1445, 1837, 1420, 1404, 1476, 1492, 6469, 6476, {6483, 6493, 6503, 6513, 6523, 6533, 6543}, {1638, 6553, 6557, 6561, 6565, 6569, 6573}, {1638, 6553, 6557, 6561, 6565, 6569, 6573}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1866,1467,6577,6596,6613,1328,0,0,0,0,0,0},{1445,6634,6658,6685,0,0,0,0},{1404,301,1943,1951,0,0,0,0,0,0,0,0},{1420,307,1960,1971,0,0,0,0,0}},
+       {6714, 1328, 1960, 1943, 6743, 6760, 6774, 6781, {6788, 6798, 6808, 6818, 6828, 6838, 6848}, {6858, 6862, 6866, 6870, 6874, 6878, 6882}, {6858, 6862, 6866, 6870, 6874, 6878, 6882}, {6886, 6891, 6896, 6901, 6906, 6911, 6916, 6921, 6926, 6931, 6937, 6943, 0}, {6886, 6891, 6896, 6901, 6906, 6911, 6916, 6921, 6926, 6931, 6937, 6943, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1328,5894,1859,1819,0,0,0,0,0,0,0,0,0,0},{6714,6949,6973,7000,7022,7053,0,0},{1943,1951,1404,301,0,0,0,0,0,0,0,0},{1960,1971,1420,307,0,0,0,0,0}},
+       {4771, 7079, 1420, 1404, 2005, 55, 973, 978, {7088, 7095, 7103, 7111, 7120, 7130, 7138}, {7147, 4424, 7150, 7153, 7156, 7159, 7162}, {7165, 2486, 2775, 3895, 2775, 4157, 7165}, {7167, 7175, 7184, 2517, 7190, 2527, 2532, 7194, 2544, 2554, 2562, 2571, 0}, {7167, 7175, 7184, 2517, 7190, 2527, 2532, 7194, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 7203, 2592, 7190, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {7079,2335,1354,14,1363,2906,1328,0,0,0,0,0,0,0},{4771,6451,3755,4997,0,0,0,0},{1404,301,2350,7207,7219,0,0,0,0,0,0,0},{1420,307,7231,7246,0,0,0,0,0}},
+       {1983, 2670, 307, 301, 2005, 2385, 973, 978, {2403, 2411, 2418, 2426, 2433, 2441, 2448}, {7261, 7266, 7270, 7274, 7278, 7282, 7286}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2580, 2584, 2588, 2592, 4910, 2596, 2600, 2604, 2608, 2612, 2616, 6129, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 790, 268, {2670,1363,2926,1328,2906,0,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,7291,5006,0,0,0,0,0,0,0,0},{307,1420,7302,6460,0,0,0,0,0}},
+       {3755, 1328, 307, 301, 2005, 4788, 3804, 3807, {7316, 7326, 7340, 7347, 7354, 7363, 2075}, {7371, 7378, 7383, 7387, 7392, 7397, 7401}, {2106, 2108, 3895, 7406, 7409, 2108, 2113}, {7411, 7420, 7425, 7432, 2523, 7442, 7451, 7458, 7468, 7478, 2192, 7491, 0}, {7501, 7510, 7517, 7523, 7532, 7537, 7545, 7551, 7560, 7570, 7584, 7594, 0}, {7602, 7606, 2588, 7610, 2523, 7614, 7618, 7622, 7626, 7630, 7635, 7639, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {1328,5894,0,0,0,0,0,0,0,0,0,0,0,0},{3755,5510,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {7643, 270, 307, 301, 4057, 7671, 3804, 3807, {4072, 7684, 7698, 7711, 7724, 7737, 4119}, {4127, 7749, 7753, 7757, 7761, 7765, 4148}, {2775, 2113, 2488, 7769, 7769, 2113, 2113}, {7771, 7779, 7789, 1097, 7796, 7801, 7807, 4196, 7813, 7822, 7830, 7839, 0}, {7771, 7779, 7789, 1097, 7796, 7801, 7807, 4196, 7813, 7822, 7830, 7839, 0}, {2580, 7848, 2588, 4238, 4910, 2596, 2600, 4242, 6435, 7852, 2616, 7856, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,3010,1347,1354,2374,2335,7079,1363,2670,2906,2926,1996,1328},{7643,4281,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {2992, 270, 307, 301, 2005, 55, 7860, 7863, {7866, 7875, 4810, 7885, 7893, 7901, 7910}, {7916, 7919, 4424, 7923, 7926, 7930, 2103}, {2775, 6251, 2486, 2486, 6251, 4157, 2113}, {7933, 7941, 4899, 7948, 7955, 7960, 7970, 7978, 7984, 7994, 2562, 2571, 0}, {7933, 7941, 4899, 7948, 7955, 7960, 7970, 7978, 7984, 7994, 2562, 2571, 0}, {8002, 8009, 4899, 4974, 7955, 8015, 8022, 7978, 8027, 1313, 1318, 5875, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1339,8033,1347,270,1328,0,0,0,0,0,0,0},{2992,3755,4997,0,0,0,0,0},{301,1404,8041,8053,8064,8072,8082,8091,2945,8097,8105,8110},{307,1420,8113,8128,2970,2956,8142,8155,2985}},
+       {3755, 2670, 307, 301, 2005, 4788, 3804, 3807, {8167, 8177, 8182, 8189, 8198, 8202, 8209}, {8220, 8223, 8226, 2763, 8229, 8232, 8235}, {2775, 2494, 2486, 2486, 4155, 4157, 2113}, {8239, 8248, 8258, 8265, 4910, 8273, 8279, 2537, 8285, 8296, 8306, 8316, 0}, {8239, 8248, 8258, 8265, 4910, 8273, 8279, 2537, 8285, 8296, 8306, 8316, 0}, {8326, 8331, 4857, 8336, 4910, 8341, 8346, 5858, 4985, 1313, 1318, 5875, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1996,1328,0,0,0,0,0,0,0,0,0,0,0},{3755,0,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {841, 2670, 1420, 1404, 2005, 3796, 8351, 8371, {8397, 8420, 451, 8443, 8454, 8469, 8484}, {8499, 8504, 8509, 8514, 8519, 8524, 8529}, {8534, 8537, 8534, 8540, 8543, 8537, 8540}, {8546, 8559, 8574, 8583, 8596, 8603, 8612, 8621, 8634, 8651, 8666, 8679, 0}, {8694, 8707, 8722, 8733, 8746, 8753, 8762, 8771, 8786, 8803, 8818, 8831, 0}, {8846, 8854, 8574, 8864, 8596, 8603, 8612, 8872, 8880, 8890, 8898, 8908, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{841,316,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {8916, 8930, 1420, 1404, 44, 2385, 3804, 3807, {8940, 8949, 8961, 8968, 8976, 8986, 8992}, {8999, 9003, 9007, 9011, 9015, 9020, 9024}, {9028, 9030, 9032, 1076, 9034, 9030, 1076}, {9037, 9047, 9056, 9064, 9072, 9080, 9087, 9094, 9102, 2192, 9108, 9116, 0}, {9125, 9135, 9144, 9152, 9160, 9168, 9175, 9182, 9191, 7584, 9197, 9207, 0}, {9216, 9220, 9225, 9230, 9234, 7618, 9238, 9242, 9246, 7635, 9250, 9254, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {8930,9258,6133,9266,9278,9288,9298,1328,0,0,0,0,0,0},{8916,9310,9325,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 9345, 1420, 1404, 2005, 55, 9356, 9367, {9378, 9386, 9395, 9402, 9409, 9418, 2075}, {2082, 2085, 9425, 2092, 9428, 9432, 2103}, {2106, 2108, 9435, 2113, 9437, 2108, 2113}, {5734, 5742, 9440, 6055, 9446, 6108, 6113, 2537, 2544, 5813, 2562, 2571, 0}, {9451, 9460, 7517, 9470, 9478, 9484, 9490, 9496, 9504, 9514, 9523, 9532, 0}, {2580, 2584, 2588, 2592, 9446, 6108, 6113, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 9541, 268, {9345,1996,9544,2926,2670,1363,1328,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{1404,301,2350,0,0,0,0,0,0,0,0,0},{1420,307,2366,0,0,0,0,0,0}},
+       {1328, 1328, 9553, 9564, 9572, 3796, 9580, 9583, {9586, 9593, 9602, 9611, 9623, 9631, 9640}, {9650, 9654, 3951, 9659, 9664, 9668, 9672}, {2775, 5718, 2486, 2486, 9676, 2108, 2113}, {9678, 9684, 4899, 9691, 2523, 9697, 9705, 9712, 9718, 9726, 9732, 9740, 0}, {9678, 9684, 4899, 9691, 2523, 9697, 9705, 9712, 9718, 9726, 9732, 9740, 0}, {2861, 9748, 3951, 9752, 9756, 9760, 9764, 9768, 9672, 9772, 9776, 9781, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 2624, 268, {1328,5894,0,0,0,0,0,0,0,0,0,0,0,0},{1328,0,0,0,0,0,0,0},{9564,301,0,0,0,0,0,0,0,0,0,0},{9553,307,0,0,0,0,0,0,0}},
+       {9785, 1328, 307, 301, 2005, 9803, 9816, 9819, {9822, 9830, 9838, 2426, 2433, 2441, 9845}, {9853, 9858, 9863, 2469, 2473, 2477, 9867}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {7167, 7175, 4899, 2517, 2523, 2527, 2532, 9872, 2544, 2554, 2562, 2571, 0}, {7167, 7175, 4899, 2517, 2523, 2527, 2532, 9872, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {1328,5894,0,0,0,0,0,0,0,0,0,0,0,0},{9785,9880,0,0,0,0,0,0},{301,1404,9903,0,0,0,0,0,0,0,0,0},{307,1420,9913,0,0,0,0,0,0}},
+       {3755, 3010, 1420, 1404, 2005, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,270,9926,9937,1328,0,0,0,0,0,0,0},{3755,9949,9965,0,0,0,0,0},{1404,301,3030,35,0,0,0,0,0,0,0,0},{1420,307,3019,23,0,0,0,0,0}},
+       {10007, 2670, 307, 301, 2005, 55, 3804, 3807, {10025, 10031, 10041, 10047, 10058, 10068, 10073}, {10083, 10087, 10091, 10095, 10100, 10104, 10108}, {2108, 2108, 2113, 10112, 2108, 7409, 7409}, {10115, 10120, 10127, 10132, 10138, 10145, 10153, 10160, 10169, 10176, 10181, 10188, 0}, {10115, 10120, 10127, 10132, 10138, 10145, 10153, 10160, 10169, 10176, 10181, 10188, 0}, {10196, 10200, 3951, 10205, 3920, 10209, 10213, 10217, 10222, 10226, 10230, 10234, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,1328,0,0,0,0,0,0,0,0,0,0,0},{10007,5510,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {4014, 270, 3019, 3030, 44, 55, 10238, 10243, {10250, 10261, 10268, 10277, 10284, 10297, 10306}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {10315, 10326, 10337, 10346, 10357, 10362, 10369, 10380, 10389, 10400, 10413, 10424, 0}, {10315, 10326, 10337, 10346, 10357, 10362, 10369, 10380, 10389, 10400, 10413, 10424, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {5510, 270, 1420, 1404, 2005, 55, 3804, 3807, {10435, 10442, 10448, 10455, 10460, 10466, 10472}, {10478, 10482, 10486, 10490, 10494, 10498, 10502}, {2486, 2113, 2113, 10506, 4442, 4155, 2113}, {10508, 10516, 10525, 2798, 10531, 2808, 2813, 10535, 2825, 2835, 2843, 10543, 0}, {10508, 10516, 10525, 2798, 10531, 2808, 2813, 10535, 2825, 2835, 2843, 10543, 0}, {2861, 2865, 3951, 2874, 10531, 2878, 2882, 10552, 2890, 2894, 2898, 10556, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {10560, 2670, 1420, 1404, 10578, 4788, 10594, 10599, {10604, 10617, 10636, 10653, 10666, 10679, 10696}, {10709, 8504, 8509, 8514, 8519, 8524, 8529}, {10714, 8537, 8534, 8540, 8543, 8537, 8540}, {10717, 10730, 10741, 10758, 10773, 10788, 10803, 10816, 10831, 10848, 10863, 10880, 0}, {10895, 10906, 10919, 10934, 10947, 10960, 10973, 10984, 10997, 11012, 11025, 11044, 0}, {11057, 11064, 11071, 11078, 11085, 11092, 11099, 11106, 11113, 11120, 11127, 11134, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,1328,0,0,0,0,0,0,0,0,0,0,0},{10560,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3755, 2670, 1420, 1404, 2005, 4788, 11141, 11154, {11167, 11182, 11203, 11218, 11231, 11244, 11259}, {520, 525, 11272, 535, 11277, 545, 550}, {555, 558, 11282, 564, 567, 558, 564}, {11285, 11302, 11311, 11326, 11343, 11358, 11373, 11386, 11401, 11418, 11439, 11456, 0}, {11285, 11302, 11311, 11326, 620, 11358, 11373, 11386, 11401, 11418, 11439, 11456, 0}, {11471, 11478, 11485, 11492, 11499, 11506, 11513, 11520, 11527, 11534, 11541, 11548, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 790, 268, {2670,1363,1328,0,0,0,0,0,0,0,0,0,0,0},{3755,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 2015, 11555, {11560, 11568, 11579, 11585, 11591, 11600, 2075}, {8999, 9003, 2473, 11606, 9015, 9020, 11610}, {9028, 9030, 1068, 1076, 9034, 9030, 1076}, {2496, 2503, 9440, 2517, 2523, 11614, 11620, 11626, 2544, 2554, 2562, 2571, 0}, {2496, 2503, 9440, 2517, 2523, 11614, 11620, 11626, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 11633, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {11648, 11667, 1420, 1404, 11677, 2385, 11693, 11698, {11703, 11714, 11725, 11736, 11747, 11758, 11764}, {2108, 9676, 2488, 4442, 2106, 10506, 2494}, {2108, 9676, 2488, 4442, 2106, 10506, 2494}, {11773, 11781, 11790, 11797, 4910, 11804, 11810, 2537, 2544, 11816, 2562, 11825, 0}, {11773, 11781, 11790, 11797, 4910, 11804, 11810, 2537, 2544, 11816, 2562, 11825, 0}, {11835, 11840, 11790, 2592, 4910, 11804, 11810, 2604, 11846, 2612, 2616, 11851, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {11667,2670,1363,1328,0,0,0,0,0,0,0,0,0,0},{11648,11856,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {11876, 5620, 1420, 1404, 5632, 2385, 11903, 11920, {11934, 11945, 11955, 11964, 11975, 11987, 11998}, {12008, 12011, 12014, 12017, 12020, 12023, 12026}, {2113, 2108, 2490, 2488, 7409, 2108, 2113}, {12029, 12039, 2511, 12050, 12059, 12065, 12073, 12081, 12089, 12100, 12109, 12119, 0}, {12029, 12039, 2511, 12050, 12059, 12065, 12073, 12081, 12089, 12100, 12109, 12119, 0}, {4961, 1288, 2511, 8336, 12059, 12129, 12135, 5858, 4985, 5870, 1318, 5875, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {5620,12141,1328,0,0,0,0,0,0,0,0,0,0,0},{11876,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {12151, 1848, 307, 301, 12173, 12188, 12200, 11555, {12206, 12218, 12230, 12242, 12256, 12271, 12284}, {12298, 12011, 12301, 12017, 12304, 12307, 12310}, {2113, 2108, 12314, 2488, 4442, 2108, 9437}, {12316, 12323, 12331, 12337, 12346, 12355, 12365, 12371, 12382, 12392, 12399, 12409, 0}, {12417, 12424, 12432, 12438, 12447, 12456, 12466, 12472, 12483, 12493, 12500, 12510, 0}, {12518, 12524, 12529, 12534, 12539, 12544, 12549, 12555, 12561, 12567, 12573, 12580, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1848,1328,0,0,0,0,0,0,0,0,0,0,0,0},{12151,0,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {3755, 1363, 1420, 1404, 2005, 3796, 12587, 12599, {12611, 12626, 12641, 12656, 12673, 12692, 12703}, {12714, 12721, 12728, 12735, 12742, 12749, 12756}, {0, 0, 0, 0, 0, 0, 0}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12864, 12871, 12878, 12885, 8596, 12798, 12805, 12892, 12899, 12906, 12913, 12920, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 790, 268, {1363,1328,0,0,0,0,0,0,0,0,0,0,0,0},{3755,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,0,0,0,0,0,0,0,0}},
+       {3767, 3979, 23, 35, 44, 3796, 12927, 12947, {12964, 12977, 12990, 13006, 13023, 13038, 13047}, {12964, 12977, 12990, 13006, 13023, 13038, 13047}, {13056, 13059, 13062, 13065, 13068, 13071, 13074}, {13077, 13090, 13101, 13110, 13121, 13126, 13135, 13146, 13153, 13168, 13179, 13192, 0}, {13205, 13220, 13101, 13110, 13233, 13126, 13240, 13146, 13153, 13168, 13179, 13192, 0}, {13077, 13090, 13101, 13110, 13121, 13126, 13135, 13146, 13153, 13168, 13179, 13192, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {3979,3970,0,0,0,0,0,0,0,0,0,0,0,0},{3767,4000,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {5510, 270, 3019, 3030, 2005, 55, 13253, 13256, {13259, 13272, 13282, 13291, 13301, 13312, 13323}, {13335, 13338, 13343, 13348, 13353, 13358, 13363}, {13335, 13368, 13371, 13374, 13377, 13380, 13383}, {13386, 13399, 13410, 13420, 13431, 13443, 13455, 13468, 13480, 13493, 13508, 13529, 0}, {13386, 13399, 13410, 13420, 13431, 13443, 13455, 13468, 13480, 13493, 13508, 13529, 0}, {13548, 13554, 13560, 13566, 13572, 13578, 13584, 13590, 13596, 13602, 13609, 13616, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1354,2374,1328,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {13623, 2670, 1420, 1404, 44, 4788, 13636, 13644, {13652, 13665, 13686, 13705, 13726, 13745, 13758}, {13769, 13776, 13783, 13790, 13797, 13804, 13811}, {0, 0, 0, 0, 0, 0, 0}, {13818, 13833, 13848, 13857, 13868, 13879, 13892, 13905, 13920, 13939, 13958, 13975, 0}, {13818, 13833, 13848, 13857, 13868, 13879, 13892, 13905, 13920, 13939, 13958, 13975, 0}, {13994, 14001, 14008, 14015, 14022, 14029, 14036, 14043, 14050, 14057, 14064, 14071, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,14078,270,14088,3743,1328,0,0,0,0,0,0,0},{13623,2992,14099,5510,14118,14129,14141,14158},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3755, 2670, 1420, 1404, 2005, 4788, 0, 0, {14176, 14182, 14196, 14219, 14233, 14249, 14256}, {14265, 14268, 14273, 14279, 14283, 7409, 14288}, {251, 239, 241, 243, 245, 247, 249}, {14292, 14299, 10127, 14306, 3920, 14312, 14318, 14324, 14331, 14340, 14348, 14355, 0}, {14292, 14299, 10127, 14306, 3920, 14312, 14318, 14324, 14331, 14340, 14348, 14355, 0}, {14362, 7848, 2588, 2592, 14366, 14370, 14374, 14378, 14382, 2612, 14386, 14390, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{3755,5510,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {14394, 1837, 1420, 301, 14421, 3796, 3804, 3807, {14437, 14445, 14456, 14466, 14477, 14486, 14495}, {14505, 14508, 14511, 14514, 14517, 14520, 14523}, {14526, 2486, 12314, 2494, 12314, 2490, 14526}, {14528, 14538, 14546, 14554, 14562, 14570, 14577, 14585, 14593, 14600, 14606, 14613, 0}, {14528, 14538, 14546, 14554, 14562, 14570, 14577, 14585, 14593, 14600, 14606, 14613, 0}, {14621, 14625, 2588, 14629, 4910, 14633, 14637, 14641, 14645, 14649, 14653, 14657, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {1837,1328,0,0,0,0,0,0,0,0,0,0,0,0},{14394,0,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{1420,307,1428,0,0,0,0,0,0}},
+       {14099, 2670, 307, 301, 2005, 55, 14661, 14682, {14699, 430, 451, 8443, 14712, 14729, 14740}, {14753, 14761, 14769, 14775, 14783, 14791, 14799}, {555, 558, 561, 564, 567, 558, 564}, {14807, 583, 600, 609, 14822, 14829, 14838, 641, 654, 673, 690, 705, 0}, {14807, 583, 600, 609, 14822, 14829, 14838, 641, 654, 673, 690, 705, 0}, {14847, 14855, 14863, 738, 14822, 14871, 14879, 746, 754, 764, 772, 14887, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,1328,0,0,0,0,0,0,0,0,0,0,0},{14099,0,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 0, 0, {14899, 14906, 14917, 14926, 14935, 14942, 14953}, {14963, 14967, 14971, 14975, 14979, 14982, 14986}, {0, 0, 0, 0, 0, 0, 0}, {14990, 15000, 15009, 15017, 15026, 15039, 15051, 15058, 15065, 15072, 15082, 15094, 0}, {14990, 15000, 15009, 15017, 15026, 15039, 15051, 15058, 15065, 15072, 15082, 15094, 0}, {15107, 15111, 15115, 15119, 15123, 15127, 15131, 15135, 15139, 15143, 15147, 15151, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 0, 0, {15155, 15160, 15166, 15176, 15188, 15196, 15207}, {15216, 15220, 15224, 15228, 15232, 15236, 15240}, {0, 0, 0, 0, 0, 0, 0}, {15244, 15254, 15264, 15271, 15278, 2808, 15283, 15290, 15297, 15306, 15314, 15322, 0}, {15244, 15254, 15264, 15271, 15278, 2808, 15283, 15290, 15297, 15306, 15314, 15322, 0}, {2861, 2865, 14986, 15330, 15334, 2878, 2882, 15338, 2890, 2894, 2898, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 3804, 3807, {15346, 15352, 15363, 15176, 15373, 15196, 15207}, {15382, 15386, 15390, 15228, 15232, 15236, 15240}, {2113, 2486, 15394, 2488, 2113, 5718, 2486}, {15396, 15406, 15417, 15424, 15433, 15439, 15445, 15453, 15461, 15472, 15482, 15491, 0}, {15500, 15254, 15509, 15515, 15278, 2808, 15283, 15290, 15522, 15306, 15314, 15322, 0}, {2861, 2865, 15532, 2874, 15334, 2878, 2882, 15338, 2890, 2894, 2898, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 15536, 15540, {15544, 15551, 15559, 15567, 15576, 15586, 15593}, {2754, 8226, 2760, 15602, 2766, 15605, 2772}, {2113, 2486, 2775, 3895, 2775, 4157, 2113}, {15608, 15617, 15627, 2798, 10531, 15633, 15639, 15645, 2825, 2835, 2843, 10543, 0}, {15608, 15617, 15627, 2798, 10531, 15633, 15639, 15645, 2825, 2835, 2843, 10543, 0}, {2861, 2865, 3951, 2874, 10531, 2878, 2882, 2886, 2890, 2894, 2898, 10556, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,15654,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {15666, 2670, 1420, 1404, 2005, 15698, 15704, 15720, {15742, 15758, 15783, 15811, 15839, 15867, 15895}, {15914, 15924, 15934, 15944, 15954, 15964, 15974}, {15984, 15988, 15992, 15988, 15996, 16000, 16004}, {16008, 16030, 16058, 16074, 16093, 16109, 16128, 16144, 16166, 16197, 16225, 16250, 0}, {16008, 16030, 16058, 16074, 16093, 16109, 16128, 16144, 16166, 16197, 16225, 16250, 0}, {16278, 16288, 16298, 16308, 16318, 16328, 16338, 16348, 16358, 16368, 16378, 16388, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{15666,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 2374, 307, 301, 2005, 2385, 16398, 16403, {5913, 16408, 16419, 16429, 16439, 16449, 16463}, {5999, 6003, 16475, 16480, 16484, 16489, 16494}, {2113, 2486, 2488, 2486, 5718, 2492, 2494}, {2496, 2503, 4899, 6055, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2496, 2503, 4899, 6055, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2580, 2584, 2588, 2592, 4910, 2596, 2600, 2604, 2608, 2612, 2616, 6129, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {2374,1354,1328,0,0,0,0,0,0,0,0,0,0,0},{1983,0,0,0,0,0,0,0},{301,5006,0,0,0,0,0,0,0,0,0,0},{307,6460,0,0,0,0,0,0,0}},
+       {5510, 2374, 307, 301, 44, 55, 16498, 16526, {16548, 16567, 16586, 16608, 16627, 16661, 16686}, {16705, 16716, 16727, 16741, 16752, 16763, 16780}, {16791, 16795, 16802, 16809, 16816, 16823, 16830}, {16834, 16850, 16866, 16882, 16901, 16908, 16918, 16934, 16950, 16972, 16994, 17013, 0}, {16834, 16850, 16866, 16882, 16901, 16908, 16918, 16934, 16950, 16972, 16994, 17013, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,2335,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {17035, 270, 307, 301, 2005, 17059, 17072, 17075, {17078, 17087, 17096, 17106, 17116, 17126, 17138}, {17146, 17151, 17155, 17159, 17163, 17168, 17173}, {17177, 2488, 2488, 9676, 17177, 17180, 2113}, {17183, 17190, 17195, 2798, 17201, 17207, 17214, 17220, 17228, 17238, 17246, 17255, 0}, {17183, 17190, 17195, 2798, 17201, 17207, 17214, 17220, 17228, 17238, 17246, 17255, 0}, {2861, 17265, 3951, 2874, 17269, 17273, 17278, 17282, 17286, 17290, 2898, 17294, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,1328,17299,7079,3010,0,0,0,0,0,0,0,0,0},{17035,17308,9937,0,0,0,0,0},{301,3030,1404,35,0,0,0,0,0,0,0,0},{307,3019,1420,23,0,0,0,0,0}},
+       {17326, 2670, 307, 301, 2005, 17344, 17358, 17363, {17368, 17380, 17391, 17405, 17417, 17427, 17437}, {17448, 17453, 17458, 17463, 17468, 17473, 17478}, {2113, 4157, 2486, 6251, 2775, 15394, 2494}, {17483, 17500, 17513, 17527, 17540, 17553, 17566, 17580, 17592, 17606, 17620, 17634, 0}, {17483, 17500, 17513, 17527, 17540, 17553, 17566, 17580, 17592, 17606, 17620, 17634, 0}, {17647, 17654, 17659, 17664, 17668, 17673, 17678, 17683, 17688, 17695, 17700, 17706, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,2926,1328,0,0,0,0,0,0,0,0,0,0},{17326,0,0,0,0,0,0,0},{301,1404,5006,0,0,0,0,0,0,0,0,0},{307,1420,6460,0,0,0,0,0,0}},
+       {3755, 270, 307, 301, 2005, 55, 973, 978, {17711, 17725, 17735, 17746, 17760, 17771, 17782}, {17795, 17800, 17805, 17812, 17818, 17824, 17830}, {2775, 2494, 2486, 7409, 2775, 12314, 2113}, {17835, 17843, 17851, 17858, 17867, 17877, 17887, 17893, 17901, 17916, 17934, 17942, 0}, {17835, 17843, 17851, 17858, 17867, 17877, 17887, 17893, 17901, 17916, 17934, 17942, 0}, {17950, 17954, 17851, 17960, 17964, 17969, 17887, 17975, 17980, 17987, 17994, 17999, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1347,2926,1328,0,0,0,0,0,0,0,0,0},{3755,5510,9937,9926,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {5510, 270, 1420, 1404, 2005, 55, 18004, 18007, {18011, 18016, 10448, 10455, 18022, 18029, 10472}, {18036, 18040, 10486, 10490, 18044, 10498, 10502}, {12314, 14526, 2113, 10506, 4442, 4155, 2113}, {10508, 10516, 18048, 2798, 10531, 2878, 18052, 18058, 2825, 2835, 2843, 18063, 0}, {10508, 10516, 18048, 2798, 10531, 2878, 18052, 18058, 2825, 2835, 2843, 18063, 0}, {2861, 2865, 18048, 2874, 10531, 2878, 2882, 18058, 2890, 2894, 2898, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {18072, 2670, 1420, 1404, 2005, 4788, 0, 0, {18090, 18105, 18122, 18139, 18154, 18171, 18180}, {18191, 18197, 18203, 18209, 18215, 18221, 18227}, {239, 0, 0, 245, 247, 249, 251}, {18233, 18246, 18257, 18270, 18281, 18292, 18305, 18316, 18327, 18344, 18355, 18368, 0}, {18233, 18387, 18257, 18270, 18281, 18292, 18305, 18316, 18327, 18344, 18355, 18368, 0}, {18398, 18406, 18414, 18422, 18430, 18438, 18446, 18454, 18462, 18470, 18478, 18486, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{18072,18496,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {18515, 1363, 1420, 1404, 18535, 4788, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1363,1328,0,0,0,0,0,0,0,0,0,0,0,0},{18515,0,0,0,0,0,0,0},{1404,0,0,0,0,0,0,0,0,0,0,0},{1420,0,0,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 18551, 18559, {18567, 18576, 18585, 18593, 18602, 18611, 18618}, {18627, 18630, 18633, 18636, 18639, 18643, 18646}, {241, 243, 245, 247, 12314, 14526, 239}, {10508, 10516, 18649, 18655, 10531, 2808, 18052, 18662, 15297, 18669, 15314, 18676, 0}, {10508, 10516, 18649, 18655, 10531, 2808, 18052, 18662, 15297, 18669, 15314, 18676, 0}, {2861, 2865, 18048, 2874, 10531, 2878, 2882, 18684, 2890, 2894, 2898, 10556, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {18688, 18706, 307, 301, 2005, 18717, 0, 0, {18724, 18739, 18754, 18769, 18786, 18803, 18812}, {18823, 18830, 18837, 18844, 18851, 18858, 18865}, {18872, 18875, 8540, 8543, 8537, 18878, 18881}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12864, 12871, 12878, 12885, 8596, 12798, 12805, 12892, 12899, 12906, 12913, 12920, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {18706,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{18688,3755,5510,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {5510, 1354, 6460, 5006, 44, 55, 18884, 18912, {18934, 18953, 18972, 18997, 19016, 19050, 19075}, {19094, 19104, 19114, 19130, 19140, 19165, 19181}, {19191, 19195, 19202, 19206, 19213, 19220, 19227}, {19231, 19259, 19293, 19309, 19328, 19335, 19345, 19361, 19377, 19408, 19430, 19452, 0}, {19231, 19259, 19293, 19309, 19328, 19335, 19345, 19361, 19377, 19408, 19430, 19452, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{5006,2350,19477,19486,0,0,0,0,0,0,0,0},{6460,2366,19494,19506,0,0,0,0,0}},
+       {10007, 1354, 1971, 1951, 44, 55, 19517, 19549, {19581, 19597, 19616, 19638, 19657, 19676, 19704}, {19732, 19740, 19751, 19765, 19776, 19787, 19804}, {19818, 19822, 19829, 19836, 19846, 19853, 19866}, {19873, 19889, 19908, 19921, 19940, 19947, 19957, 19973, 19986, 20002, 20021, 20037, 0}, {19873, 19889, 19908, 19921, 19940, 19947, 19957, 19973, 19986, 20002, 20021, 20037, 0}, {239, 241, 243, 245, 19940, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{10007,3755,0,0,0,0,0,0},{1951,1943,1404,301,0,0,0,0,0,0,0,0},{1971,1960,1420,307,0,0,0,0,0}},
+       {5510, 1354, 307, 301, 44, 55, 20053, 20094, {20135, 20154, 20173, 20195, 20214, 20236, 20261}, {20280, 20290, 20300, 20313, 20323, 20336, 20352}, {20362, 20366, 20373, 20380, 20387, 20394, 20401}, {20405, 20433, 20461, 20477, 20496, 20503, 20513, 20529, 20545, 20573, 20595, 20617, 0}, {20405, 20433, 20461, 20477, 20496, 20503, 20513, 20529, 20545, 20573, 20595, 20617, 0}, {20642, 20661, 20461, 20477, 20496, 20503, 20513, 20529, 20680, 20696, 20712, 20722, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 1354, 307, 301, 44, 55, 7860, 20735, {20738, 20757, 20776, 20801, 20820, 20842, 20867}, {20886, 20896, 20906, 20922, 20932, 20945, 20961}, {20971, 20975, 20982, 20986, 20993, 21000, 21007}, {21011, 21033, 21064, 21086, 21105, 21112, 21122, 21138, 21154, 21185, 21207, 21229, 0}, {21011, 21033, 21064, 21086, 21105, 21112, 21122, 21138, 21154, 21185, 21207, 21229, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 2374, 307, 301, 2005, 55, 21254, 21279, {21304, 21323, 21345, 21370, 21386, 21408, 21427}, {21437, 21444, 21451, 21458, 21465, 21472, 21479}, {21437, 21444, 21451, 21458, 21465, 21472, 21479}, {21483, 21499, 21524, 21543, 21562, 21569, 21582, 21595, 21614, 21645, 21670, 21692, 0}, {21483, 21499, 21524, 21543, 21562, 21569, 21582, 21717, 21614, 21645, 21670, 21692, 0}, {21736, 21744, 21758, 21772, 21562, 21569, 21582, 21783, 21791, 21805, 21816, 21824, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,2335,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 1354, 307, 301, 44, 55, 21835, 21866, {21891, 21913, 21935, 21960, 21982, 22007, 22035}, {22057, 22067, 22077, 22090, 22100, 22113, 22129}, {22139, 22143, 22150, 22154, 22161, 22168, 22175}, {22179, 22195, 22220, 22239, 22261, 22268, 22281, 22294, 22313, 22344, 22369, 22388, 0}, {22179, 22195, 22220, 22239, 22261, 22268, 22281, 22294, 22313, 22344, 22369, 22388, 0}, {22413, 22420, 243, 22436, 22261, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 1354, 307, 301, 44, 55, 3804, 3807, {22452, 22471, 22490, 22512, 22531, 22553, 22578}, {22597, 22602, 22610, 22618, 22626, 22634, 22642}, {22653, 22657, 22664, 22671, 22678, 22685, 22692}, {22696, 22712, 22737, 22756, 22778, 22785, 22798, 22811, 22830, 22858, 22883, 22905, 0}, {22696, 22712, 22737, 22756, 22778, 22785, 22798, 22811, 22830, 22858, 22883, 22905, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 1354, 6460, 5006, 44, 55, 22930, 22949, {22980, 23005, 23036, 23064, 23089, 23117, 23151}, {23176, 23195, 23220, 23236, 23255, 23274, 23293}, {23303, 23310, 23317, 23324, 23331, 23344, 23351}, {23355, 23374, 23402, 23430, 23455, 23468, 23484, 23497, 23522, 23559, 23587, 23609, 0}, {23355, 23374, 23402, 23430, 23455, 23468, 23484, 23497, 23522, 23559, 23587, 23609, 0}, {23634, 23644, 23663, 23679, 23455, 23468, 23484, 23695, 23702, 23727, 23743, 23753, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{5006,2350,19477,19486,0,0,0,0,0,0,0,0},{6460,2366,19494,19506,0,0,0,0,0}},
+       {23766, 2374, 1960, 1943, 23785, 55, 23793, 23821, {23843, 23862, 23881, 23906, 23925, 23959, 23984}, {24003, 19104, 19114, 19130, 24013, 24038, 19181}, {0, 0, 0, 0, 0, 0, 0}, {24054, 24079, 24110, 24126, 19328, 19335, 19345, 24145, 24161, 24192, 24214, 24236, 0}, {24054, 24079, 24110, 24126, 19328, 19335, 19345, 24145, 24161, 24192, 24214, 24236, 0}, {24261, 24274, 24110, 24126, 19328, 19335, 19345, 24293, 24300, 24316, 24332, 24342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,0,0,0,0,0,0,0,0,0,0,0,0,0},{23766,0,0,0,0,0,0,0},{1943,1951,0,0,0,0,0,0,0,0,0,0},{1960,1971,0,0,0,0,0,0,0}},
+       {5510, 2374, 307, 301, 44, 55, 3804, 3807, {16548, 16567, 24355, 16608, 24377, 16661, 16686}, {24399, 24409, 24419, 24432, 24442, 24455, 24471}, {16791, 16795, 16802, 16809, 16816, 16823, 16830}, {24481, 24506, 16866, 24537, 24556, 16908, 24563, 24576, 24592, 24617, 24639, 24667, 0}, {24481, 24506, 16866, 24537, 24556, 16908, 24563, 24576, 24592, 24617, 24639, 24667, 0}, {24689, 24702, 16866, 24721, 24556, 16908, 24563, 24737, 24744, 257, 24766, 24788, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,2335,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {24804, 24825, 1420, 1404, 24834, 4788, 0, 0, {24851, 24858, 24869, 24882, 24895, 24906, 24919}, {24930, 24935, 24940, 24945, 24950, 24955, 24960}, {0, 0, 0, 0, 0, 0, 0}, {24965, 24980, 24989, 24996, 25009, 25016, 25027, 25036, 25045, 25052, 25063, 25074, 0}, {24965, 24980, 24989, 24996, 25009, 25016, 25027, 25036, 25045, 25052, 25063, 25074, 0}, {25085, 25092, 25099, 25106, 25113, 25120, 25127, 25134, 25141, 25148, 25155, 25162, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 790, 268, {24825,1328,0,0,0,0,0,0,0,0,0,0,0,0},{24804,0,0,0,0,0,0,0},{1404,0,0,0,0,0,0,0,0,0,0,0},{1420,0,0,0,0,0,0,0,0}},
+       {25169, 1467, 307, 301, 25212, 25219, 25245, 25267, {25292, 25320, 25348, 25385, 25416, 25450, 25475}, {25509, 25525, 25541, 25566, 25585, 25607, 25626}, {25648, 25655, 25662, 25669, 25676, 25683, 25687}, {25697, 25731, 25768, 25802, 25836, 25867, 25904, 25941, 25981, 26015, 26049, 26098, 0}, {25697, 25731, 25768, 25802, 25836, 25867, 25904, 25941, 25981, 26015, 26049, 26098, 0}, {26147, 26160, 26173, 26186, 26199, 26212, 26225, 26238, 26251, 26264, 26280, 26296, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1848,1328,1837,1859,1866,1873,0,0,0,0,0},{25169,26312,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {5510, 270, 307, 301, 2005, 55, 0, 0, {26360, 26369, 26379, 26391, 26404, 26413, 26425}, {26437, 26441, 26446, 26450, 26454, 26458, 26462}, {2113, 2494, 2486, 2486, 14526, 6251, 2113}, {26466, 26473, 26482, 26489, 2804, 26496, 26504, 26515, 26520, 26525, 26532, 26541, 0}, {26466, 26473, 26482, 26489, 2804, 26496, 26549, 26515, 26520, 26525, 26532, 26541, 0}, {26559, 26563, 26446, 26568, 2804, 26572, 26576, 26515, 26520, 26580, 26584, 26589, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 0, 266, 268, {270,14,1347,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,35,3030,0,0,0,0,0,0,0,0},{307,1420,23,3019,0,0,0,0,0}},
+       {3755, 1328, 307, 26594, 26602, 26637, 26673, 26689, {26705, 26739, 26770, 26801, 26823, 26866, 26894}, {26919, 26926, 26930, 26934, 26941, 26951, 26958}, {0, 0, 0, 0, 0, 0, 0}, {26962, 26975, 26994, 27007, 27020, 27033, 27052, 27071, 27084, 27100, 27113, 27138, 0}, {26962, 26975, 26994, 27007, 27020, 27033, 27052, 27071, 27084, 27100, 27113, 27138, 0}, {27151, 27155, 27159, 27163, 27167, 27171, 27175, 27179, 27183, 27187, 27194, 27201, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1328,0,0,0,0,0,0,0,0,0,0,0,0,0},{3755,9949,0,0,0,0,0,0},{26594,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {5510, 270, 307, 26594, 2005, 55, 27208, 27233, {27258, 27283, 27302, 27330, 27349, 27374, 27393}, {27415, 27423, 27428, 27433, 27438, 27446, 27454}, {0, 0, 0, 0, 0, 0, 0}, {27459, 27478, 27494, 27507, 27520, 27542, 27561, 27583, 27599, 27615, 27628, 27644, 0}, {27459, 27478, 27494, 27507, 27520, 27542, 27561, 27583, 27599, 27615, 27628, 27644, 0}, {27660, 27669, 27678, 27690, 27700, 27709, 27721, 27730, 27739, 27748, 27757, 27766, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,1328,0,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{26594,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {4028, 270, 1420, 1404, 4057, 55, 973, 978, {27775, 27783, 27788, 27795, 27805, 27811, 27818}, {27826, 27830, 3951, 27834, 27839, 27843, 27847}, {2775, 2494, 2486, 2486, 4153, 4157, 2113}, {27852, 27860, 6270, 27869, 27875, 27880, 27886, 6304, 27892, 27901, 27909, 27918, 0}, {27852, 27860, 6270, 27869, 27875, 27880, 27886, 6304, 27892, 27901, 27909, 27918, 0}, {27927, 2865, 3951, 27931, 2804, 27935, 27940, 18684, 17286, 27944, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1339,1347,1354,1363,1328,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{1404,301,35,1409,0,0,0,0,0,0,0,0},{1420,307,23,1428,0,0,0,0,0}},
+       {5510, 2374, 307, 301, 44, 55, 27948, 27960, {27972, 16567, 28000, 16608, 24377, 16661, 16686}, {24399, 24409, 24419, 24432, 24442, 24455, 24471}, {0, 0, 0, 0, 0, 0, 0}, {24481, 24506, 16866, 24537, 24556, 16908, 24563, 28019, 28035, 28063, 24639, 24667, 0}, {24481, 24506, 16866, 24537, 24556, 16908, 24563, 28019, 28035, 28063, 24639, 24667, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,2335,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {28085, 1328, 3019, 3030, 28133, 3796, 28143, 28155, {28164, 28180, 28196, 28224, 28240, 28283, 28308}, {28336, 28346, 28356, 28363, 28373, 28389, 28402}, {28412, 28416, 28420, 28424, 28428, 28441, 28448}, {28455, 28474, 28499, 28518, 28543, 28556, 28569, 28582, 28604, 28638, 28663, 28691, 0}, {28455, 28474, 28499, 28518, 28543, 28556, 28569, 28582, 28604, 28638, 28663, 28691, 0}, {28719, 28726, 28736, 28518, 28543, 28556, 28569, 28749, 28759, 28772, 28782, 28795, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 2624, 268, {1328,1837,1880,270,14,0,0,0,0,0,0,0,0,0},{28085,0,0,0,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {28808, 3010, 3019, 3030, 2005, 28840, 28854, 28864, {28877, 28887, 28894, 28907, 28917, 28927, 28937}, {28877, 28887, 28947, 28907, 28917, 28927, 28937}, {28957, 28961, 28965, 28969, 28973, 28977, 28981}, {28985, 29001, 29017, 29027, 29040, 29047, 29054, 29064, 29077, 29096, 29115, 29131, 0}, {28985, 29001, 29017, 29027, 29040, 29047, 29054, 29064, 29077, 29096, 29115, 29131, 0}, {29147, 29157, 29017, 29167, 29040, 29047, 29054, 29177, 29187, 29197, 29207, 29217, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1328,0,0,0,0,0,0,0,0,0,0,0,0},{28808,0,0,0,0,0,0,0},{3030,0,0,0,0,0,0,0,0,0,0,0},{3019,0,0,0,0,0,0,0,0}},
+       {4014, 2374, 1420, 1404, 44, 55, 29227, 29237, {29250, 29257, 29263, 29270, 29276, 29282, 29290}, {29300, 29304, 29308, 29312, 29316, 29320, 29324}, {12314, 12314, 12314, 12314, 12314, 12314, 12314}, {29330, 29339, 29348, 29353, 29359, 29365, 29371, 29378, 29384, 29393, 29402, 29410, 0}, {29330, 29339, 29348, 29353, 29359, 29365, 29371, 29378, 29384, 29393, 29402, 29410, 0}, {29419, 29423, 3951, 29427, 3920, 29431, 29435, 29439, 29444, 29448, 29454, 29458, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{1404,301,29462,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 29468, 3796, 29478, 29519, {29560, 29579, 29598, 29623, 29642, 29664, 29689}, {29708, 24409, 29718, 24432, 29734, 24455, 24471}, {29747, 29751, 29755, 29759, 29763, 29767, 29771}, {16834, 29775, 16866, 29803, 24556, 29822, 16918, 16934, 29832, 29863, 29885, 29910, 0}, {16834, 29775, 16866, 29803, 24556, 29822, 16918, 16934, 29832, 29863, 29885, 29910, 0}, {29935, 29942, 16866, 29952, 24556, 29822, 29968, 29981, 29988, 30004, 30020, 30033, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {270, 14, 3019, 3030, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {30046, 30053, 30062, 30077, 30088, 30097, 30104, 30111, 30118, 30129, 30142, 30155, 0}, {30046, 30053, 30062, 30077, 30088, 30097, 30104, 30111, 30118, 30129, 30142, 30155, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {14,270,0,0,0,0,0,0,0,0,0,0,0,0},{270,1,281,30160,0,0,0,0},{3030,1404,0,0,0,0,0,0,0,0,0,0},{3019,1420,0,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 3804, 3807, {30178, 30185, 27788, 30191, 30202, 30210, 30219}, {30226, 27830, 3951, 30230, 30234, 30238, 10502}, {2494, 2494, 2486, 2486, 5718, 15394, 2113}, {30242, 30248, 30256, 27869, 30262, 30267, 30273, 6304, 30279, 30289, 30297, 30307, 0}, {30242, 30248, 30256, 27869, 30262, 30267, 30273, 6304, 30279, 30289, 30297, 30307, 0}, {30317, 30321, 3951, 27931, 3920, 30325, 30329, 18684, 17286, 2894, 30333, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {3767, 3010, 3019, 3030, 44, 3796, 0, 0, {30337, 30344, 30352, 30359, 30366, 30374, 30382}, {30389, 30392, 30395, 30398, 30401, 30404, 30407}, {2494, 2494, 2488, 2494, 12314, 4155, 12314}, {30410, 30418, 30428, 30434, 30442, 30447, 30452, 30457, 30464, 18669, 30472, 30480, 0}, {30410, 30418, 30428, 30434, 30442, 30447, 30452, 30457, 30464, 18669, 30472, 30480, 0}, {2861, 30488, 3951, 30492, 3920, 29431, 29435, 30496, 3891, 2894, 30500, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,270,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {3767, 3010, 3019, 3030, 44, 3796, 30504, 30515, {30525, 30543, 30558, 30580, 30593, 30607, 30624}, {30648, 30656, 30661, 30580, 30593, 30673, 30680}, {0, 0, 0, 0, 0, 0, 0}, {30694, 30716, 30732, 30752, 30766, 30783, 30798, 30815, 30829, 30842, 30861, 30875, 0}, {30694, 30716, 30732, 30752, 30766, 30783, 30798, 30815, 30829, 30842, 30861, 30875, 0}, {30894, 30909, 30918, 30931, 30938, 30948, 30956, 30966, 30973, 30979, 30991, 30998, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,270,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 0, 0, {31010, 31018, 14917, 14926, 14935, 31029, 31039}, {15382, 14967, 14971, 14975, 14979, 15236, 31048}, {0, 0, 0, 0, 0, 0, 0}, {31052, 31061, 31071, 31079, 10531, 3924, 31087, 31093, 31102, 31111, 31120, 31129, 0}, {31052, 31061, 31071, 31079, 10531, 3924, 31087, 31093, 31102, 31111, 31120, 31129, 0}, {2861, 2865, 14986, 31138, 10531, 2878, 2882, 18684, 17286, 2894, 31142, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {1983, 2374, 307, 301, 2005, 2385, 31146, 31151, {31156, 31163, 31178, 31192, 31208, 31223, 31239}, {6247, 31254, 2588, 31258, 31262, 31266, 31270}, {2113, 12314, 2486, 2108, 2113, 2488, 12314}, {7167, 7175, 31274, 31281, 31288, 2527, 2532, 31293, 31303, 31314, 31323, 31333, 0}, {7167, 7175, 31274, 31281, 31288, 2527, 2532, 31293, 31303, 31314, 31323, 31333, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,1328,2626,0,0,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {3767, 3010, 3019, 3030, 44, 3796, 31343, 31348, {31353, 31369, 31377, 31385, 31394, 31406, 31416}, {31426, 31432, 31438, 31442, 31446, 31454, 3891}, {0, 0, 0, 0, 0, 0, 0}, {31461, 31474, 31488, 31497, 31503, 31507, 31512, 31520, 15297, 31533, 15314, 15322, 0}, {31461, 31474, 31488, 31497, 31503, 31507, 31512, 31520, 15297, 31533, 15314, 15322, 0}, {31542, 2865, 31546, 15330, 31503, 31550, 2882, 31554, 2890, 31562, 2898, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,270,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {31568, 1467, 1420, 1943, 31592, 31609, 31623, 31630, {31637, 31647, 31657, 31667, 31677, 31687, 31697}, {31707, 31714, 31721, 31728, 31735, 31742, 31749}, {31756, 31760, 31764, 31768, 31772, 31776, 31780}, {31784, 31791, 31798, 31805, 31812, 31819, 31826, 31833, 31840, 31847, 31854, 31864, 0}, {31784, 31791, 31798, 31805, 31812, 31819, 31826, 31833, 31840, 31847, 31854, 31864, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1848,1328,1837,0,0,0,0,0,0,0,0},{31568,31874,31904,0,0,0,0,0},{1943,1404,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4771, 270, 307, 301, 2005, 4788, 0, 0, {26437, 27830, 31934, 31941, 31951, 31956, 31963}, {31970, 4131, 31974, 4862, 31979, 31984, 31989}, {4421, 31994, 31997, 32000, 32003, 32006, 32009}, {32012, 32019, 31934, 32030, 32036, 32040, 32049, 32056, 32061, 32070, 8220, 32075, 0}, {32012, 32019, 31934, 32030, 32036, 32040, 32049, 32056, 32061, 32070, 8220, 32075, 0}, {32081, 32085, 32092, 26568, 32036, 32097, 32102, 32056, 32107, 32070, 8220, 32112, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1363,1354,1328,0,0,0,0,0,0,0,0,0},{4771,4997,3755,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {32116, 270, 307, 301, 2005, 4788, 0, 0, {32144, 32152, 32159, 32167, 32177, 32185, 1034}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {32196, 32204, 1091, 1097, 4910, 32213, 32218, 1120, 1126, 32225, 1143, 32234, 0}, {32196, 32204, 1091, 1097, 4910, 32213, 32218, 1120, 1126, 32225, 1143, 32234, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1363,1354,1328,0,0,0,0,0,0,0,0,0},{32116,0,0,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {4771, 270, 307, 301, 2005, 4788, 32243, 32248, {32253, 32261, 32271, 32281, 32290, 32300, 32308}, {32318, 32322, 32327, 32331, 32335, 32339, 32343}, {2113, 2486, 2775, 2486, 2775, 2492, 2113}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 32347, 32356, 32367, 32376, 32386, 0}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 32347, 32356, 32367, 32376, 32386, 0}, {2861, 2865, 2869, 2874, 2804, 2878, 2882, 2886, 2890, 2894, 2898, 2902, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1363,1354,1328,0,0,0,0,0,0,0,0,0},{4771,4997,3755,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {32396, 32414, 1420, 1404, 32425, 3796, 32441, 32446, {32451, 32476, 32505, 32530, 32543, 32558, 32575}, {32590, 32595, 32600, 32605, 32610, 32615, 8529}, {32620, 32620, 32623, 8540, 8543, 32620, 8540}, {32626, 32645, 32660, 32682, 32702, 32718, 32734, 32748, 32774, 32798, 32815, 32832, 0}, {32626, 32645, 32660, 32682, 32702, 32718, 32734, 32748, 32774, 32798, 32815, 32832, 0}, {32849, 32858, 32867, 32881, 32895, 32907, 32919, 32929, 32945, 32959, 32966, 32973, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {32414,32980,2926,3970,32989,0,0,0,0,0,0,0,0,0},{32396,33000,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 0, 0, {33019, 33031, 33042, 33054, 33066, 33076, 33088}, {33103, 33108, 33113, 33118, 33123, 33128, 33133}, {0, 0, 0, 0, 0, 0, 0}, {33138, 33147, 33159, 33167, 33172, 33182, 33189, 33198, 33205, 33211, 33220, 33231, 0}, {33138, 33147, 33159, 33167, 33172, 33182, 33189, 33198, 33205, 33211, 33220, 33231, 0}, {33239, 33244, 33249, 33254, 33259, 33264, 33269, 33123, 33274, 33279, 33284, 33289, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {5510, 270, 307, 301, 2005, 55, 6031, 6036, {33294, 33307, 33315, 33324, 33334, 33344, 33353}, {33365, 33369, 33373, 33377, 33381, 33385, 33389}, {2775, 2494, 2486, 7409, 12314, 5718, 2113}, {33393, 33407, 33418, 33427, 33438, 33450, 33464, 33476, 33489, 33502, 33514, 33527, 0}, {33393, 33407, 33418, 33427, 33438, 33450, 33464, 33476, 33489, 33502, 33514, 33527, 0}, {33541, 33546, 33552, 33558, 33563, 33569, 33575, 33580, 33586, 33591, 17994, 33597, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 0, 266, 268, {270,14,1347,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,35,3030,0,0,0,0,0,0,0,0},{307,1420,23,3019,0,0,0,0,0}},
+       {1, 14, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {14,270,0,0,0,0,0,0,0,0,0,0,0,0},{1,281,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {316, 335, 350, 365, 377, 55, 393, 405, {417, 430, 451, 466, 477, 496, 507}, {520, 525, 530, 535, 540, 545, 550}, {555, 558, 561, 564, 567, 558, 564}, {570, 583, 600, 609, 620, 627, 634, 641, 654, 673, 690, 705, 0}, {570, 583, 600, 609, 620, 627, 634, 641, 654, 673, 690, 705, 0}, {722, 728, 600, 738, 620, 627, 634, 746, 754, 764, 772, 782, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {335,792,808,824,0,0,0,0,0,0,0,0,0,0},{316,841,859,884,0,0,0,0},{365,908,0,0,0,0,0,0,0,0,0,0},{350,919,0,0,0,0,0,0,0}},
+       {933, 270, 307, 301, 959, 55, 973, 978, {983, 992, 1000, 1008, 1017, 1024, 1034}, {1043, 1046, 1049, 1052, 1055, 1058, 1061}, {1064, 1066, 1068, 1070, 1072, 1074, 1076}, {1078, 1084, 1091, 1097, 1103, 1108, 1113, 1120, 1126, 1135, 1143, 1152, 0}, {1161, 1170, 1180, 1189, 1199, 1207, 1215, 1225, 1235, 1247, 1259, 1271, 0}, {1283, 1288, 1091, 1294, 1103, 1108, 1299, 1304, 1308, 1313, 1318, 1323, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1328,1339,1347,1354,1363,0,0,0,0,0,0,0},{933,1372,1388,0,0,0,0,0},{301,1404,1409,0,0,0,0,0,0,0,0,0},{307,1420,1428,0,0,0,0,0,0}},
+       {1445, 1467, 1971, 1951, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {33603, 33610, 33617, 33624, 33631, 33638, 33645}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1837,1328,0,0,0,0,0,0,0,0,0,0,0},{1445,6634,0,0,0,0,0,0},{1951,1943,301,1404,0,0,0,0,0,0,0,0},{1971,1960,307,1420,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 55, 2015, 2020, {2025, 2033, 2043, 2051, 2059, 2068, 2075}, {2082, 2085, 2088, 2092, 2095, 2099, 2103}, {2106, 2108, 2110, 2113, 2115, 2108, 2113}, {2118, 2124, 2130, 2138, 2144, 2152, 2160, 2170, 2176, 2184, 2192, 2201, 0}, {2210, 2216, 2223, 2231, 2237, 2245, 2253, 2263, 2176, 2269, 2277, 2287, 0}, {2296, 2299, 2302, 2305, 2308, 2311, 2314, 2317, 2320, 2323, 2327, 2331, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1996,2335,1328,1819,1859,0,0,0,0,0,0,0,0,0},{1983,0,0,0,0,0,0,0},{1404,301,2342,2350,0,0,0,0,0,0,0,0},{1420,307,2355,2366,0,0,0,0,0}},
+       {1983, 2374, 307, 301, 2005, 2385, 2393, 2398, {2403, 2411, 2418, 2426, 2433, 2441, 2448}, {2456, 2461, 2465, 2469, 2473, 2477, 2481}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {2496, 2503, 2511, 2517, 2523, 2527, 2532, 2537, 2544, 2554, 2562, 2571, 0}, {2496, 2503, 2511, 2517, 2523, 2527, 2532, 2537, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {2374,1354,1328,2626,0,0,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {2651, 2670, 307, 301, 2005, 55, 2681, 2687, {2694, 2702, 2709, 2718, 2727, 2738, 2746}, {2754, 2757, 2760, 2763, 2766, 2769, 2772}, {2113, 2486, 2775, 2486, 2775, 2492, 2113}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2861, 2865, 2869, 2874, 2804, 2878, 2882, 2886, 2890, 2894, 2898, 2902, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,2906,1363,2918,2926,1996,1328,0,0,0,0,0,0,0},{2651,1983,2933,0,0,0,0,0},{301,1404,2350,2945,0,0,0,0,0,0,0,0},{307,2956,2970,2985,0,0,0,0,0}},
+       {2992, 3010, 3019, 3030, 2005, 55, 3038, 3045, {3052, 3067, 3082, 3093, 3108, 3121, 3140}, {3155, 3162, 3169, 3176, 3183, 3190, 3197}, {3204, 3207, 3210, 3210, 3213, 3213, 3216}, {3219, 3240, 3263, 3278, 3295, 3306, 3321, 3336, 3355, 3378, 3397, 3416, 0}, {3437, 3458, 3481, 3496, 3513, 3524, 3539, 3554, 3573, 3596, 3615, 3634, 0}, {3655, 3662, 3669, 3676, 3683, 3690, 3699, 3708, 3715, 3722, 3729, 3736, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {3010,270,1347,14,3743,1328,0,0,0,0,0,0,0,0},{2992,3755,0,0,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {4303, 1996, 1420, 1404, 2005, 4320, 4332, 4336, {4340, 4352, 4364, 4374, 4388, 4398, 4410}, {4421, 4424, 4427, 4430, 4433, 4436, 4439}, {2113, 2486, 2488, 4442, 2488, 2108, 2494}, {4444, 4453, 4462, 4472, 4481, 4490, 4499, 4509, 4516, 4524, 4532, 4542, 0}, {4551, 4562, 4573, 4585, 4596, 4607, 4618, 4630, 4639, 4649, 4659, 4671, 0}, {4682, 4688, 4694, 4701, 4707, 4713, 4719, 4726, 4730, 4735, 4740, 4747, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1996,2670,2926,1328,0,0,0,0,0,0,0,0,0,0},{4303,4753,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4771, 270, 307, 301, 2005, 4788, 3804, 3807, {4795, 4804, 4810, 4816, 4825, 4831, 4840}, {4847, 4852, 4857, 4862, 4867, 4872, 4877}, {2775, 2494, 2486, 2486, 4155, 4157, 2113}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4961, 4967, 4899, 4974, 4910, 4914, 4979, 4927, 4985, 1313, 1318, 4991, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1363,1354,1328,0,0,0,0,0,0,0,0,0},{4771,4997,3755,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {5030, 270, 307, 301, 2005, 55, 5048, 5061, {5072, 5090, 5104, 5122, 5140, 5158, 5174}, {5188, 5200, 5212, 5224, 5236, 5248, 5260}, {5267, 5270, 5273, 5276, 5279, 5282, 5285}, {5288, 5299, 5312, 5319, 5330, 5337, 5346, 5355, 5368, 5381, 5396, 5409, 0}, {5288, 5299, 5312, 5319, 5330, 5337, 5346, 5355, 5368, 5381, 5396, 5409, 0}, {5420, 5429, 5312, 5438, 5330, 5447, 5456, 5465, 5474, 5483, 5492, 5501, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,5510,14,1,1354,2374,5523,1328,5536,5553,0,0,0,0},{5030,5510,5563,5585,5536,0,0,0},{301,35,0,0,0,0,0,0,0,0,0,0},{307,23,0,0,0,0,0,0,0}},
+       {5606, 5620, 1420, 1404, 5632, 5643, 5651, 5655, {5659, 5669, 5677, 5682, 5689, 5702, 5710}, {4157, 5718, 4442, 5720, 5724, 2108, 5727}, {4157, 5718, 4442, 5731, 5724, 2108, 5731}, {5734, 5742, 5751, 5760, 5769, 5776, 5784, 5792, 5802, 5813, 2562, 2571, 0}, {5734, 5742, 5751, 5760, 5769, 5776, 5784, 5792, 5802, 5813, 2562, 2571, 0}, {5822, 1288, 5827, 5834, 5840, 5846, 5852, 5858, 5863, 5870, 1318, 5875, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {5620,5880,1328,5894,0,0,0,0,0,0,0,0,0,0},{5606,0,0,0,0,0,0,0},{1404,301,3030,0,0,0,0,0,0,0,0,0},{1420,307,3019,0,0,0,0,0,0}},
+       {1983, 1996, 307, 301, 2005, 2385, 5903, 5908, {5913, 5924, 5935, 5949, 5963, 5975, 5987}, {5999, 6003, 6008, 6013, 6018, 6022, 6027}, {1076, 6031, 6033, 6031, 6036, 6036, 1066}, {6038, 6046, 4899, 6055, 6062, 6067, 6074, 6081, 2544, 5813, 6089, 6099, 0}, {6038, 6046, 4899, 6055, 6062, 6067, 6074, 6081, 2544, 5813, 6089, 6099, 0}, {2580, 2584, 2588, 2592, 6062, 6108, 6113, 6118, 2608, 2612, 6124, 6129, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1996,1363,6133,6145,1328,6158,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {4771, 270, 307, 301, 2005, 55, 6167, 6170, {6173, 6182, 6190, 6199, 6210, 6219, 6228}, {4127, 4131, 2588, 6235, 6239, 6243, 6247}, {2775, 2494, 2486, 2486, 6251, 4157, 2113}, {6253, 6261, 6270, 6276, 6283, 6290, 6297, 6304, 6311, 6321, 6329, 6338, 0}, {6347, 6355, 4173, 6364, 6371, 6378, 6385, 4196, 6392, 6402, 1143, 6410, 0}, {6419, 2584, 2588, 2592, 6423, 6427, 6431, 4242, 6435, 6439, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,3743,14,6443,1347,1328,0,0,0,0,0,0,0,0},{4771,6451,3755,0,0,0,0,0},{301,1404,2350,5006,0,0,0,0,0,0,0,0},{307,2366,6460,0,0,0,0,0,0}},
+       {1445, 1837, 1420, 1404, 1476, 1492, 6469, 6476, {6483, 6493, 6503, 6513, 6523, 6533, 6543}, {1638, 6553, 6557, 6561, 6565, 6569, 6573}, {1638, 6553, 6557, 6561, 6565, 6569, 6573}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1866,1467,6577,6596,6613,1328,0,0,0,0,0,0},{1445,6634,6658,6685,0,0,0,0},{1404,301,1943,1951,0,0,0,0,0,0,0,0},{1420,307,1960,1971,0,0,0,0,0}},
+       {6714, 1328, 1960, 1943, 6743, 6760, 6774, 6781, {6788, 6798, 6808, 6818, 6828, 6838, 6848}, {6858, 6862, 6866, 6870, 6874, 6878, 6882}, {6858, 6862, 6866, 6870, 6874, 6878, 6882}, {6886, 6891, 6896, 6901, 6906, 6911, 6916, 6921, 6926, 6931, 6937, 6943, 0}, {6886, 6891, 6896, 6901, 6906, 6911, 6916, 6921, 6926, 6931, 6937, 6943, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1328,5894,1859,1819,0,0,0,0,0,0,0,0,0,0},{6714,6949,6973,7000,7022,7053,0,0},{1943,1951,1404,301,0,0,0,0,0,0,0,0},{1960,1971,1420,307,0,0,0,0,0}},
+       {4771, 7079, 1420, 1404, 2005, 55, 973, 978, {7088, 7095, 7103, 7111, 7120, 7130, 7138}, {7147, 4424, 7150, 7153, 7156, 7159, 7162}, {7165, 2486, 2775, 3895, 2775, 4157, 7165}, {7167, 7175, 7184, 2517, 7190, 2527, 2532, 7194, 2544, 2554, 2562, 2571, 0}, {7167, 7175, 7184, 2517, 7190, 2527, 2532, 7194, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 7203, 2592, 7190, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {7079,2335,1354,14,1363,2906,1328,0,0,0,0,0,0,0},{4771,6451,3755,4997,0,0,0,0},{1404,301,2350,7207,7219,0,0,0,0,0,0,0},{1420,307,7231,7246,0,0,0,0,0}},
+       {1983, 2670, 307, 301, 2005, 2385, 973, 978, {2403, 2411, 2418, 2426, 2433, 2441, 2448}, {7261, 7266, 7270, 7274, 7278, 7282, 7286}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2580, 2584, 2588, 2592, 4910, 2596, 2600, 2604, 2608, 2612, 2616, 6129, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,2926,1328,2906,0,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,7291,5006,0,0,0,0,0,0,0,0},{307,1420,7302,6460,0,0,0,0,0}},
+       {3755, 1328, 307, 301, 2005, 4788, 3804, 3807, {7316, 7326, 7340, 7347, 7354, 7363, 2075}, {7371, 7378, 7383, 7387, 7392, 7397, 7401}, {2106, 2108, 3895, 7406, 7409, 2108, 2113}, {7411, 7420, 7425, 7432, 2523, 7442, 7451, 7458, 7468, 7478, 2192, 7491, 0}, {7501, 7510, 7517, 7523, 7532, 7537, 7545, 7551, 7560, 7570, 7584, 7594, 0}, {7602, 7606, 2588, 7610, 2523, 7614, 7618, 7622, 7626, 7630, 7635, 7639, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {1328,5894,0,0,0,0,0,0,0,0,0,0,0,0},{3755,5510,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {7643, 270, 307, 301, 4057, 7671, 3804, 3807, {4072, 7684, 7698, 7711, 7724, 7737, 4119}, {4127, 7749, 7753, 7757, 7761, 7765, 4148}, {2775, 2113, 2488, 7769, 7769, 2113, 2113}, {7771, 7779, 7789, 1097, 7796, 7801, 7807, 4196, 7813, 7822, 7830, 7839, 0}, {7771, 7779, 7789, 1097, 7796, 7801, 7807, 4196, 7813, 7822, 7830, 7839, 0}, {2580, 7848, 2588, 4238, 4910, 2596, 2600, 4242, 6435, 7852, 2616, 7856, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,3010,1347,1354,2374,2335,7079,1363,2670,2906,2926,1996,1328},{7643,4281,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {2992, 270, 307, 301, 2005, 55, 7860, 7863, {7866, 7875, 4810, 7885, 7893, 7901, 7910}, {7916, 7919, 4424, 7923, 7926, 7930, 2103}, {2775, 6251, 2486, 2486, 6251, 4157, 2113}, {7933, 7941, 4899, 7948, 7955, 7960, 7970, 7978, 7984, 7994, 2562, 2571, 0}, {7933, 7941, 4899, 7948, 7955, 7960, 7970, 7978, 7984, 7994, 2562, 2571, 0}, {8002, 8009, 4899, 4974, 7955, 8015, 8022, 7978, 8027, 1313, 1318, 5875, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1339,8033,1347,270,1328,0,0,0,0,0,0,0},{2992,3755,4997,0,0,0,0,0},{301,1404,8041,8053,8064,8072,8082,8091,2945,8097,8105,8110},{307,1420,8113,8128,2970,2956,8142,8155,2985}},
+       {3755, 2670, 307, 301, 2005, 4788, 3804, 3807, {8167, 8177, 8182, 8189, 8198, 8202, 8209}, {8220, 8223, 8226, 2763, 8229, 8232, 8235}, {2775, 2494, 2486, 2486, 4155, 4157, 2113}, {8239, 8248, 8258, 8265, 4910, 8273, 8279, 2537, 8285, 8296, 8306, 8316, 0}, {8239, 8248, 8258, 8265, 4910, 8273, 8279, 2537, 8285, 8296, 8306, 8316, 0}, {8326, 8331, 4857, 8336, 4910, 8341, 8346, 5858, 4985, 1313, 1318, 5875, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1996,1328,0,0,0,0,0,0,0,0,0,0,0},{3755,0,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {841, 2670, 1420, 1404, 2005, 3796, 8351, 8371, {8397, 8420, 451, 8443, 8454, 8469, 8484}, {8499, 8504, 8509, 8514, 8519, 8524, 8529}, {8534, 8537, 8534, 8540, 8543, 8537, 8540}, {8546, 8559, 8574, 8583, 8596, 8603, 8612, 8621, 8634, 8651, 8666, 8679, 0}, {8694, 8707, 8722, 8733, 8746, 8753, 8762, 8771, 8786, 8803, 8818, 8831, 0}, {8846, 8854, 8574, 8864, 8596, 8603, 8612, 8872, 8880, 8890, 8898, 8908, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{841,316,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {8916, 8930, 1420, 1404, 44, 2385, 3804, 3807, {8940, 8949, 8961, 8968, 8976, 8986, 8992}, {8999, 9003, 9007, 9011, 9015, 9020, 9024}, {9028, 9030, 9032, 1076, 9034, 9030, 1076}, {9037, 9047, 9056, 9064, 9072, 9080, 9087, 9094, 9102, 2192, 9108, 9116, 0}, {9125, 9135, 9144, 9152, 9160, 9168, 9175, 9182, 9191, 7584, 9197, 9207, 0}, {9216, 9220, 9225, 9230, 9234, 7618, 9238, 9242, 9246, 7635, 9250, 9254, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {8930,9258,6133,9266,9278,9288,9298,1328,0,0,0,0,0,0},{8916,9310,9325,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 9345, 1420, 1404, 2005, 55, 9356, 9367, {9378, 9386, 9395, 9402, 9409, 9418, 2075}, {2082, 2085, 9425, 2092, 9428, 9432, 2103}, {2106, 2108, 9435, 2113, 9437, 2108, 2113}, {5734, 5742, 9440, 6055, 9446, 6108, 6113, 2537, 2544, 5813, 2562, 2571, 0}, {9451, 9460, 7517, 9470, 9478, 9484, 9490, 9496, 9504, 9514, 9523, 9532, 0}, {2580, 2584, 2588, 2592, 9446, 6108, 6113, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 9541, 268, {9345,1996,9544,2926,2670,1363,1328,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{1404,301,2350,0,0,0,0,0,0,0,0,0},{1420,307,2366,0,0,0,0,0,0}},
+       {1328, 1328, 9553, 9564, 9572, 3796, 9580, 9583, {9586, 9593, 9602, 9611, 9623, 9631, 9640}, {9650, 9654, 3951, 9659, 9664, 9668, 9672}, {2775, 5718, 2486, 2486, 9676, 2108, 2113}, {9678, 9684, 4899, 9691, 2523, 9697, 9705, 9712, 9718, 9726, 9732, 9740, 0}, {9678, 9684, 4899, 9691, 2523, 9697, 9705, 9712, 9718, 9726, 9732, 9740, 0}, {2861, 9748, 3951, 9752, 9756, 9760, 9764, 9768, 9672, 9772, 9776, 9781, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 2624, 268, {1328,5894,0,0,0,0,0,0,0,0,0,0,0,0},{1328,0,0,0,0,0,0,0},{9564,301,0,0,0,0,0,0,0,0,0,0},{9553,307,0,0,0,0,0,0,0}},
+       {9785, 1328, 307, 301, 2005, 9803, 9816, 9819, {9822, 9830, 9838, 2426, 2433, 2441, 9845}, {9853, 9858, 9863, 2469, 2473, 2477, 9867}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {7167, 7175, 4899, 2517, 2523, 2527, 2532, 9872, 2544, 2554, 2562, 2571, 0}, {7167, 7175, 4899, 2517, 2523, 2527, 2532, 9872, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {1328,5894,0,0,0,0,0,0,0,0,0,0,0,0},{9785,9880,0,0,0,0,0,0},{301,1404,9903,0,0,0,0,0,0,0,0,0},{307,1420,9913,0,0,0,0,0,0}},
+       {3755, 3010, 1420, 1404, 2005, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,270,9926,9937,1328,0,0,0,0,0,0,0},{3755,9949,9965,0,0,0,0,0},{1404,301,3030,35,0,0,0,0,0,0,0,0},{1420,307,3019,23,0,0,0,0,0}},
+       {10007, 2670, 307, 301, 2005, 55, 3804, 3807, {10025, 10031, 10041, 10047, 10058, 10068, 10073}, {10083, 10087, 10091, 10095, 10100, 10104, 10108}, {2108, 2108, 2113, 10112, 2108, 7409, 7409}, {10115, 10120, 10127, 10132, 10138, 10145, 10153, 10160, 10169, 10176, 10181, 10188, 0}, {10115, 10120, 10127, 10132, 10138, 10145, 10153, 10160, 10169, 10176, 10181, 10188, 0}, {10196, 10200, 3951, 10205, 3920, 10209, 10213, 10217, 10222, 10226, 10230, 10234, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,1328,0,0,0,0,0,0,0,0,0,0,0},{10007,5510,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {4014, 270, 3019, 3030, 44, 55, 10238, 10243, {10250, 10261, 10268, 10277, 10284, 10297, 10306}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {10315, 10326, 10337, 10346, 10357, 10362, 10369, 10380, 10389, 10400, 10413, 10424, 0}, {10315, 10326, 10337, 10346, 10357, 10362, 10369, 10380, 10389, 10400, 10413, 10424, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {5510, 270, 1420, 1404, 2005, 55, 3804, 3807, {10435, 10442, 10448, 10455, 10460, 10466, 10472}, {10478, 10482, 10486, 10490, 10494, 10498, 10502}, {2486, 2113, 2113, 10506, 4442, 4155, 2113}, {10508, 10516, 10525, 2798, 10531, 2808, 2813, 10535, 2825, 2835, 2843, 10543, 0}, {10508, 10516, 10525, 2798, 10531, 2808, 2813, 10535, 2825, 2835, 2843, 10543, 0}, {2861, 2865, 3951, 2874, 10531, 2878, 2882, 10552, 2890, 2894, 2898, 10556, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {10560, 2670, 1420, 1404, 10578, 4788, 10594, 10599, {10604, 10617, 10636, 10653, 10666, 10679, 10696}, {10709, 8504, 8509, 8514, 8519, 8524, 8529}, {10714, 8537, 8534, 8540, 8543, 8537, 8540}, {10717, 10730, 10741, 10758, 10773, 10788, 10803, 10816, 10831, 10848, 10863, 10880, 0}, {10895, 10906, 10919, 10934, 10947, 10960, 10973, 10984, 10997, 11012, 11025, 11044, 0}, {11057, 11064, 11071, 11078, 11085, 11092, 11099, 11106, 11113, 11120, 11127, 11134, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,1328,0,0,0,0,0,0,0,0,0,0,0},{10560,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3755, 2670, 1420, 1404, 2005, 4788, 11141, 11154, {11167, 11182, 11203, 11218, 11231, 11244, 11259}, {520, 525, 11272, 535, 11277, 545, 550}, {555, 558, 11282, 564, 567, 558, 564}, {11285, 11302, 11311, 11326, 11343, 11358, 11373, 11386, 11401, 11418, 11439, 11456, 0}, {11285, 11302, 11311, 11326, 620, 11358, 11373, 11386, 11401, 11418, 11439, 11456, 0}, {11471, 11478, 11485, 11492, 11499, 11506, 11513, 11520, 11527, 11534, 11541, 11548, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 790, 268, {2670,1363,1328,0,0,0,0,0,0,0,0,0,0,0},{3755,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 2015, 11555, {11560, 11568, 11579, 11585, 11591, 11600, 2075}, {8999, 9003, 2473, 11606, 9015, 9020, 11610}, {9028, 9030, 1068, 1076, 9034, 9030, 1076}, {2496, 2503, 9440, 2517, 2523, 11614, 11620, 11626, 2544, 2554, 2562, 2571, 0}, {2496, 2503, 9440, 2517, 2523, 11614, 11620, 11626, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 11633, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {11648, 11667, 1420, 1404, 11677, 2385, 11693, 11698, {11703, 11714, 11725, 11736, 11747, 11758, 11764}, {2108, 9676, 2488, 4442, 2106, 10506, 2494}, {2108, 9676, 2488, 4442, 2106, 10506, 2494}, {11773, 11781, 11790, 11797, 4910, 11804, 11810, 2537, 2544, 11816, 2562, 11825, 0}, {11773, 11781, 11790, 11797, 4910, 11804, 11810, 2537, 2544, 11816, 2562, 11825, 0}, {11835, 11840, 11790, 2592, 4910, 11804, 11810, 2604, 11846, 2612, 2616, 11851, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {11667,2670,1363,1328,0,0,0,0,0,0,0,0,0,0},{11648,11856,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {11876, 5620, 1420, 1404, 5632, 2385, 11903, 11920, {11934, 11945, 11955, 11964, 11975, 11987, 11998}, {12008, 12011, 12014, 12017, 12020, 12023, 12026}, {2113, 2108, 2490, 2488, 7409, 2108, 2113}, {12029, 12039, 2511, 12050, 12059, 12065, 12073, 12081, 12089, 12100, 12109, 12119, 0}, {12029, 12039, 2511, 12050, 12059, 12065, 12073, 12081, 12089, 12100, 12109, 12119, 0}, {4961, 1288, 2511, 8336, 12059, 12129, 12135, 5858, 4985, 5870, 1318, 5875, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {5620,12141,1328,0,0,0,0,0,0,0,0,0,0,0},{11876,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {12151, 1848, 307, 301, 12173, 12188, 12200, 11555, {12206, 12218, 12230, 12242, 12256, 12271, 12284}, {12298, 12011, 12301, 12017, 12304, 12307, 12310}, {2113, 2108, 12314, 2488, 4442, 2108, 9437}, {12316, 12323, 12331, 12337, 12346, 12355, 12365, 12371, 12382, 12392, 12399, 12409, 0}, {12417, 12424, 12432, 12438, 12447, 12456, 12466, 12472, 12483, 12493, 12500, 12510, 0}, {12518, 12524, 12529, 12534, 12539, 12544, 12549, 12555, 12561, 12567, 12573, 12580, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1848,1328,0,0,0,0,0,0,0,0,0,0,0,0},{12151,0,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {3755, 1363, 1420, 1404, 2005, 3796, 12587, 12599, {12611, 12626, 12641, 12656, 12673, 12692, 12703}, {12714, 12721, 12728, 12735, 12742, 12749, 12756}, {0, 0, 0, 0, 0, 0, 0}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12864, 12871, 12878, 12885, 8596, 12798, 12805, 12892, 12899, 12906, 12913, 12920, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1363,1328,0,0,0,0,0,0,0,0,0,0,0,0},{3755,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,0,0,0,0,0,0,0,0}},
+       {3767, 3979, 23, 35, 44, 3796, 12927, 12947, {12964, 12977, 12990, 13006, 13023, 13038, 13047}, {12964, 12977, 12990, 13006, 13023, 13038, 13047}, {13056, 13059, 13062, 13065, 13068, 13071, 13074}, {13077, 13090, 13101, 13110, 13121, 13126, 13135, 13146, 13153, 13168, 13179, 13192, 0}, {13205, 13220, 13101, 13110, 13233, 13126, 13240, 13146, 13153, 13168, 13179, 13192, 0}, {13077, 13090, 13101, 13110, 13121, 13126, 13135, 13146, 13153, 13168, 13179, 13192, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {3979,3970,0,0,0,0,0,0,0,0,0,0,0,0},{3767,4000,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {5510, 270, 3019, 3030, 2005, 55, 13253, 13256, {13259, 13272, 13282, 13291, 13301, 13312, 13323}, {13335, 13338, 13343, 13348, 13353, 13358, 13363}, {13335, 13368, 13371, 13374, 13377, 13380, 13383}, {13386, 13399, 13410, 13420, 13431, 13443, 13455, 13468, 13480, 13493, 13508, 13529, 0}, {13386, 13399, 13410, 13420, 13431, 13443, 13455, 13468, 13480, 13493, 13508, 13529, 0}, {13548, 13554, 13560, 13566, 13572, 13578, 13584, 13590, 13596, 13602, 13609, 13616, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1354,2374,1328,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {13623, 2670, 1420, 1404, 44, 4788, 13636, 13644, {13652, 13665, 13686, 13705, 13726, 13745, 13758}, {13769, 13776, 13783, 13790, 13797, 13804, 13811}, {0, 0, 0, 0, 0, 0, 0}, {13818, 13833, 13848, 13857, 13868, 13879, 13892, 13905, 13920, 13939, 13958, 13975, 0}, {13818, 13833, 13848, 13857, 13868, 13879, 13892, 13905, 13920, 13939, 13958, 13975, 0}, {13994, 14001, 14008, 14015, 14022, 14029, 14036, 14043, 14050, 14057, 14064, 14071, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,14078,270,14088,3743,1328,0,0,0,0,0,0,0},{13623,2992,14099,5510,14118,14129,14141,14158},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3755, 2670, 1420, 1404, 2005, 4788, 0, 0, {14176, 14182, 14196, 14219, 14233, 14249, 14256}, {14265, 14268, 14273, 14279, 14283, 7409, 14288}, {251, 239, 241, 243, 245, 247, 249}, {14292, 14299, 10127, 14306, 3920, 14312, 14318, 14324, 14331, 14340, 14348, 14355, 0}, {14292, 14299, 10127, 14306, 3920, 14312, 14318, 14324, 14331, 14340, 14348, 14355, 0}, {14362, 7848, 2588, 2592, 14366, 14370, 14374, 14378, 14382, 2612, 14386, 14390, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{3755,5510,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {14394, 1837, 1420, 301, 14421, 3796, 3804, 3807, {14437, 14445, 14456, 14466, 14477, 14486, 14495}, {14505, 14508, 14511, 14514, 14517, 14520, 14523}, {14526, 2486, 12314, 2494, 12314, 2490, 14526}, {14528, 14538, 14546, 14554, 14562, 14570, 14577, 14585, 14593, 14600, 14606, 14613, 0}, {14528, 14538, 14546, 14554, 14562, 14570, 14577, 14585, 14593, 14600, 14606, 14613, 0}, {14621, 14625, 2588, 14629, 4910, 14633, 14637, 14641, 14645, 14649, 14653, 14657, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {1837,1328,0,0,0,0,0,0,0,0,0,0,0,0},{14394,0,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{1420,307,1428,0,0,0,0,0,0}},
+       {14099, 2670, 307, 301, 2005, 55, 14661, 14682, {14699, 430, 451, 8443, 14712, 14729, 14740}, {14753, 14761, 14769, 14775, 14783, 14791, 14799}, {555, 558, 561, 564, 567, 558, 564}, {14807, 583, 600, 609, 14822, 14829, 14838, 641, 654, 673, 690, 705, 0}, {14807, 583, 600, 609, 14822, 14829, 14838, 641, 654, 673, 690, 705, 0}, {14847, 14855, 14863, 738, 14822, 14871, 14879, 746, 754, 764, 772, 14887, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,1328,0,0,0,0,0,0,0,0,0,0,0},{14099,0,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 0, 0, {14899, 14906, 14917, 14926, 14935, 14942, 14953}, {14963, 14967, 14971, 14975, 14979, 14982, 14986}, {0, 0, 0, 0, 0, 0, 0}, {14990, 15000, 15009, 15017, 15026, 15039, 15051, 15058, 15065, 15072, 15082, 15094, 0}, {14990, 15000, 15009, 15017, 15026, 15039, 15051, 15058, 15065, 15072, 15082, 15094, 0}, {15107, 15111, 15115, 15119, 15123, 15127, 15131, 15135, 15139, 15143, 15147, 15151, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 0, 0, {15155, 15160, 15166, 15176, 15188, 15196, 15207}, {15216, 15220, 15224, 15228, 15232, 15236, 15240}, {0, 0, 0, 0, 0, 0, 0}, {15244, 15254, 15264, 15271, 15278, 2808, 15283, 15290, 15297, 15306, 15314, 15322, 0}, {15244, 15254, 15264, 15271, 15278, 2808, 15283, 15290, 15297, 15306, 15314, 15322, 0}, {2861, 2865, 14986, 15330, 15334, 2878, 2882, 15338, 2890, 2894, 2898, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 3804, 3807, {15346, 15352, 15363, 15176, 15373, 15196, 15207}, {15382, 15386, 15390, 15228, 15232, 15236, 15240}, {2113, 2486, 15394, 2488, 2113, 5718, 2486}, {15396, 15406, 15417, 15424, 15433, 15439, 15445, 15453, 15461, 15472, 15482, 15491, 0}, {15500, 15254, 15509, 15515, 15278, 2808, 15283, 15290, 15522, 15306, 15314, 15322, 0}, {2861, 2865, 15532, 2874, 15334, 2878, 2882, 15338, 2890, 2894, 2898, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 15536, 15540, {15544, 15551, 15559, 15567, 15576, 15586, 15593}, {2754, 8226, 2760, 15602, 2766, 15605, 2772}, {2113, 2486, 2775, 3895, 2775, 4157, 2113}, {15608, 15617, 15627, 2798, 10531, 15633, 15639, 15645, 2825, 2835, 2843, 10543, 0}, {15608, 15617, 15627, 2798, 10531, 15633, 15639, 15645, 2825, 2835, 2843, 10543, 0}, {2861, 2865, 3951, 2874, 10531, 2878, 2882, 2886, 2890, 2894, 2898, 10556, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,15654,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {15666, 2670, 1420, 1404, 2005, 15698, 15704, 15720, {15742, 15758, 15783, 15811, 15839, 15867, 15895}, {15914, 15924, 15934, 15944, 15954, 15964, 15974}, {15984, 15988, 15992, 15988, 15996, 16000, 16004}, {16008, 16030, 16058, 16074, 16093, 16109, 16128, 16144, 16166, 16197, 16225, 16250, 0}, {16008, 16030, 16058, 16074, 16093, 16109, 16128, 16144, 16166, 16197, 16225, 16250, 0}, {16278, 16288, 16298, 16308, 16318, 16328, 16338, 16348, 16358, 16368, 16378, 16388, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{15666,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 2374, 307, 301, 2005, 2385, 16398, 16403, {5913, 16408, 16419, 16429, 16439, 16449, 16463}, {5999, 6003, 16475, 16480, 16484, 16489, 16494}, {2113, 2486, 2488, 2486, 5718, 2492, 2494}, {2496, 2503, 4899, 6055, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2496, 2503, 4899, 6055, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2580, 2584, 2588, 2592, 4910, 2596, 2600, 2604, 2608, 2612, 2616, 6129, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {2374,1354,1328,0,0,0,0,0,0,0,0,0,0,0},{1983,0,0,0,0,0,0,0},{301,5006,0,0,0,0,0,0,0,0,0,0},{307,6460,0,0,0,0,0,0,0}},
+       {5510, 2374, 307, 301, 44, 55, 16498, 16526, {16548, 16567, 16586, 16608, 16627, 16661, 16686}, {16705, 16716, 16727, 16741, 16752, 16763, 16780}, {16791, 16795, 16802, 16809, 16816, 16823, 16830}, {16834, 16850, 16866, 16882, 16901, 16908, 16918, 16934, 16950, 16972, 16994, 17013, 0}, {16834, 16850, 16866, 16882, 16901, 16908, 16918, 16934, 16950, 16972, 16994, 17013, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,2335,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {17035, 270, 307, 301, 2005, 17059, 17072, 17075, {17078, 17087, 17096, 17106, 17116, 17126, 17138}, {17146, 17151, 17155, 17159, 17163, 17168, 17173}, {17177, 2488, 2488, 9676, 17177, 17180, 2113}, {17183, 17190, 17195, 2798, 17201, 17207, 17214, 17220, 17228, 17238, 17246, 17255, 0}, {17183, 17190, 17195, 2798, 17201, 17207, 17214, 17220, 17228, 17238, 17246, 17255, 0}, {2861, 17265, 3951, 2874, 17269, 17273, 17278, 17282, 17286, 17290, 2898, 17294, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,1328,17299,7079,3010,0,0,0,0,0,0,0,0,0},{17035,17308,9937,0,0,0,0,0},{301,3030,1404,35,0,0,0,0,0,0,0,0},{307,3019,1420,23,0,0,0,0,0}},
+       {17326, 2670, 307, 301, 2005, 17344, 17358, 17363, {17368, 17380, 17391, 17405, 17417, 17427, 17437}, {17448, 17453, 17458, 17463, 17468, 17473, 17478}, {2113, 4157, 2486, 6251, 2775, 15394, 2494}, {17483, 17500, 17513, 17527, 17540, 17553, 17566, 17580, 17592, 17606, 17620, 17634, 0}, {17483, 17500, 17513, 17527, 17540, 17553, 17566, 17580, 17592, 17606, 17620, 17634, 0}, {17647, 17654, 17659, 17664, 17668, 17673, 17678, 17683, 17688, 17695, 17700, 17706, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,2926,1328,0,0,0,0,0,0,0,0,0,0},{17326,0,0,0,0,0,0,0},{301,1404,5006,0,0,0,0,0,0,0,0,0},{307,1420,6460,0,0,0,0,0,0}},
+       {5510, 270, 1420, 1404, 2005, 55, 18004, 18007, {18011, 18016, 10448, 10455, 18022, 18029, 10472}, {18036, 18040, 10486, 10490, 18044, 10498, 10502}, {12314, 14526, 2113, 10506, 4442, 4155, 2113}, {10508, 10516, 18048, 2798, 10531, 2878, 18052, 18058, 2825, 2835, 2843, 18063, 0}, {10508, 10516, 18048, 2798, 10531, 2878, 18052, 18058, 2825, 2835, 2843, 18063, 0}, {2861, 2865, 18048, 2874, 10531, 2878, 2882, 18058, 2890, 2894, 2898, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {18515, 1363, 1420, 1404, 18535, 4788, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1363,1328,0,0,0,0,0,0,0,0,0,0,0,0},{18515,0,0,0,0,0,0,0},{1404,0,0,0,0,0,0,0,0,0,0,0},{1420,0,0,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 18551, 18559, {18567, 18576, 18585, 18593, 18602, 18611, 18618}, {18627, 18630, 18633, 18636, 18639, 18643, 18646}, {241, 243, 245, 247, 12314, 14526, 239}, {10508, 10516, 18649, 18655, 10531, 2808, 18052, 18662, 15297, 18669, 15314, 18676, 0}, {10508, 10516, 18649, 18655, 10531, 2808, 18052, 18662, 15297, 18669, 15314, 18676, 0}, {2861, 2865, 18048, 2874, 10531, 2878, 2882, 18684, 2890, 2894, 2898, 10556, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {18688, 18706, 307, 301, 2005, 18717, 0, 0, {33652, 33662, 33671, 33680, 33691, 33701, 33706}, {33713, 33719, 33724, 33729, 33734, 10104, 33738}, {33743, 2775, 2113, 7409, 2108, 7409, 2113}, {14292, 14299, 10127, 14306, 3920, 33745, 33750, 33755, 14331, 14340, 14348, 14355, 0}, {14292, 14299, 10127, 14306, 3920, 33745, 33750, 33755, 14331, 14340, 14348, 14355, 0}, {33762, 33767, 3951, 2874, 3920, 33745, 33750, 33771, 10482, 2894, 33775, 33780, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {18706,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{18688,3755,5510,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {5510, 1354, 6460, 5006, 44, 55, 18884, 18912, {18934, 18953, 18972, 18997, 19016, 19050, 19075}, {19094, 19104, 19114, 19130, 19140, 19165, 19181}, {19191, 19195, 19202, 19206, 19213, 19220, 19227}, {19231, 19259, 19293, 19309, 19328, 19335, 19345, 19361, 19377, 19408, 19430, 19452, 0}, {19231, 19259, 19293, 19309, 19328, 19335, 19345, 19361, 19377, 19408, 19430, 19452, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{5006,2350,19477,19486,0,0,0,0,0,0,0,0},{6460,2366,19494,19506,0,0,0,0,0}},
+       {5510, 1354, 307, 301, 44, 55, 20053, 20094, {20135, 20154, 20173, 20195, 20214, 20236, 20261}, {20280, 20290, 20300, 20313, 20323, 20336, 20352}, {20362, 20366, 20373, 20380, 20387, 20394, 20401}, {20405, 20433, 20461, 20477, 20496, 20503, 20513, 20529, 20545, 20573, 20595, 20617, 0}, {20405, 20433, 20461, 20477, 20496, 20503, 20513, 20529, 20545, 20573, 20595, 20617, 0}, {20642, 20661, 20461, 20477, 20496, 20503, 20513, 20529, 20680, 20696, 20712, 20722, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 1354, 307, 301, 44, 55, 7860, 20735, {20738, 20757, 20776, 20801, 20820, 20842, 20867}, {20886, 20896, 20906, 20922, 20932, 20945, 20961}, {20971, 20975, 20982, 20986, 20993, 21000, 21007}, {21011, 21033, 21064, 21086, 21105, 21112, 21122, 21138, 21154, 21185, 21207, 21229, 0}, {21011, 21033, 21064, 21086, 21105, 21112, 21122, 21138, 21154, 21185, 21207, 21229, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 2374, 307, 301, 2005, 55, 21254, 21279, {21304, 21323, 21345, 21370, 21386, 21408, 21427}, {21437, 21444, 21451, 21458, 21465, 21472, 21479}, {21437, 21444, 21451, 21458, 21465, 21472, 21479}, {21483, 21499, 21524, 21543, 21562, 21569, 21582, 21595, 21614, 21645, 21670, 21692, 0}, {21483, 21499, 21524, 21543, 21562, 21569, 21582, 21717, 21614, 21645, 21670, 21692, 0}, {21736, 21744, 21758, 21772, 21562, 21569, 21582, 21783, 21791, 21805, 21816, 21824, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,2335,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 1354, 307, 301, 44, 55, 21835, 21866, {21891, 21913, 21935, 21960, 21982, 22007, 22035}, {22057, 22067, 22077, 22090, 22100, 22113, 22129}, {22139, 22143, 22150, 22154, 22161, 22168, 22175}, {22179, 22195, 22220, 22239, 22261, 22268, 22281, 22294, 22313, 22344, 22369, 22388, 0}, {22179, 22195, 22220, 22239, 22261, 22268, 22281, 22294, 22313, 22344, 22369, 22388, 0}, {22413, 22420, 243, 22436, 22261, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 1354, 307, 301, 44, 55, 3804, 3807, {22452, 22471, 22490, 22512, 22531, 22553, 22578}, {22597, 22602, 22610, 22618, 22626, 22634, 22642}, {22653, 22657, 22664, 22671, 22678, 22685, 22692}, {22696, 22712, 22737, 22756, 22778, 22785, 22798, 22811, 22830, 22858, 22883, 22905, 0}, {22696, 22712, 22737, 22756, 22778, 22785, 22798, 22811, 22830, 22858, 22883, 22905, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {5510, 1354, 6460, 5006, 44, 55, 22930, 22949, {22980, 23005, 23036, 23064, 23089, 23117, 23151}, {23176, 23195, 23220, 23236, 23255, 23274, 23293}, {23303, 23310, 23317, 23324, 23331, 23344, 23351}, {23355, 23374, 23402, 23430, 23455, 23468, 23484, 23497, 23522, 23559, 23587, 23609, 0}, {23355, 23374, 23402, 23430, 23455, 23468, 23484, 23497, 23522, 23559, 23587, 23609, 0}, {23634, 23644, 23663, 23679, 23455, 23468, 23484, 23695, 23702, 23727, 23743, 23753, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{5006,2350,19477,19486,0,0,0,0,0,0,0,0},{6460,2366,19494,19506,0,0,0,0,0}},
+       {23766, 2374, 1960, 1943, 23785, 55, 23793, 23821, {23843, 23862, 23881, 23906, 23925, 23959, 23984}, {24003, 19104, 19114, 19130, 24013, 24038, 19181}, {0, 0, 0, 0, 0, 0, 0}, {24054, 24079, 24110, 24126, 19328, 19335, 19345, 24145, 24161, 24192, 24214, 24236, 0}, {24054, 24079, 24110, 24126, 19328, 19335, 19345, 24145, 24161, 24192, 24214, 24236, 0}, {24261, 24274, 24110, 24126, 19328, 19335, 19345, 24293, 24300, 24316, 24332, 24342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,0,0,0,0,0,0,0,0,0,0,0,0,0},{23766,0,0,0,0,0,0,0},{1943,1951,0,0,0,0,0,0,0,0,0,0},{1960,1971,0,0,0,0,0,0,0}},
+       {5510, 2374, 307, 301, 44, 55, 3804, 3807, {16548, 16567, 24355, 16608, 24377, 16661, 16686}, {24399, 24409, 24419, 24432, 24442, 24455, 24471}, {16791, 16795, 16802, 16809, 16816, 16823, 16830}, {24481, 24506, 16866, 24537, 24556, 16908, 24563, 24576, 24592, 24617, 24639, 24667, 0}, {24481, 24506, 16866, 24537, 24556, 16908, 24563, 24576, 24592, 24617, 24639, 24667, 0}, {24689, 24702, 16866, 24721, 24556, 16908, 24563, 24737, 24744, 257, 24766, 24788, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,2335,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {25169, 1467, 307, 301, 25212, 25219, 25245, 25267, {25292, 25320, 25348, 25385, 25416, 25450, 25475}, {25509, 25525, 25541, 25566, 25585, 25607, 25626}, {25648, 25655, 25662, 25669, 25676, 25683, 25687}, {25697, 25731, 25768, 25802, 25836, 25867, 25904, 25941, 25981, 26015, 26049, 26098, 0}, {25697, 25731, 25768, 25802, 25836, 25867, 25904, 25941, 25981, 26015, 26049, 26098, 0}, {26147, 26160, 26173, 26186, 26199, 26212, 26225, 26238, 26251, 26264, 26280, 26296, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1848,1328,1837,1859,1866,1873,0,0,0,0,0},{25169,26312,0,0,0,0,0,0},{301,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {5510, 270, 307, 301, 2005, 55, 0, 0, {26360, 26369, 26379, 26391, 26404, 26413, 26425}, {26437, 26441, 26446, 26450, 26454, 26458, 26462}, {2113, 2494, 2486, 2486, 14526, 6251, 2113}, {26466, 26473, 26482, 26489, 2804, 26496, 26504, 26515, 26520, 26525, 26532, 26541, 0}, {26466, 26473, 26482, 26489, 2804, 26496, 26549, 26515, 26520, 26525, 26532, 26541, 0}, {26559, 26563, 26446, 26568, 2804, 26572, 26576, 26515, 26520, 26580, 26584, 26589, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 0, 266, 268, {270,14,1347,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,35,3030,0,0,0,0,0,0,0,0},{307,1420,23,3019,0,0,0,0,0}},
+       {3755, 1328, 307, 26594, 26602, 26637, 26673, 26689, {26705, 26739, 26770, 26801, 26823, 26866, 26894}, {26919, 26926, 26930, 26934, 26941, 26951, 26958}, {0, 0, 0, 0, 0, 0, 0}, {26962, 26975, 26994, 27007, 27020, 27033, 27052, 27071, 27084, 27100, 27113, 27138, 0}, {26962, 26975, 26994, 27007, 27020, 27033, 27052, 27071, 27084, 27100, 27113, 27138, 0}, {27151, 27155, 27159, 27163, 27167, 27171, 27175, 27179, 27183, 27187, 27194, 27201, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1328,0,0,0,0,0,0,0,0,0,0,0,0,0},{3755,9949,0,0,0,0,0,0},{26594,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {5510, 270, 307, 26594, 2005, 55, 27208, 27233, {27258, 27283, 27302, 27330, 27349, 27374, 27393}, {27415, 27423, 27428, 27433, 27438, 27446, 27454}, {0, 0, 0, 0, 0, 0, 0}, {27459, 27478, 27494, 27507, 27520, 27542, 27561, 27583, 27599, 27615, 27628, 27644, 0}, {27459, 27478, 27494, 27507, 27520, 27542, 27561, 27583, 27599, 27615, 27628, 27644, 0}, {27660, 27669, 27678, 27690, 27700, 27709, 27721, 27730, 27739, 27748, 27757, 27766, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,1328,0,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{26594,0,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {4028, 270, 1420, 1404, 4057, 55, 973, 978, {27775, 27783, 27788, 27795, 27805, 27811, 27818}, {27826, 27830, 3951, 27834, 27839, 27843, 27847}, {2775, 2494, 2486, 2486, 4153, 4157, 2113}, {27852, 27860, 6270, 27869, 27875, 27880, 27886, 6304, 27892, 27901, 27909, 27918, 0}, {27852, 27860, 6270, 27869, 27875, 27880, 27886, 6304, 27892, 27901, 27909, 27918, 0}, {27927, 2865, 3951, 27931, 2804, 27935, 27940, 18684, 17286, 27944, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1339,1347,1354,1363,1328,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{1404,301,35,1409,0,0,0,0,0,0,0,0},{1420,307,23,1428,0,0,0,0,0}},
+       {5510, 2374, 307, 301, 44, 55, 27948, 27960, {27972, 16567, 28000, 16608, 24377, 16661, 16686}, {24399, 24409, 24419, 24432, 24442, 24455, 24471}, {0, 0, 0, 0, 0, 0, 0}, {24481, 24506, 16866, 24537, 24556, 16908, 24563, 28019, 28035, 28063, 24639, 24667, 0}, {24481, 24506, 16866, 24537, 24556, 16908, 24563, 28019, 28035, 28063, 24639, 24667, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,2335,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,1943,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {28085, 1328, 3019, 3030, 28133, 3796, 28143, 28155, {28164, 28180, 28196, 28224, 28240, 28283, 28308}, {28336, 28346, 28356, 28363, 28373, 28389, 28402}, {28412, 28416, 28420, 28424, 28428, 28441, 28448}, {28455, 28474, 28499, 28518, 28543, 28556, 28569, 28582, 28604, 28638, 28663, 28691, 0}, {28455, 28474, 28499, 28518, 28543, 28556, 28569, 28582, 28604, 28638, 28663, 28691, 0}, {28719, 28726, 28736, 28518, 28543, 28556, 28569, 28749, 28759, 28772, 28782, 28795, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 2624, 268, {1328,1837,1880,270,14,0,0,0,0,0,0,0,0,0},{28085,0,0,0,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {28808, 3010, 3019, 3030, 2005, 28840, 28854, 28864, {28877, 28887, 28894, 28907, 28917, 28927, 28937}, {28877, 28887, 28947, 28907, 28917, 28927, 28937}, {28957, 28961, 28965, 28969, 28973, 28977, 28981}, {28985, 29001, 29017, 29027, 29040, 29047, 29054, 29064, 29077, 29096, 29115, 29131, 0}, {28985, 29001, 29017, 29027, 29040, 29047, 29054, 29064, 29077, 29096, 29115, 29131, 0}, {29147, 29157, 29017, 29167, 29040, 29047, 29054, 29177, 29187, 29197, 29207, 29217, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1328,0,0,0,0,0,0,0,0,0,0,0,0},{28808,0,0,0,0,0,0,0},{3030,0,0,0,0,0,0,0,0,0,0,0},{3019,0,0,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 29468, 3796, 29478, 29519, {29560, 29579, 29598, 29623, 29642, 29664, 29689}, {29708, 24409, 29718, 24432, 29734, 24455, 24471}, {29747, 29751, 29755, 29759, 29763, 29767, 29771}, {16834, 29775, 16866, 29803, 24556, 29822, 16918, 16934, 29832, 29863, 29885, 29910, 0}, {16834, 29775, 16866, 29803, 24556, 29822, 16918, 16934, 29832, 29863, 29885, 29910, 0}, {29935, 29942, 16866, 29952, 24556, 29822, 29968, 29981, 29988, 30004, 30020, 30033, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {270, 14, 3019, 3030, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {30046, 30053, 30062, 30077, 30088, 30097, 30104, 30111, 30118, 30129, 30142, 30155, 0}, {30046, 30053, 30062, 30077, 30088, 30097, 30104, 30111, 30118, 30129, 30142, 30155, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {14,270,0,0,0,0,0,0,0,0,0,0,0,0},{270,1,281,30160,0,0,0,0},{3030,1404,0,0,0,0,0,0,0,0,0,0},{3019,1420,0,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 3804, 3807, {30178, 30185, 27788, 30191, 30202, 30210, 30219}, {30226, 27830, 3951, 30230, 30234, 30238, 10502}, {2494, 2494, 2486, 2486, 5718, 15394, 2113}, {30242, 30248, 30256, 27869, 30262, 30267, 30273, 6304, 30279, 30289, 30297, 30307, 0}, {30242, 30248, 30256, 27869, 30262, 30267, 30273, 6304, 30279, 30289, 30297, 30307, 0}, {30317, 30321, 3951, 27931, 3920, 30325, 30329, 18684, 17286, 2894, 30333, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {3767, 3010, 3019, 3030, 44, 3796, 0, 0, {30337, 30344, 30352, 30359, 30366, 30374, 30382}, {30389, 30392, 30395, 30398, 30401, 30404, 30407}, {2494, 2494, 2488, 2494, 12314, 4155, 12314}, {30410, 30418, 30428, 30434, 30442, 30447, 30452, 30457, 30464, 18669, 30472, 30480, 0}, {30410, 30418, 30428, 30434, 30442, 30447, 30452, 30457, 30464, 18669, 30472, 30480, 0}, {2861, 30488, 3951, 30492, 3920, 29431, 29435, 30496, 3891, 2894, 30500, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,270,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {3767, 3010, 3019, 3030, 44, 3796, 30504, 30515, {30525, 30543, 30558, 30580, 30593, 30607, 30624}, {30648, 30656, 30661, 30580, 30593, 30673, 30680}, {0, 0, 0, 0, 0, 0, 0}, {30694, 30716, 30732, 30752, 30766, 30783, 30798, 30815, 30829, 30842, 30861, 30875, 0}, {30694, 30716, 30732, 30752, 30766, 30783, 30798, 30815, 30829, 30842, 30861, 30875, 0}, {30894, 30909, 30918, 30931, 30938, 30948, 30956, 30966, 30973, 30979, 30991, 30998, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,270,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 0, 0, {31010, 31018, 14917, 14926, 14935, 31029, 31039}, {15382, 14967, 14971, 14975, 14979, 15236, 31048}, {0, 0, 0, 0, 0, 0, 0}, {31052, 31061, 31071, 31079, 10531, 3924, 31087, 31093, 31102, 31111, 31120, 31129, 0}, {31052, 31061, 31071, 31079, 10531, 3924, 31087, 31093, 31102, 31111, 31120, 31129, 0}, {2861, 2865, 14986, 31138, 10531, 2878, 2882, 18684, 17286, 2894, 31142, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,3030,301,0,0,0,0,0,0,0,0,0},{23,3019,307,0,0,0,0,0,0}},
+       {1983, 2374, 307, 301, 2005, 2385, 31146, 31151, {31156, 31163, 31178, 31192, 31208, 31223, 31239}, {6247, 31254, 2588, 31258, 31262, 31266, 31270}, {2113, 12314, 2486, 2108, 2113, 2488, 12314}, {7167, 7175, 31274, 31281, 31288, 2527, 2532, 31293, 31303, 31314, 31323, 31333, 0}, {7167, 7175, 31274, 31281, 31288, 2527, 2532, 31293, 31303, 31314, 31323, 31333, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,1328,2626,0,0,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {3767, 3010, 3019, 3030, 44, 3796, 31343, 31348, {31353, 31369, 31377, 31385, 31394, 31406, 31416}, {31426, 31432, 31438, 31442, 31446, 31454, 3891}, {0, 0, 0, 0, 0, 0, 0}, {31461, 31474, 31488, 31497, 31503, 31507, 31512, 31520, 15297, 31533, 15314, 15322, 0}, {31461, 31474, 31488, 31497, 31503, 31507, 31512, 31520, 15297, 31533, 15314, 15322, 0}, {31542, 2865, 31546, 15330, 31503, 31550, 2882, 31554, 2890, 31562, 2898, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,270,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {31568, 1467, 1420, 1943, 31592, 31609, 31623, 31630, {31637, 31647, 31657, 31667, 31677, 31687, 31697}, {31707, 31714, 31721, 31728, 31735, 31742, 31749}, {31756, 31760, 31764, 31768, 31772, 31776, 31780}, {31784, 31791, 31798, 31805, 31812, 31819, 31826, 31833, 31840, 31847, 31854, 31864, 0}, {31784, 31791, 31798, 31805, 31812, 31819, 31826, 31833, 31840, 31847, 31854, 31864, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1848,1328,1837,0,0,0,0,0,0,0,0},{31568,31874,31904,0,0,0,0,0},{1943,1404,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4771, 270, 307, 301, 2005, 4788, 0, 0, {26437, 27830, 31934, 31941, 31951, 31956, 31963}, {31970, 4131, 31974, 4862, 31979, 31984, 31989}, {4421, 31994, 31997, 32000, 32003, 32006, 32009}, {32012, 32019, 31934, 32030, 32036, 32040, 32049, 32056, 32061, 32070, 8220, 32075, 0}, {32012, 32019, 31934, 32030, 32036, 32040, 32049, 32056, 32061, 32070, 8220, 32075, 0}, {32081, 32085, 32092, 26568, 32036, 32097, 32102, 32056, 32107, 32070, 8220, 32112, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1363,1354,1328,0,0,0,0,0,0,0,0,0},{4771,4997,3755,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {32116, 270, 307, 301, 2005, 4788, 0, 0, {32144, 32152, 32159, 32167, 32177, 32185, 1034}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {32196, 32204, 1091, 1097, 4910, 32213, 32218, 1120, 1126, 32225, 1143, 32234, 0}, {32196, 32204, 1091, 1097, 4910, 32213, 32218, 1120, 1126, 32225, 1143, 32234, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1363,1354,1328,0,0,0,0,0,0,0,0,0},{32116,0,0,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {32396, 32414, 1420, 1404, 32425, 3796, 32441, 32446, {32451, 32476, 32505, 32530, 32543, 32558, 32575}, {32590, 32595, 32600, 32605, 32610, 32615, 8529}, {32620, 32620, 32623, 8540, 8543, 32620, 8540}, {32626, 32645, 32660, 32682, 32702, 32718, 32734, 32748, 32774, 32798, 32815, 32832, 0}, {32626, 32645, 32660, 32682, 32702, 32718, 32734, 32748, 32774, 32798, 32815, 32832, 0}, {32849, 32858, 32867, 32881, 32895, 32907, 32919, 32929, 32945, 32959, 32966, 32973, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {32414,32980,2926,3970,32989,0,0,0,0,0,0,0,0,0},{32396,33000,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 0, 0, {33019, 33031, 33042, 33054, 33066, 33076, 33088}, {33103, 33108, 33113, 33118, 33123, 33128, 33133}, {0, 0, 0, 0, 0, 0, 0}, {33138, 33147, 33159, 33167, 33172, 33182, 33189, 33198, 33205, 33211, 33220, 33231, 0}, {33138, 33147, 33159, 33167, 33172, 33182, 33189, 33198, 33205, 33211, 33220, 33231, 0}, {33239, 33244, 33249, 33254, 33259, 33264, 33269, 33123, 33274, 33279, 33284, 33289, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {5510, 270, 307, 301, 2005, 55, 6031, 6036, {33294, 33307, 33315, 33324, 33334, 33344, 33353}, {33365, 33369, 33373, 33377, 33381, 33385, 33389}, {2775, 2494, 2486, 7409, 12314, 5718, 2113}, {33393, 33407, 33418, 33427, 33438, 33450, 33464, 33476, 33489, 33502, 33514, 33527, 0}, {33393, 33407, 33418, 33427, 33438, 33450, 33464, 33476, 33489, 33502, 33514, 33527, 0}, {33541, 33546, 33552, 33558, 33563, 33569, 33575, 33580, 33586, 33591, 17994, 33597, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 0, 266, 268, {270,14,1347,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,35,3030,0,0,0,0,0,0,0,0},{307,1420,23,3019,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {1445, 1467, 1420, 1404, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {1589, 1596, 1603, 1610, 1617, 1624, 1631}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1328,1837,1848,1859,1866,1873,1880,0,0,0,0},{1445,1889,1916,0,0,0,0,0},{1404,301,1943,1951,0,0,0,0,0,0,0,0},{1420,307,1960,1971,0,0,0,0,0}},
+       {2651, 2670, 307, 301, 2005, 55, 2681, 2687, {2694, 2702, 2709, 2718, 2727, 2738, 2746}, {2754, 2757, 2760, 2763, 2766, 2769, 2772}, {2113, 2486, 2775, 2486, 2775, 2492, 2113}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2861, 2865, 2869, 2874, 2804, 2878, 2882, 2886, 2890, 2894, 2898, 2902, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,2918,33784,2926,1328,0,0,0,0,0,0,0,0},{2651,1983,33794,0,0,0,0,0},{301,1404,8082,8072,2945,8105,8110,8091,8097,0,0,0},{307,1420,8142,8155,2970,2956,2985,0,0}},
+       {5510, 270, 307, 301, 2005, 55, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 0, 266, 268, {270,14,1347,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,35,3030,0,0,0,0,0,0,0,0},{307,1420,23,3019,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,3743,14,1339,1347,1354,1328,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {4771, 14078, 307, 301, 2005, 4788, 3804, 3807, {4795, 4804, 4810, 4816, 4825, 4831, 4840}, {4847, 4852, 4857, 4862, 4867, 4872, 4877}, {2775, 2494, 2486, 2486, 4155, 4157, 2113}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4961, 4967, 4899, 4974, 4910, 4914, 4979, 4927, 4985, 1313, 1318, 4991, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {14078,1339,1363,1880,1354,270,1328,0,0,0,0,0,0,0},{4771,3755,3990,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {2651, 2670, 307, 301, 2005, 2385, 6167, 6170, {6173, 6182, 6190, 6199, 6210, 6219, 6228}, {4127, 4131, 2588, 6235, 6239, 6243, 6247}, {2775, 2494, 2486, 2486, 6251, 4157, 2113}, {6253, 6261, 6270, 6276, 6283, 6290, 6297, 6304, 6311, 6321, 6329, 6338, 0}, {6347, 6355, 4173, 6364, 6371, 6378, 6385, 4196, 6392, 6402, 1143, 6410, 0}, {6419, 2584, 2588, 2592, 6423, 6427, 6431, 4242, 6435, 6439, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,11637,1347,6443,1328,0,0,0,0,0,0,0,0},{2651,6451,3755,0,0,0,0,0},{301,1404,8082,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {4771, 14078, 1420, 1404, 2005, 55, 973, 978, {7088, 7095, 7103, 7111, 7120, 7130, 7138}, {7147, 4424, 7150, 7153, 7156, 7159, 7162}, {7165, 2486, 2775, 3895, 2775, 4157, 7165}, {7167, 7175, 7184, 2517, 7190, 2527, 2532, 7194, 2544, 2554, 2562, 2571, 0}, {7167, 7175, 7184, 2517, 7190, 2527, 2532, 7194, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 7203, 2592, 7190, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {14078,1339,1354,1363,2906,1328,0,0,0,0,0,0,0,0},{4771,3990,3755,5553,0,0,0,0},{1404,301,33804,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 2670, 307, 301, 2005, 2385, 2393, 2398, {2403, 9830, 33814, 2426, 2433, 2441, 33821}, {2456, 9858, 33829, 2469, 2473, 2477, 6027}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2580, 2584, 2588, 2592, 4910, 2596, 2600, 2604, 2608, 2612, 2616, 6129, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,2926,1328,2906,0,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,7291,5006,0,0,0,0,0,0,0,0},{307,1420,7302,6460,0,0,0,0,0}},
+       {7643, 2374, 307, 301, 4057, 33833, 973, 978, {27775, 33837, 33851, 33864, 33877, 33890, 27818}, {4127, 7749, 7753, 7757, 7761, 7765, 4148}, {2775, 2113, 2488, 7769, 7769, 2113, 2113}, {33902, 33910, 33920, 27869, 27875, 33927, 33933, 6304, 27892, 27901, 27909, 33939, 0}, {33902, 33910, 33920, 27869, 27875, 33927, 33933, 6304, 27892, 27901, 27909, 33939, 0}, {2861, 33767, 3951, 27931, 2804, 2878, 2882, 18684, 17286, 27944, 2898, 2902, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 2624, 268, {2374,14129,24825,2926,14,1328,0,0,0,0,0,0,0,0},{7643,4281,33948,33957,0,0,0,0},{301,33966,0,0,0,0,0,0,0,0,0,0},{307,0,0,0,0,0,0,0,0}},
+       {9785, 1996, 307, 301, 2005, 9803, 9816, 9819, {9822, 9830, 9838, 2426, 2433, 2441, 9845}, {9853, 9858, 9863, 2469, 2473, 2477, 9867}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {7167, 7175, 4899, 2517, 2523, 2527, 2532, 9872, 2544, 2554, 2562, 2571, 0}, {7167, 7175, 4899, 2517, 2523, 2527, 2532, 9872, 2544, 2554, 2562, 2571, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 2604, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1996,2670,2926,1328,0,0,0,0,0,0,0,0,0,0},{9785,9880,0,0,0,0,0,0},{301,1404,9903,0,0,0,0,0,0,0,0,0},{307,1420,9913,0,0,0,0,0,0}},
+       {3755, 2670, 1420, 1404, 2005, 4788, 0, 0, {33977, 33988, 34012, 34042, 34059, 34081, 34090}, {14265, 14268, 14273, 14279, 14283, 7409, 14288}, {251, 239, 241, 243, 245, 247, 249}, {34101, 34114, 600, 34127, 620, 34138, 34147, 641, 34156, 34173, 34188, 34201, 0}, {34101, 34114, 600, 34127, 620, 34138, 34147, 641, 34156, 34173, 34188, 34201, 0}, {14362, 7848, 2588, 2592, 14366, 14370, 14374, 14378, 14382, 2612, 14386, 14390, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{3755,5510,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3755, 270, 307, 301, 2005, 55, 973, 978, {17711, 17725, 17735, 17746, 17760, 17771, 17782}, {17795, 17800, 17805, 17812, 17818, 17824, 17830}, {2775, 2494, 2486, 7409, 2775, 12314, 2113}, {17835, 17843, 17851, 17858, 17867, 17877, 17887, 17893, 17901, 17916, 17934, 17942, 0}, {17835, 17843, 17851, 17858, 17867, 17877, 17887, 17893, 17901, 17916, 17934, 17942, 0}, {17950, 17954, 17851, 17960, 17964, 17969, 17887, 17975, 17980, 17987, 17994, 17999, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1347,2926,1328,0,0,0,0,0,0,0,0,0},{3755,5510,9937,9926,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {5510, 270, 1420, 1404, 2005, 55, 18004, 18007, {18011, 18016, 10448, 10455, 18022, 18029, 10472}, {18036, 18040, 10486, 10490, 18044, 10498, 10502}, {12314, 14526, 2113, 10506, 4442, 4155, 2113}, {10508, 10516, 18048, 2798, 10531, 2878, 18052, 18058, 2825, 2835, 2843, 18063, 0}, {10508, 10516, 18048, 2798, 10531, 2878, 18052, 18058, 2825, 2835, 2843, 18063, 0}, {2861, 2865, 18048, 2874, 10531, 2878, 2882, 18058, 2890, 2894, 2898, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {34214, 2670, 307, 301, 2005, 18717, 0, 0, {18724, 18739, 18754, 18769, 18786, 18803, 18812}, {18823, 18830, 18837, 18844, 18851, 18858, 18865}, {18872, 18875, 8540, 8543, 8537, 18878, 18881}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12864, 12871, 12878, 12885, 8596, 12798, 12805, 12892, 12899, 12906, 12913, 12920, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,18706,2926,14,1328,0,0,0,0,0,0,0,0},{34214,3755,5510,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {5510, 1354, 6460, 5006, 44, 55, 18884, 18912, {18934, 18953, 18972, 18997, 19016, 19050, 19075}, {19094, 19104, 19114, 19130, 19140, 19165, 19181}, {19191, 19195, 19202, 19206, 19213, 19220, 19227}, {19231, 19259, 19293, 19309, 19328, 19335, 19345, 19361, 19377, 19408, 19430, 19452, 0}, {19231, 19259, 19293, 19309, 19328, 19335, 19345, 19361, 19377, 19408, 19430, 19452, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 5, 2624, 268, {1354,2335,2926,2374,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{5006,2350,19477,19486,0,0,0,0,0,0,0,0},{6460,2366,19494,19506,0,0,0,0,0}},
+       {34235, 1467, 1420, 1404, 34311, 34343, 0, 0, {24851, 24858, 24869, 24882, 24895, 24906, 24919}, {24930, 24935, 24940, 24945, 24950, 24955, 24960}, {0, 0, 0, 0, 0, 0, 0}, {24965, 24980, 24989, 24996, 25009, 25016, 25027, 25036, 25045, 25052, 25063, 25074, 0}, {24965, 24980, 24989, 24996, 25009, 25016, 25027, 25036, 25045, 25052, 25063, 25074, 0}, {25085, 25092, 25099, 25106, 25113, 25120, 25127, 25134, 25141, 25148, 25155, 25162, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1848,1328,1837,1859,1866,1873,1880,0,0,0,0},{34235,34378,0,0,0,0,0,0},{1404,0,0,0,0,0,0,0,0,0,0,0},{1420,0,0,0,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {1445, 3010, 1420, 1404, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {33603, 33610, 33617, 33624, 33631, 33638, 33645}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,1866,1880,1467,1837,1328,0,0,0,0,0,0},{1445,6634,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {34462, 2670, 307, 301, 2005, 55, 2681, 2687, {2694, 2702, 2709, 2718, 2727, 2738, 2746}, {2754, 2757, 2760, 2763, 2766, 2769, 2772}, {2113, 2486, 2775, 2486, 2775, 2492, 2113}, {34482, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {34482, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {34490, 2865, 2869, 2874, 2804, 2878, 2882, 2886, 2890, 2894, 2898, 2902, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,34495,1328,0,0,0,0,0,0,0,0,0,0},{34462,34505,34517,9926,0,0,0,0},{301,1404,34527,34539,8105,8110,8097,0,0,0,0,0},{307,1420,2970,2956,2985,0,0,0,0}},
+       {2992, 14078, 3019, 3030, 2005, 55, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {14078,1339,1347,3010,14,270,3990,5523,1328,1880,1837,0,0,0},{2992,3755,0,0,0,0,0,0},{3030,1404,301,0,0,0,0,0,0,0,0,0},{3019,1420,307,0,0,0,0,0,0}},
+       {4028, 270, 1420, 1404, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1339,1347,1354,1363,1328,2906,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{1404,301,1409,0,0,0,0,0,0,0,0,0},{1420,307,1428,0,0,0,0,0,0}},
+       {3755, 1328, 307, 301, 44, 4788, 3804, 3807, {4795, 4804, 4810, 4816, 4825, 4831, 4840}, {4847, 4852, 4857, 4862, 4867, 4872, 4877}, {2775, 2494, 2486, 2486, 4155, 4157, 2113}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4961, 4967, 4899, 4974, 4910, 4914, 4979, 4927, 4985, 1313, 1318, 4991, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {1328,5894,1354,6158,14,3743,0,0,0,0,0,0,0,0},{3755,9926,0,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {17326, 1996, 1420, 1404, 2005, 17344, 17358, 17363, {34550, 34558, 34566, 34574, 34586, 34595, 34607}, {17448, 17453, 17458, 17463, 17468, 17473, 17478}, {2113, 2486, 2775, 6251, 2775, 15394, 2494}, {17483, 17500, 17513, 17527, 17540, 17553, 17566, 17580, 17592, 17606, 17620, 17634, 0}, {17483, 17500, 17513, 17527, 17540, 17553, 17566, 17580, 17592, 17606, 17620, 17634, 0}, {34618, 34629, 34636, 34644, 34651, 34658, 34665, 34673, 34679, 34687, 34695, 34703, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {1996,2670,2926,1328,0,0,0,0,0,0,0,0,0,0},{17326,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {1445, 3010, 1960, 1943, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {1589, 1596, 1603, 1610, 1617, 1624, 1631}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,1866,1880,1467,1837,1328,0,0,0,0,0,0},{1445,6634,0,0,0,0,0,0},{1943,1951,1404,301,0,0,0,0,0,0,0,0},{1960,1971,1420,307,0,0,0,0,0}},
+       {2651, 2670, 307, 301, 2005, 55, 2681, 2687, {2694, 2702, 2709, 2718, 2727, 2738, 2746}, {2754, 2757, 2760, 2763, 2766, 2769, 2772}, {2113, 2486, 2775, 2486, 2775, 2492, 2113}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2861, 2865, 2869, 2874, 2804, 2878, 2882, 2886, 2890, 2894, 2898, 2902, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,2918,2926,1996,1328,0,0,0,0,0,0,0,0},{2651,1983,2933,0,0,0,0,0},{301,1404,2350,2945,0,0,0,0,0,0,0,0},{307,2956,2970,2985,0,0,0,0,0}},
+       {34710, 270, 3019, 3030, 44, 3796, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1347,1328,5894,34721,3990,14129,0,0,0,0,0,0},{34710,34729,6451,3767,0,0,0,0},{3030,35,301,1404,0,0,0,0,0,0,0,0},{3019,23,307,1420,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,14078,1347,1354,1328,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {4771, 2670, 307, 301, 2005, 4788, 3804, 3807, {4795, 4804, 4810, 4816, 4825, 4831, 4840}, {4847, 4852, 4857, 4862, 4867, 4872, 4877}, {2775, 2494, 2486, 2486, 4155, 4157, 2113}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4961, 4967, 4899, 4974, 4910, 4914, 4979, 4927, 4985, 1313, 1318, 4991, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,33784,2926,1328,0,0,0,0,0,0,0,0,0},{4771,3755,4997,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {4014, 2374, 1420, 1404, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 2624, 268, {2374,1354,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{1404,301,35,0,0,0,0,0,0,0,0,0},{1420,307,23,0,0,0,0,0,0}},
+       {1445, 3010, 1420, 1404, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {33603, 33610, 33617, 33624, 33631, 33638, 33645}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,1866,1880,1467,1837,1328,0,0,0,0,0,0},{1445,34742,34769,2626,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {2651, 2670, 307, 301, 2005, 55, 2681, 2687, {2694, 2702, 2709, 2718, 2727, 2738, 2746}, {2754, 2757, 2760, 2763, 2766, 2769, 2772}, {2113, 2486, 2775, 2486, 2775, 2492, 2113}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2777, 2784, 2792, 2798, 2804, 2808, 2813, 2818, 2825, 2835, 2843, 2852, 0}, {2861, 2865, 2869, 2874, 2804, 2878, 2882, 2886, 2890, 2894, 2898, 2902, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,2918,33784,2926,1328,0,0,0,0,0,0,0,0},{2651,1983,33794,0,0,0,0,0},{301,1404,8082,8072,2945,8105,8110,8091,8097,0,0,0},{307,1420,8142,8155,2970,2956,2985,0,0}},
+       {2992, 14078, 3019, 3030, 2005, 55, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {14078,1339,14,2918,1328,0,0,0,0,0,0,0,0,0},{2992,3755,0,0,0,0,0,0},{3030,35,301,1404,0,0,0,0,0,0,0,0},{3019,23,307,1420,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1347,1354,1328,0,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {4771, 270, 307, 301, 2005, 4788, 3804, 3807, {4795, 4804, 4810, 4816, 4825, 4831, 4840}, {4847, 4852, 4857, 4862, 4867, 4872, 4877}, {2775, 2494, 2486, 2486, 4155, 4157, 2113}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4961, 4967, 4899, 4974, 4910, 4914, 4979, 4927, 4985, 1313, 1318, 4991, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1363,1354,1328,0,0,0,0,0,0,0,0,0},{4771,4997,3755,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {4014, 2374, 1420, 1404, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 2624, 268, {2374,1354,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{1404,301,35,0,0,0,0,0,0,0,0,0},{1420,307,23,0,0,0,0,0,0}},
+       {5510, 270, 307, 301, 2005, 55, 973, 978, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1347,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {4028, 3979, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3979,3970,1347,14,1354,1328,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {4771, 270, 307, 301, 2005, 4788, 3804, 3807, {4795, 4804, 4810, 4816, 4825, 4831, 4840}, {4847, 4852, 4857, 4862, 4867, 4872, 4877}, {2775, 2494, 2486, 2486, 4155, 4157, 2113}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4882, 4890, 4899, 4904, 4910, 4914, 4919, 4927, 4933, 4943, 1143, 4951, 0}, {4961, 4967, 4899, 4974, 4910, 4914, 4979, 4927, 4985, 1313, 1318, 4991, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 266, 268, {270,14,1363,1354,1328,0,0,0,0,0,0,0,0,0},{4771,4997,3755,0,0,0,0,0},{301,1404,5006,5012,5022,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 34785, 34795, {11560, 34803, 8961, 11585, 8976, 8986, 8992}, {8999, 9003, 9007, 11606, 9015, 9020, 9024}, {9028, 9030, 9032, 1076, 9034, 9030, 1076}, {2496, 2503, 34814, 2517, 2523, 2596, 2600, 11626, 34819, 34829, 34837, 34846, 0}, {2496, 2503, 34814, 2517, 2523, 2596, 2600, 11626, 34819, 34829, 34837, 34846, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 11633, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4014, 2374, 1420, 1404, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{1404,301,35,0,0,0,0,0,0,0,0,0},{1420,307,23,0,0,0,0,0,0}},
+       {5510, 1837, 23, 35, 2005, 55, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1837,1880,1328,0,0,0,0,0,0,0,0,0,0,0},{5510,0,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,3979,1347,1354,1328,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 44, 2385, 34855, 34873, {34888, 34901, 34920, 34933, 34948, 34965, 11259}, {34976, 34983, 34990, 34997, 35004, 35011, 35018}, {555, 558, 35025, 564, 567, 558, 564}, {35028, 35041, 600, 609, 14822, 14829, 14838, 641, 35056, 35075, 35090, 35107, 0}, {35028, 35041, 600, 609, 14822, 14829, 14838, 641, 35056, 35075, 35090, 35107, 0}, {35124, 35131, 35138, 35145, 14822, 35152, 35159, 35166, 35173, 35180, 35187, 35194, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,1404,0,0,0,0,0,0,0,0,0},{23,307,1420,0,0,0,0,0,0}},
+       {3767, 270, 23, 35, 44, 3796, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,1328,0,0,0,0,0,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1347,1354,1328,0,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,1404,0,0,0,0,0,0,0,0,0},{23,307,1420,0,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,14078,1347,1354,1328,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 34785, 34795, {11560, 34803, 8961, 11585, 8976, 8986, 8992}, {8999, 9003, 9007, 11606, 9015, 9020, 9024}, {9028, 9030, 9032, 1076, 9034, 9030, 1076}, {2496, 2503, 34814, 2517, 2523, 2596, 2600, 11626, 34819, 34829, 34837, 34846, 0}, {2496, 2503, 34814, 2517, 2523, 2596, 2600, 11626, 34819, 34829, 34837, 34846, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 11633, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {35201, 35225, 35234, 35243, 35254, 35263, 35276, 35285, 35290, 35301, 35323, 35347, 0}, {35201, 35225, 35234, 35243, 35254, 35263, 35276, 35285, 35290, 35301, 35323, 35347, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,1404,0,0,0,0,0,0,0,0,0},{23,307,1420,0,0,0,0,0,0}},
+       {14099, 270, 23, 35, 2005, 55, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,1328,0,0,0,0,0,0,0,0,0,0,0,0},{14099,0,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1347,1354,1328,0,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 34855, 34873, {34888, 34901, 34920, 8443, 34948, 34965, 11259}, {34976, 34983, 34990, 35369, 35004, 35011, 35018}, {555, 558, 35025, 564, 567, 558, 564}, {35028, 35041, 600, 609, 14822, 35152, 35159, 641, 35056, 35075, 35090, 35107, 0}, {35028, 35041, 600, 609, 14822, 35152, 35159, 641, 35056, 35075, 35090, 35107, 0}, {35124, 35131, 35138, 35145, 14822, 35152, 35159, 35166, 35173, 35180, 35187, 35194, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {35201, 35225, 35234, 35243, 35254, 35263, 35276, 35285, 35290, 35301, 35323, 35347, 0}, {35201, 35225, 35234, 35243, 35254, 35263, 35276, 35285, 35290, 35301, 35323, 35347, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,1404,0,0,0,0,0,0,0,0,0},{23,307,1420,0,0,0,0,0,0}},
+       {14099, 270, 23, 35, 2005, 55, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,1328,0,0,0,0,0,0,0,0,0,0,0,0},{14099,0,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1347,1354,1328,0,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,301,1404,0,0,0,0,0,0,0,0},{23,3019,307,1420,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 34785, 34795, {11560, 34803, 8961, 11585, 8976, 8986, 8992}, {8999, 9003, 9007, 11606, 9015, 9020, 9024}, {9028, 9030, 9032, 1076, 9034, 9030, 1076}, {2496, 2503, 34814, 2517, 2523, 2596, 2600, 11626, 34819, 34829, 34837, 34846, 0}, {2496, 2503, 34814, 2517, 2523, 2596, 2600, 11626, 34819, 34829, 34837, 34846, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 11633, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {35201, 35225, 35234, 35243, 35254, 35263, 35276, 35285, 35290, 35301, 35323, 35347, 0}, {35201, 35225, 35234, 35243, 35254, 35263, 35276, 35285, 35290, 35301, 35323, 35347, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,1404,0,0,0,0,0,0,0,0,0},{23,307,1420,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1328,1880,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {4028, 270, 1420, 1404, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1347,1354,1328,0,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 34855, 34873, {34888, 34901, 34920, 8443, 34948, 34965, 11259}, {34976, 34983, 34990, 35369, 35004, 35011, 35018}, {555, 558, 35025, 564, 567, 558, 564}, {35028, 35041, 600, 609, 14822, 35152, 35159, 641, 35056, 35075, 35090, 35107, 0}, {35028, 35041, 600, 609, 14822, 35152, 35159, 641, 35056, 35075, 35090, 35107, 0}, {35124, 35131, 35138, 35145, 14822, 35152, 35159, 35166, 35173, 35180, 35187, 35194, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,1404,0,0,0,0,0,0,0,0,0},{23,307,1420,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 44, 3796, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1328,1880,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {4028, 2374, 1420, 1404, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 2624, 268, {2374,1354,14,1347,1328,0,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,1404,0,0,0,0,0,0,0,0,0},{23,307,1420,0,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {270,14,1347,1354,1328,0,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,1404,0,0,0,0,0,0,0,0,0},{23,307,1420,0,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1347,1354,1328,0,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {4014, 270, 23, 35, 44, 55, 0, 0, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {63, 72, 79, 99, 119, 143, 167, 174, 185, 196, 205, 223, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 6, 266, 268, {270,14,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{35,301,1404,0,0,0,0,0,0,0,0,0},{23,307,1420,0,0,0,0,0,0}},
+       {5510, 2374, 307, 301, 44, 55, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,2335,2926,1328,0,0,0,0,0,0,0,0,0},{5510,3755,0,0,0,0,0,0},{301,1404,1951,0,0,0,0,0,0,0,0,0},{307,1420,1971,1960,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,1347,1354,1328,0,0,0,0,0,0,0,0,0},{4028,4254,4281,0,0,0,0,0},{35,3030,1404,301,0,0,0,0,0,0,0,0},{23,3019,1420,307,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,32989,1328,0,0,0,0,0,0,0,0,0,0},{4028,0,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {35376, 3010, 3019, 3030, 44, 4788, 3804, 3807, {3810, 3817, 3824, 3832, 3842, 3851, 3858}, {3867, 3871, 3875, 3879, 3883, 3887, 3891}, {2113, 2486, 2488, 3895, 2488, 2492, 2113}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {3897, 3905, 3914, 2798, 3920, 3924, 3929, 2818, 2825, 3934, 2843, 3942, 0}, {2861, 2865, 3951, 2874, 3920, 2878, 2882, 2886, 2890, 3955, 2898, 3959, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,270,14,1328,0,0,0,0,0,0,0,0,0},{35376,13623,0,0,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,32989,1328,0,0,0,0,0,0,0,0,0,0},{4028,0,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,32989,1328,0,0,0,0,0,0,0,0,0,0},{4028,0,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {4028, 270, 23, 35, 4057, 55, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {270,14,32989,1328,0,0,0,0,0,0,0,0,0,0},{4028,0,0,0,0,0,0,0},{35,301,0,0,0,0,0,0,0,0,0,0},{23,307,0,0,0,0,0,0,0}},
+       {3767, 3787, 3019, 3030, 4057, 7671, 973, 978, {4072, 4080, 4086, 4093, 4104, 4111, 4119}, {4127, 4131, 2588, 4135, 4140, 4144, 4148}, {2775, 2494, 2486, 4153, 4155, 4157, 2113}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4159, 4165, 4173, 1097, 4179, 4184, 4190, 4196, 4203, 1135, 4214, 4224, 0}, {4234, 2584, 2588, 4238, 4179, 2596, 2600, 4242, 2608, 4246, 2616, 4250, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3787,3963,3970,3979,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 34855, 34873, {34888, 34901, 34920, 8443, 34948, 34965, 11259}, {34976, 34983, 34990, 35369, 35004, 35011, 35018}, {555, 558, 35025, 564, 567, 558, 564}, {35028, 35041, 600, 609, 14822, 35152, 35159, 641, 35056, 35075, 35090, 35107, 0}, {35028, 35041, 600, 609, 14822, 35152, 35159, 641, 35056, 35075, 35090, 35107, 0}, {35124, 35131, 35138, 35145, 14822, 35152, 35159, 35166, 35173, 35180, 35187, 35194, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 34785, 34795, {11560, 34803, 8961, 11585, 8976, 8986, 8992}, {8999, 9003, 9007, 11606, 9015, 9020, 9024}, {9028, 9030, 9032, 1076, 9034, 9030, 1076}, {2496, 2503, 34814, 2517, 2523, 2596, 2600, 11626, 34819, 34829, 34837, 34846, 0}, {2496, 2503, 34814, 2517, 2523, 2596, 2600, 11626, 34819, 34829, 34837, 34846, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 11633, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3755, 2670, 1420, 1404, 2005, 4788, 0, 0, {33977, 33988, 34012, 34042, 34059, 34081, 34090}, {14265, 14268, 14273, 14279, 14283, 7409, 14288}, {251, 239, 241, 243, 245, 247, 249}, {34101, 34114, 600, 34127, 620, 34138, 34147, 641, 34156, 34173, 34188, 34201, 0}, {34101, 34114, 600, 34127, 620, 34138, 34147, 641, 34156, 34173, 34188, 34201, 0}, {14362, 7848, 2588, 2592, 14366, 14370, 14374, 14378, 14382, 2612, 14386, 14390, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{3755,5510,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1445, 1467, 1420, 1404, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {1589, 1596, 1603, 1610, 1617, 1624, 1631}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1666, 1673, 1680, 1687, 1694, 1701, 1708, 1715, 1722, 1729, 1736, 1746, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1328,1837,1848,1859,1866,1873,1880,0,0,0,0},{1445,1889,1916,0,0,0,0,0},{1404,301,1943,1951,0,0,0,0,0,0,0,0},{1420,307,1960,1971,0,0,0,0,0}},
+       {1983, 2670, 307, 301, 2005, 2385, 2393, 2398, {2403, 9830, 33814, 2426, 2433, 2441, 33821}, {2456, 9858, 33829, 2469, 2473, 2477, 6027}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2580, 2584, 2588, 2592, 4910, 2596, 2600, 2604, 2608, 2612, 2616, 6129, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,2926,1328,2906,0,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,7291,5006,0,0,0,0,0,0,0,0},{307,1420,7302,6460,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 34785, 34795, {8940, 8949, 8961, 8968, 8976, 8986, 8992}, {8999, 9003, 9007, 9011, 9015, 9020, 9024}, {0, 0, 0, 0, 0, 0, 0}, {2496, 2503, 34814, 2517, 2523, 2527, 2532, 11626, 34819, 34829, 34837, 34846, 0}, {2496, 2503, 34814, 2517, 2523, 2527, 2532, 11626, 34819, 34829, 34837, 34846, 0}, {2580, 2584, 2588, 2592, 2523, 2596, 2600, 11633, 2608, 2612, 2616, 2620, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3755, 2670, 1420, 1404, 2005, 4788, 0, 0, {14176, 14182, 14196, 14219, 14233, 14249, 14256}, {14265, 14268, 14273, 14279, 14283, 7409, 14288}, {251, 239, 241, 243, 245, 247, 249}, {14292, 14299, 10127, 14306, 3920, 14312, 14318, 14324, 14331, 14340, 14348, 14355, 0}, {14292, 14299, 10127, 14306, 3920, 14312, 14318, 14324, 14331, 14340, 14348, 14355, 0}, {14362, 7848, 2588, 2592, 14366, 14370, 14374, 14378, 14382, 2612, 14386, 14390, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{3755,5510,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {34214, 2670, 307, 301, 2005, 18717, 0, 0, {18724, 18739, 18754, 18769, 18786, 18803, 18812}, {18823, 18830, 18837, 18844, 18851, 18858, 18865}, {18872, 18875, 8540, 8543, 8537, 18878, 18881}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12864, 12871, 12878, 12885, 8596, 12798, 12805, 12892, 12899, 12906, 12913, 12920, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {2670,1363,18706,2926,14,1328,0,0,0,0,0,0,0,0},{34214,3755,5510,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {24804, 24825, 1420, 1404, 24834, 4788, 0, 0, {24851, 24858, 24869, 24882, 24895, 24906, 24919}, {24930, 24935, 24940, 24945, 24950, 24955, 24960}, {0, 0, 0, 0, 0, 0, 0}, {24965, 24980, 24989, 24996, 25009, 25016, 25027, 25036, 25045, 25052, 25063, 25074, 0}, {24965, 24980, 24989, 24996, 25009, 25016, 25027, 25036, 25045, 25052, 25063, 25074, 0}, {25085, 25092, 25099, 25106, 25113, 25120, 25127, 25134, 25141, 25148, 25155, 25162, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 790, 268, {24825,1328,0,0,0,0,0,0,0,0,0,0,0,0},{24804,0,0,0,0,0,0,0},{1404,0,0,0,0,0,0,0,0,0,0,0},{1420,0,0,0,0,0,0,0,0}},
+       {1445, 3010, 1420, 1404, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {33603, 33610, 33617, 33624, 33631, 33638, 33645}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,1866,1880,1467,1837,1328,0,0,0,0,0,0},{1445,6634,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1445, 3010, 1420, 1404, 1476, 1492, 1505, 1512, {1519, 1529, 1539, 1549, 1559, 1569, 1579}, {33603, 33610, 33617, 33624, 33631, 33638, 33645}, {1638, 1642, 1646, 1650, 1654, 1658, 1662}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {1756, 1761, 1766, 1771, 1776, 1781, 1786, 1791, 1796, 1801, 1807, 1813, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,1866,1880,1467,1837,1328,0,0,0,0,0,0},{1445,6634,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {1983, 2670, 307, 301, 2005, 2385, 973, 978, {2403, 2411, 2418, 2426, 2433, 2441, 2448}, {7261, 7266, 7270, 7274, 7278, 7282, 7286}, {2113, 2486, 2488, 2490, 2488, 2492, 2494}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2496, 2503, 4899, 2517, 4910, 2527, 2532, 2537, 2544, 2554, 2562, 6099, 0}, {2580, 2584, 2588, 2592, 4910, 2596, 2600, 2604, 2608, 2612, 2616, 6129, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 2, 1, 790, 268, {2670,1363,2926,1328,2906,0,0,0,0,0,0,0,0,0},{1983,2637,0,0,0,0,0,0},{301,1404,7291,5006,0,0,0,0,0,0,0,0},{307,1420,7302,6460,0,0,0,0,0}},
+       {1983, 1996, 1420, 1404, 2005, 2385, 34855, 34873, {34888, 34901, 34920, 8443, 34948, 34965, 11259}, {34976, 34983, 34990, 35369, 35004, 35011, 35018}, {555, 558, 35025, 564, 567, 558, 564}, {35028, 35041, 600, 609, 14822, 35152, 35159, 641, 35056, 35075, 35090, 35107, 0}, {35028, 35041, 600, 609, 14822, 35152, 35159, 641, 35056, 35075, 35090, 35107, 0}, {35124, 35131, 35138, 35145, 14822, 35152, 35159, 35166, 35173, 35180, 35187, 35194, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1996,2926,9345,2670,9544,1363,11637,1328,0,0,0,0,0,0},{1983,2637,2651,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3755, 1363, 1420, 1404, 2005, 3796, 12587, 12599, {12611, 12626, 12641, 12656, 12673, 12692, 12703}, {12714, 12721, 12728, 12735, 12742, 12749, 12756}, {0, 0, 0, 0, 0, 0, 0}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12763, 12774, 8574, 12787, 8596, 12798, 12805, 8621, 12812, 12827, 12840, 12851, 0}, {12864, 12871, 12878, 12885, 8596, 12798, 12805, 12892, 12899, 12906, 12913, 12920, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 790, 268, {1363,1328,0,0,0,0,0,0,0,0,0,0,0,0},{3755,0,0,0,0,0,0,0},{1404,301,0,0,0,0,0,0,0,0,0,0},{1420,0,0,0,0,0,0,0,0}},
+       {18688, 18706, 307, 301, 2005, 18717, 0, 0, {33652, 33662, 33671, 33680, 33691, 33701, 33706}, {33713, 33719, 33724, 33729, 33734, 10104, 33738}, {33743, 2775, 2113, 7409, 2108, 7409, 2113}, {14292, 14299, 10127, 14306, 3920, 33745, 33750, 33755, 14331, 14340, 14348, 14355, 0}, {14292, 14299, 10127, 14306, 3920, 33745, 33750, 33755, 14331, 14340, 14348, 14355, 0}, {33762, 33767, 3951, 2874, 3920, 33745, 33750, 33771, 10482, 2894, 33775, 33780, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 1, 266, 268, {18706,1363,2926,14,1328,0,0,0,0,0,0,0,0,0},{18688,3755,5510,0,0,0,0,0},{301,1404,0,0,0,0,0,0,0,0,0,0},{307,1420,0,0,0,0,0,0,0}},
+       {34235, 1467, 1420, 1404, 34311, 34343, 0, 0, {24851, 24858, 24869, 24882, 24895, 24906, 24919}, {24930, 24935, 24940, 24945, 24950, 24955, 24960}, {0, 0, 0, 0, 0, 0, 0}, {24965, 24980, 24989, 24996, 25009, 25016, 25027, 25036, 25045, 25052, 25063, 25074, 0}, {24965, 24980, 24989, 24996, 25009, 25016, 25027, 25036, 25045, 25052, 25063, 25074, 0}, {25085, 25092, 25099, 25106, 25113, 25120, 25127, 25134, 25141, 25148, 25155, 25162, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {1467,1819,1828,1848,1328,1837,1859,1866,1873,1880,0,0,0,0},{34235,34378,0,0,0,0,0,0},{1404,0,0,0,0,0,0,0,0,0,0,0},{1420,0,0,0,0,0,0,0,0}},
+       {4014, 2374, 1420, 1404, 44, 55, 29227, 29237, {29250, 29257, 29263, 29270, 29276, 29282, 29290}, {29300, 29304, 29308, 29312, 29316, 29320, 29324}, {12314, 12314, 12314, 12314, 12314, 12314, 12314}, {29330, 29339, 29348, 29353, 29359, 29365, 29371, 29378, 29384, 29393, 29402, 29410, 0}, {29330, 29339, 29348, 29353, 29359, 29365, 29371, 29378, 29384, 29393, 29402, 29410, 0}, {29419, 29423, 3951, 29427, 3920, 29431, 29435, 29439, 29444, 29448, 29454, 29458, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 2624, 268, {2374,1354,1328,0,0,0,0,0,0,0,0,0,0,0},{4014,281,0,0,0,0,0,0},{1404,301,29462,0,0,0,0,0,0,0,0,0},{1420,307,0,0,0,0,0,0,0}},
+       {3767, 3010, 3019, 3030, 44, 3796, 0, 0, {30337, 30344, 30352, 30359, 30366, 30374, 30382}, {30389, 30392, 30395, 30398, 30401, 30404, 30407}, {2494, 2494, 2488, 2494, 12314, 4155, 12314}, {30410, 30418, 30428, 30434, 30442, 30447, 30452, 30457, 30464, 18669, 30472, 30480, 0}, {30410, 30418, 30428, 30434, 30442, 30447, 30452, 30457, 30464, 18669, 30472, 30480, 0}, {2861, 30488, 3951, 30492, 3920, 29431, 29435, 30496, 3891, 2894, 30500, 15342, 0}, {239, 241, 243, 245, 247, 249, 251, 253, 255, 257, 260, 263, 0}, 0, 0, 266, 268, {3010,1347,14,270,1880,1328,3990,0,0,0,0,0,0,0},{3767,4000,281,4014,0,0,0,0},{3030,35,1404,301,0,0,0,0,0,0,0,0},{3019,23,1420,307,0,0,0,0,0}}
 };
 
 
 static const NumberFormatEntry number_format_entries [] = {
-       {17764, 17767, 17764, 17767, 17764, 17767, 0, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 0, 0, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 0, 0, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 0, 0, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 2, 2, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 0, 0, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 0, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17799, 17777, 17781, 17786, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 17822, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 1, 0, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17832, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17842, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17846, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17850, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 12, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 1, 1, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17853, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17855, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17859, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17862, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17866, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 0, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17868, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 0, 0, 1, 0, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 0, 0, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17850, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17872, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17876, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17880, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17884, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 5, 1, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17888, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 10419, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17891, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17850, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17895, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17899, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17902, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 0, 1, 1, 1, 0, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17905, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 1, 0, 1, 1, 1, 0, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17913, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17850, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17917, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17920, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {2, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 17923, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 0, 3, 2, 2, 1, 0, 2, 2, {5, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17927, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17930, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 0, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 9891, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 0, 17797, 17799, 17777, 17781, 17786, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17850, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 12, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17934, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17941, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17945, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17952, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17959, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17934, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17934, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17934, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}, {2, 2, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 17967, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 3, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17977, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17981, 844, 17981, 844, 17981, 17983, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17988, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17853, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17981, 844, 17981, 844, 17981, 17983, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 12, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17850, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 17991, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18001, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17853, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 17794, 17792, 17794, 17792, 17794, 17853, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18005, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 3, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18015, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17853, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18018, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17981, 844, 17981, 844, 17981, 18020, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18025, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 4380, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17853, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 18035, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17838, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18039, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17838, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18049, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18052, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 1, 0, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 9891, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18062, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18066, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 18076, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 12, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18079, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 1, 0, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17853, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18089, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 1, 0, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18099, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18102, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 3, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17853, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17853, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18112, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18122, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 18125, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18129, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 3, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18139, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 17853, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18143, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 18153, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18157, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 11, 2, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 18167, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 12, 2, 1, 1, 1, 0, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17764, 17767, 17764, 17767, 17764, 17767, 18170, 17770, 17773, 17777, 17781, 17786, 1909, 17790, 1, 0, 1, 1, 3, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {17792, 844, 17792, 844, 17792, 844, 18180, 17797, 17773, 17777, 17781, 17786, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18183, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18187, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 18190, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 17853, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}},
-       {844, 17792, 844, 17792, 844, 17792, 0, 17797, 17799, 17777, 17803, 17813, 1909, 17790, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}, {3, -1, -1, -1, -1}}
+       {35395, 35398, 35395, 35398, 35395, 35398, 35401, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35448, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35468, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35468, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35472, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35476, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35481, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35490, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35494, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35476, 35454, 35497, 35460, 35502, 35436, 35509, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35468, 35454, 35513, 35460, 35431, 35436, 2624, 35441, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35529, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35533, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35537, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35540, 790, 35540, 790, 35540, 0, 35454, 35456, 35460, 35502, 35436, 35509, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 0, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35544, 35454, 35552, 35460, 35431, 35436, 2624, 35441, 5, 1, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35568, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 2, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35571, 35454, 0, 35460, 35431, 35436, 2624, 35441, 5, 1, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35476, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35582, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35586, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35589, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 3, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35594, 35454, 0, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35597, 35454, 35601, 35460, 35431, 35436, 2624, 35441, 5, 1, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35617, 35454, 35620, 35460, 35502, 35436, 35509, 35441, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35634, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35637, 35411, 0, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35641, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35645, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 0, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 0, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35476, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 12, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35651, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {790, 35443, 790, 35443, 790, 35443, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 12, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35655, 35454, 0, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35658, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35665, 35454, 0, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35669, 35454, 35676, 35460, 35431, 35436, 2624, 35441, 12, 2, 2, 2, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 35702, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {790, 35443, 790, 35443, 790, 35443, 35651, 35454, 0, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {790, 35443, 790, 35443, 790, 35443, 35651, 35454, 35734, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 0, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 35760, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {790, 35443, 790, 35443, 790, 35443, 35651, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 2, 2, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 0, 35460, 35431, 35436, 2624, 35441, 12, 1, 1, 1, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 35791, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 5, 1, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35801, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35806, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35809, 35454, 0, 35460, 35431, 35436, 2624, 35441, 5, 1, 1, 1, 2, 2, 2, 2, {3, -1}, {3, 0}, {3, 0}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35813, 35454, 0, 35460, 35431, 35436, 2624, 35441, 4, 1, 0, 0, 0, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 0, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35817, 35454, 0, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35825, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 1, 1, 1, 2, 1, 1, {3, 0}, {3, 0}, {3, 0}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35832, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, 2}, {3, 2}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35845, 35411, 0, 35460, 35431, 35436, 2624, 35441, 3, 0, 4, 2, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35848, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35852, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35476, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35852, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35801, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, 0}, {3, 0}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35540, 790, 35540, 790, 35540, 0, 35454, 35456, 35460, 35502, 35436, 35509, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 5, 1, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35856, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35806, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35401, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35448, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35859, 35454, 35863, 35460, 35431, 35436, 2624, 35441, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35472, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35476, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35481, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35490, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35494, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35476, 35454, 35497, 35460, 35502, 35436, 35509, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35468, 35454, 35513, 35460, 35431, 35436, 2624, 35441, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35529, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35476, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35533, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35537, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35540, 790, 35540, 790, 35540, 0, 35454, 35456, 35460, 35502, 35436, 35509, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 0, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35544, 35454, 35552, 35460, 35431, 35436, 2624, 35441, 5, 1, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35568, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 2, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35571, 35454, 0, 35460, 35431, 35436, 2624, 35441, 5, 1, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35476, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35582, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35586, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35589, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 3, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35594, 35454, 0, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35597, 35454, 35601, 35460, 35431, 35436, 2624, 35441, 5, 1, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35617, 35454, 35620, 35460, 35502, 35436, 35509, 35441, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35634, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35658, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35637, 35411, 0, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35641, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35645, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35873, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 0, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35476, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 12, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35651, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {790, 35443, 790, 35443, 790, 35443, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 12, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35655, 35454, 0, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35658, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35665, 35454, 0, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35878, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 35676, 35460, 35431, 35436, 2624, 35441, 12, 2, 2, 2, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 35702, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {790, 35443, 790, 35443, 790, 35443, 35651, 35454, 0, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {790, 35443, 790, 35443, 790, 35443, 35651, 35454, 35734, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 0, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 35760, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {790, 35443, 790, 35443, 790, 35443, 35651, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 2, 2, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 0, 35460, 35431, 35436, 2624, 35441, 12, 1, 1, 1, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 35791, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {790, 35443, 790, 35443, 790, 35443, 35801, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35806, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35809, 35454, 0, 35460, 35431, 35436, 2624, 35441, 5, 1, 1, 1, 2, 2, 2, 2, {3, -1}, {3, 0}, {3, 0}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35813, 35454, 0, 35460, 35431, 35436, 2624, 35441, 4, 1, 0, 0, 0, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35651, 35454, 0, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35817, 35454, 0, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, 2}, {3, 2}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35825, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 1, 1, 1, 2, 1, 1, {3, 0}, {3, 0}, {3, 0}},
+       {790, 35443, 790, 35443, 790, 35443, 35832, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, 2}, {3, 2}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35845, 35411, 0, 35460, 35431, 35436, 2624, 35441, 3, 0, 4, 2, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35848, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35852, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35852, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 2, 2, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35476, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35852, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35801, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, 0}, {3, 0}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 5, 1, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35856, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35806, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35884, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35468, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35894, 790, 35894, 790, 35894, 0, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35806, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35894, 790, 35894, 790, 35894, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35476, 35454, 35456, 35460, 35502, 35436, 35509, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35896, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35464, 35454, 0, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 0, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35904, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35911, 35454, 35676, 35460, 35431, 35436, 2624, 35441, 12, 2, 2, 2, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35801, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35915, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35863, 35460, 35431, 35436, 2624, 35441, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 9, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 15, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35575, 35460, 35502, 35436, 35509, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35925, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 0, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 7769, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35894, 790, 35894, 790, 35894, 0, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35935, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 0, 35454, 35863, 35460, 35431, 35436, 2624, 35441, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35894, 790, 35894, 790, 35894, 0, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35945, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35949, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35959, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35963, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35966, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 10506, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 2, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35976, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35982, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 1, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35992, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 35998, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 36008, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 36013, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 36023, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 36027, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 36035, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 36045, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35464, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 36055, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35848, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 9, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 36065, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 36075, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 36085, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35395, 35398, 35395, 35398, 35395, 35398, 36089, 35411, 35414, 35428, 35431, 35436, 2624, 35441, 3, 2, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35651, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, 2}, {3, 2}, {3, 2}},
+       {35443, 790, 35443, 790, 35443, 790, 36099, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 36102, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 2494, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 36106, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 14, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35479, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 0, 0, 0, 0, 1, 2, 2, 2, {3, -1}, {3, 0}, {3, 0}},
+       {35443, 790, 35443, 790, 35443, 790, 36109, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 36117, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35896, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 36122, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35476, 35454, 35456, 35460, 35502, 35436, 35509, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 35873, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35904, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 5, 1, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 36125, 35454, 35863, 35460, 35431, 35436, 2624, 35441, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 36125, 35454, 35863, 35460, 35431, 35436, 2624, 35441, 0, 0, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35476, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 12, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 790, 35443, 790, 35443, 790, 36117, 35454, 35456, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35443, 35443, 35443, 35443, 35443, 35658, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35878, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 35801, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 0, 1, 1, 1, 2, 2, 2, {3, 0}, {3, 0}, {3, 0}},
+       {35443, 35445, 35443, 35445, 35443, 35445, 0, 35454, 0, 35460, 35431, 35436, 2624, 35441, 8, 3, 0, 0, 3, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}},
+       {790, 35443, 790, 35443, 790, 35443, 35852, 35454, 0, 35460, 35431, 35436, 2624, 35441, 2, 2, 0, 0, 1, 2, 2, 2, {3, -1}, {3, -1}, {3, -1}}
 };
 
 
 static const CultureInfoEntry culture_entries [] = {
-       {0x0001, 0x007F, 0x0401, -1,18193, 18196, 18196, 18196, 18203, 18218, 18222, 18193, 0, {16777216, 0, 0, 0, 0}, 0, 0, { 1256, 20420, 10004, 720, ';' }},
-       {0x0002, 0x007F, 0x0402, -1,18226, 18229, 18229, 18229, 18239, 18258, 18262, 18226, 0, {0, 0, 0, 0, 0}, 1, 1, { 1251, 20420, 10007, 866, ';' }},
-       {0x0003, 0x007F, 0x0403, -1,18266, 18269, 18269, 18269, 18277, 18285, 18289, 18266, 0, {0, 0, 0, 0, 0}, 2, 2, { 1252, 500, 10000, 850, ';' }},
-       {0x0004, 0x007F, 0x0000, -1,18293, 18300, 18300, 18300, 18308, 18315, 18319, 18323, 0, {0, 0, 0, 0, 0}, 166, 166, { 936, 500, 10008, 936, ',' }},
-       {0x0005, 0x007F, 0x0405, -1,18326, 18329, 18329, 18329, 18335, 18345, 18349, 18326, 0, {0, 0, 0, 0, 0}, 4, 4, { 1250, 500, 10029, 852, ';' }},
-       {0x0006, 0x007F, 0x0406, -1,18353, 18356, 18356, 18356, 18363, 18369, 18373, 18353, 0, {0, 0, 0, 0, 0}, 5, 5, { 1252, 20277, 10000, 850, ';' }},
-       {0x0007, 0x007F, 0x0407, -1,18377, 18380, 18380, 18380, 18387, 18395, 18399, 18377, 0, {0, 0, 0, 0, 0}, 6, 6, { 1252, 20273, 10000, 850, ';' }},
-       {0x0008, 0x007F, 0x0408, -1,18403, 18406, 18406, 18406, 18412, 18429, 18433, 18403, 0, {0, 0, 0, 0, 0}, 7, 7, { 1253, 20273, 10006, 737, ';' }},
-       {0x0009, 0x007F, 0x0409, -1,18437, 18440, 18440, 18440, 18440, 18448, 18452, 18437, 0, {0, 0, 0, 0, 0}, 8, 8, { 1252, 37, 10000, 437, ',' }},
-       {0x000A, 0x007F, 0x0C0A, -1,18456, 18459, 18459, 18459, 18467, 18476, 18480, 18456, 0, {0, 0, 0, 0, 0}, 9, 9, { 1252, 20284, 10000, 850, ';' }},
-       {0x000B, 0x007F, 0x040B, -1,18484, 18487, 18487, 18487, 18495, 18501, 18505, 18484, 0, {0, 0, 0, 0, 0}, 10, 10, { 1252, 20278, 10000, 850, ';' }},
-       {0x000C, 0x007F, 0x040C, -1,5984, 18509, 18509, 18509, 18516, 18526, 18530, 5984, 0, {0, 0, 0, 0, 0}, 11, 11, { 1252, 20297, 10000, 850, ';' }},
-       {0x000D, 0x007F, 0x040D, -1,18534, 18537, 18537, 18537, 18544, 18555, 18559, 18534, 0, {0, 0, 0, 0, 0}, 12, 12, { 1255, 500, 10005, 862, ',' }},
-       {0x000E, 0x007F, 0x040E, -1,18563, 18566, 18566, 18566, 18576, 18583, 18587, 18563, 0, {0, 0, 0, 0, 0}, 13, 13, { 1250, 500, 10029, 852, ';' }},
-       {0x000F, 0x007F, 0x040F, -1,18591, 18594, 18594, 18594, 18604, 18614, 18618, 18591, 0, {0, 0, 0, 0, 0}, 14, 14, { 1252, 20871, 10079, 850, ';' }},
-       {0x0010, 0x007F, 0x0410, -1,18622, 18625, 18625, 18625, 18633, 18642, 18646, 18622, 0, {0, 0, 0, 0, 0}, 15, 15, { 1252, 20280, 10000, 850, ';' }},
-       {0x0011, 0x007F, 0x0411, -1,18650, 18653, 18653, 18653, 18662, 18672, 18676, 18650, 0, {0, 0, 0, 0, 0}, 16, 16, { 932, 20290, 10001, 932, ',' }},
-       {0x0012, 0x007F, 0x0412, -1,18680, 18683, 18683, 18683, 18690, 18700, 18704, 18680, 0, {0, 0, 0, 0, 0}, 17, 17, { 949, 20833, 10003, 949, ',' }},
-       {0x0013, 0x007F, 0x0413, -1,18708, 18711, 18711, 18711, 18717, 18728, 18732, 18708, 0, {0, 0, 0, 0, 0}, 18, 18, { 1252, 500, 10000, 850, ';' }},
-       {0x0014, 0x007F, 0x0414, -1,18736, 18739, 18739, 18739, 18749, 18755, 18759, 18736, 0, {0, 0, 0, 0, 0}, 19, 19, { 1252, 20277, 10000, 850, ';' }},
-       {0x0015, 0x007F, 0x0415, -1,18763, 18766, 18766, 18766, 18773, 18780, 18784, 18763, 0, {0, 0, 0, 0, 0}, 20, 20, { 1250, 20880, 10029, 852, ';' }},
-       {0x0016, 0x007F, 0x0416, -1,18788, 18791, 18791, 18791, 18802, 18813, 18817, 18788, 0, {0, 0, 0, 0, 0}, 21, 21, { 1252, 500, 10000, 850, ';' }},
-       {0x0018, 0x007F, 0x0418, -1,18821, 18824, 18824, 18824, 18833, 18842, 18846, 18821, 0, {0, 0, 0, 0, 0}, 22, 22, { 1250, 20880, 10029, 852, ';' }},
-       {0x0019, 0x007F, 0x0419, -1,18850, 18853, 18853, 18853, 18861, 18876, 18880, 18850, 0, {0, 0, 0, 0, 0}, 23, 23, { 1251, 20880, 10007, 866, ';' }},
-       {0x001A, 0x007F, 0x041A, -1,18884, 18887, 18887, 18887, 18896, 18905, 18909, 18884, 0, {0, 0, 0, 0, 0}, 24, 24, { 1250, 500, 10082, 852, ';' }},
-       {0x001B, 0x007F, 0x041B, -1,18913, 18916, 18916, 18916, 18923, 18934, 18938, 18913, 0, {0, 0, 0, 0, 0}, 25, 25, { 1250, 20880, 10029, 852, ';' }},
-       {0x001C, 0x007F, 0x041C, -1,18942, 18945, 18945, 18945, 18954, 18961, 18965, 18942, 0, {0, 0, 0, 0, 0}, 26, 26, { 1250, 20880, 10029, 852, ';' }},
-       {0x001D, 0x007F, 0x041D, -1,18969, 18972, 18972, 18972, 18980, 18988, 18992, 18969, 0, {0, 0, 0, 0, 0}, 27, 27, { 1252, 20278, 10000, 850, ';' }},
-       {0x001E, 0x007F, 0x041E, -1,18996, 18999, 18999, 18999, 19004, 19014, 19018, 18996, 0, {0, 0, 0, 0, 0}, 28, 28, { 874, 20838, 10021, 874, ',' }},
-       {0x001F, 0x007F, 0x041F, -1,19022, 19025, 19025, 19025, 19033, 19042, 19046, 19022, 0, {0, 0, 0, 0, 0}, 29, 29, { 1254, 20905, 10081, 857, ';' }},
-       {0x0021, 0x007F, 0x0421, -1,19050, 19053, 19053, 19053, 19064, 19081, 19085, 19050, 0, {0, 0, 0, 0, 0}, 30, 30, { 1252, 500, 10000, 850, ';' }},
-       {0x0022, 0x007F, 0x0422, -1,19089, 19092, 19092, 19092, 19102, 19123, 19127, 19089, 0, {0, 0, 0, 0, 0}, 31, 31, { 1251, 500, 10017, 866, ';' }},
-       {0x0023, 0x007F, 0x0423, -1,19131, 19134, 19134, 19134, 19145, 19164, 19168, 19131, 0, {0, 0, 0, 0, 0}, 32, 32, { 1251, 500, 10007, 866, ';' }},
-       {0x0024, 0x007F, 0x0424, -1,19172, 19175, 19175, 19175, 19185, 19199, 19203, 19172, 0, {0, 0, 0, 0, 0}, 33, 33, { 1250, 20880, 10029, 852, ';' }},
-       {0x0025, 0x007F, 0x0425, -1,19207, 19210, 19210, 19210, 19219, 19225, 19229, 19207, 0, {0, 0, 0, 0, 0}, 34, 34, { 1257, 500, 10029, 775, ';' }},
-       {0x0026, 0x007F, 0x0426, -1,19233, 19236, 19236, 19236, 19244, 19254, 19258, 19233, 0, {0, 0, 0, 0, 0}, 35, 35, { 1257, 500, 10029, 775, ';' }},
-       {0x0027, 0x007F, 0x0427, -1,19262, 19265, 19265, 19265, 19276, 19286, 19290, 19262, 0, {0, 0, 0, 0, 0}, 36, 36, { 1257, 500, 10029, 775, ';' }},
-       {0x0029, 0x007F, 0x0429, -1,19294, 19297, 19297, 19297, 19305, 19316, 19320, 19294, 0, {0, 0, 0, 0, 0}, 37, 37, { 1256, 20420, 10004, 720, ';' }},
-       {0x002A, 0x007F, 0x042A, -1,19324, 19327, 19327, 19327, 19338, 19353, 3169, 19324, 0, {0, 0, 0, 0, 0}, 38, 38, { 1258, 500, 10000, 1258, ',' }},
-       {0x002B, 0x007F, 0x042B, -1,19357, 19360, 19360, 19360, 19369, 19384, 19388, 19357, 0, {0, 0, 0, 0, 0}, 39, 39, { 0, 500, 2, 1, ',' }},
-       {0x002D, 0x007F, 0x042D, -1,19392, 19395, 19395, 19395, 19402, 19410, 19414, 19392, 0, {0, 0, 0, 0, 0}, 40, 40, { 1252, 500, 10000, 850, ';' }},
-       {0x002F, 0x007F, 0x042F, -1,19418, 19421, 19421, 19421, 19432, 19453, 19457, 19418, 0, {0, 0, 0, 0, 0}, 41, 41, { 1251, 500, 10007, 866, ';' }},
-       {0x0036, 0x007F, 0x0436, -1,19461, 19464, 19464, 19464, 19474, 19485, 19489, 19461, 0, {0, 0, 0, 0, 0}, 42, 42, { 1252, 500, 10000, 850, ',' }},
-       {0x0037, 0x007F, 0x0437, -1,19493, 19496, 19496, 19496, 19505, 19527, 19531, 19493, 0, {0, 0, 0, 0, 0}, 43, 43, { 0, 500, 2, 1, ';' }},
-       {0x0038, 0x007F, 0x0438, -1,19535, 19538, 19538, 19538, 19546, 19556, 19560, 19535, 0, {0, 0, 0, 0, 0}, 44, 44, { 1252, 20277, 10079, 850, ';' }},
-       {0x0039, 0x007F, 0x0439, -1,19564, 19567, 19567, 19567, 19573, 19589, 19593, 19564, 0, {0, 0, 0, 0, 0}, 45, 45, { 0, 500, 2, 1, ',' }},
-       {0x0041, 0x007F, 0x0441, -1,19597, 19600, 19600, 19600, 19608, 19618, 19622, 19597, 0, {0, 0, 0, 0, 0}, 46, 46, { 1252, 500, 10000, 437, ',' }},
-       {0x0047, 0x007F, 0x0447, -1,19626, 19629, 19629, 19629, 19638, 19660, 19664, 19626, 0, {0, 0, 0, 0, 0}, 47, 47, { 0, 500, 2, 1, ',' }},
-       {0x0049, 0x007F, 0x0449, -1,19668, 19671, 19671, 19671, 19677, 19693, 19697, 19668, 0, {0, 0, 0, 0, 0}, 48, 48, { 0, 500, 2, 1, ',' }},
-       {0x004A, 0x007F, 0x044A, -1,19701, 19704, 19704, 19704, 19711, 19730, 19734, 19701, 0, {0, 0, 0, 0, 0}, 49, 49, { 0, 500, 2, 1, ',' }},
-       {0x004B, 0x007F, 0x044B, -1,19738, 19741, 19741, 19741, 19749, 19765, 19769, 19738, 0, {0, 0, 0, 0, 0}, 50, 50, { 0, 500, 2, 1, ',' }},
-       {0x004E, 0x007F, 0x044E, -1,19773, 19776, 19776, 19776, 19784, 19800, 1873, 19773, 0, {0, 0, 0, 0, 0}, 51, 51, { 0, 500, 2, 1, ',' }},
-       {0x0056, 0x007F, 0x0456, -1,19804, 19807, 19807, 19807, 19816, 19823, 19827, 19804, 0, {0, 0, 0, 0, 0}, 52, 52, { 1252, 500, 10000, 850, ',' }},
-       {0x0057, 0x007F, 0x0457, -1,19831, 19835, 19835, 19835, 19843, 19862, 19831, 19564, 0, {0, 0, 0, 0, 0}, 53, 53, { 0, 500, 2, 1, ',' }},
-       {0x0401, 0x0001, 0x0401, 174,19866, 19872, 19872, 19872, 19894, 18218, 18222, 18193, 11005, {16777216, 0, 0, 0, 0}, 54, 54, { 1256, 20420, 10004, 720, ';' }},
-       {0x0402, 0x0002, 0x0402, 19,19943, 19949, 19949, 19949, 19970, 18258, 18262, 18226, 20008, {0, 0, 0, 0, 0}, 55, 55, { 1251, 20420, 10007, 866, ';' }},
-       {0x0403, 0x0003, 0x0403, 61,20011, 20017, 20017, 20017, 20033, 18285, 18289, 18266, 20051, {0, 0, 0, 0, 0}, 56, 56, { 1252, 500, 10000, 850, ';' }},
-       {0x0404, 0x7C04, 0x0404, 207,20054, 20060, 20060, 20060, 20077, 20093, 18319, 18323, 20097, {0, 0, 0, 0, 0}, 57, 57, { 950, 500, 10002, 950, ',' }},
-       {0x0405, 0x0005, 0x0405, 49,20100, 20106, 20106, 20106, 20129, 18345, 18349, 18326, 20159, {0, 0, 0, 0, 0}, 58, 58, { 1250, 500, 10029, 852, ';' }},
-       {0x0406, 0x0006, 0x0406, 52,20162, 20168, 20168, 20168, 20185, 18369, 18373, 18353, 20201, {0, 0, 0, 0, 0}, 59, 59, { 1252, 20277, 10000, 850, ';' }},
-       {0x0407, 0x0007, 0x0407, 50,20204, 20210, 20210, 20210, 20227, 18395, 18399, 18377, 4304, {0, 0, 0, 0, 0}, 60, 60, { 1252, 20273, 10000, 850, ';' }},
-       {0x0408, 0x0008, 0x0408, 81,20249, 20255, 20255, 20255, 20270, 18429, 18433, 18403, 20302, {0, 0, 0, 0, 0}, 61, 61, { 1253, 20273, 10006, 737, ';' }},
-       {0x0409, 0x0009, 0x0409, 212,20305, 20311, 20311, 20311, 20311, 18448, 18452, 18437, 20335, {0, 0, 0, 0, 0}, 62, 62, { 1252, 37, 10000, 437, ',' }},
-       {0x040B, 0x000B, 0x040B, 63,20338, 20344, 20344, 20344, 20362, 18501, 18505, 18484, 20376, {0, 0, 0, 0, 0}, 63, 63, { 1252, 20278, 10000, 850, ';' }},
-       {0x040C, 0x000C, 0x040C, 68,20379, 20385, 20385, 20385, 20401, 18526, 18530, 5984, 20420, {0, 0, 0, 0, 0}, 64, 64, { 1252, 20297, 10000, 850, ';' }},
-       {0x040D, 0x000D, 0x040D, 92,20423, 20429, 20429, 20429, 20445, 18555, 18559, 18534, 20469, {0, 0, 0, 0, 0}, 65, 65, { 1255, 500, 10005, 862, ',' }},
-       {0x040E, 0x000E, 0x040E, 89,20472, 20478, 20478, 20478, 20498, 18583, 18587, 18563, 20521, {0, 0, 0, 0, 0}, 66, 66, { 1250, 500, 10029, 852, ';' }},
-       {0x040F, 0x000F, 0x040F, 97,20524, 20530, 20530, 20530, 20550, 18614, 18618, 18591, 20570, {0, 0, 0, 0, 0}, 67, 67, { 1252, 20871, 10079, 850, ';' }},
-       {0x0410, 0x0010, 0x0410, 98,20573, 20579, 20579, 20579, 20595, 18642, 18646, 18622, 20613, {0, 0, 0, 0, 0}, 68, 68, { 1252, 20280, 10000, 850, ';' }},
-       {0x0411, 0x0011, 0x0411, 101,20616, 20622, 20622, 20622, 20639, 18672, 18676, 18650, 20658, {0, 0, 0, 0, 0}, 69, 69, { 932, 20290, 10001, 932, ',' }},
-       {0x0412, 0x0012, 0x0412, 109,20661, 20667, 20667, 20667, 20688, 18700, 18704, 18680, 20713, {0, 0, 0, 0, 0}, 70, 70, { 949, 20833, 10003, 949, ',' }},
-       {0x0413, 0x0013, 0x0413, 149,20716, 20722, 20722, 20722, 20742, 18728, 18732, 18708, 20765, {0, 0, 0, 0, 0}, 71, 71, { 1252, 500, 10000, 850, ';' }},
-       {0x0414, 0x0014, 0x0414, 150,20768, 20774, 20800, 20800, 20827, 18755, 20849, 20853, 20856, {0, 0, 0, 0, 0}, 72, 72, { 1252, 20277, 10000, 850, ';' }},
-       {0x0415, 0x0015, 0x0415, 162,20859, 20865, 20865, 20865, 20881, 18780, 18784, 18763, 20897, {0, 0, 0, 0, 0}, 73, 73, { 1250, 20880, 10029, 852, ';' }},
-       {0x0416, 0x0016, 0x0416, 26,20900, 20906, 20906, 20906, 20926, 18813, 18817, 18788, 20946, {0, 0, 0, 0, 0}, 74, 74, { 1252, 500, 10000, 850, ';' }},
-       {0x0418, 0x0018, 0x0418, 171,20949, 20955, 20955, 20955, 20974, 18842, 18846, 18821, 20994, {0, 0, 0, 0, 0}, 75, 75, { 1250, 20880, 10029, 852, ';' }},
-       {0x0419, 0x0019, 0x0419, 172,20997, 21003, 21003, 21003, 21020, 18876, 18880, 18850, 21050, {0, 0, 0, 0, 0}, 76, 76, { 1251, 20880, 10007, 866, ';' }},
-       {0x041A, 0x001A, 0x041A, 88,21053, 21059, 21059, 21059, 21078, 18905, 18909, 18884, 21098, {0, 0, 0, 0, 0}, 77, 77, { 1250, 500, 10082, 852, ';' }},
-       {0x041B, 0x001B, 0x041B, 183,21101, 21107, 21107, 21107, 21125, 18934, 18938, 18913, 21159, {0, 0, 0, 0, 0}, 78, 78, { 1250, 20880, 10029, 852, ';' }},
-       {0x041C, 0x001C, 0x041C, 4,21162, 21168, 21168, 21168, 21187, 18961, 18965, 18942, 21207, {0, 0, 0, 0, 0}, 79, 79, { 1250, 20880, 10029, 852, ';' }},
-       {0x041D, 0x001D, 0x041D, 178,21210, 21216, 21216, 21216, 21233, 18988, 18992, 18969, 21251, {0, 0, 0, 0, 0}, 80, 80, { 1252, 20278, 10000, 850, ';' }},
-       {0x041E, 0x001E, 0x041E, 197,21254, 21260, 21260, 21260, 21276, 19014, 19018, 18996, 21316, {0, 0, 0, 0, 0}, 81, 81, { 874, 20838, 10021, 874, ',' }},
-       {0x041F, 0x001F, 0x041F, 204,21319, 21325, 21325, 21325, 21342, 19042, 19046, 19022, 21362, {0, 0, 0, 0, 0}, 82, 82, { 1254, 20905, 10081, 857, ';' }},
-       {0x0421, 0x0021, 0x0421, 90,21365, 21371, 21371, 21371, 21394, 19081, 19085, 19050, 21423, {0, 0, 0, 0, 0}, 83, 83, { 1252, 500, 10000, 850, ';' }},
-       {0x0422, 0x0022, 0x0422, 209,21426, 21432, 21432, 21432, 21452, 19123, 19127, 19089, 21490, {0, 0, 0, 0, 0}, 84, 84, { 1251, 500, 10017, 866, ';' }},
-       {0x0423, 0x0023, 0x0423, 30,21493, 21499, 21499, 21499, 21520, 19164, 19168, 19131, 21558, {0, 0, 0, 0, 0}, 85, 85, { 1251, 500, 10007, 866, ';' }},
-       {0x0424, 0x0024, 0x0424, 181,21561, 21567, 21567, 21567, 21588, 19199, 19203, 19172, 21614, {0, 0, 0, 0, 0}, 86, 86, { 1250, 20880, 10029, 852, ';' }},
-       {0x0425, 0x0025, 0x0425, 57,21617, 21623, 21623, 21623, 21642, 19225, 19229, 19207, 21656, {0, 0, 0, 0, 0}, 87, 87, { 1257, 500, 10029, 775, ';' }},
-       {0x0426, 0x0026, 0x0426, 121,21659, 21665, 21665, 21665, 21682, 19254, 19258, 19233, 21702, {0, 0, 0, 0, 0}, 88, 88, { 1257, 500, 10029, 775, ';' }},
-       {0x0427, 0x0027, 0x0427, 119,21705, 21711, 21711, 21711, 21734, 19286, 19290, 19262, 21754, {0, 0, 0, 0, 0}, 89, 89, { 1257, 500, 10029, 775, ';' }},
-       {0x0429, 0x0029, 0x0429, 96,21757, 21763, 21763, 21763, 21778, 19316, 19320, 19294, 21802, {0, 0, 0, 0, 0}, 90, 90, { 1256, 20420, 10004, 720, ';' }},
-       {0x042A, 0x002A, 0x042A, 220,21805, 21811, 21811, 21811, 21832, 19353, 3169, 19324, 21860, {0, 0, 0, 0, 0}, 91, 91, { 1258, 500, 10000, 1258, ',' }},
-       {0x042B, 0x002B, 0x042B, 5,21863, 21869, 21869, 21869, 21888, 19384, 19388, 19357, 465, {0, 0, 0, 0, 0}, 92, 92, { 0, 500, 2, 1, ',' }},
-       {0x042D, 0x002D, 0x042D, 61,21953, 21959, 21959, 21959, 21974, 19410, 19414, 19392, 20051, {0, 0, 0, 0, 0}, 93, 93, { 1252, 500, 10000, 850, ';' }},
-       {0x042F, 0x002F, 0x042F, 128,21993, 21999, 21999, 21999, 22022, 19453, 19457, 19418, 22066, {0, 0, 0, 0, 0}, 94, 94, { 1251, 500, 10007, 866, ';' }},
-       {0x0436, 0x0036, 0x0436, 227,22069, 22075, 22075, 22075, 22100, 19485, 19489, 19461, 22125, {0, 0, 0, 0, 0}, 95, 95, { 1252, 500, 10000, 850, ',' }},
-       {0x0437, 0x0037, 0x0437, 72,22128, 22134, 22134, 22134, 22153, 19527, 19531, 19493, 22208, {0, 0, 0, 0, 0}, 96, 96, { 0, 500, 2, 1, ';' }},
-       {0x0438, 0x0038, 0x0438, 67,22211, 22217, 22217, 22217, 22241, 19556, 19560, 19535, 22262, {0, 0, 0, 0, 0}, 97, 97, { 1252, 20277, 10079, 850, ';' }},
-       {0x0439, 0x0039, 0x0439, 93,22265, 22271, 22271, 22271, 22285, 19589, 19593, 19564, 22316, {0, 0, 0, 0, 0}, 98, 98, { 0, 500, 2, 1, ',' }},
-       {0x0441, 0x0041, 0x0441, 102,22319, 22325, 22325, 22325, 22341, 19618, 19622, 19597, 22359, {0, 0, 0, 0, 0}, 99, 99, { 1252, 500, 10000, 437, ',' }},
-       {0x0447, 0x0047, 0x0447, 93,22362, 22368, 22368, 22368, 22385, 19660, 19664, 19626, 22316, {0, 0, 0, 0, 0}, 100, 100, { 0, 500, 2, 1, ',' }},
-       {0x0449, 0x0049, 0x0449, 93,22422, 22428, 22428, 22428, 22442, 19693, 19697, 19668, 22316, {0, 0, 0, 0, 0}, 101, 101, { 0, 500, 2, 1, ',' }},
-       {0x044A, 0x004A, 0x044A, 93,22482, 22488, 22488, 22488, 22503, 19730, 19734, 19701, 22316, {0, 0, 0, 0, 0}, 102, 102, { 0, 500, 2, 1, ',' }},
-       {0x044B, 0x004B, 0x044B, 93,22550, 22556, 22556, 22556, 22572, 19765, 19769, 19738, 22316, {0, 0, 0, 0, 0}, 103, 103, { 0, 500, 2, 1, ',' }},
-       {0x044E, 0x004E, 0x044E, 93,22603, 22609, 22609, 22609, 22625, 19800, 1873, 19773, 22316, {0, 0, 0, 0, 0}, 104, 104, { 0, 500, 2, 1, ',' }},
-       {0x0456, 0x0056, 0x0456, 61,22656, 22662, 22662, 22662, 22679, 19823, 19827, 19804, 20051, {0, 0, 0, 0, 0}, 105, 105, { 1252, 500, 10000, 850, ',' }},
-       {0x0457, 0x0057, 0x0457, 93,22696, 22703, 22703, 22703, 22719, 19862, 19831, 19831, 22316, {0, 0, 0, 0, 0}, 106, 106, { 0, 500, 2, 1, ',' }},
-       {0x0801, 0x0001, 0x0801, 95,22753, 22759, 22759, 22759, 22773, 22803, 18222, 18193, 22807, {2, 1, 0, 0, 0}, 107, 107, { 1256, 20420, 10004, 720, ';' }},
-       {0x0804, 0x0004, 0x0804, 42,22810, 22816, 22816, 22816, 22832, 18315, 18319, 18323, 11087, {0, 0, 0, 0, 0}, 108, 108, { 936, 500, 10008, 936, ',' }},
-       {0x0807, 0x0007, 0x0807, 37,22848, 22854, 22854, 22854, 22875, 22893, 18399, 18377, 11008, {0, 0, 0, 0, 0}, 109, 109, { 1252, 20273, 10000, 850, ';' }},
-       {0x0809, 0x0009, 0x0809, 70,22897, 22903, 22903, 22903, 22903, 22928, 18452, 18437, 22932, {0, 0, 0, 0, 0}, 110, 110, { 1252, 20285, 10000, 850, ',' }},
-       {0x080A, 0x000A, 0x080A, 141,22935, 22941, 22941, 22941, 22958, 22977, 18480, 18456, 22981, {0, 0, 0, 0, 0}, 111, 111, { 1252, 20284, 10000, 850, ',' }},
-       {0x080C, 0x000C, 0x080C, 17,22984, 22990, 22990, 22990, 23007, 23028, 18530, 5984, 23032, {0, 0, 0, 0, 0}, 112, 112, { 1252, 20297, 10000, 850, ';' }},
-       {0x0810, 0x0010, 0x0810, 37,23035, 23041, 23041, 23041, 23063, 23083, 18646, 18622, 11008, {0, 0, 0, 0, 0}, 113, 113, { 1252, 500, 10000, 850, ';' }},
-       {0x0813, 0x0013, 0x0813, 17,23087, 23093, 23093, 23093, 23109, 23130, 18732, 18708, 23032, {0, 0, 0, 0, 0}, 114, 114, { 1252, 500, 10000, 850, ';' }},
-       {0x0814, 0x0014, 0x0814, 150,23134, 23140, 23140, 23140, 23167, 23189, 23193, 23197, 20856, {0, 0, 0, 0, 0}, 115, 115, { 1252, 20277, 10000, 850, ';' }},
-       {0x0816, 0x0016, 0x0816, 166,23200, 23206, 23206, 23206, 23228, 23250, 18817, 18788, 23254, {0, 0, 0, 0, 0}, 116, 116, { 1252, 500, 10000, 850, ';' }},
-       {0x081D, 0x001D, 0x081D, 63,23257, 23263, 23263, 23263, 23281, 23299, 18992, 18969, 20376, {0, 0, 0, 0, 0}, 117, 117, { 1252, 20278, 10000, 850, ';' }},
-       {0x0C01, 0x0001, 0x0C01, 58,23303, 23309, 23309, 23309, 23324, 23348, 18222, 18193, 23352, {16777216, 0, 0, 0, 0}, 118, 118, { 1256, 20420, 10004, 720, ';' }},
-       {0x0C04, 0x7C04, 0x0C04, 85,23355, 23361, 23361, 23361, 23395, 23432, 18319, 18323, 23436, {0, 0, 0, 0, 0}, 119, 119, { 950, 500, 10002, 950, ',' }},
-       {0x0C07, 0x0007, 0x0C07, 10,23439, 23445, 23445, 23445, 23462, 23484, 18399, 18377, 23488, {0, 0, 0, 0, 0}, 120, 120, { 1252, 20273, 10000, 850, ';' }},
-       {0x0C09, 0x0009, 0x0C09, 11,23491, 23497, 23497, 23497, 23497, 23517, 18452, 18437, 23521, {0, 0, 0, 0, 0}, 121, 121, { 1252, 500, 10000, 850, ',' }},
-       {0x0C0A, 0x000A, 0x0C0A, 61,23524, 23530, 23530, 23530, 23546, 23565, 18480, 18456, 20051, {0, 0, 0, 0, 0}, 122, 122, { 1252, 20284, 10000, 850, ';' }},
-       {0x0C0C, 0x000C, 0x0C0C, 32,23569, 23575, 23575, 23575, 23591, 23610, 18530, 5984, 23614, {0, 0, 0, 0, 0}, 123, 123, { 1252, 20297, 10000, 850, ';' }},
-       {0x1001, 0x0001, 0x1001, 122,23617, 23623, 23623, 23623, 23638, 23666, 18222, 18193, 23670, {16777216, 0, 0, 0, 0}, 124, 124, { 1256, 20420, 10004, 720, ';' }},
-       {0x1004, 0x0004, 0x1004, 179,23673, 23679, 23679, 23679, 23699, 23718, 18319, 18323, 23722, {0, 0, 0, 0, 0}, 125, 125, { 936, 500, 10008, 936, ',' }},
-       {0x1007, 0x0007, 0x1007, 120,23725, 23731, 23731, 23731, 23751, 23771, 18399, 18377, 23775, {0, 0, 0, 0, 0}, 126, 126, { 1252, 20273, 10000, 850, ';' }},
-       {0x1009, 0x0009, 0x1009, 32,23778, 23784, 23784, 23784, 23784, 23801, 18452, 18437, 23614, {0, 0, 0, 0, 0}, 127, 127, { 1252, 37, 10000, 850, ',' }},
-       {0x100A, 0x000A, 0x100A, 82,23805, 23811, 23811, 23811, 23831, 23852, 18480, 18456, 23856, {0, 0, 0, 0, 0}, 128, 128, { 1252, 20284, 10000, 850, ',' }},
-       {0x100C, 0x000C, 0x100C, 37,23859, 23865, 23865, 23865, 23886, 23905, 18530, 5984, 11008, {0, 0, 0, 0, 0}, 129, 129, { 1252, 20297, 10000, 850, ';' }},
-       {0x1401, 0x0001, 0x1401, 55,23909, 23915, 23915, 23915, 23932, 23964, 18222, 18193, 23968, {16777216, 0, 0, 0, 0}, 130, 130, { 1256, 20420, 10004, 720, ';' }},
-       {0x1404, 0x0004, 0x1404, 132,23971, 23977, 23977, 23977, 24006, 24043, 18319, 18323, 24047, {0, 0, 0, 0, 0}, 131, 131, { 950, 500, 10002, 950, ',' }},
-       {0x1409, 0x0009, 0x1409, 154,24050, 24056, 24056, 24056, 24056, 24078, 18452, 18437, 24082, {0, 0, 0, 0, 0}, 132, 132, { 1252, 500, 10000, 850, ',' }},
-       {0x140A, 0x000A, 0x140A, 44,24085, 24091, 24091, 24091, 24112, 24134, 18480, 18456, 24138, {0, 0, 0, 0, 0}, 133, 133, { 1252, 20284, 10000, 850, ',' }},
-       {0x140C, 0x000C, 0x140C, 120,24141, 24147, 24147, 24147, 24167, 24190, 18530, 5984, 23775, {0, 0, 0, 0, 0}, 134, 134, { 1252, 20297, 10000, 850, ';' }},
-       {0x1801, 0x0001, 0x1801, 123,24194, 24200, 24200, 24200, 24217, 24247, 18222, 18193, 24251, {16777216, 0, 0, 0, 0}, 135, 135, { 1256, 20420, 10004, 720, ';' }},
-       {0x1809, 0x0009, 0x1809, 91,24254, 24260, 24260, 24260, 24260, 24278, 18452, 18437, 24282, {0, 0, 0, 0, 0}, 136, 136, { 1252, 500, 10000, 850, ',' }},
-       {0x180A, 0x000A, 0x180A, 156,24285, 24291, 24291, 24291, 24308, 24327, 18480, 18456, 24331, {0, 0, 0, 0, 0}, 137, 137, { 1252, 20284, 10000, 850, ',' }},
-       {0x1C01, 0x0001, 0x1C01, 202,24334, 24340, 24340, 24340, 24357, 24383, 18222, 18193, 24387, {16777216, 0, 0, 0, 0}, 138, 138, { 1256, 20420, 10004, 720, ';' }},
-       {0x1C09, 0x0009, 0x1C09, 227,24390, 24396, 24396, 24396, 24396, 24419, 18452, 18437, 22125, {0, 0, 0, 0, 0}, 139, 139, { 1252, 500, 10000, 437, ',' }},
-       {0x1C0A, 0x000A, 0x1C0A, 54,24423, 24429, 24429, 24429, 24458, 24491, 18480, 18456, 24495, {0, 0, 0, 0, 0}, 140, 140, { 1252, 20284, 10000, 850, ',' }},
-       {0x2001, 0x0001, 0x2001, 155,24498, 24504, 24504, 24504, 24518, 24544, 18222, 18193, 24548, {16777216, 0, 0, 0, 0}, 141, 141, { 1256, 20420, 10004, 720, ';' }},
-       {0x200A, 0x000A, 0x200A, 217,24551, 24557, 24557, 24557, 24577, 24598, 18480, 18456, 24602, {0, 0, 0, 0, 0}, 142, 142, { 1252, 20284, 10000, 850, ',' }},
-       {0x2401, 0x0001, 0x2401, 224,24605, 24611, 24611, 24611, 24626, 24654, 18222, 18193, 24658, {16777216, 0, 0, 0, 0}, 143, 143, { 1256, 20420, 10004, 720, ';' }},
-       {0x240A, 0x000A, 0x240A, 43,24661, 24667, 24667, 24667, 24686, 24706, 18480, 18456, 24710, {0, 0, 0, 0, 0}, 144, 144, { 1252, 20284, 10000, 850, ',' }},
-       {0x2801, 0x0001, 0x2801, 191,24713, 24719, 24719, 24719, 24734, 24762, 18222, 18193, 24766, {16777216, 0, 0, 0, 0}, 145, 145, { 1256, 20420, 10004, 720, ';' }},
-       {0x280A, 0x000A, 0x280A, 157,24769, 24775, 24775, 24775, 24790, 24807, 18480, 18456, 24811, {0, 0, 0, 0, 0}, 146, 146, { 1252, 20284, 10000, 850, ',' }},
-       {0x2C01, 0x0001, 0x2C01, 100,24814, 24820, 24820, 24820, 24836, 24866, 18222, 18193, 24870, {16777216, 0, 0, 0, 0}, 147, 147, { 1256, 20420, 10004, 720, ';' }},
-       {0x2C09, 0x0009, 0x2C09, 205,24873, 24879, 24879, 24879, 24879, 24909, 18452, 18437, 24913, {0, 0, 0, 0, 0}, 148, 148, { 1252, 500, 10000, 850, ';' }},
-       {0x2C0A, 0x000A, 0x2C0A, 8,24916, 24922, 24922, 24922, 24942, 24963, 18480, 18456, 24967, {0, 0, 0, 0, 0}, 149, 149, { 1252, 20284, 10000, 850, ',' }},
-       {0x3001, 0x0001, 0x3001, 114,24970, 24976, 24976, 24976, 24993, 25021, 18222, 18193, 25025, {16777216, 0, 0, 0, 0}, 150, 150, { 1256, 20420, 10004, 720, ';' }},
-       {0x3009, 0x0009, 0x3009, 229,25028, 25034, 25034, 25034, 25034, 25053, 18452, 18437, 25057, {0, 0, 0, 0, 0}, 151, 151, { 1252, 500, 10000, 437, ',' }},
-       {0x300A, 0x000A, 0x300A, 56,25060, 25066, 25066, 25066, 25084, 25103, 18480, 18456, 25107, {0, 0, 0, 0, 0}, 152, 152, { 1252, 20284, 10000, 850, ',' }},
-       {0x3401, 0x0001, 0x3401, 110,25110, 25116, 25116, 25116, 25132, 25162, 18222, 18193, 25166, {16777216, 0, 0, 0, 0}, 153, 153, { 1256, 20420, 10004, 720, ';' }},
-       {0x3409, 0x0009, 0x3409, 160,25169, 25175, 25175, 25175, 25175, 25197, 18452, 18437, 25201, {0, 0, 0, 0, 0}, 154, 154, { 1252, 500, 10000, 437, ',' }},
-       {0x340A, 0x000A, 0x340A, 40,25204, 25210, 25210, 25210, 25226, 25243, 18480, 18456, 25247, {0, 0, 0, 0, 0}, 155, 155, { 1252, 20284, 10000, 850, ',' }},
-       {0x3801, 0x0001, 0x3801, 0,25250, 25256, 25256, 25256, 25286, 25350, 18222, 18193, 25354, {16777216, 0, 0, 0, 0}, 156, 156, { 1256, 20420, 10004, 720, ';' }},
-       {0x380A, 0x000A, 0x380A, 213,25357, 25363, 25363, 25363, 25381, 25400, 18480, 18456, 25404, {0, 0, 0, 0, 0}, 157, 157, { 1252, 20284, 10000, 850, ',' }},
-       {0x3C01, 0x0001, 0x3C01, 20,25407, 25413, 25413, 25413, 25430, 25462, 18222, 18193, 25466, {16777216, 0, 0, 0, 0}, 158, 158, { 1256, 20420, 10004, 720, ';' }},
-       {0x3C0A, 0x000A, 0x3C0A, 168,25469, 25475, 25475, 25475, 25494, 25514, 18480, 18456, 25518, {0, 0, 0, 0, 0}, 159, 159, { 1252, 20284, 10000, 850, ',' }},
-       {0x4001, 0x0001, 0x4001, 169,25521, 25527, 25527, 25527, 25542, 25566, 18222, 18193, 25570, {16777216, 0, 0, 0, 0}, 160, 160, { 1256, 20420, 10004, 720, ';' }},
-       {0x400A, 0x000A, 0x400A, 25,25573, 25579, 25579, 25579, 25597, 25616, 18480, 18456, 25620, {0, 0, 0, 0, 0}, 161, 161, { 1252, 20284, 10000, 850, ',' }},
-       {0x440A, 0x000A, 0x440A, 190,25623, 25629, 25629, 25629, 25651, 25674, 18480, 18456, 25678, {0, 0, 0, 0, 0}, 162, 162, { 1252, 20284, 10000, 850, ',' }},
-       {0x480A, 0x000A, 0x480A, 87,25681, 25687, 25687, 25687, 25706, 25726, 18480, 18456, 25730, {0, 0, 0, 0, 0}, 163, 163, { 1252, 20284, 10000, 850, ',' }},
-       {0x4C0A, 0x000A, 0x4C0A, 148,25733, 25739, 25739, 25739, 25759, 25780, 18480, 18456, 25784, {0, 0, 0, 0, 0}, 164, 164, { 1252, 20284, 10000, 850, ',' }},
-       {0x500A, 0x000A, 0x500A, 165,25787, 25793, 25793, 25793, 25815, 25838, 18480, 18456, 25842, {0, 0, 0, 0, 0}, 165, 165, { 1252, 20284, 10000, 850, ',' }},
-       {0x7C04, 0x007F, 0x0000, -1,25845, 20060, 18300, 18300, 18308, 20093, 18319, 18323, 0, {0, 0, 0, 0, 0}, 166, 166, { 950, 500, 10002, 950, ',' }}
+       {0x0001, 0x007F, 768, -1, 36129, 36132, 36139, 36154, 36158, 36129, 0, {0, 0, 36162, 0}, 0, 0, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0002, 0x007F, 257, -1, 36190, 36193, 36203, 36222, 36226, 36190, 0, {36230, 0, 0, 0}, 1, 1, { 1251, 21025, 10007, 866, 0, ';' }},
+       {0x0003, 0x007F, 257, -1, 36272, 36275, 36283, 36291, 36295, 36272, 0, {36299, 0, 0, 0}, 2, 2, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0004, 0x0004, 257, -1, 36319, 36326, 36354, 36361, 36365, 36369, 0, {36372, 0, 0, 0}, 3, 3, { 936, 500, 10008, 936, 0, ',' }},
+       {0x0004, 0x7804, 257, -1, 36379, 36387, 36354, 36361, 36365, 36369, 0, {36372, 0, 0, 0}, 4, 4, { 936, 500, 10008, 936, 0, ',' }},
+       {0x0005, 0x007F, 257, -1, 36408, 36411, 36417, 36427, 36431, 36408, 0, {36435, 0, 0, 0}, 5, 5, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x0006, 0x007F, 257, -1, 36461, 36464, 36471, 36477, 36481, 36461, 0, {36485, 0, 0, 0}, 6, 6, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0007, 0x007F, 257, -1, 36506, 36509, 36516, 36524, 36528, 36506, 0, {36532, 0, 0, 0}, 7, 7, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0008, 0x007F, 257, -1, 36557, 36560, 36566, 36583, 36587, 36557, 0, {36591, 0, 0, 0}, 8, 8, { 1253, 20273, 10006, 737, 0, ';' }},
+       {0x0009, 0x007F, 257, -1, 36633, 36636, 36636, 36644, 36648, 36633, 0, {36652, 0, 0, 0}, 9, 9, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x000A, 0x007F, 257, -1, 36671, 36674, 36682, 36691, 36695, 36671, 0, {36699, 0, 0, 0}, 10, 10, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x000B, 0x007F, 257, -1, 36721, 36724, 36732, 36738, 36742, 36721, 0, {36746, 0, 0, 0}, 11, 11, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x000C, 0x007F, 257, -1, 36771, 36774, 36781, 36791, 36795, 36771, 0, {36799, 0, 0, 0}, 12, 12, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x000D, 0x007F, 257, -1, 36821, 36824, 36831, 36842, 36846, 36821, 0, {36850, 0, 0, 0}, 13, 13, { 1255, 500, 10005, 862, 1, ',' }},
+       {0x000E, 0x007F, 257, -1, 36883, 36886, 36896, 36903, 36907, 36883, 0, {36911, 0, 0, 0}, 14, 14, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x000F, 0x007F, 257, -1, 36927, 36930, 36940, 36950, 36954, 36927, 0, {36958, 0, 0, 0}, 15, 15, { 1252, 20871, 10079, 850, 0, ';' }},
+       {0x0010, 0x007F, 257, -1, 36978, 36981, 36989, 36998, 37002, 36978, 0, {36699, 0, 0, 0}, 16, 16, { 1252, 20280, 10000, 850, 0, ';' }},
+       {0x0011, 0x007F, 257, -1, 37006, 37009, 37018, 37028, 37032, 37006, 0, {37036, 0, 0, 0}, 17, 17, { 932, 20290, 10001, 932, 0, ',' }},
+       {0x0012, 0x007F, 257, -1, 37063, 37066, 37073, 37083, 37087, 37063, 0, {37091, 0, 0, 0}, 18, 18, { 949, 20833, 10003, 949, 0, ',' }},
+       {0x0013, 0x007F, 257, -1, 37101, 37104, 37110, 37121, 37125, 37101, 0, {37129, 0, 0, 0}, 19, 19, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0014, 0x007F, 257, -1, 37151, 37154, 37164, 37170, 37174, 37178, 0, {36485, 0, 0, 0}, 20, 20, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0015, 0x007F, 257, -1, 37181, 37184, 37191, 37198, 37202, 37181, 0, {37206, 0, 0, 0}, 21, 21, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0016, 0x007F, 257, -1, 37230, 37233, 37244, 37255, 37259, 37230, 0, {37263, 0, 0, 0}, 22, 22, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0017, 0x007F, 257, -1, 37286, 37289, 37297, 37307, 37311, 37286, 0, {37315, 0, 0, 0}, 23, 23, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0018, 0x007F, 257, -1, 37335, 37338, 37347, 37356, 37360, 37335, 0, {37364, 0, 0, 0}, 24, 24, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0019, 0x007F, 257, -1, 37383, 37386, 37394, 37409, 37413, 37383, 0, {37417, 0, 0, 0}, 25, 25, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x001A, 0x007F, 257, -1, 37463, 37466, 37475, 37484, 37488, 37463, 0, {37492, 0, 0, 0}, 26, 26, { 1250, 500, 10082, 852, 0, ';' }},
+       {0x001B, 0x007F, 257, -1, 37515, 37518, 37525, 37537, 37541, 37515, 0, {37545, 0, 0, 0}, 27, 27, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x001C, 0x007F, 257, -1, 37569, 37572, 37581, 37587, 37591, 37569, 0, {0, 0, 0, 0}, 28, 28, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x001D, 0x007F, 257, -1, 37595, 37598, 37606, 37614, 37618, 37595, 0, {36485, 0, 0, 0}, 29, 29, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x001E, 0x007F, 512, -1, 37622, 37625, 37630, 37640, 37644, 37622, 0, {0, 37648, 0, 0}, 30, 30, { 874, 20838, 10021, 874, 0, ',' }},
+       {0x001F, 0x007F, 257, -1, 37679, 37682, 37690, 37699, 37703, 37679, 0, {37707, 0, 0, 0}, 31, 31, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x0020, 0x007F, 257, -1, 37721, 37724, 37729, 37738, 37742, 37721, 0, {37746, 0, 0, 0}, 32, 32, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0021, 0x007F, 257, -1, 37776, 37779, 37790, 37807, 37811, 37776, 0, {37815, 0, 0, 0}, 33, 33, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0022, 0x007F, 257, -1, 37834, 37837, 37847, 37868, 37872, 37834, 0, {37876, 0, 0, 0}, 34, 34, { 1251, 500, 10017, 866, 0, ';' }},
+       {0x0023, 0x007F, 257, -1, 37922, 37925, 37936, 37957, 37961, 37922, 0, {37965, 0, 0, 0}, 35, 35, { 1251, 500, 10007, 866, 0, ';' }},
+       {0x0024, 0x007F, 257, -1, 38007, 38010, 38020, 38034, 38038, 38007, 0, {38042, 0, 0, 0}, 36, 36, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0025, 0x007F, 257, -1, 38064, 38067, 38076, 38082, 38086, 38064, 0, {38090, 0, 0, 0}, 37, 37, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0026, 0x007F, 257, -1, 38110, 38113, 38121, 38131, 38135, 38110, 0, {38139, 0, 0, 0}, 38, 38, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0027, 0x007F, 257, -1, 38158, 38161, 38172, 38182, 38186, 38158, 0, {38190, 0, 0, 0}, 39, 39, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0028, 0x007F, 257, -1, 38213, 38216, 0, 38222, 38226, 38213, 0, {0, 0, 0, 0}, 40, 40, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0029, 0x007F, 257, -1, 38230, 38233, 38241, 38252, 38256, 38230, 0, {38260, 0, 0, 0}, 41, 41, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x002A, 0x007F, 257, -1, 38284, 38287, 38298, 38313, 4144, 38284, 0, {38317, 0, 0, 0}, 42, 42, { 1258, 500, 10000, 1258, 0, ',' }},
+       {0x002B, 0x007F, 257, -1, 38332, 38335, 38344, 38359, 38363, 38332, 0, {0, 0, 0, 0}, 43, 43, { 0, 500, 2, 1, 0, ',' }},
+       {0x002C, 0x007F, 257, -1, 14514, 38367, 38379, 38393, 38397, 14514, 0, {38401, 0, 0, 0}, 44, 44, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x002D, 0x007F, 257, -1, 38419, 38422, 38429, 38437, 38441, 38419, 0, {38445, 0, 0, 0}, 45, 45, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x002F, 0x007F, 257, -1, 38465, 38468, 38479, 38500, 38504, 38465, 0, {38508, 0, 0, 0}, 46, 46, { 1251, 500, 10007, 866, 0, ';' }},
+       {0x0032, 0x007F, 257, -1, 38552, 38555, 38562, 38571, 38575, 38552, 0, {0, 0, 0, 0}, 47, 47, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0034, 0x007F, 257, -1, 38579, 38582, 38588, 38597, 38601, 38579, 0, {0, 0, 0, 0}, 48, 48, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0035, 0x007F, 257, -1, 38605, 38608, 38613, 38621, 38625, 38605, 0, {38629, 0, 0, 0}, 49, 49, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0036, 0x007F, 257, -1, 38650, 38653, 38653, 38663, 38667, 38650, 0, {38671, 0, 0, 0}, 50, 50, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0037, 0x007F, 257, -1, 38691, 38694, 38703, 38725, 38729, 38691, 0, {38733, 0, 0, 0}, 51, 51, { 0, 500, 2, 1, 0, ';' }},
+       {0x0038, 0x007F, 257, -1, 38798, 38801, 38809, 38819, 38823, 38798, 0, {0, 0, 0, 0}, 52, 52, { 1252, 20277, 10079, 850, 0, ';' }},
+       {0x0039, 0x007F, 257, -1, 38827, 38830, 38836, 38855, 38859, 38827, 0, {38863, 0, 0, 0}, 53, 53, { 0, 500, 2, 1, 0, ',' }},
+       {0x003A, 0x007F, 257, -1, 38904, 38907, 38915, 38921, 38925, 38904, 0, {38929, 0, 0, 0}, 54, 54, { 0, 500, 2, 1, 0, ',' }},
+       {0x003B, 0x007F, 257, -1, 38950, 38953, 38967, 38984, 38988, 38950, 0, {0, 0, 0, 0}, 55, 55, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x003C, 0x007F, 257, -1, 38992, 38995, 39001, 39009, 39013, 38992, 0, {39017, 0, 0, 0}, 56, 56, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x003E, 0x007F, 257, -1, 39038, 39041, 39047, 39061, 39065, 39038, 0, {39069, 0, 0, 0}, 57, 57, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x003F, 0x007F, 257, -1, 39086, 39089, 39096, 39116, 39120, 39086, 0, {39124, 0, 0, 0}, 58, 58, { 0, 500, 2, 1, 0, ';' }},
+       {0x0040, 0x007F, 257, -1, 39166, 39169, 39177, 39190, 39194, 39166, 0, {0, 0, 0, 0}, 59, 59, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0041, 0x007F, 257, -1, 39198, 39201, 39209, 39219, 39223, 39198, 0, {39227, 0, 0, 0}, 60, 60, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x0043, 0x007F, 257, -1, 39248, 39251, 39257, 39268, 39272, 39248, 0, {0, 0, 0, 0}, 61, 61, { 1254, 500, 10029, 857, 0, ';' }},
+       {0x0045, 0x007F, 257, -1, 39276, 39279, 39287, 39303, 39307, 39276, 0, {39311, 0, 0, 0}, 62, 62, { 0, 500, 2, 1, 0, ',' }},
+       {0x0046, 0x007F, 257, -1, 39376, 39379, 39387, 39406, 39410, 39376, 0, {0, 0, 0, 0}, 63, 63, { 0, 500, 2, 1, 0, ',' }},
+       {0x0047, 0x007F, 257, -1, 39414, 39417, 39426, 39448, 39452, 39414, 0, {39456, 0, 0, 0}, 64, 64, { 0, 500, 2, 1, 0, ',' }},
+       {0x0048, 0x007F, 257, -1, 14520, 39512, 39518, 39534, 39538, 14520, 0, {0, 0, 0, 0}, 65, 65, { 0, 500, 2, 1, 0, ',' }},
+       {0x0049, 0x007F, 257, -1, 39542, 39545, 39551, 39567, 39571, 39542, 0, {39575, 0, 0, 0}, 66, 66, { 0, 500, 2, 1, 0, ',' }},
+       {0x004A, 0x007F, 257, -1, 39640, 39643, 39650, 39669, 39673, 39640, 0, {39677, 0, 0, 0}, 67, 67, { 0, 500, 2, 1, 0, ',' }},
+       {0x004B, 0x007F, 257, -1, 35568, 39742, 39750, 39766, 39770, 35568, 0, {39774, 0, 0, 0}, 68, 68, { 0, 500, 2, 1, 0, ',' }},
+       {0x004C, 0x007F, 257, -1, 39845, 39848, 39858, 39877, 39881, 39845, 0, {39885, 0, 0, 0}, 69, 69, { 0, 500, 2, 1, 0, ',' }},
+       {0x004D, 0x007F, 257, -1, 14511, 39935, 39944, 39966, 39970, 14511, 0, {39974, 0, 0, 0}, 70, 70, { 0, 500, 2, 1, 0, ',' }},
+       {0x004E, 0x007F, 257, -1, 40027, 40030, 40038, 40054, 2588, 40027, 0, {40058, 0, 0, 0}, 71, 71, { 0, 500, 2, 1, 0, ',' }},
+       {0x0050, 0x007F, 257, -1, 40120, 40123, 40133, 40146, 40150, 40120, 0, {0, 0, 0, 0}, 72, 72, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0051, 0x007F, 257, -1, 40154, 40157, 40165, 40190, 40194, 40154, 0, {0, 0, 0, 0}, 73, 73, { 0, 500, 2, 1, 0, ',' }},
+       {0x0052, 0x007F, 257, -1, 40198, 40201, 40207, 40215, 40219, 40198, 0, {0, 0, 0, 0}, 74, 74, { 1252, 20285, 10000, 850, 0, ',' }},
+       {0x0053, 0x007F, 257, -1, 40223, 40226, 40232, 40260, 40264, 40223, 0, {0, 0, 0, 0}, 75, 75, { 0, 500, 2, 1, 0, ',' }},
+       {0x0054, 0x007F, 257, -1, 40268, 40271, 40275, 40285, 40289, 40268, 0, {0, 0, 0, 0}, 76, 76, { 0, 500, 2, 1, 0, ',' }},
+       {0x0056, 0x007F, 257, -1, 40293, 40296, 40305, 40312, 40316, 40293, 0, {36699, 0, 0, 0}, 77, 77, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0057, 0x007F, 257, -1, 40320, 40324, 40332, 40351, 40320, 40320, 0, {0, 0, 0, 0}, 78, 78, { 0, 500, 2, 1, 0, ',' }},
+       {0x005B, 0x007F, 257, -1, 40355, 40358, 40366, 40382, 40386, 40355, 0, {40390, 0, 0, 0}, 79, 79, { 0, 500, 2, 1, 0, ',' }},
+       {0x005E, 0x007F, 257, -1, 7860, 40412, 40420, 40433, 40437, 7860, 0, {40441, 0, 0, 0}, 80, 80, { 0, 500, 2, 1, 0, ';' }},
+       {0x005F, 0x007F, 257, -1, 40486, 40490, 40516, 40526, 40486, 40486, 0, {0, 0, 0, 0}, 81, 81, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0061, 0x007F, 257, -1, 2082, 40530, 40537, 40556, 40560, 2082, 0, {40564, 0, 0, 0}, 82, 82, { 0, 500, 2, 1, 0, ',' }},
+       {0x0063, 0x007F, 1024, -1, 40614, 40617, 40624, 40633, 40637, 40614, 0, {0, 0, 0, 0}, 83, 83, { 0, 500, 2, 1, 1, ';' }},
+       {0x0064, 0x007F, 257, -1, 40641, 40645, 40645, 40654, 40641, 40641, 0, {40658, 0, 0, 0}, 84, 84, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x0068, 0x007F, 257, -1, 40681, 40684, 40684, 40690, 40694, 40681, 0, {0, 0, 0, 0}, 85, 85, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x006A, 0x007F, 257, -1, 40698, 40701, 40708, 40723, 40727, 40698, 0, {0, 0, 0, 0}, 86, 86, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x006C, 0x007F, 257, -1, 40731, 40735, 40750, 40767, 40731, 40731, 0, {0, 0, 0, 0}, 87, 87, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x006F, 0x007F, 257, -1, 40771, 40774, 40786, 40798, 40802, 40771, 0, {0, 0, 0, 0}, 88, 88, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0070, 0x007F, 257, -1, 14505, 40806, 40806, 40811, 40815, 14505, 0, {0, 0, 0, 0}, 89, 89, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x0078, 0x007F, 257, -1, 40819, 40822, 40833, 40843, 40847, 40819, 0, {40851, 0, 0, 0}, 90, 90, { 0, 500, 2, 1, 0, ',' }},
+       {0x007E, 0x007F, 257, -1, 40864, 40867, 40874, 40884, 40888, 40864, 0, {40892, 0, 0, 0}, 91, 91, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0082, 0x007F, 257, -1, 40912, 40915, 40923, 40931, 40935, 40912, 0, {0, 0, 0, 0}, 92, 92, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0084, 0x007F, 257, -1, 40939, 40943, 40956, 40975, 40939, 40939, 0, {40979, 0, 0, 0}, 93, 93, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0085, 0x007F, 257, -1, 41004, 41008, 41014, 41032, 41004, 41004, 0, {0, 0, 0, 0}, 94, 94, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0087, 0x007F, 257, -1, 41036, 41039, 41039, 41051, 41055, 41036, 0, {0, 0, 0, 0}, 95, 95, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x0091, 0x007F, 257, -1, 41059, 41062, 41078, 41088, 41092, 41059, 0, {41096, 0, 0, 0}, 96, 96, { 1252, 20285, 10000, 850, 0, ',' }},
+       {0x0401, 0x0001, 768, 98, 41121, 41127, 41149, 36154, 36158, 36129, 13253, {0, 0, 36162, 0}, 97, 97, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0402, 0x0002, 257, 11, 41213, 41219, 41240, 36222, 36226, 36190, 41278, {36230, 0, 0, 0}, 98, 98, { 1251, 21025, 10007, 866, 0, ';' }},
+       {0x0403, 0x0003, 257, 32, 41281, 41287, 41303, 36291, 36295, 36272, 41321, {36299, 0, 0, 0}, 99, 99, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0404, 0x7C04, 257, 110, 41324, 41330, 41352, 41368, 36365, 36369, 41372, {41375, 0, 0, 0}, 100, 100, { 950, 500, 10002, 950, 0, ',' }},
+       {0x0405, 0x0005, 257, 24, 41382, 41388, 41411, 36427, 36431, 36408, 41441, {36435, 0, 0, 0}, 101, 101, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x0406, 0x0006, 257, 26, 41444, 41450, 41467, 36477, 36481, 36461, 41483, {36485, 0, 0, 0}, 102, 102, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0407, 0x0007, 257, 25, 41486, 41492, 41509, 36524, 36528, 36506, 41531, {36532, 0, 0, 0}, 103, 103, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0408, 0x0008, 257, 40, 41534, 41540, 41555, 36583, 36587, 36557, 41587, {36591, 0, 0, 0}, 104, 104, { 1253, 20273, 10006, 737, 0, ';' }},
+       {0x0409, 0x0009, 257, 112, 41590, 41596, 41596, 36644, 36648, 36633, 41620, {36652, 0, 0, 0}, 105, 105, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x040B, 0x000B, 257, 34, 41623, 41629, 41647, 36738, 36742, 36721, 41661, {36746, 0, 0, 0}, 106, 106, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x040C, 0x000C, 257, 36, 41664, 41670, 41686, 36791, 36795, 36771, 41705, {36799, 0, 0, 0}, 107, 107, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x040D, 0x000D, 257, 48, 41708, 41714, 41730, 36842, 36846, 36821, 41754, {36850, 0, 0, 0}, 108, 108, { 1255, 500, 10005, 862, 1, ',' }},
+       {0x040E, 0x000E, 257, 45, 41757, 41763, 41783, 36903, 36907, 36883, 41806, {36911, 0, 0, 0}, 109, 109, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x040F, 0x000F, 257, 52, 41809, 41815, 41835, 36950, 36954, 36927, 41855, {36958, 0, 0, 0}, 110, 110, { 1252, 20871, 10079, 850, 0, ';' }},
+       {0x0410, 0x0010, 257, 53, 41858, 41864, 41880, 36998, 37002, 36978, 41898, {36699, 0, 0, 0}, 111, 111, { 1252, 20280, 10000, 850, 0, ';' }},
+       {0x0411, 0x0011, 257, 56, 41901, 41907, 41924, 37028, 37032, 37006, 41943, {37036, 0, 0, 0}, 112, 112, { 932, 20290, 10001, 932, 0, ',' }},
+       {0x0412, 0x0012, 257, 60, 41946, 41952, 41973, 37083, 37087, 37063, 41998, {37091, 0, 0, 0}, 113, 113, { 949, 20833, 10003, 949, 0, ',' }},
+       {0x0413, 0x0013, 257, 80, 42001, 42007, 42027, 37121, 37125, 37101, 42050, {37129, 0, 0, 0}, 114, 114, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0414, 0x7C14, 257, 81, 42053, 42059, 42086, 37170, 37174, 37178, 42108, {36485, 0, 0, 0}, 115, 115, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0415, 0x0015, 257, 89, 42111, 42117, 42133, 37198, 37202, 37181, 42149, {37206, 0, 0, 0}, 116, 116, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0416, 0x0016, 257, 15, 42152, 42158, 42178, 37255, 37259, 37230, 42198, {37263, 0, 0, 0}, 117, 117, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0417, 0x0017, 257, 19, 42201, 42207, 42229, 37307, 37311, 37286, 13256, {37315, 0, 0, 0}, 118, 118, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0418, 0x0018, 257, 94, 42248, 42254, 42273, 37356, 37360, 37335, 42293, {37364, 0, 0, 0}, 119, 119, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0419, 0x0019, 257, 96, 42296, 42302, 42319, 37409, 37413, 37383, 42349, {37417, 0, 0, 0}, 120, 120, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x041A, 0x001A, 257, 44, 42352, 42358, 42377, 37484, 37488, 37463, 42397, {37492, 0, 0, 0}, 121, 121, { 1250, 500, 10082, 852, 0, ';' }},
+       {0x041B, 0x001B, 257, 102, 42400, 42406, 42424, 37537, 37541, 37515, 42459, {37545, 0, 0, 0}, 122, 122, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x041C, 0x001C, 257, 2, 42462, 42468, 42487, 37587, 37591, 37569, 42506, {0, 0, 0, 0}, 123, 123, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x041D, 0x001D, 257, 99, 42509, 42515, 42532, 37614, 37618, 37595, 42550, {36485, 0, 0, 0}, 124, 124, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x041E, 0x001E, 512, 105, 42553, 42559, 42575, 37640, 37644, 37622, 42597, {0, 37648, 0, 0}, 125, 125, { 874, 20838, 10021, 874, 0, ',' }},
+       {0x041F, 0x001F, 257, 108, 42600, 42606, 42623, 37699, 37703, 37679, 42643, {37707, 0, 0, 0}, 126, 126, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x0420, 0x0020, 257, 88, 42646, 42652, 42668, 37738, 37742, 37721, 42694, {37746, 0, 0, 0}, 127, 127, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0421, 0x0021, 257, 46, 42697, 42703, 42726, 37807, 37811, 37776, 42755, {37815, 0, 0, 0}, 128, 128, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0422, 0x0022, 257, 111, 42758, 42764, 42784, 37868, 37872, 37834, 42822, {37876, 0, 0, 0}, 129, 129, { 1251, 500, 10017, 866, 0, ';' }},
+       {0x0423, 0x0023, 257, 16, 42825, 42831, 42852, 37957, 37961, 37922, 42892, {37965, 0, 0, 0}, 130, 130, { 1251, 500, 10007, 866, 0, ';' }},
+       {0x0424, 0x0024, 257, 101, 42895, 42901, 42922, 38034, 38038, 38007, 42948, {38042, 0, 0, 0}, 131, 131, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0425, 0x0025, 257, 30, 42951, 42957, 42976, 38082, 38086, 38064, 42990, {38090, 0, 0, 0}, 132, 132, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0426, 0x0026, 257, 68, 42993, 42999, 43016, 38131, 38135, 38110, 43036, {38139, 0, 0, 0}, 133, 133, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0427, 0x0027, 257, 66, 43039, 43045, 43068, 38182, 38186, 38158, 43088, {38190, 0, 0, 0}, 134, 134, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0428, 0x7C28, 257, 106, 43091, 43102, 0, 38222, 38226, 38213, 43131, {0, 0, 0, 0}, 135, 135, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0429, 0x0029, 257, 51, 43134, 43140, 43155, 38252, 38256, 38230, 43179, {38260, 0, 0, 0}, 136, 136, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x042A, 0x002A, 257, 116, 43182, 43188, 43209, 38313, 4144, 38284, 43237, {38317, 0, 0, 0}, 137, 137, { 1258, 500, 10000, 1258, 0, ',' }},
+       {0x042B, 0x002B, 257, 3, 43240, 43246, 43265, 38359, 38363, 38332, 3804, {0, 0, 0, 0}, 138, 138, { 0, 500, 2, 1, 0, ',' }},
+       {0x042C, 0x782C, 257, 7, 43330, 43341, 43373, 38393, 38397, 14514, 43401, {38401, 0, 0, 0}, 139, 139, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x042D, 0x002D, 257, 32, 43404, 43410, 43425, 38437, 38441, 38419, 41321, {38445, 0, 0, 0}, 140, 140, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x042F, 0x002F, 257, 73, 43444, 43450, 43473, 38500, 38504, 38465, 43517, {38508, 0, 0, 0}, 141, 141, { 1251, 500, 10007, 866, 0, ';' }},
+       {0x0432, 0x0032, 257, 118, 43520, 43526, 38562, 38571, 38575, 38552, 43548, {0, 0, 0, 0}, 142, 142, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0434, 0x0034, 257, 118, 43551, 43557, 38588, 38597, 38601, 38579, 43548, {0, 0, 0, 0}, 143, 143, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0435, 0x0035, 257, 118, 43578, 43584, 43604, 38621, 38625, 38605, 43548, {38629, 0, 0, 0}, 144, 144, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0436, 0x0036, 257, 118, 43632, 43638, 43663, 38663, 38667, 38650, 43548, {38671, 0, 0, 0}, 145, 145, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0437, 0x0037, 257, 38, 43687, 43693, 43712, 38725, 38729, 38691, 43767, {38733, 0, 0, 0}, 146, 146, { 0, 500, 2, 1, 0, ';' }},
+       {0x0438, 0x0038, 257, 35, 43770, 43776, 43800, 38819, 38823, 38798, 43821, {0, 0, 0, 0}, 147, 147, { 1252, 20277, 10079, 850, 0, ';' }},
+       {0x0439, 0x0039, 257, 49, 43824, 43830, 43844, 38855, 38859, 38827, 43878, {38863, 0, 0, 0}, 148, 148, { 0, 500, 2, 1, 0, ',' }},
+       {0x043A, 0x003A, 257, 75, 43881, 43887, 43903, 38921, 38925, 38904, 43917, {38929, 0, 0, 0}, 149, 149, { 0, 500, 2, 1, 0, ',' }},
+       {0x043B, 0x003B, 257, 81, 43920, 43926, 43949, 38984, 38988, 38950, 42108, {0, 0, 0, 0}, 150, 150, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x043E, 0x003E, 257, 77, 43974, 43980, 43997, 39061, 39065, 39038, 44022, {39069, 0, 0, 0}, 151, 151, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0440, 0x0040, 257, 58, 44025, 44031, 44052, 39190, 39194, 39166, 44088, {0, 0, 0, 0}, 152, 152, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0441, 0x0041, 257, 57, 44091, 44097, 44113, 39219, 39223, 39198, 44131, {39227, 0, 0, 0}, 153, 153, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x0443, 0x7C43, 257, 114, 44134, 44145, 44171, 39268, 39272, 39248, 44205, {0, 0, 0, 0}, 154, 154, { 1254, 500, 10029, 857, 0, ';' }},
+       {0x0445, 0x0045, 257, 49, 44208, 44214, 44230, 39303, 39307, 39276, 43878, {39311, 0, 0, 0}, 155, 155, { 0, 500, 2, 1, 0, ',' }},
+       {0x0447, 0x0047, 257, 49, 44261, 44267, 44284, 39448, 39452, 39414, 43878, {39456, 0, 0, 0}, 156, 156, { 0, 500, 2, 1, 0, ',' }},
+       {0x0448, 0x0048, 257, 49, 44321, 44327, 44341, 39534, 39538, 14520, 43878, {0, 0, 0, 0}, 157, 157, { 0, 500, 2, 1, 0, ',' }},
+       {0x0449, 0x0049, 257, 49, 44372, 44378, 44392, 39567, 39571, 39542, 43878, {39575, 0, 0, 0}, 158, 158, { 0, 500, 2, 1, 0, ',' }},
+       {0x044A, 0x004A, 257, 49, 44432, 44438, 44453, 39669, 39673, 39640, 43878, {39677, 0, 0, 0}, 159, 159, { 0, 500, 2, 1, 0, ',' }},
+       {0x044B, 0x004B, 257, 49, 44500, 44506, 44522, 39766, 39770, 35568, 43878, {39774, 0, 0, 0}, 160, 160, { 0, 500, 2, 1, 0, ',' }},
+       {0x044C, 0x004C, 257, 49, 44553, 44559, 44577, 39877, 39881, 39845, 43878, {39885, 0, 0, 0}, 161, 161, { 0, 500, 2, 1, 0, ',' }},
+       {0x044D, 0x004D, 257, 49, 44617, 44623, 44640, 39966, 39970, 14511, 43878, {39974, 0, 0, 0}, 162, 162, { 0, 500, 2, 1, 0, ',' }},
+       {0x044E, 0x004E, 257, 49, 44677, 44683, 44699, 40054, 2588, 40027, 43878, {40058, 0, 0, 0}, 163, 163, { 0, 500, 2, 1, 0, ',' }},
+       {0x0451, 0x0051, 257, 21, 44730, 44736, 44752, 40190, 40194, 40154, 13335, {0, 0, 0, 0}, 164, 164, { 0, 500, 2, 1, 0, ',' }},
+       {0x0452, 0x0052, 257, 37, 44798, 44804, 44827, 40215, 40219, 40198, 44850, {0, 0, 0, 0}, 165, 165, { 1252, 20285, 10000, 850, 0, ',' }},
+       {0x0453, 0x0053, 257, 59, 44853, 44859, 44876, 40260, 40264, 40223, 44928, {0, 0, 0, 0}, 166, 166, { 0, 500, 2, 1, 0, ',' }},
+       {0x0454, 0x0054, 257, 62, 44931, 44937, 44948, 40285, 40289, 40268, 44970, {0, 0, 0, 0}, 167, 167, { 0, 500, 2, 1, 0, ',' }},
+       {0x0456, 0x0056, 257, 32, 44973, 44979, 44996, 40312, 40316, 40293, 41321, {36699, 0, 0, 0}, 168, 168, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0457, 0x0057, 257, 49, 45013, 45020, 45036, 40351, 40320, 40320, 43878, {0, 0, 0, 0}, 169, 169, { 0, 500, 2, 1, 0, ',' }},
+       {0x045B, 0x005B, 257, 65, 45070, 45076, 45096, 40382, 40386, 40355, 45146, {40390, 0, 0, 0}, 170, 170, { 0, 500, 2, 1, 0, ',' }},
+       {0x045E, 0x005E, 257, 33, 45149, 45155, 45174, 40433, 40437, 7860, 45205, {40441, 0, 0, 0}, 171, 171, { 0, 500, 2, 1, 0, ';' }},
+       {0x0461, 0x0061, 257, 82, 45208, 45214, 45229, 40556, 40560, 2082, 45266, {40564, 0, 0, 0}, 172, 172, { 0, 500, 2, 1, 0, ',' }},
+       {0x0463, 0x0063, 1024, 1, 45269, 45275, 45296, 40633, 40637, 40614, 45326, {0, 0, 0, 0}, 173, 173, { 0, 500, 2, 1, 1, ';' }},
+       {0x0464, 0x0064, 257, 87, 45329, 45336, 45359, 40654, 40641, 40641, 45380, {40658, 0, 0, 0}, 174, 174, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x0468, 0x7C68, 257, 78, 45383, 45394, 45417, 40690, 40694, 40681, 45434, {0, 0, 0, 0}, 175, 175, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x046A, 0x006A, 257, 78, 45437, 45443, 45460, 40723, 40727, 40698, 45434, {0, 0, 0, 0}, 176, 176, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x046C, 0x006C, 257, 118, 45506, 45513, 40750, 40767, 40731, 40731, 43548, {0, 0, 0, 0}, 177, 177, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x046F, 0x006F, 257, 39, 45543, 45549, 45573, 40798, 40802, 40771, 45604, {0, 0, 0, 0}, 178, 178, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0470, 0x0070, 257, 78, 45607, 45613, 45613, 40811, 40815, 14505, 45434, {0, 0, 0, 0}, 179, 179, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x0478, 0x0078, 257, 21, 45628, 45634, 45653, 40843, 40847, 40819, 13335, {40851, 0, 0, 0}, 180, 180, { 0, 500, 2, 1, 0, ',' }},
+       {0x047E, 0x007E, 257, 36, 45672, 45678, 45694, 40884, 40888, 40864, 41705, {40892, 0, 0, 0}, 181, 181, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0482, 0x0082, 257, 36, 45713, 45719, 45736, 40931, 40935, 40912, 41705, {0, 0, 0, 0}, 182, 182, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0485, 0x0085, 257, 96, 45754, 45761, 41014, 41032, 41004, 41004, 42349, {0, 0, 0, 0}, 183, 183, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0487, 0x0087, 257, 97, 45776, 45782, 45782, 41051, 41055, 41036, 45803, {0, 0, 0, 0}, 184, 184, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x0491, 0x0091, 257, 37, 45806, 45812, 45845, 41088, 41092, 41059, 44850, {41096, 0, 0, 0}, 185, 185, { 1252, 20285, 10000, 850, 0, ',' }},
+       {0x0801, 0x0001, 257, 50, 45881, 45887, 45901, 45931, 36158, 36129, 45935, {36162, 0, 0, 0}, 186, 186, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0804, 0x0004, 257, 21, 45938, 36387, 45944, 36361, 36365, 36369, 13335, {36372, 0, 0, 0}, 187, 187, { 936, 500, 10008, 936, 0, ',' }},
+       {0x0807, 0x0007, 257, 19, 45960, 45966, 45987, 46005, 36528, 36506, 13256, {36532, 0, 0, 0}, 188, 188, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0809, 0x0009, 257, 37, 46009, 46015, 46015, 46040, 36648, 36633, 44850, {36652, 0, 0, 0}, 189, 189, { 1252, 20285, 10000, 850, 0, ',' }},
+       {0x080A, 0x000A, 257, 76, 46044, 46050, 46067, 46086, 36695, 36671, 46090, {36699, 0, 0, 0}, 190, 190, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x080C, 0x000C, 257, 10, 46093, 46099, 46116, 46137, 36795, 36771, 46141, {36799, 0, 0, 0}, 191, 191, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0810, 0x0010, 257, 19, 46144, 46150, 46172, 46192, 37002, 36978, 13256, {36699, 0, 0, 0}, 192, 192, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0813, 0x0013, 257, 10, 46196, 46202, 46218, 46239, 37125, 37101, 46141, {37129, 0, 0, 0}, 193, 193, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0814, 0x7814, 257, 81, 46243, 46249, 46276, 46292, 46296, 46300, 42108, {36485, 0, 0, 0}, 194, 194, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0816, 0x0016, 257, 91, 46303, 46309, 46331, 46353, 37259, 37230, 46357, {37263, 0, 0, 0}, 195, 195, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x081D, 0x001D, 257, 34, 46360, 46366, 46384, 46402, 37618, 37595, 41661, {36485, 0, 0, 0}, 196, 196, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x082C, 0x742C, 257, 7, 46406, 46417, 43373, 46452, 38397, 14514, 43401, {38401, 0, 0, 0}, 197, 197, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x083C, 0x003C, 257, 47, 46456, 46462, 46478, 39009, 39013, 38992, 46494, {39017, 0, 0, 0}, 198, 198, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x083E, 0x003E, 257, 13, 46497, 46503, 46518, 46541, 39065, 39038, 46545, {39069, 0, 0, 0}, 199, 199, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0843, 0x7843, 257, 114, 46548, 46559, 44171, 39268, 39272, 39248, 44205, {0, 0, 0, 0}, 200, 200, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0845, 0x0045, 257, 9, 46588, 46594, 46615, 46658, 39307, 39276, 46662, {39311, 0, 0, 0}, 201, 201, { 0, 500, 2, 1, 0, ',' }},
+       {0x0850, 0x7C50, 257, 21, 46665, 46676, 40133, 46705, 40150, 40120, 13335, {0, 0, 0, 0}, 202, 202, { 0, 500, 2, 1, 0, ',' }},
+       {0x0C01, 0x0001, 257, 31, 46709, 46715, 46730, 46754, 36158, 36129, 46758, {36162, 0, 0, 0}, 203, 203, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0C04, 0x7C04, 257, 42, 46761, 46767, 46810, 46847, 36365, 36369, 46851, {41375, 0, 0, 0}, 204, 204, { 950, 500, 10002, 950, 0, ',' }},
+       {0x0C07, 0x0007, 257, 5, 46854, 46860, 46877, 46899, 36528, 36506, 46903, {36532, 0, 0, 0}, 205, 205, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0C09, 0x0009, 257, 6, 46906, 46912, 46912, 46932, 36648, 36633, 46936, {36652, 0, 0, 0}, 206, 206, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0C0A, 0x000A, 257, 32, 46939, 46945, 46961, 46980, 36695, 36671, 41321, {36699, 0, 0, 0}, 207, 207, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x0C0C, 0x000C, 257, 18, 46984, 46990, 47006, 47025, 36795, 36771, 47029, {36799, 0, 0, 0}, 208, 208, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0C3B, 0x003B, 257, 34, 47032, 47038, 47062, 47088, 47092, 38950, 41661, {0, 0, 0, 0}, 209, 209, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x1001, 0x0001, 257, 69, 47096, 47102, 47117, 47145, 36158, 36129, 47149, {36162, 0, 0, 0}, 210, 210, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x1004, 0x0004, 257, 100, 47152, 47158, 47190, 47209, 36365, 36369, 47213, {36372, 0, 0, 0}, 211, 211, { 936, 500, 10008, 936, 0, ',' }},
+       {0x1007, 0x0007, 257, 67, 47216, 47222, 47242, 47262, 36528, 36506, 47266, {36532, 0, 0, 0}, 212, 212, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x1009, 0x0009, 257, 18, 47269, 47275, 47275, 47292, 36648, 36633, 47029, {36652, 0, 0, 0}, 213, 213, { 1252, 37, 10000, 850, 0, ',' }},
+       {0x100A, 0x000A, 257, 41, 47296, 47302, 47322, 47343, 36695, 36671, 47347, {36699, 0, 0, 0}, 214, 214, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x100C, 0x000C, 257, 19, 47350, 47356, 47377, 47396, 36795, 36771, 13256, {36799, 0, 0, 0}, 215, 215, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x1401, 0x0001, 257, 28, 47400, 47406, 47423, 47455, 36158, 36129, 47459, {36162, 0, 0, 0}, 216, 216, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x1404, 0x7C04, 257, 74, 47462, 47468, 47507, 47544, 36365, 36369, 47548, {41375, 0, 0, 0}, 217, 217, { 950, 500, 10002, 950, 0, ',' }},
+       {0x1407, 0x0007, 257, 64, 47551, 47557, 47580, 47604, 36528, 36506, 47608, {36532, 0, 0, 0}, 218, 218, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x1409, 0x0009, 257, 83, 47611, 47617, 47617, 47639, 36648, 36633, 47643, {36652, 0, 0, 0}, 219, 219, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x140A, 0x000A, 257, 23, 47646, 47652, 47673, 47695, 36695, 36671, 47699, {36699, 0, 0, 0}, 220, 220, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x140C, 0x000C, 257, 67, 47702, 47708, 47728, 47751, 36795, 36771, 47266, {36799, 0, 0, 0}, 221, 221, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x1801, 0x0001, 257, 70, 47755, 47761, 47778, 47808, 36158, 36129, 47812, {36162, 0, 0, 0}, 222, 222, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x1809, 0x0009, 257, 47, 47815, 47821, 47821, 47839, 36648, 36633, 46494, {36652, 0, 0, 0}, 223, 223, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x180A, 0x000A, 257, 85, 47843, 47849, 47866, 47885, 36695, 36671, 47889, {36699, 0, 0, 0}, 224, 224, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x180C, 0x000C, 257, 71, 47892, 47898, 47914, 47933, 36795, 36771, 47937, {36799, 0, 0, 0}, 225, 225, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x181A, 0x701A, 257, 8, 47940, 47951, 47991, 48043, 48047, 48051, 48054, {48057, 0, 0, 0}, 226, 226, { 1250, 870, 10082, 852, 0, ';' }},
+       {0x1C01, 0x0001, 257, 107, 48080, 48086, 48103, 48129, 36158, 36129, 48133, {36162, 0, 0, 0}, 227, 227, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x1C09, 0x0009, 257, 118, 48136, 48142, 48142, 48165, 36648, 36633, 43548, {36652, 0, 0, 0}, 228, 228, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x1C0A, 0x000A, 257, 27, 48169, 48175, 48204, 48237, 36695, 36671, 48241, {36699, 0, 0, 0}, 229, 229, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x1C1A, 0x6C1A, 257, 8, 48244, 48255, 47991, 48298, 48302, 48051, 48054, {38508, 0, 0, 0}, 230, 230, { 1251, 21025, 10007, 855, 0, ';' }},
+       {0x2001, 0x0001, 257, 84, 48306, 48312, 48326, 48354, 36158, 36129, 48358, {36162, 0, 0, 0}, 231, 231, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x2009, 0x0009, 257, 54, 48361, 48367, 48367, 48385, 36648, 36633, 48389, {36652, 0, 0, 0}, 232, 232, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x200A, 0x000A, 257, 115, 48392, 48398, 48418, 48439, 36695, 36671, 48443, {36699, 0, 0, 0}, 233, 233, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x2401, 0x0001, 257, 117, 48446, 48452, 48467, 48495, 36158, 36129, 48499, {36162, 0, 0, 0}, 234, 234, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x240A, 0x000A, 257, 22, 48502, 48508, 48527, 48547, 36695, 36671, 48551, {36699, 0, 0, 0}, 235, 235, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x241A, 0x701A, 257, 95, 48554, 48565, 48589, 48617, 9238, 48051, 48621, {48057, 0, 0, 0}, 236, 236, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x2801, 0x0001, 257, 104, 48624, 48630, 48645, 48673, 36158, 36129, 48677, {36162, 0, 0, 0}, 237, 237, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x2809, 0x0009, 257, 17, 48680, 48686, 48686, 48703, 36648, 36633, 48707, {36652, 0, 0, 0}, 238, 238, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x280A, 0x000A, 257, 86, 48710, 48716, 48731, 48748, 36695, 36671, 48752, {36699, 0, 0, 0}, 239, 239, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x281A, 0x6C1A, 257, 95, 48755, 48766, 48589, 48793, 9238, 48051, 48621, {38508, 0, 0, 0}, 240, 240, { 1251, 21025, 10007, 855, 0, ';' }},
+       {0x2C01, 0x0001, 257, 55, 48797, 48803, 48819, 48849, 36158, 36129, 48853, {36162, 0, 0, 0}, 241, 241, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x2C09, 0x0009, 257, 109, 48856, 48862, 48862, 48892, 36648, 36633, 48896, {36652, 0, 0, 0}, 242, 242, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x2C0A, 0x000A, 257, 4, 48899, 48905, 48925, 48946, 36695, 36671, 48950, {36699, 0, 0, 0}, 243, 243, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x2C1A, 0x701A, 257, 72, 48953, 48964, 48992, 49025, 9238, 48051, 49029, {48057, 0, 0, 0}, 244, 244, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x3001, 0x0001, 257, 63, 49032, 49038, 49055, 49083, 36158, 36129, 49087, {36162, 0, 0, 0}, 245, 245, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x3009, 0x0009, 257, 119, 49090, 49096, 49096, 49115, 36648, 36633, 49119, {36652, 0, 0, 0}, 246, 246, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x300A, 0x000A, 257, 29, 49122, 49128, 49146, 49165, 36695, 36671, 49169, {36699, 0, 0, 0}, 247, 247, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x301A, 0x6C1A, 257, 72, 49172, 49183, 48992, 49214, 9238, 48051, 49029, {38508, 0, 0, 0}, 248, 248, { 1251, 21025, 10007, 855, 0, ';' }},
+       {0x3401, 0x0001, 257, 61, 49218, 49224, 49240, 49270, 36158, 36129, 49274, {36162, 0, 0, 0}, 249, 249, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x3409, 0x0009, 257, 87, 49277, 49283, 49283, 49305, 36648, 36633, 45380, {36652, 0, 0, 0}, 250, 250, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x340A, 0x000A, 257, 20, 49309, 49315, 49331, 49348, 36695, 36671, 49352, {36699, 0, 0, 0}, 251, 251, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x3801, 0x0001, 257, 0, 49355, 49361, 49391, 49455, 36158, 36129, 49459, {36162, 0, 0, 0}, 252, 252, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x380A, 0x000A, 257, 113, 49462, 49468, 49486, 49505, 36695, 36671, 49509, {36699, 0, 0, 0}, 253, 253, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x3C01, 0x0001, 257, 12, 49512, 49518, 49535, 49567, 36158, 36129, 49571, {36162, 0, 0, 0}, 254, 254, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x3C0A, 0x000A, 257, 92, 49574, 49580, 49599, 49619, 36695, 36671, 49623, {36699, 0, 0, 0}, 255, 255, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x4001, 0x0001, 257, 93, 49626, 49632, 49647, 49671, 36158, 36129, 49675, {36162, 0, 0, 0}, 256, 256, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x4009, 0x0009, 257, 49, 49678, 49684, 49684, 49700, 36648, 36633, 43878, {36652, 0, 0, 0}, 257, 257, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x400A, 0x000A, 257, 14, 49704, 49710, 49728, 49747, 36695, 36671, 49751, {36699, 0, 0, 0}, 258, 258, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x440A, 0x000A, 257, 103, 49754, 49760, 49782, 49805, 36695, 36671, 49809, {36699, 0, 0, 0}, 259, 259, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x4809, 0x0009, 257, 100, 49812, 49818, 49818, 49838, 36648, 36633, 47213, {36652, 0, 0, 0}, 260, 260, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x480A, 0x000A, 257, 43, 49842, 49848, 49867, 49887, 36695, 36671, 49891, {36699, 0, 0, 0}, 261, 261, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x4C0A, 0x000A, 257, 79, 49894, 49900, 49920, 49941, 36695, 36671, 49945, {36699, 0, 0, 0}, 262, 262, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x500A, 0x000A, 257, 90, 49948, 49954, 49976, 49999, 36695, 36671, 50003, {36699, 0, 0, 0}, 263, 263, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x540A, 0x000A, 257, 112, 50006, 50012, 50036, 50062, 36695, 36671, 41620, {36699, 0, 0, 0}, 264, 264, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x6C1A, 0x7C1A, 257, -1, 50066, 50074, 50093, 48793, 9238, 48051, 0, {38508, 0, 0, 0}, 265, 265, { 1251, 21025, 10007, 855, 0, ';' }},
+       {0x701A, 0x7C1A, 257, -1, 50106, 50114, 50093, 48617, 9238, 48051, 0, {48057, 0, 0, 0}, 266, 266, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x742C, 0x002C, 257, -1, 50130, 50138, 38379, 46452, 38397, 14514, 0, {38401, 0, 0, 0}, 267, 267, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x7804, 0x007F, 257, -1, 36369, 36387, 36354, 36361, 36365, 36369, 0, {36372, 0, 0, 0}, 268, 268, { 936, 500, 10008, 936, 0, ',' }},
+       {0x7814, 0x0014, 257, -1, 46300, 50161, 50179, 46292, 46296, 46300, 0, {36485, 0, 0, 0}, 269, 269, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x781A, 0x007F, 257, -1, 50187, 50190, 50198, 50207, 50211, 50187, 0, {48057, 0, 0, 0}, 270, 270, { 1250, 870, 10082, 852, 0, ';' }},
+       {0x782C, 0x002C, 257, -1, 50215, 50223, 38379, 38393, 38397, 14514, 0, {38401, 0, 0, 0}, 271, 271, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x7843, 0x0043, 257, -1, 50243, 50251, 39257, 39268, 39272, 39248, 0, {0, 0, 0, 0}, 272, 272, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x7850, 0x0050, 257, -1, 50268, 50276, 40133, 50297, 40150, 40120, 0, {0, 0, 0, 0}, 273, 273, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x7C04, 0x7C04, 257, -1, 50301, 50308, 36354, 41368, 36365, 36369, 0, {41375, 0, 0, 0}, 274, 274, { 950, 500, 10002, 950, 0, ',' }},
+       {0x7C04, 0x7804, 257, -1, 50337, 41330, 36354, 41368, 36365, 36369, 0, {41375, 0, 0, 0}, 275, 275, { 950, 500, 10002, 950, 0, ',' }},
+       {0x7C14, 0x0014, 257, -1, 37178, 50345, 50363, 37170, 37174, 37178, 0, {36485, 0, 0, 0}, 276, 276, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x7C1A, 0x007F, 257, -1, 48051, 50377, 50093, 50385, 9238, 48051, 0, {38508, 0, 0, 0}, 277, 277, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x7C28, 0x0028, 257, -1, 50389, 50397, 0, 38222, 38226, 38213, 0, {0, 0, 0, 0}, 278, 278, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x7C43, 0x0043, 257, -1, 50414, 50422, 39257, 39268, 39272, 39248, 0, {0, 0, 0, 0}, 279, 279, { 1254, 500, 10029, 857, 0, ';' }},
+       {0x7C50, 0x0050, 257, -1, 50436, 50444, 40133, 46705, 40150, 40120, 0, {0, 0, 0, 0}, 280, 280, { 0, 500, 2, 1, 0, ',' }},
+       {0x7C5F, 0x005F, 257, -1, 50466, 50475, 40516, 40526, 40486, 40486, 0, {0, 0, 0, 0}, 281, 281, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x7C68, 0x0068, 257, -1, 50509, 50517, 40684, 40690, 40694, 40681, 0, {0, 0, 0, 0}, 282, 282, { 1252, 37, 10000, 437, 0, ',' }}
 };
 
 
 static const CultureInfoNameEntry culture_name_entries [] = {
-       {19461, 42},
-       {25852, 95},
-       {18193, 0},
-       {25858, 156},
-       {25864, 158},
-       {25870, 130},
-       {25876, 118},
-       {25882, 107},
-       {25888, 147},
-       {25894, 153},
-       {25900, 150},
-       {25906, 124},
-       {25912, 135},
-       {25918, 141},
-       {25924, 160},
-       {25930, 54},
-       {25936, 145},
-       {25942, 138},
-       {25948, 143},
-       {19131, 32},
-       {25954, 85},
-       {18226, 1},
-       {25960, 55},
-       {18266, 2},
-       {25966, 56},
-       {18326, 4},
-       {25972, 58},
-       {18353, 5},
-       {25978, 59},
-       {18377, 6},
-       {25984, 120},
-       {25990, 109},
-       {25996, 60},
-       {26002, 126},
-       {18403, 7},
-       {26008, 61},
-       {18437, 8},
-       {26014, 121},
-       {26020, 127},
-       {26026, 110},
-       {26032, 136},
-       {26038, 132},
-       {26044, 154},
-       {26050, 148},
-       {26056, 62},
-       {26062, 139},
-       {26068, 151},
-       {18456, 9},
-       {26074, 149},
-       {26080, 161},
-       {26086, 155},
-       {26092, 144},
-       {26098, 133},
-       {26104, 140},
-       {26110, 152},
-       {26116, 122},
-       {26122, 128},
-       {26128, 163},
-       {26134, 111},
-       {26140, 164},
-       {26146, 137},
-       {26152, 146},
-       {26158, 165},
-       {26164, 159},
-       {26170, 162},
-       {26176, 157},
-       {26182, 142},
-       {19207, 34},
-       {26188, 87},
-       {19392, 40},
-       {26194, 93},
-       {19294, 37},
-       {26200, 90},
-       {18484, 10},
-       {26206, 63},
-       {19535, 44},
-       {26212, 97},
-       {5984, 11},
-       {26218, 112},
-       {26224, 123},
-       {26230, 129},
-       {26236, 64},
-       {26242, 134},
-       {19804, 52},
-       {26248, 105},
-       {19626, 47},
-       {26254, 100},
-       {18534, 12},
-       {26260, 65},
-       {19564, 45},
-       {26266, 98},
-       {18884, 24},
-       {26272, 77},
-       {18563, 13},
-       {26278, 66},
-       {19357, 39},
-       {26284, 92},
-       {19050, 30},
-       {26290, 83},
-       {18591, 14},
-       {26296, 67},
-       {18622, 15},
-       {26302, 113},
-       {26308, 68},
-       {18650, 16},
-       {26314, 69},
-       {19493, 43},
-       {26320, 96},
-       {19738, 50},
-       {26326, 103},
-       {18680, 17},
-       {26332, 70},
-       {19831, 53},
-       {26338, 106},
-       {19262, 36},
-       {26345, 89},
-       {19233, 35},
-       {26351, 88},
-       {19418, 41},
-       {26357, 94},
-       {19773, 51},
-       {26363, 104},
-       {26369, 72},
-       {18708, 18},
-       {26375, 114},
-       {26381, 71},
-       {26387, 115},
-       {18736, 19},
-       {18763, 20},
-       {26393, 73},
-       {18788, 21},
-       {26399, 74},
-       {26405, 116},
-       {18821, 22},
-       {26411, 75},
-       {18850, 23},
-       {26417, 76},
-       {18913, 25},
-       {26423, 78},
-       {19172, 33},
-       {26429, 86},
-       {18942, 26},
-       {26435, 79},
-       {18969, 27},
-       {26441, 117},
-       {26447, 80},
-       {19597, 46},
-       {26453, 99},
-       {19668, 48},
-       {26459, 101},
-       {19701, 49},
-       {26465, 102},
-       {18996, 28},
-       {26471, 81},
-       {19022, 29},
-       {26477, 82},
-       {19089, 31},
-       {26483, 84},
-       {19324, 38},
-       {26489, 91},
-       {26495, 3},
-       {26502, 166},
-       {26509, 108},
-       {26515, 119},
-       {26521, 131},
-       {26527, 125},
-       {26533, 57}
+       {38650, 50},     /* af */
+       {50531, 145},    /* af-za */
+       {7860, 80},      /* am */
+       {50537, 171},    /* am-et */
+       {36129, 0},      /* ar */
+       {50543, 252},    /* ar-ae */
+       {50549, 254},    /* ar-bh */
+       {50555, 216},    /* ar-dz */
+       {50561, 203},    /* ar-eg */
+       {50567, 186},    /* ar-iq */
+       {50573, 241},    /* ar-jo */
+       {50579, 249},    /* ar-kw */
+       {50585, 245},    /* ar-lb */
+       {50591, 210},    /* ar-ly */
+       {50597, 222},    /* ar-ma */
+       {50603, 231},    /* ar-om */
+       {50609, 256},    /* ar-qa */
+       {50615, 97},     /* ar-sa */
+       {50621, 237},    /* ar-sy */
+       {50627, 227},    /* ar-tn */
+       {50633, 234},    /* ar-ye */
+       {14511, 70},     /* as */
+       {50639, 162},    /* as-in */
+       {14514, 44},     /* az */
+       {50645, 267},    /* az-cyrl */
+       {50653, 197},    /* az-cyrl-az */
+       {50664, 271},    /* az-latn */
+       {50672, 139},    /* az-latn-az */
+       {37922, 35},     /* be */
+       {50683, 130},    /* be-by */
+       {36190, 1},      /* bg */
+       {50689, 98},     /* bg-bg */
+       {39276, 62},     /* bn */
+       {50695, 201},    /* bn-bd */
+       {50701, 155},    /* bn-in */
+       {40154, 73},     /* bo */
+       {50707, 164},    /* bo-cn */
+       {40864, 91},     /* br */
+       {50713, 181},    /* br-fr */
+       {50187, 270},    /* bs */
+       {36272, 2},      /* ca */
+       {50719, 99},     /* ca-es */
+       {36408, 5},      /* cs */
+       {50725, 101},    /* cs-cz */
+       {40198, 74},     /* cy */
+       {50731, 165},    /* cy-gb */
+       {36461, 6},      /* da */
+       {50737, 102},    /* da-dk */
+       {36506, 7},      /* de */
+       {50743, 205},    /* de-at */
+       {50749, 188},    /* de-ch */
+       {50755, 103},    /* de-de */
+       {50761, 218},    /* de-li */
+       {50767, 212},    /* de-lu */
+       {36557, 8},      /* el */
+       {50773, 104},    /* el-gr */
+       {36633, 9},      /* en */
+       {50779, 206},    /* en-au */
+       {50785, 238},    /* en-bz */
+       {50791, 213},    /* en-ca */
+       {50797, 189},    /* en-gb */
+       {50803, 223},    /* en-ie */
+       {50809, 257},    /* en-in */
+       {50815, 232},    /* en-jm */
+       {50821, 219},    /* en-nz */
+       {50827, 250},    /* en-ph */
+       {50833, 260},    /* en-sg */
+       {50839, 242},    /* en-tt */
+       {50845, 105},    /* en-us */
+       {50851, 228},    /* en-za */
+       {50857, 246},    /* en-zw */
+       {36671, 10},     /* es */
+       {50863, 243},    /* es-ar */
+       {50869, 258},    /* es-bo */
+       {50875, 251},    /* es-cl */
+       {50881, 235},    /* es-co */
+       {50887, 220},    /* es-cr */
+       {50893, 229},    /* es-do */
+       {50899, 247},    /* es-ec */
+       {50905, 207},    /* es-es */
+       {50911, 214},    /* es-gt */
+       {50917, 261},    /* es-hn */
+       {50923, 190},    /* es-mx */
+       {50929, 262},    /* es-ni */
+       {50935, 224},    /* es-pa */
+       {50941, 239},    /* es-pe */
+       {50947, 263},    /* es-pr */
+       {50953, 255},    /* es-py */
+       {50959, 259},    /* es-sv */
+       {50965, 264},    /* es-us */
+       {50971, 253},    /* es-uy */
+       {50977, 233},    /* es-ve */
+       {38064, 37},     /* et */
+       {50983, 132},    /* et-ee */
+       {38419, 45},     /* eu */
+       {50989, 140},    /* eu-es */
+       {38230, 41},     /* fa */
+       {50995, 136},    /* fa-ir */
+       {36721, 11},     /* fi */
+       {51001, 106},    /* fi-fi */
+       {40641, 84},     /* fil */
+       {51007, 174},    /* fil-ph */
+       {38798, 52},     /* fo */
+       {51014, 147},    /* fo-fo */
+       {36771, 12},     /* fr */
+       {51020, 191},    /* fr-be */
+       {51026, 208},    /* fr-ca */
+       {51032, 215},    /* fr-ch */
+       {51038, 107},    /* fr-fr */
+       {51044, 221},    /* fr-lu */
+       {51050, 225},    /* fr-mc */
+       {38992, 56},     /* ga */
+       {51056, 198},    /* ga-ie */
+       {41059, 96},     /* gd */
+       {51062, 185},    /* gd-gb */
+       {40293, 77},     /* gl */
+       {51068, 168},    /* gl-es */
+       {40939, 93},     /* gsw */
+       {39414, 64},     /* gu */
+       {51074, 156},    /* gu-in */
+       {40681, 85},     /* ha */
+       {51080, 282},    /* ha-latn */
+       {51088, 175},    /* ha-latn-ng */
+       {36821, 13},     /* he */
+       {51099, 108},    /* he-il */
+       {38827, 53},     /* hi */
+       {51105, 148},    /* hi-in */
+       {37463, 26},     /* hr */
+       {51111, 121},    /* hr-hr */
+       {36883, 14},     /* hu */
+       {51117, 109},    /* hu-hu */
+       {38332, 43},     /* hy */
+       {51123, 138},    /* hy-am */
+       {37776, 33},     /* id */
+       {51129, 128},    /* id-id */
+       {14505, 89},     /* ig */
+       {51135, 179},    /* ig-ng */
+       {40819, 90},     /* ii */
+       {51141, 180},    /* ii-cn */
+       {36927, 15},     /* is */
+       {51147, 110},    /* is-is */
+       {36978, 16},     /* it */
+       {51153, 192},    /* it-ch */
+       {51159, 111},    /* it-it */
+       {37006, 17},     /* ja */
+       {51165, 112},    /* ja-jp */
+       {38691, 51},     /* ka */
+       {51171, 146},    /* ka-ge */
+       {39086, 58},     /* kk */
+       {40771, 88},     /* kl */
+       {51177, 178},    /* kl-gl */
+       {40223, 75},     /* km */
+       {51183, 166},    /* km-kh */
+       {35568, 68},     /* kn */
+       {51189, 160},    /* kn-in */
+       {37063, 18},     /* ko */
+       {51195, 113},    /* ko-kr */
+       {40320, 78},     /* kok */
+       {51201, 169},    /* kok-in */
+       {39166, 59},     /* ky */
+       {51208, 152},    /* ky-kg */
+       {40268, 76},     /* lo */
+       {51214, 167},    /* lo-la */
+       {38158, 39},     /* lt */
+       {51220, 134},    /* lt-lt */
+       {38110, 38},     /* lv */
+       {51226, 133},    /* lv-lv */
+       {38465, 46},     /* mk */
+       {51232, 141},    /* mk-mk */
+       {39845, 69},     /* ml */
+       {51238, 161},    /* ml-in */
+       {40120, 72},     /* mn */
+       {51244, 273},    /* mn-cyrl */
+       {51252, 280},    /* mn-mong */
+       {51260, 202},    /* mn-mong-cn */
+       {40027, 71},     /* mr */
+       {51271, 163},    /* mr-in */
+       {39038, 57},     /* ms */
+       {51277, 199},    /* ms-bn */
+       {51283, 151},    /* ms-my */
+       {38904, 54},     /* mt */
+       {51289, 149},    /* mt-mt */
+       {37178, 276},    /* nb */
+       {51295, 115},    /* nb-no */
+       {2082, 82},      /* ne */
+       {51301, 172},    /* ne-np */
+       {37101, 19},     /* nl */
+       {51307, 193},    /* nl-be */
+       {51313, 114},    /* nl-nl */
+       {46300, 269},    /* nn */
+       {51319, 194},    /* nn-no */
+       {37151, 20},     /* no */
+       {40731, 87},     /* nso */
+       {51325, 177},    /* nso-za */
+       {40912, 92},     /* oc */
+       {51332, 182},    /* oc-fr */
+       {14520, 65},     /* or */
+       {51338, 157},    /* or-in */
+       {39376, 63},     /* pa */
+       {37181, 21},     /* pl */
+       {51344, 116},    /* pl-pl */
+       {40614, 83},     /* ps */
+       {51350, 173},    /* ps-af */
+       {37230, 22},     /* pt */
+       {51356, 117},    /* pt-br */
+       {51362, 195},    /* pt-pt */
+       {37286, 23},     /* rm */
+       {51368, 118},    /* rm-ch */
+       {37335, 24},     /* ro */
+       {51374, 119},    /* ro-ro */
+       {37383, 25},     /* ru */
+       {51380, 120},    /* ru-ru */
+       {41036, 95},     /* rw */
+       {51386, 184},    /* rw-rw */
+       {41004, 94},     /* sah */
+       {51392, 183},    /* sah-ru */
+       {38950, 55},     /* se */
+       {51399, 209},    /* se-fi */
+       {51405, 150},    /* se-no */
+       {40355, 79},     /* si */
+       {51411, 170},    /* si-lk */
+       {37515, 27},     /* sk */
+       {51417, 122},    /* sk-sk */
+       {38007, 36},     /* sl */
+       {51423, 131},    /* sl-si */
+       {37569, 28},     /* sq */
+       {51429, 123},    /* sq-al */
+       {48051, 277},    /* sr */
+       {51435, 265},    /* sr-cyrl */
+       {51443, 230},    /* sr-cyrl-ba */
+       {51454, 248},    /* sr-cyrl-me */
+       {51465, 240},    /* sr-cyrl-rs */
+       {51476, 266},    /* sr-latn */
+       {51484, 226},    /* sr-latn-ba */
+       {51495, 244},    /* sr-latn-me */
+       {51506, 236},    /* sr-latn-rs */
+       {37595, 29},     /* sv */
+       {51517, 196},    /* sv-fi */
+       {51523, 124},    /* sv-se */
+       {39198, 60},     /* sw */
+       {51529, 153},    /* sw-ke */
+       {39542, 66},     /* ta */
+       {51535, 158},    /* ta-in */
+       {39640, 67},     /* te */
+       {51541, 159},    /* te-in */
+       {38213, 40},     /* tg */
+       {51547, 278},    /* tg-cyrl */
+       {51555, 135},    /* tg-cyrl-tj */
+       {37622, 30},     /* th */
+       {51566, 125},    /* th-th */
+       {38552, 47},     /* tn */
+       {51572, 142},    /* tn-za */
+       {37679, 31},     /* tr */
+       {51578, 126},    /* tr-tr */
+       {40486, 81},     /* tzm */
+       {51584, 281},    /* tzm-latn */
+       {37834, 34},     /* uk */
+       {51593, 129},    /* uk-ua */
+       {37721, 32},     /* ur */
+       {51599, 127},    /* ur-pk */
+       {39248, 61},     /* uz */
+       {51605, 272},    /* uz-cyrl */
+       {51613, 200},    /* uz-cyrl-uz */
+       {51624, 279},    /* uz-latn */
+       {51632, 154},    /* uz-latn-uz */
+       {38284, 42},     /* vi */
+       {51643, 137},    /* vi-vn */
+       {38579, 48},     /* xh */
+       {51649, 143},    /* xh-za */
+       {40698, 86},     /* yo */
+       {51655, 176},    /* yo-ng */
+       {36369, 268},    /* zh */
+       {51661, 3},      /* zh-chs */
+       {51668, 274},    /* zh-cht */
+       {51675, 187},    /* zh-cn */
+       {51681, 4},      /* zh-hans */
+       {51689, 275},    /* zh-hant */
+       {51697, 204},    /* zh-hk */
+       {51703, 217},    /* zh-mo */
+       {51709, 211},    /* zh-sg */
+       {51715, 100},    /* zh-tw */
+       {38605, 49},     /* zu */
+       {51721, 144}     /* zu-za */
 };
 
 
 static const RegionInfoEntry region_entries [] = {
-       { 0, 0,25354,343,343,26539,343,26560,26564},
-       { 0, 1,26592,343,343,26595,343,26607,26611},
-       { 0, 2,26619,343,343,26622,343,26642,26646},
-       { 0, 3,26668,343,343,26671,343,26642,26646},
-       { 0, 4,21207,343,343,26680,343,26688,26692},
-       { 0, 5,465,343,343,26705,343,26713,26717},
-       { 0, 6,26731,343,343,26734,343,26755,26759},
-       { 0, 7,26788,343,343,26791,343,26798,26802},
-       { 0, 8,24967,343,343,26817,343,24762,26827},
-       { 0, 9,26842,343,343,26845,343,26860,26864},
-       { 0, 10,23488,343,343,26874,343,26882,26886},
-       { 0, 11,23521,343,343,26891,343,26901,26905},
-       { 0, 12,26923,343,343,26926,343,26932,26936},
-       { 0, 13,26951,343,343,26954,343,26965,26969},
-       { 0, 14,26989,343,343,26992,343,27015,27019},
-       { 0, 15,27055,343,343,27058,343,27067,27071},
-       { 0, 16,27087,343,343,27090,343,27101,27105},
-       { 0, 17,23032,343,343,27121,343,26882,26886},
-       { 0, 18,27129,343,343,27132,343,27145,27149},
-       { 0, 19,20008,343,343,27165,343,27174,27178},
-       { 0, 20,25466,343,343,27196,343,27204,27208},
-       { 0, 21,27223,343,343,27226,343,27234,27238},
-       { 0, 22,27252,343,343,27255,343,27145,27149},
-       { 0, 23,27261,343,343,27264,343,27272,27276},
-       { 0, 24,27292,343,343,27295,343,27302,27306},
-       { 0, 25,25620,343,343,27320,343,27328,27332},
-       { 0, 26,20946,343,343,27342,343,27349,27353},
-       { 0, 27,27368,343,343,27371,343,27379,27383},
-       { 0, 28,27399,343,343,27402,343,27416,27420},
-       { 0, 29,27436,343,343,27439,343,27448,27452},
-       { 0, 30,21558,343,343,27467,343,27475,27479},
-       { 0, 31,27497,343,343,27500,343,27507,27511},
-       { 0, 32,23614,343,343,27525,343,27532,27536},
-       { 0, 33,27552,343,343,27555,343,26901,26905},
-       { 0, 34,27569,343,343,27572,343,27605,27609},
-       { 0, 35,27635,343,343,27638,343,27663,27667},
-       { 0, 36,27682,343,343,27685,343,27663,27667},
-       { 0, 37,11008,343,343,27691,343,27703,27707},
-       { 0, 38,27719,343,343,27722,343,27145,27149},
-       { 0, 39,27737,343,343,27740,343,27753,27757},
-       { 0, 40,25247,343,343,27776,343,27782,27786},
-       { 0, 41,27799,343,343,27802,343,27663,27667},
-       { 0, 42,11087,343,343,27811,343,27817,27821},
-       { 0, 43,24710,343,343,27843,343,27852,27856},
-       { 0, 44,24138,343,343,27871,343,18035,27882},
-       { 0, 45,27900,343,343,27903,343,27908,27912},
-       { 0, 46,27923,343,343,27926,343,27937,27941},
-       { 0, 47,27959,343,343,27962,343,26901,26905},
-       { 0, 48,27979,343,343,27982,343,27989,27993},
-       { 0, 49,20159,343,343,28006,343,28021,28025},
-       { 0, 50,4304,343,343,28047,343,26882,26886},
-       { 0, 51,28055,343,343,28058,343,28067,28071},
-       { 0, 52,20201,343,343,28086,343,28094,28098},
-       { 0, 53,28111,343,343,28114,343,26642,26646},
-       { 0, 54,24495,343,343,28123,343,28142,28146},
-       { 0, 55,23968,343,343,28161,343,28169,28173},
-       { 0, 56,25107,343,343,28188,343,28196,28200},
-       { 0, 57,21656,343,343,28214,343,28222,28226},
-       { 0, 58,23352,343,343,28241,343,28247,28251},
-       { 0, 59,28266,343,343,28269,343,28284,28288},
-       { 0, 60,28304,343,343,28307,343,28315,28319},
-       { 0, 61,20051,343,343,28334,343,26882,26886},
-       { 0, 62,28340,343,343,28343,343,28352,28356},
-       { 0, 63,20376,343,343,28371,343,26882,26886},
-       { 0, 64,28379,343,343,28382,343,28387,28391},
-       { 0, 65,28403,343,343,28406,343,28423,28427},
-       { 0, 66,28450,343,343,28453,343,26860,26864},
-       { 0, 67,22262,343,343,28464,343,28094,28098},
-       { 0, 68,20420,343,343,28478,343,26882,26886},
-       { 0, 69,28485,343,343,28488,343,27663,27667},
-       { 0, 70,22932,343,343,28494,343,28509,28513},
-       { 0, 71,28536,343,343,28539,343,26642,26646},
-       { 0, 72,22208,343,343,28547,343,28555,28559},
-       { 0, 73,28573,343,343,28576,343,26882,26886},
-       { 0, 74,28590,343,343,28593,343,28599,28603},
-       { 0, 75,28614,343,343,28617,343,28627,28631},
-       { 0, 76,28647,343,343,28650,343,28094,28098},
-       { 0, 77,28660,343,343,28663,343,28670,28674},
-       { 0, 78,28688,343,343,28691,343,28698,28702},
-       { 0, 79,28715,343,343,28718,343,26882,26886},
-       { 0, 80,28729,343,343,28732,343,27663,27667},
-       { 0, 81,20302,343,343,28750,343,26882,26886},
-       { 0, 82,23856,343,343,28757,343,28767,28771},
-       { 0, 83,28789,343,343,28792,343,26860,26864},
-       { 0, 84,28797,343,343,28800,343,28807,28811},
-       { 0, 85,23436,343,343,28825,343,28849,28853},
-       { 0, 86,28870,343,343,28873,343,26901,26905},
-       { 0, 87,25730,343,343,28907,343,28916,28920},
-       { 0, 88,21098,343,343,28936,343,28944,28948},
-       { 0, 89,20521,343,343,28962,343,28970,28974},
-       { 0, 90,21423,343,343,28991,343,29001,29005},
-       { 0, 91,24282,343,343,29023,343,26882,26886},
-       { 0, 92,20469,343,343,29031,343,29038,29042},
-       { 0, 93,22316,343,343,29061,343,29067,29071},
-       { 0, 94,29084,343,343,29087,343,26860,26864},
-       { 0, 95,22807,343,343,29118,343,29123,29127},
-       { 0, 96,21802,343,343,29139,343,29144,29148},
-       { 0, 97,20570,343,343,29161,343,29169,29173},
-       { 0, 98,20613,343,343,29189,343,26882,26886},
-       { 0, 99,29195,343,343,29198,343,29206,29210},
-       { 0, 100,24870,343,343,29226,343,29233,29237},
-       { 0, 101,20658,343,343,29253,343,29259,29263},
-       { 0, 102,22359,343,343,29276,343,29282,29286},
-       { 0, 103,29302,343,343,29305,343,29316,29320},
-       { 0, 104,29334,343,343,29337,343,29346,29350},
-       { 0, 105,29365,343,343,29368,343,26901,26905},
-       { 0, 106,29377,343,343,29380,343,29388,29392},
-       { 0, 107,29405,343,343,29408,343,26642,26646},
-       { 0, 108,29430,343,343,29433,343,29445,29449},
-       { 0, 109,20713,343,343,29466,343,29478,29482},
-       { 0, 110,25166,343,343,29499,343,29506,29510},
-       { 0, 111,29524,343,343,29527,343,29542,29546},
-       { 0, 112,29568,343,343,29571,343,29582,29586},
-       { 0, 113,29603,343,343,29606,343,29611,29615},
-       { 0, 114,25025,343,343,29627,343,29635,29639},
-       { 0, 115,29654,343,343,29657,343,26642,26646},
-       { 0, 116,29669,343,343,29672,343,27703,27707},
-       { 0, 117,29686,343,343,29689,343,29699,29703},
-       { 0, 118,29719,343,343,29722,343,29730,29734},
-       { 0, 119,21754,343,343,29750,343,29760,29764},
-       { 0, 120,23775,343,343,29780,343,26882,26886},
-       { 0, 121,21702,343,343,29791,343,29798,29802},
-       { 0, 122,23670,343,343,29815,343,29821,29825},
-       { 0, 123,24251,343,343,29838,343,28284,28288},
-       { 0, 124,29846,343,343,29849,343,26882,26886},
-       { 0, 125,7444,343,343,29856,343,29864,29868},
-       { 0, 126,29881,343,343,29884,343,29895,29899},
-       { 0, 127,29916,343,343,29919,343,26860,26864},
-       { 0, 128,22066,343,343,29936,343,29946,29950},
-       { 0, 129,29967,343,343,29970,343,27145,27149},
-       { 0, 130,29975,343,343,29978,343,29986,29990},
-       { 0, 131,30003,343,343,30006,343,30015,30019},
-       { 0, 132,24047,343,343,30036,343,30055,30059},
-       { 0, 133,30072,343,343,30075,343,26860,26864},
-       { 0, 134,30100,343,343,30103,343,26882,26886},
-       { 0, 135,30114,343,343,30117,343,30128,30132},
-       { 0, 136,30151,343,343,30154,343,26642,26646},
-       { 0, 137,30165,343,343,30168,343,30174,30178},
-       { 0, 138,30191,343,343,30194,343,30204,30208},
-       { 0, 139,30224,343,343,30227,343,30236,30240},
-       { 0, 140,30264,343,343,30267,343,30274,30278},
-       { 0, 141,22981,343,343,30292,343,30299,30303},
-       { 0, 142,30316,343,343,30319,343,30328,30332},
-       { 0, 143,30350,343,343,30353,343,30364,30368},
-       { 0, 144,30387,343,343,30390,343,30404,30408},
-       { 0, 145,30418,343,343,30421,343,27145,27149},
-       { 0, 146,30427,343,343,30430,343,26901,26905},
-       { 0, 147,30445,343,343,30448,343,30456,30460},
-       { 0, 148,25784,343,343,30475,343,30485,30489},
-       { 0, 149,20765,343,343,30512,343,26882,26886},
-       { 0, 150,20856,343,343,30524,343,27416,27420},
-       { 0, 151,30531,343,343,30534,343,30540,30544},
-       { 0, 152,30559,343,343,30562,343,26901,26905},
-       { 0, 153,30568,343,343,30571,343,27753,27757},
-       { 0, 154,24082,343,343,30576,343,27753,27757},
-       { 0, 155,24548,343,343,30588,343,30593,30597},
-       { 0, 156,24331,343,343,30607,343,30614,30618},
-       { 0, 157,24811,343,343,30636,343,30641,30645},
-       { 0, 158,30664,343,343,30667,343,30404,30408},
-       { 0, 159,30684,343,343,30687,343,30704,30708},
-       { 0, 160,25201,343,343,30730,343,18139,30742},
-       { 0, 161,30758,343,343,30761,343,30770,30774},
-       { 0, 162,20897,343,343,30789,343,30796,30800},
-       { 0, 163,468,343,343,30813,343,26882,26886},
-       { 0, 164,30839,343,343,30842,343,27753,27757},
-       { 0, 165,25842,343,343,30851,343,26860,26864},
-       { 0, 166,23254,343,343,30863,343,26882,26886},
-       { 0, 167,30872,343,343,30875,343,26860,26864},
-       { 0, 168,25518,343,343,30881,343,30890,30894},
-       { 0, 169,25570,343,343,30911,343,30917,30921},
-       { 0, 170,30933,343,343,30936,343,26882,26886},
-       { 0, 171,20994,343,343,30945,343,30953,30957},
-       { 0, 172,21050,343,343,30970,343,30977,30981},
-       { 0, 173,31007,343,343,31010,343,31017,31021},
-       { 0, 174,11005,343,343,31035,343,31048,31052},
-       { 0, 175,31064,343,343,31067,343,31083,31087},
-       { 0, 176,31110,343,343,31113,343,31124,31128},
-       { 0, 177,31145,343,343,31148,343,31154,31158},
-       { 0, 178,21251,343,343,31173,343,31180,31184},
-       { 0, 179,23722,343,343,31198,343,31208,31212},
-       { 0, 180,31229,343,343,31232,343,31245,31249},
-       { 0, 181,21614,343,343,31268,343,17913,31277},
-       { 0, 182,31292,343,343,31295,343,27416,27420},
-       { 0, 183,21159,343,343,31318,343,31327,31331},
-       { 0, 184,31345,343,343,31348,343,31361,31365},
-       { 0, 185,31384,343,343,31387,343,26882,26886},
-       { 0, 186,31398,343,343,31401,343,27145,27149},
-       { 0, 187,31409,343,343,31412,343,31420,31424},
-       { 0, 188,31440,343,343,31443,343,31452,31456},
-       { 0, 189,31473,343,343,31476,343,31498,31502},
-       { 0, 190,25678,343,343,31530,343,18183,31542},
-       { 0, 191,24766,343,343,31560,343,31566,31570},
-       { 0, 192,31583,343,343,31586,343,31596,31600},
-       { 0, 193,31620,343,343,31623,343,26860,26864},
-       { 0, 194,31648,343,343,31651,343,27663,27667},
-       { 0, 195,31656,343,343,31659,343,26882,26886},
-       { 0, 196,31687,343,343,31690,343,27145,27149},
-       { 0, 197,21316,343,343,31695,343,31704,31708},
-       { 0, 198,31718,343,343,31721,343,31732,31736},
-       { 0, 199,31754,343,343,31757,343,27753,27757},
-       { 0, 200,17899,343,343,31765,343,26860,26864},
-       { 0, 201,31777,343,343,31780,343,31793,31797},
-       { 0, 202,24387,343,343,31816,343,31824,31828},
-       { 0, 203,31843,343,343,31846,343,31852,31856},
-       { 0, 204,21362,343,343,31871,343,31878,31882},
-       { 0, 205,24913,343,343,31895,343,31915,31919},
-       { 0, 206,31946,343,343,31949,343,26901,26905},
-       { 0, 207,20097,343,343,31956,343,31963,31967},
-       { 0, 208,31985,343,343,31988,343,31997,32001},
-       { 0, 209,21490,343,343,32020,343,32028,32032},
-       { 0, 210,32050,343,343,32053,343,32060,32064},
-       { 0, 211,32081,343,343,32084,343,26860,26864},
-       { 0, 212,20335,343,343,32121,343,26860,26864},
-       { 0, 213,25404,343,343,32135,343,32143,32147},
-       { 0, 214,32169,343,343,32172,343,32183,32187},
-       { 0, 215,32202,343,343,32205,343,26882,26886},
-       { 0, 216,32213,343,343,32216,343,26642,26646},
-       { 0, 217,24602,343,343,32249,343,32259,32263},
-       { 0, 218,32282,343,343,32285,343,26860,26864},
-       { 0, 219,1621,343,343,32308,343,26860,26864},
-       { 0, 220,21860,343,343,32328,343,32336,32340},
-       { 0, 221,32356,343,343,32359,343,32367,32371},
-       { 0, 222,32384,343,343,32387,343,30404,30408},
-       { 0, 223,32405,343,343,32408,343,32414,32418},
-       { 0, 224,24658,343,343,32437,343,32443,32447},
-       { 0, 225,32459,343,343,32462,343,26882,26886},
-       { 0, 226,32470,343,343,32473,343,32484,32488},
-       { 0, 227,22125,343,343,32512,343,32525,32529},
-       { 0, 228,32548,343,343,32551,343,32558,32562},
-       { 0, 229,25057,343,343,32577,343,32586,32590}
+       { 224,49459,46754,46754,51727,51748,36065,51795,51799,51827},
+       { 3,45326,51851,51851,51855,51867,35845,51886,51890,51905},
+       { 6,42506,51918,51918,51922,51930,35571,51941,51945,0},
+       { 7,3804,47808,47808,51958,51966,35645,52014,52018,0},
+       { 11,48950,47455,47455,52032,52032,35479,48673,52042,52057},
+       { 14,46903,52072,52072,52076,52084,35464,52096,52100,52100},
+       { 12,46936,52105,52105,52109,52109,35479,52119,52123,52123},
+       { 5,43401,38393,38393,52141,52152,35873,52164,52168,52186},
+       { 25,48054,52206,52206,52210,52233,35963,52270,52274,52310},
+       { 23,46662,52353,52353,52357,52368,35911,52393,52397,52414},
+       { 21,46141,37957,37957,52455,52463,35464,52096,52100,52472},
+       { 35,41278,36222,36222,52477,52486,35448,52503,52507,52521},
+       { 17,49571,52547,52547,52551,52559,36075,52574,52578,52593},
+       { 37,46545,52617,52617,52621,52621,35479,52628,52632,52646},
+       { 26,49751,52659,52659,52663,52663,36099,40190,52671,52690},
+       { 32,42198,52700,52700,52704,52711,35537,52718,52722,52737},
+       { 29,42892,52753,52753,52757,52765,0,52782,52786,52803},
+       { 24,48707,52835,52835,52839,52839,35479,52846,52850,52850},
+       { 39,47029,52864,52864,52868,52868,35479,52875,52879,52895},
+       { 223,13256,52911,52911,52915,52927,0,52934,52938,52950},
+       { 46,49352,52964,52964,52968,52968,35479,52974,52978,52991},
+       { 45,13335,53004,53004,53008,53014,35801,53033,53037,53050},
+       { 51,48551,53069,53069,53073,53073,35479,53082,53086,53101},
+       { 54,47699,53117,53117,53121,53121,35945,53132,53136,53155},
+       { 75,41441,53176,53176,53180,53195,35472,53213,53217,53239},
+       { 94,41531,36524,36524,53254,53262,35464,52096,52100,52100},
+       { 61,41483,53274,53274,53278,53286,35476,53294,53298,53311},
+       { 65,48241,53323,53323,53327,53346,35479,53368,53372,53387},
+       { 4,47459,53403,53403,53407,53415,35935,53430,53434,53449},
+       { 66,49169,53473,53473,53477,53477,35479,53485,53489,53499},
+       { 70,42990,50062,50062,53521,53529,35464,52096,52100,52472},
+       { 67,46758,53535,53535,53539,53545,35915,53552,53556,53571},
+       { 217,41321,36691,36691,53589,53595,35464,52096,52100,52472},
+       { 73,45205,53603,53603,53607,53616,35825,53632,53636,53651},
+       { 77,41661,36738,36738,53677,53685,35464,52096,52100,52472},
+       { 81,43821,53691,53691,53695,53709,35476,53294,53298,53718},
+       { 84,41705,36791,36791,53731,53731,35464,52096,52100,52472},
+       { 242,44850,53738,53738,53742,53757,35806,53770,53774,53797},
+       { 88,43767,53819,53819,53823,53831,0,53862,53866,53880},
+       { 93,45604,53915,53915,53919,53929,35476,53294,53298,53946},
+       { 98,41587,53964,53964,53968,53975,35464,52096,52100,53988},
+       { 99,47347,53997,53997,54001,54001,7769,54011,54015,54034},
+       { 104,46851,54055,54055,54059,54079,35479,54107,54111,54128},
+       { 106,49891,54135,54135,54139,54139,2494,54148,54152,54169},
+       { 108,42397,37484,37484,54188,54196,35568,54205,54209,54223},
+       { 109,41806,36903,36903,54228,54236,35494,54250,54254,54271},
+       { 111,42755,54285,54285,54289,54289,35594,54299,54303,54321},
+       { 68,46494,54338,54338,54342,54350,35464,52096,52100,52100},
+       { 117,41754,54356,54356,54360,54367,35490,54378,54382,54401},
+       { 113,43878,37807,37807,54408,54414,35651,54427,54431,54444},
+       { 121,45935,54479,54479,54483,54488,35884,54501,54505,54517},
+       { 116,43179,54539,54539,54543,54548,35637,54559,54563,54576},
+       { 110,41855,36950,36950,54596,54604,35476,54612,54616,54633},
+       { 118,41898,36998,36998,54649,54655,35464,52096,52100,52100},
+       { 124,48389,54662,54662,54666,54666,35479,54674,54678,54678},
+       { 126,48853,54694,54694,54698,54705,36035,54718,54722,54738},
+       { 122,41943,37028,37028,54760,54766,35468,54773,54777,54790},
+       { 129,44131,54800,54800,54804,54804,35665,54810,54814,54830},
+       { 130,44088,54848,54848,54852,54863,35658,54884,54888,0},
+       { 40,44928,40260,40260,54903,54912,35809,54934,54938,54953},
+       { 134,41998,37083,37083,54958,54970,35529,54983,54987,55004},
+       { 136,49274,55021,55021,55025,55032,36055,55045,55049,55063},
+       { 138,44970,40285,40285,55085,40275,35813,55090,55094,55106},
+       { 139,49087,55116,55116,55120,55128,36045,55139,55143,55158},
+       { 145,47608,55180,55180,55184,55184,0,52934,52938,55198},
+       { 42,45146,55216,55216,55220,55230,35817,55262,55266,55283},
+       { 141,43088,55318,55318,55322,55332,35634,55340,55344,55361},
+       { 147,47266,55367,55367,55371,55382,35464,52096,52100,52100},
+       { 140,43036,55392,55392,55396,55403,35617,55411,55415,55428},
+       { 148,47149,55442,55442,55446,55452,35925,55463,55467,55480},
+       { 159,47812,40054,40054,55500,55508,35949,55521,55525,55541},
+       { 158,47937,55561,55561,55565,55565,35464,52096,52100,52472},
+       { 270,49029,55572,55572,55576,55587,35464,52096,52100,55605},
+       { 19618,43517,55610,55610,55614,55624,0,55610,55645,55662},
+       { 151,47548,55694,55694,55698,55714,0,55742,55746,55762},
+       { 163,43917,38921,38921,55772,55772,35464,52096,52100,55778},
+       { 166,46090,55783,55783,55787,55794,35479,55802,55806,55819},
+       { 167,44022,55833,55833,55837,55837,35655,55846,55850,55868},
+       { 175,45434,55885,55885,55889,55897,35852,55906,55910,55925},
+       { 182,49945,55931,55931,55935,55935,36106,55945,55949,55969},
+       { 176,42050,37121,37121,55992,56004,35464,52096,52100,52100},
+       { 177,42108,37170,37170,56014,56021,35476,56027,56031,56047},
+       { 178,45266,56061,56061,56065,56071,35832,56087,56091,0},
+       { 183,47643,56106,56106,56110,56110,35479,56122,56126,56126},
+       { 164,48358,56145,56145,56149,56154,35982,56165,56169,56180},
+       { 192,47889,39406,39406,56200,56207,35959,56215,56219,56237},
+       { 187,48752,56254,56254,56258,56263,36023,56269,56273,56292},
+       { 201,45380,56310,56310,56314,56326,35848,56336,56340,56340},
+       { 190,42694,56356,56356,56360,56369,35589,56384,56388,56404},
+       { 191,42149,56432,56432,56436,56443,35533,56450,56454,56467},
+       { 202,50003,56481,56481,56485,56485,35479,53485,53489,53499},
+       { 193,46357,56497,56497,56501,56501,35464,52096,52100,52100},
+       { 185,49623,56510,56510,56514,56514,36085,56523,56527,56546},
+       { 197,49675,56565,56565,56569,56575,36089,56582,56586,56598},
+       { 200,42293,56616,56616,56620,56628,0,56637,56641,56654},
+       { 271,48621,50385,50385,56668,56675,36008,56688,56692,56706},
+       { 203,42349,37409,37409,56719,56726,35544,56739,56743,56757},
+       { 204,45803,56789,56789,56793,56793,35856,56800,56804,0},
+       { 205,13253,56818,56818,56822,56835,35401,56882,56886,56898},
+       { 221,42550,56918,56918,56922,56929,35476,56937,56941,56955},
+       { 215,47213,56968,56968,56972,56982,0,56992,56996,57013},
+       { 212,42948,57026,57026,57030,57039,35464,52096,52100,57049},
+       { 143,42459,57054,57054,57058,57067,35464,52096,52100,52100},
+       { 72,49809,38034,38034,57088,57088,36102,53485,53489,53499},
+       { 222,48677,57100,57100,57104,57110,36013,57121,57125,57138},
+       { 227,42597,37640,37640,57158,37630,35582,57167,57171,57181},
+       { 228,43131,57200,57200,57204,0,35658,57215,57219,57238},
+       { 234,48133,57251,57251,57255,57263,35966,57272,57276,57291},
+       { 235,42643,57312,57312,57316,57323,35586,57332,57336,57349},
+       { 225,48896,57363,57363,57367,57367,35479,57387,57391,57391},
+       { 237,41372,57418,57418,57422,57429,35859,57436,57440,57458},
+       { 241,42822,37868,37868,57468,57476,35597,57491,57495,57513},
+       { 244,41620,57547,57547,57551,57551,35479,53485,53489,53489},
+       { 246,49509,57565,57565,57569,57569,35479,57577,57581,57596},
+       { 247,44205,39268,39268,57610,57621,35878,57642,57646,57661},
+       { 249,48443,57680,57680,57684,57684,35992,57694,57698,57718},
+       { 251,43237,57738,57738,57742,57750,35641,57761,57765,57781},
+       { 261,48499,57789,57789,57793,57799,35998,57810,57814,57826},
+       { 209,43548,57844,57844,57848,0,10506,57861,57865,0},
+       { 264,49119,57884,57884,57888,57888,35479,53485,53489,53489}
 };
 
 
 static const RegionInfoNameEntry region_name_entries [] = {
-       {25354, 0},
-       {26592, 1},
-       {26619, 2},
-       {26668, 3},
-       {21207, 4},
-       {465, 5},
-       {26731, 6},
-       {26788, 7},
-       {24967, 8},
-       {26842, 9},
-       {23488, 10},
-       {23521, 11},
-       {26923, 12},
-       {26951, 13},
-       {26989, 14},
-       {27055, 15},
-       {27087, 16},
-       {23032, 17},
-       {27129, 18},
-       {20008, 19},
-       {25466, 20},
-       {27223, 21},
-       {27252, 22},
-       {27261, 23},
-       {27292, 24},
-       {25620, 25},
-       {20946, 26},
-       {27368, 27},
-       {27399, 28},
-       {27436, 29},
-       {21558, 30},
-       {27497, 31},
-       {23614, 32},
-       {27552, 33},
-       {27569, 34},
-       {27635, 35},
-       {27682, 36},
-       {11008, 37},
-       {27719, 38},
-       {27737, 39},
-       {25247, 40},
-       {27799, 41},
-       {11087, 42},
-       {24710, 43},
-       {24138, 44},
-       {27900, 45},
-       {27923, 46},
-       {27959, 47},
-       {27979, 48},
-       {20159, 49},
-       {4304, 50},
-       {28055, 51},
-       {20201, 52},
-       {28111, 53},
-       {24495, 54},
-       {23968, 55},
-       {25107, 56},
-       {21656, 57},
-       {23352, 58},
-       {28266, 59},
-       {28304, 60},
-       {20051, 61},
-       {28340, 62},
-       {20376, 63},
-       {28379, 64},
-       {28403, 65},
-       {28450, 66},
-       {22262, 67},
-       {20420, 68},
-       {28485, 69},
-       {22932, 70},
-       {28536, 71},
-       {22208, 72},
-       {28573, 73},
-       {28590, 74},
-       {28614, 75},
-       {28647, 76},
-       {28660, 77},
-       {28688, 78},
-       {28715, 79},
-       {28729, 80},
-       {20302, 81},
-       {23856, 82},
-       {28789, 83},
-       {28797, 84},
-       {23436, 85},
-       {28870, 86},
-       {25730, 87},
-       {21098, 88},
-       {20521, 89},
-       {21423, 90},
-       {24282, 91},
-       {20469, 92},
-       {22316, 93},
-       {29084, 94},
-       {22807, 95},
-       {21802, 96},
-       {20570, 97},
-       {20613, 98},
-       {29195, 99},
-       {24870, 100},
-       {20658, 101},
-       {22359, 102},
-       {29302, 103},
-       {29334, 104},
-       {29365, 105},
-       {29377, 106},
-       {29405, 107},
-       {29430, 108},
-       {20713, 109},
-       {25166, 110},
-       {29524, 111},
-       {29568, 112},
-       {29603, 113},
-       {25025, 114},
-       {29654, 115},
-       {29669, 116},
-       {29686, 117},
-       {29719, 118},
-       {21754, 119},
-       {23775, 120},
-       {21702, 121},
-       {23670, 122},
-       {24251, 123},
-       {29846, 124},
-       {7444, 125},
-       {29881, 126},
-       {29916, 127},
-       {22066, 128},
-       {29967, 129},
-       {29975, 130},
-       {30003, 131},
-       {24047, 132},
-       {30072, 133},
-       {30100, 134},
-       {30114, 135},
-       {30151, 136},
-       {30165, 137},
-       {30191, 138},
-       {30224, 139},
-       {30264, 140},
-       {22981, 141},
-       {30316, 142},
-       {30350, 143},
-       {30387, 144},
-       {30418, 145},
-       {30427, 146},
-       {30445, 147},
-       {25784, 148},
-       {20765, 149},
-       {20856, 150},
-       {30531, 151},
-       {30559, 152},
-       {30568, 153},
-       {24082, 154},
-       {24548, 155},
-       {24331, 156},
-       {24811, 157},
-       {30664, 158},
-       {30684, 159},
-       {25201, 160},
-       {30758, 161},
-       {20897, 162},
-       {468, 163},
-       {30839, 164},
-       {25842, 165},
-       {23254, 166},
-       {30872, 167},
-       {25518, 168},
-       {25570, 169},
-       {30933, 170},
-       {20994, 171},
-       {21050, 172},
-       {31007, 173},
-       {11005, 174},
-       {31064, 175},
-       {31110, 176},
-       {31145, 177},
-       {21251, 178},
-       {23722, 179},
-       {31229, 180},
-       {21614, 181},
-       {31292, 182},
-       {21159, 183},
-       {31345, 184},
-       {31384, 185},
-       {31398, 186},
-       {31409, 187},
-       {31440, 188},
-       {31473, 189},
-       {25678, 190},
-       {24766, 191},
-       {31583, 192},
-       {31620, 193},
-       {31648, 194},
-       {31656, 195},
-       {31687, 196},
-       {21316, 197},
-       {31718, 198},
-       {31754, 199},
-       {17899, 200},
-       {31777, 201},
-       {24387, 202},
-       {31843, 203},
-       {21362, 204},
-       {24913, 205},
-       {31946, 206},
-       {20097, 207},
-       {31985, 208},
-       {21490, 209},
-       {32050, 210},
-       {32081, 211},
-       {20335, 212},
-       {25404, 213},
-       {32169, 214},
-       {32202, 215},
-       {32213, 216},
-       {24602, 217},
-       {32282, 218},
-       {1621, 219},
-       {21860, 220},
-       {32356, 221},
-       {32384, 222},
-       {32405, 223},
-       {24658, 224},
-       {32459, 225},
-       {32470, 226},
-       {22125, 227},
-       {32548, 228},
-       {25057, 229}
+       {49459, 0},      /* AE */
+       {45326, 1},      /* AF */
+       {42506, 2},      /* AL */
+       {3804, 3},       /* AM */
+       {48950, 4},      /* AR */
+       {46903, 5},      /* AT */
+       {46936, 6},      /* AU */
+       {43401, 7},      /* AZ */
+       {48054, 8},      /* BA */
+       {46662, 9},      /* BD */
+       {46141, 10},     /* BE */
+       {41278, 11},     /* BG */
+       {49571, 12},     /* BH */
+       {46545, 13},     /* BN */
+       {49751, 14},     /* BO */
+       {42198, 15},     /* BR */
+       {42892, 16},     /* BY */
+       {48707, 17},     /* BZ */
+       {47029, 18},     /* CA */
+       {13256, 19},     /* CH */
+       {49352, 20},     /* CL */
+       {13335, 21},     /* CN */
+       {48551, 22},     /* CO */
+       {47699, 23},     /* CR */
+       {41441, 24},     /* CZ */
+       {41531, 25},     /* DE */
+       {41483, 26},     /* DK */
+       {48241, 27},     /* DO */
+       {47459, 28},     /* DZ */
+       {49169, 29},     /* EC */
+       {42990, 30},     /* EE */
+       {46758, 31},     /* EG */
+       {41321, 32},     /* ES */
+       {45205, 33},     /* ET */
+       {41661, 34},     /* FI */
+       {43821, 35},     /* FO */
+       {41705, 36},     /* FR */
+       {44850, 37},     /* GB */
+       {43767, 38},     /* GE */
+       {45604, 39},     /* GL */
+       {41587, 40},     /* GR */
+       {47347, 41},     /* GT */
+       {46851, 42},     /* HK */
+       {49891, 43},     /* HN */
+       {42397, 44},     /* HR */
+       {41806, 45},     /* HU */
+       {42755, 46},     /* ID */
+       {46494, 47},     /* IE */
+       {41754, 48},     /* IL */
+       {43878, 49},     /* IN */
+       {45935, 50},     /* IQ */
+       {43179, 51},     /* IR */
+       {41855, 52},     /* IS */
+       {41898, 53},     /* IT */
+       {48389, 54},     /* JM */
+       {48853, 55},     /* JO */
+       {41943, 56},     /* JP */
+       {44131, 57},     /* KE */
+       {44088, 58},     /* KG */
+       {44928, 59},     /* KH */
+       {41998, 60},     /* KR */
+       {49274, 61},     /* KW */
+       {44970, 62},     /* LA */
+       {49087, 63},     /* LB */
+       {47608, 64},     /* LI */
+       {45146, 65},     /* LK */
+       {43088, 66},     /* LT */
+       {47266, 67},     /* LU */
+       {43036, 68},     /* LV */
+       {47149, 69},     /* LY */
+       {47812, 70},     /* MA */
+       {47937, 71},     /* MC */
+       {49029, 72},     /* ME */
+       {43517, 73},     /* MK */
+       {47548, 74},     /* MO */
+       {43917, 75},     /* MT */
+       {46090, 76},     /* MX */
+       {44022, 77},     /* MY */
+       {45434, 78},     /* NG */
+       {49945, 79},     /* NI */
+       {42050, 80},     /* NL */
+       {42108, 81},     /* NO */
+       {45266, 82},     /* NP */
+       {47643, 83},     /* NZ */
+       {48358, 84},     /* OM */
+       {47889, 85},     /* PA */
+       {48752, 86},     /* PE */
+       {45380, 87},     /* PH */
+       {42694, 88},     /* PK */
+       {42149, 89},     /* PL */
+       {50003, 90},     /* PR */
+       {46357, 91},     /* PT */
+       {49623, 92},     /* PY */
+       {49675, 93},     /* QA */
+       {42293, 94},     /* RO */
+       {48621, 95},     /* RS */
+       {42349, 96},     /* RU */
+       {45803, 97},     /* RW */
+       {13253, 98},     /* SA */
+       {42550, 99},     /* SE */
+       {47213, 100},    /* SG */
+       {42948, 101},    /* SI */
+       {42459, 102},    /* SK */
+       {49809, 103},    /* SV */
+       {48677, 104},    /* SY */
+       {42597, 105},    /* TH */
+       {43131, 106},    /* TJ */
+       {48133, 107},    /* TN */
+       {42643, 108},    /* TR */
+       {48896, 109},    /* TT */
+       {41372, 110},    /* TW */
+       {42822, 111},    /* UA */
+       {41620, 112},    /* US */
+       {49509, 113},    /* UY */
+       {44205, 114},    /* UZ */
+       {48443, 115},    /* VE */
+       {43237, 116},    /* VN */
+       {48499, 117},    /* YE */
+       {43548, 118},    /* ZA */
+       {49119, 119}     /* ZW */
 };
 
 
 static const char locale_strings [] = {
 "\0"
-       "d MMMM, yyyy h:mm:ss t\0"
-       "d MMMM, yyyy\0"
-       "d/M/yyyy\0"
-       "h:mm:ss t\0"
-       "h:mm t\0"
+       "dd/MMMM/yyyy\0"
+       "dd/MM/yy\0"
+       "hh:mm:ss tt\0"
+       "hh:mm tt\0"
        "MMMM, yyyy\0"
-       "d MMMM\0"
-       "\xd8\xb5\0"
-       "\xd9\x85\0"
-       "\xd8\xa7\xd9\x84\xd8\xa3\xd8\xad\xd8\xaf\0"
-       "\xd8\xa7\xd9\x84\xd8\xa7\xd8\xab\xd9\x86\xd9\x8a\xd9\x86\0"
-       "\xd8\xa7\xd9\x84\xd8\xab\xd9\x84\xd8\xa7\xd8\xab\xd8\xa7\xd8\xa1\0"
-       "\xd8\xa7\xd9\x84\xd8\xa3\xd8\xb1\xd8\xa8\xd8\xb9\xd8\xa7\xd8\xa1\0"
-       "\xd8\xa7\xd9\x84\xd8\xae\xd9\x85\xd9\x8a\xd8\xb3\0"
-       "\xd8\xa7\xd9\x84\xd8\xac\xd9\x85\xd8\xb9\xd8\xa9\0"
-       "\xd8\xa7\xd9\x84\xd8\xb3\xd8\xa8\xd8\xaa\0"
-       "\xd8\xad\0"
-       "\xd9\x86\0"
-       "\xd8\xab\0"
-       "\xd8\xb1\0"
-       "\xd8\xae\0"
-       "\xd8\xac\0"
-       "\xd8\xb3\0"
-       "\xd9\x8a\xd9\x86\xd8\xa7\xd9\x8a\xd8\xb1\0"
-       "\xd9\x81\xd8\xa8\xd8\xb1\xd8\xa7\xd9\x8a\xd8\xb1\0"
-       "\xd9\x85\xd8\xa7\xd8\xb1\xd8\xb3\0"
-       "\xd8\xa3\xd8\xa8\xd8\xb1\xd9\x8a\xd9\x84\0"
-       "\xd9\x85\xd8\xa7\xd9\x8a\xd9\x88\0"
-       "\xd9\x8a\xd9\x88\xd9\x86\xd9\x8a\xd9\x88\0"
-       "\xd9\x8a\xd9\x88\xd9\x84\xd9\x8a\xd9\x88\0"
-       "\xd8\xa3\xd8\xba\xd8\xb3\xd8\xb7\xd8\xb3\0"
-       "\xd8\xb3\xd8\xa8\xd8\xaa\xd9\x85\xd8\xa8\xd8\xb1\0"
-       "\xd8\xa3\xd9\x83\xd8\xaa\xd9\x88\xd8\xa8\xd8\xb1\0"
-       "\xd9\x86\xd9\x88\xd9\x81\xd9\x85\xd8\xa8\xd8\xb1\0"
-       "\xd8\xaf\xd9\x8a\xd8\xb3\xd9\x85\xd8\xa8\xd8\xb1\0"
-       "\0"
+       "dd MMMM\0"
+       "\xd9\x85\xd8\xad\xd8\xb1\xd9\x85\0"
+       "\xd8\xb5\xd9\x81\xd8\xb1\0"
+       "\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xb9 \xd8\xa7\xd9\x84\xd8\xa3\xd9\x88\xd9\x84\0"
+       "\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xb9 \xd8\xa7\xd9\x84\xd8\xa2\xd8\xae\xd8\xb1\0"
+       "\xd8\xac\xd9\x85\xd8\xa7\xd8\xaf\xd9\x89 \xd8\xa7\xd9\x84\xd8\xa3\xd9\x88\xd9\x84\xd9\x89\0"
+       "\xd8\xac\xd9\x85\xd8\xa7\xd8\xaf\xd9\x89 \xd8\xa7\xd9\x84\xd8\xa2\xd8\xae\xd8\xb1\xd8\xa9\0"
+       "\xd8\xb1\xd8\xac\xd8\xa8\0"
+       "\xd8\xb4\xd8\xb9\xd8\xa8\xd8\xa7\xd9\x86\0"
+       "\xd8\xb1\xd9\x85\xd8\xb6\xd8\xa7\xd9\x86\0"
+       "\xd8\xb4\xd9\x88\xd8\xa7\xd9\x84\0"
+       "\xd8\xb0\xd9\x88 \xd8\xa7\xd9\x84\xd9\x82\xd8\xb9\xd8\xaf\xd8\xa9\0"
+       "\xd8\xb0\xd9\x88 \xd8\xa7\xd9\x84\xd8\xad\xd8\xac\xd8\xa9\0"
+       "1\0"
+       "2\0"
+       "3\0"
+       "4\0"
+       "5\0"
+       "6\0"
+       "7\0"
+       "8\0"
+       "9\0"
+       "10\0"
+       "11\0"
+       "12\0"
        "/\0"
        ":\0"
-       "yy/MM/dd\0"
-       "yyyy MMMM d \0"
+       "dd/MM/yyyy\0"
+       "dddd, dd MMMM, yyyy\0"
        "HH:mm\0"
-       "HH:mm:ss z\0"
-       "dd MMMM yyyy HH:mm:ss\0"
-       "dd MMMM yyyy\0"
-       "dd.M.yyyy '\xd0\xb3.'\0"
        "HH:mm:ss\0"
-       "MMMM yyyy\0"
-       "dd MMMM\0"
-       "AM\0"
-       "PM\0"
+       "dd MMMM yyyy '\xd0\xb3.'\0"
+       "d.M.yyyy '\xd0\xb3.'\0"
+       "HH:mm:ss '\xd1\x87.'\0"
+       "HH:mm '\xd1\x87.'\0"
+       "MMMM yyyy '\xd0\xb3.'\0"
+       "\xd0\xbf\xd1\x80. \xd0\xbe\xd0\xb1.\0"
+       "\xd1\x81\xd0\xbb. \xd0\xbe\xd0\xb1.\0"
        "\xd0\xbd\xd0\xb5\xd0\xb4\xd0\xb5\xd0\xbb\xd1\x8f\0"
        "\xd0\xbf\xd0\xbe\xd0\xbd\xd0\xb5\xd0\xb4\xd0\xb5\xd0\xbb\xd0\xbd\xd0\xb8\xd0\xba\0"
        "\xd0\xb2\xd1\x82\xd0\xbe\xd1\x80\xd0\xbd\xd0\xb8\xd0\xba\0"
@@ -1219,13 +1456,18 @@ static const char locale_strings [] = {
        "\xd1\x87\xd0\xb5\xd1\x82\xd0\xb2\xd1\x8a\xd1\x80\xd1\x82\xd1\x8a\xd0\xba\0"
        "\xd0\xbf\xd0\xb5\xd1\x82\xd1\x8a\xd0\xba\0"
        "\xd1\x81\xd1\x8a\xd0\xb1\xd0\xbe\xd1\x82\xd0\xb0\0"
-       "\xd0\xbd\xd0\xb5\xd0\xb4.\0"
-       "\xd0\xbf\xd0\xbe\xd0\xbd.\0"
-       "\xd0\xb2\xd1\x82.\0"
-       "\xd1\x81\xd1\x80.\0"
-       "\xd1\x87\xd0\xb5\xd1\x82\xd0\xb2.\0"
-       "\xd0\xbf\xd0\xb5\xd1\x82.\0"
-       "\xd1\x81\xd1\x8a\xd0\xb1.\0"
+       "\xd0\xbd\xd0\xb4\0"
+       "\xd0\xbf\xd0\xbd\0"
+       "\xd0\xb2\xd1\x82\0"
+       "\xd1\x81\xd1\x80\0"
+       "\xd1\x87\xd1\x82\0"
+       "\xd0\xbf\xd1\x82\0"
+       "\xd1\x81\xd0\xb1\0"
+       "\xd0\xbd\0"
+       "\xd0\xbf\0"
+       "\xd0\xb2\0"
+       "\xd1\x81\0"
+       "\xd1\x87\0"
        "\xd1\x8f\xd0\xbd\xd1\x83\xd0\xb0\xd1\x80\xd0\xb8\0"
        "\xd1\x84\xd0\xb5\xd0\xb2\xd1\x80\xd1\x83\xd0\xb0\xd1\x80\xd0\xb8\0"
        "\xd0\xbc\xd0\xb0\xd1\x80\xd1\x82\0"
@@ -1239,18 +1481,26 @@ static const char locale_strings [] = {
        "\xd0\xbd\xd0\xbe\xd0\xb5\xd0\xbc\xd0\xb2\xd1\x80\xd0\xb8\0"
        "\xd0\xb4\xd0\xb5\xd0\xba\xd0\xb5\xd0\xbc\xd0\xb2\xd1\x80\xd0\xb8\0"
        "\xd1\x8f\xd0\xbd.\0"
-       "\xd1\x84\xd0\xb5\xd0\xb2.\0"
+       "\xd1\x84\xd0\xb5\xd0\xb2\xd1\x80.\0"
        "\xd0\xb0\xd0\xbf\xd1\x80.\0"
        "\xd0\xb0\xd0\xb2\xd0\xb3.\0"
-       "\xd1\x81\xd0\xb5\xd0\xbf.\0"
+       "\xd1\x81\xd0\xb5\xd0\xbf\xd1\x82.\0"
        "\xd0\xbe\xd0\xba\xd1\x82.\0"
        "\xd0\xbd\xd0\xbe\xd0\xb5\xd0\xbc.\0"
        "\xd0\xb4\xd0\xb5\xd0\xba.\0"
        ".\0"
-       "dd.MM.yy\0"
-       "d MMMM yyyy HH:mm:ss z\0"
-       "d MMMM yyyy\0"
-       "dd/MM/yy\0"
+       "dd.M.yyyy '\xd0\xb3.'\0"
+       "d.MM.yyyy '\xd0\xb3.'\0"
+       "dd.MM.yyyy '\xd0\xb3.'\0"
+       "d MMMM yyyy '\xd0\xb3.'\0"
+       "dddd, dd MMMM yyyy '\xd0\xb3.'\0"
+       "dddd, d MMMM yyyy '\xd0\xb3.'\0"
+       "H:mm '\xd1\x87.'\0"
+       "H:mm:ss '\xd1\x87.'\0"
+       "dddd, d' / 'MMMM' / 'yyyy\0"
+       "MMMM' / 'yyyy\0"
+       "a.m.\0"
+       "p.m.\0"
        "diumenge\0"
        "dilluns\0"
        "dimarts\0"
@@ -1258,13 +1508,20 @@ static const char locale_strings [] = {
        "dijous\0"
        "divendres\0"
        "dissabte\0"
-       "dg.\0"
-       "dl.\0"
-       "dt.\0"
-       "dc.\0"
-       "dj.\0"
-       "dv.\0"
-       "ds.\0"
+       "dg\0"
+       "dl\0"
+       "dt\0"
+       "dc\0"
+       "dj\0"
+       "dv\0"
+       "ds\0"
+       "g\0"
+       "l\0"
+       "t\0"
+       "c\0"
+       "j\0"
+       "v\0"
+       "s\0"
        "gener\0"
        "febrer\0"
        "mar\xc3\xa7\0"
@@ -1277,8 +1534,20 @@ static const char locale_strings [] = {
        "octubre\0"
        "novembre\0"
        "desembre\0"
+       "de gener\0"
+       "de febrer\0"
+       "de mar\xc3\xa7\0"
+       "d\xe2\x80\x99\x61\x62ril\0"
+       "de maig\0"
+       "de juny\0"
+       "de juliol\0"
+       "d\xe2\x80\x99\x61gost\0"
+       "de setembre\0"
+       "d\xe2\x80\x99octubre\0"
+       "de novembre\0"
+       "de desembre\0"
        "gen.\0"
-       "feb.\0"
+       "febr.\0"
        "abr.\0"
        "jul.\0"
        "ag.\0"
@@ -1286,9 +1555,21 @@ static const char locale_strings [] = {
        "oct.\0"
        "nov.\0"
        "des.\0"
-       "yyyy MMMM d  HH:mm:ss z\0"
-       "yyyy MMMM\0"
-       "MMMM dd\0"
+       "yyyy-MM-dd\0"
+       "d/MM/yy\0"
+       "d/M/yy\0"
+       "dd-MM-yy\0"
+       "dd.MM.yy\0"
+       "d'/'MMMM'/'yyyy\0"
+       "d' 'MMMM' 'yyyy\0"
+       "H:mm\0"
+       "HH'H'mm'''\0"
+       "H:mm:ss\0"
+       "HH'H'mm'''ss''''\0"
+       "yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5'\0"
+       "yyyy/M/d\0"
+       "yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'\0"
+       "M'\xe6\x9c\x88'd'\xe6\x97\xa5'\0"
        "\xe4\xb8\x8a\xe5\x8d\x88\0"
        "\xe4\xb8\x8b\xe5\x8d\x88\0"
        "\xe6\x98\x9f\xe6\x9c\x9f\xe6\x97\xa5\0"
@@ -1298,6 +1579,13 @@ static const char locale_strings [] = {
        "\xe6\x98\x9f\xe6\x9c\x9f\xe5\x9b\x9b\0"
        "\xe6\x98\x9f\xe6\x9c\x9f\xe4\xba\x94\0"
        "\xe6\x98\x9f\xe6\x9c\x9f\xe5\x85\xad\0"
+       "\xe5\x91\xa8\xe6\x97\xa5\0"
+       "\xe5\x91\xa8\xe4\xb8\x80\0"
+       "\xe5\x91\xa8\xe4\xba\x8c\0"
+       "\xe5\x91\xa8\xe4\xb8\x89\0"
+       "\xe5\x91\xa8\xe5\x9b\x9b\0"
+       "\xe5\x91\xa8\xe4\xba\x94\0"
+       "\xe5\x91\xa8\xe5\x85\xad\0"
        "\xe6\x97\xa5\0"
        "\xe4\xb8\x80\0"
        "\xe4\xba\x8c\0"
@@ -1317,12 +1605,35 @@ static const char locale_strings [] = {
        "\xe5\x8d\x81\xe6\x9c\x88\0"
        "\xe5\x8d\x81\xe4\xb8\x80\xe6\x9c\x88\0"
        "\xe5\x8d\x81\xe4\xba\x8c\xe6\x9c\x88\0"
-       "d. MMMM yyyy H:mm:ss z\0"
+       "1\xe6\x9c\x88\0"
+       "2\xe6\x9c\x88\0"
+       "3\xe6\x9c\x88\0"
+       "4\xe6\x9c\x88\0"
+       "5\xe6\x9c\x88\0"
+       "6\xe6\x9c\x88\0"
+       "7\xe6\x9c\x88\0"
+       "8\xe6\x9c\x88\0"
+       "9\xe6\x9c\x88\0"
+       "10\xe6\x9c\x88\0"
+       "11\xe6\x9c\x88\0"
+       "12\xe6\x9c\x88\0"
+       "yyyy-M-d\0"
+       "yyyy.M.d\0"
+       "yyyy/MM/dd\0"
+       "yyyy.MM.dd\0"
+       "yy-M-d\0"
+       "yy/M/d\0"
+       "yy.M.d\0"
+       "yy/MM/dd\0"
+       "yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5',dddd\0"
+       "dddd,yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5'\0"
+       "tt h:mm\0"
+       "tt hh:mm\0"
+       "tt h:mm:ss\0"
+       "tt hh:mm:ss\0"
        "d. MMMM yyyy\0"
-       "d.M.yy\0"
-       "H:mm:ss z\0"
-       "H:mm\0"
-       "d. MMMM\0"
+       "d.M.yyyy\0"
+       "MMMM yyyy\0"
        "dop.\0"
        "odp.\0"
        "ned\xc4\x9ble\0"
@@ -1339,6 +1650,11 @@ static const char locale_strings [] = {
        "\xc4\x8dt\0"
        "p\xc3\xa1\0"
        "so\0"
+       "N\0"
+       "P\0"
+       "\xc3\x9a\0"
+       "S\0"
+       "\xc4\x8c\0"
        "leden\0"
        "\xc3\xbanor\0"
        "b\xc5\x99\x65zen\0"
@@ -1351,22 +1667,38 @@ static const char locale_strings [] = {
        "\xc5\x99\xc3\xadjen\0"
        "listopad\0"
        "prosinec\0"
-       "I\0"
-       "II\0"
-       "III\0"
-       "IV\0"
-       "V\0"
-       "VI\0"
-       "VII\0"
-       "VIII\0"
-       "IX\0"
-       "X\0"
-       "XI\0"
-       "XII\0"
-       "d. MMM yyyy HH:mm:ss\0"
-       "d. MMM yyyy\0"
+       "ledna\0"
+       "\xc3\xbanora\0"
+       "b\xc5\x99\x65zna\0"
+       "dubna\0"
+       "kv\xc4\x9btna\0"
+       "\xc4\x8d\x65rvna\0"
+       "\xc4\x8d\x65rvence\0"
+       "srpna\0"
+       "\xc5\x99\xc3\xadjna\0"
+       "listopadu\0"
+       "prosince\0"
+       "1.\0"
+       "2.\0"
+       "3.\0"
+       "4.\0"
+       "5.\0"
+       "6.\0"
+       "7.\0"
+       "8.\0"
+       "9.\0"
+       "10.\0"
+       "11.\0"
+       "12.\0"
+       "d-M-yy\0"
+       "h.mm tt\0"
+       "H.mm\0"
+       "h.mm.ss tt\0"
+       "H.mm.ss\0"
        "dd-MM-yyyy\0"
-       "dd. MMMM\0"
+       "d. MMMM\0"
+       "f.m.\0"
+       "e.m.\0"
        "s\xc3\xb8ndag\0"
        "mandag\0"
        "tirsdag\0"
@@ -1381,6 +1713,11 @@ static const char locale_strings [] = {
        "tor\0"
        "fre\0"
        "l\xc3\xb8r\0"
+       "M\0"
+       "T\0"
+       "O\0"
+       "F\0"
+       "L\0"
        "januar\0"
        "februar\0"
        "marts\0"
@@ -1405,8 +1742,9 @@ static const char locale_strings [] = {
        "nov\0"
        "dec\0"
        "-\0"
-       "dd-MM-yy\0"
-       "d. MMMM yyyy HH:mm:ss\0"
+       "yyyy MM dd\0"
+       "dd. MMMM yyyy\0"
+       "dddd, d. MMMM yyyy\0"
        "dd.MM.yyyy\0"
        "vorm.\0"
        "nachm.\0"
@@ -1424,6 +1762,7 @@ static const char locale_strings [] = {
        "Do\0"
        "Fr\0"
        "Sa\0"
+       "D\0"
        "Januar\0"
        "Februar\0"
        "M\xc3\xa4rz\0"
@@ -1438,7 +1777,7 @@ static const char locale_strings [] = {
        "Dezember\0"
        "Jan\0"
        "Feb\0"
-       "Mrz\0"
+       "M\xc3\xa4r\0"
        "Apr\0"
        "Jun\0"
        "Jul\0"
@@ -1447,10 +1786,20 @@ static const char locale_strings [] = {
        "Okt\0"
        "Nov\0"
        "Dez\0"
-       "dd MMMM yyyy h:mm:ss tt\0"
+       "dd.MMM.yyyy\0"
+       "d.MM.yy\0"
+       "d.M.yy\0"
+       "d. MMM yyyy\0"
+       "H.mm' Uhr'\0"
+       "H:mm:ss' Uhr'\0"
+       "HH:mm:ss' Uhr'\0"
+       "HHmmss\0"
+       "dddd, d MMMM yyyy\0"
+       "d/M/yyyy\0"
        "h:mm:ss tt\0"
-       "\xce\xa0\xce\x9c\0"
-       "\xce\x9c\xce\x9c\0"
+       "h:mm tt\0"
+       "\xcf\x80.\xce\xbc.\0"
+       "\xce\xbc.\xce\xbc.\0"
        "\xce\x9a\xcf\x85\xcf\x81\xce\xb9\xce\xb1\xce\xba\xce\xae\0"
        "\xce\x94\xce\xb5\xcf\x85\xcf\x84\xce\xad\xcf\x81\xce\xb1\0"
        "\xce\xa4\xcf\x81\xce\xaf\xcf\x84\xce\xb7\0"
@@ -1460,11 +1809,16 @@ static const char locale_strings [] = {
        "\xce\xa3\xce\xac\xce\xb2\xce\xb2\xce\xb1\xcf\x84\xce\xbf\0"
        "\xce\x9a\xcf\x85\xcf\x81\0"
        "\xce\x94\xce\xb5\xcf\x85\0"
-       "\xce\xa4\xcf\x81\xce\xb9\0"
+       "\xce\xa4\xcf\x81\xce\xaf\0"
        "\xce\xa4\xce\xb5\xcf\x84\0"
-       "\xce\xa0\xce\xb5\xce\xbc\0"
+       "\xce\xa0\xce\xad\xce\xbc\0"
        "\xce\xa0\xce\xb1\xcf\x81\0"
-       "\xce\xa3\xce\xb1\xce\xb2\0"
+       "\xce\xa3\xce\xac\xce\xb2\0"
+       "\xce\x9a\0"
+       "\xce\x94\0"
+       "\xce\xa4\0"
+       "\xce\xa0\0"
+       "\xce\xa3\0"
        "\xce\x99\xce\xb1\xce\xbd\xce\xbf\xcf\x85\xce\xac\xcf\x81\xce\xb9\xce\xbf\xcf\x82\0"
        "\xce\xa6\xce\xb5\xce\xb2\xcf\x81\xce\xbf\xcf\x85\xce\xac\xcf\x81\xce\xb9\xce\xbf\xcf\x82\0"
        "\xce\x9c\xce\xac\xcf\x81\xcf\x84\xce\xb9\xce\xbf\xcf\x82\0"
@@ -1477,25 +1831,37 @@ static const char locale_strings [] = {
        "\xce\x9f\xce\xba\xcf\x84\xcf\x8e\xce\xb2\xcf\x81\xce\xb9\xce\xbf\xcf\x82\0"
        "\xce\x9d\xce\xbf\xce\xad\xce\xbc\xce\xb2\xcf\x81\xce\xb9\xce\xbf\xcf\x82\0"
        "\xce\x94\xce\xb5\xce\xba\xce\xad\xce\xbc\xce\xb2\xcf\x81\xce\xb9\xce\xbf\xcf\x82\0"
+       "\xce\x99\xce\xb1\xce\xbd\xce\xbf\xcf\x85\xce\xb1\xcf\x81\xce\xaf\xce\xbf\xcf\x85\0"
+       "\xce\xa6\xce\xb5\xce\xb2\xcf\x81\xce\xbf\xcf\x85\xce\xb1\xcf\x81\xce\xaf\xce\xbf\xcf\x85\0"
+       "\xce\x9c\xce\xb1\xcf\x81\xcf\x84\xce\xaf\xce\xbf\xcf\x85\0"
+       "\xce\x91\xcf\x80\xcf\x81\xce\xb9\xce\xbb\xce\xaf\xce\xbf\xcf\x85\0"
+       "\xce\x9c\xce\xb1\xce\x90\xce\xbf\xcf\x85\0"
+       "\xce\x99\xce\xbf\xcf\x85\xce\xbd\xce\xaf\xce\xbf\xcf\x85\0"
+       "\xce\x99\xce\xbf\xcf\x85\xce\xbb\xce\xaf\xce\xbf\xcf\x85\0"
+       "\xce\x91\xcf\x85\xce\xb3\xce\xbf\xcf\x8d\xcf\x83\xcf\x84\xce\xbf\xcf\x85\0"
+       "\xce\xa3\xce\xb5\xcf\x80\xcf\x84\xce\xb5\xce\xbc\xce\xb2\xcf\x81\xce\xaf\xce\xbf\xcf\x85\0"
+       "\xce\x9f\xce\xba\xcf\x84\xcf\x89\xce\xb2\xcf\x81\xce\xaf\xce\xbf\xcf\x85\0"
+       "\xce\x9d\xce\xbf\xce\xb5\xce\xbc\xce\xb2\xcf\x81\xce\xaf\xce\xbf\xcf\x85\0"
+       "\xce\x94\xce\xb5\xce\xba\xce\xb5\xce\xbc\xce\xb2\xcf\x81\xce\xaf\xce\xbf\xcf\x85\0"
        "\xce\x99\xce\xb1\xce\xbd\0"
        "\xce\xa6\xce\xb5\xce\xb2\0"
-       "\xce\x9c\xce\xb1\xcf\x81\0"
+       "\xce\x9c\xce\xac\xcf\x81\0"
        "\xce\x91\xcf\x80\xcf\x81\0"
-       "\xce\x9c\xce\xb1\xcf\x8a\0"
-       "\xce\x99\xce\xbf\xcf\x85\xce\xbd\0"
-       "\xce\x99\xce\xbf\xcf\x85\xce\xbb\0"
+       "\xce\x9c\xce\xac\xce\xb9\0"
+       "\xce\x99\xce\xbf\xcf\x8d\xce\xbd\0"
+       "\xce\x99\xce\xbf\xcf\x8d\xce\xbb\0"
        "\xce\x91\xcf\x85\xce\xb3\0"
        "\xce\xa3\xce\xb5\xcf\x80\0"
        "\xce\x9f\xce\xba\xcf\x84\0"
-       "\xce\x9d\xce\xbf\xce\xb5\0"
+       "\xce\x9d\xce\xbf\xce\xad\0"
        "\xce\x94\xce\xb5\xce\xba\0"
-       "dd/MM/yyyy\0"
-       "h:mm:ss t z\0"
-       "dddd, MMMM dd, yyyy h:mm:ss tt\0"
+       "dd/MMM/yyyy\0"
+       "d MMMM yyyy\0"
        "dddd, MMMM dd, yyyy\0"
-       "M/d/yy\0"
-       "h:mm tt\0"
-       "MMMM d\0"
+       "M/d/yyyy\0"
+       "MMMM dd\0"
+       "AM\0"
+       "PM\0"
        "Sunday\0"
        "Monday\0"
        "Tuesday\0"
@@ -1510,6 +1876,7 @@ static const char locale_strings [] = {
        "Thu\0"
        "Fri\0"
        "Sat\0"
+       "W\0"
        "January\0"
        "February\0"
        "March\0"
@@ -1521,19 +1888,14 @@ static const char locale_strings [] = {
        "Mar\0"
        "Oct\0"
        "Dec\0"
-       "MMMM dd, yyyy\0"
-       "dddd, dd MMMM, yyyy\0"
-       "dd, MMMM, yyyy\0"
-       "hh:mm tt\0"
-       "hh:mm:ss tt\0"
-       "H:mm:ss\0"
-       "d' de 'MMMM' de 'yyyy hh:mm:ss tt\0"
-       "d' de 'MMMM' de 'yyyy\0"
+       "M/d/yy\0"
+       "MM/dd/yy\0"
        "MM/dd/yyyy\0"
-       "MMMM\0"
-       "d' de 'MMMM\0"
-       "a.m.\0"
-       "p.m.\0"
+       "dd-MMM-yy\0"
+       "MMMM dd, yyyy\0"
+       "dd MMMM, yyyy\0"
+       "dddd, dd' de 'MMMM' de 'yyyy\0"
+       "MMMM' de 'yyyy\0"
        "domingo\0"
        "lunes\0"
        "martes\0"
@@ -1547,6 +1909,9 @@ static const char locale_strings [] = {
        "jue\0"
        "vie\0"
        "s\xc3\xa1\x62\0"
+       "X\0"
+       "J\0"
+       "V\0"
        "enero\0"
        "febrero\0"
        "marzo\0"
@@ -1559,23 +1924,22 @@ static const char locale_strings [] = {
        "diciembre\0"
        "ene\0"
        "abr\0"
-       "may\0"
        "ago\0"
        "oct\0"
        "dic\0"
-       "d/MM/yy\0"
-       "d. MMMM'ta 'yyyy H:mm:ss\0"
+       "dddd d' de 'MMMM' de 'yyyy\0"
+       "d' de 'MMMM' de 'yyyy\0"
        "d. MMMM'ta 'yyyy\0"
-       "d.M.yyyy\0"
-       "MMMM'ta'yyyy\0"
        "d. MMMM'ta'\0"
-       "sunnuntai\0"
-       "maanantai\0"
-       "tiistai\0"
-       "keskiviikko\0"
-       "torstai\0"
-       "perjantai\0"
-       "lauantai\0"
+       "ap.\0"
+       "ip.\0"
+       "sunnuntaina\0"
+       "maanantaina\0"
+       "tiistaina\0"
+       "keskiviikkona\0"
+       "torstaina\0"
+       "perjantaina\0"
+       "lauantaina\0"
        "su\0"
        "ma\0"
        "ti\0"
@@ -1583,6 +1947,7 @@ static const char locale_strings [] = {
        "to\0"
        "pe\0"
        "la\0"
+       "K\0"
        "tammikuu\0"
        "helmikuu\0"
        "maaliskuu\0"
@@ -1595,6 +1960,18 @@ static const char locale_strings [] = {
        "lokakuu\0"
        "marraskuu\0"
        "joulukuu\0"
+       "tammikuuta\0"
+       "helmikuuta\0"
+       "maaliskuuta\0"
+       "huhtikuuta\0"
+       "toukokuuta\0"
+       "kes\xc3\xa4kuuta\0"
+       "hein\xc3\xa4kuuta\0"
+       "elokuuta\0"
+       "syyskuuta\0"
+       "lokakuuta\0"
+       "marraskuuta\0"
+       "joulukuuta\0"
        "tammi\0"
        "helmi\0"
        "maalis\0"
@@ -1607,8 +1984,9 @@ static const char locale_strings [] = {
        "loka\0"
        "marras\0"
        "joulu\0"
-       "dddd d MMMM yyyy HH:mm:ss\0"
+       "dd. MMMM'ta 'yyyy\0"
        "dddd d MMMM yyyy\0"
+       "d MMMM\0"
        "dimanche\0"
        "lundi\0"
        "mardi\0"
@@ -1640,14 +2018,26 @@ static const char locale_strings [] = {
        "juil.\0"
        "sept.\0"
        "d\xc3\xa9\x63.\0"
-       "d/MM/yyyy\0"
-       "HH:mm:ss d MMMM yyyy\0"
+       "d MMM yy\0"
+       "HH.mm\0"
+       "HH' h 'mm\0"
+       "HH'h'mm\0"
+       "dddd dd MMMM yyyy\0"
+       "\xd7\x9c\xd7\xa4\xd7\xa0\xd7\x94\xd7\xb4\xd7\xa6\0"
+       "\xd7\x90\xd7\x97\xd7\x94\xd7\xb4\xd7\xa6\0"
        "\xd7\x99\xd7\x95\xd7\x9d \xd7\xa8\xd7\x90\xd7\xa9\xd7\x95\xd7\x9f\0"
        "\xd7\x99\xd7\x95\xd7\x9d \xd7\xa9\xd7\xa0\xd7\x99\0"
        "\xd7\x99\xd7\x95\xd7\x9d \xd7\xa9\xd7\x9c\xd7\x99\xd7\xa9\xd7\x99\0"
        "\xd7\x99\xd7\x95\xd7\x9d \xd7\xa8\xd7\x91\xd7\x99\xd7\xa2\xd7\x99\0"
        "\xd7\x99\xd7\x95\xd7\x9d \xd7\x97\xd7\x9e\xd7\x99\xd7\xa9\xd7\x99\0"
        "\xd7\x99\xd7\x95\xd7\x9d \xd7\xa9\xd7\x99\xd7\xa9\xd7\x99\0"
+       "\xd7\x99\xd7\x95\xd7\x9d \xd7\xa9\xd7\x91\xd7\xaa\0"
+       "\xd7\x99\xd7\x95\xd7\x9d \xd7\x90\xd7\xb3\0"
+       "\xd7\x99\xd7\x95\xd7\x9d \xd7\x91\xd7\xb3\0"
+       "\xd7\x99\xd7\x95\xd7\x9d \xd7\x92\xd7\xb3\0"
+       "\xd7\x99\xd7\x95\xd7\x9d \xd7\x93\xd7\xb3\0"
+       "\xd7\x99\xd7\x95\xd7\x9d \xd7\x94\xd7\xb3\0"
+       "\xd7\x99\xd7\x95\xd7\x9d \xd7\x95\xd7\xb3\0"
        "\xd7\xa9\xd7\x91\xd7\xaa\0"
        "\xd7\x90\0"
        "\xd7\x91\0"
@@ -1668,23 +2058,28 @@ static const char locale_strings [] = {
        "\xd7\x90\xd7\x95\xd7\xa7\xd7\x98\xd7\x95\xd7\x91\xd7\xa8\0"
        "\xd7\xa0\xd7\x95\xd7\x91\xd7\x9e\xd7\x91\xd7\xa8\0"
        "\xd7\x93\xd7\xa6\xd7\x9e\xd7\x91\xd7\xa8\0"
-       "\xd7\x99\xd7\xa0\xd7\x95\0"
-       "\xd7\xa4\xd7\x91\xd7\xa8\0"
-       "\xd7\x90\xd7\xa4\xd7\xa8\0"
-       "\xd7\x99\xd7\x95\xd7\xa0\0"
-       "\xd7\x99\xd7\x95\xd7\x9c\0"
-       "\xd7\x90\xd7\x95\xd7\x92\0"
-       "\xd7\xa1\xd7\xa4\xd7\x98\0"
-       "\xd7\x90\xd7\x95\xd7\xa7\0"
-       "\xd7\xa0\xd7\x95\xd7\x91\0"
-       "\xd7\x93\xd7\xa6\xd7\x9e\0"
-       "yyyy. MMMM d. H:mm:ss\0"
+       "\xd7\x99\xd7\xa0\xd7\x95\xd7\xb3\0"
+       "\xd7\xa4\xd7\x91\xd7\xa8\xd7\xb3\0"
+       "\xd7\x90\xd7\xa4\xd7\xa8\xd7\xb3\0"
+       "\xd7\x99\xd7\x95\xd7\xa0\xd7\xb3\0"
+       "\xd7\x99\xd7\x95\xd7\x9c\xd7\xb3\0"
+       "\xd7\x90\xd7\x95\xd7\x92\xd7\xb3\0"
+       "\xd7\xa1\xd7\xa4\xd7\x98\xd7\xb3\0"
+       "\xd7\x90\xd7\x95\xd7\xa7\xd7\xb3\0"
+       "\xd7\xa0\xd7\x95\xd7\x91\xd7\xb3\0"
+       "\xd7\x93\xd7\xa6\xd7\x9e\xd7\xb3\0"
+       "dd MMMM yyyy\0"
+       "dd-MMMM-yyyy\0"
+       "dd '\xd7\x91'MMMM yyyy\0"
+       "dd MMM yy\0"
+       "dddd dd '\xd7\x91'MMMM yyyy\0"
+       "ddd dd '\xd7\x91'MMMM yyyy\0"
        "yyyy. MMMM d.\0"
-       "yyyy. MM. dd.\0"
+       "yyyy.MM.dd.\0"
        "yyyy. MMMM\0"
        "MMMM d.\0"
-       "DE\0"
-       "DU\0"
+       "de.\0"
+       "du.\0"
        "vas\xc3\xa1rnap\0"
        "h\xc3\xa9tf\xc5\x91\0"
        "kedd\0"
@@ -1693,11 +2088,10 @@ static const char locale_strings [] = {
        "p\xc3\xa9ntek\0"
        "szombat\0"
        "H\0"
-       "K\0"
        "Sze\0"
        "Cs\0"
-       "P\0"
        "Szo\0"
+       "Sz\0"
        "janu\xc3\xa1r\0"
        "febru\xc3\xa1r\0"
        "m\xc3\xa1rcius\0"
@@ -1709,7 +2103,6 @@ static const char locale_strings [] = {
        "szeptember\0"
        "okt\xc3\xb3\x62\x65r\0"
        "jan.\0"
-       "febr.\0"
        "m\xc3\xa1rc.\0"
        "\xc3\xa1pr.\0"
        "m\xc3\xa1j.\0"
@@ -1719,8 +2112,10 @@ static const char locale_strings [] = {
        "szept.\0"
        "okt.\0"
        "dec.\0"
-       ". \0"
-       "yyyy.MM.dd.\0"
+       "yyyy. MM. dd.\0"
+       "yy-MM-dd\0"
+       "f.h.\0"
+       "e.h.\0"
        "sunnudagur\0"
        "m\xc3\xa1nudagur\0"
        "\xc3\xberi\xc3\xb0judagur\0"
@@ -1735,6 +2130,9 @@ static const char locale_strings [] = {
        "fim\0"
        "f\xc3\xb6s\0"
        "lau\0"
+       "m\0"
+       "\xc3\xbe\0"
+       "f\0"
        "jan\xc3\xba\x61r\0"
        "febr\xc3\xba\x61r\0"
        "apr\xc3\xadl\0"
@@ -1749,7 +2147,9 @@ static const char locale_strings [] = {
        "\xc3\xa1g\xc3\xba\0"
        "n\xc3\xb3v\0"
        "des\0"
-       "dd MMMM yyyy HH:mm:ss z\0"
+       "d. M. yyyy.\0"
+       "d. M. '''yy.\0"
+       "yy MM dd\0"
        "m.\0"
        "p.\0"
        "domenica\0"
@@ -1763,6 +2163,19 @@ static const char locale_strings [] = {
        "gio\0"
        "ven\0"
        "sab\0"
+       "G\0"
+       "Gennaio\0"
+       "Febbraio\0"
+       "Marzo\0"
+       "Aprile\0"
+       "Maggio\0"
+       "Giugno\0"
+       "Luglio\0"
+       "Agosto\0"
+       "Settembre\0"
+       "Ottobre\0"
+       "Novembre\0"
+       "Dicembre\0"
        "gennaio\0"
        "febbraio\0"
        "aprile\0"
@@ -1778,11 +2191,9 @@ static const char locale_strings [] = {
        "lug\0"
        "set\0"
        "ott\0"
-       "yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5' H:mm:ss\0"
-       "yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5'\0"
-       "yyyy/MM/dd\0"
-       "yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'\0"
-       "M'\xe6\x9c\x88'd'\xe6\x97\xa5'\0"
+       "dd.M.yy\0"
+       "d-MMM-yy\0"
+       "HH.mm.ss\0"
        "\xe5\x8d\x88\xe5\x89\x8d\0"
        "\xe5\x8d\x88\xe5\xbe\x8c\0"
        "\xe6\x97\xa5\xe6\x9b\x9c\xe6\x97\xa5\0"
@@ -1798,47 +2209,13 @@ static const char locale_strings [] = {
        "\xe6\x9c\xa8\0"
        "\xe9\x87\x91\0"
        "\xe5\x9c\x9f\0"
-       "1\xe6\x9c\x88\0"
-       "2\xe6\x9c\x88\0"
-       "3\xe6\x9c\x88\0"
-       "4\xe6\x9c\x88\0"
-       "5\xe6\x9c\x88\0"
-       "6\xe6\x9c\x88\0"
-       "7\xe6\x9c\x88\0"
-       "8\xe6\x9c\x88\0"
-       "9\xe6\x9c\x88\0"
-       "10\xe6\x9c\x88\0"
-       "11\xe6\x9c\x88\0"
-       "12\xe6\x9c\x88\0"
-       "1\0"
-       "2\0"
-       "3\0"
-       "4\0"
-       "5\0"
-       "6\0"
-       "7\0"
-       "8\0"
-       "9\0"
-       "10\0"
-       "11\0"
-       "12\0"
-       "yy/M/d\0"
-       "yyyy/M/d\0"
        "yy/MM/dd' ('ddd')'\0"
        "yy/M/d' ('ddd')'\0"
-       "yyyy/M/d' ('ddd')'\0"
+       "yyyy/MM/dd' ('ddd')'\0"
        "yyyy'\xe5\xb9\xb4'MM'\xe6\x9c\x88'dd'\xe6\x97\xa5'\0"
        "yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5' dddd\0"
        "yyyy'\xe5\xb9\xb4'MM'\xe6\x9c\x88'dd'\xe6\x97\xa5' dddd\0"
-       "tt h:mm\0"
-       "tt hh:mm\0"
-       "tt h:mm:ss\0"
-       "tt hh:mm:ss\0"
-       "yyyy'\xeb\x85\x84' M'\xec\x9b\x94' d'\xec\x9d\xbc' EE t hh'\xec\x8b\x9c' mm'\xeb\xb6\x84' ss'\xec\xb4\x88'\0"
-       "yyyy'\xeb\x85\x84' M'\xec\x9b\x94' d'\xec\x9d\xbc' EE\0"
-       "yy-MM-dd\0"
-       "t hh'\xec\x8b\x9c' mm'\xeb\xb6\x84' ss'\xec\xb4\x88'\0"
-       "t hh'\xec\x8b\x9c' mm'\xeb\xb6\x84'\0"
+       "yyyy'\xeb\x85\x84' M'\xec\x9b\x94' d'\xec\x9d\xbc' dddd\0"
        "yyyy'\xeb\x85\x84' M'\xec\x9b\x94'\0"
        "M'\xec\x9b\x94' d'\xec\x9d\xbc'\0"
        "\xec\x98\xa4\xec\xa0\x84\0"
@@ -1869,8 +2246,12 @@ static const char locale_strings [] = {
        "10\xec\x9b\x94\0"
        "11\xec\x9b\x94\0"
        "12\xec\x9b\x94\0"
-       "d MMMM yyyy H:mm:ss z\0"
-       "d-M-yy\0"
+       "yyyy'\xeb\x85\x84' M'\xec\x9b\x94' d'\xec\x9d\xbc'\0"
+       "yy'\xeb\x85\x84' M'\xec\x9b\x94' d'\xec\x9d\xbc' dddd\0"
+       "yy'\xeb\x85\x84' M'\xec\x9b\x94' d'\xec\x9d\xbc'\0"
+       "yyyy'\xeb\x85\x84' MM'\xec\x9b\x94' dd'\xec\x9d\xbc' dddd\0"
+       "yyyy'\xeb\x85\x84' MM'\xec\x9b\x94' dd'\xec\x9d\xbc'\0"
+       "d-M-yyyy\0"
        "zondag\0"
        "maandag\0"
        "dinsdag\0"
@@ -1884,33 +2265,41 @@ static const char locale_strings [] = {
        "do\0"
        "vr\0"
        "za\0"
+       "Z\0"
        "januari\0"
        "februari\0"
        "maart\0"
        "mei\0"
        "augustus\0"
        "mrt\0"
-       "d. MMMM yyyy HH.mm.ss z\0"
-       "HH.mm.ss z\0"
-       "HH.mm\0"
-       "s\xc3\xb8\0"
-       "on\0"
-       "fr\0"
-       "l\xc3\xb8\0"
-       "d MMMM yyyy HH:mm:ss\0"
-       "yyyy-MM-dd\0"
+       "HH.mm' uur'\0"
+       "HH:mm' uur'\0"
+       "HH.mm.ss' uur'\0"
+       "HH:mm:ss' uur'\0"
+       "s\xc3\xb8.\0"
+       "ma.\0"
+       "ti.\0"
+       "on.\0"
+       "to.\0"
+       "fr.\0"
+       "l\xc3\xb8.\0"
+       "'kl 'HH.mm\0"
+       "'kl 'HH.mm.ss\0"
        "niedziela\0"
        "poniedzia\xc5\x82\x65k\0"
        "wtorek\0"
        "\xc5\x9broda\0"
        "czwartek\0"
        "pi\xc4\x85tek\0"
-       "N\0"
-       "Pn\0"
-       "Wt\0"
-       "\xc5\x9ar\0"
-       "Cz\0"
-       "Pt\0"
+       "niedz.\0"
+       "pon.\0"
+       "wt.\0"
+       "\xc5\x9br.\0"
+       "czw.\0"
+       "pt.\0"
+       "sob.\0"
+       "\xc5\x9a\0"
+       "C\0"
        "stycze\xc5\x84\0"
        "luty\0"
        "marzec\0"
@@ -1921,6 +2310,18 @@ static const char locale_strings [] = {
        "wrzesie\xc5\x84\0"
        "pa\xc5\xba\x64ziernik\0"
        "grudzie\xc5\x84\0"
+       "stycznia\0"
+       "lutego\0"
+       "marca\0"
+       "kwietnia\0"
+       "maja\0"
+       "czerwca\0"
+       "lipca\0"
+       "sierpnia\0"
+       "wrze\xc5\x9bnia\0"
+       "pa\xc5\xba\x64ziernika\0"
+       "listopada\0"
+       "grudnia\0"
        "sty\0"
        "lut\0"
        "kwi\0"
@@ -1931,7 +2332,8 @@ static const char locale_strings [] = {
        "pa\xc5\xba\0"
        "lis\0"
        "gru\0"
-       "d' de 'MMMM' de 'yyyy HH:mm:ss z\0"
+       "dddd, d' de 'MMMM' de 'yyyy\0"
+       "dd' de 'MMMM\0"
        "segunda-feira\0"
        "ter\xc3\xa7\x61-feira\0"
        "quarta-feira\0"
@@ -1942,6 +2344,7 @@ static const char locale_strings [] = {
        "qua\0"
        "qui\0"
        "sex\0"
+       "Q\0"
        "janeiro\0"
        "fevereiro\0"
        "mar\xc3\xa7o\0"
@@ -1955,18 +2358,60 @@ static const char locale_strings [] = {
        "fev\0"
        "out\0"
        "dez\0"
+       "am\0"
+       "sm\0"
+       "dumengia\0"
+       "glindesdi\0"
+       "mesemna\0"
+       "gievgia\0"
+       "venderdi\0"
+       "sonda\0"
+       "du\0"
+       "gli\0"
+       "me\0"
+       "gie\0"
+       "ve\0"
+       "schaner\0"
+       "favrer\0"
+       "avrigl\0"
+       "matg\0"
+       "zercladur\0"
+       "fanadur\0"
+       "avust\0"
+       "settember\0"
+       "october\0"
+       "schan.\0"
+       "favr.\0"
+       "zercl.\0"
+       "fan.\0"
+       "sett.\0"
+       "dd/M/yy\0"
+       "HH:mm' Ura'\0"
+       "H:mm' Ura'\0"
+       "H' Ura'\0"
+       "HH.mm' h'\0"
+       "H.mm' h'\0"
+       "H' h'\0"
+       "H' Uhr'\0"
+       "HHmm\0"
+       "HH\0"
+       "HH:mm:ss' Ura'\0"
+       "H:mm:ss' Ura'\0"
+       "HH:mm:ss' h'\0"
+       "H:mm:ss' h'\0"
        "duminic\xc4\x83\0"
        "luni\0"
-       "mar\xc5\xa3i\0"
+       "mar\xc8\x9bi\0"
        "miercuri\0"
        "joi\0"
        "vineri\0"
-       "s\xc3\xaemb\xc4\x83t\xc4\x83\0"
-       "D\0"
-       "L\0"
+       "s\xc3\xa2mb\xc4\x83t\xc4\x83\0"
+       "Du\0"
+       "Lu\0"
        "Ma\0"
-       "J\0"
-       "S\0"
+       "Jo\0"
+       "Vi\0"
+       "S\xc3\xa2\0"
        "ianuarie\0"
        "februarie\0"
        "martie\0"
@@ -1977,12 +2422,13 @@ static const char locale_strings [] = {
        "octombrie\0"
        "noiembrie\0"
        "decembrie\0"
-       "Ian\0"
-       "Iun\0"
-       "Iul\0"
-       "d MMMM yyyy '\xd0\xb3.' H:mm:ss\0"
-       "d MMMM yyyy '\xd0\xb3.'\0"
-       "MMMM yyyy '\xd0\xb3.'\0"
+       "ian.\0"
+       "feb.\0"
+       "apr.\0"
+       "iun.\0"
+       "iul.\0"
+       "\xd0\xb4\xd0\xbe \xd0\xbf\xd0\xbe\xd0\xbb\xd1\x83\xd0\xb4\xd0\xbd\xd1\x8f\0"
+       "\xd0\xbf\xd0\xbe\xd1\x81\xd0\xbb\xd0\xb5 \xd0\xbf\xd0\xbe\xd0\xbb\xd1\x83\xd0\xb4\xd0\xbd\xd1\x8f\0"
        "\xd0\xb2\xd0\xbe\xd1\x81\xd0\xba\xd1\x80\xd0\xb5\xd1\x81\xd0\xb5\xd0\xbd\xd1\x8c\xd0\xb5\0"
        "\xd0\xbf\xd0\xbe\xd0\xbd\xd0\xb5\xd0\xb4\xd0\xb5\xd0\xbb\xd1\x8c\xd0\xbd\xd0\xb8\xd0\xba\0"
        "\xd1\x81\xd1\x80\xd0\xb5\xd0\xb4\xd0\xb0\0"
@@ -1996,6 +2442,10 @@ static const char locale_strings [] = {
        "\xd0\xa7\xd1\x82\0"
        "\xd0\x9f\xd1\x82\0"
        "\xd0\xa1\xd0\xb1\0"
+       "\xd0\x92\0"
+       "\xd0\x9f\0"
+       "\xd0\xa1\0"
+       "\xd0\xa7\0"
        "\xd0\xaf\xd0\xbd\xd0\xb2\xd0\xb0\xd1\x80\xd1\x8c\0"
        "\xd0\xa4\xd0\xb5\xd0\xb2\xd1\x80\xd0\xb0\xd0\xbb\xd1\x8c\0"
        "\xd0\x9c\xd0\xb0\xd1\x80\xd1\x82\0"
@@ -2008,19 +2458,28 @@ static const char locale_strings [] = {
        "\xd0\x9e\xd0\xba\xd1\x82\xd1\x8f\xd0\xb1\xd1\x80\xd1\x8c\0"
        "\xd0\x9d\xd0\xbe\xd1\x8f\xd0\xb1\xd1\x80\xd1\x8c\0"
        "\xd0\x94\xd0\xb5\xd0\xba\xd0\xb0\xd0\xb1\xd1\x80\xd1\x8c\0"
-       "\xd1\x8f\xd0\xbd\xd0\xb2\0"
-       "\xd1\x84\xd0\xb5\xd0\xb2\0"
-       "\xd0\xbc\xd0\xb0\xd1\x80\0"
-       "\xd0\xb0\xd0\xbf\xd1\x80\0"
-       "\xd0\xb8\xd1\x8e\xd0\xbd\0"
-       "\xd0\xb8\xd1\x8e\xd0\xbb\0"
-       "\xd0\xb0\xd0\xb2\xd0\xb3\0"
-       "\xd1\x81\xd0\xb5\xd0\xbd\0"
-       "\xd0\xbe\xd0\xba\xd1\x82\0"
-       "\xd0\xbd\xd0\xbe\xd1\x8f\0"
-       "\xd0\xb4\xd0\xb5\xd0\xba\0"
-       "yyyy. MMMM dd H:mm:ss\0"
-       "yyyy. MMMM dd\0"
+       "\xd1\x8f\xd0\xbd\xd0\xb2\xd0\xb0\xd1\x80\xd1\x8f\0"
+       "\xd1\x84\xd0\xb5\xd0\xb2\xd1\x80\xd0\xb0\xd0\xbb\xd1\x8f\0"
+       "\xd0\xbc\xd0\xb0\xd1\x80\xd1\x82\xd0\xb0\0"
+       "\xd0\xb0\xd0\xbf\xd1\x80\xd0\xb5\xd0\xbb\xd1\x8f\0"
+       "\xd0\xbc\xd0\xb0\xd1\x8f\0"
+       "\xd0\xb8\xd1\x8e\xd0\xbd\xd1\x8f\0"
+       "\xd0\xb8\xd1\x8e\xd0\xbb\xd1\x8f\0"
+       "\xd0\xb0\xd0\xb2\xd0\xb3\xd1\x83\xd1\x81\xd1\x82\xd0\xb0\0"
+       "\xd1\x81\xd0\xb5\xd0\xbd\xd1\x82\xd1\x8f\xd0\xb1\xd1\x80\xd1\x8f\0"
+       "\xd0\xbe\xd0\xba\xd1\x82\xd1\x8f\xd0\xb1\xd1\x80\xd1\x8f\0"
+       "\xd0\xbd\xd0\xbe\xd1\x8f\xd0\xb1\xd1\x80\xd1\x8f\0"
+       "\xd0\xb4\xd0\xb5\xd0\xba\xd0\xb0\xd0\xb1\xd1\x80\xd1\x8f\0"
+       "\xd0\xaf\xd0\xbd\xd0\xb2.\0"
+       "\xd0\xa4\xd0\xb5\xd0\xb2\xd1\x80.\0"
+       "\xd0\x90\xd0\xbf\xd1\x80.\0"
+       "\xd0\x90\xd0\xb2\xd0\xb3.\0"
+       "\xd0\xa1\xd0\xb5\xd0\xbd\xd1\x82.\0"
+       "\xd0\x9e\xd0\xba\xd1\x82.\0"
+       "\xd0\x9d\xd0\xbe\xd1\x8f\xd0\xb1.\0"
+       "\xd0\x94\xd0\xb5\xd0\xba.\0"
+       "d. MMMM yyyy.\0"
+       "d.M.yyyy.\0"
        "nedjelja\0"
        "ponedjeljak\0"
        "utorak\0"
@@ -2035,6 +2494,10 @@ static const char locale_strings [] = {
        "\xc4\x8d\x65t\0"
        "pet\0"
        "sub\0"
+       "n\0"
+       "p\0"
+       "u\0"
+       "\xc4\x8d\0"
        "sije\xc4\x8d\x61nj\0"
        "velja\xc4\x8d\x61\0"
        "o\xc5\xbeujak\0"
@@ -2046,8 +2509,19 @@ static const char locale_strings [] = {
        "rujan\0"
        "studeni\0"
        "prosinac\0"
+       "sije\xc4\x8dnja\0"
+       "velja\xc4\x8d\x65\0"
+       "o\xc5\xbeujka\0"
+       "travnja\0"
+       "svibnja\0"
+       "lipnja\0"
+       "srpnja\0"
+       "kolovoza\0"
+       "rujna\0"
+       "studenoga\0"
+       "prosinca\0"
        "sij\0"
-       "vel\0"
+       "velj\0"
        "o\xc5\xbeu\0"
        "tra\0"
        "svi\0"
@@ -2056,27 +2530,45 @@ static const char locale_strings [] = {
        "ruj\0"
        "stu\0"
        "pro\0"
-       "yyyy.MM.dd\0"
-       "d. MMMM yyyy H:mm:ss\0"
+       "d.M.yy.\0"
+       "dd.MM.yyyy.\0"
+       "d. M. yy.\0"
+       "dd.MM.yy.\0"
+       "dd. MM. yy.\0"
+       "dd. MMMM yyyy.\0"
+       "dddd, d. MMMM yyyy.\0"
        "d. M. yyyy\0"
-       "Nede\xc4\xbe\x61\0"
-       "Pondelok\0"
-       "Utorok\0"
-       "Streda\0"
-       "\xc5\xa0tvrtok\0"
-       "Piatok\0"
-       "Sobota\0"
-       "Ne\0"
-       "Po\0"
-       "Ut\0"
-       "St\0"
-       "\xc5\xa0t\0"
-       "Pi\0"
+       "dopoludnia\0"
+       "popoludn\xc3\xad\0"
+       "nede\xc4\xbe\x61\0"
+       "pondelok\0"
+       "utorok\0"
+       "streda\0"
+       "\xc5\xa1tvrtok\0"
+       "piatok\0"
+       "ut\0"
+       "\xc5\xa1t\0"
+       "pi\0"
+       "U\0"
+       "\xc5\xa0\0"
        "marec\0"
        "m\xc3\xa1j\0"
-       "dd MMMM yyyy h:mm:ss.tt\0"
+       "janu\xc3\xa1ra\0"
+       "febru\xc3\xa1ra\0"
+       "apr\xc3\xadla\0"
+       "m\xc3\xa1ja\0"
+       "j\xc3\xbana\0"
+       "j\xc3\xbala\0"
+       "augusta\0"
+       "septembra\0"
+       "okt\xc3\xb3\x62ra\0"
+       "novembra\0"
+       "decembra\0"
+       ". \0"
+       "d. M. yy\0"
        "h:mm:ss.tt\0"
-       "h.mm.t\0"
+       "h:mm.tt\0"
+       "yyyy-MM\0"
        "PD\0"
        "MD\0"
        "e diel\0"
@@ -2092,6 +2584,7 @@ static const char locale_strings [] = {
        "Enj\0"
        "Pre\0"
        "Sht\0"
+       "E\0"
        "janar\0"
        "shkurt\0"
        "prill\0"
@@ -2111,63 +2604,27 @@ static const char locale_strings [] = {
        "Tet\0"
        "N\xc3\xabn\0"
        "Dhj\0"
-       "h.mm.ss.t z\0"
-       "'den 'd MMM yyyy HH.mm.ss z\0"
-       "'den 'd MMM yyyy\0"
-       "fm\0"
-       "em\0"
+       "'den 'd MMMM yyyy\0"
+       "'den 'd MMMM\0"
+       "FM\0"
+       "EM\0"
        "s\xc3\xb6ndag\0"
        "m\xc3\xa5ndag\0"
        "tisdag\0"
        "l\xc3\xb6rdag\0"
-       "s\xc3\xb6\0"
-       "m\xc3\xa5\0"
-       "l\xc3\xb6\0"
+       "s\xc3\xb6n\0"
+       "m\xc3\xa5n\0"
+       "tis\0"
+       "l\xc3\xb6r\0"
        "augusti\0"
-       "d MMMM yyyy, H:mm:ss\0"
-       "\xe0\xb8\x81\xe0\xb9\x88\xe0\xb8\xad\xe0\xb8\x99\xe0\xb9\x80\xe0\xb8\x97\xe0\xb8\xb5\xe0\xb9\x88\xe0\xb8\xa2\xe0\xb8\x87\0"
-       "\xe0\xb8\xab\xe0\xb8\xa5\xe0\xb8\xb1\xe0\xb8\x87\xe0\xb9\x80\xe0\xb8\x97\xe0\xb8\xb5\xe0\xb9\x88\xe0\xb8\xa2\xe0\xb8\x87\0"
-       "\xe0\xb8\xa7\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\xad\xe0\xb8\xb2\xe0\xb8\x97\xe0\xb8\xb4\xe0\xb8\x95\xe0\xb8\xa2\xe0\xb9\x8c\0"
-       "\xe0\xb8\xa7\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\x88\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\x97\xe0\xb8\xa3\xe0\xb9\x8c\0"
-       "\xe0\xb8\xa7\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\xad\xe0\xb8\xb1\xe0\xb8\x87\xe0\xb8\x84\xe0\xb8\xb2\xe0\xb8\xa3\0"
-       "\xe0\xb8\xa7\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\x9e\xe0\xb8\xb8\xe0\xb8\x98\0"
-       "\xe0\xb8\xa7\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\x9e\xe0\xb8\xa4\xe0\xb8\xab\xe0\xb8\xb1\xe0\xb8\xaa\xe0\xb8\x9a\xe0\xb8\x94\xe0\xb8\xb5\0"
-       "\xe0\xb8\xa7\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\xa8\xe0\xb8\xb8\xe0\xb8\x81\xe0\xb8\xa3\xe0\xb9\x8c\0"
-       "\xe0\xb8\xa7\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb9\x80\xe0\xb8\xaa\xe0\xb8\xb2\xe0\xb8\xa3\xe0\xb9\x8c\0"
-       "\xe0\xb8\xad\xe0\xb8\xb2.\0"
-       "\xe0\xb8\x88.\0"
-       "\xe0\xb8\xad.\0"
-       "\xe0\xb8\x9e.\0"
-       "\xe0\xb8\x9e\xe0\xb8\xa4.\0"
-       "\xe0\xb8\xa8.\0"
-       "\xe0\xb8\xaa.\0"
-       "\xe0\xb8\xa1\xe0\xb8\x81\xe0\xb8\xa3\xe0\xb8\xb2\xe0\xb8\x84\xe0\xb8\xa1\0"
-       "\xe0\xb8\x81\xe0\xb8\xb8\xe0\xb8\xa1\xe0\xb8\xa0\xe0\xb8\xb2\xe0\xb8\x9e\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\x98\xe0\xb9\x8c\0"
-       "\xe0\xb8\xa1\xe0\xb8\xb5\xe0\xb8\x99\xe0\xb8\xb2\xe0\xb8\x84\xe0\xb8\xa1\0"
-       "\xe0\xb9\x80\xe0\xb8\xa1\xe0\xb8\xa9\xe0\xb8\xb2\xe0\xb8\xa2\xe0\xb8\x99\0"
-       "\xe0\xb8\x9e\xe0\xb8\xa4\xe0\xb8\xa9\xe0\xb8\xa0\xe0\xb8\xb2\xe0\xb8\x84\xe0\xb8\xa1\0"
-       "\xe0\xb8\xa1\xe0\xb8\xb4\xe0\xb8\x96\xe0\xb8\xb8\xe0\xb8\x99\xe0\xb8\xb2\xe0\xb8\xa2\xe0\xb8\x99\0"
-       "\xe0\xb8\x81\xe0\xb8\xa3\xe0\xb8\x81\xe0\xb8\x8e\xe0\xb8\xb2\xe0\xb8\x84\xe0\xb8\xa1\0"
-       "\xe0\xb8\xaa\xe0\xb8\xb4\xe0\xb8\x87\xe0\xb8\xab\xe0\xb8\xb2\xe0\xb8\x84\xe0\xb8\xa1\0"
-       "\xe0\xb8\x81\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\xa2\xe0\xb8\xb2\xe0\xb8\xa2\xe0\xb8\x99\0"
-       "\xe0\xb8\x95\xe0\xb8\xb8\xe0\xb8\xa5\xe0\xb8\xb2\xe0\xb8\x84\xe0\xb8\xa1\0"
-       "\xe0\xb8\x9e\xe0\xb8\xa4\xe0\xb8\xa8\xe0\xb8\x88\xe0\xb8\xb4\xe0\xb8\x81\xe0\xb8\xb2\xe0\xb8\xa2\xe0\xb8\x99\0"
-       "\xe0\xb8\x98\xe0\xb8\xb1\xe0\xb8\x99\xe0\xb8\xa7\xe0\xb8\xb2\xe0\xb8\x84\xe0\xb8\xa1\0"
-       "\xe0\xb8\xa1.\xe0\xb8\x84.\0"
-       "\xe0\xb8\x81.\xe0\xb8\x9e.\0"
-       "\xe0\xb8\xa1\xe0\xb8\xb5.\xe0\xb8\x84.\0"
-       "\xe0\xb9\x80\xe0\xb8\xa1.\xe0\xb8\xa2.\0"
-       "\xe0\xb8\x9e.\xe0\xb8\x84.\0"
-       "\xe0\xb8\xa1\xe0\xb8\xb4.\xe0\xb8\xa2.\0"
-       "\xe0\xb8\x81.\xe0\xb8\x84.\0"
-       "\xe0\xb8\xaa.\xe0\xb8\x84.\0"
-       "\xe0\xb8\x81.\xe0\xb8\xa2.\0"
-       "\xe0\xb8\x95.\xe0\xb8\x84.\0"
-       "\xe0\xb8\x9e.\xe0\xb8\xa2.\0"
-       "\xe0\xb8\x98.\xe0\xb8\x84.\0"
-       "H' \xe0\xb8\x99\xe0\xb8\xb2\xe0\xb8\xac\xe0\xb8\xb4\xe0\xb8\x81\xe0\xb8\xb2 'm' \xe0\xb8\x99\xe0\xb8\xb2\xe0\xb8\x97\xe0\xb8\xb5'\0"
-       "dd MMMM yyyy EEEE HH:mm:ss\0"
-       "dd MMMM yyyy EEEE\0"
+       "dddd' den 'd MMMM yyyy\0"
+       "'kl 'H:mm\0"
+       "'kl 'H:mm:ss\0"
+       "d MMM yyyy\0"
+       "dd MMM yyyy\0"
+       "ddd d MMMM yyyy\0"
+       "'\xe0\xb8\xa7\xe0\xb8\xb1\xe0\xb8\x99'dddd'\xe0\xb8\x97\xe0\xb8\xb5\xe0\xb9\x88' d MMMM gg yyyy\0"
+       "dd MMMM yyyy dddd\0"
        "Pazar\0"
        "Pazartesi\0"
        "Sal\xc4\xb1\0"
@@ -2182,6 +2639,7 @@ static const char locale_strings [] = {
        "Per\0"
        "Cum\0"
        "Cmt\0"
+       "\xc3\x87\0"
        "Ocak\0"
        "\xc5\x9eubat\0"
        "Mart\0"
@@ -2204,6 +2662,27 @@ static const char locale_strings [] = {
        "Eki\0"
        "Kas\0"
        "Ara\0"
+       "\xd8\xaf\xd9\x86\0"
+       "\xd8\xb1\xd8\xa7\xd8\xaa\0"
+       "\xd8\xa7\xd8\xaa\xd9\x88\xd8\xa7\xd8\xb1\0"
+       "\xd9\xbe\xd9\x8a\xd8\xb1\0"
+       "\xd9\x85\xd9\x86\xda\xaf\xd9\x84\0"
+       "\xd8\xa8\xd8\xaf\xd9\x87\0"
+       "\xd8\xac\xd9\x85\xd8\xb9\xd8\xb1\xd8\xa7\xd8\xaa\0"
+       "\xd8\xac\xd9\x85\xd8\xb9\xdb\x81\0"
+       "\xdb\x81\xd9\x81\xd8\xaa\xdb\x81\0"
+       "\xd8\xac\xd9\x86\xd9\x88\xd8\xb1\xdb\x8c\0"
+       "\xd9\x81\xd8\xb1\xd9\x88\xd8\xb1\xdb\x8c\0"
+       "\xd9\x85\xd8\xa7\xd8\xb1\xda\x86\0"
+       "\xd8\xa7\xd9\xbe\xd8\xb1\xd9\x8a\xd9\x84\0"
+       "\xd9\x85\xd8\xa6\0"
+       "\xd8\xac\xd9\x88\xd9\x86\0"
+       "\xd8\xac\xd9\x88\xd9\x84\xd8\xa7\xd8\xa6\0"
+       "\xd8\xa7\xda\xaf\xd8\xb3\xd8\xaa\0"
+       "\xd8\xb3\xd8\xaa\xd9\x85\xd8\xa8\xd8\xb1\0"
+       "\xd8\xa7\xda\xa9\xd8\xaa\xd9\x88\xd8\xa8\xd8\xb1\0"
+       "\xd9\x86\xd9\x88\xd9\x85\xd8\xa8\xd8\xb1\0"
+       "\xd8\xaf\xd8\xb3\xd9\x85\xd8\xa8\xd8\xb1\0"
        "Minggu\0"
        "Senin\0"
        "Selasa\0"
@@ -2218,24 +2697,40 @@ static const char locale_strings [] = {
        "Kam\0"
        "Jum\0"
        "Sab\0"
+       "R\0"
        "Januari\0"
        "Februari\0"
        "Maret\0"
        "Mei\0"
        "Agustus\0"
        "Desember\0"
-       "Agu\0"
+       "Agt\0"
        "Des\0"
-       "d MMMM yyyy H:mm:ss\0"
-       "MMMM yyyy '\xd1\x80.'\0"
+       "d MMMM yyyy' \xd1\x80.'\0"
+       "MMMM yyyy' \xd1\x80.'\0"
+       "\xd0\xb4\xd0\xbf\0"
+       "\xd0\xbf\xd0\xbf\0"
        "\xd0\x9d\xd0\xb5\xd0\xb4\xd1\x96\xd0\xbb\xd1\x8f\0"
        "\xd0\x9f\xd0\xbe\xd0\xbd\xd0\xb5\xd0\xb4\xd1\x96\xd0\xbb\xd0\xbe\xd0\xba\0"
        "\xd0\x92\xd1\x96\xd0\xb2\xd1\x82\xd0\xbe\xd1\x80\xd0\xbe\xd0\xba\0"
        "\xd0\xa1\xd0\xb5\xd1\x80\xd0\xb5\xd0\xb4\xd0\xb0\0"
        "\xd0\xa7\xd0\xb5\xd1\x82\xd0\xb2\xd0\xb5\xd1\x80\0"
-       "\xd0\x9f'\xd1\x8f\xd1\x82\xd0\xbd\xd0\xb8\xd1\x86\xd1\x8f\0"
+       "\xd0\x9f\xca\xbc\xd1\x8f\xd1\x82\xd0\xbd\xd0\xb8\xd1\x86\xd1\x8f\0"
        "\xd0\xa1\xd1\x83\xd0\xb1\xd0\xbe\xd1\x82\xd0\xb0\0"
        "\xd0\x9d\xd0\xb4\0"
+       "\xd0\x9d\0"
+       "\xd0\xa1\xd1\x96\xd1\x87\xd0\xb5\xd0\xbd\xd1\x8c\0"
+       "\xd0\x9b\xd1\x8e\xd1\x82\xd0\xb8\xd0\xb9\0"
+       "\xd0\x91\xd0\xb5\xd1\x80\xd0\xb5\xd0\xb7\xd0\xb5\xd0\xbd\xd1\x8c\0"
+       "\xd0\x9a\xd0\xb2\xd1\x96\xd1\x82\xd0\xb5\xd0\xbd\xd1\x8c\0"
+       "\xd0\xa2\xd1\x80\xd0\xb0\xd0\xb2\xd0\xb5\xd0\xbd\xd1\x8c\0"
+       "\xd0\xa7\xd0\xb5\xd1\x80\xd0\xb2\xd0\xb5\xd0\xbd\xd1\x8c\0"
+       "\xd0\x9b\xd0\xb8\xd0\xbf\xd0\xb5\xd0\xbd\xd1\x8c\0"
+       "\xd0\xa1\xd0\xb5\xd1\x80\xd0\xbf\xd0\xb5\xd0\xbd\xd1\x8c\0"
+       "\xd0\x92\xd0\xb5\xd1\x80\xd0\xb5\xd1\x81\xd0\xb5\xd0\xbd\xd1\x8c\0"
+       "\xd0\x96\xd0\xbe\xd0\xb2\xd1\x82\xd0\xb5\xd0\xbd\xd1\x8c\0"
+       "\xd0\x9b\xd0\xb8\xd1\x81\xd1\x82\xd0\xbe\xd0\xbf\xd0\xb0\xd0\xb4\0"
+       "\xd0\x93\xd1\x80\xd1\x83\xd0\xb4\xd0\xb5\xd0\xbd\xd1\x8c\0"
        "\xd1\x81\xd1\x96\xd1\x87\xd0\xbd\xd1\x8f\0"
        "\xd0\xbb\xd1\x8e\xd1\x82\xd0\xbe\xd0\xb3\xd0\xbe\0"
        "\xd0\xb1\xd0\xb5\xd1\x80\xd0\xb5\xd0\xb7\xd0\xbd\xd1\x8f\0"
@@ -2248,19 +2743,20 @@ static const char locale_strings [] = {
        "\xd0\xb6\xd0\xbe\xd0\xb2\xd1\x82\xd0\xbd\xd1\x8f\0"
        "\xd0\xbb\xd0\xb8\xd1\x81\xd1\x82\xd0\xbe\xd0\xbf\xd0\xb0\xd0\xb4\xd0\xb0\0"
        "\xd0\xb3\xd1\x80\xd1\x83\xd0\xb4\xd0\xbd\xd1\x8f\0"
-       "\xd1\x81\xd1\x96\xd1\x87\0"
-       "\xd0\xbb\xd1\x8e\xd1\x82\0"
-       "\xd0\xb1\xd0\xb5\xd1\x80\0"
-       "\xd0\xba\xd0\xb2\xd1\x96\xd1\x82\0"
-       "\xd1\x82\xd1\x80\xd0\xb0\xd0\xb2\0"
-       "\xd1\x87\xd0\xb5\xd1\x80\xd0\xb2\0"
-       "\xd0\xbb\xd0\xb8\xd0\xbf\0"
-       "\xd1\x81\xd0\xb5\xd1\x80\xd0\xbf\0"
-       "\xd0\xb2\xd0\xb5\xd1\x80\0"
-       "\xd0\xb6\xd0\xbe\xd0\xb2\xd1\x82\0"
-       "\xd0\xbb\xd0\xb8\xd1\x81\xd1\x82\0"
-       "\xd0\xb3\xd1\x80\xd1\x83\xd0\xb4\0"
-       "d MMMM yyyy HH.mm.ss z\0"
+       "\xd0\xa1\xd1\x96\xd1\x87\0"
+       "\xd0\x9b\xd1\x8e\xd1\x82\0"
+       "\xd0\x91\xd0\xb5\xd1\x80\0"
+       "\xd0\x9a\xd0\xb2\xd1\x96\0"
+       "\xd0\xa2\xd1\x80\xd0\xb0\0"
+       "\xd0\xa7\xd0\xb5\xd1\x80\0"
+       "\xd0\x9b\xd0\xb8\xd0\xbf\0"
+       "\xd0\xa1\xd0\xb5\xd1\x80\0"
+       "\xd0\x92\xd0\xb5\xd1\x80\0"
+       "\xd0\x96\xd0\xbe\xd0\xb2\0"
+       "\xd0\x9b\xd0\xb8\xd1\x81\0"
+       "\xd0\x93\xd1\x80\xd1\x83\0"
+       "\xd1\x80\xd0\xb0\xd0\xbd\xd1\x96\xd1\x86\xd1\x8b\0"
+       "\xd0\xb2\xd0\xb5\xd1\x87\xd0\xb0\xd1\x80\xd0\xb0\0"
        "\xd0\xbd\xd1\x8f\xd0\xb4\xd0\xb7\xd0\xb5\xd0\xbb\xd1\x8f\0"
        "\xd0\xbf\xd0\xb0\xd0\xbd\xd1\x8f\xd0\xb4\xd0\xb7\xd0\xb5\xd0\xbb\xd0\xb0\xd0\xba\0"
        "\xd0\xb0\xd1\x9e\xd1\x82\xd0\xbe\xd1\x80\xd0\xb0\xd0\xba\0"
@@ -2268,17 +2764,14 @@ static const char locale_strings [] = {
        "\xd1\x87\xd0\xb0\xd1\x86\xd0\xb2\xd0\xb5\xd1\x80\0"
        "\xd0\xbf\xd1\x8f\xd1\x82\xd0\xbd\xd1\x96\xd1\x86\xd0\xb0\0"
        "\xd1\x81\xd1\x83\xd0\xb1\xd0\xbe\xd1\x82\xd0\xb0\0"
-       "\xd0\xbd\xd0\xb4\0"
-       "\xd0\xbf\xd0\xbd\0"
        "\xd0\xb0\xd1\x9e\0"
-       "\xd1\x81\xd1\x80\0"
        "\xd1\x87\xd1\x86\0"
-       "\xd0\xbf\xd1\x82\0"
-       "\xd1\x81\xd0\xb1\0"
+       "\xd0\xb0\0"
        "\xd1\x81\xd1\x82\xd1\x83\xd0\xb4\xd0\xb7\xd0\xb5\xd0\xbd\xd1\x8c\0"
        "\xd0\xbb\xd1\x8e\xd1\x82\xd1\x8b\0"
        "\xd1\x81\xd0\xb0\xd0\xba\xd0\xb0\xd0\xb2\xd1\x96\xd0\xba\0"
        "\xd0\xba\xd1\x80\xd0\xb0\xd1\x81\xd0\xb0\xd0\xb2\xd1\x96\xd0\xba\0"
+       "\xd1\x82\xd1\x80\xd0\xb0\xd0\xb2\xd0\xb5\xd0\xbd\xd1\x8c\0"
        "\xd1\x87\xd1\x8d\xd1\x80\xd0\xb2\xd0\xb5\xd0\xbd\xd1\x8c\0"
        "\xd0\xbb\xd1\x96\xd0\xbf\xd0\xb5\xd0\xbd\xd1\x8c\0"
        "\xd0\xb6\xd0\xbd\xd1\x96\xd0\xb2\xd0\xb5\xd0\xbd\xd1\x8c\0"
@@ -2287,16 +2780,18 @@ static const char locale_strings [] = {
        "\xd0\xbb\xd1\x96\xd1\x81\xd1\x82\xd0\xb0\xd0\xbf\xd0\xb0\xd0\xb4\0"
        "\xd1\x81\xd0\xbd\xd0\xb5\xd0\xb6\xd0\xb0\xd0\xbd\xd1\x8c\0"
        "\xd1\x81\xd1\x82\xd1\x83\0"
+       "\xd0\xbb\xd1\x8e\xd1\x82\0"
        "\xd1\x81\xd0\xb0\xd0\xba\0"
        "\xd0\xba\xd1\x80\xd0\xb0\0"
+       "\xd1\x82\xd1\x80\xd0\xb0\0"
        "\xd1\x87\xd1\x8d\xd1\x80\0"
        "\xd0\xbb\xd1\x96\xd0\xbf\0"
        "\xd0\xb6\xd0\xbd\xd1\x96\0"
+       "\xd0\xb2\xd0\xb5\xd1\x80\0"
        "\xd0\xba\xd0\xb0\xd1\x81\0"
        "\xd0\xbb\xd1\x96\xd1\x81\0"
        "\xd1\x81\xd0\xbd\xd0\xb5\0"
-       "dd. MMMM yyyy H:mm:ss\0"
-       "dd. MMMM yyyy\0"
+       "pop.\0"
        "nedelja\0"
        "ponedeljek\0"
        "torek\0"
@@ -2309,9 +2804,12 @@ static const char locale_strings [] = {
        "julij\0"
        "avgust\0"
        "avg\0"
-       "yy.M.d\0"
+       "dd. MM. yy\0"
+       "d. MMMM yyyy'. a.'\0"
        "d.MM.yyyy\0"
-       "d, MMMM\0"
+       "MMMM yyyy'. a.'\0"
+       "e.k.\0"
+       "p.k.\0"
        "p\xc3\xbchap\xc3\xa4\x65v\0"
        "esmasp\xc3\xa4\x65v\0"
        "teisip\xc3\xa4\x65v\0"
@@ -2319,9 +2817,6 @@ static const char locale_strings [] = {
        "neljap\xc3\xa4\x65v\0"
        "reede\0"
        "laup\xc3\xa4\x65v\0"
-       "E\0"
-       "T\0"
-       "R\0"
        "jaanuar\0"
        "veebruar\0"
        "m\xc3\xa4rts\0"
@@ -2334,9 +2829,10 @@ static const char locale_strings [] = {
        "veebr\0"
        "sept\0"
        "dets\0"
-       "yyyy'. gada 'd. MMMM H:mm:ss\0"
-       "yyyy'. gada 'd. MMMM\0"
-       "yyyy'. gada 'MMMM\0"
+       "dd. MMMM yyyy'. a.'\0"
+       "dddd, yyyy'. gada 'd. MMMM\0"
+       "priek\xc5\xa1pusdien\xc4\x81\0"
+       "p\xc4\x93\x63pusdien\xc4\x81\0"
        "sv\xc4\x93tdiena\0"
        "pirmdiena\0"
        "otrdiena\0"
@@ -2345,9 +2841,12 @@ static const char locale_strings [] = {
        "piektdiena\0"
        "sestdiena\0"
        "Sv\0"
-       "O\0"
-       "C\0"
+       "Pr\0"
+       "Ot\0"
+       "Tr\0"
+       "Ce\0"
        "Pk\0"
+       "Se\0"
        "janv\xc4\x81ris\0"
        "febru\xc4\x81ris\0"
        "apr\xc4\xablis\0"
@@ -2359,69 +2858,115 @@ static const char locale_strings [] = {
        "oktobris\0"
        "novembris\0"
        "decembris\0"
-       "J\xc5\xabn\0"
-       "J\xc5\xabl\0"
-       "yy.d.M\0"
-       "yyyy 'm.' MMMM d 'd.' HH:mm:ss z\0"
+       "j\xc5\xabn.\0"
+       "j\xc5\xabl.\0"
+       "yy.MM.dd.\0"
        "yyyy 'm.' MMMM d 'd.'\0"
        "yyyy 'm.' MMMM\0"
        "MMMM d 'd.'\0"
-       "Sekmadienis\0"
-       "Pirmadienis\0"
-       "Antradienis\0"
-       "Tre\xc4\x8diadienis\0"
-       "Ketvirtadienis\0"
-       "Penktadienis\0"
-       "\xc5\xa0\x65\xc5\xa1tadienis\0"
+       "pr.p.\0"
+       "sekmadienis\0"
+       "pirmadienis\0"
+       "antradienis\0"
+       "tre\xc4\x8diadienis\0"
+       "ketvirtadienis\0"
+       "penktadienis\0"
+       "\xc5\xa1\x65\xc5\xa1tadienis\0"
        "Sk\0"
-       "Pr\0"
        "An\0"
-       "Tr\0"
        "Kt\0"
-       "Sausio\0"
-       "Vasario\0"
-       "Kovo\0"
-       "Baland\xc5\xbeio\0"
-       "Gegu\xc5\xbe\xc4\x97s\0"
-       "Bir\xc5\xbe\x65lio\0"
-       "Liepos\0"
-       "Rugpj\xc5\xab\xc4\x8dio\0"
-       "Rugs\xc4\x97jo\0"
-       "Spalio\0"
-       "Lapkri\xc4\x8dio\0"
-       "Gruod\xc5\xbeio\0"
-       "Sau\0"
-       "Vas\0"
-       "Kov\0"
-       "Bal\0"
-       "Geg\0"
-       "Bir\0"
-       "Lie\0"
-       "Rgp\0"
-       "Rgs\0"
-       "Spa\0"
-       "Lap\0"
-       "Grd\0"
-       "d MMMM yyyy hh:mm:ss tt\0"
-       "M/d/yyyy\0"
-       "\xd9\x82.\xd8\xb8.\0"
-       "\xd8\xa8.\xd8\xb8.\0"
-       "\xdb\x8c\xda\xa9\xe2\x80\x8c\xd8\xb4\xd9\x86\xd8\xa8\xd9\x87\0"
+       "Pn\0"
+       "\xc5\xa0t\0"
+       "A\0"
+       "Sausis\0"
+       "Vasaris\0"
+       "Kovas\0"
+       "Balandis\0"
+       "Gegu\xc5\xbe\xc4\x97\0"
+       "Bir\xc5\xbe\x65lis\0"
+       "Liepa\0"
+       "Rugpj\xc5\xabtis\0"
+       "Rugs\xc4\x97jis\0"
+       "Spalis\0"
+       "Lapkritis\0"
+       "Gruodis\0"
+       "sausio\0"
+       "vasaris\0"
+       "kovas\0"
+       "balandis\0"
+       "gegu\xc5\xbe\xc4\x97\0"
+       "bir\xc5\xbe\x65lis\0"
+       "liepa\0"
+       "rugpj\xc5\xabtis\0"
+       "rugs\xc4\x97jis\0"
+       "spalis\0"
+       "lapkritis\0"
+       "gruodis\0"
+       "Saus.\0"
+       "Vas.\0"
+       "Kov.\0"
+       "Bal.\0"
+       "Geg.\0"
+       "Bir.\0"
+       "Liep.\0"
+       "Rugp.\0"
+       "Rugs.\0"
+       "Spal.\0"
+       "Lapkr.\0"
+       "Gruod.\0"
+       "\xd0\xbf\xd0\xb5. \xd1\x87\xd0\xbe.\0"
+       "\xd0\xbf\xd0\xb0. \xd1\x87\xd0\xbe.\0"
+       "\xd0\xaf\xd0\xba\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb5\0"
+       "\xd0\x94\xd1\x83\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb5\0"
+       "\xd0\xa1\xd0\xb5\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb5\0"
+       "\xd0\xa7\xd0\xbe\xd1\x80\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb5\0"
+       "\xd0\x9f\xd0\xb0\xd0\xbd\xd2\xb7\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb5\0"
+       "\xd2\xb6\xd1\x83\xd0\xbc\xd1\x8a\xd0\xb0\0"
+       "\xd0\xa8\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb5\0"
+       "\xd0\xaf\xd1\x88\xd0\xb1\0"
+       "\xd0\x94\xd1\x88\xd0\xb1\0"
+       "\xd0\xa1\xd1\x88\xd0\xb1\0"
+       "\xd0\xa7\xd1\x88\xd0\xb1\0"
+       "\xd0\x9f\xd1\x88\xd0\xb1\0"
+       "\xd2\xb6\xd0\xbc\xd1\x8a\0"
+       "\xd0\xa8\xd0\xbd\xd0\xb1\0"
+       "\xd0\xaf\xd0\xbd\xd0\xb2\xd0\xb0\xd1\x80\0"
+       "\xd0\xa4\xd0\xb5\xd0\xb2\xd1\x80\xd0\xb0\xd0\xbb\0"
+       "\xd0\x90\xd0\xbf\xd1\x80\xd0\xb5\xd0\xbb\0"
+       "\xd0\x98\xd1\x8e\xd0\xbd\0"
+       "\xd0\x98\xd1\x8e\xd0\xbb\0"
+       "\xd0\xa1\xd0\xb5\xd0\xbd\xd1\x82\xd1\x8f\xd0\xb1\xd1\x80\0"
+       "\xd0\x9e\xd0\xba\xd1\x82\xd1\x8f\xd0\xb1\xd1\x80\0"
+       "\xd0\x9d\xd0\xbe\xd1\x8f\xd0\xb1\xd1\x80\0"
+       "\xd0\x94\xd0\xb5\xd0\xba\xd0\xb0\xd0\xb1\xd1\x80\0"
+       "\xd0\xaf\xd0\xbd\xd0\xb2\0"
+       "\xd0\xa4\xd0\xb5\xd0\xb2\0"
+       "\xd0\x9c\xd0\xb0\xd1\x80\0"
+       "\xd0\x90\xd0\xbf\xd1\x80\0"
+       "\xd0\x90\xd0\xb2\xd0\xb3\0"
+       "\xd0\xa1\xd0\xb5\xd0\xbd\0"
+       "\xd0\x9e\xd0\xba\xd1\x82\0"
+       "\xd0\x9d\xd0\xbe\xd1\x8f\0"
+       "\xd0\x94\xd0\xb5\xd0\xba\0"
+       "\xd9\x82\xd8\xa8\xd9\x84\xe2\x80\x8c\xd8\xa7\xd8\xb2\xd8\xb8\xd9\x87\xd8\xb1\0"
+       "\xd8\xa8\xd8\xb9\xd8\xaf\xd8\xa7\xd8\xb2\xd8\xb8\xd9\x87\xd8\xb1\0"
+       "\xdb\x8c\xda\xa9\xd8\xb4\xd9\x86\xd8\xa8\xd9\x87\0"
        "\xd8\xaf\xd9\x88\xd8\xb4\xd9\x86\xd8\xa8\xd9\x87\0"
        "\xd8\xb3\xd9\x87\xe2\x80\x8c\xd8\xb4\xd9\x86\xd8\xa8\xd9\x87\0"
        "\xda\x86\xd9\x87\xd8\xa7\xd8\xb1\xd8\xb4\xd9\x86\xd8\xa8\xd9\x87\0"
-       "\xd9\xbe\xd9\x86\xd8\xac\xe2\x80\x8c\xd8\xb4\xd9\x86\xd8\xa8\xd9\x87\0"
+       "\xd9\xbe\xd9\x86\xd8\xac\xd8\xb4\xd9\x86\xd8\xa8\xd9\x87\0"
        "\xd8\xac\xd9\x85\xd8\xb9\xd9\x87\0"
        "\xd8\xb4\xd9\x86\xd8\xa8\xd9\x87\0"
-       "\xdb\x8c.\0"
-       "\xd8\xaf.\0"
-       "\xd8\xb3.\0"
-       "\xda\x86.\0"
-       "\xd9\xbe.\0"
-       "\xd8\xac.\0"
-       "\xd8\xb4.\0"
+       "\xdb\x8c\0"
+       "\xd8\xaf\0"
+       "\xd8\xb3\0"
+       "\xda\x86\0"
+       "\xd9\xbe\0"
+       "\xd8\xac\0"
+       "\xd8\xb4\0"
        "\xda\x98\xd8\xa7\xd9\x86\xd9\x88\xdb\x8c\xd9\x87\0"
        "\xd9\x81\xd9\x88\xd8\xb1\xdb\x8c\xd9\x87\0"
+       "\xd9\x85\xd8\xa7\xd8\xb1\xd8\xb3\0"
        "\xd8\xa2\xd9\x88\xd8\xb1\xdb\x8c\xd9\x84\0"
        "\xd9\x85\xd9\x87\0"
        "\xda\x98\xd9\x88\xd8\xa6\xd9\x86\0"
@@ -2431,20 +2976,10 @@ static const char locale_strings [] = {
        "\xd8\xa7\xda\xa9\xd8\xaa\xd8\xa8\xd8\xb1\0"
        "\xd9\x86\xd9\x88\xd8\xa7\xd9\x85\xd8\xa8\xd8\xb1\0"
        "\xd8\xaf\xd8\xb3\xd8\xa7\xd9\x85\xd8\xa8\xd8\xb1\0"
-       "\xda\x98\xd8\xa7\xd9\x86\0"
-       "\xd9\x81\xd9\x88\xd8\xb1\0"
-       "\xd9\x85\xd8\xa7\xd8\xb1\0"
-       "\xd8\xa2\xd9\x88\xd8\xb1\0"
-       "\xd9\x85\xd9\x80\xd9\x87\0"
-       "\xda\x98\xd9\x88\xd9\x86\0"
-       "\xda\x98\xd9\x88\xdb\x8c\0"
-       "\xd8\xb3\xd9\xbe\xd8\xaa\0"
-       "\xd8\xa7\xda\xa9\xd8\xaa\0"
-       "\xd9\x86\xd9\x88\xd8\xa7\0"
-       "\xd8\xaf\xd8\xb3\xd8\xa7\0"
-       "yyyy/MM/d\0"
-       "HH:mm:ss (z)\0"
-       "h:mm:ss tt dd MMMM yyyy\0"
+       "\xda\x98\xd8\xa7\xd9\x86\xd9\x88\xdb\x8c\xd9\x87\xd9\x94\0"
+       "\xd9\x81\xd9\x88\xd8\xb1\xdb\x8c\xd9\x87\xd9\x94\0"
+       "\xd9\x85\xd9\x87\xd9\x94\0"
+       "\xda\x98\xd9\x88\xd8\xa6\xdb\x8c\xd9\x87\xd9\x94\0"
        "SA\0"
        "CH\0"
        "Ch\xe1\xbb\xa7 nh\xe1\xba\xadt\0"
@@ -2461,33 +2996,39 @@ static const char locale_strings [] = {
        "Th 5\0"
        "Th 6\0"
        "Th 7\0"
-       "Th\xc3\xa1ng m\xe1\xbb\x99t\0"
-       "Th\xc3\xa1ng hai\0"
-       "Th\xc3\xa1ng ba\0"
-       "Th\xc3\xa1ng t\xc6\xb0\0"
-       "Th\xc3\xa1ng n\xc4\x83m\0"
-       "Th\xc3\xa1ng s\xc3\xa1u\0"
-       "Th\xc3\xa1ng b\xe1\xba\xa3y\0"
-       "Th\xc3\xa1ng t\xc3\xa1m\0"
-       "Th\xc3\xa1ng ch\xc3\xadn\0"
-       "Th\xc3\xa1ng m\xc6\xb0\xe1\xbb\x9di\0"
-       "Th\xc3\xa1ng m\xc6\xb0\xe1\xbb\x9di m\xe1\xbb\x99t\0"
-       "Th\xc3\xa1ng m\xc6\xb0\xe1\xbb\x9di hai\0"
-       "Thg 1\0"
-       "Thg 2\0"
-       "Thg 3\0"
-       "Thg 4\0"
-       "Thg 5\0"
-       "Thg 6\0"
-       "Thg 7\0"
-       "Thg 8\0"
-       "Thg 9\0"
-       "Thg 10\0"
-       "Thg 11\0"
-       "Thg 12\0"
-       "MMMM dd, yyyy H:mm:ss\0"
+       "T2\0"
+       "T3\0"
+       "T4\0"
+       "T5\0"
+       "T6\0"
+       "T7\0"
+       "th\xc3\xa1ng m\xe1\xbb\x99t\0"
+       "th\xc3\xa1ng hai\0"
+       "th\xc3\xa1ng ba\0"
+       "th\xc3\xa1ng t\xc6\xb0\0"
+       "th\xc3\xa1ng n\xc4\x83m\0"
+       "th\xc3\xa1ng s\xc3\xa1u\0"
+       "th\xc3\xa1ng b\xe1\xba\xa3y\0"
+       "th\xc3\xa1ng t\xc3\xa1m\0"
+       "th\xc3\xa1ng ch\xc3\xadn\0"
+       "th\xc3\xa1ng m\xc6\xb0\xe1\xbb\x9di\0"
+       "th\xc3\xa1ng m\xc6\xb0\xe1\xbb\x9di m\xe1\xbb\x99t\0"
+       "th\xc3\xa1ng m\xc6\xb0\xe1\xbb\x9di hai\0"
+       "thg 1\0"
+       "thg 2\0"
+       "thg 3\0"
+       "thg 4\0"
+       "thg 5\0"
+       "thg 6\0"
+       "thg 7\0"
+       "thg 8\0"
+       "thg 9\0"
+       "thg 10\0"
+       "thg 11\0"
+       "thg 12\0"
+       "d MMMM, yyyy\0"
        "\xd4\xb1\xd5\xbc\xe2\x80\xa4\0"
-       "\xd4\xb5\xd6\x80\xe2\x80\xa4\0"
+       "\xd4\xbf\xd5\xa5\xe2\x80\xa4\0"
        "\xd4\xbf\xd5\xab\xd6\x80\xd5\xa1\xd5\xaf\xd5\xab\0"
        "\xd4\xb5\xd6\x80\xd5\xaf\xd5\xb8\xd6\x82\xd5\xb7\xd5\xa1\xd5\xa2\xd5\xa9\xd5\xab\0"
        "\xd4\xb5\xd6\x80\xd5\xa5\xd6\x84\xd5\xb7\xd5\xa1\xd5\xa2\xd5\xa9\xd5\xab\0"
@@ -2502,31 +3043,70 @@ static const char locale_strings [] = {
        "\xd5\x80\xd5\xb6\xd5\xa3\0"
        "\xd5\x88\xd6\x82\xd6\x80\0"
        "\xd5\x87\xd5\xa1\xd5\xa2\0"
-       "\xd5\x85\xd5\xb8\xd6\x82\xd5\xb6\xd5\xb8\xd6\x82\xd5\xa1\xd6\x80\0"
-       "\xd5\x93\xd5\xa5\xd5\xbf\xd6\x80\xd5\xb8\xd6\x82\xd5\xa1\xd6\x80\0"
+       "\xd5\x80\xd5\xb8\xd6\x82\xd5\xb6\xd5\xbe\xd5\xa1\xd6\x80\0"
+       "\xd5\x93\xd5\xa5\xd5\xbf\xd6\x80\xd5\xbe\xd5\xa1\xd6\x80\0"
        "\xd5\x84\xd5\xa1\xd6\x80\xd5\xbf\0"
        "\xd4\xb1\xd5\xba\xd6\x80\xd5\xab\xd5\xac\0"
        "\xd5\x84\xd5\xa1\xd5\xb5\xd5\xab\xd5\xbd\0"
-       "\xd5\x85\xd5\xb8\xd6\x82\xd5\xb6\xd5\xab\xd5\xbd\0"
-       "\xd5\x85\xd5\xb8\xd6\x82\xd5\xac\xd5\xab\xd5\xbd\0"
+       "\xd5\x80\xd5\xb8\xd6\x82\xd5\xb6\xd5\xab\xd5\xbd\0"
+       "\xd5\x80\xd5\xb8\xd6\x82\xd5\xac\xd5\xab\xd5\xbd\0"
        "\xd5\x95\xd5\xa3\xd5\xb8\xd5\xbd\xd5\xbf\xd5\xb8\xd5\xbd\0"
        "\xd5\x8d\xd5\xa5\xd5\xba\xd5\xbf\xd5\xa5\xd5\xb4\xd5\xa2\xd5\xa5\xd6\x80\0"
        "\xd5\x80\xd5\xb8\xd5\xaf\xd5\xbf\xd5\xa5\xd5\xb4\xd5\xa2\xd5\xa5\xd6\x80\0"
        "\xd5\x86\xd5\xb8\xd5\xb5\xd5\xa5\xd5\xb4\xd5\xa2\xd5\xa5\xd6\x80\0"
        "\xd4\xb4\xd5\xa5\xd5\xaf\xd5\xbf\xd5\xa5\xd5\xb4\xd5\xa2\xd5\xa5\xd6\x80\0"
-       "\xd5\x85\xd5\xb6\xd6\x80\0"
-       "\xd5\x93\xd5\xbf\xd6\x80\0"
+       "\xd5\x80\xd5\xb6\xd5\xbe\0"
+       "\xd5\x93\xd5\xbf\xd5\xbe\0"
        "\xd5\x84\xd6\x80\xd5\xbf\0"
        "\xd4\xb1\xd5\xba\xd6\x80\0"
        "\xd5\x84\xd5\xb5\xd5\xbd\0"
-       "\xd5\x85\xd5\xb6\xd5\xbd\0"
-       "\xd5\x85\xd5\xac\xd5\xbd\0"
+       "\xd5\x80\xd5\xb6\xd5\xbd\0"
+       "\xd5\x80\xd5\xac\xd5\xbd\0"
        "\xd5\x95\xd5\xa3\xd5\xbd\0"
        "\xd5\x8d\xd5\xa5\xd5\xba\0"
        "\xd5\x80\xd5\xb8\xd5\xaf\0"
        "\xd5\x86\xd5\xb8\xd5\xb5\0"
        "\xd4\xb4\xd5\xa5\xd5\xaf\0"
-       "MM/dd/yy\0"
+       "d/MM/yyyy\0"
+       "d/MMM/yyyy\0"
+       "dddd, dd MMMM yyyy\0"
+       "d-MMM-yyyy\0"
+       "dd-MMM-yyyy\0"
+       "ddd, d-MMMM-yyyy\0"
+       "ddd, dd-MMMM-yyyy\0"
+       "bazar\0"
+       "bazar ert\xc9\x99si\0"
+       "\xc3\xa7\xc9\x99r\xc5\x9f\xc9\x99nb\xc9\x99 ax\xc5\x9f\x61m\xc4\xb1\0"
+       "\xc3\xa7\xc9\x99r\xc5\x9f\xc9\x99nb\xc9\x99\0"
+       "c\xc3\xbcm\xc9\x99 ax\xc5\x9f\x61m\xc4\xb1\0"
+       "c\xc3\xbcm\xc9\x99\0"
+       "\xc5\x9f\xc9\x99nb\xc9\x99\0"
+       "B.\0"
+       "B.E.\0"
+       "\xc3\x87.A.\0"
+       "\xc3\x87.\0"
+       "C.A.\0"
+       "\xc5\x9e.\0"
+       "Yanvar\0"
+       "Fevral\0"
+       "Aprel\0"
+       "\xc4\xb0yun\0"
+       "\xc4\xb0yul\0"
+       "Avqust\0"
+       "Sentyabr\0"
+       "Oktyabr\0"
+       "Noyabr\0"
+       "Dekabr\0"
+       "yan\0"
+       "may\0"
+       "iyn\0"
+       "iyl\0"
+       "avq\0"
+       "sen\0"
+       "noy\0"
+       "dek\0"
+       "dddd, yyyy.'eko' MMMM'k 'd\0"
+       "yyyy.'eko' MMMM\0"
        "igandea\0"
        "astelehena\0"
        "asteartea\0"
@@ -2541,6 +3121,7 @@ static const char locale_strings [] = {
        "og\0"
        "or\0"
        "lr\0"
+       "I\0"
        "urtarrila\0"
        "otsaila\0"
        "martxoa\0"
@@ -2563,27 +3144,123 @@ static const char locale_strings [] = {
        "urr\0"
        "aza\0"
        "abe\0"
+       "\xd0\xbf\xd1\x80\xd0\xb5\xd1\x82\xd0\xbf\xd0\xbb\xd0\xb0\xd0\xb4\xd0\xbd\xd0\xb5\0"
+       "\xd0\xbf\xd0\xbe\xd0\xbf\xd0\xbb\xd0\xb0\xd0\xb4\xd0\xbd\xd0\xb5\0"
        "\xd0\xbd\xd0\xb5\xd0\xb4\xd0\xb5\xd0\xbb\xd0\xb0\0"
        "\xd1\x87\xd0\xb5\xd1\x82\xd0\xb2\xd1\x80\xd1\x82\xd0\xbe\xd0\xba\0"
        "\xd0\xbf\xd0\xb5\xd1\x82\xd0\xbe\xd0\xba\0"
        "\xd1\x81\xd0\xb0\xd0\xb1\xd0\xbe\xd1\x82\xd0\xb0\0"
+       "\xd0\xbd\xd0\xb5\xd0\xb4.\0"
+       "\xd0\xbf\xd0\xbe\xd0\xbd.\0"
+       "\xd0\xb2\xd1\x82.\0"
        "\xd1\x81\xd1\x80\xd0\xb5.\0"
        "\xd1\x87\xd0\xb5\xd1\x82.\0"
+       "\xd0\xbf\xd0\xb5\xd1\x82.\0"
        "\xd1\x81\xd0\xb0\xd0\xb1.\0"
        "\xd1\x98\xd0\xb0\xd0\xbd\xd1\x83\xd0\xb0\xd1\x80\xd0\xb8\0"
        "\xd0\xbc\xd0\xb0\xd1\x98\0"
        "\xd1\x98\xd1\x83\xd0\xbd\xd0\xb8\0"
        "\xd1\x98\xd1\x83\xd0\xbb\xd0\xb8\0"
        "\xd1\x98\xd0\xb0\xd0\xbd.\0"
+       "\xd1\x84\xd0\xb5\xd0\xb2.\0"
        "\xd0\xbc\xd0\xb0\xd1\x80.\0"
-       "\xd0\xbc\xd0\xb0\xd1\x98.\0"
        "\xd1\x98\xd1\x83\xd0\xbd.\0"
        "\xd1\x98\xd1\x83\xd0\xbb.\0"
-       "\xd1\x81\xd0\xb5\xd0\xbf\xd1\x82.\0"
        "\xd0\xb4\xd0\xb5\xd0\xba\xd0\xb5\xd0\xbc.\0"
-       "dd.M.yy\0"
-       "VM\0"
-       "NM\0"
+       "Tshipi\0"
+       "Mosopulogo\0"
+       "Labobedi\0"
+       "Laboraro\0"
+       "Labone\0"
+       "Labotlhano\0"
+       "Matlhatso\0"
+       "Tsh\0"
+       "Mos\0"
+       "Bed\0"
+       "Rar\0"
+       "Ne\0"
+       "Tla\0"
+       "Mat\0"
+       "Ferikgong\0"
+       "Tlhakole\0"
+       "Mopitlo\0"
+       "Moranang\0"
+       "Motsheganang\0"
+       "Seetebosigo\0"
+       "Phukwi\0"
+       "Phatwe\0"
+       "Lwetse\0"
+       "Diphalane\0"
+       "Ngwanatsele\0"
+       "Sedimonthole\0"
+       "Fer\0"
+       "Tlh\0"
+       "Mop\0"
+       "Mor\0"
+       "Mot\0"
+       "See\0"
+       "Phu\0"
+       "Pha\0"
+       "Lwe\0"
+       "Dip\0"
+       "Ngw\0"
+       "Sed\0"
+       "Cawe\0"
+       "Mvulo\0"
+       "Lwesibini\0"
+       "Lwesithathu\0"
+       "Lwesine\0"
+       "Lwesihlanu\0"
+       "Mgqibelo\0"
+       "Caw\0"
+       "Mvu\0"
+       "Bin\0"
+       "Tha\0"
+       "Sin\0"
+       "Hla\0"
+       "Mgq\0"
+       "Janyuwari\0"
+       "Februwari\0"
+       "Matshi\0"
+       "Epreli\0"
+       "Meyi\0"
+       "Julayi\0"
+       "Agasti\0"
+       "Septemba\0"
+       "Okthoba\0"
+       "Novemba\0"
+       "Disemba\0"
+       "Epr\0"
+       "Mey\0"
+       "Aga\0"
+       "Dis\0"
+       "Sonto\0"
+       "Msombuluko\0"
+       "Lwesibili\0"
+       "uLwesine\0"
+       "Son\0"
+       "Mso\0"
+       "Bil\0"
+       "B\0"
+       "uJanuwari\0"
+       "uFebruwari\0"
+       "uMashi\0"
+       "u-Apreli\0"
+       "uMeyi\0"
+       "uJuni\0"
+       "uJulayi\0"
+       "uAgasti\0"
+       "uSepthemba\0"
+       "u-Okthoba\0"
+       "uNovemba\0"
+       "uDisemba\0"
+       "Januwari\0"
+       "Mashi\0"
+       "Apreli\0"
+       "Septhemba\0"
+       "Mas\0"
+       "vm.\0"
+       "nm.\0"
        "Sondag\0"
        "Maandag\0"
        "Dinsdag\0"
@@ -2599,12 +3276,57 @@ static const char locale_strings [] = {
        "Junie\0"
        "Julie\0"
        "Augustus\0"
-       "y MMMM d HH:mm:ss z\0"
-       "y MMMM d\0"
-       "y MMMM\0"
+       "yyyy/MMM/dd\0"
+       "yyyy '\xe1\x83\xac\xe1\x83\x9a\xe1\x83\x98\xe1\x83\xa1' dd MM, dddd\0"
+       "dd MM\0"
        "\xe1\x83\x93\xe1\x83\x98\xe1\x83\x9a\xe1\x83\x98\xe1\x83\xa1\0"
        "\xe1\x83\xa1\xe1\x83\x90\xe1\x83\xa6\xe1\x83\x90\xe1\x83\x9b\xe1\x83\x9d\xe1\x83\xa1\0"
-       "d. MMM yyyy HH:mm:ss z\0"
+       "\xe1\x83\x99\xe1\x83\x95\xe1\x83\x98\xe1\x83\xa0\xe1\x83\x90\0"
+       "\xe1\x83\x9d\xe1\x83\xa0\xe1\x83\xa8\xe1\x83\x90\xe1\x83\x91\xe1\x83\x90\xe1\x83\x97\xe1\x83\x98\0"
+       "\xe1\x83\xa1\xe1\x83\x90\xe1\x83\x9b\xe1\x83\xa8\xe1\x83\x90\xe1\x83\x91\xe1\x83\x90\xe1\x83\x97\xe1\x83\x98\0"
+       "\xe1\x83\x9d\xe1\x83\x97\xe1\x83\xae\xe1\x83\xa8\xe1\x83\x90\xe1\x83\x91\xe1\x83\x90\xe1\x83\x97\xe1\x83\x98\0"
+       "\xe1\x83\xae\xe1\x83\xa3\xe1\x83\x97\xe1\x83\xa8\xe1\x83\x90\xe1\x83\x91\xe1\x83\x90\xe1\x83\x97\xe1\x83\x98\0"
+       "\xe1\x83\x9e\xe1\x83\x90\xe1\x83\xa0\xe1\x83\x90\xe1\x83\xa1\xe1\x83\x99\xe1\x83\x94\xe1\x83\x95\xe1\x83\x98\0"
+       "\xe1\x83\xa8\xe1\x83\x90\xe1\x83\x91\xe1\x83\x90\xe1\x83\x97\xe1\x83\x98\0"
+       "\xe1\x83\x99\xe1\x83\x95\xe1\x83\x98\0"
+       "\xe1\x83\x9d\xe1\x83\xa0\xe1\x83\xa8\0"
+       "\xe1\x83\xa1\xe1\x83\x90\xe1\x83\x9b\0"
+       "\xe1\x83\x9d\xe1\x83\x97\xe1\x83\xae\0"
+       "\xe1\x83\xae\xe1\x83\xa3\xe1\x83\x97\0"
+       "\xe1\x83\x9e\xe1\x83\x90\xe1\x83\xa0\0"
+       "\xe1\x83\xa8\xe1\x83\x90\xe1\x83\x91\0"
+       "\xe1\x83\x99\0"
+       "\xe1\x83\x9d\0"
+       "\xe1\x83\xa1\0"
+       "\xe1\x83\xae\0"
+       "\xe1\x83\x9e\0"
+       "\xe1\x83\xa8\0"
+       "\xe1\x83\x98\xe1\x83\x90\xe1\x83\x9c\xe1\x83\x95\xe1\x83\x90\xe1\x83\xa0\xe1\x83\x98\0"
+       "\xe1\x83\x97\xe1\x83\x94\xe1\x83\x91\xe1\x83\x94\xe1\x83\xa0\xe1\x83\x95\xe1\x83\x90\xe1\x83\x9a\xe1\x83\x98\0"
+       "\xe1\x83\x9b\xe1\x83\x90\xe1\x83\xa0\xe1\x83\xa2\xe1\x83\x98\0"
+       "\xe1\x83\x90\xe1\x83\x9e\xe1\x83\xa0\xe1\x83\x98\xe1\x83\x9a\xe1\x83\x98\0"
+       "\xe1\x83\x9b\xe1\x83\x90\xe1\x83\x98\xe1\x83\xa1\xe1\x83\x98\0"
+       "\xe1\x83\x98\xe1\x83\x95\xe1\x83\x9c\xe1\x83\x98\xe1\x83\xa1\xe1\x83\x98\0"
+       "\xe1\x83\x98\xe1\x83\x95\xe1\x83\x9a\xe1\x83\x98\xe1\x83\xa1\0"
+       "\xe1\x83\x90\xe1\x83\x92\xe1\x83\x95\xe1\x83\x98\xe1\x83\xa1\xe1\x83\xa2\xe1\x83\x9d\0"
+       "\xe1\x83\xa1\xe1\x83\x94\xe1\x83\xa5\xe1\x83\xa2\xe1\x83\x94\xe1\x83\x9b\xe1\x83\x91\xe1\x83\x94\xe1\x83\xa0\xe1\x83\x98\0"
+       "\xe1\x83\x9d\xe1\x83\xa5\xe1\x83\xa2\xe1\x83\x9d\xe1\x83\x9b\xe1\x83\x91\xe1\x83\x94\xe1\x83\xa0\xe1\x83\x98\0"
+       "\xe1\x83\x9c\xe1\x83\x9d\xe1\x83\x94\xe1\x83\x9b\xe1\x83\x91\xe1\x83\x94\xe1\x83\xa0\xe1\x83\x98\0"
+       "\xe1\x83\x93\xe1\x83\x94\xe1\x83\x99\xe1\x83\x94\xe1\x83\x9b\xe1\x83\x91\xe1\x83\x94\xe1\x83\xa0\xe1\x83\x98\0"
+       "\xe1\x83\x98\xe1\x83\x90\xe1\x83\x9c\0"
+       "\xe1\x83\x97\xe1\x83\x94\xe1\x83\x91\0"
+       "\xe1\x83\x9b\xe1\x83\x90\xe1\x83\xa0\0"
+       "\xe1\x83\x90\xe1\x83\x9e\xe1\x83\xa0\0"
+       "\xe1\x83\x9b\xe1\x83\x90\xe1\x83\x98\0"
+       "\xe1\x83\x98\xe1\x83\x95\xe1\x83\x9c\0"
+       "\xe1\x83\x98\xe1\x83\x95\xe1\x83\x9a\0"
+       "\xe1\x83\x90\xe1\x83\x92\xe1\x83\x95\0"
+       "\xe1\x83\xa1\xe1\x83\x94\xe1\x83\xa5\0"
+       "\xe1\x83\x9d\xe1\x83\xa5\xe1\x83\xa2\0"
+       "\xe1\x83\x9c\xe1\x83\x9d\xe1\x83\x94\0"
+       "\xe1\x83\x93\xe1\x83\x94\xe1\x83\x99\0"
+       "f.p.\0"
+       "s.p.\0"
        "m\xc3\xa1nadagur\0"
        "t\xc3\xbdsdagur\0"
        "mikudagur\0"
@@ -2622,16 +3344,23 @@ static const char locale_strings [] = {
        "\xe0\xa4\xb8\xe0\xa5\x8b\xe0\xa4\xae\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
        "\xe0\xa4\xae\xe0\xa4\x82\xe0\xa4\x97\xe0\xa4\xb2\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
        "\xe0\xa4\xac\xe0\xa5\x81\xe0\xa4\xa7\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
-       "\xe0\xa4\x97\xe0\xa5\x81\xe0\xa4\xb0\xe0\xa5\x81\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\xac\xe0\xa5\x83\xe0\xa4\xb9\xe0\xa4\xb8\xe0\xa5\x8d\xe0\xa4\xaa\xe0\xa4\xa4\xe0\xa4\xbf\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
        "\xe0\xa4\xb6\xe0\xa5\x81\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
        "\xe0\xa4\xb6\xe0\xa4\xa8\xe0\xa4\xbf\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
-       "\xe0\xa4\xb0\xe0\xa4\xb5\xe0\xa4\xbf\0"
-       "\xe0\xa4\xb8\xe0\xa5\x8b\xe0\xa4\xae\0"
-       "\xe0\xa4\xae\xe0\xa4\x82\xe0\xa4\x97\xe0\xa4\xb2\0"
-       "\xe0\xa4\xac\xe0\xa5\x81\xe0\xa4\xa7\0"
-       "\xe0\xa4\x97\xe0\xa5\x81\xe0\xa4\xb0\xe0\xa5\x81\0"
-       "\xe0\xa4\xb6\xe0\xa5\x81\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\xb0\0"
-       "\xe0\xa4\xb6\xe0\xa4\xa8\xe0\xa4\xbf\0"
+       "\xe0\xa4\xb0\xe0\xa4\xb5\xe0\xa4\xbf.\0"
+       "\xe0\xa4\xb8\xe0\xa5\x8b\xe0\xa4\xae.\0"
+       "\xe0\xa4\xae\xe0\xa4\x82\xe0\xa4\x97\xe0\xa4\xb2.\0"
+       "\xe0\xa4\xac\xe0\xa5\x81\xe0\xa4\xa7.\0"
+       "\xe0\xa4\xac\xe0\xa5\x83\xe0\xa4\xb9.\0"
+       "\xe0\xa4\xb6\xe0\xa5\x81\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\xb0.\0"
+       "\xe0\xa4\xb6\xe0\xa4\xa8\xe0\xa4\xbf.\0"
+       "\xe0\xa4\xb0\0"
+       "\xe0\xa4\xb8\xe0\xa5\x8b\0"
+       "\xe0\xa4\xae\xe0\xa4\x82\0"
+       "\xe0\xa4\xac\xe0\xa5\x81\0"
+       "\xe0\xa4\x97\xe0\xa5\x81\0"
+       "\xe0\xa4\xb6\xe0\xa5\x81\0"
+       "\xe0\xa4\xb6\0"
        "\xe0\xa4\x9c\xe0\xa4\xa8\xe0\xa4\xb5\xe0\xa4\xb0\xe0\xa5\x80\0"
        "\xe0\xa4\xab\xe0\xa4\xb0\xe0\xa4\xb5\xe0\xa4\xb0\xe0\xa5\x80\0"
        "\xe0\xa4\xae\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa5\x8d\xe0\xa4\x9a\0"
@@ -2644,6 +3373,183 @@ static const char locale_strings [] = {
        "\xe0\xa4\x85\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\xa4\xe0\xa5\x82\xe0\xa4\xac\xe0\xa4\xb0\0"
        "\xe0\xa4\xa8\xe0\xa4\xb5\xe0\xa4\xae\xe0\xa5\x8d\xe0\xa4\xac\xe0\xa4\xb0\0"
        "\xe0\xa4\xa6\xe0\xa4\xbf\xe0\xa4\xb8\xe0\xa4\xae\xe0\xa5\x8d\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "dddd, d' ta' 'MMMM yyyy\0"
+       "d' ta' 'MMMM\0"
+       "QN\0"
+       "WN\0"
+       "Il-\xc4\xa6\x61\x64\x64\0"
+       "It-Tnejn\0"
+       "It-Tlieta\0"
+       "L-Erbg\xc4\xa7\x61\0"
+       "Il-\xc4\xa6\x61mis\0"
+       "Il-\xc4\xa0img\xc4\xa7\x61\0"
+       "Is-Sibt\0"
+       "\xc4\xa6\x61\x64\0"
+       "Tne\0"
+       "Tli\0"
+       "Erb\0"
+       "\xc4\xa6\x61m\0"
+       "\xc4\xa0im\0"
+       "Sib\0"
+       "\xc4\xa6\0"
+       "\xc4\xa0\0"
+       "Jannar\0"
+       "Frar\0"
+       "Marzu\0"
+       "Mejju\0"
+       "\xc4\xa0unju\0"
+       "Lulju\0"
+       "Awwissu\0"
+       "Settembru\0"
+       "Ottubru\0"
+       "Novembru\0"
+       "Di\xc4\x8b\x65mbru\0"
+       "Fra\0"
+       "Mej\0"
+       "\xc4\xa0un\0"
+       "Lul\0"
+       "Aww\0"
+       "Set\0"
+       "Ott\0"
+       "Di\xc4\x8b\0"
+       "ddMMyyyy\0"
+       "d' ta' 'MMMM yyyy\0"
+       "MMMM d'. b. 'yyyy\0"
+       "MMMM d'. b. '\0"
+       "i.b.\0"
+       "e.b.\0"
+       "sotnabeaivi\0"
+       "vuoss\xc3\xa1rga\0"
+       "ma\xc5\x8b\xc5\x8b\x65\x62\xc3\xa1rga\0"
+       "gaskavahkku\0"
+       "duorasdat\0"
+       "bearjadat\0"
+       "l\xc3\xa1vvardat\0"
+       "sotn\0"
+       "vuos\0"
+       "ma\xc5\x8b\0"
+       "gask\0"
+       "duor\0"
+       "bear\0"
+       "l\xc3\xa1v\0"
+       "o\xc4\x91\xc4\x91\x61jagem\xc3\xa1nnu\0"
+       "guovvam\xc3\xa1nnu\0"
+       "njuk\xc4\x8d\x61m\xc3\xa1nnu\0"
+       "cuo\xc5\x8bom\xc3\xa1nnu\0"
+       "miessem\xc3\xa1nnu\0"
+       "geassem\xc3\xa1nnu\0"
+       "suoidnem\xc3\xa1nnu\0"
+       "borgem\xc3\xa1nnu\0"
+       "\xc4\x8d\x61k\xc4\x8d\x61m\xc3\xa1nnu\0"
+       "golggotm\xc3\xa1nnu\0"
+       "sk\xc3\xa1\x62mam\xc3\xa1nnu\0"
+       "juovlam\xc3\xa1nnu\0"
+       "o\xc4\x91\xc4\x91j\0"
+       "guov\0"
+       "njuk\0"
+       "cuo\0"
+       "mies\0"
+       "geas\0"
+       "suoi\0"
+       "borg\0"
+       "\xc4\x8d\x61k\xc4\x8d\0"
+       "golg\0"
+       "sk\xc3\xa1\x62\0"
+       "juov\0"
+       "D\xc3\xa9 Domhnaigh\0"
+       "D\xc3\xa9 Luain\0"
+       "D\xc3\xa9 M\xc3\xa1irt\0"
+       "D\xc3\xa9 C\xc3\xa9\x61\x64\x61oin\0"
+       "D\xc3\xa9\x61rdaoin\0"
+       "D\xc3\xa9 hAoine\0"
+       "D\xc3\xa9 Sathairn\0"
+       "Domh\0"
+       "Luan\0"
+       "M\xc3\xa1irt\0"
+       "C\xc3\xa9\x61\x64\0"
+       "D\xc3\xa9\x61r\0"
+       "Aoine\0"
+       "Sath\0"
+       "Ean\xc3\xa1ir\0"
+       "Feabhra\0"
+       "M\xc3\xa1rta\0"
+       "Aibre\xc3\xa1n\0"
+       "Bealtaine\0"
+       "Meitheamh\0"
+       "I\xc3\xbail\0"
+       "L\xc3\xbanasa\0"
+       "Me\xc3\xa1n F\xc3\xb3mhair\0"
+       "Deireadh F\xc3\xb3mhair\0"
+       "Samhain\0"
+       "Nollaig\0"
+       "Ean\0"
+       "Feabh\0"
+       "Aib\0"
+       "Beal\0"
+       "Meith\0"
+       "L\xc3\xban\0"
+       "MF\xc3\xb3mh\0"
+       "DF\xc3\xb3mh\0"
+       "Samh\0"
+       "Noll\0"
+       "pg\0"
+       "ptg\0"
+       "Ahad\0"
+       "Isnin\0"
+       "Khamis\0"
+       "Jumaat\0"
+       "Ahd\0"
+       "Isn\0"
+       "Kha\0"
+       "Mac\0"
+       "Julai\0"
+       "Ogos\0"
+       "Disember\0"
+       "d MMMM yyyy '\xd0\xb6.'\0"
+       "\xd0\xb6\xd0\xb5\xd0\xba\xd1\x81\xd0\xb5\xd0\xbd\xd1\x96\0"
+       "\xd0\xb4\xd1\x83\xd0\xb9\xd1\x81\xd0\xb5\xd0\xbd\xd0\xb1\xd1\x96\0"
+       "\xd1\x81\xd0\xb5\xd0\xb9\xd1\x81\xd0\xb5\xd0\xbd\xd0\xb1\xd1\x96\0"
+       "\xd1\x81\xd3\x99\xd1\x80\xd0\xb5\xd0\xbd\xd0\xb1\xd1\x96\0"
+       "\xd0\xb1\xd0\xb5\xd0\xb9\xd1\x81\xd0\xb5\xd0\xbd\xd0\xb1\xd1\x96\0"
+       "\xd0\xb6\xd2\xb1\xd0\xbc\xd0\xb0\0"
+       "\xd1\x81\xd0\xb5\xd0\xbd\xd0\xb1\xd1\x96\0"
+       "\xd0\xb6\xd1\x81.\0"
+       "\xd0\xb4\xd1\x81.\0"
+       "\xd1\x81\xd1\x81.\0"
+       "\xd1\x81\xd1\x80.\0"
+       "\xd0\xb1\xd1\x81.\0"
+       "\xd0\xb6\xd0\xbc.\0"
+       "\xd1\x81\xd0\xbd.\0"
+       "\xd2\x9b\xd0\xb0\xd2\xa3\xd1\x82\xd0\xb0\xd1\x80\0"
+       "\xd0\x90\xd2\x9b\xd0\xbf\xd0\xb0\xd0\xbd\0"
+       "\xd0\xbd\xd0\xb0\xd1\x83\xd1\x80\xd1\x8b\xd0\xb7\0"
+       "\xd1\x81\xd3\x99\xd1\x83\xd1\x96\xd1\x80\0"
+       "\xd0\xbc\xd0\xb0\xd0\xbc\xd1\x8b\xd1\x80\0"
+       "\xd0\xbc\xd0\xb0\xd1\x83\xd1\x81\xd1\x8b\xd0\xbc\0"
+       "\xd1\x88\xd1\x96\xd0\xbb\xd0\xb4\xd0\xb5\0"
+       "\xd1\x82\xd0\xb0\xd0\xbc\xd1\x8b\xd0\xb7\0"
+       "\xd2\x9b\xd1\x8b\xd1\x80\xd0\xba\xd2\xaf\xd0\xb9\xd0\xb5\xd0\xba\0"
+       "\xd2\x9b\xd0\xb0\xd0\xb7\xd0\xb0\xd0\xbd\0"
+       "\xd2\x9b\xd0\xb0\xd1\x80\xd0\xb0\xd1\x88\xd0\xb0\0"
+       "\xd0\xb6\xd0\xb5\xd0\xbb\xd1\x82\xd0\xbe\xd2\x9b\xd1\x81\xd0\xb0\xd0\xbd\0"
+       "\xd0\xb0\xd2\x9b\xd0\xbf\xd0\xb0\xd0\xbd\0"
+       "\xd2\x9b\xd0\xb0\xd2\xa3.\0"
+       "\xd0\xb0\xd2\x9b\xd0\xbf.\0"
+       "\xd0\xbd\xd0\xb0\xd1\x83.\0"
+       "\xd1\x81\xd3\x99\xd1\x83.\0"
+       "\xd0\xbc\xd0\xb0\xd0\xbc.\0"
+       "\xd0\xbc\xd0\xb0\xd1\x83.\0"
+       "\xd1\x88\xd1\x96\xd0\xbb.\0"
+       "\xd1\x82\xd0\xb0\xd0\xbc.\0"
+       "\xd2\x9b\xd1\x8b\xd1\x80.\0"
+       "\xd2\x9b\xd0\xb0\xd0\xb7.\0"
+       "\xd2\x9b\xd0\xb0\xd1\x80.\0"
+       "\xd0\xb6\xd0\xb5\xd0\xbb\xd1\x82.\0"
+       "dd MMMM yyyy '\xd0\xb6.'\0"
+       "d'-'MMMM yyyy'-\xd0\xb6.'\0"
+       "MMMM yyyy'-\xd0\xb6.'\0"
+       "asubuhi\0"
+       "alasiri\0"
        "Jumapili\0"
        "Jumatatu\0"
        "Jumanne\0"
@@ -2651,24 +3557,116 @@ static const char locale_strings [] = {
        "Alhamisi\0"
        "Ijumaa\0"
        "Jumamosi\0"
-       "Jpi\0"
-       "Jtt\0"
-       "Jnn\0"
-       "Jtn\0"
+       "J2\0"
+       "J3\0"
+       "J4\0"
+       "J5\0"
        "Alh\0"
-       "Iju\0"
-       "Jmo\0"
+       "Ij\0"
+       "J1\0"
        "Machi\0"
        "Aprili\0"
-       "Julai\0"
        "Agosti\0"
-       "Septemba\0"
        "Oktoba\0"
-       "Novemba\0"
        "Desemba\0"
        "Ago\0"
-       "\xe0\xaa\xaa\xe0\xab\x82\xe0\xaa\xb0\xe0\xab\x8d\xe0\xaa\xb5\xc2\xa0\xe0\xaa\xae\xe0\xaa\xa7\xe0\xab\x8d\xe0\xaa\xaf\xe0\xaa\xbe\xe0\xaa\xb9\xe0\xab\x8d\xe0\xaa\xa8\0"
-       "\xe0\xaa\x89\xe0\xaa\xa4\xe0\xab\x8d\xe0\xaa\xa4\xe0\xaa\xb0\xc2\xa0\xe0\xaa\xae\xe0\xaa\xa7\xe0\xab\x8d\xe0\xaa\xaf\xe0\xaa\xbe\xe0\xaa\xb9\xe0\xab\x8d\xe0\xaa\xa8\0"
+       "yyyy 'yil' d-MMMM\0"
+       "dd/MM yyyy\0"
+       "d-MMMM\0"
+       "\xd1\x8f\xd0\xba\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb0\0"
+       "\xd0\xb4\xd1\x83\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb0\0"
+       "\xd1\x81\xd0\xb5\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb0\0"
+       "\xd1\x87\xd0\xbe\xd1\x80\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb0\0"
+       "\xd0\xbf\xd0\xb0\xd0\xb9\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb0\0"
+       "\xd0\xb6\xd1\x83\xd0\xbc\xd0\xb0\0"
+       "\xd1\x88\xd0\xb0\xd0\xbd\xd0\xb1\xd0\xb0\0"
+       "\xd0\xaf\xd0\xba\xd1\x88\0"
+       "\xd0\x94\xd1\x83\xd1\x88\0"
+       "\xd0\xa1\xd0\xb5\xd1\x88\0"
+       "\xd0\xa7\xd0\xbe\xd1\x80\0"
+       "\xd0\x9f\xd0\xb0\xd0\xb9\0"
+       "\xd0\x96\xd1\x83\xd0\xbc\0"
+       "\xd0\xa8\xd0\xb0\xd0\xbd\0"
+       "\xd0\xaf\0"
+       "\xd0\x94\0"
+       "\xd0\x96\0"
+       "\xd0\xa8\0"
+       "\xe0\xa6\xaa\xe0\xa7\x82\xe0\xa6\xb0\xe0\xa7\x8d\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\xb9\xe0\xa7\x8d\xe0\xa6\xa3\0"
+       "\xe0\xa6\x85\xe0\xa6\xaa\xe0\xa6\xb0\xe0\xa6\xbe\xe0\xa6\xb9\xe0\xa7\x8d\xe0\xa6\xa3\0"
+       "\xe0\xa6\xb0\xe0\xa6\xac\xe0\xa6\xbf\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\xb0\0"
+       "\xe0\xa6\xb8\xe0\xa7\x8b\xe0\xa6\xae\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\xb0\0"
+       "\xe0\xa6\xae\xe0\xa6\x99\xe0\xa7\x8d\xe0\xa6\x97\xe0\xa6\xb2\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\xb0\0"
+       "\xe0\xa6\xac\xe0\xa7\x81\xe0\xa6\xa7\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\xb0\0"
+       "\xe0\xa6\xac\xe0\xa7\x83\xe0\xa6\xb9\xe0\xa6\xb7\xe0\xa7\x8d\xe0\xa6\xaa\xe0\xa6\xa4\xe0\xa6\xbf\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\xb0\0"
+       "\xe0\xa6\xb6\xe0\xa7\x81\xe0\xa6\x95\xe0\xa7\x8d\xe0\xa6\xb0\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\xb0\0"
+       "\xe0\xa6\xb6\xe0\xa6\xa8\xe0\xa6\xbf\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\xb0\0"
+       "\xe0\xa6\xb0\xe0\xa6\xac\xe0\xa6\xbf\0"
+       "\xe0\xa6\xb8\xe0\xa7\x8b\xe0\xa6\xae\0"
+       "\xe0\xa6\xae\xe0\xa6\x99\xe0\xa7\x8d\xe0\xa6\x97\xe0\xa6\xb2\0"
+       "\xe0\xa6\xac\xe0\xa7\x81\xe0\xa6\xa7\0"
+       "\xe0\xa6\xac\xe0\xa7\x83\xe0\xa6\xb9\xe0\xa6\xb8\xe0\xa7\x8d\xe0\xa6\xaa\xe0\xa6\xa4\xe0\xa6\xbf\0"
+       "\xe0\xa6\xb6\xe0\xa7\x81\xe0\xa6\x95\xe0\xa7\x8d\xe0\xa6\xb0\0"
+       "\xe0\xa6\xb6\xe0\xa6\xa8\xe0\xa6\xbf\0"
+       "\xe0\xa6\xb0\0"
+       "\xe0\xa6\xb8\xe0\xa7\x8b\0"
+       "\xe0\xa6\xae\0"
+       "\xe0\xa6\xac\xe0\xa7\x81\0"
+       "\xe0\xa6\xac\xe0\xa7\x83\0"
+       "\xe0\xa6\xb6\xe0\xa7\x81\0"
+       "\xe0\xa6\xb6\0"
+       "\xe0\xa6\x9c\xe0\xa6\xbe\xe0\xa6\xa8\xe0\xa7\x81\xe0\xa6\xaf\xe0\xa6\xbc\xe0\xa6\xbe\xe0\xa6\xb0\xe0\xa7\x80\0"
+       "\xe0\xa6\xab\xe0\xa7\x87\xe0\xa6\xac\xe0\xa7\x8d\xe0\xa6\xb0\xe0\xa7\x81\xe0\xa6\xaf\xe0\xa6\xbc\xe0\xa6\xbe\xe0\xa6\xb0\xe0\xa7\x80\0"
+       "\xe0\xa6\xae\xe0\xa6\xbe\xe0\xa6\xb0\xe0\xa7\x8d\xe0\xa6\x9a\0"
+       "\xe0\xa6\x8f\xe0\xa6\xaa\xe0\xa7\x8d\xe0\xa6\xb0\xe0\xa6\xbf\xe0\xa6\xb2\0"
+       "\xe0\xa6\xae\xe0\xa7\x87\0"
+       "\xe0\xa6\x9c\xe0\xa7\x81\xe0\xa6\xa8\0"
+       "\xe0\xa6\x9c\xe0\xa7\x81\xe0\xa6\xb2\xe0\xa6\xbe\xe0\xa6\x87\0"
+       "\xe0\xa6\x86\xe0\xa6\x97\xe0\xa6\xb8\xe0\xa7\x8d\xe0\xa6\x9f\0"
+       "\xe0\xa6\xb8\xe0\xa7\x87\xe0\xa6\xaa\xe0\xa7\x8d\xe0\xa6\x9f\xe0\xa7\x87\xe0\xa6\xae\xe0\xa7\x8d\xe0\xa6\xac\xe0\xa6\xb0\0"
+       "\xe0\xa6\x85\xe0\xa6\x95\xe0\xa7\x8d\xe0\xa6\x9f\xe0\xa7\x8b\xe0\xa6\xac\xe0\xa6\xb0\0"
+       "\xe0\xa6\xa8\xe0\xa6\xad\xe0\xa7\x87\xe0\xa6\xae\xe0\xa7\x8d\xe0\xa6\xac\xe0\xa6\xb0\0"
+       "\xe0\xa6\xa1\xe0\xa6\xbf\xe0\xa6\xb8\xe0\xa7\x87\xe0\xa6\xae\xe0\xa7\x8d\xe0\xa6\xac\xe0\xa6\xb0\0"
+       "tt hh.mm\0"
+       "tt h.mm\0"
+       "tt hh.mm.ss\0"
+       "tt h.mm.ss\0"
+       "\xe0\xa8\xaa\xe0\xa9\x82\xe0\xa8\xb0\xe0\xa8\xb5 \xe0\xa8\xa6\xe0\xa9\x81\xe0\xa8\xaa\xe0\xa8\xb9\xe0\xa8\xbf\xe0\xa8\xb0\0"
+       "\xe0\xa8\xac\xe0\xa8\xbe\xe0\xa8\x85\xe0\xa8\xa6 \xe0\xa8\xa6\xe0\xa9\x81\xe0\xa8\xaa\xe0\xa8\xb9\xe0\xa8\xbf\xe0\xa8\xb0\0"
+       "\xe0\xa8\x90\xe0\xa8\xa4\xe0\xa8\xb5\xe0\xa8\xbe\xe0\xa8\xb0\0"
+       "\xe0\xa8\xb8\xe0\xa9\x8b\xe0\xa8\xae\xe0\xa8\xb5\xe0\xa8\xbe\xe0\xa8\xb0\0"
+       "\xe0\xa8\xae\xe0\xa9\xb0\xe0\xa8\x97\xe0\xa8\xb2\xe0\xa8\xb5\xe0\xa8\xbe\xe0\xa8\xb0\0"
+       "\xe0\xa8\xac\xe0\xa9\x81\xe0\xa8\xa7\xe0\xa8\xb5\xe0\xa8\xbe\xe0\xa8\xb0\0"
+       "\xe0\xa8\xb5\xe0\xa9\x80\xe0\xa8\xb0\xe0\xa8\xb5\xe0\xa8\xbe\xe0\xa8\xb0\0"
+       "\xe0\xa8\xb8\xe0\xa8\xbc\xe0\xa9\x81\xe0\xa9\xb1\xe0\xa8\x95\xe0\xa8\xb0\xe0\xa8\xb5\xe0\xa8\xbe\xe0\xa8\xb0\0"
+       "\xe0\xa8\xb8\xe0\xa8\xbc\xe0\xa8\xa8\xe0\xa9\x80\xe0\xa8\x9a\xe0\xa8\xb0\xe0\xa8\xb5\xe0\xa8\xbe\xe0\xa8\xb0\0"
+       "\xe0\xa8\x90\xe0\xa8\xa4.\0"
+       "\xe0\xa8\xb8\xe0\xa9\x8b\xe0\xa8\xae.\0"
+       "\xe0\xa8\xae\xe0\xa9\xb0\xe0\xa8\x97\xe0\xa8\xb2.\0"
+       "\xe0\xa8\xac\xe0\xa9\x81\xe0\xa8\xa7.\0"
+       "\xe0\xa8\xb5\xe0\xa9\x80\xe0\xa8\xb0.\0"
+       "\xe0\xa8\xb8\xe0\xa8\xbc\xe0\xa9\x81\xe0\xa8\x95\xe0\xa8\xb0.\0"
+       "\xe0\xa8\xb8\xe0\xa8\xbc\xe0\xa8\xa8\xe0\xa9\x80.\0"
+       "\xe0\xa8\x90\0"
+       "\xe0\xa8\xb8\xe0\xa9\x8b\0"
+       "\xe0\xa8\xae\xe0\xa9\xb0\0"
+       "\xe0\xa8\xac\xe0\xa9\x81\xe0\xa9\xb1\0"
+       "\xe0\xa8\xb5\xe0\xa9\x80\0"
+       "\xe0\xa8\xb8\xe0\xa8\xbc\xe0\xa9\x81\xe0\xa9\xb1\0"
+       "\xe0\xa8\xb8\xe0\xa8\xbc\0"
+       "\xe0\xa8\x9c\xe0\xa8\xa8\xe0\xa8\xb5\xe0\xa8\xb0\xe0\xa9\x80\0"
+       "\xe0\xa8\xab\xe0\xa8\xbc\xe0\xa8\xb0\xe0\xa8\xb5\xe0\xa8\xb0\xe0\xa9\x80\0"
+       "\xe0\xa8\xae\xe0\xa8\xbe\xe0\xa8\xb0\xe0\xa8\x9a\0"
+       "\xe0\xa8\x85\xe0\xa8\xaa\xe0\xa9\x8d\xe0\xa8\xb0\xe0\xa9\x88\xe0\xa8\xb2\0"
+       "\xe0\xa8\xae\xe0\xa8\x88\0"
+       "\xe0\xa8\x9c\xe0\xa9\x82\xe0\xa8\xa8\0"
+       "\xe0\xa8\x9c\xe0\xa9\x81\xe0\xa8\xb2\xe0\xa8\xbe\xe0\xa8\x88\0"
+       "\xe0\xa8\x85\xe0\xa8\x97\xe0\xa8\xb8\xe0\xa8\xa4\0"
+       "\xe0\xa8\xb8\xe0\xa8\xa4\xe0\xa9\xb0\xe0\xa8\xac\xe0\xa8\xb0\0"
+       "\xe0\xa8\x85\xe0\xa8\x95\xe0\xa8\xa4\xe0\xa9\x82\xe0\xa8\xac\xe0\xa8\xb0\0"
+       "\xe0\xa8\xa8\xe0\xa8\xb5\xe0\xa9\xb0\xe0\xa8\xac\xe0\xa8\xb0\0"
+       "\xe0\xa8\xa6\xe0\xa8\xb8\xe0\xa9\xb0\xe0\xa8\xac\xe0\xa8\xb0\0"
+       "\xe0\xaa\xaa\xe0\xab\x82\xe0\xaa\xb0\xe0\xab\x8d\xe0\xaa\xb5 \xe0\xaa\xae\xe0\xaa\xa7\xe0\xab\x8d\xe0\xaa\xaf\xe0\xaa\xbe\xe0\xaa\xb9\xe0\xab\x8d\xe0\xaa\xa8\0"
+       "\xe0\xaa\x89\xe0\xaa\xa4\xe0\xab\x8d\xe0\xaa\xa4\xe0\xaa\xb0 \xe0\xaa\xae\xe0\xaa\xa7\xe0\xab\x8d\xe0\xaa\xaf\xe0\xaa\xbe\xe0\xaa\xb9\xe0\xab\x8d\xe0\xaa\xa8\0"
        "\xe0\xaa\xb0\xe0\xaa\xb5\xe0\xaa\xbf\xe0\xaa\xb5\xe0\xaa\xbe\xe0\xaa\xb0\0"
        "\xe0\xaa\xb8\xe0\xab\x8b\xe0\xaa\xae\xe0\xaa\xb5\xe0\xaa\xbe\xe0\xaa\xb0\0"
        "\xe0\xaa\xae\xe0\xaa\x82\xe0\xaa\x97\xe0\xaa\xb3\xe0\xaa\xb5\xe0\xaa\xbe\xe0\xaa\xb0\0"
@@ -2683,6 +3681,13 @@ static const char locale_strings [] = {
        "\xe0\xaa\x97\xe0\xab\x81\xe0\xaa\xb0\xe0\xab\x81\0"
        "\xe0\xaa\xb6\xe0\xab\x81\xe0\xaa\x95\xe0\xab\x8d\xe0\xaa\xb0\0"
        "\xe0\xaa\xb6\xe0\xaa\xa8\xe0\xaa\xbf\0"
+       "\xe0\xaa\xb0\0"
+       "\xe0\xaa\xb8\xe0\xab\x8b\0"
+       "\xe0\xaa\xae\xe0\xaa\x82\0"
+       "\xe0\xaa\xac\xe0\xab\x81\0"
+       "\xe0\xaa\x97\xe0\xab\x81\0"
+       "\xe0\xaa\xb6\xe0\xab\x81\0"
+       "\xe0\xaa\xb6\0"
        "\xe0\xaa\x9c\xe0\xaa\xbe\xe0\xaa\xa8\xe0\xab\x8d\xe0\xaa\xaf\xe0\xab\x81\xe0\xaa\x86\xe0\xaa\xb0\xe0\xab\x80\0"
        "\xe0\xaa\xab\xe0\xab\x87\xe0\xaa\xac\xe0\xab\x8d\xe0\xaa\xb0\xe0\xab\x81\xe0\xaa\x86\xe0\xaa\xb0\xe0\xab\x80\0"
        "\xe0\xaa\xae\xe0\xaa\xbe\xe0\xaa\xb0\xe0\xab\x8d\xe0\xaa\x9a\0"
@@ -2701,8 +3706,42 @@ static const char locale_strings [] = {
        "\xe0\xaa\x91\xe0\xaa\x95\xe0\xab\x8d\xe0\xaa\x9f\xe0\xab\x8b\0"
        "\xe0\xaa\xa8\xe0\xaa\xb5\xe0\xab\x87\0"
        "\xe0\xaa\xa1\xe0\xaa\xbf\xe0\xaa\xb8\xe0\xab\x87\0"
-       "\xe0\xae\x95\xe0\xae\xbe\xe0\xae\xb2\xe0\xaf\x88\0"
-       "\xe0\xae\xae\xe0\xae\xbe\xe0\xae\xb2\xe0\xaf\x88\0"
+       "pm\0"
+       "\xe0\xac\xb0\xe0\xac\xac\xe0\xac\xbf\xe0\xac\xac\xe0\xac\xbe\xe0\xac\xb0\0"
+       "\xe0\xac\xb8\xe0\xad\x8b\xe0\xac\xae\xe0\xac\xac\xe0\xac\xbe\xe0\xac\xb0\0"
+       "\xe0\xac\xae\xe0\xac\x99\xe0\xad\x8d\xe0\xac\x97\xe0\xac\xb3\xe0\xac\xac\xe0\xac\xbe\xe0\xac\xb0\0"
+       "\xe0\xac\xac\xe0\xad\x81\xe0\xac\xa7\xe0\xac\xac\xe0\xac\xbe\xe0\xac\xb0\0"
+       "\xe0\xac\x97\xe0\xad\x81\xe0\xac\xb0\xe0\xad\x81\xe0\xac\xac\xe0\xac\xbe\xe0\xac\xb0\0"
+       "\xe0\xac\xb6\xe0\xad\x81\xe0\xac\x95\xe0\xad\x8d\xe0\xac\xb0\xe0\xac\xac\xe0\xac\xbe\xe0\xac\xb0\0"
+       "\xe0\xac\xb6\xe0\xac\xa8\xe0\xac\xbf\xe0\xac\xac\xe0\xac\xbe\xe0\xac\xb0\0"
+       "\xe0\xac\xb0\xe0\xac\xac\xe0\xac\xbf\0"
+       "\xe0\xac\xb8\xe0\xad\x8b\xe0\xac\xae\0"
+       "\xe0\xac\xae\xe0\xac\x99\xe0\xad\x8d\xe0\xac\x97\xe0\xac\xb3\0"
+       "\xe0\xac\xac\xe0\xad\x81\xe0\xac\xa7\0"
+       "\xe0\xac\x97\xe0\xad\x81\xe0\xac\xb0\xe0\xad\x81\0"
+       "\xe0\xac\xb6\xe0\xad\x81\xe0\xac\x95\xe0\xad\x8d\xe0\xac\xb0\0"
+       "\xe0\xac\xb6\xe0\xac\xa8\xe0\xac\xbf\0"
+       "\xe0\xac\xb0\0"
+       "\xe0\xac\xb8\xe0\xad\x8b\0"
+       "\xe0\xac\xae\0"
+       "\xe0\xac\xac\xe0\xad\x81\0"
+       "\xe0\xac\x97\xe0\xad\x81\0"
+       "\xe0\xac\xb6\xe0\xad\x81\0"
+       "\xe0\xac\xb6\0"
+       "\xe0\xac\x9c\xe0\xac\xbe\xe0\xac\xa8\xe0\xad\x81\xe0\xac\x86\xe0\xac\xb0\xe0\xad\x80\0"
+       "\xe0\xac\xab\xe0\xad\x87\xe0\xac\xac\xe0\xad\x8d\xe0\xac\xb0\xe0\xad\x81\xe0\xad\x9f\xe0\xac\xbe\xe0\xac\xb0\xe0\xad\x80\0"
+       "\xe0\xac\xae\xe0\xac\xbe\xe0\xac\xb0\xe0\xad\x8d\xe0\xac\x9a\xe0\xad\x8d\xe0\xac\x9a\0"
+       "\xe0\xac\x85\xe0\xac\xaa\xe0\xad\x8d\xe0\xac\xb0\xe0\xad\x87\xe0\xac\xb2\0"
+       "\xe0\xac\xae\xe0\xad\x87\0"
+       "\xe0\xac\x9c\xe0\xad\x81\xe0\xac\xa8\0"
+       "\xe0\xac\x9c\xe0\xad\x81\xe0\xac\xb2\xe0\xac\xbe\xe0\xac\x87\0"
+       "\xe0\xac\x85\xe0\xac\x97\xe0\xac\xb7\xe0\xad\x8d\xe0\xac\x9f\0"
+       "\xe0\xac\xb8\xe0\xad\x87\xe0\xac\xaa\xe0\xad\x8d\xe0\xac\x9f\xe0\xad\x87\xe0\xac\xae\xe0\xad\x8d\xe0\xac\xac\xe0\xac\xb0\0"
+       "\xe0\xac\x85\xe0\xac\x95\xe0\xad\x8d\xe0\xac\x9f\xe0\xad\x8b\xe0\xac\xac\xe0\xac\xb0\0"
+       "\xe0\xac\xa8\xe0\xac\xad\xe0\xad\x87\xe0\xac\xae\xe0\xad\x8d\xe0\xac\xac\xe0\xac\xb0\0"
+       "\xe0\xac\xa1\xe0\xac\xbf\xe0\xac\xb8\xe0\xad\x87\xe0\xac\xae\xe0\xad\x8d\xe0\xac\xac\xe0\xac\xb0\0"
+       "\xe0\xae\xae\xe0\xaf\x81\xe0\xae\xb1\xe0\xaf\x8d\xe0\xae\xaa\xe0\xae\x95\xe0\xae\xb2\xe0\xaf\x8d\0"
+       "\xe0\xae\xaa\xe0\xae\xbf\xe0\xae\xb1\xe0\xaf\x8d\xe0\xae\xaa\xe0\xae\x95\xe0\xae\xb2\xe0\xaf\x8d\0"
        "\xe0\xae\x9e\xe0\xae\xbe\xe0\xae\xaf\xe0\xae\xbf\xe0\xae\xb1\xe0\xaf\x81\0"
        "\xe0\xae\xa4\xe0\xae\xbf\xe0\xae\x99\xe0\xaf\x8d\xe0\xae\x95\xe0\xae\xb3\xe0\xaf\x8d\0"
        "\xe0\xae\x9a\xe0\xaf\x86\xe0\xae\xb5\xe0\xaf\x8d\xe0\xae\xb5\xe0\xae\xbe\xe0\xae\xaf\xe0\xaf\x8d\0"
@@ -2724,11 +3763,12 @@ static const char locale_strings [] = {
        "\xe0\xae\xae\xe0\xaf\x87\0"
        "\xe0\xae\x9c\xe0\xaf\x82\xe0\xae\xa9\xe0\xaf\x8d\0"
        "\xe0\xae\x9c\xe0\xaf\x82\xe0\xae\xb2\xe0\xaf\x88\0"
-       "\xe0\xae\x86\xe0\xae\x95\xe0\xae\xb8\xe0\xaf\x8d\xe0\xae\x9f\xe0\xaf\x8d\0"
+       "\xe0\xae\x86\xe0\xae\x95\xe0\xae\xb8\xe0\xaf\x8d\xe0\xae\x9f\xe0\xaf\x81\0"
        "\xe0\xae\x9a\xe0\xaf\x86\xe0\xae\xaa\xe0\xaf\x8d\xe0\xae\x9f\xe0\xae\xae\xe0\xaf\x8d\xe0\xae\xaa\xe0\xae\xb0\xe0\xaf\x8d\0"
        "\xe0\xae\x85\xe0\xae\x95\xe0\xaf\x8d\xe0\xae\x9f\xe0\xaf\x8b\xe0\xae\xaa\xe0\xae\xb0\xe0\xaf\x8d\0"
        "\xe0\xae\xa8\xe0\xae\xb5\xe0\xae\xae\xe0\xaf\x8d\xe0\xae\xaa\xe0\xae\xb0\xe0\xaf\x8d\0"
        "\xe0\xae\x9f\xe0\xae\xbf\xe0\xae\x9a\xe0\xae\xae\xe0\xaf\x8d\xe0\xae\xaa\xe0\xae\xb0\xe0\xaf\x8d\0"
+       "\xe0\xae\x86\xe0\xae\x95\xe0\xae\xb8\xe0\xaf\x8d\xe0\xae\x9f\xe0\xaf\x8d\0"
        "\xe0\xae\x9c\xe0\xae\xa9.\0"
        "\xe0\xae\xaa\xe0\xae\xbf\xe0\xae\xaa\xe0\xaf\x8d.\0"
        "\xe0\xae\xae\xe0\xae\xbe\xe0\xae\xb0\xe0\xaf\x8d.\0"
@@ -2738,8 +3778,8 @@ static const char locale_strings [] = {
        "\xe0\xae\x85\xe0\xae\x95\xe0\xaf\x8d.\0"
        "\xe0\xae\xa8\xe0\xae\xb5.\0"
        "\xe0\xae\x9f\xe0\xae\xbf\xe0\xae\x9a.\0"
-       "\xe0\xb0\xaa\xe0\xb1\x82\xe0\xb0\xb0\xe0\xb1\x8d\xe0\xb0\xb5\xe0\xb0\xbe\xe0\xb0\xb9\xe0\xb1\x8d\xe0\xb0\xa8\0"
-       "\xe0\xb0\x85\xe0\xb0\xaa\xe0\xb0\xb0\xe0\xb0\xbe\xe0\xb0\xb9\xe0\xb1\x8d\xe0\xb0\xa8\0"
+       "\xe0\xb0\xaa\xe0\xb1\x82\xe0\xb0\xb0\xe0\xb1\x8d\xe0\xb0\xb5\xe0\xb0\xbe\xe0\xb0\xb9\xe0\xb1\x8d\xe0\xb0\xa8\xe0\xb0\x82\0"
+       "\xe0\xb0\x85\xe0\xb0\xaa\xe0\xb0\xb0\xe0\xb0\xbe\xe0\xb0\xb9\xe0\xb1\x8d\xe0\xb0\xa8\xe0\xb0\x82\0"
        "\xe0\xb0\x86\xe0\xb0\xa6\xe0\xb0\xbf\xe0\xb0\xb5\xe0\xb0\xbe\xe0\xb0\xb0\xe0\xb0\x82\0"
        "\xe0\xb0\xb8\xe0\xb1\x8b\xe0\xb0\xae\xe0\xb0\xb5\xe0\xb0\xbe\xe0\xb0\xb0\xe0\xb0\x82\0"
        "\xe0\xb0\xae\xe0\xb0\x82\xe0\xb0\x97\xe0\xb0\xb3\xe0\xb0\xb5\xe0\xb0\xbe\xe0\xb0\xb0\xe0\xb0\x82\0"
@@ -2754,10 +3794,17 @@ static const char locale_strings [] = {
        "\xe0\xb0\x97\xe0\xb1\x81\xe0\xb0\xb0\xe0\xb1\x81\0"
        "\xe0\xb0\xb6\xe0\xb1\x81\xe0\xb0\x95\xe0\xb1\x8d\xe0\xb0\xb0\0"
        "\xe0\xb0\xb6\xe0\xb0\xa8\xe0\xb0\xbf\0"
+       "\xe0\xb0\x86\0"
+       "\xe0\xb0\xb8\xe0\xb1\x8b\0"
+       "\xe0\xb0\xae\0"
+       "\xe0\xb0\xac\xe0\xb1\x81\0"
+       "\xe0\xb0\x97\xe0\xb1\x81\0"
+       "\xe0\xb0\xb6\xe0\xb1\x81\0"
+       "\xe0\xb0\xb6\0"
        "\xe0\xb0\x9c\xe0\xb0\xa8\xe0\xb0\xb5\xe0\xb0\xb0\xe0\xb0\xbf\0"
        "\xe0\xb0\xab\xe0\xb0\xbf\xe0\xb0\xac\xe0\xb1\x8d\xe0\xb0\xb0\xe0\xb0\xb5\xe0\xb0\xb0\xe0\xb0\xbf\0"
        "\xe0\xb0\xae\xe0\xb0\xbe\xe0\xb0\xb0\xe0\xb1\x8d\xe0\xb0\x9a\xe0\xb0\xbf\0"
-       "\xe0\xb0\x8f\xe0\xb0\xaa\xe0\xb1\x8d\xe0\xb0\xb0\xe0\xb0\xbf\xe0\xb0\xb2\xe0\xb1\x8d\0"
+       "\xe0\xb0\x8e\xe0\xb0\xaa\xe0\xb1\x8d\xe0\xb0\xb0\xe0\xb0\xbf\xe0\xb0\xb2\xe0\xb1\x8d\0"
        "\xe0\xb0\xae\xe0\xb1\x87\0"
        "\xe0\xb0\x9c\xe0\xb1\x82\xe0\xb0\xa8\xe0\xb1\x8d\0"
        "\xe0\xb0\x9c\xe0\xb1\x82\xe0\xb0\xb2\xe0\xb1\x88\0"
@@ -2766,8 +3813,9 @@ static const char locale_strings [] = {
        "\xe0\xb0\x85\xe0\xb0\x95\xe0\xb1\x8d\xe0\xb0\x9f\xe0\xb1\x8b\xe0\xb0\xac\xe0\xb0\xb0\xe0\xb1\x8d\0"
        "\xe0\xb0\xa8\xe0\xb0\xb5\xe0\xb0\x82\xe0\xb0\xac\xe0\xb0\xb0\xe0\xb1\x8d\0"
        "\xe0\xb0\xa1\xe0\xb0\xbf\xe0\xb0\xb8\xe0\xb1\x86\xe0\xb0\x82\xe0\xb0\xac\xe0\xb0\xb0\xe0\xb1\x8d\0"
-       "\xe0\xb2\xaa\xe0\xb3\x82\xe0\xb2\xb0\xe0\xb3\x8d\xe0\xb2\xb5\xe0\xb2\xbe\xe0\xb2\xb9\xe0\xb3\x8d\xe0\xb2\xa8\0"
-       "\xe0\xb2\x85\xe0\xb2\xaa\xe0\xb2\xb0\xe0\xb2\xbe\xe0\xb2\xb9\xe0\xb3\x8d\xe0\xb2\xa8\0"
+       "\xe0\xb0\x9c\xe0\xb0\xa8\0"
+       "\xe0\xb0\xab\xe0\xb0\xbf\xe0\xb0\xac\xe0\xb1\x8d\xe0\xb0\xb0\0"
+       "\xe0\xb0\x8f\xe0\xb0\xaa\xe0\xb1\x8d\xe0\xb0\xb0\xe0\xb0\xbf\0"
        "\xe0\xb2\xb0\xe0\xb2\xb5\xe0\xb2\xbf\xe0\xb2\xb5\xe0\xb2\xbe\xe0\xb2\xb0\0"
        "\xe0\xb2\xb8\xe0\xb3\x8b\xe0\xb2\xae\xe0\xb2\xb5\xe0\xb2\xbe\xe0\xb2\xb0\0"
        "\xe0\xb2\xae\xe0\xb2\x82\xe0\xb2\x97\xe0\xb2\xb3\xe0\xb2\xb5\xe0\xb2\xbe\xe0\xb2\xb0\0"
@@ -2782,6 +3830,13 @@ static const char locale_strings [] = {
        "\xe0\xb2\x97\xe0\xb3\x81.\0"
        "\xe0\xb2\xb6\xe0\xb3\x81.\0"
        "\xe0\xb2\xb6\xe0\xb2\xa8\xe0\xb2\xbf.\0"
+       "\xe0\xb2\xb0\0"
+       "\xe0\xb2\xb8\xe0\xb3\x8b\0"
+       "\xe0\xb2\xae\xe0\xb2\x82\0"
+       "\xe0\xb2\xac\xe0\xb3\x81\0"
+       "\xe0\xb2\x97\xe0\xb3\x81\0"
+       "\xe0\xb2\xb6\xe0\xb3\x81\0"
+       "\xe0\xb2\xb6\0"
        "\xe0\xb2\x9c\xe0\xb2\xa8\xe0\xb2\xb5\xe0\xb2\xb0\xe0\xb3\x80\0"
        "\xe0\xb2\xab\xe0\xb3\x86\xe0\xb2\xac\xe0\xb3\x8d\xe0\xb2\xb0\xe0\xb2\xb5\xe0\xb2\xb0\xe0\xb3\x80\0"
        "\xe0\xb2\xae\xe0\xb2\xbe\xe0\xb2\xb0\xe0\xb3\x8d\xe0\xb2\x9a\xe0\xb3\x8d\0"
@@ -2794,20 +3849,315 @@ static const char locale_strings [] = {
        "\xe0\xb2\x85\xe0\xb2\x95\xe0\xb3\x8d\xe0\xb2\x9f\xe0\xb3\x8b\xe0\xb2\xac\xe0\xb2\xb0\xe0\xb3\x8d\0"
        "\xe0\xb2\xa8\xe0\xb2\xb5\xe0\xb3\x86\xe0\xb2\x82\xe0\xb2\xac\xe0\xb2\xb0\xe0\xb3\x8d\0"
        "\xe0\xb2\xa1\xe0\xb2\xbf\xe0\xb2\xb8\xe0\xb3\x86\xe0\xb2\x82\xe0\xb2\xac\xe0\xb2\xb0\xe0\xb3\x8d\0"
-       "\xe0\xa4\xae.\xe0\xa4\xaa\xe0\xa5\x82.\0"
-       "\xe0\xa4\xae.\xe0\xa4\xa8\xe0\xa4\x82.\0"
+       "\xe0\xb4\xb0\xe0\xb4\xbe\xe0\xb4\xb5\xe0\xb4\xbf\xe0\xb4\xb2\xe0\xb5\x86\0"
+       "\xe0\xb4\xb5\xe0\xb5\x88\xe0\xb4\x95\xe0\xb5\x81\xe0\xb4\xa8\xe0\xb5\x8d\xe0\xb4\xa8\xe0\xb5\x87\xe0\xb4\xb0\xe0\xb4\x82\0"
+       "\xe0\xb4\x9e\xe0\xb4\xbe\xe0\xb4\xaf\xe0\xb4\xb1\xe0\xb4\xbe\xe0\xb4\xb4\xe0\xb5\x8d\xe0\xb4\x9a\0"
+       "\xe0\xb4\xa4\xe0\xb4\xbf\xe0\xb4\x99\xe0\xb5\x8d\xe0\xb4\x95\xe0\xb4\xb3\xe0\xb4\xbe\xe0\xb4\xb4\xe0\xb5\x8d\xe0\xb4\x9a\0"
+       "\xe0\xb4\x9a\xe0\xb5\x8a\xe0\xb4\xb5\xe0\xb5\x8d\xe0\xb4\xb5\xe0\xb4\xbe\xe0\xb4\xb4\xe0\xb5\x8d\xe0\xb4\x9a\0"
+       "\xe0\xb4\xac\xe0\xb5\x81\xe0\xb4\xa7\xe0\xb4\xa8\xe0\xb4\xbe\xe0\xb4\xb4\xe0\xb5\x8d\xe0\xb4\x9a\0"
+       "\xe0\xb4\xb5\xe0\xb5\x8d\xe0\xb4\xaf\xe0\xb4\xbe\xe0\xb4\xb4\xe0\xb4\xbe\xe0\xb4\xb4\xe0\xb5\x8d\xe0\xb4\x9a\0"
+       "\xe0\xb4\xb5\xe0\xb5\x86\xe0\xb4\xb3\xe0\xb5\x8d\xe0\xb4\xb3\xe0\xb4\xbf\xe0\xb4\xaf\xe0\xb4\xbe\xe0\xb4\xb4\xe0\xb5\x8d\xe0\xb4\x9a\0"
+       "\xe0\xb4\xb6\xe0\xb4\xa8\xe0\xb4\xbf\xe0\xb4\xaf\xe0\xb4\xbe\xe0\xb4\xb4\xe0\xb5\x8d\xe0\xb4\x9a\0"
+       "\xe0\xb4\x9e\xe0\xb4\xbe\xe0\xb4\xaf\xe0\xb4\xb0\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\xa4\xe0\xb4\xbf\xe0\xb4\x99\xe0\xb5\x8d\xe0\xb4\x95\xe0\xb4\xb3\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\x9a\xe0\xb5\x8a\xe0\xb4\xb5\xe0\xb5\x8d\xe0\xb4\xb5\0"
+       "\xe0\xb4\xac\xe0\xb5\x81\xe0\xb4\xa7\xe0\xb4\xa8\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\xb5\xe0\xb5\x8d\xe0\xb4\xaf\xe0\xb4\xbe\xe0\xb4\xb4\xe0\xb4\x82\0"
+       "\xe0\xb4\xb5\xe0\xb5\x86\xe0\xb4\xb3\xe0\xb5\x8d\xe0\xb4\xb3\xe0\xb4\xbf\0"
+       "\xe0\xb4\xb6\xe0\xb4\xa8\xe0\xb4\xbf\0"
+       "\xe0\xb4\x9e\xe0\xb4\xbe\0"
+       "\xe0\xb4\xa4\xe0\xb4\xbf\0"
+       "\xe0\xb4\x9a\xe0\xb5\x8a\0"
+       "\xe0\xb4\xac\xe0\xb5\x81\0"
+       "\xe0\xb4\xb5\xe0\xb5\x8d\xe0\xb4\xaf\xe0\xb4\xbe\0"
+       "\xe0\xb4\xb5\xe0\xb5\x86\0"
+       "\xe0\xb4\xb6\0"
+       "\xe0\xb4\x9c\xe0\xb4\xa8\xe0\xb5\x81\xe0\xb4\xb5\xe0\xb4\xb0\xe0\xb4\xbf\0"
+       "\xe0\xb4\xab\xe0\xb5\x86\xe0\xb4\xac\xe0\xb5\x8d\xe0\xb4\xb0\xe0\xb5\x81\xe0\xb4\xb5\xe0\xb4\xb0\xe0\xb4\xbf\0"
+       "\xe0\xb4\xae\xe0\xb4\xbe\xe0\xb4\xb0\xe0\xb5\x8d\xe2\x80\x8d\xe0\xb4\x9a\xe0\xb5\x8d\xe0\xb4\x9a\xe0\xb5\x8d\0"
+       "\xe0\xb4\x8f\xe0\xb4\xaa\xe0\xb5\x8d\xe0\xb4\xb0\xe0\xb4\xbf\xe0\xb4\xb2\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\xae\xe0\xb5\x87\xe0\xb4\xaf\xe0\xb5\x8d\0"
+       "\xe0\xb4\x9c\xe0\xb5\x82\xe0\xb4\xa3\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\x9c\xe0\xb5\x82\xe0\xb4\xb2\xe0\xb5\x88\0"
+       "\xe0\xb4\x86\xe0\xb4\x97\xe0\xb4\xb8\xe0\xb5\x8d\xe0\xb4\xb1\xe0\xb5\x8d\xe0\xb4\xb1\xe0\xb5\x8d\0"
+       "\xe0\xb4\xb8\xe0\xb5\x86\xe0\xb4\xaa\xe0\xb5\x8d\xe0\xb4\xb1\xe0\xb5\x8d\xe0\xb4\xb1\xe0\xb4\x82\xe0\xb4\xac\xe0\xb4\xb0\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\x92\xe0\xb4\x95\xe0\xb5\x8d\xe0\xb4\x9f\xe0\xb5\x8b\xe0\xb4\xac\xe0\xb4\xb0\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\xa8\xe0\xb4\xb5\xe0\xb4\x82\xe0\xb4\xac\xe0\xb4\xb0\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\xa1\xe0\xb4\xbf\xe0\xb4\xb8\xe0\xb4\x82\xe0\xb4\xac\xe0\xb4\xb0\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\x9c\xe0\xb4\xa8\xe0\xb5\x81\0"
+       "\xe0\xb4\xab\xe0\xb5\x86\xe0\xb4\xac\xe0\xb5\x8d\xe0\xb4\xb0\xe0\xb5\x81\0"
+       "\xe0\xb4\xae\xe0\xb4\xbe\xe0\xb4\xb0\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "\xe0\xb4\x8f\xe0\xb4\xaa\xe0\xb5\x8d\xe0\xb4\xb0\xe0\xb4\xbf\0"
+       "\xe0\xb4\x93\xe0\xb4\x97\0"
+       "\xe0\xb4\xb8\xe0\xb5\x86\xe0\xb4\xaa\xe0\xb5\x8d\xe0\xb4\xb1\xe0\xb5\x8d\xe0\xb4\xb1\xe0\xb4\x82\0"
+       "\xe0\xb4\x92\xe0\xb4\x95\xe0\xb5\x8d\xe0\xb4\x9f\xe0\xb5\x8b\0"
+       "\xe0\xb4\xa8\xe0\xb4\xb5\xe0\xb4\x82\0"
+       "\xe0\xb4\xa1\xe0\xb4\xbf\xe0\xb4\xb8\xe0\xb4\x82\0"
+       "yyyy,MMMM dd, dddd\0"
+       "MMMM,yy\0"
+       "\xe0\xa6\xaa\xe0\xa7\x82\xe0\xa7\xb0\xe0\xa7\x8d\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\xb9\xe0\xa7\x8d\xe0\xa6\xa3\0"
+       "\xe0\xa6\x85\xe0\xa6\xaa\xe0\xa7\xb0\xe0\xa6\xbe\xe0\xa6\xb9\xe0\xa7\x8d\xe0\xa6\xa3\0"
+       "\xe0\xa6\xa6\xe0\xa7\x87\xe0\xa6\x93\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa7\xb0\0"
+       "\xe0\xa6\xb8\xe0\xa7\x8b\xe0\xa6\xae\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa7\xb0\0"
+       "\xe0\xa6\xae\xe0\xa6\x99\xe0\xa7\x8d\xe0\xa6\x97\xe0\xa6\xb2\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa7\xb0\0"
+       "\xe0\xa6\xac\xe0\xa7\x81\xe0\xa6\xa7\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa7\xb0\0"
+       "\xe0\xa6\xac\xe0\xa7\x83\xe0\xa6\xb9\xe0\xa6\xb7\xe0\xa7\x8d\xe0\xa6\xaa\xe0\xa6\xa4\xe0\xa6\xbf\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa7\xb0\0"
+       "\xe0\xa6\xb6\xe0\xa7\x81\xe0\xa6\x95\xe0\xa7\x8d\xe0\xa7\xb0\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa7\xb0\0"
+       "\xe0\xa6\xb6\xe0\xa6\xa8\xe0\xa6\xbf\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa7\xb0\0"
+       "\xe0\xa7\xb0\xe0\xa6\xac\xe0\xa6\xbf\0"
+       "\xe0\xa6\xac\xe0\xa7\x83\xe0\xa6\xb9\xe0\xa6\xb7\xe0\xa7\x8d\xe0\xa6\xaa\xe0\xa6\xa4\xe0\xa6\xbf\0"
+       "\xe0\xa6\xb6\xe0\xa7\x81\xe0\xa6\x95\xe0\xa7\x8d\xe0\xa7\xb0\0"
+       "\xe0\xa6\x9c\xe0\xa6\xbe\xe0\xa6\xa8\xe0\xa7\x81\xe0\xa7\xb1\xe0\xa6\xbe\xe0\xa7\xb0\xe0\xa7\x80\0"
+       "\xe0\xa6\xab\xe0\xa7\x87\xe0\xa6\xac\xe0\xa7\x8d\xe0\xa7\xb0\xe0\xa7\x81\xe0\xa7\xb1\xe0\xa6\xbe\xe0\xa7\xb0\xe0\xa7\x80\0"
+       "\xe0\xa6\xae\xe0\xa6\xbe\xe0\xa7\xb0\xe0\xa7\x8d\xe0\xa6\x9a\0"
+       "\xe0\xa6\x8f\xe0\xa6\xaa\xe0\xa7\x8d\xe0\xa7\xb0\xe0\xa6\xbf\xe0\xa6\xb2\0"
+       "\xe0\xa6\x86\xe0\xa6\x97\xe0\xa6\xb7\xe0\xa7\x8d\xe0\xa6\x9f\0"
+       "\xe0\xa6\x9b\xe0\xa7\x87\xe0\xa6\xaa\xe0\xa7\x8d\xe0\xa6\xa4\xe0\xa7\x87\xe0\xa6\xae\xe0\xa7\x8d\xe0\xa6\xac\xe0\xa7\xb0\0"
+       "\xe0\xa6\x85\xe0\xa6\x95\xe0\xa7\x8d\xe0\xa6\x9f\xe0\xa7\x8b\xe0\xa6\xac\xe0\xa7\xb0\0"
+       "\xe0\xa6\xa8\xe0\xa7\xb1\xe0\xa7\x87\xe0\xa6\xae\xe0\xa7\x8d\xe0\xa6\xac\xe0\xa7\xb0\0"
+       "\xe0\xa6\xa1\xe0\xa6\xbf\xe0\xa6\x9a\xe0\xa7\x87\xe0\xa6\xae\xe0\xa7\x8d\xe0\xa6\xac\xe0\xa7\xb0\0"
+       "\xe0\xa6\x9c\xe0\xa6\xbe\xe0\xa6\xa8\xe0\xa7\x81\0"
+       "\xe0\xa6\xab\xe0\xa7\x87\xe0\xa6\xac\xe0\xa7\x8d\xe0\xa7\xb0\xe0\xa7\x81\0"
+       "\xe0\xa6\x86\xe0\xa6\x97\0"
+       "\xe0\xa6\xb8\xe0\xa7\x87\xe0\xa6\xaa\xe0\xa7\x8d\xe0\xa6\x9f\0"
+       "\xe0\xa6\x85\xe0\xa6\x95\xe0\xa7\x8d\xe0\xa6\x9f\xe0\xa7\x8b\0"
+       "\xe0\xa6\xa8\xe0\xa6\xad\xe0\xa7\x87\0"
+       "\xe0\xa6\xa1\xe0\xa6\xbf\xe0\xa6\xb8\xe0\xa7\x87\0"
        "\xe0\xa4\xae\xe0\xa4\x82\xe0\xa4\x97\xe0\xa4\xb3\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\x97\xe0\xa5\x81\xe0\xa4\xb0\xe0\xa5\x81\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\xb0\xe0\xa4\xb5\xe0\xa4\xbf\0"
+       "\xe0\xa4\xb8\xe0\xa5\x8b\xe0\xa4\xae\0"
        "\xe0\xa4\xae\xe0\xa4\x82\xe0\xa4\x97\xe0\xa4\xb3\0"
+       "\xe0\xa4\xac\xe0\xa5\x81\xe0\xa4\xa7\0"
+       "\xe0\xa4\x97\xe0\xa5\x81\xe0\xa4\xb0\xe0\xa5\x81\0"
+       "\xe0\xa4\xb6\xe0\xa5\x81\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\xb0\0"
+       "\xe0\xa4\xb6\xe0\xa4\xa8\xe0\xa4\xbf\0"
        "\xe0\xa4\x9c\xe0\xa4\xbe\xe0\xa4\xa8\xe0\xa5\x87\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa5\x80\0"
-       "\xe0\xa4\xab\xe0\xa5\x87\xe0\xa4\xac\xe0\xa5\x83\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa5\x80\0"
+       "\xe0\xa4\xab\xe0\xa5\x87\xe0\xa4\xac\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa5\x81\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa5\x80\0"
        "\xe0\xa4\x8f\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa4\xbf\xe0\xa4\xb2\0"
        "\xe0\xa4\xae\xe0\xa5\x87\0"
        "\xe0\xa4\x9c\xe0\xa5\x81\xe0\xa4\xb2\xe0\xa5\x88\0"
-       "\xe0\xa4\x93\xe0\xa4\x97\xe0\xa4\xb8\xe0\xa5\x8d\xe0\xa4\x9f\0"
-       "\xe0\xa4\xb8\xe0\xa5\x87\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x87\xe0\xa4\x82\xe0\xa4\xac\xe0\xa4\xb0\0"
-       "\xe0\xa4\x93\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x8b\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "\xe0\xa4\x91\xe0\xa4\x97\xe0\xa4\xb8\xe0\xa5\x8d\xe0\xa4\x9f\0"
+       "\xe0\xa4\xb8\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x87\xe0\xa4\x82\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "\xe0\xa4\x91\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x8b\xe0\xa4\xac\xe0\xa4\xb0\0"
        "\xe0\xa4\xa8\xe0\xa5\x8b\xe0\xa4\xb5\xe0\xa5\x8d\xe0\xa4\xb9\xe0\xa5\x87\xe0\xa4\x82\xe0\xa4\xac\xe0\xa4\xb0\0"
        "\xe0\xa4\xa1\xe0\xa4\xbf\xe0\xa4\xb8\xe0\xa5\x87\xe0\xa4\x82\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "\xe0\xa4\x9c\xe0\xa4\xbe\xe0\xa4\xa8\xe0\xa5\x87\0"
+       "\xe0\xa4\xab\xe0\xa5\x87\xe0\xa4\xac\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa5\x81\0"
+       "\xe0\xa4\x8f\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa4\xbf\0"
+       "\xe0\xa4\x91\xe0\xa4\x97\0"
+       "\xe0\xa4\xb8\xe0\xa5\x87\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x87\xe0\xa4\x82\0"
+       "\xe0\xa4\xa8\xe0\xa5\x8b\xe0\xa4\xb5\xe0\xa5\x8d\xe0\xa4\xb9\xe0\xa5\x87\xe0\xa4\x82\0"
+       "\xe0\xa4\xa1\xe0\xa4\xbf\xe0\xa4\xb8\xe0\xa5\x87\xe0\xa4\x82\0"
+       "yyyy '\xd0\xbe\xd0\xbd\xd1\x8b' MMMM d\0"
+       "yy.MM.dd\0"
+       "yyyy '\xd0\xbe\xd0\xbd' MMMM\0"
+       "\xd0\xbd\xd1\x8f\xd0\xbc\0"
+       "\xd0\xb4\xd0\xb0\xd0\xb2\xd0\xb0\xd0\xb0\0"
+       "\xd0\xbc\xd1\x8f\xd0\xb3\xd0\xbc\xd0\xb0\xd1\x80\0"
+       "\xd0\xbb\xd1\x85\xd0\xb0\xd0\xb3\xd0\xb2\xd0\xb0\0"
+       "\xd0\xbf\xd2\xaf\xd1\x80\xd1\x8d\xd0\xb2\0"
+       "\xd0\xb1\xd0\xb0\xd0\xb0\xd1\x81\xd0\xb0\xd0\xbd\0"
+       "\xd0\xb1\xd1\x8f\xd0\xbc\xd0\xb1\xd0\xb0\0"
+       "\xd0\x9d\xd1\x8f\0"
+       "\xd0\x94\xd0\xb0\0"
+       "\xd0\x9c\xd1\x8f\0"
+       "\xd0\x9b\xd1\x85\0"
+       "\xd0\x9f\xd2\xaf\0"
+       "\xd0\x91\xd0\xb0\0"
+       "\xd0\x91\xd1\x8f\0"
+       "\xd0\xa5\xd1\x83\xd0\xbb\xd0\xb3\xd0\xb0\xd0\xbd\xd0\xb0\0"
+       "\xd2\xae\xd1\x85\xd1\x8d\xd1\x80\0"
+       "\xd0\x91\xd0\xb0\xd1\x80\0"
+       "\xd0\xa2\xd1\x83\xd1\x83\xd0\xbb\xd0\xb0\xd0\xb9\0"
+       "\xd0\x9b\xd1\x83\xd1\x83\0"
+       "\xd0\x9c\xd0\xbe\xd0\xb3\xd0\xbe\xd0\xb9\0"
+       "\xd0\x9c\xd0\xbe\xd1\x80\xd1\x8c\0"
+       "\xd0\xa5\xd0\xbe\xd0\xbd\xd1\x8c\0"
+       "\xd0\x91\xd0\xb8\xd1\x87\0"
+       "\xd0\xa2\xd0\xb0\xd1\x85\xd0\xb8\xd0\xb0\0"
+       "\xd0\x9d\xd0\xbe\xd1\x85\xd0\xbe\xd0\xb9\0"
+       "\xd0\x93\xd0\xb0\xd1\x85\xd0\xb0\xd0\xb9\0"
+       "\xd1\x85\xd1\x83\xd0\xbb\0"
+       "\xd2\xaf\xd1\x85\xd1\x8d\0"
+       "\xd0\xb1\xd0\xb0\xd1\x80\0"
+       "\xd1\x82\xd1\x83\xd1\x83\0"
+       "\xd0\xbb\xd1\x83\xd1\x83\0"
+       "\xd0\xbc\xd0\xbe\xd0\xb3\0"
+       "\xd0\xbc\xd0\xbe\xd1\x80\0"
+       "\xd1\x85\xd0\xbe\xd0\xbd\0"
+       "\xd0\xb1\xd0\xb8\xd1\x87\0"
+       "\xd1\x82\xd0\xb0\xd1\x85\0"
+       "\xd0\xbd\xd0\xbe\xd1\x85\0"
+       "\xd0\xb3\xd0\xb0\xd1\x85\0"
+       "yyyy'\xe0\xbd\xa3\xe0\xbd\xbc\xe0\xbd\xa0\xe0\xbd\xb2\xe0\xbc\x8b\xe0\xbd\x9f\xe0\xbe\xb3' M'\xe0\xbd\x9a\xe0\xbd\xba\xe0\xbd\xa6' d\0"
+       "yyyy.M\0"
+       "'\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b' M'\xe0\xbd\x9a\xe0\xbd\xba\xe0\xbd\xa6'd\0"
+       "\xe0\xbd\xa6\xe0\xbe\x94\xe0\xbc\x8b\xe0\xbd\x91\xe0\xbe\xb2\xe0\xbd\xbc\xe0\xbc\x8b\0"
+       "\xe0\xbd\x95\xe0\xbe\xb1\xe0\xbd\xb2\xe0\xbc\x8b\xe0\xbd\x91\xe0\xbe\xb2\xe0\xbd\xbc\xe0\xbc\x8b\0"
+       "\xe0\xbd\x82\xe0\xbd\x9f\xe0\xbd\xa0\xe0\xbc\x8b\xe0\xbd\x89\xe0\xbd\xb2\xe0\xbc\x8b\xe0\xbd\x98\xe0\xbc\x8b\0"
+       "\xe0\xbd\x82\xe0\xbd\x9f\xe0\xbd\xa0\xe0\xbc\x8b\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\0"
+       "\xe0\xbd\x82\xe0\xbd\x9f\xe0\xbd\xa0\xe0\xbc\x8b\xe0\xbd\x98\xe0\xbd\xb2\xe0\xbd\x82\xe0\xbc\x8b\xe0\xbd\x91\xe0\xbd\x98\xe0\xbd\xa2\xe0\xbc\x8b\0"
+       "\xe0\xbd\x82\xe0\xbd\x9f\xe0\xbd\xa0\xe0\xbc\x8b\xe0\xbd\xa7\xe0\xbe\xb3\xe0\xbd\x82\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x82\xe0\xbd\x9f\xe0\xbd\xa0\xe0\xbc\x8b\xe0\xbd\x95\xe0\xbd\xb4\xe0\xbd\xa2\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbd\xb4\xe0\xbc\x8b\0"
+       "\xe0\xbd\x82\xe0\xbd\x9f\xe0\xbd\xa0\xe0\xbc\x8b\xe0\xbd\xa6\xe0\xbd\x84\xe0\xbd\xa6\xe0\xbc\x8b\0"
+       "\xe0\xbd\x82\xe0\xbd\x9f\xe0\xbd\xa0\xe0\xbc\x8b\xe0\xbd\xa6\xe0\xbe\xa4\xe0\xbd\xba\xe0\xbd\x93\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x89\xe0\xbd\xb2\xe0\xbc\x8b\xe0\xbd\x98\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\0"
+       "\xe0\xbd\x98\xe0\xbd\xb2\xe0\xbd\x82\xe0\xbc\x8b\xe0\xbd\x91\xe0\xbd\x98\xe0\xbd\xa2\xe0\xbc\x8b\0"
+       "\xe0\xbd\xa3\xe0\xbe\xb7\xe0\xbd\x82\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x95\xe0\xbd\xb4\xe0\xbd\xa2\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbd\xb4\xe0\xbc\x8b\0"
+       "\xe0\xbd\x94\xe0\xbc\x8b\xe0\xbd\xa6\xe0\xbd\x84\xe0\xbd\xa6\xe0\xbc\x8b\0"
+       "\xe0\xbd\xa6\xe0\xbe\xa4\xe0\xbd\xba\xe0\xbd\x93\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x89\xe0\xbd\xb2\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\0"
+       "\xe0\xbd\x98\xe0\xbd\xb2\0"
+       "\xe0\xbd\xa7\xe0\xbe\xb3\0"
+       "\xe0\xbd\x95\xe0\xbd\xb4\0"
+       "\xe0\xbd\xa6\0"
+       "\xe0\xbd\xa6\xe0\xbe\xa4\xe0\xbd\xba\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x91\xe0\xbd\x84\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbd\xbc\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x82\xe0\xbd\x89\xe0\xbd\xb2\xe0\xbd\xa6\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\xa6\xe0\xbd\xb4\xe0\xbd\x98\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbd\x9e\xe0\xbd\xb2\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\xa3\xe0\xbe\x94\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x91\xe0\xbe\xb2\xe0\xbd\xb4\xe0\xbd\x82\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbd\x91\xe0\xbd\xb4\xe0\xbd\x93\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbd\xa2\xe0\xbe\x92\xe0\xbe\xb1\xe0\xbd\x91\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x91\xe0\xbd\x82\xe0\xbd\xb4\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbd\x85\xe0\xbd\xb4\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbd\x85\xe0\xbd\xb4\xe0\xbc\x8b\xe0\xbd\x82\xe0\xbd\x85\xe0\xbd\xb2\xe0\xbd\x82\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbc\x8b\xe0\xbd\x96\xe0\xbd\x85\xe0\xbd\xb4\xe0\xbc\x8b\xe0\xbd\x82\xe0\xbd\x89\xe0\xbd\xb2\xe0\xbd\xa6\xe0\xbc\x8b\xe0\xbd\x94\xe0\xbc\x8b\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa1\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa2\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa3\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa4\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa5\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa6\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa7\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa8\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa9\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa1\xe0\xbc\xa0\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa1\xe0\xbc\xa1\0"
+       "\xe0\xbd\x9f\xe0\xbe\xb3\xe0\xbc\x8b\xe0\xbc\xa1\xe0\xbc\xa2\0"
+       "yyyy'\xe0\xbd\xa3\xe0\xbd\xbc\xe0\xbd\xa0\xe0\xbd\xb2\xe0\xbc\x8b\xe0\xbd\x9f\xe0\xbe\xb3' M'\xe0\xbd\x9a\xe0\xbd\xba\xe0\xbd\xa6' d dddd\0"
+       "Dydd Sul\0"
+       "Dydd Llun\0"
+       "Dydd Mawrth\0"
+       "Dydd Mercher\0"
+       "Dydd Iau\0"
+       "Dydd Gwener\0"
+       "Dydd Sadwrn\0"
+       "Sul\0"
+       "Llun\0"
+       "Maw\0"
+       "Mer\0"
+       "Iau\0"
+       "Gwe\0"
+       "Sad\0"
+       "Ionawr\0"
+       "Chwefror\0"
+       "Mawrth\0"
+       "Ebrill\0"
+       "Mehefin\0"
+       "Gorffennaf\0"
+       "Awst\0"
+       "Medi\0"
+       "Hydref\0"
+       "Tachwedd\0"
+       "Rhagfyr\0"
+       "Gorffenaf\0"
+       "Ion\0"
+       "Chwe\0"
+       "Ebr\0"
+       "Meh\0"
+       "Gor\0"
+       "Hyd\0"
+       "Tach\0"
+       "Rhag\0"
+       "H:mm tt\0"
+       "'\xe1\x9e\x81\xe1\x9f\x82' MM '\xe1\x9e\x86\xe1\x9f\x92\xe1\x9e\x93\xe1\x9e\xb6\xe1\x9f\x86' yyyy\0"
+       "'\xe1\x9e\x90\xe1\x9f\x92\xe1\x9e\x84\xe1\x9f\x83\xe1\x9e\x91\xe1\x9e\xb8' dd '\xe1\x9e\x81\xe1\x9f\x82' MM\0"
+       "\xe1\x9e\x96\xe1\x9f\x92\xe1\x9e\x9a\xe1\x9e\xb9\xe1\x9e\x80\0"
+       "\xe1\x9e\x9b\xe1\x9f\x92\xe1\x9e\x84\xe1\x9e\xb6\xe1\x9e\x85\0"
+       "\xe1\x9e\x90\xe1\x9f\x92\xe1\x9e\x84\xe1\x9f\x83\xe1\x9e\xa2\xe1\x9e\xb6\xe1\x9e\x91\xe1\x9e\xb7\xe1\x9e\x8f\xe1\x9f\x92\xe1\x9e\x99\0"
+       "\xe2\x80\x8b\xe1\x9e\x90\xe1\x9f\x92\xe1\x9e\x84\xe1\x9f\x83\xe1\x9e\x85\xe1\x9f\x90\xe1\x9e\x93\xe1\x9f\x92\xe1\x9e\x91\0"
+       "\xe1\x9e\x90\xe1\x9f\x92\xe1\x9e\x84\xe1\x9f\x83\xe1\x9e\xa2\xe1\x9e\x84\xe1\x9f\x92\xe1\x9e\x82\xe1\x9e\xb6\xe1\x9e\x9a\0"
+       "\xe1\x9e\x90\xe1\x9f\x92\xe1\x9e\x84\xe1\x9f\x83\xe1\x9e\x96\xe1\x9e\xbb\xe1\x9e\x92\0"
+       "\xe1\x9e\x90\xe1\x9f\x92\xe1\x9e\x84\xe1\x9f\x83\xe1\x9e\x96\xe1\x9f\x92\xe1\x9e\x9a\xe1\x9e\xa0\xe1\x9e\x9f\xe1\x9f\x92\xe1\x9e\x94\xe1\x9e\x8f\xe1\x9e\xb7\xe1\x9f\x8d\0"
+       "\xe1\x9e\x90\xe1\x9f\x92\xe1\x9e\x84\xe1\x9f\x83\xe1\x9e\x9f\xe1\x9e\xbb\xe1\x9e\x80\xe1\x9f\x92\xe1\x9e\x9a\0"
+       "\xe1\x9e\x90\xe1\x9f\x92\xe1\x9e\x84\xe1\x9f\x83\xe1\x9e\x9f\xe1\x9f\x85\xe1\x9e\x9a\xe1\x9f\x8d\0"
+       "\xe1\x9e\xa2\xe1\x9e\xb6\0"
+       "\xe1\x9e\x85\0"
+       "\xe1\x9e\xa2\0"
+       "\xe1\x9e\x96\xe1\x9e\xbb\0"
+       "\xe1\x9e\x96\xe1\x9f\x92\xe1\x9e\x9a\0"
+       "\xe1\x9e\x9f\xe1\x9e\xbb\0"
+       "\xe1\x9e\x9f\0"
+       "\xe1\x9e\x98\xe1\x9e\x80\xe1\x9e\x9a\xe1\x9e\xb6\0"
+       "\xe1\x9e\x80\xe1\x9e\xbb\xe1\x9e\x98\xe1\x9f\x92\xe1\x9e\x97\xe1\x9f\x88\0"
+       "\xe1\x9e\x98\xe1\x9e\xb7\xe1\x9e\x93\xe1\x9e\xb6\0"
+       "\xe1\x9e\x98\xe1\x9f\x81\xe1\x9e\x9f\xe1\x9e\xb6\0"
+       "\xe1\x9e\xa7\xe1\x9e\x9f\xe1\x9e\x97\xe1\x9e\xb6\0"
+       "\xe1\x9e\x98\xe1\x9e\xb7\xe1\x9e\x90\xe1\x9e\xbb\xe1\x9e\x93\xe1\x9e\xb6\0"
+       "\xe1\x9e\x80\xe1\x9e\x80\xe1\x9f\x92\xe1\x9e\x80\xe1\x9e\x8a\xe1\x9e\xb6\0"
+       "\xe1\x9e\x9f\xe1\x9e\xb8\xe1\x9e\xa0\xe1\x9e\xb6\0"
+       "\xe1\x9e\x80\xe1\x9e\x89\xe1\x9f\x92\xe1\x9e\x89\xe1\x9e\xb6\0"
+       "\xe1\x9e\x8f\xe1\x9e\xbb\xe1\x9e\x9b\xe1\x9e\xb6\0"
+       "\xe1\x9e\x9c\xe1\x9e\xb7\xe1\x9e\x85\xe1\x9f\x92\xe1\x9e\x86\xe1\x9e\xb7\xe1\x9e\x80\xe1\x9e\xb6\0"
+       "\xe1\x9e\x92\xe1\x9f\x92\xe1\x9e\x93\xe1\x9e\xbc\0"
+       "\xe1\x9f\xa1\0"
+       "\xe1\x9f\xa2\0"
+       "\xe1\x9f\xa3\0"
+       "\xe1\x9f\xa4\0"
+       "\xe1\x9f\xa5\0"
+       "\xe1\x9f\xa6\0"
+       "\xe1\x9f\xa7\0"
+       "\xe1\x9f\xa8\0"
+       "\xe1\x9f\xa9\0"
+       "\xe1\x9f\xa1\xe1\x9f\xa0\0"
+       "\xe1\x9f\xa1\xe1\x9f\xa1\0"
+       "\xe1\x9f\xa1\xe1\x9f\xa2\0"
+       "\xe0\xba\x81\xe0\xbb\x88\xe0\xba\xad\xe0\xba\x99\xe0\xba\x97\xe0\xbb\x88\xe0\xba\xbd\xe0\xba\x87\0"
+       "\xe0\xba\xab\xe0\xba\xa5\xe0\xba\xb1\xe0\xba\x87\xe0\xba\x97\xe0\xbb\x88\xe0\xba\xbd\xe0\xba\x87\0"
+       "\xe0\xba\xa7\xe0\xba\xb1\xe0\xba\x99\xe0\xba\xad\xe0\xba\xb2\xe0\xba\x97\xe0\xba\xb4\xe0\xba\x94\0"
+       "\xe0\xba\xa7\xe0\xba\xb1\xe0\xba\x99\xe0\xba\x88\xe0\xba\xb1\xe0\xba\x99\0"
+       "\xe0\xba\xa7\xe0\xba\xb1\xe0\xba\x99\xe0\xba\xad\xe0\xba\xb1\xe0\xba\x87\xe0\xba\x84\xe0\xba\xb2\xe0\xba\x99\0"
+       "\xe0\xba\xa7\xe0\xba\xb1\xe0\xba\x99\xe0\xba\x9e\xe0\xba\xb8\xe0\xba\x94\0"
+       "\xe0\xba\xa7\xe0\xba\xb1\xe0\xba\x99\xe0\xba\x9e\xe0\xba\xb0\xe0\xba\xab\xe0\xba\xb1\xe0\xba\x94\0"
+       "\xe0\xba\xa7\xe0\xba\xb1\xe0\xba\x99\xe0\xba\xaa\xe0\xba\xb8\xe0\xba\x81\0"
+       "\xe0\xba\xa7\xe0\xba\xb1\xe0\xba\x99\xe0\xbb\x80\xe0\xba\xaa\xe0\xba\xbb\xe0\xba\xb2\0"
+       "\xe0\xba\xad\xe0\xba\xb2.\0"
+       "\xe0\xba\x88.\0"
+       "\xe0\xba\xad.\0"
+       "\xe0\xba\x9e.\0"
+       "\xe0\xba\x9e\xe0\xba\xab.\0"
+       "\xe0\xba\xaa\xe0\xba\x81.\0"
+       "\xe0\xba\xaa.\0"
+       "\xe0\xba\xa1\xe0\xba\xb1\xe0\xba\x87\xe0\xba\x81\xe0\xba\xad\xe0\xba\x99\0"
+       "\xe0\xba\x81\xe0\xba\xb8\xe0\xba\xa1\xe0\xba\x9e\xe0\xba\xb2\0"
+       "\xe0\xba\xa1\xe0\xba\xb5\xe0\xba\x99\xe0\xba\xb2\0"
+       "\xe0\xbb\x80\xe0\xba\xa1\xe0\xba\xaa\xe0\xba\xb2\0"
+       "\xe0\xba\x9e\xe0\xba\xb6\xe0\xba\x94\xe0\xba\xaa\xe0\xba\xb0\xe0\xba\x9e\xe0\xba\xb2\0"
+       "\xe0\xba\xa1\xe0\xba\xb4\xe0\xba\x96\xe0\xba\xb8\xe0\xba\x99\xe0\xba\xb2\0"
+       "\xe0\xba\x81\xe0\xbb\x8d\xe0\xba\xa5\xe0\xba\xb0\xe0\xba\x81\xe0\xba\xbb\xe0\xba\x94\0"
+       "\xe0\xba\xaa\xe0\xba\xb4\xe0\xba\x87\xe0\xba\xab\xe0\xba\xb2\0"
+       "\xe0\xba\x81\xe0\xba\xb1\xe0\xba\x99\xe0\xba\x8d\xe0\xba\xb2\0"
+       "\xe0\xba\x95\xe0\xba\xb8\xe0\xba\xa5\xe0\xba\xb2\0"
+       "\xe0\xba\x9e\xe0\xba\xb0\xe0\xba\x88\xe0\xba\xb4\xe0\xba\x81\0"
+       "\xe0\xba\x97\xe0\xba\xb1\xe0\xba\x99\xe0\xba\xa7\xe0\xba\xb2\0"
+       "\xe0\xba\xa1.\xe0\xba\x81.\0"
+       "\xe0\xba\x81.\xe0\xba\x9e.\0"
+       "\xe0\xba\xa1\xe0\xba\xb5.\xe0\xba\x99.\0"
+       "\xe0\xba\xa1.\xe0\xba\xaa..\0"
+       "\xe0\xba\x9e.\xe0\xba\x9e.\0"
+       "\xe0\xba\xa1\xe0\xba\xb4.\xe0\xba\x96.\0"
+       "\xe0\xba\x81.\xe0\xba\xa5.\0"
+       "\xe0\xba\xaa.\xe0\xba\xab.\0"
+       "\xe0\xba\x81.\xe0\xba\x8d.\0"
+       "\xe0\xba\x95.\xe0\xba\xa5.\0"
+       "\xe0\xba\x9e.\xe0\xba\x88.\0"
+       "\xe0\xba\x97.\xe0\xba\xa7.\0"
        "Domingo\0"
        "Luns\0"
        "Martes\0"
@@ -2823,12 +4173,10 @@ static const char locale_strings [] = {
        "S\xc3\xa1\x62\0"
        "Xaneiro\0"
        "Febreiro\0"
-       "Marzo\0"
        "Abril\0"
        "Maio\0"
        "Xu\xc3\xb1o\0"
        "Xullo\0"
-       "Agosto\0"
        "Setembro\0"
        "Outubro\0"
        "Novembro\0"
@@ -2837,96 +4185,723 @@ static const char locale_strings [] = {
        "Abr\0"
        "Xu\xc3\xb1\0"
        "Xul\0"
-       "Set\0"
        "Out\0"
+       "\xe0\xa4\xae.\xe0\xa4\xaa\xe0\xa5\x82.\0"
+       "\xe0\xa4\xae.\xe0\xa4\xa8\xe0\xa4\x82.\0"
        "\xe0\xa4\x86\xe0\xa4\xa6\xe0\xa4\xbf\xe0\xa4\xa4\xe0\xa5\x8d\xe0\xa4\xaf\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\0"
        "\xe0\xa4\xae\xe0\xa4\x82\xe0\xa4\x97\xe0\xa4\xb3\xe0\xa4\xbe\xe0\xa4\xb0\0"
-       "\xe0\xa4\xab\xe0\xa5\x87\xe0\xa4\xac\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa5\x81\xe0\xa4\xb5\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa5\x80\0"
-       "yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5' thh'\xe6\x99\x82'mm'\xe5\x88\x86'ss'\xe7\xa7\x92'\0"
-       "thh'\xe6\x99\x82'mm'\xe5\x88\x86'ss'\xe7\xa7\x92'\0"
-       "t h:mm\0"
-       "dd-MMM-yy\0"
-       "dd MMMM yyyy H.mm.ss\0"
-       "H.mm.ss\0"
-       "yyyy'\xeb\x85\x84' M'\xec\x9b\x94' d'\xec\x9d\xbc' tt h'\xec\x8b\x9c' mm'\xeb\xb6\x84' ss'\xec\xb4\x88'\0"
-       "yyyy'\xeb\x85\x84' M'\xec\x9b\x94' d'\xec\x9d\xbc'\0"
-       "tt h'\xec\x8b\x9c' mm'\xeb\xb6\x84' ss'\xec\xb4\x88'\0"
-       "yyyy. MM. dd\0"
-       "yy. MM. dd\0"
-       "yyyy'\xeb\x85\x84' MM'\xec\x9b\x94' dd'\xec\x9d\xbc'\0"
-       "yy'\xeb\x85\x84' M'\xec\x9b\x94' d'\xec\x9d\xbc'\0"
-       "yy'\xeb\x85\x84' MM'\xec\x9b\x94' dd'\xec\x9d\xbc'\0"
-       "H'\xec\x8b\x9c' m'\xeb\xb6\x84'\0"
-       "H'\xec\x8b\x9c' mm'\xeb\xb6\x84'\0"
-       "HH'\xec\x8b\x9c' mm'\xeb\xb6\x84'\0"
-       "tt h'\xec\x8b\x9c' m'\xeb\xb6\x84'\0"
-       "tt h'\xec\x8b\x9c' mm'\xeb\xb6\x84'\0"
-       "tt hh'\xec\x8b\x9c' mm'\xeb\xb6\x84'\0"
-       "H'\xec\x8b\x9c' m'\xeb\xb6\x84' ss'\xec\xb4\x88'\0"
-       "HH'\xec\x8b\x9c' mm'\xeb\xb6\x84' ss'\xec\xb4\x88'\0"
-       "tt h'\xec\x8b\x9c' m'\xeb\xb6\x84' ss'\xec\xb4\x88'\0"
-       "tt hh'\xec\x8b\x9c' mm'\xeb\xb6\x84' ss'\xec\xb4\x88'\0"
-       "d-M-yyyy\0"
-       "d' de 'MMMM' de 'yyyy HH:mm:ss\0"
-       "H'h'm'min's's' z\0"
-       "'den 'd MMM yyyy HH:mm:ss\0"
-       "dd MMMM yyyy H:mm:ss\0"
-       "yyyy 'm.' MMMM d 'd.' HH:mm:ss\0"
-       "\xd4\xbf\xd5\xa5\xe2\x80\xa4\0"
-       "\xd5\x80\xd5\xb8\xd6\x82\xd5\xb6\xd5\xbe\xd5\xa1\xd6\x80\0"
-       "\xd5\x93\xd5\xa5\xd5\xbf\xd6\x80\xd5\xbe\xd5\xa1\xd6\x80\0"
-       "\xd5\x80\xd5\xb8\xd6\x82\xd5\xb6\xd5\xab\xd5\xbd\0"
-       "\xd5\x80\xd5\xb8\xd6\x82\xd5\xac\xd5\xab\xd5\xbd\0"
-       "\xd5\x80\xd5\xb6\xd5\xbe\0"
-       "\xd5\x93\xd5\xbf\xd5\xbe\0"
-       "\xd5\x80\xd5\xb6\xd5\xbd\0"
-       "\xd5\x80\xd5\xac\xd5\xbd\0"
-       "EEE, yyyy'eko' MMM'ren' dd'a' HH:mm:ss\0"
-       "EEE, yyyy'eko' MMM'ren' dd'a'\0"
-       "yyyy'eko' MMMM\0"
-       "yy'-'MM'-'dd\0"
-       "dd MMMM yyyy hh:mm:ss tt\0"
-       "yyyy '\xe1\x83\xac\xe1\x83\x9a\xe1\x83\x98\xe1\x83\xa1' dd MM, dddd H:mm:ss\0"
-       "yyyy '\xe1\x83\xac\xe1\x83\x9a\xe1\x83\x98\xe1\x83\xa1' dd MM, dddd\0"
-       "d. MMM yyyy HH.mm.ss\0"
-       "HH.mm.ss\0"
-       "yyyy MMMM d  h.mm.ss tt\0"
-       "h.mm.ss tt\0"
-       "d MMMM yyyy hh:mm:ss t z\0"
-       "d-MM-yy\0"
-       "hh:mm:ss t z\0"
-       "hh:mm t\0"
-       "d MMMM yyyy h:mm:ss t z\0"
-       "yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5' thh'\xe6\x97\xb6'mm'\xe5\x88\x86'ss'\xe7\xa7\x92'\0"
-       "yy-M-d\0"
-       "thh'\xe6\x97\xb6'mm'\xe5\x88\x86'ss'\xe7\xa7\x92'\0"
-       "th:mm\0"
-       "d' de 'MMMM' de 'yyyy H:mm:ss\0"
-       "d MMMM, yyyy hh:mm:ss tt\0"
-       "yyyy'\xe5\xb9\xb4'MM'\xe6\x9c\x88'dd'\xe6\x97\xa5' thh'\xe6\x99\x82'mm'\xe5\x88\x86'ss'\xe7\xa7\x92'\0"
-       "yy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5'\0"
-       "yyyy'\xe5\xb9\xb4'MM'\xe6\x9c\x88'\0"
-       "MM'\xe6\x9c\x88'dd'\xe6\x97\xa5'\0"
-       "dd. MMMM yyyy HH:mm:ss\0"
+       "\xe0\xa4\x93\xe0\xa4\x97\xe0\xa4\xb8\xe0\xa5\x8d\xe0\xa4\x9f\0"
+       "\xe0\xa4\xb8\xe0\xa5\x87\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x87\xe0\xa4\x82\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "\xe0\xa4\x93\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x8b\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "yyyy MMMM' \xe0\xb6\xb8\xe0\xb7\x83 'dd' \xe0\xb7\x80\xe0\xb7\x90\xe0\xb6\xb1\xe0\xb7\x92\xe0\xb6\xaf\xe0\xb7\x8f 'dddd\0"
+       "yyyy MMMM\0"
+       "\xe0\xb6\xb4\xe0\xb7\x99.\xe0\xb7\x80.\0"
+       "\xe0\xb6\xb4.\xe0\xb7\x80.\0"
+       "\xe0\xb6\x89\xe0\xb6\xbb\xe0\xb7\x92\xe0\xb6\xaf\xe0\xb7\x8f\0"
+       "\xe0\xb7\x83\xe0\xb6\xb3\xe0\xb7\x94\xe0\xb6\xaf\xe0\xb7\x8f\0"
+       "\xe0\xb6\x85\xe0\xb6\x9f\xe0\xb7\x84\xe0\xb6\xbb\xe0\xb7\x94\xe0\xb7\x80\xe0\xb7\x8f\xe0\xb6\xaf\xe0\xb7\x8f\0"
+       "\xe0\xb6\xb6\xe0\xb6\xaf\xe0\xb7\x8f\xe0\xb6\xaf\xe0\xb7\x8f\0"
+       "\xe0\xb6\xb6\xe0\xb7\x8a\xe2\x80\x8d\xe0\xb6\xbb\xe0\xb7\x84\xe0\xb7\x83\xe0\xb7\x8a\xe0\xb6\xb4\xe0\xb6\xad\xe0\xb7\x92\xe0\xb6\xb1\xe0\xb7\x8a\xe0\xb6\xaf\xe0\xb7\x8f\0"
+       "\xe0\xb7\x83\xe0\xb7\x92\xe0\xb6\x9a\xe0\xb7\x94\xe0\xb6\xbb\xe0\xb7\x8f\xe0\xb6\xaf\xe0\xb7\x8f\0"
+       "\xe0\xb7\x83\xe0\xb7\x99\xe0\xb6\xb1\xe0\xb7\x83\xe0\xb7\x94\xe0\xb6\xbb\xe0\xb7\x8f\xe0\xb6\xaf\xe0\xb7\x8f\0"
+       "\xe0\xb6\x89\xe0\xb6\xbb\xe0\xb7\x92\0"
+       "\xe0\xb7\x83\xe0\xb6\xb3\xe0\xb7\x94\0"
+       "\xe0\xb6\x85\xe0\xb6\x9f\0"
+       "\xe0\xb6\xb6\xe0\xb6\xaf\xe0\xb7\x8f\0"
+       "\xe0\xb6\xb6\xe0\xb7\x8a\xe2\x80\x8d\xe0\xb6\xbb\xe0\xb7\x84\0"
+       "\xe0\xb7\x83\xe0\xb7\x92\xe0\xb6\x9a\xe0\xb7\x94\0"
+       "\xe0\xb7\x83\xe0\xb7\x99\xe0\xb6\xb1\0"
+       "\xe0\xb6\x89\0"
+       "\xe0\xb7\x83\0"
+       "\xe0\xb6\x85\0"
+       "\xe0\xb6\xb6\0"
+       "\xe0\xb6\xb6\xe0\xb7\x8a\xe2\x80\x8d\xe0\xb6\xbb\0"
+       "\xe0\xb7\x83\xe0\xb7\x92\0"
+       "\xe0\xb7\x83\xe0\xb7\x99\0"
+       "\xe0\xb6\xa2\xe0\xb6\xb1\xe0\xb7\x80\xe0\xb7\x8f\xe0\xb6\xbb\xe0\xb7\x92\0"
+       "\xe0\xb6\xb4\xe0\xb7\x99\xe0\xb6\xb6\xe0\xb6\xbb\xe0\xb7\x80\xe0\xb7\x8f\xe0\xb6\xbb\xe0\xb7\x92\0"
+       "\xe0\xb6\xb8\xe0\xb7\x8f\xe0\xb6\xbb\xe0\xb7\x8a\xe0\xb6\xad\xe0\xb7\x94\0"
+       "\xe0\xb6\x85\xe0\xb6\xb4\xe0\xb7\x8a\xe2\x80\x8d\xe0\xb6\xbb\xe0\xb7\x9a\xe0\xb6\xbd\xe0\xb7\x8a\0"
+       "\xe0\xb6\xb8\xe0\xb7\x90\xe0\xb6\xba\xe0\xb7\x92\0"
+       "\xe0\xb6\xa2\xe0\xb7\x96\xe0\xb6\xb1\xe0\xb7\x92\0"
+       "\xe0\xb6\xa2\xe0\xb7\x96\xe0\xb6\xbd\xe0\xb7\x92\0"
+       "\xe0\xb6\x85\xe0\xb6\x9c\xe0\xb7\x9d\xe0\xb7\x83\xe0\xb7\x8a\xe0\xb6\xad\xe0\xb7\x94\0"
+       "\xe0\xb7\x83\xe0\xb7\x90\xe0\xb6\xb4\xe0\xb7\x8a\xe0\xb6\xad\xe0\xb7\x90\xe0\xb6\xb8\xe0\xb7\x8a\xe0\xb6\xb6\xe0\xb6\xbb\xe0\xb7\x8a\0"
+       "\xe0\xb6\x94\xe0\xb6\x9a\xe0\xb7\x8a\xe0\xb6\xad\xe0\xb7\x9d\xe0\xb6\xb6\xe0\xb6\xbb\xe0\xb7\x8a\0"
+       "\xe0\xb6\xb1\xe0\xb7\x9c\xe0\xb7\x80\xe0\xb7\x90\xe0\xb6\xb8\xe0\xb7\x8a\xe0\xb6\xb6\xe0\xb6\xbb\xe0\xb7\x8a\0"
+       "\xe0\xb6\xaf\xe0\xb7\x99\xe0\xb7\x83\xe0\xb7\x90\xe0\xb6\xb8\xe0\xb7\x8a\xe0\xb6\xb6\xe0\xb6\xbb\xe0\xb7\x8a\0"
+       "\xe0\xb6\xa2\xe0\xb6\xb1\0"
+       "\xe0\xb6\xb4\xe0\xb7\x99\xe0\xb6\xb6\0"
+       "\xe0\xb6\xb8\xe0\xb7\x8f\xe0\xb6\xbb\xe0\xb7\x8a\0"
+       "\xe0\xb6\x85\xe0\xb6\x9c\xe0\xb7\x9d\0"
+       "\xe0\xb7\x83\xe0\xb7\x90\xe0\xb6\xb4\xe0\xb7\x8a\0"
+       "\xe0\xb6\x94\xe0\xb6\x9a\xe0\xb7\x8a\0"
+       "\xe0\xb6\xb1\xe0\xb7\x9c\xe0\xb7\x80\xe0\xb7\x90\0"
+       "\xe0\xb6\xaf\xe0\xb7\x99\xe0\xb7\x83\xe0\xb7\x90\0"
+       "dddd '\xe1\x8d\xa3' MMMM d '\xe1\x89\x80\xe1\x8a\x95' yyyy\0"
+       "MMMM d \xe1\x89\x80\xe1\x8a\x95\0"
+       "\xe1\x8c\xa1\xe1\x8b\x8b\xe1\x89\xb5\0"
+       "\xe1\x8a\xa8\xe1\x88\xb3\xe1\x8b\x93\xe1\x89\xb5\0"
+       "\xe1\x8a\xa5\xe1\x88\x91\xe1\x8b\xb5\0"
+       "\xe1\x88\xb0\xe1\x8a\x9e\0"
+       "\xe1\x88\x9b\xe1\x8a\xad\xe1\x88\xb0\xe1\x8a\x9e\0"
+       "\xe1\x88\xa8\xe1\x89\xa1\xe1\x8b\x95\0"
+       "\xe1\x88\x90\xe1\x88\x99\xe1\x88\xb5\0"
+       "\xe1\x8b\x93\xe1\x88\xad\xe1\x89\xa5\0"
+       "\xe1\x89\x85\xe1\x8b\xb3\xe1\x88\x9c\0"
+       "\xe1\x88\x9b\xe1\x8a\xad\xe1\x88\xb0\0"
+       "\xe1\x8a\xa5\0"
+       "\xe1\x88\xb0\0"
+       "\xe1\x88\x9b\0"
+       "\xe1\x88\xa8\0"
+       "\xe1\x88\x90\0"
+       "\xe1\x8b\x93\0"
+       "\xe1\x89\x85\0"
+       "\xe1\x8c\x83\xe1\x8a\x95\xe1\x8b\xa9\xe1\x8b\x88\xe1\x88\xaa\0"
+       "\xe1\x8d\x8c\xe1\x89\xa5\xe1\x88\xa9\xe1\x8b\x88\xe1\x88\xaa\0"
+       "\xe1\x88\x9b\xe1\x88\xad\xe1\x89\xbd\0"
+       "\xe1\x8a\xa4\xe1\x8d\x95\xe1\x88\xa8\xe1\x88\x8d\0"
+       "\xe1\x88\x9c\xe1\x8b\xad\0"
+       "\xe1\x8c\x81\xe1\x8a\x95\0"
+       "\xe1\x8c\x81\xe1\x88\x8b\xe1\x8b\xad\0"
+       "\xe1\x8a\xa6\xe1\x8c\x88\xe1\x88\xb5\xe1\x89\xb5\0"
+       "\xe1\x88\xb4\xe1\x8d\x95\xe1\x89\xb4\xe1\x88\x9d\xe1\x89\xa0\xe1\x88\xad\0"
+       "\xe1\x8a\xa6\xe1\x8a\xad\xe1\x89\xb0\xe1\x8b\x8d\xe1\x89\xa0\xe1\x88\xad\0"
+       "\xe1\x8a\x96\xe1\x89\xac\xe1\x88\x9d\xe1\x89\xa0\xe1\x88\xad\0"
+       "\xe1\x8b\xb2\xe1\x88\xb4\xe1\x88\x9d\xe1\x89\xa0\xe1\x88\xad\0"
+       "\xe1\x8c\x83\xe1\x8a\x95\xe1\x8b\xa9\0"
+       "\xe1\x8d\x8c\xe1\x89\xa5\xe1\x88\xa9\0"
+       "\xe1\x8a\xa4\xe1\x8d\x95\xe1\x88\xa8\0"
+       "\xe1\x8a\xa6\xe1\x8c\x88\xe1\x88\xb5\0"
+       "\xe1\x88\xb4\xe1\x8d\x95\xe1\x89\xb4\0"
+       "\xe1\x8a\xa6\xe1\x8a\xad\xe1\x89\xb0\0"
+       "\xe1\x8a\x96\xe1\x89\xac\xe1\x88\x9d\0"
+       "\xe1\x8b\xb2\xe1\x88\xb4\xe1\x88\x9d\0"
+       "Zdat azal\0"
+       "\xe1\xb8\x8c\x65\x66\x66ir aza\0"
+       "Asamas\0"
+       "Aynas\0"
+       "Asinas\0"
+       "Akras\0"
+       "Akwas\0"
+       "Asimwas\0"
+       "Asi\xe1\xb8\x8dyas\0"
+       "Asa\0"
+       "Ayn\0"
+       "Asn\0"
+       "Akr\0"
+       "Akw\0"
+       "Asm\0"
+       "As\xe1\xb8\x8d\0"
+       "Yennayer\0"
+       "Yebrayer\0"
+       "Mars\0"
+       "Ibrir\0"
+       "Mayyu\0"
+       "Yunyu\0"
+       "Yulyuz\0"
+       "\xc6\x94uct\0"
+       "Cutanbir\0"
+       "K\xe1\xb9\xaduber\0"
+       "Nwanbir\0"
+       "Dujanbir\0"
+       "Yen\0"
+       "Yeb\0"
+       "Ibr\0"
+       "Yun\0"
+       "Yul\0"
+       "\xc6\x94uc\0"
+       "Cut\0"
+       "K\xe1\xb9\xadu\0"
+       "Nwa\0"
+       "Duj\0"
+       "hh:mm\0"
+       "MMMM,yyyy\0"
+       "\xe0\xa4\xaa\xe0\xa5\x82\xe0\xa4\xb0\xe0\xa5\x8d\xe0\xa4\xb5 \xe0\xa4\xae\xe0\xa4\xa7\xe0\xa5\x8d\xe0\xa4\xaf\xe0\xa4\xbe\xe0\xa4\xa8\xe0\xa5\x8d\xe0\xa4\xb9\0"
+       "\xe0\xa4\x89\xe0\xa4\xa4\xe0\xa5\x8d\xe0\xa4\xa4\xe0\xa4\xb0 \xe0\xa4\xae\xe0\xa4\xa7\xe0\xa5\x8d\xe0\xa4\xaf\xe0\xa4\xbe\xe0\xa4\xa8\xe0\xa5\x8d\xe0\xa4\xb9\0"
+       "\xe0\xa4\x86\xe0\xa4\x87\xe0\xa4\xa4\xe0\xa4\xac\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\xb8\xe0\xa5\x8b\xe0\xa4\xae\xe0\xa4\xac\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\xae\xe0\xa4\x99\xe0\xa5\x8d\xe0\xa4\x97\xe0\xa4\xb2\xe0\xa4\xac\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\xac\xe0\xa5\x81\xe0\xa4\xa7\xe0\xa4\xac\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\xac\xe0\xa4\xbf\xe0\xa4\xb9\xe0\xa5\x80\xe0\xa4\xac\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\xb6\xe0\xa5\x81\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa4\xac\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\xb6\xe0\xa4\xa8\xe0\xa4\xbf\xe0\xa4\xac\xe0\xa4\xbe\xe0\xa4\xb0\0"
+       "\xe0\xa4\x86\xe0\xa4\x87\xe0\xa4\xa4\0"
+       "\xe0\xa4\xae\xe0\xa4\x99\xe0\xa5\x8d\xe0\xa4\x97\xe0\xa4\xb2\0"
+       "\xe0\xa4\xac\xe0\xa4\xbf\xe0\xa4\xb9\xe0\xa5\x80\0"
+       "\xe0\xa5\xa7\0"
+       "\xe0\xa5\xa8\0"
+       "\xe0\xa5\xa9\0"
+       "\xe0\xa5\xaa\0"
+       "\xe0\xa5\xab\0"
+       "\xe0\xa5\xac\0"
+       "\xe0\xa5\xad\0"
+       "\xe0\xa4\xab\xe0\xa5\x87\xe0\xa4\xac\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa5\x81\xe0\xa4\x85\xe0\xa4\xb0\xe0\xa5\x80\0"
+       "\xe0\xa4\x85\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa4\xbf\xe0\xa4\xb2\0"
+       "\xe0\xa4\x9c\xe0\xa5\x81\xe0\xa4\xa8\0"
+       "\xe0\xa4\xb8\xe0\xa5\x87\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x87\xe0\xa4\xae\xe0\xa5\x8d\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "\xe0\xa4\x85\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x8b\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "\xe0\xa4\xa8\xe0\xa5\x8b\xe0\xa4\xad\xe0\xa5\x87\xe0\xa4\xae\xe0\xa5\x8d\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "\xe0\xa4\xa1\xe0\xa4\xbf\xe0\xa4\xb8\xe0\xa5\x87\xe0\xa4\xae\xe0\xa5\x8d\xe0\xa4\xac\xe0\xa4\xb0\0"
+       "\xe0\xa4\x9c\xe0\xa4\xa8\0"
+       "\xe0\xa4\xab\xe0\xa5\x87\xe0\xa4\xac\0"
+       "\xe0\xa4\x85\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa4\xbf\0"
+       "\xe0\xa4\x9c\xe0\xa5\x81\xe0\xa4\xb2\xe0\xa4\xbe\0"
+       "\xe0\xa4\x85\xe0\xa4\x97\0"
+       "\xe0\xa4\xb8\xe0\xa5\x87\xe0\xa4\xaa\xe0\xa5\x8d\xe0\xa4\x9f\0"
+       "\xe0\xa4\x85\xe0\xa4\x95\xe0\xa5\x8d\xe0\xa4\x9f\xe0\xa5\x8b\0"
+       "\xe0\xa4\xa8\xe0\xa5\x8b\xe0\xa4\xad\xe0\xa5\x87\0"
+       "\xe0\xa4\xa1\xe0\xa4\xbf\xe0\xa4\xb8\xe0\xa5\x87\0"
+       "\xd9\x88\xd8\xb1\xdb\x8c\0"
+       "\xd8\xba\xd9\x88\xdb\x8c\xdb\x8c\0"
+       "\xd8\xba\xd8\xa8\xd8\xb1\xda\xab\xd9\x88\xd9\x84\xdb\x8c\0"
+       "\xda\x86\xd9\x86\xda\xab\xd8\xa7\xda\x9a\0"
+       "\xd8\xb2\xd9\x85\xd8\xb1\xdb\x8c\0"
+       "\xd9\x88\xda\x96\xdb\x8c\0"
+       "\xd8\xaa\xd9\x84\xd9\x87\0"
+       "\xd9\x84\xda\x93\xd9\x85\0"
+       "\xd9\x84\xdb\x8c\xd9\x86\xd8\xaf\xdb\x8d\0"
+       "\xd9\x85\xd8\xb1\xd8\xba\xd9\x88\xd9\x85\xdb\x8c\0"
+       "\xd8\xb3\xd9\x84\xd9\x88\xd8\xa7\xd8\xba\xd9\x87\0"
+       "\xda\xa9\xd8\xa8\0"
+       "dd/MM/yyyy '\xd9\x87\xd9\x80'\0"
+       "Linggo\0"
+       "Lunes\0"
+       "Miyerkules\0"
+       "Huwebes\0"
+       "Biyernes\0"
+       "Sabado\0"
+       "Lin\0"
+       "Miy\0"
+       "Huw\0"
+       "Biy\0"
+       "Enero\0"
+       "Pebrero\0"
+       "Marso\0"
+       "Mayo\0"
+       "Hunyo\0"
+       "Hulyo\0"
+       "Setyembre\0"
+       "Oktubre\0"
+       "Nobyembre\0"
+       "Disyembre\0"
+       "Ene\0"
+       "Peb\0"
+       "Hun\0"
+       "Hul\0"
+       "Nob\0"
+       "Lahadi\0"
+       "Litinin\0"
+       "Talata\0"
+       "Laraba\0"
+       "Alhamis\0"
+       "Jumma'a\0"
+       "Asabar\0"
+       "Lh\0"
+       "Li\0"
+       "Ta\0"
+       "Lr\0"
+       "Al\0"
+       "Ju\0"
+       "As\0"
+       "Janairu\0"
+       "Faburairu\0"
+       "Maris\0"
+       "Afirilu\0"
+       "Mayu\0"
+       "Yuni\0"
+       "Yuli\0"
+       "Agusta\0"
+       "Satumba\0"
+       "Nuwamba\0"
+       "Disamba\0"
+       "Fab\0"
+       "Afi\0"
+       "Agu\0"
+       "Nuw\0"
+       "\xc3\x80\xc3\xa1r\xe1\xbb\x8d\xcc\x80\0"
+       "\xe1\xbb\x8c\xcc\x80s\xc3\xa1n\0"
+       "\xe1\xbb\x8cj\xe1\xbb\x8d\xcc\x81 \xc3\x80\xc3\xack\xc3\xba\0"
+       "\xe1\xbb\x8cj\xe1\xbb\x8d\xcc\x81 Aj\xc3\xa9\0"
+       "\xe1\xbb\x8cj\xe1\xbb\x8d\xcc\x81 \xc3\x8cs\xe1\xba\xb9\xcc\x81gun\0"
+       "\xe1\xbb\x8cj\xe1\xbb\x8d\xcc\x81r\xc3\xba\0"
+       "\xe1\xbb\x8cj\xe1\xbb\x8d\xcc\x81\x62\xe1\xbb\x8d\0"
+       "\xe1\xbb\x8cj\xe1\xbb\x8d\xcc\x81 \xe1\xba\xb8t\xc3\xac\0"
+       "\xe1\xbb\x8cj\xe1\xbb\x8d\xcc\x81 \xc3\x80\x62\xc3\xa1m\xe1\xba\xb9\xcc\x81ta\0"
+       "\xc3\x80\xc3\xack\xc3\xba\0"
+       "Aj\xc3\xa9\0"
+       "\xc3\x8cs\xe1\xba\xb9\xcc\x81gun\0"
+       "\xe1\xba\xb8t\xc3\xac\0"
+       "\xc3\x80\x62\xc3\xa1m\xe1\xba\xb9\xcc\x81ta\0"
+       "O\xe1\xb9\xa3\xc3\xb9 \xe1\xb9\xa2\xe1\xba\xb9\xcc\x81r\xe1\xba\xb9\xcc\x81\0"
+       "O\xe1\xb9\xa3\xc3\xb9 \xc3\x88r\xc3\xa8l\xc3\xa8\0"
+       "O\xe1\xb9\xa3\xc3\xb9 \xe1\xba\xb8r\xe1\xba\xb9\xcc\x80n\xc3\xa0\0"
+       "O\xe1\xb9\xa3\xc3\xb9 \xc3\x8cgb\xc3\xa9\0"
+       "O\xe1\xb9\xa3\xc3\xb9 \xe1\xba\xb8\xcc\x80\x62ibi\0"
+       "O\xe1\xb9\xa3\xc3\xb9 \xc3\x92k\xc3\xba\x64u\0"
+       "O\xe1\xb9\xa3\xc3\xb9 Ag\xe1\xba\xb9m\xe1\xbb\x8d\0"
+       "O\xe1\xb9\xa3\xc3\xb9 \xc3\x92g\xc3\xban\0"
+       "O\xe1\xb9\xa3\xc3\xb9 Owewe\0"
+       "O\xe1\xb9\xa3\xc3\xb9 \xe1\xbb\x8c\xcc\x80w\xc3\xa0r\xc3\xa0\0"
+       "O\xe1\xb9\xa3\xc3\xb9 B\xc3\xa9l\xc3\xba\0"
+       "O\xe1\xb9\xa3\xc3\xb9 \xe1\xbb\x8c\xcc\x80p\xe1\xba\xb9\xcc\x80\0"
+       "\xe1\xb9\xa2\xe1\xba\xb9\xcc\x81r\xe1\xba\xb9\xcc\x81\0"
+       "\xc3\x88r\xc3\xa8l\xc3\xa8\0"
+       "\xe1\xba\xb8r\xe1\xba\xb9\xcc\x80n\xc3\xa0\0"
+       "\xc3\x8cgb\xc3\xa9\0"
+       "\xe1\xba\xb8\xcc\x80\x62ibi\0"
+       "\xc3\x92k\xc3\xba\x64u\0"
+       "Ag\xe1\xba\xb9m\xe1\xbb\x8d\0"
+       "\xc3\x92g\xc3\xban\0"
+       "Owewe\0"
+       "\xe1\xbb\x8c\xcc\x80w\xc3\xa0r\xc3\xa0\0"
+       "B\xc3\xa9l\xc3\xba\0"
+       "\xe1\xbb\x8c\xcc\x80p\xe1\xba\xb9\xcc\x80\0"
+       "Sontaga\0"
+       "Mosupalogo\0"
+       "Labohlano\0"
+       "Mokibelo\0"
+       "Mok\0"
+       "Janaware\0"
+       "Feberware\0"
+       "Mat\xc5\xa1he\0"
+       "Aporele\0"
+       "Julae\0"
+       "Agostose\0"
+       "Setemere\0"
+       "Oktobore\0"
+       "Nofemere\0"
+       "Disemere\0"
+       "Apo\0"
+       "Nof\0"
+       "u.t.\0"
+       "u.k.\0"
+       "sabaat\0"
+       "ataasinngorneq\0"
+       "marlunngorneq\0"
+       "pingasunngorneq\0"
+       "sisamanngorneq\0"
+       "tallimanngorneq\0"
+       "arfininngorneq\0"
+       "ata\0"
+       "pin\0"
+       "sis\0"
+       "tal\0"
+       "arf\0"
+       "martsi\0"
+       "aprili\0"
+       "maji\0"
+       "augustusi\0"
+       "septemberi\0"
+       "oktoberi\0"
+       "novemberi\0"
+       "decemberi\0"
+       "A.M.\0"
+       "P.M.\0"
+       "Mb\xe1\xbb\x8ds\xe1\xbb\x8b \xe1\xbb\xa4ka\0"
+       "M\xe1\xbb\x8dnde\0"
+       "Tiuzdee\0"
+       "Wenezdee\0"
+       "T\xe1\xbb\x8d\xe1\xbb\x8dzdee\0"
+       "Fra\xe1\xbb\x8b\x64\x65\x65\0"
+       "Sat\xe1\xbb\x8d\x64\x65\x65\0"
+       "\xe1\xbb\xa4ka\0"
+       "M\xe1\xbb\x8dn\0"
+       "Tiu\0"
+       "Wen\0"
+       "T\xe1\xbb\x8d\xe1\xbb\x8d\0"
+       "Fra\xe1\xbb\x8b\0"
+       "Jen\xe1\xbb\xa5war\xe1\xbb\x8b\0"
+       "Febr\xe1\xbb\xa5war\xe1\xbb\x8b\0"
+       "Maach\xe1\xbb\x8b\0"
+       "Eprel\0"
+       "Mee\0"
+       "Juun\0"
+       "Jula\xe1\xbb\x8b\0"
+       "\xe1\xbb\x8cg\xe1\xbb\x8d\xe1\xbb\x8dst\0"
+       "\xe1\xbb\x8cktoba\0"
+       "Jen\0"
+       "Maa\0"
+       "Juu\0"
+       "\xe1\xbb\x8cg\xe1\xbb\x8d\0"
+       "\xe1\xbb\x8ckt\0"
+       "yyyy'\xea\x88\x8e' M'\xea\x86\xaa' d'\xea\x91\x8d'\0"
+       "yyyy'\xea\x88\x8e' M'\xea\x86\xaa'\0"
+       "M'\xea\x86\xaa' d'\xea\x91\x8d'\0"
+       "\xea\x8e\xb8\xea\x84\x91\0"
+       "\xea\x81\xaf\xea\x8b\x92\0"
+       "\xea\x91\xad\xea\x86\x8f\xea\x91\x8d\0"
+       "\xea\x86\x8f\xea\x8a\x82\xea\x8b\x8d\0"
+       "\xea\x86\x8f\xea\x8a\x82\xea\x91\x8d\0"
+       "\xea\x86\x8f\xea\x8a\x82\xea\x8c\x95\0"
+       "\xea\x86\x8f\xea\x8a\x82\xea\x87\x96\0"
+       "\xea\x86\x8f\xea\x8a\x82\xea\x89\xac\0"
+       "\xea\x86\x8f\xea\x8a\x82\xea\x83\x98\0"
+       "\xea\x91\xad\xea\x86\x8f\0"
+       "\xea\x86\x8f\xea\x8b\x8d\0"
+       "\xea\x86\x8f\xea\x91\x8d\0"
+       "\xea\x86\x8f\xea\x8c\x95\0"
+       "\xea\x86\x8f\xea\x87\x96\0"
+       "\xea\x86\x8f\xea\x89\xac\0"
+       "\xea\x86\x8f\xea\x83\x98\0"
+       "\xea\x86\x8f\0"
+       "\xea\x8b\x8d\0"
+       "\xea\x91\x8d\0"
+       "\xea\x8c\x95\0"
+       "\xea\x87\x96\0"
+       "\xea\x89\xac\0"
+       "\xea\x83\x98\0"
+       "\xea\x8b\x8d\xea\x86\xaa\0"
+       "\xea\x91\x8d\xea\x86\xaa\0"
+       "\xea\x8c\x95\xea\x86\xaa\0"
+       "\xea\x87\x96\xea\x86\xaa\0"
+       "\xea\x89\xac\xea\x86\xaa\0"
+       "\xea\x83\x98\xea\x86\xaa\0"
+       "\xea\x8f\x83\xea\x86\xaa\0"
+       "\xea\x89\x86\xea\x86\xaa\0"
+       "\xea\x88\xac\xea\x86\xaa\0"
+       "\xea\x8a\xb0\xea\x86\xaa\0"
+       "\xea\x8a\xb0\xea\x8a\xaa\xea\x86\xaa\0"
+       "\xea\x8a\xb0\xea\x91\x8b\xea\x86\xaa\0"
+       "dddd, yyyy'\xea\x88\x8e' M'\xea\x86\xaa' d'\xea\x91\x8d'\0"
+       "yyyy'\xea\x88\x8e' M'\xea\x86\xaa' d'\xea\x91\x8d', dddd\0"
+       "Meurzh\0"
+       "Merc\xca\xbcher\0"
+       "Yaou\0"
+       "Gwener\0"
+       "Sadorn\0"
+       "sul\0"
+       "meu.\0"
+       "yaou\0"
+       "gwe.\0"
+       "sad.\0"
+       "lu\0"
+       "mz\0"
+       "mc\0"
+       "ya\0"
+       "gw\0"
+       "sa\0"
+       "Genver\0"
+       "C\xca\xbchwevrer\0"
+       "Ebrel\0"
+       "Mae\0"
+       "Mezheven\0"
+       "Gouere\0"
+       "Eost\0"
+       "Gwengolo\0"
+       "Here\0"
+       "Kerzu\0"
+       "Gen\0"
+       "C\xca\xbchwe\0"
+       "Meur\0"
+       "Mezh\0"
+       "Goue\0"
+       "Gwen\0"
+       "Ker\0"
+       "dddd,' lo 'd MMMM' de 'yyyy\0"
+       "Dimenge\0"
+       "diluns\0"
+       "dimar\xc3\xa7\0"
+       "dim\xc3\xa8\x63res\0"
+       "dij\xc3\xb2us\0"
+       "div\xc3\xa8ndres\0"
+       "geni\xc3\xa8r\0"
+       "febri\xc3\xa8r\0"
+       "junh\0"
+       "julhet\0"
+       "oct\xc3\xb2\x62re\0"
+       "dezembre\0"
+       "v.m.\0"
+       "n.m.\0"
+       "Sunntig\0"
+       "M\xc3\xa4\xc3\xa4ntig\0"
+       "Ziischtig\0"
+       "Mittwuch\0"
+       "Dunschtig\0"
+       "Friitig\0"
+       "Samschtig\0"
+       "Su.\0"
+       "M\xc3\xa4.\0"
+       "Zi.\0"
+       "Mi.\0"
+       "Du.\0"
+       "Fr.\0"
+       "Sa.\0"
+       "Auguscht\0"
+       "Sept\xc3\xa4mber\0"
+       "Oktoober\0"
+       "Nov\xc3\xa4mber\0"
+       "Dez\xc3\xa4mber\0"
+       "MMMM d yyyy '\xd1\x81.'\0"
+       "MM.dd.yyyy\0"
+       "MMMM yyyy '\xd1\x81.'\0"
+       "\xd0\xad\xd0\x98\0"
+       "\xd0\xad\xd0\x9a\0"
+       "\xd0\x91\xd0\xb0\xd1\x81\xd0\xba\xd1\x8b\xd2\xbb\xd1\x8b\xd0\xb0\xd0\xbd\xd0\xbd\xd1\x8c\xd0\xb0\0"
+       "\xd0\x91\xd1\x8d\xd0\xbd\xd0\xb8\xd0\xb4\xd0\xb8\xd1\x8d\xd0\xbb\xd0\xb8\xd0\xbd\xd0\xbd\xd1\x8c\xd0\xb8\xd0\xba\0"
+       "\xd0\x9e\xd0\xbf\xd1\x82\xd1\x83\xd0\xbe\xd1\x80\xd1\x83\xd0\xbd\xd0\xbd\xd1\x8c\xd1\x83\xd0\xba\0"
+       "\xd0\xa1\xd1\x8d\xd1\x80\xd1\x8d\xd0\xb4\xd1\x8d\0"
+       "\xd0\xa7\xd1\x8d\xd0\xbf\xd0\xbf\xd0\xb8\xd1\x8d\xd1\x80\0"
+       "\xd0\x91\xd1\x8d\xd1\x8d\xd1\x82\xd0\xb8\xd2\xa5\xd1\x81\xd1\x8d\0"
+       "\xd0\xa1\xd1\x83\xd0\xb1\xd1\x83\xd0\xbe\xd1\x82\xd0\xb0\0"
+       "\xd0\x91\xd1\x81\0"
+       "\xd0\x91\xd0\xbd\0"
+       "\xd0\x9e\xd0\xbf\0"
+       "\xd0\xa1\xd1\x8d\0"
+       "\xd0\xa7\xd0\xbf\0"
+       "\xd0\x91\xd1\x8d\0"
+       "\xd0\x91\0"
+       "\xd0\x9e\0"
+       "\xd0\xa2\xd0\xbe\xd1\x85\xd1\x81\xd1\x83\xd0\xbd\xd0\xbd\xd1\x8c\xd1\x83\0"
+       "\xd0\x9e\xd0\xbb\xd1\x83\xd0\xbd\xd0\xbd\xd1\x8c\xd1\x83\0"
+       "\xd0\x9a\xd1\x83\xd0\xbb\xd1\x83\xd0\xbd \xd1\x82\xd1\x83\xd1\x82\xd0\xb0\xd1\x80\0"
+       "\xd0\x9c\xd1\x83\xd1\x83\xd1\x81 \xd1\x83\xd1\x81\xd1\x82\xd0\xb0\xd1\x80\0"
+       "\xd0\xab\xd0\xb0\xd0\xbc \xd1\x8b\xd0\xb9\xd1\x8b\xd0\xbd\0"
+       "\xd0\x91\xd1\x8d\xd1\x81 \xd1\x8b\xd0\xb9\xd1\x8b\xd0\xbd\0"
+       "\xd0\x9e\xd1\x82 \xd1\x8b\xd0\xb9\xd1\x8b\xd0\xbd\0"
+       "\xd0\x90\xd1\x82\xd1\x8b\xd1\x80\xd0\xb4\xd1\x8c\xd1\x8b\xd1\x85 \xd1\x8b\xd0\xb9\xd1\x8b\xd0\xbd\0"
+       "\xd0\x91\xd0\xb0\xd0\xbb\xd0\xb0\xd2\x95\xd0\xb0\xd0\xbd \xd1\x8b\xd0\xb9\xd1\x8b\xd0\xbd\0"
+       "\xd0\x90\xd0\xbb\xd1\x82\xd1\x8b\xd0\xbd\xd0\xbd\xd1\x8c\xd1\x8b\0"
+       "\xd0\xa1\xd1\x8d\xd1\x82\xd0\xb8\xd0\xbd\xd0\xbd\xd1\x8c\xd0\xb8\0"
+       "\xd0\x90\xd1\x85\xd1\x81\xd1\x8b\xd0\xbd\xd0\xbd\xd1\x8c\xd1\x8b\0"
+       "\xd0\xa2\xd0\xbe\xd1\x85\xd1\x81\0"
+       "\xd0\x9e\xd0\xbb\xd1\x83\xd0\xbd\0"
+       "\xd0\x9a\xd0\xbb\xd0\xbd_\xd1\x82\xd1\x82\xd1\x80\0"
+       "\xd0\x9c\xd1\x83\xd1\x81_\xd1\x83\xd1\x81\xd1\x82\0"
+       "\xd0\xab\xd0\xb0\xd0\xbc_\xd0\xb9\xd0\xbd\0"
+       "\xd0\x91\xd1\x8d\xd1\x81_\xd0\xb9\xd0\xbd\0"
+       "\xd0\x9e\xd1\x82_\xd0\xb9\xd0\xbd\0"
+       "\xd0\x90\xd1\x82\xd1\x80\xd0\xb4\xd1\x8c_\xd0\xb9\xd0\xbd\0"
+       "\xd0\x91\xd0\xbb\xd2\x95\xd0\xbd_\xd0\xb9\xd0\xbd\0"
+       "\xd0\x90\xd0\xbb\xd1\x82\0"
+       "\xd0\xa1\xd1\x8d\xd1\x82\0"
+       "\xd0\x90\xd1\x85\xd1\x81\0"
+       "MM.dd.yy\0"
+       "MM-dd-yyyy\0"
+       "MMMM dd yyyy '\xd1\x81.'\0"
+       "Ku cyumweru\0"
+       "Kuwa mbere\0"
+       "Kuwa kabiri\0"
+       "Kuwa gatatu\0"
+       "Kuwa kane\0"
+       "Kuwa gatanu\0"
+       "Kuwa gatandatu\0"
+       "cyu.\0"
+       "mbe.\0"
+       "kab.\0"
+       "gtu.\0"
+       "kan.\0"
+       "gnu.\0"
+       "gnd.\0"
+       "Mutarama\0"
+       "Gashyantare\0"
+       "Werurwe\0"
+       "Mata\0"
+       "Gicuransi\0"
+       "Kamena\0"
+       "Nyakanga\0"
+       "Kanama\0"
+       "Nzeli\0"
+       "Ukwakira\0"
+       "Ugushyingo\0"
+       "Ukuboza\0"
+       "mut.\0"
+       "gas.\0"
+       "wer.\0"
+       "mat.\0"
+       "gic.\0"
+       "kam.\0"
+       "nya.\0"
+       "nze.\0"
+       "ukw.\0"
+       "ugu.\0"
+       "uku.\0"
+       "DiD\xc3\xb2mhnaich\0"
+       "DiLuain\0"
+       "DiM\xc3\xa0irt\0"
+       "DiCiadain\0"
+       "Diardaoin\0"
+       "DihAoine\0"
+       "DiSathairne\0"
+       "DiD\0"
+       "DiL\0"
+       "DiM\0"
+       "DiC\0"
+       "Dia\0"
+       "Dih\0"
+       "DiS\0"
+       "Am Faoilleach\0"
+       "An Gearran\0"
+       "Am M\xc3\xa0rt\0"
+       "An Giblean\0"
+       "An C\xc3\xa8itean\0"
+       "An t-\xc3\x92gmhios\0"
+       "An t-Iuchar\0"
+       "An L\xc3\xb9nastal\0"
+       "An t-Sultain\0"
+       "An D\xc3\xa0mhair\0"
+       "An t-Samhain\0"
+       "An D\xc3\xb9\x62hlachd\0"
+       "Faoi\0"
+       "Gearr\0"
+       "M\xc3\xa0rt\0"
+       "Gibl\0"
+       "C\xc3\xa8it\0"
+       "\xc3\x92gmh\0"
+       "Iuch\0"
+       "L\xc3\xb9na\0"
+       "Sult\0"
+       "D\xc3\xa0mh\0"
+       "D\xc3\xb9\x62h\0"
+       "\xe9\x80\xb1\xe6\x97\xa5\0"
+       "\xe9\x80\xb1\xe4\xb8\x80\0"
+       "\xe9\x80\xb1\xe4\xba\x8c\0"
+       "\xe9\x80\xb1\xe4\xb8\x89\0"
+       "\xe9\x80\xb1\xe5\x9b\x9b\0"
+       "\xe9\x80\xb1\xe4\xba\x94\0"
+       "\xe9\x80\xb1\xe5\x85\xad\0"
+       "yakshanba\0"
+       "dushanba\0"
+       "seshanba\0"
+       "chorshanba\0"
+       "payshanba\0"
+       "cuma\0"
+       "shanba\0"
+       "Yaksh\0"
+       "Dush\0"
+       "Sesh\0"
+       "Chor\0"
+       "Pay\0"
+       "Shan\0"
+       "Y\0"
+       "Iyun\0"
+       "Iyul\0"
+       "Avgust\0"
+       "Yanv\0"
+       "Fev\0"
+       "Avg\0"
+       "Noya\0"
+       "Dek\0"
+       "dd. M. yy\0"
+       "d. MMM yy\0"
+       "H.mm' u.'\0"
+       "tysdag\0"
+       "laurdag\0"
+       "tys\0"
+       "d/M\0"
+       "Segunda-feira\0"
+       "Ter\xc3\xa7\x61-feira\0"
+       "Quarta-feira\0"
+       "Quinta-feira\0"
+       "Sexta-feira\0"
+       "Janeiro\0"
+       "Fevereiro\0"
+       "Mar\xc3\xa7o\0"
+       "Junho\0"
+       "Julho\0"
+       "Dezembro\0"
+       "d/MMM/yy\0"
+       "d.MMM.yy\0"
+       "HH'H'mm'm'\0"
+       "\xd0\xb1\xd0\xb0\xd0\xb7\xd0\xb0\xd1\x80\0"
+       "\xd0\xb1\xd0\xb0\xd0\xb7\xd0\xb0\xd1\x80 \xd0\xb5\xd1\x80\xd1\x82\xd3\x99\xd1\x81\xd0\xb8\0"
+       "\xd1\x87\xd3\x99\xd1\x80\xd1\x88\xd3\x99\xd0\xbd\xd0\xb1\xd3\x99 \xd0\xb0\xd1\x85\xd1\x88\xd0\xb0\xd0\xbc\xd1\x8b\0"
+       "\xd1\x87\xd3\x99\xd1\x80\xd1\x88\xd3\x99\xd0\xbd\xd0\xb1\xd3\x99\0"
+       "\xd2\xb9\xd2\xaf\xd0\xbc\xd3\x99 \xd0\xb0\xd1\x85\xd1\x88\xd0\xb0\xd0\xbc\xd1\x8b\0"
+       "\xd2\xb9\xd2\xaf\xd0\xbc\xd3\x99\0"
+       "\xd1\x88\xd3\x99\xd0\xbd\xd0\xb1\xd3\x99\0"
+       "\xd1\x98\xd0\xb0\xd0\xbd\xd0\xb2\xd0\xb0\xd1\x80\0"
+       "\xd1\x84\xd0\xb5\xd0\xb2\xd1\x80\xd0\xb0\xd0\xbb\0"
+       "\xd0\xb0\xd0\xbf\xd1\x80\xd0\xb5\xd0\xbb\0"
+       "\xd0\xb8\xd1\x98\xd1\x83\xd0\xbd\0"
+       "\xd0\xb8\xd1\x98\xd1\x83\xd0\xbb\0"
+       "\xd1\x81\xd0\xb5\xd0\xbd\xd1\x82\xd1\x98\xd0\xb0\xd0\xb1\xd1\x80\0"
+       "\xd0\xbe\xd0\xba\xd1\x82\xd1\x98\xd0\xb0\xd0\xb1\xd1\x80\0"
+       "\xd0\xbd\xd0\xbe\xd1\x98\xd0\xb0\xd0\xb1\xd1\x80\0"
+       "\xd0\xb4\xd0\xb5\xd0\xba\xd0\xb0\xd0\xb1\xd1\x80\0"
+       "yyyy '\xd0\xb9\xd0\xb8\xd0\xbb' d-MMMM\0"
+       "yyyy'\xe1\xa0\xa3\xe1\xa0\xa8 \xe1\xa0\xa4\xe1\xa0\x8b' M'\xe1\xa0\xb0\xe1\xa0\xa0\xe1\xa0\xb7\xe1\xa0\x8e\xe1\xa0\xa0 \xe2\x80\xaf\xe1\xa0\xa2\xe1\xa0\xa2\xe1\xa0\xa8 'd' \xe1\xa0\xa4\xe1\xa0\x8b \xe1\xa0\xa1\xe1\xa0\xb3\xe1\xa0\xa6\xe1\xa0\xb7'\0"
+       "yyyy'\xe1\xa0\xa3\xe1\xa0\xa8' M'\xe1\xa0\xb0\xe1\xa0\xa0\xe1\xa0\xb7\xe1\xa0\x8e\xe1\xa0\xa0'\0"
+       "M'\xe1\xa0\xb0\xe1\xa0\xa0\xe1\xa0\xb7\xe1\xa0\x8e\xe1\xa0\xa0' d'\xe1\xa0\xa1\xe1\xa0\xb3\xe1\xa0\xa6\xe1\xa0\xb7'\0"
+       "yyyy'\xe1\xa0\xa3\xe1\xa0\xa8 \xe1\xa0\xa4\xe1\xa0\x8b' M'\xe1\xa0\xb0\xe1\xa0\xa0\xe1\xa0\xb7\xe1\xa0\x8e\xe1\xa0\xa0 \xe2\x80\xaf\xe1\xa0\xa2\xe1\xa0\xa2\xe1\xa0\xa8 'd' \xe1\xa0\xa4\xe1\xa0\x8b \xe1\xa0\xa1\xe1\xa0\xb3\xe1\xa0\xa6\xe1\xa0\xb7\xe1\xa0\x82' dddd\0"
+       "dddd, dd. MMMM yyyy\0"
        "J\xc3\xa4nner\0"
        "J\xc3\xa4n\0"
-       "M\xc3\xa4r\0"
-       "d MMMM yyyy h:mm:ss tt\0"
-       "dddd, dd' de 'MMMM' de 'yyyy H:mm:ss\0"
-       "dddd, dd' de 'MMMM' de 'yyyy\0"
-       "MMMM' de 'yyyy\0"
-       "dd MMM yyyy t hh:mm:ss\0"
-       "dd MMM yyyy\0"
-       "t hh:mm:ss\0"
-       "t hh:mm\0"
-       "MMMM d, yyyy h:mm:ss tt\0"
+       "dd.M.yyyy\0"
+       "d.MMMM yyyy\0"
+       "d.MMMyyyy\0"
+       "HH:mm' Uhr'\0"
+       "H:mm' Uhr'\0"
+       "aejlege\0"
+       "m\xc3\xa5\x61nta\0"
+       "d\xc3\xa4jsta\0"
+       "gaskevahkoe\0"
+       "d\xc3\xa5\x61rsta\0"
+       "bearjadahke\0"
+       "laavadahke\0"
+       "o\xc4\x91\xc4\x91\x61jage\0"
+       "guovva\0"
+       "njuk\xc4\x8d\x61\0"
+       "cuo\xc5\x8bo\0"
+       "miesse\0"
+       "geasse\0"
+       "suoidne\0"
+       "borge\0"
+       "\xc4\x8d\x61k\xc4\x8d\x61\0"
+       "golggot\0"
+       "sk\xc3\xa1\x62ma\0"
+       "juovla\0"
+       "MMMM-dd-yy\0"
+       "M/dd/yy\0"
        "MMMM d, yyyy\0"
-       "d MMMM, yyyy H:mm:ss\0"
+       "dddd yyyy'\xe5\xb9\xb4'M'\xe6\x9c\x88'd'\xe6\x97\xa5'\0"
+       "dddd yyyy MM dd\0"
+       "pre podne\0"
+       "popodne\0"
+       "ponedeljak\0"
+       "mart\0"
+       "septembar\0"
+       "oktobar\0"
+       "novembar\0"
+       "decembar\0"
+       "\xd0\xbf\xd1\x80\xd0\xb5 \xd0\xbf\xd0\xbe\xd0\xb4\xd0\xbd\xd0\xb5\0"
+       "\xd0\xbf\xd0\xbe\xd0\xbf\xd0\xbe\xd0\xb4\xd0\xbd\xd0\xb5\0"
+       "\xd0\xbd\xd0\xb5\xd0\xb4\xd0\xb5\xd1\x99\xd0\xb0\0"
+       "\xd0\xbf\xd0\xbe\xd0\xbd\xd0\xb5\xd0\xb4\xd0\xb5\xd1\x99\xd0\xb0\xd0\xba\0"
+       "\xd1\x83\xd1\x82\xd0\xbe\xd1\x80\xd0\xb0\xd0\xba\0"
+       "\xd1\x81\xd1\x80\xd0\xb8\xd1\x98\xd0\xb5\xd0\xb4\xd0\xb0\0"
+       "\xd1\x87\xd0\xb5\xd1\x82\xd0\xb2\xd1\x80\xd1\x82\xd0\xb0\xd0\xba\0"
+       "\xd0\xbf\xd0\xb5\xd1\x82\xd0\xb0\xd0\xba\0"
+       "\xd0\xbd\xd0\xb5\xd0\xb4\0"
+       "\xd0\xbf\xd0\xbe\xd0\xbd\0"
+       "\xd1\x83\xd1\x82\xd0\xbe\0"
+       "\xd1\x81\xd1\x80\xd0\xb8\0"
+       "\xd1\x87\xd0\xb5\xd1\x82\0"
+       "\xd0\xbf\xd0\xb5\xd1\x82\0"
+       "\xd1\x81\xd1\x83\xd0\xb1\0"
+       "\xd1\x83\0"
+       "\xd1\x98\xd0\xb0\xd0\xbd\xd1\x83\xd0\xb0\xd1\x80\0"
+       "\xd1\x84\xd0\xb5\xd0\xb1\xd1\x80\xd1\x83\xd0\xb0\xd1\x80\0"
+       "\xd1\x81\xd0\xb5\xd0\xbf\xd1\x82\xd0\xb5\xd0\xbc\xd0\xb1\xd0\xb0\xd1\x80\0"
+       "\xd0\xbe\xd0\xba\xd1\x82\xd0\xbe\xd0\xb1\xd0\xb0\xd1\x80\0"
+       "\xd0\xbd\xd0\xbe\xd0\xb2\xd0\xb5\xd0\xbc\xd0\xb1\xd0\xb0\xd1\x80\0"
+       "\xd0\xb4\xd0\xb5\xd1\x86\xd0\xb5\xd0\xbc\xd0\xb1\xd0\xb0\xd1\x80\0"
+       "\xd1\x98\xd0\xb0\xd0\xbd\0"
+       "\xd1\x84\xd0\xb5\xd0\xb1\0"
+       "\xd0\xbc\xd0\xb0\xd1\x80\0"
+       "\xd0\xb0\xd0\xbf\xd1\x80\0"
+       "\xd1\x98\xd1\x83\xd0\xbd\0"
+       "\xd1\x98\xd1\x83\xd0\xbb\0"
+       "\xd0\xb0\xd0\xb2\xd0\xb3\0"
+       "\xd1\x81\xd0\xb5\xd0\xbf\0"
+       "\xd0\xbe\xd0\xba\xd1\x82\0"
+       "\xd0\xbd\xd0\xbe\xd0\xb2\0"
+       "\xd0\xb4\xd0\xb5\xd1\x86\0"
        "\xd9\x83\xd8\xa7\xd9\x86\xd9\x88\xd9\x86 \xd8\xa7\xd9\x84\xd8\xab\xd8\xa7\xd9\x86\xd9\x8a\0"
        "\xd8\xb4\xd8\xa8\xd8\xa7\xd8\xb7\0"
        "\xd8\xa2\xd8\xb0\xd8\xa7\xd8\xb1\0"
        "\xd9\x86\xd9\x8a\xd8\xb3\xd8\xa7\xd9\x86\0"
-       "\xd9\x86\xd9\x88\xd8\xa7\xd8\xb1\0"
+       "\xd8\xa3\xd9\x8a\xd8\xa7\xd8\xb1\0"
        "\xd8\xad\xd8\xb2\xd9\x8a\xd8\xb1\xd8\xa7\xd9\x86\0"
        "\xd8\xaa\xd9\x85\xd9\x88\xd8\xb2\0"
        "\xd8\xa2\xd8\xa8\0"
@@ -2934,170 +4909,208 @@ static const char locale_strings [] = {
        "\xd8\xaa\xd8\xb4\xd8\xb1\xd9\x8a\xd9\x86 \xd8\xa7\xd9\x84\xd8\xa3\xd9\x88\xd9\x84\0"
        "\xd8\xaa\xd8\xb4\xd8\xb1\xd9\x8a\xd9\x86 \xd8\xa7\xd9\x84\xd8\xab\xd8\xa7\xd9\x86\xd9\x8a\0"
        "\xd9\x83\xd8\xa7\xd9\x86\xd9\x88\xd9\x86 \xd8\xa7\xd9\x84\xd8\xa3\xd9\x88\xd9\x84\0"
-       "\xd8\xa3\xd9\x8a\xd8\xa7\xd8\xb1\0"
-       "dddd, dd MMMM yyyy hh:mm:ss tt\0"
-       "dddd, dd MMMM yyyy\0"
-       "dd' de 'MMMM' de 'yyyy hh:mm:ss tt\0"
-       "dd' de 'MMMM' de 'yyyy\0"
-       "dd' de 'MMMM\0"
+       "\xd1\x81\xd1\x80\xd0\xb5\0"
+       "dddd, d MMMM, yyyy\0"
        "\xd9\xab\0"
        "\xd9\xac\0"
+       "\xd8\xb1.\xd8\xb3.\xe2\x80\x8f\0"
        "\xd9\xaa\0"
-       "\xef\xbf\xbd\0"
-       "\xe2\x80\xb0\0"
+       "\xd9\x84\xd9\x8a\xd8\xb3 \xd8\xb1\xd9\x82\xd9\x85\0"
+       "\xd8\x89\0"
        "-\xe2\x88\x9e\0"
-       "\xe2\x88\x9e\0"
+       "+\xe2\x88\x9e\0"
        "+\0"
        ",\0"
        "\xc2\xa0\0"
+       "\xd0\xbb\xd0\xb2.\0"
        "%\0"
        "NaN\0"
-       "-Infinity\0"
-       "Infinity\0"
-       "\xd8\xb1.\xd8\xb3.\xe2\x80\x8f\0"
-       "\xd0\xbb\xd0\xb2.\0"
+       "\xe2\x80\xb0\0"
        "\xe2\x82\xac\0"
-       "NT$\0"
+       "\xef\xbf\xa5\0"
        "K\xc4\x8d\0"
        "kr\0"
        "$\0"
+       "ep\xc3\xa4luku\0"
        "\xe2\x82\xaa\0"
        "Ft\0"
-       "kr.\0"
-       "\\\0"
-       "\xef\xbf\xa6\0"
+       "EiTa\0"
+       "\xe2\x88\x92\xe2\x88\x9e\0"
+       "\xe2\x88\x92\0"
+       "NaN\xef\xbc\x88\xe9\x9d\x9e\xe6\x95\xb0\xef\xbc\x89\0"
+       "\xe2\x82\xa9\0"
        "z\xc5\x82\0"
-       "R$ \0"
-       "lei\0"
-       "\xd1\x80.\0"
-       "Kn\0"
+       "R$\0"
+       "\xe2\x80\x99\0"
+       "\xd1\x80\xd1\x83\xd0\xb1.\0"
+       "\xd0\xbd\xd0\xb5 \xd1\x87\xd0\xb8\xd1\x81\xd0\xbb\xd0\xbe\0"
+       "kn\0"
        "Lek\0"
+       "\xc2\xa4\xc2\xa4\xc2\xa4\0"
        "\xe0\xb8\xbf\0"
        "TL\0"
+       "PKRs\0"
        "Rp\0"
-       "\xd0\xb3\xd1\x80\xd0\xbd.\0"
-       "SIT\0"
+       "\xe2\x82\xb4\0"
+       "\xd0\x9d\xd0\xb5 \xd1\x87\xd0\xb8\xd1\x81\xd0\xbb\xd0\xbe\0"
        "Ls\0"
+       "nav\xc2\xa0skaitlis\0"
        "Lt\0"
        "\xef\xb7\xbc\0"
-       "\xc4\x91\0"
-       "Den\0"
-       "\xe0\xa4\xb0\xe0\xa5\x81\0"
-       "KSh\0"
-       "\xe0\xaa\xb0\xe0\xab\x81\0"
-       "\xe0\xae\xb0\xe0\xaf\x82\0"
-       "\xe0\xb0\xb0\xe0\xb1\x82.\0"
+       "\xe2\x82\xab\0"
+       "\xd5\xa4\xd6\x80.\0"
+       "\xe2\x82\xb9\0"
+       "RM\0"
+       "\xd1\x81\xd0\xbe\xd0\xbc\0"
+       "Ksh\0"
+       "\xe0\xa6\x9f\xe0\xa6\xbe\0"
+       "\xe0\xa6\xb8\xe0\xa6\x82\xe0\xa6\x96\xe0\xa7\x8d\xe0\xa6\xaf\xe0\xa6\xbe \xe0\xa6\xa8\xe0\xa6\xbe\0"
+       "\xe0\xaa\xb8\xe0\xaa\x82\xe0\xaa\x96\xe0\xab\x8d\xe0\xaa\xaf\xe0\xaa\xbe \xe0\xaa\xa8\xe0\xaa\xa5\xe0\xab\x80\xe0\xaa\x82\0"
+       "\xe0\xae\x8e\xe0\xae\xa3\xe0\xaf\x8d \xe0\xae\x87\xe0\xae\xb2\xe0\xaf\x8d\xe0\xae\xb2\xe0\xaf\x88\0"
+       "\xe0\xb2\xb8\xe0\xb2\x82\xe0\xb2\x96\xe0\xb3\x8d\xe0\xb2\xaf\xe0\xb3\x86\xe0\xb2\xaf\xe0\xb2\xb2\xe0\xb3\x8d\xe0\xb2\xb2\0"
+       "\xe0\xa4\xa8\xe0\xa4\xbe\xe0\xa4\xa8\0"
+       "CN\xc2\xa5\0"
+       "\xc2\xa3\0"
+       "\xe1\x9f\x9b\0"
+       "\xe2\x82\xad\0"
+       "\xe0\xb6\xbb\xe0\xb7\x94.\0"
+       "\xe1\x89\xa5\xe1\x88\xad\0"
+       "\xe0\xa4\xa8\xe0\xa5\x87\xe0\xa4\xb0\xe0\xa5\x82\0"
+       "\xd8\x8b\0"
+       "\xe2\x82\xb1\0"
+       "\xe2\x82\xa6\0"
+       "RF\0"
+       "NT$\0"
+       "\xe9\x9d\x9e\xe6\x95\xb8\xe5\x80\xbc\0"
+       "man.\0"
+       "so\xca\xbcm\0"
        "\xd8\xaf.\xd8\xb9.\xe2\x80\x8f\0"
-       "\xef\xbf\xa5\0"
        "'\0"
-       "SFr.\0"
-       "\xc2\xa3\0"
+       "\xd0\xbc\xd0\xb0\xd0\xbd.\0"
+       "\xd1\x81\xd1\x9e\xd0\xbc\0"
+       "\xe0\xa7\xb3\0"
        "\xd8\xac.\xd9\x85.\xe2\x80\x8f\0"
-       "HK$\0"
        "\xd8\xaf.\xd9\x84.\xe2\x80\x8f\0"
-       "S$\0"
-       "Q\0"
-       "sFr.\0"
        "\xd8\xaf.\xd8\xac.\xe2\x80\x8f\0"
-       "CRC\0"
+       "\xe2\x82\xa1\0"
        "\xd8\xaf.\xd9\x85.\xe2\x80\x8f\0"
-       "B/\0"
+       "B/.\0"
+       "KM\0"
        "\xd8\xaf.\xd8\xaa.\xe2\x80\x8f\0"
-       "RD$\0"
+       "\xd0\x9a\xd0\x9c.\0"
        "\xd8\xb1.\xd8\xb9.\xe2\x80\x8f\0"
-       "Bs\0"
+       "Bs.F.\0"
        "\xd8\xb1.\xd9\x8a.\xe2\x80\x8f\0"
+       "din.\0"
        "\xd9\x84.\xd8\xb3.\xe2\x80\x8f\0"
-       "S/\0"
+       "S/.\0"
+       "\xd0\xb4\xd0\xb8\xd0\xbd.\0"
        "\xd8\xaf.\xd8\xa3.\xe2\x80\x8f\0"
        "\xd9\x84.\xd9\x84.\xe2\x80\x8f\0"
-       "Z$\0"
-       "S/.\0"
        "\xd8\xaf.\xd9\x83.\xe2\x80\x8f\0"
-       "PHP\0"
        "\xd8\xaf.\xd8\xa5.\xe2\x80\x8f\0"
-       "NU$\0"
        "\xd8\xaf.\xd8\xa8.\xe2\x80\x8f\0"
-       "Gs\0"
+       "\xe2\x82\xb2\0"
        "\xd8\xb1.\xd9\x82.\xe2\x80\x8f\0"
-       "$b\0"
-       "SVC\0"
-       "L.\0"
+       "Bs\0"
+       "US$\0"
        "C$\0"
+       "\xd0\x94\xd0\xb8\xd0\xbd.\0"
+       "Din.\0"
+       "\xc2\xa5\0"
+       "HK$\0"
        "ar\0"
        "Arabic\0"
        "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9\0"
        "ARA\0"
        "ara\0"
+       "\xd8\xa7\xd9\x84\xd8\xaa\xd9\x82\xd9\x88\xd9\x8a\xd9\x85 \xd8\xa7\xd9\x84\xd9\x87\xd8\xac\xd8\xb1\xd9\x8a\0"
        "bg\0"
        "Bulgarian\0"
-       "\xd0\x91\xd1\x8a\xd0\xbb\xd0\xb3\xd0\xb0\xd1\x80\xd1\x81\xd0\xba\xd0\xb8\0"
+       "\xd0\xb1\xd1\x8a\xd0\xbb\xd0\xb3\xd0\xb0\xd1\x80\xd1\x81\xd0\xba\xd0\xb8\0"
        "BGR\0"
        "bul\0"
+       "\xd0\x93\xd1\x80\xd0\xb8\xd0\xb3\xd0\xbe\xd1\x80\xd0\xb8\xd0\xb0\xd0\xbd\xd1\x81\xd0\xba\xd0\xb8 \xd0\xba\xd0\xb0\xd0\xbb\xd0\xb5\xd0\xbd\xd0\xb4\xd0\xb0\xd1\x80\0"
        "ca\0"
        "Catalan\0"
        "catal\xc3\xa0\0"
        "CAT\0"
        "cat\0"
+       "calendari gregori\xc3\xa0\0"
        "zh-CHS\0"
-       "Chinese\0"
+       "Chinese (Simplified) Legacy\0"
        "\xe4\xb8\xad\xe6\x96\x87\0"
        "CHS\0"
        "zho\0"
        "zh\0"
+       "\xe5\x85\xac\xe5\x8e\x86\0"
+       "zh-Hans\0"
+       "Chinese (Simplified)\0"
        "cs\0"
        "Czech\0"
-       "\xc4\x8c\x65\xc5\xa1tina\0"
+       "\xc4\x8d\x65\xc5\xa1tina\0"
        "CSY\0"
        "ces\0"
+       "Gregori\xc3\xa1nsk\xc3\xbd kalend\xc3\xa1\xc5\x99\0"
        "da\0"
        "Danish\0"
-       "Dansk\0"
+       "dansk\0"
        "DAN\0"
        "dan\0"
+       "gregoriansk kalender\0"
        "de\0"
        "German\0"
        "Deutsch\0"
        "DEU\0"
        "deu\0"
+       "Gregorianischer Kalender\0"
        "el\0"
        "Greek\0"
        "\xce\x95\xce\xbb\xce\xbb\xce\xb7\xce\xbd\xce\xb9\xce\xba\xce\xac\0"
        "ELL\0"
        "ell\0"
+       "\xce\x93\xcf\x81\xce\xb7\xce\xb3\xce\xbf\xcf\x81\xce\xb9\xce\xb1\xce\xbd\xcf\x8c \xce\xb7\xce\xbc\xce\xb5\xcf\x81\xce\xbf\xce\xbb\xcf\x8c\xce\xb3\xce\xb9\xce\xbf\0"
        "en\0"
        "English\0"
        "ENU\0"
        "eng\0"
+       "Gregorian Calendar\0"
        "es\0"
        "Spanish\0"
        "espa\xc3\xb1ol\0"
        "ESP\0"
        "spa\0"
+       "calendario gregoriano\0"
        "fi\0"
        "Finnish\0"
        "suomi\0"
        "FIN\0"
        "fin\0"
+       "gregoriaaninen kalenteri\0"
+       "fr\0"
        "French\0"
        "fran\xc3\xa7\x61is\0"
        "FRA\0"
        "fra\0"
+       "Calendrier gr\xc3\xa9gorien\0"
        "he\0"
        "Hebrew\0"
        "\xd7\xa2\xd7\x91\xd7\xa8\xd7\x99\xd7\xaa\0"
        "HEB\0"
        "heb\0"
+       "\xd7\x9c\xd7\x95\xd7\x97 \xd7\xa9\xd7\xa0\xd7\x94 \xd7\x92\xd7\xa8\xd7\x92\xd7\x95\xd7\xa8\xd7\x99\xd7\x90\xd7\xa0\xd7\x99\0"
        "hu\0"
        "Hungarian\0"
        "magyar\0"
        "HUN\0"
        "hun\0"
+       "Gergely-napt\xc3\xa1r\0"
        "is\0"
        "Icelandic\0"
        "\xc3\xadslenska\0"
        "ISL\0"
        "isl\0"
+       "Gregor\xc3\xadskt dagatal\0"
        "it\0"
        "Italian\0"
        "italiano\0"
@@ -3108,54 +5121,70 @@ static const char locale_strings [] = {
        "\xe6\x97\xa5\xe6\x9c\xac\xe8\xaa\x9e\0"
        "JPN\0"
        "jpn\0"
+       "\xe8\xa5\xbf\xe6\x9a\xa6[\xe3\x82\xb0\xe3\x83\xac\xe3\x82\xb4\xe3\x83\xaa\xe3\x82\xaa\xe6\x9a\xa6]\0"
        "ko\0"
        "Korean\0"
        "\xed\x95\x9c\xea\xb5\xad\xec\x96\xb4\0"
        "KOR\0"
        "kor\0"
+       "\xed\x83\x9c\xec\x96\x91\xeb\xa0\xa5\0"
        "nl\0"
        "Dutch\0"
        "Nederlands\0"
        "NLD\0"
        "nld\0"
+       "Gregoriaanse kalender\0"
        "no\0"
        "Norwegian\0"
        "norsk\0"
        "NOR\0"
-       "nor\0"
+       "nob\0"
+       "nb\0"
        "pl\0"
        "Polish\0"
        "polski\0"
        "PLK\0"
        "pol\0"
+       "kalendarz gregoria\xc5\x84ski\0"
        "pt\0"
        "Portuguese\0"
        "portugu\xc3\xaas\0"
        "PTB\0"
        "por\0"
+       "Calend\xc3\xa1rio Gregoriano\0"
+       "rm\0"
+       "Romansh\0"
+       "rumantsch\0"
+       "RMC\0"
+       "roh\0"
+       "chalender gregorian\0"
        "ro\0"
        "Romanian\0"
-       "Rom\xc3\xa2n\xc4\x83\0"
+       "rom\xc3\xa2n\xc4\x83\0"
        "ROM\0"
        "ron\0"
+       "calendar gregorian\0"
        "ru\0"
        "Russian\0"
-       "\xd0\xa0\xd1\x83\xd1\x81\xd1\x81\xd0\xba\xd0\xb8\xd0\xb9\0"
+       "\xd1\x80\xd1\x83\xd1\x81\xd1\x81\xd0\xba\xd0\xb8\xd0\xb9\0"
        "RUS\0"
        "rus\0"
+       "\xd0\x93\xd1\x80\xd0\xb8\xd0\xb3\xd0\xbe\xd1\x80\xd0\xb8\xd0\xb0\xd0\xbd\xd1\x81\xd0\xba\xd0\xb8\xd0\xb9 \xd0\xba\xd0\xb0\xd0\xbb\xd0\xb5\xd0\xbd\xd0\xb4\xd0\xb0\xd1\x80\xd1\x8c\0"
        "hr\0"
        "Croatian\0"
        "hrvatski\0"
        "HRV\0"
        "hrv\0"
+       "gregorijanski kalendar\0"
        "sk\0"
        "Slovak\0"
-       "slovensk\xc3\xbd\0"
+       "sloven\xc4\x8dina\0"
        "SKY\0"
        "slk\0"
+       "Gregori\xc3\xa1nsky kalend\xc3\xa1r\0"
        "sq\0"
        "Albanian\0"
-       "shqipe\0"
+       "shqip\0"
        "SQI\0"
        "sqi\0"
        "sv\0"
@@ -3168,80 +5197,125 @@ static const char locale_strings [] = {
        "\xe0\xb9\x84\xe0\xb8\x97\xe0\xb8\xa2\0"
        "THA\0"
        "tha\0"
+       "\xe0\xb8\x9b\xe0\xb8\x8f\xe0\xb8\xb4\xe0\xb8\x97\xe0\xb8\xb4\xe0\xb8\x99\xe0\xb8\x9e\xe0\xb8\xb8\xe0\xb8\x97\xe0\xb8\x98\0"
        "tr\0"
        "Turkish\0"
        "T\xc3\xbcrk\xc3\xa7\x65\0"
        "TRK\0"
        "tur\0"
+       "Miladi Takvim\0"
+       "ur\0"
+       "Urdu\0"
+       "\xd8\xa7\xd8\xb1\xd8\xaf\xd9\x88\0"
+       "URD\0"
+       "urd\0"
+       "\xd8\xac\xd8\xa7\xd8\xb1\xd8\xac\xdb\x8c\xd8\xa7\xd8\xa6\xdb\x8c \xda\xa9\xdb\x8c\xd9\x84\xd9\x86\xda\x88\xd8\xb1\0"
        "id\0"
        "Indonesian\0"
        "Bahasa Indonesia\0"
        "IND\0"
        "ind\0"
+       "Kalender Gregorian\0"
        "uk\0"
        "Ukrainian\0"
-       "\xd0\xa3\xd0\xba\xd1\x80\xd0\xb0\xd1\x97\xd0\xbd\xd1\x81\xd1\x8c\xd0\xba\xd0\xb0\0"
+       "\xd1\x83\xd0\xba\xd1\x80\xd0\xb0\xd1\x97\xd0\xbd\xd1\x81\xd1\x8c\xd0\xba\xd0\xb0\0"
        "UKR\0"
        "ukr\0"
+       "\xd0\x93\xd1\x80\xd0\xb8\xd0\xb3\xd0\xbe\xd1\x80\xd1\x96\xd0\xb0\xd0\xbd\xd1\x81\xd1\x8c\xd0\xba\xd0\xb8\xd0\xb9 \xd0\xba\xd0\xb0\xd0\xbb\xd0\xb5\xd0\xbd\xd0\xb4\xd0\xb0\xd1\x80\0"
        "be\0"
        "Belarusian\0"
-       "\xd0\x91\xd0\xb5\xd0\xbb\xd0\xb0\xd1\x80\xd1\x83\xd1\x81\xd0\xba\xd1\x96\0"
+       "\xd0\xb1\xd0\xb5\xd0\xbb\xd0\xb0\xd1\x80\xd1\x83\xd1\x81\xd0\xba\xd0\xb0\xd1\x8f\0"
        "BEL\0"
        "bel\0"
+       "\xd0\xb3\xd1\x80\xd1\x8d\xd0\xb3\xd0\xb0\xd1\x80\xd1\x8b\xd1\x8f\xd0\xbd\xd1\x81\xd0\xba\xd1\x96 \xd0\xba\xd0\xb0\xd0\xbb\xd1\x8f\xd0\xbd\xd0\xb4\xd0\xb0\xd1\x80\0"
        "sl\0"
        "Slovenian\0"
-       "Sloven\xc5\xa1\xc4\x8dina\0"
+       "sloven\xc5\xa1\xc4\x8dina\0"
        "SLV\0"
        "slv\0"
+       "gregorijanski koledar\0"
        "et\0"
        "Estonian\0"
-       "Eesti\0"
+       "eesti\0"
        "ETI\0"
        "est\0"
+       "Gregoriuse kalender\0"
        "lv\0"
        "Latvian\0"
        "latvie\xc5\xa1u\0"
        "LVI\0"
        "lav\0"
+       "Gregora kalend\xc4\x81rs\0"
        "lt\0"
        "Lithuanian\0"
-       "Lietuvi\xc5\xb3\0"
+       "lietuvi\xc5\xb3\0"
        "LTH\0"
        "lit\0"
+       "Grigaliaus kalendorius\0"
+       "tg\0"
+       "Tajik\0"
+       "TAJ\0"
+       "tgk\0"
        "fa\0"
        "Persian\0"
        "\xd9\x81\xd8\xa7\xd8\xb1\xd8\xb3\xdb\x8c\0"
        "FAR\0"
        "fas\0"
+       "\xd8\xaa\xd9\x82\xd9\x88\xdb\x8c\xd9\x85 \xd9\x85\xdb\x8c\xd9\x84\xd8\xa7\xd8\xaf\xdb\x8c\0"
        "vi\0"
        "Vietnamese\0"
        "Ti\xe1\xba\xbfng Vi\xe1\xbb\x87t\0"
        "VIT\0"
+       "L\xe1\xbb\x8b\x63h Gregory\0"
        "hy\0"
        "Armenian\0"
        "\xd5\x80\xd5\xa1\xd5\xb5\xd5\xa5\xd6\x80\xd5\xa7\xd5\xb6\0"
        "HYE\0"
        "hye\0"
+       "Azerbaijani\0"
+       "az\xc9\x99rbaycanca\0"
+       "AZE\0"
+       "aze\0"
+       "Qreqoriy t\xc9\x99qvimi\0"
        "eu\0"
        "Basque\0"
        "euskara\0"
        "EUQ\0"
        "eus\0"
+       "Egutegi gregoriarra\0"
        "mk\0"
        "Macedonian\0"
        "\xd0\xbc\xd0\xb0\xd0\xba\xd0\xb5\xd0\xb4\xd0\xbe\xd0\xbd\xd1\x81\xd0\xba\xd0\xb8\0"
        "MKI\0"
        "mkd\0"
+       "\xd0\x93\xd1\x80\xd0\xb5\xd0\xb3\xd0\xbe\xd1\x80\xd0\xb8\xd1\x98\xd0\xb0\xd0\xbd\xd1\x81\xd0\xba\xd0\xb8 \xd0\xba\xd0\xb0\xd0\xbb\xd0\xb5\xd0\xbd\xd0\xb4\xd0\xb0\xd1\x80\0"
+       "tn\0"
+       "Tswana\0"
+       "Setswana\0"
+       "TSN\0"
+       "tsn\0"
+       "xh\0"
+       "Xhosa\0"
+       "isiXhosa\0"
+       "XHO\0"
+       "xho\0"
+       "zu\0"
+       "Zulu\0"
+       "isiZulu\0"
+       "ZUL\0"
+       "zul\0"
+       "i-Gregorian Calender\0"
        "af\0"
        "Afrikaans\0"
-       "Afrikaanse\0"
        "AFK\0"
        "afr\0"
+       "Gregoriese kalender\0"
        "ka\0"
        "Georgian\0"
        "\xe1\x83\xa5\xe1\x83\x90\xe1\x83\xa0\xe1\x83\x97\xe1\x83\xa3\xe1\x83\x9a\xe1\x83\x98\0"
        "KAT\0"
        "kat\0"
+       "\xe1\x83\x92\xe1\x83\xa0\xe1\x83\x98\xe1\x83\x92\xe1\x83\x9d\xe1\x83\xa0\xe1\x83\x98\xe1\x83\x90\xe1\x83\x9c\xe1\x83\xa3\xe1\x83\x9a\xe1\x83\x98 \xe1\x83\x99\xe1\x83\x90\xe1\x83\x9a\xe1\x83\x94\xe1\x83\x9c\xe1\x83\x93\xe1\x83\x90\xe1\x83\xa0\xe1\x83\x98\0"
        "fo\0"
        "Faroese\0"
        "f\xc3\xb8royskt\0"
@@ -3249,40 +5323,136 @@ static const char locale_strings [] = {
        "fao\0"
        "hi\0"
        "Hindi\0"
-       "\xe0\xa4\xb9\xe0\xa4\xbf\xe0\xa4\x82\xe0\xa4\xa6\xe0\xa5\x80\0"
+       "\xe0\xa4\xb9\xe0\xa4\xbf\xe0\xa4\xa8\xe0\xa5\x8d\xe0\xa4\xa6\xe0\xa5\x80\0"
        "HIN\0"
        "hin\0"
+       "\xe0\xa4\x97\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa5\x87\xe0\xa4\x97\xe0\xa4\xb0\xe0\xa5\x80 \xe0\xa4\xaa\xe0\xa4\x82\xe0\xa4\x9a\xe0\xa4\xbe\xe0\xa4\x82\xe0\xa4\x97\0"
+       "mt\0"
+       "Maltese\0"
+       "Malti\0"
+       "MLT\0"
+       "mlt\0"
+       "Kalendarju Gregorjan\0"
+       "se\0"
+       "Northern Sami\0"
+       "davvis\xc3\xa1megiella\0"
+       "SME\0"
+       "sme\0"
+       "ga\0"
+       "Irish\0"
+       "Gaeilge\0"
+       "IRE\0"
+       "gle\0"
+       "F\xc3\xa9ilire Greag\xc3\xb3rach\0"
+       "ms\0"
+       "Malay\0"
+       "Bahasa Melayu\0"
+       "MSL\0"
+       "msa\0"
+       "Kalendar Gregory\0"
+       "kk\0"
+       "Kazakh\0"
+       "\xd2\x9b\xd0\xb0\xd0\xb7\xd0\xb0\xd2\x9b \xd1\x82\xd1\x96\xd0\xbb\xd1\x96\0"
+       "KKZ\0"
+       "kaz\0"
+       "\xd0\x93\xd1\x80\xd0\xb5\xd0\xb3\xd0\xbe\xd1\x80\xd0\xb8\xd0\xb0\xd0\xbd\xd0\xb4\xd1\x8b\xd2\x9b \xd0\xba\xd2\xaf\xd0\xbd\xd1\x82\xd1\x96\xd0\xb7\xd0\xb1\xd0\xb5\0"
+       "ky\0"
+       "Kirghiz\0"
+       "\xd0\x9a\xd1\x8b\xd1\x80\xd0\xb3\xd1\x8b\xd0\xb7\0"
+       "KYR\0"
+       "kir\0"
        "sw\0"
        "Swahili\0"
        "Kiswahili\0"
        "SWK\0"
        "swa\0"
+       "Kalenda ya Kigregori\0"
+       "uz\0"
+       "Uzbek\0"
+       "\xd0\x8e\xd0\xb7\xd0\xb1\xd0\xb5\xd0\xba\0"
+       "UZB\0"
+       "uzb\0"
+       "bn\0"
+       "Bengali\0"
+       "\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\x82\xe0\xa6\xb2\xe0\xa6\xbe\0"
+       "BNG\0"
+       "bng\0"
+       "\xe0\xa6\x97\xe0\xa7\x8d\xe0\xa6\xb0\xe0\xa6\xbf\xe0\xa6\x97\xe0\xa7\x8b\xe0\xa6\xb0\xe0\xa6\xbf\xe0\xa6\xaf\xe0\xa6\xbc\xe0\xa6\xbe\xe0\xa6\xa8 \xe0\xa6\xac\xe0\xa6\xb0\xe0\xa7\x8d\xe0\xa6\xb7\xe0\xa6\xaa\xe0\xa6\x9e\xe0\xa7\x8d\xe0\xa6\x9c\xe0\xa7\x80\0"
+       "pa\0"
+       "Punjabi\0"
+       "\xe0\xa8\xaa\xe0\xa9\xb0\xe0\xa8\x9c\xe0\xa8\xbe\xe0\xa8\xac\xe0\xa9\x80\0"
+       "PAN\0"
+       "pan\0"
        "gu\0"
        "Gujarati\0"
        "\xe0\xaa\x97\xe0\xab\x81\xe0\xaa\x9c\xe0\xaa\xb0\xe0\xaa\xbe\xe0\xaa\xa4\xe0\xab\x80\0"
        "GUJ\0"
        "guj\0"
+       "\xe0\xaa\x97\xe0\xab\x8d\xe0\xaa\xb0\xe0\xab\x87\xe0\xaa\x97\xe0\xab\x8b\xe0\xaa\xb0\xe0\xaa\xbf\xe0\xaa\xaf\xe0\xaa\xa8 \xe0\xaa\x95\xe0\xab\x87\xe0\xaa\xb2\xe0\xab\x87\xe0\xaa\xa8\xe0\xab\x8d\xe0\xaa\xa1\xe0\xaa\xb0\0"
+       "Oriya\0"
+       "\xe0\xac\x93\xe0\xac\xa1\xe0\xac\xbc\xe0\xac\xbf\xe0\xac\x86\0"
+       "ORI\0"
+       "ori\0"
        "ta\0"
        "Tamil\0"
        "\xe0\xae\xa4\xe0\xae\xae\xe0\xae\xbf\xe0\xae\xb4\xe0\xaf\x8d\0"
        "TAM\0"
        "tam\0"
+       "\xe0\xae\x95\xe0\xae\xbf\xe0\xae\xb0\xe0\xae\xbf\xe0\xae\x95\xe0\xaf\x8b\xe0\xae\xb0\xe0\xae\xbf\xe0\xae\xaf\xe0\xae\xa9\xe0\xaf\x8d \xe0\xae\xa8\xe0\xae\xbe\xe0\xae\xb3\xe0\xaf\x8d\xe0\xae\x95\xe0\xae\xbe\xe0\xae\x9f\xe0\xaf\x8d\xe0\xae\x9f\xe0\xae\xbf\0"
        "te\0"
        "Telugu\0"
        "\xe0\xb0\xa4\xe0\xb1\x86\xe0\xb0\xb2\xe0\xb1\x81\xe0\xb0\x97\xe0\xb1\x81\0"
        "TEL\0"
        "tel\0"
-       "kn\0"
+       "\xe0\xb0\x97\xe0\xb1\x8d\xe0\xb0\xb0\xe0\xb1\x87\xe0\xb0\x97\xe0\xb1\x8b\xe0\xb0\xb0\xe0\xb0\xbf\xe0\xb0\xaf\xe0\xb0\xa8\xe0\xb1\x8d \xe0\xb0\x95\xe0\xb1\x8d\xe0\xb0\xaf\xe0\xb0\xbe\xe0\xb0\xb2\xe0\xb1\x86\xe0\xb0\x82\xe0\xb0\xa1\xe0\xb0\xb0\xe0\xb1\x8d\0"
        "Kannada\0"
        "\xe0\xb2\x95\xe0\xb2\xa8\xe0\xb3\x8d\xe0\xb2\xa8\xe0\xb2\xa1\0"
-       "KAN\0"
+       "KDI\0"
        "kan\0"
+       "\xe0\xb2\x97\xe0\xb3\x8d\xe0\xb2\xb0\xe0\xb3\x86\xe0\xb2\x97\xe0\xb3\x8a\xe0\xb2\xb0\xe0\xb2\xbf\xe0\xb2\xaf\xe0\xb2\xa8\xe0\xb3\x8d\xe2\x80\x8c \xe0\xb2\x95\xe0\xb3\x8d\xe0\xb2\xaf\xe0\xb2\xbe\xe0\xb2\xb2\xe0\xb3\x86\xe0\xb2\x82\xe0\xb2\xa1\xe0\xb2\xb0\xe0\xb3\x8d\xe2\x80\x8c\0"
+       "ml\0"
+       "Malayalam\0"
+       "\xe0\xb4\xae\xe0\xb4\xb2\xe0\xb4\xaf\xe0\xb4\xbe\xe0\xb4\xb3\xe0\xb4\x82\0"
+       "MYM\0"
+       "mym\0"
+       "\xe0\xb4\x87\xe0\xb4\x82\xe0\xb4\x97\xe0\xb5\x8d\xe0\xb4\xb2\xe0\xb5\x80\xe0\xb4\xb7\xe0\xb5\x8d \xe0\xb4\x95\xe0\xb4\xb2\xe0\xb4\xa3\xe0\xb5\x8d\xe0\xb4\x9f\xe0\xb4\xb0\xe0\xb5\x8d\xe2\x80\x8d\0"
+       "Assamese\0"
+       "\xe0\xa6\x85\xe0\xa6\xb8\xe0\xa6\xae\xe0\xa7\x80\xe0\xa6\xaf\xe0\xa6\xbc\xe0\xa6\xbe\0"
+       "ASM\0"
+       "asm\0"
+       "\xe0\xa6\x97\xe0\xa7\x8d\xe0\xa7\xb0\xe0\xa6\xbf\xe0\xa6\x97\xe0\xa7\x8b\xe0\xa7\xb0\xe0\xa7\x80\xe0\xa6\xaf\xe0\xa6\xbc \xe0\xa6\xaa\xe0\xa6\x9e\xe0\xa7\x8d\xe0\xa6\x9c\xe0\xa6\xbf\xe0\xa6\x95\xe0\xa6\xbe\0"
        "mr\0"
        "Marathi\0"
        "\xe0\xa4\xae\xe0\xa4\xb0\xe0\xa4\xbe\xe0\xa4\xa0\xe0\xa5\x80\0"
        "MAR\0"
+       "\xe0\xa4\x97\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa5\x87\xe0\xa4\x97\xe0\xa5\x8b\xe0\xa4\xb0\xe0\xa4\xbf\xe0\xa4\xaf\xe0\xa4\xa8 \xe0\xa4\xa6\xe0\xa4\xbf\xe0\xa4\xa8\xe0\xa4\xa6\xe0\xa4\xb0\xe0\xa5\x8d\xe0\xa4\xb6\xe0\xa4\xbf\xe0\xa4\x95\xe0\xa4\xbe\0"
+       "mn\0"
+       "Mongolian\0"
+       "\xd0\xbc\xd0\xbe\xd0\xbd\xd0\xb3\xd0\xbe\xd0\xbb\0"
+       "MON\0"
+       "mon\0"
+       "bo\0"
+       "Tibetan\0"
+       "\xe0\xbd\x94\xe0\xbd\xbc\xe0\xbd\x91\xe0\xbc\x8b\xe0\xbd\xa6\xe0\xbe\x90\xe0\xbd\x91\xe0\xbc\x8b\0"
+       "BOB\0"
+       "bod\0"
+       "cy\0"
+       "Welsh\0"
+       "Cymraeg\0"
+       "CYM\0"
+       "cym\0"
+       "km\0"
+       "Khmer\0"
+       "\xe1\x9e\x97\xe1\x9e\xb6\xe1\x9e\x9f\xe1\x9e\xb6\xe1\x9e\x81\xe1\x9f\x92\xe1\x9e\x98\xe1\x9f\x82\xe1\x9e\x9a\0"
+       "KHM\0"
+       "khm\0"
+       "lo\0"
+       "Lao\0"
+       "\xe0\xba\xa5\xe0\xba\xb2\xe0\xba\xa7\0"
+       "LAO\0"
+       "lao\0"
        "gl\0"
-       "Gallegan\0"
+       "Galician\0"
        "galego\0"
        "GLC\0"
        "glg\0"
@@ -3290,33 +5460,121 @@ static const char locale_strings [] = {
        "Konkani\0"
        "\xe0\xa4\x95\xe0\xa5\x8b\xe0\xa4\x82\xe0\xa4\x95\xe0\xa4\xa3\xe0\xa5\x80\0"
        "KNK\0"
+       "si\0"
+       "Sinhala\0"
+       "\xe0\xb7\x83\xe0\xb7\x92\xe0\xb6\x82\xe0\xb7\x84\xe0\xb6\xbd\0"
+       "SIN\0"
+       "sin\0"
+       "\xe0\xb6\xaf\xe0\xb7\x92\xe0\xb6\xb1\xe0\xb6\xaf\xe0\xb7\x83\xe0\xb7\x94\xe0\xb6\xb1\0"
+       "Amharic\0"
+       "\xe1\x8a\xa0\xe1\x88\x9b\xe1\x88\xad\xe1\x8a\x9b\0"
+       "AMH\0"
+       "amh\0"
+       "\xe1\x8b\xa8\xe1\x8c\x8d\xe1\x88\xaa\xe1\x8c\x8e\xe1\x88\xaa\xe1\x8b\xab\xe1\x8a\x95 \xe1\x89\x80\xe1\x8a\x95 \xe1\x8a\xa0\xe1\x89\x86\xe1\x8c\xa3\xe1\x8c\xa0\xe1\x88\xad\0"
+       "tzm\0"
+       "Central Morocco Tamazight\0"
+       "Tamazi\xc9\xa3t\0"
+       "TZM\0"
+       "Nepali\0"
+       "\xe0\xa4\xa8\xe0\xa5\x87\xe0\xa4\xaa\xe0\xa4\xbe\xe0\xa4\xb2\xe0\xa5\x80\0"
+       "NEP\0"
+       "nep\0"
+       "\xe0\xa4\x97\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa5\x87\xe0\xa4\x97\xe0\xa5\x8b\xe0\xa4\xb0\xe0\xa4\xbf\xe0\xa4\xaf\xe0\xa4\xa8 \xe0\xa4\xaa\xe0\xa4\xbe\xe0\xa4\xa4\xe0\xa5\x8d\xe0\xa4\xb0\xe0\xa5\x8b\0"
+       "ps\0"
+       "Pashto\0"
+       "\xd9\xbe\xda\x9a\xd8\xaa\xd9\x88\0"
+       "PAS\0"
+       "pus\0"
+       "fil\0"
+       "Filipino\0"
+       "FPO\0"
+       "Kalendaryong Gregorian\0"
+       "ha\0"
+       "Hausa\0"
+       "HAU\0"
+       "hau\0"
+       "yo\0"
+       "Yoruba\0"
+       "\xc3\x88\x64\xc3\xa8 Yor\xc3\xb9\x62\xc3\xa1\0"
+       "YOR\0"
+       "yor\0"
+       "nso\0"
+       "Northern Sotho\0"
+       "Sesotho sa Leboa\0"
+       "NSO\0"
+       "kl\0"
+       "Kalaallisut\0"
+       "kalaallisut\0"
+       "KAL\0"
+       "kal\0"
+       "Igbo\0"
+       "IBO\0"
+       "ibo\0"
+       "ii\0"
+       "Sichuan Yi\0"
+       "\xea\x86\x88\xea\x8c\xa0\xea\x89\x99\0"
+       "III\0"
+       "iii\0"
+       "\xea\x84\x89\xea\x89\xbb\xea\x83\x85\xea\x91\x8d\0"
+       "br\0"
+       "Breton\0"
+       "brezhoneg\0"
+       "BRE\0"
+       "bre\0"
+       "deiziadur gregorian\0"
+       "oc\0"
+       "Occitan\0"
+       "occitan\0"
+       "OCI\0"
+       "oci\0"
+       "gsw\0"
+       "Swiss German\0"
+       "Schwiizert\xc3\xbc\xc3\xbctsch\0"
+       "GSW\0"
+       "Gregoriaanisch Kal\xc3\xa4nder\0"
+       "sah\0"
+       "Sakha\0"
+       "\xd1\x81\xd0\xb0\xd1\x85\xd0\xb0 \xd1\x82\xd1\x8b\xd0\xbb\xd0\xb0\0"
+       "SAH\0"
+       "rw\0"
+       "Kinyarwanda\0"
+       "KIN\0"
+       "kin\0"
+       "gd\0"
+       "Scottish Gaelic\0"
+       "G\xc3\xa0idhlig\0"
+       "GLA\0"
+       "gla\0"
+       "Am M\xc3\xacosachan Griogarach\0"
        "ar-SA\0"
        "Arabic (Saudi Arabia)\0"
-       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 \xd8\xa7\xd9\x84\xd8\xb3\xd8\xb9\xd9\x88\xd8\xaf\xd9\x8a\xd8\xa9)\0"
+       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xa7\xd9\x84\xd9\x85\xd9\x85\xd9\x84\xd9\x83\xd8\xa9 \xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 \xd8\xa7\xd9\x84\xd8\xb3\xd8\xb9\xd9\x88\xd8\xaf\xd9\x8a\xd8\xa9)\0"
        "bg-BG\0"
        "Bulgarian (Bulgaria)\0"
-       "\xd0\x91\xd1\x8a\xd0\xbb\xd0\xb3\xd0\xb0\xd1\x80\xd1\x81\xd0\xba\xd0\xb8 (\xd0\x91\xd1\x8a\xd0\xbb\xd0\xb3\xd0\xb0\xd1\x80\xd0\xb8\xd1\x8f)\0"
+       "\xd0\xb1\xd1\x8a\xd0\xbb\xd0\xb3\xd0\xb0\xd1\x80\xd1\x81\xd0\xba\xd0\xb8 (\xd0\x91\xd1\x8a\xd0\xbb\xd0\xb3\xd0\xb0\xd1\x80\xd0\xb8\xd1\x8f)\0"
        "BG\0"
        "ca-ES\0"
        "Catalan (Spain)\0"
        "catal\xc3\xa0 (Espanya)\0"
        "ES\0"
        "zh-TW\0"
-       "Chinese (Taiwan)\0"
+       "Chinese (Traditional)\0"
        "\xe4\xb8\xad\xe6\x96\x87 (\xe5\x8f\xb0\xe6\xb9\xbe)\0"
        "CHT\0"
        "TW\0"
+       "\xe5\x85\xac\xe6\x9b\x86\0"
        "cs-CZ\0"
        "Czech (Czech Republic)\0"
-       "\xc4\x8c\x65\xc5\xa1tina (\xc4\x8c\x65sk\xc3\xa1 republika)\0"
+       "\xc4\x8d\x65\xc5\xa1tina (\xc4\x8c\x65sk\xc3\xa1 republika)\0"
        "CZ\0"
        "da-DK\0"
        "Danish (Denmark)\0"
-       "Dansk (Danmark)\0"
+       "dansk (Danmark)\0"
        "DK\0"
        "de-DE\0"
        "German (Germany)\0"
        "Deutsch (Deutschland)\0"
+       "DE\0"
        "el-GR\0"
        "Greek (Greece)\0"
        "\xce\x95\xce\xbb\xce\xbb\xce\xb7\xce\xbd\xce\xb9\xce\xba\xce\xac (\xce\x95\xce\xbb\xce\xbb\xce\xac\xce\xb4\xce\xb1)\0"
@@ -3361,11 +5619,8 @@ static const char locale_strings [] = {
        "Nederlands (Nederland)\0"
        "NL\0"
        "nb-NO\0"
-       "Norwegian Bokm?l (Norway)\0"
        "Norwegian Bokm\xc3\xa5l (Norway)\0"
        "norsk bokm\xc3\xa5l (Norge)\0"
-       "nob\0"
-       "nb\0"
        "NO\0"
        "pl-PL\0"
        "Polish (Poland)\0"
@@ -3375,13 +5630,16 @@ static const char locale_strings [] = {
        "Portuguese (Brazil)\0"
        "portugu\xc3\xaas (Brasil)\0"
        "BR\0"
+       "rm-CH\0"
+       "Romansh (Switzerland)\0"
+       "rumantsch (Svizra)\0"
        "ro-RO\0"
        "Romanian (Romania)\0"
-       "Rom\xc3\xa2n\xc4\x83 (Rom\xc3\xa2nia)\0"
+       "rom\xc3\xa2n\xc4\x83 (Rom\xc3\xa2nia)\0"
        "RO\0"
        "ru-RU\0"
        "Russian (Russia)\0"
-       "\xd0\xa0\xd1\x83\xd1\x81\xd1\x81\xd0\xba\xd0\xb8\xd0\xb9 (\xd0\xa0\xd0\xbe\xd1\x81\xd1\x81\xd0\xb8\xd1\x8f)\0"
+       "\xd1\x80\xd1\x83\xd1\x81\xd1\x81\xd0\xba\xd0\xb8\xd0\xb9 (\xd0\xa0\xd0\xbe\xd1\x81\xd1\x81\xd0\xb8\xd1\x8f)\0"
        "RU\0"
        "hr-HR\0"
        "Croatian (Croatia)\0"
@@ -3389,11 +5647,11 @@ static const char locale_strings [] = {
        "HR\0"
        "sk-SK\0"
        "Slovak (Slovakia)\0"
-       "slovensk\xc3\xbd (Slovensk\xc3\xa1 republika)\0"
+       "sloven\xc4\x8dina (Slovensk\xc3\xa1 republika)\0"
        "SK\0"
        "sq-AL\0"
        "Albanian (Albania)\0"
-       "shqipe (Shqip\xc3\xabria)\0"
+       "shqip (Shqip\xc3\xabria)\0"
        "AL\0"
        "sv-SE\0"
        "Swedish (Sweden)\0"
@@ -3401,31 +5659,35 @@ static const char locale_strings [] = {
        "SE\0"
        "th-TH\0"
        "Thai (Thailand)\0"
-       "\xe0\xb9\x84\xe0\xb8\x97\xe0\xb8\xa2 (\xe0\xb8\x9b\xe0\xb8\xa3\xe0\xb8\xb0\xe0\xb9\x80\xe0\xb8\x97\xe0\xb8\xa8\xe0\xb9\x84\xe0\xb8\x97\xe0\xb8\xa2)\0"
+       "\xe0\xb9\x84\xe0\xb8\x97\xe0\xb8\xa2 (\xe0\xb9\x84\xe0\xb8\x97\xe0\xb8\xa2)\0"
        "TH\0"
        "tr-TR\0"
        "Turkish (Turkey)\0"
        "T\xc3\xbcrk\xc3\xa7\x65 (T\xc3\xbcrkiye)\0"
        "TR\0"
+       "ur-PK\0"
+       "Urdu (Pakistan)\0"
+       "\xd8\xa7\xd8\xb1\xd8\xaf\xd9\x88 (\xd9\xbe\xd8\xa7\xda\xa9\xd8\xb3\xd8\xaa\xd8\xa7\xd9\x86)\0"
+       "PK\0"
        "id-ID\0"
        "Indonesian (Indonesia)\0"
        "Bahasa Indonesia (Indonesia)\0"
        "ID\0"
        "uk-UA\0"
        "Ukrainian (Ukraine)\0"
-       "\xd0\xa3\xd0\xba\xd1\x80\xd0\xb0\xd1\x97\xd0\xbd\xd1\x81\xd1\x8c\xd0\xba\xd0\xb0 (\xd0\xa3\xd0\xba\xd1\x80\xd0\xb0\xd1\x97\xd0\xbd\xd0\xb0)\0"
+       "\xd1\x83\xd0\xba\xd1\x80\xd0\xb0\xd1\x97\xd0\xbd\xd1\x81\xd1\x8c\xd0\xba\xd0\xb0 (\xd0\xa3\xd0\xba\xd1\x80\xd0\xb0\xd1\x97\xd0\xbd\xd0\xb0)\0"
        "UA\0"
        "be-BY\0"
        "Belarusian (Belarus)\0"
-       "\xd0\x91\xd0\xb5\xd0\xbb\xd0\xb0\xd1\x80\xd1\x83\xd1\x81\xd0\xba\xd1\x96 (\xd0\x91\xd0\xb5\xd0\xbb\xd0\xb0\xd1\x80\xd1\x83\xd1\x81\xd1\x8c)\0"
+       "\xd0\xb1\xd0\xb5\xd0\xbb\xd0\xb0\xd1\x80\xd1\x83\xd1\x81\xd0\xba\xd0\xb0\xd1\x8f (\xd0\x91\xd0\xb5\xd0\xbb\xd0\xb0\xd1\x80\xd1\x83\xd1\x81\xd1\x8c)\0"
        "BY\0"
        "sl-SI\0"
        "Slovenian (Slovenia)\0"
-       "Sloven\xc5\xa1\xc4\x8dina (Slovenija)\0"
+       "sloven\xc5\xa1\xc4\x8dina (Slovenija)\0"
        "SI\0"
        "et-EE\0"
        "Estonian (Estonia)\0"
-       "Eesti (Eesti)\0"
+       "eesti (Eesti)\0"
        "EE\0"
        "lv-LV\0"
        "Latvian (Latvia)\0"
@@ -3433,8 +5695,11 @@ static const char locale_strings [] = {
        "LV\0"
        "lt-LT\0"
        "Lithuanian (Lithuania)\0"
-       "Lietuvi\xc5\xb3 (Lietuva)\0"
+       "lietuvi\xc5\xb3 (Lietuva)\0"
        "LT\0"
+       "tg-Cyrl-TJ\0"
+       "Tajik (Cyrillic, Tajikistan)\0"
+       "TJ\0"
        "fa-IR\0"
        "Persian (Iran)\0"
        "\xd9\x81\xd8\xa7\xd8\xb1\xd8\xb3\xdb\x8c (\xd8\xa7\xdb\x8c\xd8\xb1\xd8\xa7\xd9\x86)\0"
@@ -3446,6 +5711,10 @@ static const char locale_strings [] = {
        "hy-AM\0"
        "Armenian (Armenia)\0"
        "\xd5\x80\xd5\xa1\xd5\xb5\xd5\xa5\xd6\x80\xd5\xa7\xd5\xb6 (\xd5\x80\xd5\xa1\xd5\xb5\xd5\xa1\xd5\xbd\xd5\xbf\xd5\xa1\xd5\xb6\xd5\xab \xd5\x80\xd5\xa1\xd5\xb6\xd6\x80\xd5\xa1\xd5\xba\xd5\xa5\xd5\xbf\xd5\xb8\xd6\x82\xd5\xa9\xd5\xab\xd6\x82\xd5\xb6)\0"
+       "az-Latn-AZ\0"
+       "Azerbaijani (Latin, Azerbaijan)\0"
+       "az\xc9\x99rbaycanca (Az\xc9\x99rbaycan)\0"
+       "AZ\0"
        "eu-ES\0"
        "Basque (Spain)\0"
        "euskara (Espainia)\0"
@@ -3453,10 +5722,17 @@ static const char locale_strings [] = {
        "Macedonian (Macedonia)\0"
        "\xd0\xbc\xd0\xb0\xd0\xba\xd0\xb5\xd0\xb4\xd0\xbe\xd0\xbd\xd1\x81\xd0\xba\xd0\xb8 (\xd0\x9c\xd0\xb0\xd0\xba\xd0\xb5\xd0\xb4\xd0\xbe\xd0\xbd\xd0\xb8\xd1\x98\xd0\xb0)\0"
        "MK\0"
+       "tn-ZA\0"
+       "Tswana (South Africa)\0"
+       "ZA\0"
+       "xh-ZA\0"
+       "Xhosa (South Africa)\0"
+       "zu-ZA\0"
+       "Zulu (South Africa)\0"
+       "isiZulu (iNingizimu Afrika)\0"
        "af-ZA\0"
        "Afrikaans (South Africa)\0"
-       "Afrikaanse (Suid-Afrika)\0"
-       "ZA\0"
+       "Afrikaans (Suid-Afrika)\0"
        "ka-GE\0"
        "Georgian (Georgia)\0"
        "\xe1\x83\xa5\xe1\x83\x90\xe1\x83\xa0\xe1\x83\x97\xe1\x83\xa3\xe1\x83\x9a\xe1\x83\x98 (\xe1\x83\xa1\xe1\x83\x90\xe1\x83\xa5\xe1\x83\x90\xe1\x83\xa0\xe1\x83\x97\xe1\x83\x95\xe1\x83\x94\xe1\x83\x9a\xe1\x83\x9d)\0"
@@ -3467,40 +5743,137 @@ static const char locale_strings [] = {
        "FO\0"
        "hi-IN\0"
        "Hindi (India)\0"
-       "\xe0\xa4\xb9\xe0\xa4\xbf\xe0\xa4\x82\xe0\xa4\xa6\xe0\xa5\x80 (\xe0\xa4\xad\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa4\xa4)\0"
+       "\xe0\xa4\xb9\xe0\xa4\xbf\xe0\xa4\xa8\xe0\xa5\x8d\xe0\xa4\xa6\xe0\xa5\x80 (\xe0\xa4\xad\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa4\xa4)\0"
        "IN\0"
+       "mt-MT\0"
+       "Maltese (Malta)\0"
+       "Malti (Malta)\0"
+       "MT\0"
+       "se-NO\0"
+       "Northern Sami (Norway)\0"
+       "davvis\xc3\xa1megiella (Norga)\0"
+       "ms-MY\0"
+       "Malay (Malaysia)\0"
+       "Bahasa Melayu (Malaysia)\0"
+       "MY\0"
+       "ky-KG\0"
+       "Kirghiz (Kyrgyzstan)\0"
+       "\xd0\x9a\xd1\x8b\xd1\x80\xd0\xb3\xd1\x8b\xd0\xb7 (\xd0\x9a\xd1\x8b\xd1\x80\xd0\xb3\xd1\x8b\xd0\xb7\xd1\x81\xd1\x82\xd0\xb0\xd0\xbd)\0"
+       "KG\0"
        "sw-KE\0"
        "Swahili (Kenya)\0"
        "Kiswahili (Kenya)\0"
        "KE\0"
+       "uz-Latn-UZ\0"
+       "Uzbek (Latin, Uzbekistan)\0"
+       "\xd0\x8e\xd0\xb7\xd0\xb1\xd0\xb5\xd0\xba (\xd0\x8e\xd0\xb7\xd0\xb1\xd0\xb5\xd0\xba\xd0\xb8\xd1\x81\xd1\x82\xd0\xbe\xd0\xbd)\0"
+       "UZ\0"
+       "bn-IN\0"
+       "Bengali (India)\0"
+       "\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\x82\xe0\xa6\xb2\xe0\xa6\xbe (\xe0\xa6\xad\xe0\xa6\xbe\xe0\xa6\xb0\xe0\xa6\xa4)\0"
        "gu-IN\0"
        "Gujarati (India)\0"
        "\xe0\xaa\x97\xe0\xab\x81\xe0\xaa\x9c\xe0\xaa\xb0\xe0\xaa\xbe\xe0\xaa\xa4\xe0\xab\x80 (\xe0\xaa\xad\xe0\xaa\xbe\xe0\xaa\xb0\xe0\xaa\xa4)\0"
+       "or-IN\0"
+       "Oriya (India)\0"
+       "\xe0\xac\x93\xe0\xac\xa1\xe0\xac\xbc\xe0\xac\xbf\xe0\xac\x86 (\xe0\xac\xad\xe0\xac\xbe\xe0\xac\xb0\xe0\xac\xa4)\0"
        "ta-IN\0"
        "Tamil (India)\0"
        "\xe0\xae\xa4\xe0\xae\xae\xe0\xae\xbf\xe0\xae\xb4\xe0\xaf\x8d (\xe0\xae\x87\xe0\xae\xa8\xe0\xaf\x8d\xe0\xae\xa4\xe0\xae\xbf\xe0\xae\xaf\xe0\xae\xbe)\0"
        "te-IN\0"
        "Telugu (India)\0"
-       "\xe0\xb0\xa4\xe0\xb1\x86\xe0\xb0\xb2\xe0\xb1\x81\xe0\xb0\x97\xe0\xb1\x81 (\xe0\xb0\xad\xe0\xb0\xbe\xe0\xb0\xb0\xe0\xb0\xa4 \xe0\xb0\xa6\xe0\xb1\x87\xe0\xb0\xb3\xe0\xb1\xa6)\0"
+       "\xe0\xb0\xa4\xe0\xb1\x86\xe0\xb0\xb2\xe0\xb1\x81\xe0\xb0\x97\xe0\xb1\x81 (\xe0\xb0\xad\xe0\xb0\xbe\xe0\xb0\xb0\xe0\xb0\xa4 \xe0\xb0\xa6\xe0\xb1\x87\xe0\xb0\xb6\xe0\xb0\x82)\0"
        "kn-IN\0"
        "Kannada (India)\0"
        "\xe0\xb2\x95\xe0\xb2\xa8\xe0\xb3\x8d\xe0\xb2\xa8\xe0\xb2\xa1 (\xe0\xb2\xad\xe0\xb2\xbe\xe0\xb2\xb0\xe0\xb2\xa4)\0"
+       "ml-IN\0"
+       "Malayalam (India)\0"
+       "\xe0\xb4\xae\xe0\xb4\xb2\xe0\xb4\xaf\xe0\xb4\xbe\xe0\xb4\xb3\xe0\xb4\x82 (\xe0\xb4\x87\xe0\xb4\xa8\xe0\xb5\x8d\xe0\xb4\xa4\xe0\xb5\x8d\xe0\xb4\xaf)\0"
+       "as-IN\0"
+       "Assamese (India)\0"
+       "\xe0\xa6\x85\xe0\xa6\xb8\xe0\xa6\xae\xe0\xa7\x80\xe0\xa6\xaf\xe0\xa6\xbc\xe0\xa6\xbe (\xe0\xa6\xad\xe0\xa6\xbe\xe0\xa7\xb0\xe0\xa6\xa4)\0"
        "mr-IN\0"
        "Marathi (India)\0"
        "\xe0\xa4\xae\xe0\xa4\xb0\xe0\xa4\xbe\xe0\xa4\xa0\xe0\xa5\x80 (\xe0\xa4\xad\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa4\xa4)\0"
+       "bo-CN\0"
+       "Tibetan (China)\0"
+       "\xe0\xbd\x94\xe0\xbd\xbc\xe0\xbd\x91\xe0\xbc\x8b\xe0\xbd\xa6\xe0\xbe\x90\xe0\xbd\x91\xe0\xbc\x8b (\xe0\xbd\xa2\xe0\xbe\x92\xe0\xbe\xb1\xe0\xbc\x8b\xe0\xbd\x93\xe0\xbd\x82)\0"
+       "cy-GB\0"
+       "Welsh (United Kingdom)\0"
+       "Cymraeg (Prydain Fawr)\0"
+       "GB\0"
+       "km-KH\0"
+       "Khmer (Cambodia)\0"
+       "\xe1\x9e\x97\xe1\x9e\xb6\xe1\x9e\x9f\xe1\x9e\xb6\xe1\x9e\x81\xe1\x9f\x92\xe1\x9e\x98\xe1\x9f\x82\xe1\x9e\x9a (\xe1\x9e\x80\xe1\x9e\x98\xe1\x9f\x92\xe1\x9e\x96\xe1\x9e\xbb\xe1\x9e\x87\xe1\x9e\xb6)\0"
+       "KH\0"
+       "lo-LA\0"
+       "Lao (Laos)\0"
+       "\xe0\xba\xa5\xe0\xba\xb2\xe0\xba\xa7 (\xe0\xba\xa5\xe0\xba\xb2\xe0\xba\xa7)\0"
+       "LA\0"
        "gl-ES\0"
-       "Gallegan (Spain)\0"
+       "Galician (Spain)\0"
        "galego (Espa\xc3\xb1\x61)\0"
        "kok-IN\0"
        "Konkani (India)\0"
        "\xe0\xa4\x95\xe0\xa5\x8b\xe0\xa4\x82\xe0\xa4\x95\xe0\xa4\xa3\xe0\xa5\x80 (\xe0\xa4\xad\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa4\xa4)\0"
+       "si-LK\0"
+       "Sinhala (Sri Lanka)\0"
+       "\xe0\xb7\x83\xe0\xb7\x92\xe0\xb6\x82\xe0\xb7\x84\xe0\xb6\xbd (\xe0\xb7\x81\xe0\xb7\x8a\xe2\x80\x8d\xe0\xb6\xbb\xe0\xb7\x93 \xe0\xb6\xbd\xe0\xb6\x82\xe0\xb6\x9a\xe0\xb7\x8f\xe0\xb7\x80)\0"
+       "LK\0"
+       "am-ET\0"
+       "Amharic (Ethiopia)\0"
+       "\xe1\x8a\xa0\xe1\x88\x9b\xe1\x88\xad\xe1\x8a\x9b (\xe1\x8a\xa2\xe1\x89\xb5\xe1\x8b\xae\xe1\x8c\xb5\xe1\x8b\xab)\0"
+       "ET\0"
+       "ne-NP\0"
+       "Nepali (Nepal)\0"
+       "\xe0\xa4\xa8\xe0\xa5\x87\xe0\xa4\xaa\xe0\xa4\xbe\xe0\xa4\xb2\xe0\xa5\x80 (\xe0\xa4\xa8\xe0\xa5\x87\xe0\xa4\xaa\xe0\xa4\xbe\xe0\xa4\xb2)\0"
+       "NP\0"
+       "ps-AF\0"
+       "Pashto (Afghanistan)\0"
+       "\xd9\xbe\xda\x9a\xd8\xaa\xd9\x88 (\xd8\xa7\xd9\x81\xd8\xba\xd8\xa7\xd9\x86\xd8\xb3\xd8\xaa\xd8\xa7\xd9\x86)\0"
+       "AF\0"
+       "fil-PH\0"
+       "Filipino (Philippines)\0"
+       "Filipino (Pilipinas)\0"
+       "PH\0"
+       "ha-Latn-NG\0"
+       "Hausa (Latin, Nigeria)\0"
+       "Hausa (Najeriya)\0"
+       "NG\0"
+       "yo-NG\0"
+       "Yoruba (Nigeria)\0"
+       "\xc3\x88\x64\xc3\xa8 Yor\xc3\xb9\x62\xc3\xa1 (Or\xc3\xadl\xe1\xba\xb9\xcc\x81\xc3\xa8\x64\x65 N\xc3\xa0\xc3\xacj\xc3\xadr\xc3\xad\xc3\xa0)\0"
+       "nso-ZA\0"
+       "Northern Sotho (South Africa)\0"
+       "kl-GL\0"
+       "Kalaallisut (Greenland)\0"
+       "kalaallisut (Kalaallit Nunaat)\0"
+       "GL\0"
+       "ig-NG\0"
+       "Igbo (Nigeria)\0"
+       "ii-CN\0"
+       "Sichuan Yi (China)\0"
+       "\xea\x86\x88\xea\x8c\xa0\xea\x89\x99 (\xea\x8d\x8f\xea\x87\xa9)\0"
+       "br-FR\0"
+       "Breton (France)\0"
+       "brezhoneg (Fra\xc3\xb1s)\0"
+       "oc-FR\0"
+       "Occitan (France)\0"
+       "occitan (Fran\xc3\xa7\x61)\0"
+       "sah-RU\0"
+       "Sakha (Russia)\0"
+       "rw-RW\0"
+       "Kinyarwanda (Rwanda)\0"
+       "RW\0"
+       "gd-GB\0"
+       "Scottish Gaelic (United Kingdom)\0"
+       "G\xc3\xa0idhlig (An R\xc3\xacoghachd Aonaichte)\0"
        "ar-IQ\0"
        "Arabic (Iraq)\0"
        "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa7\xd9\x82)\0"
        "ARI\0"
        "IQ\0"
        "zh-CN\0"
-       "Chinese (China)\0"
        "\xe4\xb8\xad\xe6\x96\x87 (\xe4\xb8\xad\xe5\x9b\xbd)\0"
        "de-CH\0"
        "German (Switzerland)\0"
@@ -3509,7 +5882,6 @@ static const char locale_strings [] = {
        "en-GB\0"
        "English (United Kingdom)\0"
        "ENG\0"
-       "GB\0"
        "es-MX\0"
        "Spanish (Mexico)\0"
        "espa\xc3\xb1ol (M\xc3\xa9xico)\0"
@@ -3530,7 +5902,7 @@ static const char locale_strings [] = {
        "NLB\0"
        "nn-NO\0"
        "Norwegian Nynorsk (Norway)\0"
-       "norsk nynorsk (Noreg)\0"
+       "nynorsk (Noreg)\0"
        "NON\0"
        "nno\0"
        "nn\0"
@@ -3543,13 +5915,35 @@ static const char locale_strings [] = {
        "Swedish (Finland)\0"
        "svenska (Finland)\0"
        "SVF\0"
+       "az-Cyrl-AZ\0"
+       "Azerbaijani (Cyrillic, Azerbaijan)\0"
+       "AZC\0"
+       "ga-IE\0"
+       "Irish (Ireland)\0"
+       "Gaeilge (\xc3\x89ire)\0"
+       "IE\0"
+       "ms-BN\0"
+       "Malay (Brunei)\0"
+       "Bahasa Melayu (Brunei)\0"
+       "MSB\0"
+       "BN\0"
+       "uz-Cyrl-UZ\0"
+       "Uzbek (Cyrillic, Uzbekistan)\0"
+       "bn-BD\0"
+       "Bengali (Bangladesh)\0"
+       "\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\x82\xe0\xa6\xb2\xe0\xa6\xbe (\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\x82\xe0\xa6\xb2\xe0\xa6\xbe\xe0\xa6\xa6\xe0\xa7\x87\xe0\xa6\xb6)\0"
+       "BNB\0"
+       "BD\0"
+       "mn-Mong-CN\0"
+       "Mongolian (Mongolian, China)\0"
+       "MNG\0"
        "ar-EG\0"
        "Arabic (Egypt)\0"
        "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd9\x85\xd8\xb5\xd8\xb1)\0"
        "ARE\0"
        "EG\0"
        "zh-HK\0"
-       "Chinese (Hong Kong S.A.R., China)\0"
+       "Chinese (Traditional, Hong Kong SAR China)\0"
        "\xe4\xb8\xad\xe6\x96\x87 (\xe4\xb8\xad\xe5\x9b\xbd\xe9\xa6\x99\xe6\xb8\xaf\xe7\x89\xb9\xe5\x88\xab\xe8\xa1\x8c\xe6\x94\xbf\xe5\x8c\xba)\0"
        "ZHH\0"
        "HK\0"
@@ -3571,13 +5965,18 @@ static const char locale_strings [] = {
        "fran\xc3\xa7\x61is (Canada)\0"
        "FRC\0"
        "CA\0"
+       "se-FI\0"
+       "Northern Sami (Finland)\0"
+       "davvis\xc3\xa1megiella (Suopma)\0"
+       "SMG\0"
+       "smg\0"
        "ar-LY\0"
        "Arabic (Libya)\0"
        "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd9\x84\xd9\x8a\xd8\xa8\xd9\x8a\xd8\xa7)\0"
        "ARL\0"
        "LY\0"
        "zh-SG\0"
-       "Chinese (Singapore)\0"
+       "Chinese (Simplified, Singapore)\0"
        "\xe4\xb8\xad\xe6\x96\x87 (\xe6\x96\xb0\xe5\x8a\xa0\xe5\x9d\xa1)\0"
        "ZHI\0"
        "SG\0"
@@ -3604,10 +6003,15 @@ static const char locale_strings [] = {
        "ARG\0"
        "DZ\0"
        "zh-MO\0"
-       "Chinese (Macao S.A.R. China)\0"
+       "Chinese (Traditional, Macau SAR China)\0"
        "\xe4\xb8\xad\xe6\x96\x87 (\xe4\xb8\xad\xe5\x9b\xbd\xe6\xbe\xb3\xe9\x97\xa8\xe7\x89\xb9\xe5\x88\xab\xe8\xa1\x8c\xe6\x94\xbf\xe5\x8c\xba)\0"
        "ZHM\0"
        "MO\0"
+       "de-LI\0"
+       "German (Liechtenstein)\0"
+       "Deutsch (Liechtenstein)\0"
+       "DEC\0"
+       "LI\0"
        "en-NZ\0"
        "English (New Zealand)\0"
        "ENZ\0"
@@ -3629,12 +6033,24 @@ static const char locale_strings [] = {
        "en-IE\0"
        "English (Ireland)\0"
        "ENI\0"
-       "IE\0"
        "es-PA\0"
        "Spanish (Panama)\0"
        "espa\xc3\xb1ol (Panam\xc3\xa1)\0"
        "ESA\0"
        "PA\0"
+       "fr-MC\0"
+       "French (Monaco)\0"
+       "fran\xc3\xa7\x61is (Monaco)\0"
+       "FRM\0"
+       "MC\0"
+       "sr-Latn-BA\0"
+       "Serbian (Latin, Bosnia and Herzegovina)\0"
+       "\xd0\xa1\xd1\x80\xd0\xbf\xd1\x81\xd0\xba\xd0\xb8 (\xd0\x91\xd0\xbe\xd1\x81\xd0\xbd\xd0\xb0 \xd0\xb8 \xd0\xa5\xd0\xb5\xd1\x80\xd1\x86\xd0\xb5\xd0\xb3\xd0\xbe\xd0\xb2\xd0\xb8\xd0\xbd\xd0\xb0)\0"
+       "SRS\0"
+       "srs\0"
+       "sr\0"
+       "BA\0"
+       "Gregorijanski kalendar\0"
        "ar-TN\0"
        "Arabic (Tunisia)\0"
        "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xaa\xd9\x88\xd9\x86\xd8\xb3)\0"
@@ -3648,11 +6064,19 @@ static const char locale_strings [] = {
        "espa\xc3\xb1ol (Rep\xc3\xba\x62lica Dominicana)\0"
        "ESD\0"
        "DO\0"
+       "sr-Cyrl-BA\0"
+       "Serbian (Cyrillic, Bosnia and Herzegovina)\0"
+       "SRN\0"
+       "srn\0"
        "ar-OM\0"
        "Arabic (Oman)\0"
-       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xb9\xd9\x85\xd8\xa7\xd9\x86)\0"
+       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xb9\xd9\x8f\xd9\x85\xd8\xa7\xd9\x86)\0"
        "ARO\0"
        "OM\0"
+       "en-JM\0"
+       "English (Jamaica)\0"
+       "ENJ\0"
+       "JM\0"
        "es-VE\0"
        "Spanish (Venezuela)\0"
        "espa\xc3\xb1ol (Venezuela)\0"
@@ -3668,19 +6092,31 @@ static const char locale_strings [] = {
        "espa\xc3\xb1ol (Colombia)\0"
        "ESO\0"
        "CO\0"
+       "sr-Latn-RS\0"
+       "Serbian (Latin, Serbia)\0"
+       "\xd0\xa1\xd1\x80\xd0\xbf\xd1\x81\xd0\xba\xd0\xb8 (\xd0\xa1\xd1\x80\xd0\xb1\xd0\xb8\xd1\x98\xd0\xb0)\0"
+       "SRM\0"
+       "RS\0"
        "ar-SY\0"
        "Arabic (Syria)\0"
-       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xb3\xd9\x88\xd8\xb1\xd9\x8a\xd8\xa9)\0"
+       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xb3\xd9\x88\xd8\xb1\xd9\x8a\xd8\xa7)\0"
        "ARS\0"
        "SY\0"
+       "en-BZ\0"
+       "English (Belize)\0"
+       "ENL\0"
+       "BZ\0"
        "es-PE\0"
        "Spanish (Peru)\0"
        "espa\xc3\xb1ol (Per\xc3\xba)\0"
        "ESR\0"
        "PE\0"
+       "sr-Cyrl-RS\0"
+       "Serbian (Cyrillic, Serbia)\0"
+       "SRO\0"
        "ar-JO\0"
        "Arabic (Jordan)\0"
-       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xa7\xd9\x84\xd8\xa7\xd8\xb1\xd8\xaf\xd9\x86)\0"
+       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xa7\xd9\x84\xd8\xa3\xd8\xb1\xd8\xaf\xd9\x86)\0"
        "ARJ\0"
        "JO\0"
        "en-TT\0"
@@ -3692,6 +6128,11 @@ static const char locale_strings [] = {
        "espa\xc3\xb1ol (Argentina)\0"
        "ESS\0"
        "AR\0"
+       "sr-Latn-ME\0"
+       "Serbian (Latin, Montenegro)\0"
+       "\xd0\xa1\xd1\x80\xd0\xbf\xd1\x81\xd0\xba\xd0\xb8 (\xd0\xa6\xd1\x80\xd0\xbd\xd0\xb0 \xd0\x93\xd0\xbe\xd1\x80\xd0\xb0)\0"
+       "SRP\0"
+       "ME\0"
        "ar-LB\0"
        "Arabic (Lebanon)\0"
        "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd9\x84\xd8\xa8\xd9\x86\xd8\xa7\xd9\x86)\0"
@@ -3706,6 +6147,9 @@ static const char locale_strings [] = {
        "espa\xc3\xb1ol (Ecuador)\0"
        "ESF\0"
        "EC\0"
+       "sr-Cyrl-ME\0"
+       "Serbian (Cyrillic, Montenegro)\0"
+       "SRQ\0"
        "ar-KW\0"
        "Arabic (Kuwait)\0"
        "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xa7\xd9\x84\xd9\x83\xd9\x88\xd9\x8a\xd8\xaa)\0"
@@ -3714,7 +6158,6 @@ static const char locale_strings [] = {
        "en-PH\0"
        "English (Philippines)\0"
        "ENP\0"
-       "PH\0"
        "es-CL\0"
        "Spanish (Chile)\0"
        "espa\xc3\xb1ol (Chile)\0"
@@ -3722,7 +6165,7 @@ static const char locale_strings [] = {
        "CL\0"
        "ar-AE\0"
        "Arabic (United Arab Emirates)\0"
-       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xa7\xd9\x84\xd8\xa7\xd9\x85\xd8\xa7\xd8\xb1\xd8\xa7\xd8\xaa \xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 \xd8\xa7\xd9\x84\xd9\x85\xd8\xaa\xd8\xad\xd8\xaf\xd8\xa9)\0"
+       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd8\xa7\xd9\x84\xd8\xa5\xd9\x85\xd8\xa7\xd8\xb1\xd8\xa7\xd8\xaa \xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 \xd8\xa7\xd9\x84\xd9\x85\xd8\xaa\xd8\xad\xd8\xaf\xd8\xa9)\0"
        "ARU\0"
        "AE\0"
        "es-UY\0"
@@ -3745,6 +6188,9 @@ static const char locale_strings [] = {
        "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 (\xd9\x82\xd8\xb7\xd8\xb1)\0"
        "ARQ\0"
        "QA\0"
+       "en-IN\0"
+       "English (India)\0"
+       "ENN\0"
        "es-BO\0"
        "Spanish (Bolivia)\0"
        "espa\xc3\xb1ol (Bolivia)\0"
@@ -3755,6 +6201,9 @@ static const char locale_strings [] = {
        "espa\xc3\xb1ol (El Salvador)\0"
        "ESE\0"
        "SV\0"
+       "en-SG\0"
+       "English (Singapore)\0"
+       "ENE\0"
        "es-HN\0"
        "Spanish (Honduras)\0"
        "espa\xc3\xb1ol (Honduras)\0"
@@ -3770,8 +6219,50 @@ static const char locale_strings [] = {
        "espa\xc3\xb1ol (Puerto Rico)\0"
        "ESU\0"
        "PR\0"
+       "es-US\0"
+       "Spanish (United States)\0"
+       "espa\xc3\xb1ol (Estados Unidos)\0"
+       "EST\0"
+       "sr-Cyrl\0"
+       "Serbian (Cyrillic)\0"
+       "\xd0\xa1\xd1\x80\xd0\xbf\xd1\x81\xd0\xba\xd0\xb8\0"
+       "sr-Latn\0"
+       "Serbian (Latin)\0"
+       "az-Cyrl\0"
+       "Azerbaijani (Cyrillic)\0"
+       "Norwegian Nynorsk\0"
+       "nynorsk\0"
+       "bs\0"
+       "Bosnian\0"
+       "bosanski\0"
+       "BSB\0"
+       "bsb\0"
+       "az-Latn\0"
+       "Azerbaijani (Latin)\0"
+       "uz-Cyrl\0"
+       "Uzbek (Cyrillic)\0"
+       "mn-Cyrl\0"
+       "Mongolian (Cyrillic)\0"
+       "MNN\0"
        "zh-CHT\0"
+       "Chinese (Traditional) Legacy\0"
+       "zh-Hant\0"
+       "Norwegian Bokm\xc3\xa5l\0"
+       "norsk bokm\xc3\xa5l\0"
+       "Serbian\0"
+       "SRB\0"
+       "tg-Cyrl\0"
+       "Tajik (Cyrillic)\0"
+       "uz-Latn\0"
+       "Uzbek (Latin)\0"
+       "mn-Mong\0"
+       "Mongolian (Mongolian)\0"
+       "tzm-Latn\0"
+       "Central Morocco Tamazight (Latin)\0"
+       "ha-Latn\0"
+       "Hausa (Latin)\0"
        "af-za\0"
+       "am-et\0"
        "ar-ae\0"
        "ar-bh\0"
        "ar-dz\0"
@@ -3788,22 +6279,37 @@ static const char locale_strings [] = {
        "ar-sy\0"
        "ar-tn\0"
        "ar-ye\0"
+       "as-in\0"
+       "az-cyrl\0"
+       "az-cyrl-az\0"
+       "az-latn\0"
+       "az-latn-az\0"
        "be-by\0"
        "bg-bg\0"
+       "bn-bd\0"
+       "bn-in\0"
+       "bo-cn\0"
+       "br-fr\0"
        "ca-es\0"
        "cs-cz\0"
+       "cy-gb\0"
        "da-dk\0"
        "de-at\0"
        "de-ch\0"
        "de-de\0"
+       "de-li\0"
        "de-lu\0"
        "el-gr\0"
        "en-au\0"
+       "en-bz\0"
        "en-ca\0"
        "en-gb\0"
        "en-ie\0"
+       "en-in\0"
+       "en-jm\0"
        "en-nz\0"
        "en-ph\0"
+       "en-sg\0"
        "en-tt\0"
        "en-us\0"
        "en-za\0"
@@ -3825,740 +6331,692 @@ static const char locale_strings [] = {
        "es-pr\0"
        "es-py\0"
        "es-sv\0"
+       "es-us\0"
        "es-uy\0"
        "es-ve\0"
        "et-ee\0"
        "eu-es\0"
        "fa-ir\0"
        "fi-fi\0"
+       "fil-ph\0"
        "fo-fo\0"
        "fr-be\0"
        "fr-ca\0"
        "fr-ch\0"
        "fr-fr\0"
        "fr-lu\0"
+       "fr-mc\0"
+       "ga-ie\0"
+       "gd-gb\0"
        "gl-es\0"
        "gu-in\0"
+       "ha-latn\0"
+       "ha-latn-ng\0"
        "he-il\0"
        "hi-in\0"
        "hr-hr\0"
        "hu-hu\0"
        "hy-am\0"
        "id-id\0"
+       "ig-ng\0"
+       "ii-cn\0"
        "is-is\0"
        "it-ch\0"
        "it-it\0"
        "ja-jp\0"
        "ka-ge\0"
+       "kl-gl\0"
+       "km-kh\0"
        "kn-in\0"
        "ko-kr\0"
        "kok-in\0"
+       "ky-kg\0"
+       "lo-la\0"
        "lt-lt\0"
        "lv-lv\0"
        "mk-mk\0"
+       "ml-in\0"
+       "mn-cyrl\0"
+       "mn-mong\0"
+       "mn-mong-cn\0"
        "mr-in\0"
+       "ms-bn\0"
+       "ms-my\0"
+       "mt-mt\0"
        "nb-no\0"
+       "ne-np\0"
        "nl-be\0"
        "nl-nl\0"
        "nn-no\0"
+       "nso-za\0"
+       "oc-fr\0"
+       "or-in\0"
        "pl-pl\0"
+       "ps-af\0"
        "pt-br\0"
        "pt-pt\0"
+       "rm-ch\0"
        "ro-ro\0"
        "ru-ru\0"
+       "rw-rw\0"
+       "sah-ru\0"
+       "se-fi\0"
+       "se-no\0"
+       "si-lk\0"
        "sk-sk\0"
        "sl-si\0"
        "sq-al\0"
+       "sr-cyrl\0"
+       "sr-cyrl-ba\0"
+       "sr-cyrl-me\0"
+       "sr-cyrl-rs\0"
+       "sr-latn\0"
+       "sr-latn-ba\0"
+       "sr-latn-me\0"
+       "sr-latn-rs\0"
        "sv-fi\0"
        "sv-se\0"
        "sw-ke\0"
        "ta-in\0"
        "te-in\0"
+       "tg-cyrl\0"
+       "tg-cyrl-tj\0"
        "th-th\0"
+       "tn-za\0"
        "tr-tr\0"
+       "tzm-latn\0"
        "uk-ua\0"
+       "ur-pk\0"
+       "uz-cyrl\0"
+       "uz-cyrl-uz\0"
+       "uz-latn\0"
+       "uz-latn-uz\0"
        "vi-vn\0"
+       "xh-za\0"
+       "yo-ng\0"
        "zh-chs\0"
        "zh-cht\0"
        "zh-cn\0"
+       "zh-hans\0"
+       "zh-hant\0"
        "zh-hk\0"
        "zh-mo\0"
        "zh-sg\0"
        "zh-tw\0"
+       "zu-za\0"
        "United Arab Emirates\0"
+       "\xd8\xa7\xd9\x84\xd8\xa5\xd9\x85\xd8\xa7\xd8\xb1\xd8\xa7\xd8\xaa \xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 \xd8\xa7\xd9\x84\xd9\x85\xd8\xaa\xd8\xad\xd8\xaf\xd8\xa9\0"
        "AED\0"
        "United Arab Emirates Dirham\0"
-       "AF\0"
+       "\xd8\xaf\xd8\xb1\xd9\x87\xd9\x85 \xd8\xa5\xd9\x85\xd8\xa7\xd8\xb1\xd8\xa7\xd8\xaa\xd9\x8a\0"
+       "AFG\0"
        "Afghanistan\0"
+       "\xd8\xa7\xd9\x81\xd8\xba\xd8\xa7\xd9\x86\xd8\xb3\xd8\xaa\xd8\xa7\xd9\x86\0"
        "AFN\0"
-       "Afghani\0"
-       "AG\0"
-       "Antigua and Barbuda\0"
-       "XCD\0"
-       "East Caribbean Dollar\0"
-       "AI\0"
-       "Anguilla\0"
+       "Afghan Afghani\0"
+       "\xd8\xa7\xd9\x81\xd8\xba\xd8\xa7\xd9\x86\xdb\x8d\0"
+       "ALB\0"
        "Albania\0"
+       "Shqip\xc3\xabria\0"
        "ALL\0"
        "Albanian Lek\0"
        "Armenia\0"
+       "\xd5\x80\xd5\xa1\xd5\xb5\xd5\xa1\xd5\xbd\xd5\xbf\xd5\xa1\xd5\xb6\xd5\xab \xd5\x80\xd5\xa1\xd5\xb6\xd6\x80\xd5\xa1\xd5\xba\xd5\xa5\xd5\xbf\xd5\xb8\xd6\x82\xd5\xa9\xd5\xab\xd6\x82\xd5\xb6\0"
        "AMD\0"
        "Armenian Dram\0"
-       "AN\0"
-       "Netherlands Antilles\0"
-       "ANG\0"
-       "Netherlands Antillan Guilder\0"
-       "AO\0"
-       "Angola\0"
-       "AOA\0"
-       "Angolan Kwanza\0"
        "Argentina\0"
        "Argentine Peso\0"
-       "AS\0"
-       "American Samoa\0"
-       "USD\0"
-       "US Dollar\0"
+       "peso argentino\0"
+       "AUT\0"
        "Austria\0"
+       "\xc3\x96sterreich\0"
        "EUR\0"
        "Euro\0"
+       "AUS\0"
        "Australia\0"
        "AUD\0"
        "Australian Dollar\0"
-       "AW\0"
-       "Aruba\0"
-       "AWG\0"
-       "Aruban Guilder\0"
-       "AZ\0"
        "Azerbaijan\0"
-       "AZM\0"
-       "Azerbaijanian Manat\0"
-       "BA\0"
+       "Az\xc9\x99rbaycan\0"
+       "AZN\0"
+       "Azerbaijani Manat\0"
+       "Az\xc9\x99rbaycan manat\xc4\xb1\0"
+       "BIH\0"
        "Bosnia and Herzegovina\0"
+       "\xd0\x91\xd0\xbe\xd1\x81\xd0\xbd\xd0\xb0 \xd0\xb8 \xd0\xa5\xd0\xb5\xd1\x80\xd1\x86\xd0\xb5\xd0\xb3\xd0\xbe\xd0\xb2\xd0\xb8\xd0\xbd\xd0\xb0\0"
        "BAM\0"
        "Bosnia-Herzegovina Convertible Mark\0"
-       "BB\0"
-       "Barbados\0"
-       "BBD\0"
-       "Barbados Dollar\0"
-       "BD\0"
+       "Bosansko-Hercegova\xc4\x8dka konvertibilna marka\0"
+       "BGD\0"
        "Bangladesh\0"
+       "\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\x82\xe0\xa6\xb2\xe0\xa6\xbe\xe0\xa6\xa6\xe0\xa7\x87\xe0\xa6\xb6\0"
        "BDT\0"
-       "Bangladesh Taka\0"
+       "Bangladeshi Taka\0"
+       "\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\x82\xe0\xa6\xb2\xe0\xa6\xbe\xe0\xa6\xa6\xe0\xa7\x87\xe0\xa6\xb6\xe0\xa7\x80 \xe0\xa6\x9f\xe0\xa6\xbe\xe0\xa6\x95\xe0\xa6\xbe\0"
        "Belgium\0"
-       "BF\0"
-       "Burkina Faso\0"
-       "XOF\0"
-       "CFA Franc BCEAO\0"
+       "Belgique\0"
+       "euro\0"
        "Bulgaria\0"
+       "\xd0\x91\xd1\x8a\xd0\xbb\xd0\xb3\xd0\xb0\xd1\x80\xd0\xb8\xd1\x8f\0"
        "BGN\0"
-       "Bulgarian New Lev\0"
+       "Bulgarian Lev\0"
+       "\xd0\x91\xd1\x8a\xd0\xbb\xd0\xb3\xd0\xb0\xd1\x80\xd1\x81\xd0\xba\xd0\xb8 \xd0\xbb\xd0\xb5\xd0\xb2\0"
+       "BHR\0"
        "Bahrain\0"
+       "\xd8\xa7\xd9\x84\xd8\xa8\xd8\xad\xd8\xb1\xd9\x8a\xd9\x86\0"
        "BHD\0"
        "Bahraini Dinar\0"
-       "BI\0"
-       "Burundi\0"
-       "BIF\0"
-       "Burundi Franc\0"
-       "BJ\0"
-       "Benin\0"
-       "BM\0"
-       "Bermuda\0"
-       "BMD\0"
-       "Bermudan Dollar\0"
-       "BN\0"
+       "\xd8\xaf\xd9\x8a\xd9\x86\xd8\xa7\xd8\xb1 \xd8\xa8\xd8\xad\xd8\xb1\xd9\x8a\xd9\x86\xd9\x8a\0"
+       "BRN\0"
        "Brunei\0"
        "BND\0"
        "Brunei Dollar\0"
+       "Dolar Brunei\0"
+       "BOL\0"
        "Bolivia\0"
-       "BOB\0"
-       "Boliviano\0"
+       "Bolivian Boliviano\0"
+       "boliviano\0"
+       "BRA\0"
        "Brazil\0"
+       "Brasil\0"
        "BRL\0"
        "Brazilian Real\0"
-       "BS\0"
-       "Bahamas\0"
-       "BSD\0"
-       "Bahamian Dollar\0"
-       "BV\0"
-       "Bouvet Island\0"
-       "NOK\0"
-       "Norwegian Krone\0"
-       "BW\0"
-       "Botswana\0"
-       "BWP\0"
-       "Botswanan Pula\0"
+       "Real brasileiro\0"
+       "BLR\0"
        "Belarus\0"
+       "\xd0\x91\xd0\xb5\xd0\xbb\xd0\xb0\xd1\x80\xd1\x83\xd1\x81\xd1\x8c\0"
        "BYR\0"
-       "Belarussian Ruble\0"
-       "BZ\0"
+       "Belarusian Ruble\0"
+       "\xd0\xb1\xd0\xb5\xd0\xbb\xd0\xb0\xd1\x80\xd1\x83\xd1\x81\xd0\xba\xd1\x96 \xd1\x80\xd1\x83\xd0\xb1\xd0\xb5\xd0\xbb\xd1\x8c\0"
+       "BLZ\0"
        "Belize\0"
        "BZD\0"
        "Belize Dollar\0"
+       "CAN\0"
        "Canada\0"
        "CAD\0"
        "Canadian Dollar\0"
-       "CC\0"
-       "Cocos Islands\0"
-       "CD\0"
-       "Democratic Republic of the Congo\0"
-       "CDF\0"
-       "Congolese Franc Congolais\0"
-       "CF\0"
-       "Central African Republic\0"
-       "XAF\0"
-       "CFA Franc BEAC\0"
-       "CG\0"
-       "Congo\0"
+       "dollar canadien\0"
+       "CHE\0"
        "Switzerland\0"
+       "Svizra\0"
        "CHF\0"
        "Swiss Franc\0"
-       "CI\0"
-       "C\xc3\xb4te d'Ivoire\0"
-       "CK\0"
-       "Cook Islands\0"
-       "NZD\0"
-       "New Zealand Dollar\0"
+       "franc svizzer\0"
+       "CHL\0"
        "Chile\0"
        "CLP\0"
        "Chilean Peso\0"
-       "CM\0"
-       "Cameroon\0"
+       "peso chileno\0"
+       "CHN\0"
        "China\0"
+       "\xe0\xbd\xa2\xe0\xbe\x92\xe0\xbe\xb1\xe0\xbc\x8b\xe0\xbd\x93\xe0\xbd\x82\0"
        "CNY\0"
-       "Chinese Yuan Renminbi\0"
+       "Chinese Yuan\0"
+       "\xe0\xbd\xa1\xe0\xbd\xb4\xe0\xbc\x8b\xe0\xbd\xa8\xe0\xbd\x93\xe0\xbc\x8b\0"
+       "COL\0"
        "Colombia\0"
        "COP\0"
        "Colombian Peso\0"
+       "peso colombiano\0"
+       "CRI\0"
        "Costa Rica\0"
-       "Costa Rican Colon\0"
-       "CU\0"
-       "Cuba\0"
-       "CUP\0"
-       "Cuban Peso\0"
-       "CV\0"
-       "Cape Verde\0"
-       "CVE\0"
-       "Cape Verde Escudo\0"
-       "CX\0"
-       "Christmas Island\0"
-       "CY\0"
-       "Cyprus\0"
-       "CYP\0"
-       "Cyprus Pound\0"
+       "CRC\0"
+       "Costa Rican Col\xc3\xb3n\0"
+       "col\xc3\xb3n costarricense\0"
+       "CZE\0"
        "Czech Republic\0"
+       "\xc4\x8c\x65sk\xc3\xa1 republika\0"
        "CZK\0"
        "Czech Republic Koruna\0"
+       "\xc4\x8d\x65sk\xc3\xa1 koruna\0"
        "Germany\0"
-       "DJ\0"
-       "Djibouti\0"
-       "DJF\0"
-       "Djibouti Franc\0"
+       "Deutschland\0"
+       "DNK\0"
        "Denmark\0"
+       "Danmark\0"
        "DKK\0"
        "Danish Krone\0"
-       "DM\0"
-       "Dominica\0"
+       "Dansk krone\0"
+       "DOM\0"
        "Dominican Republic\0"
+       "Rep\xc3\xba\x62lica Dominicana\0"
        "DOP\0"
        "Dominican Peso\0"
+       "peso dominicano\0"
+       "DZA\0"
        "Algeria\0"
+       "\xd8\xa7\xd9\x84\xd8\xac\xd8\xb2\xd8\xa7\xd8\xa6\xd8\xb1\0"
        "DZD\0"
        "Algerian Dinar\0"
+       "\xd8\xaf\xd9\x8a\xd9\x86\xd8\xa7\xd8\xb1 \xd8\xac\xd8\xb2\xd8\xa7\xd8\xa6\xd8\xb1\xd9\x8a\0"
+       "ECU\0"
        "Ecuador\0"
-       "ECS\0"
-       "Ecuador Sucre\0"
+       "USD\0"
+       "US Dollar\0"
+       "d\xc3\xb3lar estadounidense\0"
        "Estonia\0"
-       "EEK\0"
-       "Estonian Kroon\0"
+       "Eesti\0"
+       "EGY\0"
        "Egypt\0"
+       "\xd9\x85\xd8\xb5\xd8\xb1\0"
        "EGP\0"
        "Egyptian Pound\0"
-       "EH\0"
-       "Western Sahara\0"
-       "MAD\0"
-       "Moroccan Dirham\0"
-       "ER\0"
-       "Eritrea\0"
-       "ERN\0"
-       "Eritrean Nakfa\0"
+       "\xd8\xac\xd9\x86\xd9\x8a\xd9\x87 \xd9\x85\xd8\xb5\xd8\xb1\xd9\x8a\0"
        "Spain\0"
-       "ET\0"
+       "Espanya\0"
+       "ETH\0"
        "Ethiopia\0"
+       "\xe1\x8a\xa2\xe1\x89\xb5\xe1\x8b\xae\xe1\x8c\xb5\xe1\x8b\xab\0"
        "ETB\0"
        "Ethiopian Birr\0"
+       "\xe1\x8b\xa8\xe1\x8a\xa2\xe1\x89\xb5\xe1\x8b\xae\xe1\x8c\xb5\xe1\x8b\xab \xe1\x89\xa5\xe1\x88\xad\0"
        "Finland\0"
-       "FJ\0"
-       "Fiji\0"
-       "FJD\0"
-       "Fiji Dollar\0"
-       "FK\0"
-       "Falkland Islands\0"
-       "FKP\0"
-       "Falkland Islands Pound\0"
-       "FM\0"
-       "Micronesia\0"
+       "Suomi\0"
+       "FRO\0"
        "Faroe Islands\0"
+       "F\xc3\xb8royar\0"
+       "donsk kr\xc3\xb3na\0"
        "France\0"
-       "GA\0"
-       "Gabon\0"
+       "GBR\0"
        "United Kingdom\0"
+       "Prydain Fawr\0"
        "GBP\0"
        "British Pound Sterling\0"
-       "GD\0"
-       "Grenada\0"
+       "Punt Sterling Prydain\0"
+       "GEO\0"
        "Georgia\0"
+       "\xe1\x83\xa1\xe1\x83\x90\xe1\x83\xa5\xe1\x83\x90\xe1\x83\xa0\xe1\x83\x97\xe1\x83\x95\xe1\x83\x94\xe1\x83\x9a\xe1\x83\x9d\0"
        "GEL\0"
        "Georgian Lari\0"
-       "GF\0"
-       "French Guiana\0"
-       "GH\0"
-       "Ghana\0"
-       "GHC\0"
-       "Ghana Cedi\0"
-       "GI\0"
-       "Gibraltar\0"
-       "GIP\0"
-       "Gibraltar Pound\0"
-       "GL\0"
+       "\xe1\x83\xa5\xe1\x83\x90\xe1\x83\xa0\xe1\x83\x97\xe1\x83\xa3\xe1\x83\x9a\xe1\x83\x98 \xe1\x83\x9a\xe1\x83\x90\xe1\x83\xa0\xe1\x83\x98\0"
+       "GRL\0"
        "Greenland\0"
-       "GM\0"
-       "Gambia\0"
-       "GMD\0"
-       "Gambia Dalasi\0"
-       "GN\0"
-       "Guinea\0"
-       "GNF\0"
-       "Guinea Franc\0"
-       "GP\0"
-       "Guadeloupe\0"
-       "GQ\0"
-       "Equatorial Guinea\0"
+       "Kalaallit Nunaat\0"
+       "danskinut koruuni\0"
+       "GRC\0"
        "Greece\0"
+       "\xce\x95\xce\xbb\xce\xbb\xce\xac\xce\xb4\xce\xb1\0"
+       "\xce\x95\xcf\x85\xcf\x81\xcf\x8e\0"
+       "GTM\0"
        "Guatemala\0"
        "GTQ\0"
-       "Guatemala Quetzal\0"
-       "GU\0"
-       "Guam\0"
-       "GY\0"
-       "Guyana\0"
-       "GYD\0"
-       "Guyana Dollar\0"
-       "Hong Kong S.A.R., China\0"
+       "Guatemalan Quetzal\0"
+       "quetzal guatemalteco\0"
+       "HKG\0"
+       "Hong Kong SAR China\0"
+       "\xe4\xb8\xad\xe5\x9b\xbd\xe9\xa6\x99\xe6\xb8\xaf\xe7\x89\xb9\xe5\x88\xab\xe8\xa1\x8c\xe6\x94\xbf\xe5\x8c\xba\0"
        "HKD\0"
        "Hong Kong Dollar\0"
-       "HM\0"
-       "Heard Island and McDonald Islands\0"
+       "\xe6\xb8\xaf\xe5\x85\x83\0"
+       "HND\0"
        "Honduras\0"
        "HNL\0"
-       "Hoduras Lempira\0"
+       "Honduran Lempira\0"
+       "lempira hondure\xc3\xb1o\0"
        "Croatia\0"
+       "Hrvatska\0"
        "HRK\0"
        "Croatian Kuna\0"
+       "kuna\0"
        "Hungary\0"
+       "Magyarorsz\xc3\xa1g\0"
        "HUF\0"
        "Hungarian Forint\0"
+       "Magyar forint\0"
+       "IDN\0"
        "Indonesia\0"
        "IDR\0"
        "Indonesian Rupiah\0"
+       "Rupiah Indonesia\0"
+       "IRL\0"
        "Ireland\0"
+       "\xc3\x89ire\0"
+       "ISR\0"
        "Israel\0"
+       "\xd7\x99\xd7\xa9\xd7\xa8\xd7\x90\xd7\x9c\0"
        "ILS\0"
        "Israeli New Sheqel\0"
+       "\xd7\xa9\xd7\xb4\xd7\x97\0"
        "India\0"
+       "\xe0\xa4\xad\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa4\xa4\0"
        "INR\0"
        "Indian Rupee\0"
-       "IO\0"
-       "British Indian Ocean Territory\0"
+       "\xe0\xa4\xad\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa4\xa4\xe0\xa5\x80\xe0\xa4\xaf \xe0\xa4\xb0\xe0\xa5\x82\xe0\xa4\xaa\xe0\xa4\xaf\xe0\xa4\xbe\0"
+       "IRQ\0"
        "Iraq\0"
+       "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa7\xd9\x82\0"
        "IQD\0"
        "Iraqi Dinar\0"
+       "\xd8\xaf\xd9\x8a\xd9\x86\xd8\xa7\xd8\xb1 \xd8\xb9\xd8\xb1\xd8\xa7\xd9\x82\xd9\x8a\0"
+       "IRN\0"
        "Iran\0"
+       "\xd8\xa7\xdb\x8c\xd8\xb1\xd8\xa7\xd9\x86\0"
        "IRR\0"
        "Iranian Rial\0"
+       "\xd8\xb1\xdb\x8c\xd8\xa7\xd9\x84 \xd8\xa7\xdb\x8c\xd8\xb1\xd8\xa7\xd9\x86\0"
        "Iceland\0"
+       "\xc3\x8dsland\0"
        "ISK\0"
-       "Icelandic Krona\0"
+       "Icelandic Kr\xc3\xb3na\0"
+       "\xc3\x8dslensk kr\xc3\xb3na\0"
        "Italy\0"
-       "JM\0"
+       "Italia\0"
+       "JAM\0"
        "Jamaica\0"
        "JMD\0"
        "Jamaican Dollar\0"
+       "JOR\0"
        "Jordan\0"
+       "\xd8\xa7\xd9\x84\xd8\xa3\xd8\xb1\xd8\xaf\xd9\x86\0"
        "JOD\0"
        "Jordanian Dinar\0"
+       "\xd8\xaf\xd9\x8a\xd9\x86\xd8\xa7\xd8\xb1 \xd8\xa3\xd8\xb1\xd8\xaf\xd9\x86\xd9\x8a\0"
        "Japan\0"
+       "\xe6\x97\xa5\xe6\x9c\xac\0"
        "JPY\0"
        "Japanese Yen\0"
+       "\xe6\x97\xa5\xe6\x9c\xac\xe5\x86\x86\0"
+       "KEN\0"
        "Kenya\0"
        "KES\0"
        "Kenyan Shilling\0"
-       "KG\0"
+       "shilingi ya Kenya\0"
+       "KGZ\0"
        "Kyrgyzstan\0"
+       "\xd0\x9a\xd1\x8b\xd1\x80\xd0\xb3\xd1\x8b\xd0\xb7\xd1\x81\xd1\x82\xd0\xb0\xd0\xbd\0"
        "KGS\0"
-       "Kyrgystan Som\0"
-       "KH\0"
+       "Kyrgystani Som\0"
        "Cambodia\0"
+       "\xe1\x9e\x80\xe1\x9e\x98\xe1\x9f\x92\xe1\x9e\x96\xe1\x9e\xbb\xe1\x9e\x87\xe1\x9e\xb6\0"
        "KHR\0"
        "Cambodian Riel\0"
-       "KI\0"
-       "Kiribati\0"
-       "KM\0"
-       "Comoros\0"
-       "KMF\0"
-       "Comoro Franc\0"
-       "KN\0"
-       "Saint Kitts and Nevis\0"
-       "KP\0"
-       "North Korea\0"
-       "KPW\0"
-       "North Korean Won\0"
+       "Riel\0"
        "South Korea\0"
+       "\xeb\x8c\x80\xed\x95\x9c\xeb\xaf\xbc\xea\xb5\xad\0"
        "KRW\0"
        "South Korean Won\0"
+       "\xeb\x8c\x80\xed\x95\x9c\xeb\xaf\xbc\xea\xb5\xad \xec\x9b\x90\0"
+       "KWT\0"
        "Kuwait\0"
+       "\xd8\xa7\xd9\x84\xd9\x83\xd9\x88\xd9\x8a\xd8\xaa\0"
        "KWD\0"
        "Kuwaiti Dinar\0"
-       "KY\0"
-       "Cayman Islands\0"
-       "KYD\0"
-       "Cayman Islands Dollar\0"
-       "KZ\0"
-       "Kazakhstan\0"
-       "KZT\0"
-       "Kazakhstan Tenge\0"
-       "LA\0"
+       "\xd8\xaf\xd9\x8a\xd9\x86\xd8\xa7\xd8\xb1 \xd9\x83\xd9\x88\xd9\x8a\xd8\xaa\xd9\x8a\0"
        "Laos\0"
        "LAK\0"
        "Laotian Kip\0"
+       "\xe0\xba\x81\xe0\xba\xb5\xe0\xba\x9a\0"
+       "LBN\0"
        "Lebanon\0"
+       "\xd9\x84\xd8\xa8\xd9\x86\xd8\xa7\xd9\x86\0"
        "LBP\0"
        "Lebanese Pound\0"
-       "LC\0"
-       "Saint Lucia\0"
-       "LI\0"
+       "\xd8\xac\xd9\x86\xd9\x8a\xd8\xa9 \xd9\x84\xd8\xa8\xd9\x86\xd8\xa7\xd9\x86\xd9\x8a\0"
+       "LIE\0"
        "Liechtenstein\0"
-       "LK\0"
+       "Schweizer Franken\0"
+       "LKA\0"
        "Sri Lanka\0"
+       "\xe0\xb7\x81\xe0\xb7\x8a\xe2\x80\x8d\xe0\xb6\xbb\xe0\xb7\x93 \xe0\xb6\xbd\xe0\xb6\x82\xe0\xb6\x9a\xe0\xb7\x8f\xe0\xb7\x80\0"
        "LKR\0"
-       "Sri Lanka Rupee\0"
-       "LR\0"
-       "Liberia\0"
-       "LRD\0"
-       "Liberian Dollar\0"
+       "Sri Lankan Rupee\0"
+       "\xe0\xb6\xbd\xe0\xb6\x82\xe0\xb6\x9a\xe0\xb7\x8f \xe0\xb6\xbb\xe0\xb7\x94\xe0\xb6\xb4\xe0\xb7\x92\xe0\xb6\xba\xe0\xb6\xbd\xe0\xb7\x8a\0"
+       "LTU\0"
        "Lithuania\0"
+       "Lietuva\0"
        "LTL\0"
-       "Lithuanian Lita\0"
+       "Lithuanian Litas\0"
+       "Litas\0"
+       "LUX\0"
        "Luxembourg\0"
+       "Luxemburg\0"
+       "LVA\0"
        "Latvia\0"
+       "Latvija\0"
        "LVL\0"
        "Latvian Lats\0"
+       "Latvijas lats\0"
+       "LBY\0"
        "Libya\0"
+       "\xd9\x84\xd9\x8a\xd8\xa8\xd9\x8a\xd8\xa7\0"
        "LYD\0"
        "Libyan Dinar\0"
+       "\xd8\xaf\xd9\x8a\xd9\x86\xd8\xa7\xd8\xb1 \xd9\x84\xd9\x8a\xd8\xa8\xd9\x8a\0"
        "Morocco\0"
-       "MC\0"
+       "\xd8\xa7\xd9\x84\xd9\x85\xd8\xba\xd8\xb1\xd8\xa8\0"
+       "MAD\0"
+       "Moroccan Dirham\0"
+       "\xd8\xaf\xd8\xb1\xd9\x87\xd9\x85 \xd9\x85\xd8\xba\xd8\xb1\xd8\xa8\xd9\x8a\0"
+       "MCO\0"
        "Monaco\0"
-       "Moldova\0"
-       "MDL\0"
-       "Moldovan Leu\0"
-       "MG\0"
-       "Madagascar\0"
-       "MGF\0"
-       "Madagascar Franc\0"
-       "MH\0"
-       "Marshall Islands\0"
-       "Macedonia\0"
+       "MNE\0"
+       "Montenegro\0"
+       "\xd0\xa6\xd1\x80\xd0\xbd\xd0\xb0 \xd0\x93\xd0\xbe\xd1\x80\xd0\xb0\0"
+       "Evro\0"
        "MKD\0"
+       "Macedonia\0"
+       "\xd0\x9c\xd0\xb0\xd0\xba\xd0\xb5\xd0\xb4\xd0\xbe\xd0\xbd\xd0\xb8\xd1\x98\xd0\xb0\0"
        "Macedonian Denar\0"
-       "ML\0"
-       "Mali\0"
-       "MM\0"
-       "Myanmar\0"
-       "MMK\0"
-       "Myanmar Kyat\0"
-       "MN\0"
-       "Mongolia\0"
-       "MNT\0"
-       "Mongolian Tugrik\0"
-       "Macao S.A.R. China\0"
+       "\xd0\x9c\xd0\xb0\xd0\xba\xd0\xb5\xd0\xb4\xd0\xbe\xd0\xbd\xd1\x81\xd0\xba\xd0\xb8 \xd0\xb4\xd0\xb5\xd0\xbd\xd0\xb0\xd1\x80\0"
+       "MAC\0"
+       "Macau SAR China\0"
+       "\xe4\xb8\xad\xe5\x9b\xbd\xe6\xbe\xb3\xe9\x97\xa8\xe7\x89\xb9\xe5\x88\xab\xe8\xa1\x8c\xe6\x94\xbf\xe5\x8c\xba\0"
        "MOP\0"
-       "Macao Pataca\0"
-       "MP\0"
-       "Northern Mariana Islands\0"
-       "MQ\0"
-       "Martinique\0"
-       "MR\0"
-       "Mauritania\0"
-       "MRO\0"
-       "Mauritania Ouguiya\0"
-       "MS\0"
-       "Montserrat\0"
-       "MT\0"
+       "Macanese Pataca\0"
+       "\xe6\xbe\xb3\xe9\x96\x80\xe5\x85\x83\0"
        "Malta\0"
-       "MTL\0"
-       "Maltese Lira\0"
-       "MU\0"
-       "Mauritius\0"
-       "MUR\0"
-       "Mauritius Rupee\0"
-       "MV\0"
-       "Maldives\0"
-       "MVR\0"
-       "Maldive Islands Rufiyaa\0"
-       "MW\0"
-       "Malawi\0"
-       "MWK\0"
-       "Malawi Kwacha\0"
+       "Ewro\0"
+       "MEX\0"
        "Mexico\0"
+       "M\xc3\xa9xico\0"
        "MXN\0"
        "Mexican Peso\0"
-       "MY\0"
+       "peso mexicano\0"
+       "MYS\0"
        "Malaysia\0"
        "MYR\0"
        "Malaysian Ringgit\0"
-       "MZ\0"
-       "Mozambique\0"
-       "MZM\0"
-       "Mozambique Metical\0"
-       "NC\0"
-       "New Caledonia\0"
-       "XPF\0"
-       "CFP Franc\0"
-       "NE\0"
-       "Niger\0"
-       "NF\0"
-       "Norfolk Island\0"
-       "NG\0"
+       "Ringgit Malaysia\0"
+       "NGA\0"
        "Nigeria\0"
+       "Najeriya\0"
        "NGN\0"
        "Nigerian Naira\0"
+       "Naira\0"
+       "NIC\0"
        "Nicaragua\0"
        "NIO\0"
-       "Nicaraguan Cordoba Oro\0"
+       "Nicaraguan C\xc3\xb3rdoba\0"
+       "c\xc3\xb3rdoba nicarag\xc3\xbc\x65nse\0"
        "Netherlands\0"
+       "Nederland\0"
        "Norway\0"
-       "NP\0"
+       "Norge\0"
+       "NOK\0"
+       "Norwegian Krone\0"
+       "norske kroner\0"
+       "NPL\0"
        "Nepal\0"
+       "\xe0\xa4\xa8\xe0\xa5\x87\xe0\xa4\xaa\xe0\xa4\xbe\xe0\xa4\xb2\0"
        "NPR\0"
        "Nepalese Rupee\0"
-       "NR\0"
-       "Nauru\0"
-       "NU\0"
-       "Niue\0"
+       "NZL\0"
        "New Zealand\0"
+       "NZD\0"
+       "New Zealand Dollar\0"
+       "OMN\0"
        "Oman\0"
+       "\xd8\xb9\xd9\x8f\xd9\x85\xd8\xa7\xd9\x86\0"
        "OMR\0"
-       "Oman Rial\0"
+       "Omani Rial\0"
+       "\xd8\xb1\xd9\x8a\xd8\xa7\xd9\x84 \xd8\xb9\xd9\x85\xd8\xa7\xd9\x86\xd9\x8a\0"
        "Panama\0"
+       "Panam\xc3\xa1\0"
        "PAB\0"
        "Panamanian Balboa\0"
+       "balboa paname\xc3\xb1o\0"
+       "PER\0"
        "Peru\0"
+       "Per\xc3\xba\0"
        "PEN\0"
-       "Peruvian Sol Nuevo\0"
-       "PF\0"
-       "French Polynesia\0"
-       "PG\0"
-       "Papua New Guinea\0"
-       "PGK\0"
-       "Papua New Guinea Kina\0"
+       "Peruvian Nuevo Sol\0"
+       "nuevo sol peruano\0"
+       "PHL\0"
        "Philippines\0"
+       "Pilipinas\0"
+       "PHP\0"
        "Philippine Peso\0"
-       "PK\0"
+       "PAK\0"
        "Pakistan\0"
+       "\xd9\xbe\xd8\xa7\xda\xa9\xd8\xb3\xd8\xaa\xd8\xa7\xd9\x86\0"
        "PKR\0"
-       "Pakistan Rupee\0"
+       "Pakistani Rupee\0"
+       "\xd9\xbe\xd8\xa7\xda\xa9\xd8\xb3\xd8\xaa\xd8\xa7\xd9\x86\xdb\x8c \xd8\xb1\xd9\x88\xd9\xbe\xdb\x8c\xdb\x81\0"
+       "POL\0"
        "Poland\0"
+       "Polska\0"
        "PLN\0"
        "Polish Zloty\0"
-       "Saint Pierre and Miquelon\0"
-       "PN\0"
-       "Pitcairn\0"
+       "z\xc5\x82oty polski\0"
+       "PRI\0"
        "Puerto Rico\0"
+       "PRT\0"
        "Portugal\0"
-       "PW\0"
-       "Palau\0"
+       "PRY\0"
        "Paraguay\0"
        "PYG\0"
-       "Paraguay Guarani\0"
+       "Paraguayan Guarani\0"
+       "guaran\xc3\xad paraguayo\0"
+       "QAT\0"
        "Qatar\0"
+       "\xd9\x82\xd8\xb7\xd8\xb1\0"
        "QAR\0"
        "Qatari Rial\0"
-       "RE\0"
-       "R\xc3\xa9union\0"
+       "\xd8\xb1\xd9\x8a\xd8\xa7\xd9\x84 \xd9\x82\xd8\xb7\xd8\xb1\xd9\x8a\0"
+       "ROU\0"
        "Romania\0"
-       "ROL\0"
+       "Rom\xc3\xa2nia\0"
+       "RON\0"
        "Romanian Leu\0"
+       "leu rom\xc3\xa2nesc\0"
+       "Serbia\0"
+       "\xd0\xa1\xd1\x80\xd0\xb1\xd0\xb8\xd1\x98\xd0\xb0\0"
+       "RSD\0"
+       "Serbian Dinar\0"
+       "Srpski dinar\0"
        "Russia\0"
-       "RUR\0"
-       "Russian Ruble (1991-1998)\0"
-       "RW\0"
+       "\xd0\xa0\xd0\xbe\xd1\x81\xd1\x81\xd0\xb8\xd1\x8f\0"
+       "RUB\0"
+       "Russian Ruble\0"
+       "\xd0\xa0\xd0\xbe\xd1\x81\xd1\x81\xd0\xb8\xd0\xb9\xd1\x81\xd0\xba\xd0\xb8\xd0\xb9 \xd1\x80\xd1\x83\xd0\xb1\xd0\xbb\xd1\x8c\0"
+       "RWA\0"
        "Rwanda\0"
        "RWF\0"
        "Rwandan Franc\0"
+       "SAU\0"
        "Saudi Arabia\0"
+       "\xd8\xa7\xd9\x84\xd9\x85\xd9\x85\xd9\x84\xd9\x83\xd8\xa9 \xd8\xa7\xd9\x84\xd8\xb9\xd8\xb1\xd8\xa8\xd9\x8a\xd8\xa9 \xd8\xa7\xd9\x84\xd8\xb3\xd8\xb9\xd9\x88\xd8\xaf\xd9\x8a\xd8\xa9\0"
        "SAR\0"
        "Saudi Riyal\0"
-       "SB\0"
-       "Solomon Islands\0"
-       "SBD\0"
-       "Solomon Islands Dollar\0"
-       "SC\0"
-       "Seychelles\0"
-       "SCR\0"
-       "Seychelles Rupee\0"
-       "SD\0"
-       "Sudan\0"
-       "SDD\0"
-       "Sudanese Dinar\0"
+       "\xd8\xb1\xd9\x8a\xd8\xa7\xd9\x84 \xd8\xb3\xd8\xb9\xd9\x88\xd8\xaf\xd9\x8a\0"
+       "SWE\0"
        "Sweden\0"
+       "Sverige\0"
        "SEK\0"
        "Swedish Krona\0"
+       "svensk krona\0"
+       "SGP\0"
        "Singapore\0"
+       "\xe6\x96\xb0\xe5\x8a\xa0\xe5\x9d\xa1\0"
        "SGD\0"
        "Singapore Dollar\0"
-       "SH\0"
-       "Saint Helena\0"
-       "SHP\0"
-       "Saint Helena Pound\0"
+       "\xe6\x96\xb0\xe5\x8a\xa0\xe5\x9d\xa1\xe5\x85\x83\0"
+       "SVN\0"
        "Slovenia\0"
-       "Slovenia Tolar\0"
-       "SJ\0"
-       "Svalbard and Jan Mayen\0"
+       "Slovenija\0"
+       "evro\0"
+       "SVK\0"
        "Slovakia\0"
-       "SKK\0"
-       "Slovak Koruna\0"
-       "SL\0"
-       "Sierra Leone\0"
-       "SLL\0"
-       "Sierra Leone Leone\0"
-       "SM\0"
-       "San Marino\0"
-       "SN\0"
-       "Senegal\0"
-       "SO\0"
-       "Somalia\0"
-       "SOS\0"
-       "Somali Shilling\0"
-       "SR\0"
-       "Suriname\0"
-       "SRG\0"
-       "Suriname Guilder\0"
-       "ST\0"
-       "Sao Tome and Principe\0"
-       "STD\0"
-       "Sao Tome and Principe Dobra\0"
+       "Slovensk\xc3\xa1 republika\0"
        "El Salvador\0"
-       "El Salvador Colon\0"
+       "SYR\0"
        "Syria\0"
+       "\xd8\xb3\xd9\x88\xd8\xb1\xd9\x8a\xd8\xa7\0"
        "SYP\0"
        "Syrian Pound\0"
-       "SZ\0"
-       "Swaziland\0"
-       "SZL\0"
-       "Swaziland Lilangeni\0"
-       "TC\0"
-       "Turks and Caicos Islands\0"
-       "TD\0"
-       "Chad\0"
-       "TF\0"
-       "French Southern Territories\0"
-       "TG\0"
-       "Togo\0"
+       "\xd9\x84\xd9\x8a\xd8\xb1\xd8\xa9 \xd8\xb3\xd9\x88\xd8\xb1\xd9\x8a\xd8\xa9\0"
        "Thailand\0"
        "THB\0"
        "Thai Baht\0"
-       "TJ\0"
+       "\xe0\xb8\x9a\xe0\xb8\xb2\xe0\xb8\x97\xe0\xb9\x84\xe0\xb8\x97\xe0\xb8\xa2\0"
+       "TJK\0"
        "Tajikistan\0"
        "TJS\0"
-       "Tajikistan Somoni\0"
-       "TK\0"
-       "Tokelau\0"
-       "Timor-Leste\0"
-       "TM\0"
-       "Turkmenistan\0"
-       "TMM\0"
-       "Turkmenistan Manat\0"
+       "Tajikistani Somoni\0"
+       "\xd0\xa1\xd0\xbe\xd0\xbc\xd0\xbe\xd0\xbd\xd3\xa3\0"
+       "TUN\0"
        "Tunisia\0"
+       "\xd8\xaa\xd9\x88\xd9\x86\xd8\xb3\0"
        "TND\0"
        "Tunisian Dinar\0"
-       "TO\0"
-       "Tonga\0"
-       "TOP\0"
-       "Tonga Pa\xc2\xb4\x61nga\0"
+       "\xd8\xaf\xd9\x8a\xd9\x86\xd8\xa7\xd8\xb1\xd8\xaa\xd9\x88\xd9\x86\xd8\xb3\xd9\x8a\0"
+       "TUR\0"
        "Turkey\0"
-       "TRL\0"
+       "T\xc3\xbcrkiye\0"
+       "TRY\0"
        "Turkish Lira\0"
+       "T\xc3\xbcrk Liras\xc4\xb1\0"
+       "TTO\0"
        "Trinidad and Tobago\0"
        "TTD\0"
        "Trinidad and Tobago Dollar\0"
-       "TV\0"
-       "Tuvalu\0"
+       "TWN\0"
        "Taiwan\0"
+       "\xe5\x8f\xb0\xe6\xb9\xbe\0"
        "TWD\0"
-       "Taiwan New Dollar\0"
-       "TZ\0"
-       "Tanzania\0"
-       "TZS\0"
-       "Tanzanian Shilling\0"
+       "New Taiwan Dollar\0"
+       "\xe6\x96\xb0\xe8\x87\xba\xe5\xb9\xa3\0"
        "Ukraine\0"
+       "\xd0\xa3\xd0\xba\xd1\x80\xd0\xb0\xd1\x97\xd0\xbd\xd0\xb0\0"
        "UAH\0"
        "Ukrainian Hryvnia\0"
-       "UG\0"
-       "Uganda\0"
-       "UGX\0"
-       "Ugandan Shilling\0"
-       "UM\0"
-       "United States Minor Outlying Islands\0"
+       "\xd0\xa3\xd0\xba\xd1\x80\xd0\xb0\xd1\x97\xd0\xbd\xd1\x81\xd1\x8c\xd0\xba\xd0\xb0 \xd0\xb3\xd1\x80\xd0\xb8\xd0\xb2\xd0\xbd\xd1\x8f\0"
+       "USA\0"
        "United States\0"
+       "URY\0"
        "Uruguay\0"
        "UYU\0"
-       "Uruguay Peso Uruguayo\0"
-       "UZ\0"
+       "Uruguayan Peso\0"
+       "peso uruguayo\0"
        "Uzbekistan\0"
+       "\xd0\x8e\xd0\xb7\xd0\xb1\xd0\xb5\xd0\xba\xd0\xb8\xd1\x81\xd1\x82\xd0\xbe\xd0\xbd\0"
        "UZS\0"
-       "Uzbekistan Sum\0"
-       "VA\0"
-       "Vatican\0"
-       "VC\0"
-       "Saint Vincent and the Grenadines\0"
+       "Uzbekistan Som\0"
+       "O\xca\xbczbekiston so\xca\xbcm\0"
+       "VEN\0"
        "Venezuela\0"
-       "VEB\0"
-       "Venezuelan Bolivar\0"
-       "VG\0"
-       "British Virgin Islands\0"
-       "U.S. Virgin Islands\0"
+       "VEF\0"
+       "Venezuelan Bol\xc3\xadvar\0"
+       "bol\xc3\xadvar venezolano\0"
+       "VNM\0"
        "Vietnam\0"
+       "Vi\xe1\xbb\x87t Nam\0"
        "VND\0"
        "Vietnamese Dong\0"
-       "VU\0"
-       "Vanuatu\0"
-       "VUV\0"
-       "Vanuatu Vatu\0"
-       "WF\0"
-       "Wallis and Futuna\0"
-       "WS\0"
-       "Samoa\0"
-       "WST\0"
-       "Western Samoa Tala\0"
+       "\xc4\x90\xe1\xbb\x93ng\0"
+       "YEM\0"
        "Yemen\0"
+       "\xd8\xa7\xd9\x84\xd9\x8a\xd9\x85\xd9\x86\0"
        "YER\0"
        "Yemeni Rial\0"
-       "YT\0"
-       "Mayotte\0"
-       "YU\0"
-       "Yugoslavia\0"
-       "YUM\0"
-       "Yugoslavian Noviy Dinar\0"
+       "\xd8\xb1\xd9\x8a\xd8\xa7\xd9\x84 \xd9\x8a\xd9\x85\xd9\x86\xd9\x8a\0"
+       "ZAF\0"
        "South Africa\0"
        "ZAR\0"
        "South African Rand\0"
-       "ZM\0"
-       "Zambia\0"
-       "ZMK\0"
-       "Zambian Kwacha\0"
+       "ZWE\0"
        "Zimbabwe\0"
-       "ZWD\0"
-       "Zimbabwe Dollar\0"
 };
 
 
index 2392e750e60591fa1eb98023bd4c7805a2680323..50e174ffe06743bef71b34b395e589b3227ed0df 100644 (file)
@@ -6,13 +6,13 @@
 
 #define NUM_DAYS 7
 #define NUM_MONTHS 13
-#define GROUP_SIZE 5
-#define NUM_OPT_CALS 5
+#define GROUP_SIZE 2
+#define NUM_CALENDARS 4
 
 #define NUM_SHORT_DATE_PATTERNS 14
 #define NUM_LONG_DATE_PATTERNS 8
-#define NUM_SHORT_TIME_PATTERNS 11
-#define NUM_LONG_TIME_PATTERNS 10
+#define NUM_SHORT_TIME_PATTERNS 12
+#define NUM_LONG_TIME_PATTERNS 9
 
 #define idx2string(idx) (locale_strings + (idx))
 
@@ -20,7 +20,6 @@
 typedef guint16 stridx_t;
 
 typedef struct {
-       const stridx_t full_date_time_pattern;
        const stridx_t long_date_pattern;
        const stridx_t short_date_pattern;
        const stridx_t long_time_pattern;
@@ -33,11 +32,14 @@ typedef struct {
 
        const stridx_t day_names [NUM_DAYS]; 
        const stridx_t abbreviated_day_names [NUM_DAYS];
+       const stridx_t shortest_day_names [NUM_DAYS];
        const stridx_t month_names [NUM_MONTHS];
+       const stridx_t month_genitive_names [NUM_MONTHS];
        const stridx_t abbreviated_month_names [NUM_MONTHS];
+       const stridx_t abbreviated_month_genitive_names [NUM_MONTHS];
 
-       gint8 calendar_week_rule;
-       gint8 first_day_of_week;
+       const gint8 calendar_week_rule;
+       const gint8 first_day_of_week;
 
        const stridx_t date_separator;
        const stridx_t time_separator;  
@@ -66,15 +68,15 @@ typedef struct {
        const stridx_t negative_sign;
        const stridx_t positive_sign;
 
-       gint8 currency_negative_pattern;
-       gint8 currency_positive_pattern;
-       gint8 percent_negative_pattern;
-       gint8 percent_positive_pattern;
-       gint8 number_negative_pattern;
+       const gint8 currency_negative_pattern;
+       const gint8 currency_positive_pattern;
+       const gint8 percent_negative_pattern;
+       const gint8 percent_positive_pattern;
+       const gint8 number_negative_pattern;
 
-       gint8 currency_decimal_digits;
-       gint8 percent_decimal_digits;
-       gint8 number_decimal_digits;
+       const gint8 currency_decimal_digits;
+       const gint8 percent_decimal_digits;
+       const gint8 number_decimal_digits;
 
        const gint currency_group_sizes [GROUP_SIZE];
        const gint percent_group_sizes [GROUP_SIZE];
@@ -86,53 +88,51 @@ typedef struct {
        const gint ebcdic;
        const gint mac;
        const gint oem;
+       const MonoBoolean is_right_to_left;
        const char list_sep;
 } TextInfoEntry;
 
 typedef struct {
-       gint16 lcid;
-       gint16 parent_lcid;
-       gint16 specific_lcid;
-       gint16 region_entry_index;
+       const gint16 lcid;
+       const gint16 parent_lcid;
+       const gint16 calendar_type;
+       const gint16 region_entry_index;
        const stridx_t name;
-       const stridx_t icu_name;
        const stridx_t englishname;
-       const stridx_t displayname;
        const stridx_t nativename;
        const stridx_t win3lang;
        const stridx_t iso3lang;
        const stridx_t iso2lang;
        const stridx_t territory;
+       const stridx_t native_calendar_names [NUM_CALENDARS];
 
-       gint calendar_data [NUM_OPT_CALS];
-
-       gint16 datetime_format_index;
-       gint16 number_format_index;
+       const gint16 datetime_format_index;
+       const gint16 number_format_index;
        
-       TextInfoEntry text_info;
+       const TextInfoEntry text_info;
 } CultureInfoEntry;
 
 typedef struct {
        const stridx_t name;
-       gint16 culture_entry_index;
+       const gint16 culture_entry_index;
 } CultureInfoNameEntry;
 
 typedef struct {
-       gint16 lcid;
-       gint16 region_id; /* it also works as geoId in 2.0 */
-       /* gint8 measurement_system; // 0:metric 1:US 2:UK */
+       const gint16 geo_id;
        const stridx_t iso2name;
        const stridx_t iso3name;
        const stridx_t win3name;
        const stridx_t english_name;
+       const stridx_t native_name;
        const stridx_t currency_symbol;
        const stridx_t iso_currency_symbol;
        const stridx_t currency_english_name;
+       const stridx_t currency_native_name;
 } RegionInfoEntry;
 
 typedef struct {
        const stridx_t name;
-       gint16 region_entry_index;
+       const gint16 region_entry_index;
 } RegionInfoNameEntry;
 
 #endif
index c0c37bc45b22ecec123aeae5af9ba6b60ed67893..7b971aa6fc92ba06e56b1d6efd1796899a51c21b 100644 (file)
@@ -117,35 +117,7 @@ ves_icall_System_IO_FAMW_InternalFAMNextEvent (gpointer conn,
 }
 #endif
 
-#if defined(__linux__) && defined(HAVE_SYS_SYSCALL_H) && !defined(__NR_inotify_init)
-#  if defined(__i386__)
-#     define __NR_inotify_init         291
-#  elif defined(__x86_64__)
-#     define __NR_inotify_init         253
-#  elif defined(__ppc__) || defined(__powerpc__) || defined(__powerpc64__)
-#     define __NR_inotify_init         275
-#  elif defined (__s390__) || defined (__s390x__)
-#     define __NR_inotify_init         284
-#  elif defined(__sparc__) || defined (__sparc64__)
-#     define __NR_inotify_init         151
-#  elif defined (__ia64__)
-#     define __NR_inotify_init         1277
-#  elif defined (__arm__)
-#     define __NR_inotify_init         316
-#  elif defined(__alpha__)
-#     define __NR_inotify_init         444
-#  endif
-#ifdef __NR_inotify_init
-#  ifndef __NR_inotify_add_watch
-#    define __NR_inotify_add_watch (__NR_inotify_init + 1)
-#  endif
-#  ifndef __NR_inotify_rm_watch
-#    define __NR_inotify_rm_watch (__NR_inotify_init + 2)
-#  endif
-#endif
-#endif
-
-#if !defined(__linux__) || !defined(__NR_inotify_init)
+#ifndef HAVE_SYS_INOTIFY_H
 int ves_icall_System_IO_InotifyWatcher_GetInotifyInstance ()
 {
        return -1;
@@ -161,12 +133,13 @@ int ves_icall_System_IO_InotifyWatcher_RemoveWatch (int fd, gint32 watch_descrip
        return -1;
 }
 #else
+#include <sys/inotify.h>
 #include <errno.h>
 
 int
 ves_icall_System_IO_InotifyWatcher_GetInotifyInstance ()
 {
-       return syscall (__NR_inotify_init);
+       return inotify_init ();
 }
 
 int
@@ -185,7 +158,7 @@ ves_icall_System_IO_InotifyWatcher_AddWatch (int fd, MonoString *name, gint32 ma
        if (!path)
                path = str;
 
-       retval = syscall (__NR_inotify_add_watch, fd, path, mask);
+       retval = inotify_add_watch (fd, path, mask);
        if (retval < 0) {
                switch (errno) {
                case EACCES:
@@ -221,7 +194,7 @@ ves_icall_System_IO_InotifyWatcher_AddWatch (int fd, MonoString *name, gint32 ma
 int
 ves_icall_System_IO_InotifyWatcher_RemoveWatch (int fd, gint32 watch_descriptor)
 {
-       return syscall (__NR_inotify_rm_watch, fd, watch_descriptor);
+       return inotify_rm_watch (fd, watch_descriptor);
 }
 #endif
 
index 2c2ccd3fd8771959e046a8d7d0151baca2fb944a..e3a4cbf682715be2bb4d9854591ccb5441cfd13f 100644 (file)
@@ -374,5 +374,8 @@ void mono_gc_bzero (void *dest, size_t size) MONO_INTERNAL;
 void mono_gc_memmove (void *dest, const void *src, size_t size) MONO_INTERNAL;
 
 guint mono_gc_get_vtable_bits (MonoClass *class) MONO_INTERNAL;
+
+void mono_gc_register_altstack (gpointer stack, gint32 stack_size, gpointer altstack, gint32 altstack_size) MONO_INTERNAL;
+
 #endif /* __MONO_METADATA_GC_INTERNAL_H__ */
 
index 0320be82630a6c60a31dfbf2a908a67b42c58bbc..284b847661973ad7bc2660dd3d88bb23802b3c90 100644 (file)
@@ -24,6 +24,7 @@
 #include <mono/metadata/metadata-internals.h>
 #include <mono/metadata/mono-mlist.h>
 #include <mono/metadata/threadpool.h>
+#include <mono/metadata/threadpool-internals.h>
 #include <mono/metadata/threads-types.h>
 #include <mono/utils/mono-logger-internal.h>
 #include <mono/metadata/gc-internal.h>
@@ -225,9 +226,8 @@ mono_gc_run_finalize (void *obj, void *data)
 
        runtime_invoke (o, NULL, &exc, NULL);
 
-       if (exc) {
-               /* fixme: do something useful */
-       }
+       if (exc)
+               mono_internal_thread_unhandled_exception (exc);
 
        mono_domain_set_internal (caller_domain);
 }
@@ -485,6 +485,13 @@ ves_icall_System_GC_WaitForPendingFinalizers (void)
                /* Avoid deadlocks */
                return;
 
+       /*
+       If the finalizer thread is not live, lets pretend no finalizers are pending since the current thread might
+       be the one responsible for starting it up.
+       */
+       if (gc_thread == NULL)
+               return;
+
        ResetEvent (pending_done_event);
        mono_gc_finalize_notify ();
        /* g_print ("Waiting for pending finalizers....\n"); */
@@ -1013,6 +1020,15 @@ finalize_domain_objects (DomainFinalizationReq *req)
 {
        MonoDomain *domain = req->domain;
 
+#if HAVE_SGEN_GC
+#define NUM_FOBJECTS 64
+       MonoObject *to_finalize [NUM_FOBJECTS];
+       int count;
+#endif
+
+       /* Process finalizers which are already in the queue */
+       mono_gc_invoke_finalizers ();
+
 #ifdef HAVE_BOEHM_GC
        while (g_hash_table_size (domain->finalizable_objects_hash) > 0) {
                int i;
@@ -1035,9 +1051,6 @@ finalize_domain_objects (DomainFinalizationReq *req)
                g_ptr_array_free (objs, TRUE);
        }
 #elif defined(HAVE_SGEN_GC)
-#define NUM_FOBJECTS 64
-       MonoObject *to_finalize [NUM_FOBJECTS];
-       int count;
        while ((count = mono_gc_finalizers_for_domain (domain, to_finalize, NUM_FOBJECTS))) {
                int i;
                for (i = 0; i < count; ++i) {
@@ -1046,9 +1059,6 @@ finalize_domain_objects (DomainFinalizationReq *req)
        }
 #endif
 
-       /* Process finalizers which are already in the queue */
-       mono_gc_invoke_finalizers ();
-
        /* cleanup the reference queue */
        reference_queue_clear_for_domain (domain);
        
@@ -1533,7 +1543,7 @@ mono_gc_bzero (void *dest, size_t size)
 {
        char *p = (char*)dest;
        char *end = p + size;
-       char *align_end = p + unaligned_bytes (p);
+       char *align_end = align_up (p);
        char *word_end;
 
        while (p < align_end)
index 57157938d9f72b11eb4f4ba6eb42edff9b5749d0..cb6e8b4ae2d6a9241a565688be4abe7a29a0edb7 100644 (file)
@@ -290,7 +290,7 @@ ICALL(CULINF_6, "construct_internal_locale_from_name", ves_icall_System_Globaliz
 ICALL(CULINF_7, "construct_internal_locale_from_specific_name", ves_icall_System_Globalization_CultureInfo_construct_internal_locale_from_specific_name)
 ICALL(CULINF_8, "construct_number_format", ves_icall_System_Globalization_CultureInfo_construct_number_format)
 ICALL(CULINF_9, "internal_get_cultures", ves_icall_System_Globalization_CultureInfo_internal_get_cultures)
-ICALL(CULINF_10, "internal_is_lcid_neutral", ves_icall_System_Globalization_CultureInfo_internal_is_lcid_neutral)
+//ICALL(CULINF_10, "internal_is_lcid_neutral", ves_icall_System_Globalization_CultureInfo_internal_is_lcid_neutral)
 
 ICALL_TYPE(REGINF, "System.Globalization.RegionInfo", REGINF_1)
 ICALL(REGINF_1, "construct_internal_region_from_lcid", ves_icall_System_Globalization_RegionInfo_construct_internal_region_from_lcid)
index 247d9596a11929b99de87825c7d349fae74ba7c6..bb447b0eecd633181f6dcf6e8001737d569e5583 100644 (file)
@@ -1640,6 +1640,7 @@ mono_image_close_except_pools (MonoImage *image)
        free_hash (image->var_cache_slow);
        free_hash (image->mvar_cache_slow);
        free_hash (image->wrapper_param_names);
+       free_hash (image->native_wrapper_aot_cache);
 
        /* The ownership of signatures is not well defined */
        //g_hash_table_foreach (image->memberref_signatures, free_mr_signatures, NULL);
index 2431465f431deadfe4dc7c09cb77f8d6a7ad0f7d..0774b82ae422e1f1859d2567a3817ec31f175574 100644 (file)
@@ -1180,11 +1180,32 @@ mono_dllmap_lookup (MonoImage *assembly, const char *dll, const char* func, cons
        return mono_dllmap_lookup_list (global_dll_map, dll, func, rdll, rfunc);
 }
 
-/*
+/**
  * mono_dllmap_insert:
+ * @assembly: if NULL, this is a global mapping, otherwise the remapping of the dynamic library will only apply to the specified assembly
+ * @dll: The name of the external library, as it would be found in the DllImport declaration.  If prefixed with 'i:' the matching of the library name is done without case sensitivity
+ * @func: if not null, the mapping will only applied to the named function (the value of EntryPoint)
+ * @tdll: The name of the library to map the specified @dll if it matches.
+ * @tfunc: if func is not NULL, the name of the function that replaces the invocation
  *
  * LOCKING: Acquires the loader lock.
  *
+ * This function is used to programatically add DllImport remapping in either
+ * a specific assembly, or as a global remapping.   This is done by remapping
+ * references in a DllImport attribute from the @dll library name into the @tdll
+ * name.    If the @dll name contains the prefix "i:", the comparison of the 
+ * library name is done without case sensitivity.
+ *
+ * If you pass @func, this is the name of the EntryPoint in a DllImport if specified
+ * or the name of the function as determined by DllImport.    If you pass @func, you
+ * must also pass @tfunc which is the name of the target function to invoke on a match.
+ *
+ * Example:
+ * mono_dllmap_insert (NULL, "i:libdemo.dll", NULL, relocated_demo_path, NULL);
+ *
+ * The above will remap DllImport statments for "libdemo.dll" and "LIBDEMO.DLL" to
+ * the contents of relocated_demo_path for all assemblies in the Mono process.
+ *
  * NOTE: This can be called before the runtime is initialized, for example from
  * mono_config_parse ().
  */
@@ -1366,6 +1387,18 @@ mono_lookup_pinvoke_call (MonoMethod *method, const char **exc_class, const char
 #endif
                }
 
+               if (!module && g_path_is_absolute (file_name)) {
+                       mono_trace (G_LOG_LEVEL_INFO, MONO_TRACE_DLLIMPORT,
+                                       "DllImport loading: '%s'.", file_name);
+                       module = cached_module_load (file_name, MONO_DL_LAZY, &error_msg);
+                       if (!module) {
+                               mono_trace (G_LOG_LEVEL_INFO, MONO_TRACE_DLLIMPORT,
+                                               "DllImport error loading library '%s'.",
+                                               error_msg);
+                               g_free (error_msg);
+                       }
+               }
+
                if (!module) {
                        void *iter = NULL;
                        char *mdirname = g_path_get_dirname (image->name);
index e188ee4ae49a480b08034d7652af0868f61e2c5f..23e63c5e733e20ae7d0b240391d7bff9a16b570c 100644 (file)
@@ -1,13 +1,15 @@
 /*
  * locales.c: Culture-sensitive handling
  *
- * Author:
+ * Authors:
  *     Dick Porter (dick@ximian.com)
  *     Mohammad DAMT (mdamt@cdl2000.com)
+ *     Marek Safar (marek.safar@gmail.com)
  *
  * Copyright 2003 Ximian, Inc (http://www.ximian.com)
  * Copyright 2004-2009 Novell, Inc (http://www.novell.com)
  * (C) 2003 PT Cakram Datalingga Duaribu  http://www.cdl2000.com
+ * Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
  */
 
 #include <config.h>
@@ -56,15 +58,6 @@ static const RegionInfoEntry* region_info_entry_from_lcid (int lcid);
 
 static int
 culture_lcid_locator (const void *a, const void *b)
-{
-       const CultureInfoEntry *aa = a;
-       const CultureInfoEntry *bb = b;
-
-       return (aa->lcid - bb->lcid);
-}
-
-static int
-region_lcid_locator (const void *a, const void *b)
 {
        const int *lcid = a;
        const CultureInfoEntry *bb = b;
@@ -119,6 +112,26 @@ create_group_sizes_array (const gint *gs, gint ml)
 
 static MonoArray*
 create_names_array_idx (const guint16 *names, int ml)
+{
+       MonoArray *ret;
+       MonoDomain *domain;
+       int i;
+
+       if (names == NULL)
+               return NULL;
+
+       domain = mono_domain_get ();
+
+       ret = mono_array_new_cached (mono_domain_get (), mono_get_string_class (), ml);
+
+       for(i = 0; i < ml; i++)
+               mono_array_setref (ret, i, mono_string_new (domain, idx2string (names [i])));
+
+       return ret;
+}
+
+static MonoArray*
+create_names_array_idx_dynamic (const guint16 *names, int ml)
 {
        MonoArray *ret;
        MonoDomain *domain;
@@ -160,7 +173,7 @@ ves_icall_System_Globalization_CultureInfo_construct_datetime_format (MonoCultur
        domain = mono_domain_get ();
 
        datetime->readOnly = this->is_read_only;
-       MONO_OBJECT_SETREF (datetime, AbbreviatedDayNames, create_names_array_idx (dfe->abbreviated_day_names,
+       MONO_OBJECT_SETREF (datetime, AbbreviatedDayNames, create_names_array_idx (dfe->abbreviated_day_names, 
                        NUM_DAYS));
        MONO_OBJECT_SETREF (datetime, AbbreviatedMonthNames, create_names_array_idx (dfe->abbreviated_month_names,
                        NUM_MONTHS));
@@ -168,8 +181,8 @@ ves_icall_System_Globalization_CultureInfo_construct_datetime_format (MonoCultur
        datetime->CalendarWeekRule = dfe->calendar_week_rule;
        MONO_OBJECT_SETREF (datetime, DateSeparator, mono_string_new (domain, idx2string (dfe->date_separator)));
        MONO_OBJECT_SETREF (datetime, DayNames, create_names_array_idx (dfe->day_names, NUM_DAYS));
+       MONO_OBJECT_SETREF (datetime, ShortestDayNames, create_names_array_idx (dfe->shortest_day_names, NUM_DAYS));
        datetime->FirstDayOfWeek = dfe->first_day_of_week;
-       MONO_OBJECT_SETREF (datetime, FullDateTimePattern, mono_string_new (domain, idx2string (dfe->full_date_time_pattern)));
        MONO_OBJECT_SETREF (datetime, LongDatePattern, mono_string_new (domain, idx2string (dfe->long_date_pattern)));
        MONO_OBJECT_SETREF (datetime, LongTimePattern, mono_string_new (domain, idx2string (dfe->long_time_pattern)));
        MONO_OBJECT_SETREF (datetime, MonthDayPattern, mono_string_new (domain, idx2string (dfe->month_day_pattern)));
@@ -179,15 +192,16 @@ ves_icall_System_Globalization_CultureInfo_construct_datetime_format (MonoCultur
        MONO_OBJECT_SETREF (datetime, ShortTimePattern, mono_string_new (domain, idx2string (dfe->short_time_pattern)));
        MONO_OBJECT_SETREF (datetime, TimeSeparator, mono_string_new (domain, idx2string (dfe->time_separator)));
        MONO_OBJECT_SETREF (datetime, YearMonthPattern, mono_string_new (domain, idx2string (dfe->year_month_pattern)));
-       MONO_OBJECT_SETREF (datetime, ShortDatePatterns, create_names_array_idx (dfe->short_date_patterns,
+       MONO_OBJECT_SETREF (datetime, ShortDatePatterns, create_names_array_idx_dynamic (dfe->short_date_patterns,
                        NUM_SHORT_DATE_PATTERNS));
-       MONO_OBJECT_SETREF (datetime, LongDatePatterns, create_names_array_idx (dfe->long_date_patterns,
+       MONO_OBJECT_SETREF (datetime, LongDatePatterns, create_names_array_idx_dynamic (dfe->long_date_patterns,
                        NUM_LONG_DATE_PATTERNS));
-       MONO_OBJECT_SETREF (datetime, ShortTimePatterns, create_names_array_idx (dfe->short_time_patterns,
+       MONO_OBJECT_SETREF (datetime, ShortTimePatterns, create_names_array_idx_dynamic (dfe->short_time_patterns,
                        NUM_SHORT_TIME_PATTERNS));
-       MONO_OBJECT_SETREF (datetime, LongTimePatterns, create_names_array_idx (dfe->long_time_patterns,
+       MONO_OBJECT_SETREF (datetime, LongTimePatterns, create_names_array_idx_dynamic (dfe->long_time_patterns,
                        NUM_LONG_TIME_PATTERNS));
-
+       MONO_OBJECT_SETREF (datetime, GenitiveMonthNames, create_names_array_idx (dfe->month_genitive_names, NUM_MONTHS));
+       MONO_OBJECT_SETREF (datetime, GenitiveAbbreviatedMonthNames, create_names_array_idx (dfe->abbreviated_month_genitive_names, NUM_MONTHS));
 }
 
 void
@@ -253,19 +267,20 @@ construct_culture (MonoCultureInfo *this, const CultureInfoEntry *ci)
 
        this->lcid = ci->lcid;
        MONO_OBJECT_SETREF (this, name, mono_string_new (domain, idx2string (ci->name)));
-       MONO_OBJECT_SETREF (this, icu_name, mono_string_new (domain, idx2string (ci->icu_name)));
-       MONO_OBJECT_SETREF (this, displayname, mono_string_new (domain, idx2string (ci->displayname)));
        MONO_OBJECT_SETREF (this, englishname, mono_string_new (domain, idx2string (ci->englishname)));
        MONO_OBJECT_SETREF (this, nativename, mono_string_new (domain, idx2string (ci->nativename)));
        MONO_OBJECT_SETREF (this, win3lang, mono_string_new (domain, idx2string (ci->win3lang)));
        MONO_OBJECT_SETREF (this, iso3lang, mono_string_new (domain, idx2string (ci->iso3lang)));
        MONO_OBJECT_SETREF (this, iso2lang, mono_string_new (domain, idx2string (ci->iso2lang)));
-       MONO_OBJECT_SETREF (this, territory, mono_string_new (domain, idx2string (ci->territory)));
+
+       // It's null for neutral cultures
+       if (ci->territory > 0)
+               MONO_OBJECT_SETREF (this, territory, mono_string_new (domain, idx2string (ci->territory)));
+       MONO_OBJECT_SETREF (this, native_calendar_names, create_names_array_idx (ci->native_calendar_names, NUM_CALENDARS));
        this->parent_lcid = ci->parent_lcid;
-       this->specific_lcid = ci->specific_lcid;
        this->datetime_index = ci->datetime_format_index;
        this->number_index = ci->number_format_index;
-       this->calendar_data = ci->calendar_data;
+       this->calendar_type = ci->calendar_type;
        this->text_info_data = &ci->text_info;
        
        return TRUE;
@@ -276,14 +291,16 @@ construct_region (MonoRegionInfo *this, const RegionInfoEntry *ri)
 {
        MonoDomain *domain = mono_domain_get ();
 
-       this->region_id = ri->region_id;
+       this->geo_id = ri->geo_id;
        MONO_OBJECT_SETREF (this, iso2name, mono_string_new (domain, idx2string (ri->iso2name)));
        MONO_OBJECT_SETREF (this, iso3name, mono_string_new (domain, idx2string (ri->iso3name)));
        MONO_OBJECT_SETREF (this, win3name, mono_string_new (domain, idx2string (ri->win3name)));
        MONO_OBJECT_SETREF (this, english_name, mono_string_new (domain, idx2string (ri->english_name)));
+       MONO_OBJECT_SETREF (this, native_name, mono_string_new (domain, idx2string (ri->native_name)));
        MONO_OBJECT_SETREF (this, currency_symbol, mono_string_new (domain, idx2string (ri->currency_symbol)));
        MONO_OBJECT_SETREF (this, iso_currency_symbol, mono_string_new (domain, idx2string (ri->iso_currency_symbol)));
        MONO_OBJECT_SETREF (this, currency_english_name, mono_string_new (domain, idx2string (ri->currency_english_name)));
+       MONO_OBJECT_SETREF (this, currency_native_name, mono_string_new (domain, idx2string (ri->currency_native_name)));
        
        return TRUE;
 }
@@ -304,10 +321,6 @@ construct_culture_from_specific_name (MonoCultureInfo *ci, gchar *name)
 
        entry = &culture_entries [ne->culture_entry_index];
 
-       /* try avoiding another lookup, often the culture is its own specific culture */
-       if (entry->lcid != entry->specific_lcid)
-               entry = culture_info_entry_from_lcid (entry->specific_lcid);
-
        if (entry)
                return construct_culture (ci, entry);
        else
@@ -318,10 +331,8 @@ static const CultureInfoEntry*
 culture_info_entry_from_lcid (int lcid)
 {
        const CultureInfoEntry *ci;
-       CultureInfoEntry key;
 
-       key.lcid = lcid;
-       ci = bsearch (&key, culture_entries, NUM_CULTURE_ENTRIES, sizeof (CultureInfoEntry), culture_lcid_locator);
+       ci = bsearch (&lcid, culture_entries, NUM_CULTURE_ENTRIES, sizeof (CultureInfoEntry), culture_lcid_locator);
 
        return ci;
 }
@@ -334,8 +345,7 @@ region_info_entry_from_lcid (int lcid)
 
        MONO_ARCH_SAVE_REGS;
 
-       ne = bsearch (&lcid, culture_entries, NUM_CULTURE_ENTRIES,
-                       sizeof (CultureInfoEntry), region_lcid_locator);
+       ne = bsearch (&lcid, culture_entries, NUM_CULTURE_ENTRIES, sizeof (CultureInfoEntry), culture_lcid_locator);
 
        if (ne == NULL)
                return FALSE;
@@ -613,7 +623,7 @@ ves_icall_System_Globalization_CultureInfo_internal_get_cultures (MonoBoolean ne
        len = 0;
        for (i = 0; i < NUM_CULTURE_ENTRIES; i++) {
                ci = &culture_entries [i];
-               is_neutral = ((ci->lcid & 0xff00) == 0 || ci->specific_lcid == 0);
+               is_neutral = ci->territory == 0;
                if ((neutral && is_neutral) || (specific && !is_neutral))
                        len++;
        }
@@ -637,7 +647,7 @@ ves_icall_System_Globalization_CultureInfo_internal_get_cultures (MonoBoolean ne
 
        for (i = 0; i < NUM_CULTURE_ENTRIES; i++) {
                ci = &culture_entries [i];
-               is_neutral = ((ci->lcid & 0xff00) == 0 || ci->specific_lcid == 0);
+               is_neutral = ci->territory == 0;
                if ((neutral && is_neutral) || (specific && !is_neutral)) {
                        culture = (MonoCultureInfo *) mono_object_new (domain, class);
                        mono_runtime_object_init ((MonoObject *) culture);
@@ -650,28 +660,6 @@ ves_icall_System_Globalization_CultureInfo_internal_get_cultures (MonoBoolean ne
        return ret;
 }
 
-/**
- * ves_icall_System_Globalization_CultureInfo_internal_is_lcid_neutral:
- * 
- * Set is_neutral and return TRUE if the culture is found. If it is not found return FALSE.
- */
-MonoBoolean
-ves_icall_System_Globalization_CultureInfo_internal_is_lcid_neutral (gint lcid, MonoBoolean *is_neutral)
-{
-       const CultureInfoEntry *entry;
-
-       MONO_ARCH_SAVE_REGS;
-
-       entry = culture_info_entry_from_lcid (lcid);
-
-       if (entry == NULL)
-               return FALSE;
-
-       *is_neutral = (entry->specific_lcid == 0);
-
-       return TRUE;
-}
-
 void ves_icall_System_Globalization_CompareInfo_construct_compareinfo (MonoCompareInfo *comp, MonoString *locale)
 {
        /* Nothing to do here */
index 10b7e70edd9c0df297bb81796d5cd1038d885f68..c0ec1067922ac326c50ac2873d59e667e774566d 100644 (file)
@@ -32,7 +32,6 @@ extern MonoBoolean ves_icall_System_Globalization_CultureInfo_construct_internal
 extern MonoBoolean ves_icall_System_Globalization_CultureInfo_construct_internal_locale_from_name (MonoCultureInfo *this, MonoString *name) MONO_INTERNAL;
 extern MonoBoolean ves_icall_System_Globalization_CultureInfo_construct_internal_locale_from_specific_name (MonoCultureInfo *ci, MonoString *name) MONO_INTERNAL;
 extern MonoArray *ves_icall_System_Globalization_CultureInfo_internal_get_cultures (MonoBoolean neutral, MonoBoolean specific, MonoBoolean installed) MONO_INTERNAL;
-extern MonoBoolean ves_icall_System_Globalization_CultureInfo_internal_is_lcid_neutral (gint lcid, MonoBoolean *is_neutral) MONO_INTERNAL;
 extern void ves_icall_System_Globalization_CultureInfo_construct_datetime_format (MonoCultureInfo *this) MONO_INTERNAL;
 extern void ves_icall_System_Globalization_CultureInfo_construct_number_format (MonoCultureInfo *this) MONO_INTERNAL;
 extern void ves_icall_System_Globalization_CompareInfo_construct_compareinfo (MonoCompareInfo *comp, MonoString *locale) MONO_INTERNAL;
index e4405061ba577a713e016817e9f99b7eb5c26312..f2499953aa3ba217482023ae7299fa2cd496cf60 100644 (file)
@@ -83,6 +83,8 @@ static MonoNativeTlsKey last_error_tls_id;
 
 static MonoNativeTlsKey load_type_info_tls_id;
 
+static gboolean use_aot_wrappers;
+
 static void
 delegate_hash_table_add (MonoDelegate *d);
 
@@ -417,6 +419,45 @@ delegate_hash_table_add (MonoDelegate *d)
        mono_marshal_unlock ();
 }
 
+/*
+ * mono_marshal_use_aot_wrappers:
+ *
+ *   Instructs this module to use AOT compatible wrappers.
+ */
+void
+mono_marshal_use_aot_wrappers (gboolean use)
+{
+       use_aot_wrappers = use;
+}
+
+static void
+parse_unmanaged_function_pointer_attr (MonoClass *klass, MonoMethodPInvoke *piinfo)
+{
+       static MonoClass *UnmanagedFunctionPointerAttribute;
+       MonoCustomAttrInfo *cinfo;
+       MonoReflectionUnmanagedFunctionPointerAttribute *attr;
+
+       if (!UnmanagedFunctionPointerAttribute)
+               UnmanagedFunctionPointerAttribute = mono_class_from_name (mono_defaults.corlib, "System.Runtime.InteropServices", "UnmanagedFunctionPointerAttribute");
+
+       /* The attribute is only available in Net 2.0 */
+       if (UnmanagedFunctionPointerAttribute) {
+               /* 
+                * The pinvoke attributes are stored in a real custom attribute so we have to
+                * construct it.
+                */
+               cinfo = mono_custom_attrs_from_class (klass);
+               if (cinfo) {
+                       attr = (MonoReflectionUnmanagedFunctionPointerAttribute*)mono_custom_attrs_get_attr (cinfo, UnmanagedFunctionPointerAttribute);
+                       if (attr) {
+                               piinfo->piflags = (attr->call_conv << 8) | (attr->charset ? (attr->charset - 1) * 2 : 1) | attr->set_last_error;
+                       }
+                       if (!cinfo->cached)
+                               mono_custom_attrs_free (cinfo);
+               }
+       }
+}
+
 MonoDelegate*
 mono_ftnptr_to_delegate (MonoClass *klass, gpointer ftn)
 {
@@ -445,53 +486,39 @@ mono_ftnptr_to_delegate (MonoClass *klass, gpointer ftn)
 #endif
        if (d == NULL) {
                /* This is a native function, so construct a delegate for it */
-               static MonoClass *UnmanagedFunctionPointerAttribute;
                MonoMethodSignature *sig;
                MonoMethod *wrapper;
                MonoMarshalSpec **mspecs;
-               MonoCustomAttrInfo *cinfo;
-               MonoReflectionUnmanagedFunctionPointerAttribute *attr;
                MonoMethod *invoke = mono_get_delegate_invoke (klass);
                MonoMethodPInvoke piinfo;
+               MonoObject *this;
                int i;
 
-               memset (&piinfo, 0, sizeof (piinfo));
-               if (!UnmanagedFunctionPointerAttribute)
-                       UnmanagedFunctionPointerAttribute = mono_class_from_name (mono_defaults.corlib, "System.Runtime.InteropServices", "UnmanagedFunctionPointerAttribute");
-
-               /* The attribute is only available in Net 2.0 */
-               if (UnmanagedFunctionPointerAttribute) {
-                       /* 
-                        * The pinvoke attributes are stored in a real custom attribute so we have to
-                        * construct it.
-                        */
-                       cinfo = mono_custom_attrs_from_class (klass);
-                       if (cinfo) {
-                               attr = (MonoReflectionUnmanagedFunctionPointerAttribute*)mono_custom_attrs_get_attr (cinfo, UnmanagedFunctionPointerAttribute);
-                               if (attr) {
-                                       piinfo.piflags = (attr->call_conv << 8) | (attr->charset ? (attr->charset - 1) * 2 : 1) | attr->set_last_error;
-                               }
-                               if (!cinfo->cached)
-                                       mono_custom_attrs_free (cinfo);
-                       }
-               }
+               if (use_aot_wrappers) {
+                       wrapper = mono_marshal_get_native_func_wrapper_aot (klass);
+                       this = mono_value_box (mono_domain_get (), mono_defaults.int_class, &ftn);
+               } else {
+                       memset (&piinfo, 0, sizeof (piinfo));
+                       parse_unmanaged_function_pointer_attr (klass, &piinfo);
 
-               mspecs = g_new0 (MonoMarshalSpec*, mono_method_signature (invoke)->param_count + 1);
-               mono_method_get_marshal_info (invoke, mspecs);
-               /* Freed below so don't alloc from mempool */
-               sig = mono_metadata_signature_dup (mono_method_signature (invoke));
-               sig->hasthis = 0;
+                       mspecs = g_new0 (MonoMarshalSpec*, mono_method_signature (invoke)->param_count + 1);
+                       mono_method_get_marshal_info (invoke, mspecs);
+                       /* Freed below so don't alloc from mempool */
+                       sig = mono_metadata_signature_dup (mono_method_signature (invoke));
+                       sig->hasthis = 0;
 
-               wrapper = mono_marshal_get_native_func_wrapper (klass->image, sig, &piinfo, mspecs, ftn);
+                       wrapper = mono_marshal_get_native_func_wrapper (klass->image, sig, &piinfo, mspecs, ftn);
+                       this = NULL;
 
-               for (i = mono_method_signature (invoke)->param_count; i >= 0; i--)
-                       if (mspecs [i])
-                               mono_metadata_free_marshal_spec (mspecs [i]);
-               g_free (mspecs);
-               g_free (sig);
+                       for (i = mono_method_signature (invoke)->param_count; i >= 0; i--)
+                               if (mspecs [i])
+                                       mono_metadata_free_marshal_spec (mspecs [i]);
+                       g_free (mspecs);
+                       g_free (sig);
+               }
 
                d = (MonoDelegate*)mono_object_new (mono_domain_get (), klass);
-               mono_delegate_ctor_with_method ((MonoObject*)d, NULL, mono_compile_method (wrapper), wrapper);
+               mono_delegate_ctor_with_method ((MonoObject*)d, this, mono_compile_method (wrapper), wrapper);
        }
 
        if (d->object.vtable->domain != mono_domain_get ())
@@ -2529,7 +2556,7 @@ mono_marshal_method_from_wrapper (MonoMethod *wrapper)
                return res;
        case MONO_WRAPPER_MANAGED_TO_NATIVE:
                info = mono_marshal_get_wrapper_info (wrapper);
-               if (info && info->subtype == WRAPPER_SUBTYPE_NONE)
+               if (info && (info->subtype == WRAPPER_SUBTYPE_NONE || info->subtype == WRAPPER_SUBTYPE_NATIVE_FUNC_AOT))
                        return info->d.managed_to_native.method;
                else
                        return NULL;
@@ -4096,12 +4123,12 @@ mono_marshal_get_delegate_invoke (MonoMethod *method, MonoDelegate *del)
  *  Make a copy of @sig, adding an explicit this argument.
  */
 static MonoMethodSignature*
-signature_dup_add_this (MonoMethodSignature *sig, MonoClass *klass)
+signature_dup_add_this (MonoImage *image, MonoMethodSignature *sig, MonoClass *klass)
 {
        MonoMethodSignature *res;
        int i;
 
-       res = mono_metadata_signature_alloc (klass->image, sig->param_count + 1);
+       res = mono_metadata_signature_alloc (image, sig->param_count + 1);
        memcpy (res, sig, MONO_SIZEOF_METHOD_SIGNATURE);
        res->param_count = sig->param_count + 1;
        res->hasthis = FALSE;
@@ -4595,7 +4622,7 @@ mono_marshal_get_runtime_invoke (MonoMethod *method, gboolean virtual)
                         * Valuetype methods receive a managed pointer as the this argument.
                         * Create a new signature to reflect this.
                         */
-                       callsig = signature_dup_add_this (mono_method_signature (method), method->klass);
+                       callsig = signature_dup_add_this (method->klass->image, mono_method_signature (method), method->klass);
                        /* Can't share this as it would be shared with static methods taking an IntPtr argument */
                        need_direct_wrapper = TRUE;
                } else {
@@ -5413,7 +5440,7 @@ mono_marshal_get_icall_wrapper (MonoMethodSignature *sig, const char *name, gcon
 
        /* Add an explicit this argument */
        if (sig->hasthis)
-               csig2 = signature_dup_add_this (sig, mono_defaults.object_class);
+               csig2 = signature_dup_add_this (mono_defaults.corlib, sig, mono_defaults.object_class);
        else
                csig2 = signature_dup (mono_defaults.corlib, sig);
 
@@ -6141,14 +6168,15 @@ emit_marshal_string (EmitMarshalContext *m, int argnum, MonoType *t,
                        mono_mb_emit_managed_call (mb, m, NULL);
                        mono_mb_emit_icall (mb, mono_string_new_len_wrapper);
                        mono_mb_emit_byte (mb, CEE_STIND_REF);
-               } else if (t->byref && (t->attrs & PARAM_ATTRIBUTE_OUT)) {
+               } else if (t->byref && (t->attrs & PARAM_ATTRIBUTE_OUT || !(t->attrs & PARAM_ATTRIBUTE_IN))) {
                        mono_mb_emit_ldarg (mb, argnum);
                        mono_mb_emit_ldloc (mb, conv_arg);
                        mono_mb_emit_icall (mb, conv_to_icall (conv));
                        mono_mb_emit_byte (mb, CEE_STIND_REF);
+                       need_free = TRUE;
                }
 
-               if (need_free || (t->byref && (t->attrs & PARAM_ATTRIBUTE_OUT))) {
+               if (need_free) {
                        mono_mb_emit_ldloc (mb, conv_arg);
                        if (conv == MONO_MARSHAL_CONV_BSTR_STR)
                                mono_mb_emit_icall (mb, mono_free_bstr);
@@ -6496,7 +6524,8 @@ emit_marshal_object (EmitMarshalContext *m, int argnum, MonoType *t,
                } else if (klass == mono_defaults.stringbuilder_class) {
                        MonoMarshalNative encoding = mono_marshal_get_string_encoding (m->piinfo, spec);
                        MonoMarshalConv conv = mono_marshal_get_stringbuilder_to_ptr_conv (m->piinfo, spec);
-                       
+
+#if 0                  
                        if (t->byref) {
                                if (!(t->attrs & PARAM_ATTRIBUTE_OUT)) {
                                        char *msg = g_strdup_printf ("Byref marshalling of stringbuilders is not implemented.");
@@ -6504,8 +6533,14 @@ emit_marshal_object (EmitMarshalContext *m, int argnum, MonoType *t,
                                }
                                break;
                        }
+#endif
+
+                       if (t->byref && !t->attrs & PARAM_ATTRIBUTE_IN && t->attrs & PARAM_ATTRIBUTE_OUT)
+                               break;
 
                        mono_mb_emit_ldarg (mb, argnum);
+                       if (t->byref)
+                               mono_mb_emit_byte (mb, CEE_LDIND_I);
 
                        if (conv != -1)
                                mono_mb_emit_icall (mb, conv_to_icall (conv));
@@ -6595,7 +6630,7 @@ emit_marshal_object (EmitMarshalContext *m, int argnum, MonoType *t,
                        g_assert (encoding != -1);
 
                        if (t->byref) {
-                               g_assert ((t->attrs & PARAM_ATTRIBUTE_OUT));
+                               //g_assert (!(t->attrs & PARAM_ATTRIBUTE_OUT));
 
                                need_free = TRUE;
 
@@ -8035,6 +8070,10 @@ emit_marshal (EmitMarshalContext *m, int argnum, MonoType *t,
        /* Ensure that we have marshalling info for this param */
        mono_marshal_load_type_info (mono_class_from_mono_type (t));
 
+#ifdef DISABLE_JIT
+       /* Not JIT support, no need to generate correct IL */
+       return conv_arg;
+#else
        if (spec && spec->native == MONO_NATIVE_CUSTOM)
                return emit_marshal_custom (m, argnum, t, spec, conv_arg, conv_arg_type, action);
 
@@ -8099,6 +8138,7 @@ emit_marshal (EmitMarshalContext *m, int argnum, MonoType *t,
                else
                        return emit_marshal_object (m, argnum, t, spec, conv_arg, conv_arg_type, action);
        }
+#endif
 
        return conv_arg;
 }
@@ -8112,28 +8152,37 @@ emit_marshal (EmitMarshalContext *m, int argnum, MonoType *t,
  * @aot: whenever the created method will be compiled by the AOT compiler
  * @method: if non-NULL, the pinvoke method to call
  * @check_exceptions: Whenever to check for pending exceptions after the native call
+ * @func_param: the function to call is passed as a boxed IntPtr as the first parameter
  *
  * generates IL code for the pinvoke wrapper, the generated code calls @func.
  */
 void
-mono_marshal_emit_native_wrapper (MonoImage *image, MonoMethodBuilder *mb, MonoMethodSignature *sig, MonoMethodPInvoke *piinfo, MonoMarshalSpec **mspecs, gpointer func, gboolean aot, gboolean check_exceptions)
+mono_marshal_emit_native_wrapper (MonoImage *image, MonoMethodBuilder *mb, MonoMethodSignature *sig, MonoMethodPInvoke *piinfo, MonoMarshalSpec **mspecs, gpointer func, gboolean aot, gboolean check_exceptions, gboolean func_param)
 {
        EmitMarshalContext m;
        MonoMethodSignature *csig;
        MonoClass *klass;
        int i, argnum, *tmp_locals;
-       int type;
+       int type, param_shift = 0;
        static MonoMethodSignature *get_last_error_sig = NULL;
 
        m.mb = mb;
        m.piinfo = piinfo;
 
        /* we copy the signature, so that we can set pinvoke to 0 */
+       if (func_param) {
+               /* The function address is passed as the first argument */
+               g_assert (!sig->hasthis);
+               param_shift += 1;
+       }
        csig = signature_dup (mb->method->klass->image, sig);
        csig->pinvoke = 1;
        m.csig = csig;
        m.image = image;
 
+       if (sig->hasthis)
+               param_shift += 1;
+
        /* we allocate local for use with emit_struct_conv() */
        /* allocate local 0 (pointer) src_ptr */
        mono_mb_add_local (mb, &mono_defaults.int_class->byval_arg);
@@ -8166,7 +8215,7 @@ mono_marshal_emit_native_wrapper (MonoImage *image, MonoMethodBuilder *mb, MonoM
        m.orig_conv_args = alloca (sizeof (int) * (sig->param_count + 1));
 
        for (i = 0; i < sig->param_count; i ++) {
-               tmp_locals [i] = emit_marshal (&m, i + sig->hasthis, sig->params [i], mspecs [i + 1], 0, &csig->params [i], MARSHAL_ACTION_CONV_IN);
+               tmp_locals [i] = emit_marshal (&m, i + param_shift, sig->params [i], mspecs [i + 1], 0, &csig->params [i], MARSHAL_ACTION_CONV_IN);
        }
 
        /* push all arguments */
@@ -8175,11 +8224,16 @@ mono_marshal_emit_native_wrapper (MonoImage *image, MonoMethodBuilder *mb, MonoM
                mono_mb_emit_byte (mb, CEE_LDARG_0);
 
        for (i = 0; i < sig->param_count; i++) {
-               emit_marshal (&m, i + sig->hasthis, sig->params [i], mspecs [i + 1], tmp_locals [i], NULL, MARSHAL_ACTION_PUSH);
+               emit_marshal (&m, i + param_shift, sig->params [i], mspecs [i + 1], tmp_locals [i], NULL, MARSHAL_ACTION_PUSH);
        }                       
 
        /* call the native method */
-       if (MONO_CLASS_IS_IMPORT (mb->method->klass)) {
+       if (func_param) {
+               mono_mb_emit_byte (mb, CEE_LDARG_0);
+               mono_mb_emit_op (mb, CEE_UNBOX, mono_defaults.int_class);
+               mono_mb_emit_byte (mb, CEE_LDIND_I);
+               mono_mb_emit_calli (mb, csig);
+       } else if (MONO_CLASS_IS_IMPORT (mb->method->klass)) {
 #ifndef DISABLE_COM
                mono_mb_emit_cominterop_call (mb, csig, &piinfo->method);
 #else
@@ -8284,7 +8338,7 @@ mono_marshal_emit_native_wrapper (MonoImage *image, MonoMethodBuilder *mb, MonoM
                MonoType *t = sig->params [i];
                MonoMarshalSpec *spec = mspecs [i + 1];
 
-               argnum = i + sig->hasthis;
+               argnum = i + param_shift;
 
                if (spec && ((spec->native == MONO_NATIVE_CUSTOM) || (spec->native == MONO_NATIVE_ASANY))) {
                        emit_marshal (&m, argnum, t, spec, tmp_locals [i], NULL, MARSHAL_ACTION_CONV_OUT);
@@ -8444,7 +8498,7 @@ mono_marshal_get_native_wrapper (MonoMethod *method, gboolean check_exceptions,
        /* internal calls: we simply push all arguments and call the method (no conversions) */
        if (method->iflags & (METHOD_IMPL_ATTRIBUTE_INTERNAL_CALL | METHOD_IMPL_ATTRIBUTE_RUNTIME)) {
                if (sig->hasthis)
-                       csig = signature_dup_add_this (sig, method->klass);
+                       csig = signature_dup_add_this (method->klass->image, sig, method->klass);
                else
                        csig = signature_dup (method->klass->image, sig);
 
@@ -8502,7 +8556,7 @@ mono_marshal_get_native_wrapper (MonoMethod *method, gboolean check_exceptions,
        mspecs = g_new (MonoMarshalSpec*, sig->param_count + 1);
        mono_method_get_marshal_info (method, mspecs);
 
-       mono_marshal_emit_native_wrapper (mb->method->klass->image, mb, sig, piinfo, mspecs, piinfo->addr, aot, check_exceptions);
+       mono_marshal_emit_native_wrapper (mb->method->klass->image, mb, sig, piinfo, mspecs, piinfo->addr, aot, check_exceptions, FALSE);
 
        csig = signature_dup (method->klass->image, sig);
        csig->pinvoke = 0;
@@ -8552,7 +8606,7 @@ mono_marshal_get_native_func_wrapper (MonoImage *image, MonoMethodSignature *sig
        mb = mono_mb_new (mono_defaults.object_class, name, MONO_WRAPPER_MANAGED_TO_NATIVE);
        mb->method->save_lmf = 1;
 
-       mono_marshal_emit_native_wrapper (image, mb, sig, piinfo, mspecs, func, FALSE, TRUE);
+       mono_marshal_emit_native_wrapper (image, mb, sig, piinfo, mspecs, func, FALSE, TRUE, FALSE);
 
        csig = signature_dup (image, sig);
        csig->pinvoke = 0;
@@ -8562,7 +8616,70 @@ mono_marshal_get_native_func_wrapper (MonoImage *image, MonoMethodSignature *sig
 
        mono_marshal_set_wrapper_info (res, NULL);
 
-       /* code_for (res); */
+       return res;
+}
+
+/*
+ * The wrapper receives the native function as a boxed IntPtr as its 'this' argument. This is easier to support in
+ * AOT.
+ */
+MonoMethod*
+mono_marshal_get_native_func_wrapper_aot (MonoClass *klass)
+{
+       MonoMethodSignature *sig, *csig;
+       MonoMethodBuilder *mb;
+       MonoMethod *res;
+       GHashTable *cache;
+       char *name;
+       WrapperInfo *info;
+       MonoMethodPInvoke mpiinfo;
+       MonoMethodPInvoke *piinfo = &mpiinfo;
+       MonoMarshalSpec **mspecs;
+       MonoMethod *invoke = mono_get_delegate_invoke (klass);
+       MonoImage *image = invoke->klass->image;
+       int i;
+
+       // FIXME: include UnmanagedFunctionPointerAttribute info
+
+       /*
+        * The wrapper is associated with the delegate type, to pick up the marshalling info etc.
+        */
+       cache = get_cache (&image->native_func_wrapper_aot_cache, mono_aligned_addr_hash, NULL);
+       if ((res = mono_marshal_find_in_cache (cache, invoke)))
+               return res;
+
+       memset (&mpiinfo, 0, sizeof (mpiinfo));
+       parse_unmanaged_function_pointer_attr (klass, &mpiinfo);
+
+       mspecs = g_new0 (MonoMarshalSpec*, mono_method_signature (invoke)->param_count + 1);
+       mono_method_get_marshal_info (invoke, mspecs);
+       /* Freed below so don't alloc from mempool */
+       sig = mono_metadata_signature_dup (mono_method_signature (invoke));
+       sig->hasthis = 0;
+
+       name = g_strdup_printf ("wrapper_aot_native");
+       mb = mono_mb_new (invoke->klass, name, MONO_WRAPPER_MANAGED_TO_NATIVE);
+       mb->method->save_lmf = 1;
+
+       mono_marshal_emit_native_wrapper (image, mb, sig, piinfo, mspecs, NULL, FALSE, TRUE, TRUE);
+
+       g_assert (!sig->hasthis);
+       csig = signature_dup_add_this (image, sig, mono_defaults.int_class);
+       csig->pinvoke = 0;
+       res = mono_mb_create_and_cache (cache, invoke,
+                                                                       mb, csig, csig->param_count + 16);
+       mono_mb_free (mb);
+
+       info = mono_wrapper_info_create (res, WRAPPER_SUBTYPE_NATIVE_FUNC_AOT);
+       info->d.managed_to_native.method = invoke;
+
+       mono_marshal_set_wrapper_info (res, info);
+
+       for (i = mono_method_signature (invoke)->param_count; i >= 0; i--)
+               if (mspecs [i])
+                       mono_metadata_free_marshal_spec (mspecs [i]);
+       g_free (mspecs);
+       g_free (sig);
 
        return res;
 }
@@ -12216,6 +12333,8 @@ mono_marshal_free_inflated_wrappers (MonoMethod *method)
                g_hash_table_remove (method->klass->image->cominterop_wrapper_cache, method);
        if (method->klass->image->thunk_invoke_cache)
                g_hash_table_remove (method->klass->image->thunk_invoke_cache, method);
+       if (method->klass->image->native_func_wrapper_aot_cache)
+               g_hash_table_remove (method->klass->image->native_func_wrapper_aot_cache, method);
 
        mono_marshal_unlock ();
 }
index 4514c9eed4befdb7635615e0140859ff1b39e2c1..9db6cf0e2fd0d6b5b5fba65bb2b7b9ced5c4e009 100644 (file)
@@ -102,6 +102,7 @@ typedef enum {
        WRAPPER_SUBTYPE_RUNTIME_INVOKE_VIRTUAL,
        /* Subtypes of MONO_WRAPPER_MANAGED_TO_NATIVE */
        WRAPPER_SUBTYPE_ICALL_WRAPPER,
+       WRAPPER_SUBTYPE_NATIVE_FUNC_AOT,
        /* Subtypes of MONO_WRAPPER_UNKNOWN */
        WRAPPER_SUBTYPE_SYNCHRONIZED_INNER
 } WrapperSubtype;
@@ -300,6 +301,9 @@ mono_marshal_get_native_wrapper (MonoMethod *method, gboolean check_exceptions,
 MonoMethod *
 mono_marshal_get_native_func_wrapper (MonoImage *image, MonoMethodSignature *sig, MonoMethodPInvoke *piinfo, MonoMarshalSpec **mspecs, gpointer func) MONO_INTERNAL;
 
+MonoMethod*
+mono_marshal_get_native_func_wrapper_aot (MonoClass *klass) MONO_INTERNAL;
+
 MonoMethod *
 mono_marshal_get_struct_to_ptr (MonoClass *klass) MONO_INTERNAL;
 
@@ -563,7 +567,7 @@ mono_signature_no_pinvoke (MonoMethod *method) MONO_INTERNAL;
 /* Called from cominterop.c */
 
 void
-mono_marshal_emit_native_wrapper (MonoImage *image, MonoMethodBuilder *mb, MonoMethodSignature *sig, MonoMethodPInvoke *piinfo, MonoMarshalSpec **mspecs, gpointer func, gboolean aot, gboolean check_exceptions) MONO_INTERNAL;
+mono_marshal_emit_native_wrapper (MonoImage *image, MonoMethodBuilder *mb, MonoMethodSignature *sig, MonoMethodPInvoke *piinfo, MonoMarshalSpec **mspecs, gpointer func, gboolean aot, gboolean check_exceptions, gboolean func_param) MONO_INTERNAL;
 
 void
 mono_marshal_emit_managed_wrapper (MonoMethodBuilder *mb, MonoMethodSignature *invoke_sig, MonoMarshalSpec **mspecs, EmitMarshalContext* m, MonoMethod *method, uint32_t target_handle) MONO_INTERNAL;
@@ -581,6 +585,9 @@ mono_mb_create_and_cache (GHashTable *cache, gpointer key,
 void
 mono_marshal_emit_thread_interrupt_checkpoint (MonoMethodBuilder *mb) MONO_INTERNAL;
 
+void
+mono_marshal_use_aot_wrappers (gboolean use) MONO_INTERNAL;
+
 G_END_DECLS
 
 #endif /* __MONO_MARSHAL_H__ */
index 93a439899271d6619cb1ddb6c974a0b4f418c28b..eaf72145385efa357d823581e1b279807d30f756 100644 (file)
@@ -273,6 +273,7 @@ struct _MonoImage {
        GHashTable *managed_wrapper_cache;
        GHashTable *native_wrapper_cache;
        GHashTable *native_wrapper_aot_cache;
+       GHashTable *native_func_wrapper_aot_cache;
        GHashTable *remoting_invoke_cache;
        GHashTable *synchronized_cache;
        GHashTable *unbox_wrapper_cache;
index c77c244fa0e89b7e0e02feb0dd61c7eba09b1d41..5a12af08f87d5383589eb67868e3c2c0f1a1a782 100644 (file)
@@ -4241,10 +4241,7 @@ mono_backtrace (int limit)
 }
 #endif
 
-#ifndef __GNUC__
-/*#define __alignof__(a) sizeof(a)*/
-#define __alignof__(type) G_STRUCT_OFFSET(struct { char c; type x; }, x)
-#endif
+#define abi__alignof__(type) G_STRUCT_OFFSET(struct { char c; type x; }, x)
 
 /*
  * mono_type_size:
@@ -4261,7 +4258,7 @@ mono_type_size (MonoType *t, int *align)
                return 0;
        }
        if (t->byref) {
-               *align = __alignof__(gpointer);
+               *align = abi__alignof__(gpointer);
                return sizeof (gpointer);
        }
 
@@ -4270,23 +4267,23 @@ mono_type_size (MonoType *t, int *align)
                *align = 1;
                return 0;
        case MONO_TYPE_BOOLEAN:
-               *align = __alignof__(gint8);
+               *align = abi__alignof__(gint8);
                return 1;
        case MONO_TYPE_I1:
        case MONO_TYPE_U1:
-               *align = __alignof__(gint8);
+               *align = abi__alignof__(gint8);
                return 1;
        case MONO_TYPE_CHAR:
        case MONO_TYPE_I2:
        case MONO_TYPE_U2:
-               *align = __alignof__(gint16);
+               *align = abi__alignof__(gint16);
                return 2;               
        case MONO_TYPE_I4:
        case MONO_TYPE_U4:
-               *align = __alignof__(gint32);
+               *align = abi__alignof__(gint32);
                return 4;
        case MONO_TYPE_R4:
-               *align = __alignof__(float);
+               *align = abi__alignof__(float);
                return 4;
        case MONO_TYPE_I8:
        case MONO_TYPE_U8:
@@ -4294,21 +4291,21 @@ mono_type_size (MonoType *t, int *align)
                /* xcode 4.3 llvm-gcc bug */
                *align = 4;
 #else          
-               *align = __alignof__(gint64);
+               *align = abi__alignof__(gint64);
 #endif
                return 8;               
        case MONO_TYPE_R8:
-               *align = __alignof__(double);
+               *align = abi__alignof__(double);
                return 8;               
        case MONO_TYPE_I:
        case MONO_TYPE_U:
-               *align = __alignof__(gpointer);
+               *align = abi__alignof__(gpointer);
                return sizeof (gpointer);
        case MONO_TYPE_STRING:
-               *align = __alignof__(gpointer);
+               *align = abi__alignof__(gpointer);
                return sizeof (gpointer);
        case MONO_TYPE_OBJECT:
-               *align = __alignof__(gpointer);
+               *align = abi__alignof__(gpointer);
                return sizeof (gpointer);
        case MONO_TYPE_VALUETYPE: {
                if (t->data.klass->enumtype)
@@ -4321,7 +4318,7 @@ mono_type_size (MonoType *t, int *align)
        case MONO_TYPE_PTR:
        case MONO_TYPE_FNPTR:
        case MONO_TYPE_ARRAY:
-               *align = __alignof__(gpointer);
+               *align = abi__alignof__(gpointer);
                return sizeof (gpointer);
        case MONO_TYPE_TYPEDBYREF:
                return mono_class_value_size (mono_defaults.typed_reference_class, (guint32*)align);
@@ -4337,14 +4334,14 @@ mono_type_size (MonoType *t, int *align)
                        else
                                return mono_class_value_size (mono_class_from_mono_type (t), (guint32*)align);
                } else {
-                       *align = __alignof__(gpointer);
+                       *align = abi__alignof__(gpointer);
                        return sizeof (gpointer);
                }
        }
        case MONO_TYPE_VAR:
        case MONO_TYPE_MVAR:
                /* FIXME: Martin, this is wrong. */
-               *align = __alignof__(gpointer);
+               *align = abi__alignof__(gpointer);
                return sizeof (gpointer);
        default:
                g_error ("mono_type_size: type 0x%02x unknown", t->type);
@@ -4371,7 +4368,7 @@ mono_type_stack_size_internal (MonoType *t, int *align, gboolean allow_open)
        int tmp;
 #if SIZEOF_VOID_P == SIZEOF_REGISTER
        int stack_slot_size = sizeof (gpointer);
-       int stack_slot_align = __alignof__ (gpointer);
+       int stack_slot_align = abi__alignof__ (gpointer);
 #elif SIZEOF_VOID_P < SIZEOF_REGISTER
        int stack_slot_size = SIZEOF_REGISTER;
        int stack_slot_align = SIZEOF_REGISTER;
@@ -4416,14 +4413,14 @@ mono_type_stack_size_internal (MonoType *t, int *align, gboolean allow_open)
                *align = stack_slot_align;
                return stack_slot_size * 3;
        case MONO_TYPE_R4:
-               *align = __alignof__(float);
+               *align = abi__alignof__(float);
                return sizeof (float);          
        case MONO_TYPE_I8:
        case MONO_TYPE_U8:
-               *align = __alignof__(gint64);
+               *align = abi__alignof__(gint64);
                return sizeof (gint64);         
        case MONO_TYPE_R8:
-               *align = __alignof__(double);
+               *align = abi__alignof__(double);
                return sizeof (double);
        case MONO_TYPE_VALUETYPE: {
                guint32 size;
index 6209e1e33625126b1a04acc546f3ba748556e53d..26856e0c41c8f325f4894bab5199c6f3359bfbc7 100644 (file)
@@ -432,4 +432,9 @@ mono_gc_get_vtable_bits (MonoClass *class)
        return 0;
 }
 
+void
+mono_gc_register_altstack (gpointer stack, gint32 stack_size, gpointer altstack, gint32 altstack_size)
+{
+}
+
 #endif
index a817b78c5b7e515e1a15872b708f5d90617229c9..689dabe9f028dadddddc3a6450739f5dc353c10f 100644 (file)
@@ -367,6 +367,7 @@ typedef struct {
 
 typedef enum {
        MONO_THREAD_FLAG_DONT_MANAGE = 1, // Don't wait for or abort this thread
+       MONO_THREAD_FLAG_NAME_SET = 2, // Thread name set from managed code
 } MonoThreadFlags;
 
 struct _MonoInternalThread {
@@ -441,24 +442,21 @@ typedef struct {
        MonoString *LongTimePattern;
        MonoString *MonthDayPattern;
        MonoString *YearMonthPattern;
-       MonoString *FullDateTimePattern;
-       MonoString *RFC1123Pattern;
-       MonoString *SortableDateTimePattern;
-       MonoString *UniversalSortableDateTimePattern;
        guint32 FirstDayOfWeek;
-       MonoObject *Calendar;
        guint32 CalendarWeekRule;
        MonoArray *AbbreviatedDayNames;
        MonoArray *DayNames;
        MonoArray *MonthNames;
+       MonoArray *GenitiveMonthNames;
        MonoArray *AbbreviatedMonthNames;
+       MonoArray *GenitiveAbbreviatedMonthNames;
        MonoArray *ShortDatePatterns;
        MonoArray *LongDatePatterns;
        MonoArray *ShortTimePatterns;
        MonoArray *LongTimePatterns;
        MonoArray *MonthDayPatterns;
        MonoArray *YearMonthPatterns;
-       MonoArray *shortDayNames;
+       MonoArray *ShortestDayNames;
 } MonoDateTimeFormatInfo;
 
 typedef struct 
@@ -509,37 +507,37 @@ typedef struct {
        MonoBoolean is_read_only;
        gint32 lcid;
        gint32 parent_lcid;
-       gint32 specific_lcid;
        gint32 datetime_index;
        gint32 number_index;
+       gint32 calendar_type;
        MonoBoolean use_user_override;
        MonoNumberFormatInfo *number_format;
        MonoDateTimeFormatInfo *datetime_format;
        MonoObject *textinfo;
        MonoString *name;
-       MonoString *displayname;
        MonoString *englishname;
        MonoString *nativename;
        MonoString *iso3lang;
        MonoString *iso2lang;
-       MonoString *icu_name;
        MonoString *win3lang;
        MonoString *territory;
+       MonoArray *native_calendar_names;
        MonoCompareInfo *compareinfo;
-       const gint32 *calendar_data;
        const void* text_info_data;
 } MonoCultureInfo;
 
 typedef struct {
        MonoObject obj;
-       gint32 region_id;
+       gint32 geo_id;
        MonoString *iso2name;
        MonoString *iso3name;
        MonoString *win3name;
        MonoString *english_name;
+       MonoString *native_name;
        MonoString *currency_symbol;
        MonoString *iso_currency_symbol;
        MonoString *currency_english_name;
+       MonoString *currency_native_name;
 } MonoRegionInfo;
 
 typedef struct {
index 7d562d98e23b48c2b1f3e80ddd4cb5f2b1f7930d..37aba6620aa308a293565cc4ad16b5a74b36157d 100644 (file)
@@ -100,7 +100,8 @@ mono_runtime_object_init (MonoObject *this)
        MonoClass *klass = this->vtable->klass;
 
        method = mono_class_get_method_from_name (klass, ".ctor", 0);
-       g_assert (method);
+       if (!method)
+               g_error ("Could not lookup zero argument constructor for class %s", mono_type_get_full_name (klass));
 
        if (method->klass->valuetype)
                this = mono_object_unbox (this);
@@ -223,8 +224,9 @@ get_type_init_exception_for_vtable (MonoVTable *vtable)
        MonoException *ex;
        gchar *full_name;
 
-       g_assert (vtable->init_failed);
-
+       if (!vtable->init_failed)
+               g_error ("Trying to get the init exception for a non-failed vtable of class %s", mono_type_get_full_name (klass));
+       
        /* 
         * If the initializing thread was rudely aborted, the exception is not stored
         * in the hash.
@@ -1083,9 +1085,8 @@ mono_method_get_imt_slot (MonoMethod *method)
        hashes = hashes_start;
 
        if (! MONO_CLASS_IS_INTERFACE (method->klass)) {
-               printf ("mono_method_get_imt_slot: %s.%s.%s is not an interface MonoMethod\n",
+               g_error ("mono_method_get_imt_slot: %s.%s.%s is not an interface MonoMethod",
                                method->klass->name_space, method->klass->name, method->name);
-               g_assert_not_reached ();
        }
        
        /* Initialize hashes */
@@ -2060,6 +2061,54 @@ mono_class_create_runtime_vtable (MonoDomain *domain, MonoClass *class, gboolean
                }
        }
 
+       /* Initialize vtable */
+       if (callbacks.get_vtable_trampoline) {
+               // This also covers the AOT case
+               for (i = 0; i < class->vtable_size; ++i) {
+                       vt->vtable [i] = callbacks.get_vtable_trampoline (i);
+               }
+       } else {
+               mono_class_setup_vtable (class);
+
+               for (i = 0; i < class->vtable_size; ++i) {
+                       MonoMethod *cm;
+
+                       if ((cm = class->vtable [i]))
+                               vt->vtable [i] = arch_create_jit_trampoline (cm);
+               }
+       }
+
+       if (ARCH_USE_IMT && imt_table_bytes) {
+               /* Now that the vtable is full, we can actually fill up the IMT */
+               if (callbacks.get_imt_trampoline) {
+                       /* lazy construction of the IMT entries enabled */
+                       for (i = 0; i < MONO_IMT_SIZE; ++i)
+                               interface_offsets [i] = callbacks.get_imt_trampoline (i);
+               } else {
+                       build_imt (class, vt, domain, interface_offsets, NULL);
+               }
+       }
+
+       /*
+        * FIXME: Is it ok to allocate while holding the domain/loader locks ? If not, we can release them, allocate, then
+        * re-acquire them and check if another thread has created the vtable in the meantime.
+        */
+       /* Special case System.MonoType to avoid infinite recursion */
+       if (class != mono_defaults.monotype_class) {
+               /*FIXME check for OOM*/
+               vt->type = mono_type_get_object (domain, &class->byval_arg);
+               if (mono_object_get_class (vt->type) != mono_defaults.monotype_class)
+                       /* This is unregistered in
+                          unregister_vtable_reflection_type() in
+                          domain.c. */
+                       MONO_GC_REGISTER_ROOT_IF_MOVING(vt->type);
+       }
+
+       if (class->contextbound)
+               vt->remote = 1;
+       else
+               vt->remote = 0;
+
        /*  class_vtable_array keeps an array of created vtables
         */
        g_ptr_array_add (domain->class_vtable_array, vt);
@@ -2067,10 +2116,15 @@ mono_class_create_runtime_vtable (MonoDomain *domain, MonoClass *class, gboolean
         * it it enlarged and when it is stored info.
         */
 
+       /*
+        * Store the vtable in class->runtime_info.
+        * class->runtime_info is accessed without locking, so this do this last after the vtable has been constructed.
+        */
+       mono_memory_barrier ();
+
        old_info = class->runtime_info;
        if (old_info && old_info->max_domain >= domain->domain_id) {
                /* someone already created a large enough runtime info */
-               mono_memory_barrier ();
                old_info->domain_vtables [domain->domain_id] = vt;
        } else {
                int new_size = domain->domain_id;
@@ -2097,32 +2151,14 @@ mono_class_create_runtime_vtable (MonoDomain *domain, MonoClass *class, gboolean
                class->runtime_info = runtime_info;
        }
 
-       /* Initialize vtable */
-       if (callbacks.get_vtable_trampoline) {
-               // This also covers the AOT case
-               for (i = 0; i < class->vtable_size; ++i) {
-                       vt->vtable [i] = callbacks.get_vtable_trampoline (i);
-               }
-       } else {
-               mono_class_setup_vtable (class);
-
-               for (i = 0; i < class->vtable_size; ++i) {
-                       MonoMethod *cm;
-
-                       if ((cm = class->vtable [i]))
-                               vt->vtable [i] = arch_create_jit_trampoline (cm);
-               }
-       }
-
-       if (ARCH_USE_IMT && imt_table_bytes) {
-               /* Now that the vtable is full, we can actually fill up the IMT */
-               if (callbacks.get_imt_trampoline) {
-                       /* lazy construction of the IMT entries enabled */
-                       for (i = 0; i < MONO_IMT_SIZE; ++i)
-                               interface_offsets [i] = callbacks.get_imt_trampoline (i);
-               } else {
-                       build_imt (class, vt, domain, interface_offsets, NULL);
-               }
+       if (class == mono_defaults.monotype_class) {
+               /*FIXME check for OOM*/
+               vt->type = mono_type_get_object (domain, &class->byval_arg);
+               if (mono_object_get_class (vt->type) != mono_defaults.monotype_class)
+                       /* This is unregistered in
+                          unregister_vtable_reflection_type() in
+                          domain.c. */
+                       MONO_GC_REGISTER_ROOT_IF_MOVING(vt->type);
        }
 
        mono_domain_unlock (domain);
@@ -2137,18 +2173,6 @@ mono_class_create_runtime_vtable (MonoDomain *domain, MonoClass *class, gboolean
        if (class->parent)
                mono_class_vtable_full (domain, class->parent, raise_on_error);
 
-       /*FIXME check for OOM*/
-       vt->type = mono_type_get_object (domain, &class->byval_arg);
-       if (mono_object_get_class (vt->type) != mono_defaults.monotype_class)
-               /* This is unregistered in
-                  unregister_vtable_reflection_type() in
-                  domain.c. */
-               MONO_GC_REGISTER_ROOT_IF_MOVING(vt->type);
-       if (class->contextbound)
-               vt->remote = 1;
-       else
-               vt->remote = 0;
-
        return vt;
 }
 
@@ -2936,8 +2960,7 @@ handle_enum:
                t = type->data.generic_class->container_class->byval_arg.type;
                goto handle_enum;
        default:
-               g_warning ("got type %x", type->type);
-               g_assert_not_reached ();
+               g_error ("got type %x", type->type);
        }
 }
 
@@ -3372,6 +3395,9 @@ void
 mono_nullable_init (guint8 *buf, MonoObject *value, MonoClass *klass)
 {
        MonoClass *param_class = klass->cast_class;
+
+       mono_class_setup_fields_locking (klass);
+       g_assert (klass->fields_inited);
                                
        g_assert (mono_class_from_mono_type (klass->fields [0].type) == param_class);
        g_assert (mono_class_from_mono_type (klass->fields [1].type) == mono_defaults.boolean_class);
@@ -3400,6 +3426,9 @@ mono_nullable_box (guint8 *buf, MonoClass *klass)
 {
        MonoClass *param_class = klass->cast_class;
 
+       mono_class_setup_fields_locking (klass);
+       g_assert (klass->fields_inited);
+
        g_assert (mono_class_from_mono_type (klass->fields [0].type) == param_class);
        g_assert (mono_class_from_mono_type (klass->fields [1].type) == mono_defaults.boolean_class);
 
@@ -3451,9 +3480,11 @@ MonoObject*
 mono_runtime_delegate_invoke (MonoObject *delegate, void **params, MonoObject **exc)
 {
        MonoMethod *im;
+       MonoClass *klass = delegate->vtable->klass;
 
-       im = mono_get_delegate_invoke (delegate->vtable->klass);
-       g_assert (im);
+       im = mono_get_delegate_invoke (klass);
+       if (!im)
+               g_error ("Could not lookup delegate invoke method for delegate %s", mono_type_get_full_name (klass));
 
        return mono_runtime_invoke (im, delegate, params, exc);
 }
@@ -5672,26 +5703,13 @@ mono_raise_exception (MonoException *ex)
         * that will cause gcc to omit the function epilog, causing problems when
         * the JIT tries to walk the stack, since the return address on the stack
         * will point into the next function in the executable, not this one.
-        */
-
-       if (((MonoObject*)ex)->vtable->klass == mono_defaults.threadabortexception_class) {
-               MonoInternalThread *thread = mono_thread_internal_current ();
-               g_assert (ex->object.vtable->domain == mono_domain_get ());
-               MONO_OBJECT_SETREF (thread, abort_exc, ex);
-       }
-       
+        */     
        eh_callbacks.mono_raise_exception (ex);
 }
 
 void
 mono_raise_exception_with_context (MonoException *ex, MonoContext *ctx) 
 {
-       if (((MonoObject*)ex)->vtable->klass == mono_defaults.threadabortexception_class) {
-               MonoInternalThread *thread = mono_thread_internal_current ();
-               g_assert (ex->object.vtable->domain == mono_domain_get ());
-               MONO_OBJECT_SETREF (thread, abort_exc, ex);
-       }
-       
        eh_callbacks.mono_raise_exception_with_ctx (ex, ctx);
 }
 
index 83cb6716ef9dc26007443eaa3b2254cb340e5814..0820433da78723817944eb2e77ca1f13fffc7b4b 100644 (file)
@@ -747,7 +747,7 @@ MonoBoolean ves_icall_System_Diagnostics_Process_CreateProcess_internal (MonoPro
        /* The default dir name is "".  Turn that into NULL to mean
         * "current directory"
         */
-       if(mono_string_length (proc_start_info->working_directory)==0) {
+       if(proc_start_info->working_directory == NULL || mono_string_length (proc_start_info->working_directory)==0) {
                dir=NULL;
        } else {
                dir=mono_string_chars (proc_start_info->working_directory);
index 664d6f90b55ed11c6900823e2ecd97f467f1802c..373e0f5ead8d5af28c4aea8b1d044ef833d13769 100644 (file)
@@ -10927,7 +10927,11 @@ typebuilder_setup_fields (MonoClass *klass, MonoError *error)
        mono_error_init (error);
 
        if (tb->class_size) {
-               g_assert ((tb->packing_size & 0xfffffff0) == 0);
+               if ((tb->packing_size & 0xfffffff0) != 0) {
+                       char *err_msg = g_strdup_printf ("Could not load struct '%s' with packing size %d >= 16", klass->name, tb->packing_size);
+                       mono_class_set_failure (klass, MONO_EXCEPTION_TYPE_LOAD, err_msg);
+                       return;
+               }
                klass->packing_size = tb->packing_size;
                real_size = klass->instance_size + tb->class_size;
        }
index 200c6eaec90303188622694455cbb4a0bb661c28..58ab47dab2976312a856bc1d0110077d71353577 100644 (file)
@@ -128,7 +128,7 @@ alloc_degraded (MonoVTable *vtable, size_t size, gboolean for_mature)
                InterlockedExchangeAdd (&degraded_mode, size);
        }
 
-       if (mono_sgen_need_major_collection (0)) {
+       if (sgen_need_major_collection (0)) {
                sgen_collect_major_no_lock ("degraded overflow");
        }
 
@@ -166,8 +166,8 @@ mono_gc_alloc_obj_nolock (MonoVTable *vtable, size_t size)
 
                InterlockedIncrement (&alloc_count);
                if (((alloc_count % collect_before_allocs) == 0) && nursery_section) {
-                       mono_sgen_collect_nursery_no_lock (0);
-                       if (!degraded_mode && !mono_sgen_can_alloc_size (size) && size <= SGEN_MAX_SMALL_OBJ_SIZE) {
+                       sgen_collect_nursery_no_lock (0);
+                       if (!degraded_mode && !sgen_can_alloc_size (size) && size <= SGEN_MAX_SMALL_OBJ_SIZE) {
                                // FIXME:
                                g_assert_not_reached ();
                        }
@@ -186,7 +186,7 @@ mono_gc_alloc_obj_nolock (MonoVTable *vtable, size_t size)
         */
 
        if (size > SGEN_MAX_SMALL_OBJ_SIZE) {
-               p = mono_sgen_los_alloc_large_inner (vtable, size);
+               p = sgen_los_alloc_large_inner (vtable, size);
        } else {
                /* tlab_next and tlab_temp_end are TLS vars so accessing them might be expensive */
 
@@ -245,15 +245,15 @@ mono_gc_alloc_obj_nolock (MonoVTable *vtable, size_t size)
                        if (size > tlab_size || available_in_tlab > SGEN_MAX_NURSERY_WASTE) {
                                /* Allocate directly from the nursery */
                                do {
-                                       p = mono_sgen_nursery_alloc (size);
+                                       p = sgen_nursery_alloc (size);
                                        if (!p) {
-                                               mono_sgen_minor_collect_or_expand_inner (size);
+                                               sgen_minor_collect_or_expand_inner (size);
                                                if (degraded_mode) {
                                                        p = alloc_degraded (vtable, size, FALSE);
                                                        binary_protocol_alloc_degraded (p, vtable, size);
                                                        return p;
                                                } else {
-                                                       p = mono_sgen_nursery_alloc (size);
+                                                       p = sgen_nursery_alloc (size);
                                                }
                                        }
                                } while (!p);
@@ -266,21 +266,21 @@ mono_gc_alloc_obj_nolock (MonoVTable *vtable, size_t size)
                                        memset (p, 0, size);
                                }
                        } else {
-                               int alloc_size = 0;
+                               size_t alloc_size = 0;
                                if (TLAB_START)
                                        DEBUG (3, fprintf (gc_debug_file, "Retire TLAB: %p-%p [%ld]\n", TLAB_START, TLAB_REAL_END, (long)(TLAB_REAL_END - TLAB_NEXT - size)));
-                               mono_sgen_nursery_retire_region (p, available_in_tlab);
+                               sgen_nursery_retire_region (p, available_in_tlab);
 
                                do {
-                                       p = mono_sgen_nursery_alloc_range (tlab_size, size, &alloc_size);
+                                       p = sgen_nursery_alloc_range (tlab_size, size, &alloc_size);
                                        if (!p) {
-                                               mono_sgen_minor_collect_or_expand_inner (tlab_size);
+                                               sgen_minor_collect_or_expand_inner (tlab_size);
                                                if (degraded_mode) {
                                                        p = alloc_degraded (vtable, size, FALSE);
                                                        binary_protocol_alloc_degraded (p, vtable, size);
                                                        return p;
                                                } else {
-                                                       p = mono_sgen_nursery_alloc_range (tlab_size, size, &alloc_size);
+                                                       p = sgen_nursery_alloc_range (tlab_size, size, &alloc_size);
                                                }               
                                        }
                                } while (!p);
@@ -303,13 +303,13 @@ mono_gc_alloc_obj_nolock (MonoVTable *vtable, size_t size)
                                /* Allocate from the TLAB */
                                p = (void*)TLAB_NEXT;
                                TLAB_NEXT += size;
-                               mono_sgen_set_nursery_scan_start ((char*)p);
+                               sgen_set_nursery_scan_start ((char*)p);
                        }
                } else {
                        /* Reached tlab_temp_end */
 
                        /* record the scan start so we can find pinned objects more easily */
-                       mono_sgen_set_nursery_scan_start ((char*)p);
+                       sgen_set_nursery_scan_start ((char*)p);
                        /* we just bump tlab_temp_end as well */
                        TLAB_TEMP_END = MIN (TLAB_REAL_END, TLAB_NEXT + SGEN_SCAN_START_SIZE);
                        DEBUG (5, fprintf (gc_debug_file, "Expanding local alloc: %p-%p\n", TLAB_NEXT, TLAB_TEMP_END));
@@ -340,10 +340,10 @@ mono_gc_try_alloc_obj_nolock (MonoVTable *vtable, size_t size)
 
        if (G_UNLIKELY (size > tlab_size)) {
                /* Allocate directly from the nursery */
-               p = mono_sgen_nursery_alloc (size);
+               p = sgen_nursery_alloc (size);
                if (!p)
                        return NULL;
-               mono_sgen_set_nursery_scan_start ((char*)p);
+               sgen_set_nursery_scan_start ((char*)p);
 
                /*FIXME we should use weak memory ops here. Should help specially on x86. */
                if (nursery_clear_policy == CLEAR_AT_TLAB_CREATION)
@@ -365,24 +365,24 @@ mono_gc_try_alloc_obj_nolock (MonoVTable *vtable, size_t size)
 
                        /* Second case, we overflowed temp end */
                        if (G_UNLIKELY (new_next >= TLAB_TEMP_END)) {
-                               mono_sgen_set_nursery_scan_start (new_next);
+                               sgen_set_nursery_scan_start (new_next);
                                /* we just bump tlab_temp_end as well */
                                TLAB_TEMP_END = MIN (TLAB_REAL_END, TLAB_NEXT + SGEN_SCAN_START_SIZE);
                                DEBUG (5, fprintf (gc_debug_file, "Expanding local alloc: %p-%p\n", TLAB_NEXT, TLAB_TEMP_END));         
                        }
                } else if (available_in_tlab > SGEN_MAX_NURSERY_WASTE) {
                        /* Allocate directly from the nursery */
-                       p = mono_sgen_nursery_alloc (size);
+                       p = sgen_nursery_alloc (size);
                        if (!p)
                                return NULL;
 
                        if (nursery_clear_policy == CLEAR_AT_TLAB_CREATION)
                                memset (p, 0, size);                    
                } else {
-                       int alloc_size = 0;
+                       size_t alloc_size = 0;
 
-                       mono_sgen_nursery_retire_region (p, available_in_tlab);
-                       new_next = mono_sgen_nursery_alloc_range (tlab_size, size, &alloc_size);
+                       sgen_nursery_retire_region (p, available_in_tlab);
+                       new_next = sgen_nursery_alloc_range (tlab_size, size, &alloc_size);
                        p = (void**)new_next;
                        if (!p)
                                return NULL;
@@ -391,7 +391,7 @@ mono_gc_try_alloc_obj_nolock (MonoVTable *vtable, size_t size)
                        TLAB_NEXT = new_next + size;
                        TLAB_REAL_END = new_next + alloc_size;
                        TLAB_TEMP_END = new_next + MIN (SGEN_SCAN_START_SIZE, alloc_size);
-                       mono_sgen_set_nursery_scan_start ((char*)p);
+                       sgen_set_nursery_scan_start ((char*)p);
 
                        if (nursery_clear_policy == CLEAR_AT_TLAB_CREATION)
                                memset (new_next, 0, alloc_size);
@@ -533,7 +533,7 @@ mono_gc_alloc_pinned_obj (MonoVTable *vtable, size_t size)
 
        if (size > SGEN_MAX_SMALL_OBJ_SIZE) {
                /* large objects are always pinned anyway */
-               p = mono_sgen_los_alloc_large_inner (vtable, size);
+               p = sgen_los_alloc_large_inner (vtable, size);
        } else {
                DEBUG (9, g_assert (vtable->klass->inited));
                p = major_collector.alloc_small_pinned_obj (size, SGEN_VTABLE_HAS_REFERENCES (vtable));
@@ -584,7 +584,7 @@ mono_gc_free_fixed (void* addr)
 }
 
 void
-mono_sgen_init_tlab_info (SgenThreadInfo* info)
+sgen_init_tlab_info (SgenThreadInfo* info)
 {
 #ifndef HAVE_KW_THREAD
        SgenThreadInfo *__thread_info__ = info;
@@ -604,7 +604,7 @@ mono_sgen_init_tlab_info (SgenThreadInfo* info)
  * Clear the thread local TLAB variables for all threads.
  */
 void
-mono_sgen_clear_tlabs (void)
+sgen_clear_tlabs (void)
 {
        SgenThreadInfo *info;
 
@@ -972,7 +972,7 @@ mono_gc_get_managed_allocator_types (void)
 }
 
 gboolean
-mono_sgen_is_managed_allocator (MonoMethod *method)
+sgen_is_managed_allocator (MonoMethod *method)
 {
        int i;
 
@@ -984,7 +984,7 @@ mono_sgen_is_managed_allocator (MonoMethod *method)
 
 #ifdef HEAVY_STATISTICS
 void
-mono_sgen_alloc_init_heavy_stats (void)
+sgen_alloc_init_heavy_stats (void)
 {
        mono_counters_register ("# objects allocated", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_objects_alloced);     
        mono_counters_register ("bytes allocated", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_bytes_alloced);
index 2add70915452177b3b0c315c9f356da0134b67b0..91b00436de524519a972ccfc6b8899acfe6fda38 100644 (file)
@@ -89,7 +89,7 @@ dyn_array_uninit (DynArray *da)
        if (da->capacity <= 0)
                return;
 
-       mono_sgen_free_internal_dynamic (da->data, da->elem_size * da->capacity, INTERNAL_MEM_BRIDGE_DATA);
+       sgen_free_internal_dynamic (da->data, da->elem_size * da->capacity, INTERNAL_MEM_BRIDGE_DATA);
        da->data = NULL;
 }
 
@@ -107,9 +107,9 @@ dyn_array_ensure_capacity (DynArray *da, int capacity)
        while (capacity > da->capacity)
                da->capacity *= 2;
 
-       new_data = mono_sgen_alloc_internal_dynamic (da->elem_size * da->capacity, INTERNAL_MEM_BRIDGE_DATA);
+       new_data = sgen_alloc_internal_dynamic (da->elem_size * da->capacity, INTERNAL_MEM_BRIDGE_DATA);
        memcpy (new_data, da->data, da->elem_size * da->size);
-       mono_sgen_free_internal_dynamic (da->data, da->elem_size * old_capacity, INTERNAL_MEM_BRIDGE_DATA);
+       sgen_free_internal_dynamic (da->data, da->elem_size * old_capacity, INTERNAL_MEM_BRIDGE_DATA);
        da->data = new_data;
 }
 
@@ -279,15 +279,14 @@ static int current_time;
 void
 mono_gc_register_bridge_callbacks (MonoGCBridgeCallbacks *callbacks)
 {
-       if (callbacks->bridge_version != MONO_SGEN_BRIDGE_VERSION) {
-               fprintf (stderr, "Invalid bridge callback version. Expected %d but got %d\n", MONO_SGEN_BRIDGE_VERSION, callbacks->bridge_version);
-               exit (1);
-       }
+       if (callbacks->bridge_version != SGEN_BRIDGE_VERSION)
+               g_error ("Invalid bridge callback version. Expected %d but got %d\n", SGEN_BRIDGE_VERSION, callbacks->bridge_version);
+
        bridge_callbacks = *callbacks;
 }
 
 gboolean
-mono_sgen_is_bridge_object (MonoObject *obj)
+sgen_is_bridge_object (MonoObject *obj)
 {
        if ((obj->vtable->gc_bits & SGEN_GC_BIT_BRIDGE_OBJECT) != SGEN_GC_BIT_BRIDGE_OBJECT)
                return FALSE;
@@ -295,13 +294,13 @@ mono_sgen_is_bridge_object (MonoObject *obj)
 }
 
 gboolean
-mono_sgen_is_bridge_class (MonoClass *class)
+sgen_is_bridge_class (MonoClass *class)
 {
        return bridge_callbacks.is_bridge_class (class);
 }
 
 gboolean
-mono_sgen_need_bridge_processing (void)
+sgen_need_bridge_processing (void)
 {
        return bridge_callbacks.cross_references != NULL;
 }
@@ -309,7 +308,7 @@ mono_sgen_need_bridge_processing (void)
 static HashEntry*
 get_hash_entry (MonoObject *obj, gboolean *existing)
 {
-       HashEntry *entry = mono_sgen_hash_table_lookup (&hash_table, obj);
+       HashEntry *entry = sgen_hash_table_lookup (&hash_table, obj);
        HashEntry new_entry;
 
        if (entry) {
@@ -327,9 +326,9 @@ get_hash_entry (MonoObject *obj, gboolean *existing)
        new_entry.finishing_time = -1;
        new_entry.scc_index = -1;
 
-       mono_sgen_hash_table_replace (&hash_table, obj, &new_entry);
+       sgen_hash_table_replace (&hash_table, obj, &new_entry, NULL);
 
-       return mono_sgen_hash_table_lookup (&hash_table, obj);
+       return sgen_hash_table_lookup (&hash_table, obj);
 }
 
 static void
@@ -353,7 +352,7 @@ free_data (void)
                dyn_array_uninit (&entry->srcs);
        } SGEN_HASH_TABLE_FOREACH_END;
 
-       mono_sgen_hash_table_clean (&hash_table);
+       sgen_hash_table_clean (&hash_table);
 
        dyn_array_uninit (&merge_array);
        //g_print ("total srcs %d - max %d\n", total_srcs, max_srcs);
@@ -381,11 +380,11 @@ object_is_live (MonoObject **objp)
        MonoObject *fwd = SGEN_OBJECT_IS_FORWARDED (obj);
        if (fwd) {
                *objp = fwd;
-               return mono_sgen_hash_table_lookup (&hash_table, fwd) == NULL;
+               return sgen_hash_table_lookup (&hash_table, fwd) == NULL;
        }
-       if (!mono_sgen_object_is_live (obj))
+       if (!sgen_object_is_live (obj))
                return FALSE;
-       return mono_sgen_hash_table_lookup (&hash_table, obj) == NULL;
+       return sgen_hash_table_lookup (&hash_table, obj) == NULL;
 }
 
 static DynArray registered_bridges = DYN_ARRAY_PTR_STATIC_INITIALIZER;
@@ -424,10 +423,10 @@ dfs1 (HashEntry *obj_entry, HashEntry *src)
                        start = (char*)obj;
 
                        if (src) {
-                               //g_print ("link %s -> %s\n", mono_sgen_safe_name (src->obj), mono_sgen_safe_name (obj));
+                               //g_print ("link %s -> %s\n", sgen_safe_name (src->obj), sgen_safe_name (obj));
                                add_source (obj_entry, src);
                        } else {
-                               //g_print ("starting with %s\n", mono_sgen_safe_name (obj));
+                               //g_print ("starting with %s\n", sgen_safe_name (obj));
                        }
 
                        if (obj_entry->is_visited)
@@ -443,7 +442,7 @@ dfs1 (HashEntry *obj_entry, HashEntry *src)
                } else {
                        obj_entry = dyn_array_ptr_pop (&dfs_stack);
 
-                       //g_print ("finish %s\n", mono_sgen_safe_name (obj_entry->obj));
+                       //g_print ("finish %s\n", sgen_safe_name (obj_entry->obj));
                        register_finishing_time (obj_entry, current_time++);
                }
        } while (dfs_stack.size > 0);
@@ -518,20 +517,20 @@ static int fist_pass_links, second_pass_links, sccs_links;
 static int max_sccs_links = 0;
 
 void
-mono_sgen_bridge_register_finalized_object (MonoObject *obj)
+sgen_bridge_register_finalized_object (MonoObject *obj)
 {
-       g_assert (mono_sgen_need_bridge_processing ());
+       g_assert (sgen_need_bridge_processing ());
        dyn_array_ptr_push (&registered_bridges, obj);
 }
 
 void
-mono_sgen_bridge_reset_data (void)
+sgen_bridge_reset_data (void)
 {
        registered_bridges.size = 0;
 }
 
 void
-mono_sgen_bridge_processing_stw_step (void)
+sgen_bridge_processing_stw_step (void)
 {
        int i;
        SGEN_TV_DECLARE (atv);
@@ -556,7 +555,7 @@ mono_sgen_bridge_processing_stw_step (void)
 }
 
 void
-mono_sgen_bridge_processing_finish (void)
+sgen_bridge_processing_finish (void)
 {
        int i, j;
        int num_sccs, num_xrefs;
@@ -578,7 +577,7 @@ mono_sgen_bridge_processing_finish (void)
 
        /* alloc and fill array of all entries */
 
-       all_entries = mono_sgen_alloc_internal_dynamic (sizeof (HashEntry*) * hash_table.num_entries, INTERNAL_MEM_BRIDGE_DATA);
+       all_entries = sgen_alloc_internal_dynamic (sizeof (HashEntry*) * hash_table.num_entries, INTERNAL_MEM_BRIDGE_DATA);
 
        j = 0;
        SGEN_HASH_TABLE_FOREACH (&hash_table, obj, entry) {
@@ -639,7 +638,7 @@ mono_sgen_bridge_processing_finish (void)
                max_sccs_links = MAX (max_sccs_links, scc->xrefs.size);
        }
 
-       api_sccs = mono_sgen_alloc_internal_dynamic (sizeof (MonoGCBridgeSCC*) * num_sccs, INTERNAL_MEM_BRIDGE_DATA);
+       api_sccs = sgen_alloc_internal_dynamic (sizeof (MonoGCBridgeSCC*) * num_sccs, INTERNAL_MEM_BRIDGE_DATA);
        num_xrefs = 0;
        j = 0;
        for (i = 0; i < sccs.size; ++i) {
@@ -647,7 +646,7 @@ mono_sgen_bridge_processing_finish (void)
                if (!scc->num_bridge_entries)
                        continue;
 
-               api_sccs [j] = mono_sgen_alloc_internal_dynamic (sizeof (MonoGCBridgeSCC) + sizeof (MonoObject*) * scc->num_bridge_entries, INTERNAL_MEM_BRIDGE_DATA);
+               api_sccs [j] = sgen_alloc_internal_dynamic (sizeof (MonoGCBridgeSCC) + sizeof (MonoObject*) * scc->num_bridge_entries, INTERNAL_MEM_BRIDGE_DATA);
                api_sccs [j]->num_objs = scc->num_bridge_entries;
                scc->num_bridge_entries = 0;
                scc->api_index = j++;
@@ -662,7 +661,7 @@ mono_sgen_bridge_processing_finish (void)
                }
        } SGEN_HASH_TABLE_FOREACH_END;
 
-       api_xrefs = mono_sgen_alloc_internal_dynamic (sizeof (MonoGCBridgeXRef) * num_xrefs, INTERNAL_MEM_BRIDGE_DATA);
+       api_xrefs = sgen_alloc_internal_dynamic (sizeof (MonoGCBridgeXRef) * num_xrefs, INTERNAL_MEM_BRIDGE_DATA);
        j = 0;
        for (i = 0; i < sccs.size; ++i) {
                int k;
@@ -699,7 +698,7 @@ mono_sgen_bridge_processing_finish (void)
        }
        dyn_array_uninit (&sccs);
 
-       mono_sgen_free_internal_dynamic (all_entries, sizeof (HashEntry*) * hash_table.num_entries, INTERNAL_MEM_BRIDGE_DATA);
+       sgen_free_internal_dynamic (all_entries, sizeof (HashEntry*) * hash_table.num_entries, INTERNAL_MEM_BRIDGE_DATA);
 
        free_data ();
        /* Empty the registered bridges array */
@@ -723,19 +722,19 @@ mono_sgen_bridge_processing_finish (void)
                if (!api_sccs [i]->objs [0])
                        continue;
                for (j = 0; j < api_sccs [i]->num_objs; ++j)
-                       mono_sgen_mark_bridge_object (api_sccs [i]->objs [j]);
+                       sgen_mark_bridge_object (api_sccs [i]->objs [j]);
        }
 
        /* free callback data */
 
        for (i = 0; i < num_sccs; ++i) {
-               mono_sgen_free_internal_dynamic (api_sccs [i],
+               sgen_free_internal_dynamic (api_sccs [i],
                                sizeof (MonoGCBridgeSCC) + sizeof (MonoObject*) * api_sccs [i]->num_objs,
                                INTERNAL_MEM_BRIDGE_DATA);
        }
-       mono_sgen_free_internal_dynamic (api_sccs, sizeof (MonoGCBridgeSCC*) * num_sccs, INTERNAL_MEM_BRIDGE_DATA);
+       sgen_free_internal_dynamic (api_sccs, sizeof (MonoGCBridgeSCC*) * num_sccs, INTERNAL_MEM_BRIDGE_DATA);
 
-       mono_sgen_free_internal_dynamic (api_xrefs, sizeof (MonoGCBridgeXRef) * num_xrefs, INTERNAL_MEM_BRIDGE_DATA);
+       sgen_free_internal_dynamic (api_xrefs, sizeof (MonoGCBridgeXRef) * num_xrefs, INTERNAL_MEM_BRIDGE_DATA);
 
        SGEN_TV_GETTIME (atv);
        step_8 = SGEN_TV_ELAPSED (btv, atv);
@@ -778,7 +777,7 @@ bridge_test_cross_reference (int num_sccs, MonoGCBridgeSCC **sccs, int num_xrefs
                int j;
        //      g_print ("--- SCC %d\n", i);
                for (j = 0; j < sccs [i]->num_objs; ++j) {
-       //              g_print ("  %s\n", mono_sgen_safe_name (sccs [i]->objs [j]));
+       //              g_print ("  %s\n", sgen_safe_name (sccs [i]->objs [j]));
                        if (i & 1) /*retain half of the bridged objects */
                                sccs [i]->objs [0] = NULL;
                }
@@ -792,10 +791,10 @@ bridge_test_cross_reference (int num_sccs, MonoGCBridgeSCC **sccs, int num_xrefs
 
 
 void
-mono_sgen_register_test_bridge_callbacks (const char *bridge_class_name)
+sgen_register_test_bridge_callbacks (const char *bridge_class_name)
 {
        MonoGCBridgeCallbacks callbacks;
-       callbacks.bridge_version = MONO_SGEN_BRIDGE_VERSION;
+       callbacks.bridge_version = SGEN_BRIDGE_VERSION;
        callbacks.is_bridge_class = bridge_test_is_bridge_class;
        callbacks.is_bridge_object = bridge_test_is_bridge_object;
        callbacks.cross_references = bridge_test_cross_reference;
index 2512542b3c6f4bde943e32a2b28e6fde64cbd68d..3fff4b7af73dc5fe60a564cada2d5a7ad95e1b08 100644 (file)
@@ -29,7 +29,7 @@
 MONO_BEGIN_DECLS
 
 enum {
-       MONO_SGEN_BRIDGE_VERSION = 2
+       SGEN_BRIDGE_VERSION = 2
 };
        
 typedef struct {
index 5c6a844245e26a40c03473b61dbe753468198c8a..a4c755e37efdfefe66bba42605d01d597544ce7c 100644 (file)
@@ -83,25 +83,25 @@ cards_in_range (mword address, mword size)
 }
 
 static void
-mono_sgen_card_table_wbarrier_set_field (MonoObject *obj, gpointer field_ptr, MonoObject* value)
+sgen_card_table_wbarrier_set_field (MonoObject *obj, gpointer field_ptr, MonoObject* value)
 {
        *(void**)field_ptr = value;
-       if (mono_sgen_ptr_in_nursery (value))
+       if (sgen_ptr_in_nursery (value))
                sgen_card_table_mark_address ((mword)field_ptr);
-       mono_sgen_dummy_use (value);
+       sgen_dummy_use (value);
 }
 
 static void
-mono_sgen_card_table_wbarrier_set_arrayref (MonoArray *arr, gpointer slot_ptr, MonoObject* value)
+sgen_card_table_wbarrier_set_arrayref (MonoArray *arr, gpointer slot_ptr, MonoObject* value)
 {
        *(void**)slot_ptr = value;
-       if (mono_sgen_ptr_in_nursery (value))
+       if (sgen_ptr_in_nursery (value))
                sgen_card_table_mark_address ((mword)slot_ptr);
-       mono_sgen_dummy_use (value);    
+       sgen_dummy_use (value); 
 }
 
 static void
-mono_sgen_card_table_wbarrier_arrayref_copy (gpointer dest_ptr, gpointer src_ptr, int count)
+sgen_card_table_wbarrier_arrayref_copy (gpointer dest_ptr, gpointer src_ptr, int count)
 {
        gpointer *dest = dest_ptr;
        gpointer *src = src_ptr;
@@ -115,24 +115,24 @@ mono_sgen_card_table_wbarrier_arrayref_copy (gpointer dest_ptr, gpointer src_ptr
                for (; dest >= start; --src, --dest) {
                        gpointer value = *src;
                        *dest = value;
-                       if (mono_sgen_ptr_in_nursery (value))
+                       if (sgen_ptr_in_nursery (value))
                                sgen_card_table_mark_address ((mword)dest);
-                       mono_sgen_dummy_use (value);
+                       sgen_dummy_use (value);
                }
        } else {
                gpointer *end = dest + count;
                for (; dest < end; ++src, ++dest) {
                        gpointer value = *src;
                        *dest = value;
-                       if (mono_sgen_ptr_in_nursery (value))
+                       if (sgen_ptr_in_nursery (value))
                                sgen_card_table_mark_address ((mword)dest);
-                       mono_sgen_dummy_use (value);
+                       sgen_dummy_use (value);
                }
        }       
 }
 
 static void
-mono_sgen_card_table_wbarrier_value_copy (gpointer dest, gpointer src, int count, MonoClass *klass)
+sgen_card_table_wbarrier_value_copy (gpointer dest, gpointer src, int count, MonoClass *klass)
 {
        size_t element_size = mono_class_value_size (klass, NULL);
        size_t size = count * element_size;
@@ -153,7 +153,7 @@ mono_sgen_card_table_wbarrier_value_copy (gpointer dest, gpointer src, int count
 }
 
 static void
-mono_sgen_card_table_wbarrier_object_copy (MonoObject* obj, MonoObject *src)
+sgen_card_table_wbarrier_object_copy (MonoObject* obj, MonoObject *src)
 {
        int size;
        TLAB_ACCESS_INIT;
@@ -176,7 +176,7 @@ mono_sgen_card_table_wbarrier_object_copy (MonoObject* obj, MonoObject *src)
 }
 
 static void
-mono_sgen_card_table_wbarrier_generic_nostore (gpointer ptr)
+sgen_card_table_wbarrier_generic_nostore (gpointer ptr)
 {
        sgen_card_table_mark_address ((mword)ptr);      
 }
@@ -273,13 +273,13 @@ sgen_card_table_is_range_marked (guint8 *cards, mword address, mword size)
 }
 
 static void
-mono_sgen_card_table_record_pointer (gpointer address)
+sgen_card_table_record_pointer (gpointer address)
 {
        *sgen_card_table_get_card_address ((mword)address) = 1;
 }
 
 static gboolean
-mono_sgen_card_table_find_address (char *addr)
+sgen_card_table_find_address (char *addr)
 {
        return sgen_card_table_address_is_marked ((mword)addr);
 }
@@ -333,21 +333,21 @@ clear_cards (mword start, mword size)
 #endif
 
 static void
-mono_sgen_card_table_prepare_for_major_collection (void)
+sgen_card_table_prepare_for_major_collection (void)
 {
        /*XXX we could do this in 2 ways. using mincore or iterating over all sections/los objects */
        sgen_major_collector_iterate_live_block_ranges (clear_cards);
-       mono_sgen_los_iterate_live_block_ranges (clear_cards);
+       sgen_los_iterate_live_block_ranges (clear_cards);
 }
 
 static void
-mono_sgen_card_table_finish_minor_collection (void)
+sgen_card_table_finish_minor_collection (void)
 {
        sgen_card_tables_collect_stats (FALSE);
 }
 
 static void
-mono_sgen_card_table_finish_scan_remsets (void *start_nursery, void *end_nursery, SgenGrayQueue *queue)
+sgen_card_table_finish_scan_remsets (void *start_nursery, void *end_nursery, SgenGrayQueue *queue)
 {
        SGEN_TV_DECLARE (atv);
        SGEN_TV_DECLARE (btv);
@@ -358,17 +358,17 @@ mono_sgen_card_table_finish_scan_remsets (void *start_nursery, void *end_nursery
        /*FIXME we should have a bit on each block/los object telling if the object have marked cards.*/
        /*First we copy*/
        sgen_major_collector_iterate_live_block_ranges (move_cards_to_shadow_table);
-       mono_sgen_los_iterate_live_block_ranges (move_cards_to_shadow_table);
+       sgen_los_iterate_live_block_ranges (move_cards_to_shadow_table);
 
        /*Then we clear*/
-       mono_sgen_card_table_prepare_for_major_collection ();
+       sgen_card_table_prepare_for_major_collection ();
 #endif
        SGEN_TV_GETTIME (atv);
        sgen_major_collector_scan_card_table (queue);
        SGEN_TV_GETTIME (btv);
        last_major_scan_time = SGEN_TV_ELAPSED (atv, btv); 
        major_card_scan_time += last_major_scan_time;
-       mono_sgen_los_scan_card_table (queue);
+       sgen_los_scan_card_table (queue);
        SGEN_TV_GETTIME (atv);
        last_los_scan_time = SGEN_TV_ELAPSED (btv, atv);
        los_card_scan_time += last_los_scan_time;
@@ -488,9 +488,6 @@ sgen_cardtable_scan_object (char *obj, mword block_obj_size, guint8 *cards, Sgen
 {
        MonoVTable *vt = (MonoVTable*)SGEN_LOAD_VTABLE (obj);
        MonoClass *klass = vt->klass;
-       CopyOrMarkObjectFunc copy_func = mono_sgen_get_copy_object ();
-       ScanObjectFunc scan_object_func = mono_sgen_get_minor_scan_object ();
-       ScanVTypeFunc scan_vtype_func = mono_sgen_get_minor_scan_vtype ();
 
        HEAVY_STAT (++large_objects);
 
@@ -501,7 +498,7 @@ sgen_cardtable_scan_object (char *obj, mword block_obj_size, guint8 *cards, Sgen
                guint8 *card_data, *card_base;
                guint8 *card_data_end;
                char *obj_start = sgen_card_table_align_pointer (obj);
-               mword obj_size = mono_sgen_par_object_get_size (vt, (MonoObject*)obj);
+               mword obj_size = sgen_par_object_get_size (vt, (MonoObject*)obj);
                char *obj_end = obj + obj_size;
                size_t card_count;
                int extra_idx = 0;
@@ -556,18 +553,22 @@ LOOP_HEAD:
 
                        elem = (char*)mono_array_addr_with_size ((MonoArray*)obj, elem_size, index);
                        if (klass->element_class->valuetype) {
+                               ScanVTypeFunc scan_vtype_func = sgen_get_current_object_ops ()->scan_vtype;
+
                                for (; elem < card_end; elem += elem_size)
                                        scan_vtype_func (elem, desc, queue);
                        } else {
+                               CopyOrMarkObjectFunc copy_func = sgen_get_current_object_ops ()->copy_or_mark_object;
+
                                HEAVY_STAT (++los_array_cards);
                                for (; elem < card_end; elem += SIZEOF_VOID_P) {
                                        gpointer new, old = *(gpointer*)elem;
-                                       if (G_UNLIKELY (mono_sgen_ptr_in_nursery (old))) {
+                                       if (G_UNLIKELY (sgen_ptr_in_nursery (old))) {
                                                HEAVY_STAT (++los_array_remsets);
                                                copy_func ((void**)elem, queue);
                                                new = *(gpointer*)elem;
-                                               if (G_UNLIKELY (mono_sgen_ptr_in_nursery (new)))
-                                                       mono_sgen_add_to_global_remset (elem);
+                                               if (G_UNLIKELY (sgen_ptr_in_nursery (new)))
+                                                       sgen_add_to_global_remset (elem);
                                        }
                                }
                        }
@@ -587,9 +588,9 @@ LOOP_HEAD:
                HEAVY_STAT (++bloby_objects);
                if (cards) {
                        if (sgen_card_table_is_range_marked (cards, (mword)obj, block_obj_size))
-                               scan_object_func (obj, queue);
+                               sgen_get_current_object_ops ()->scan_object (obj, queue);
                } else if (sgen_card_table_region_begin_scanning ((mword)obj, block_obj_size)) {
-                       scan_object_func (obj, queue);
+                       sgen_get_current_object_ops ()->scan_object (obj, queue);
                }
        }
 }
@@ -638,12 +639,12 @@ sgen_card_tables_collect_stats (gboolean begin)
                cur_stats = &major_stats;
                sgen_major_collector_iterate_live_block_ranges (count_marked_cards);
                cur_stats = &los_stats;
-               mono_sgen_los_iterate_live_block_ranges (count_marked_cards);
+               sgen_los_iterate_live_block_ranges (count_marked_cards);
        } else {
                cur_stats = &major_stats;
                sgen_major_collector_iterate_live_block_ranges (count_marked_cards);
                cur_stats = &los_stats;
-               mono_sgen_los_iterate_live_block_ranges (count_remarked_cards);
+               sgen_los_iterate_live_block_ranges (count_remarked_cards);
                printf ("cards major (t %d m %d r %d)  los (t %d m %d r %d) major_scan %.2fms los_scan %.2fms\n", 
                        major_stats.total, major_stats.marked, major_stats.remarked,
                        los_stats.total, los_stats.marked, los_stats.remarked,
@@ -655,10 +656,10 @@ sgen_card_tables_collect_stats (gboolean begin)
 void
 sgen_card_table_init (SgenRemeberedSet *remset)
 {
-       sgen_cardtable = mono_sgen_alloc_os_memory (CARD_COUNT_IN_BYTES, TRUE);
+       sgen_cardtable = sgen_alloc_os_memory (CARD_COUNT_IN_BYTES, TRUE);
 
 #ifdef SGEN_HAVE_OVERLAPPING_CARDS
-       sgen_shadow_cardtable = mono_sgen_alloc_os_memory (CARD_COUNT_IN_BYTES, TRUE);
+       sgen_shadow_cardtable = sgen_alloc_os_memory (CARD_COUNT_IN_BYTES, TRUE);
 #endif
 
 #ifdef HEAVY_STATISTICS
@@ -677,20 +678,20 @@ sgen_card_table_init (SgenRemeberedSet *remset)
        mono_counters_register ("cardtable los scan time", MONO_COUNTER_GC | MONO_COUNTER_TIME_INTERVAL, &los_card_scan_time);
 
 
-       remset->wbarrier_set_field = mono_sgen_card_table_wbarrier_set_field;
-       remset->wbarrier_set_arrayref = mono_sgen_card_table_wbarrier_set_arrayref;
-       remset->wbarrier_arrayref_copy = mono_sgen_card_table_wbarrier_arrayref_copy;
-       remset->wbarrier_value_copy = mono_sgen_card_table_wbarrier_value_copy;
-       remset->wbarrier_object_copy = mono_sgen_card_table_wbarrier_object_copy;
-       remset->wbarrier_generic_nostore = mono_sgen_card_table_wbarrier_generic_nostore;
-       remset->record_pointer = mono_sgen_card_table_record_pointer;
+       remset->wbarrier_set_field = sgen_card_table_wbarrier_set_field;
+       remset->wbarrier_set_arrayref = sgen_card_table_wbarrier_set_arrayref;
+       remset->wbarrier_arrayref_copy = sgen_card_table_wbarrier_arrayref_copy;
+       remset->wbarrier_value_copy = sgen_card_table_wbarrier_value_copy;
+       remset->wbarrier_object_copy = sgen_card_table_wbarrier_object_copy;
+       remset->wbarrier_generic_nostore = sgen_card_table_wbarrier_generic_nostore;
+       remset->record_pointer = sgen_card_table_record_pointer;
 
-       remset->finish_scan_remsets = mono_sgen_card_table_finish_scan_remsets;
+       remset->finish_scan_remsets = sgen_card_table_finish_scan_remsets;
 
-       remset->finish_minor_collection = mono_sgen_card_table_finish_minor_collection;
-       remset->prepare_for_major_collection = mono_sgen_card_table_prepare_for_major_collection;
+       remset->finish_minor_collection = sgen_card_table_finish_minor_collection;
+       remset->prepare_for_major_collection = sgen_card_table_prepare_for_major_collection;
 
-       remset->find_address = mono_sgen_card_table_find_address;
+       remset->find_address = sgen_card_table_find_address;
 }
 
 #else
diff --git a/mono/metadata/sgen-copy-object.h b/mono/metadata/sgen-copy-object.h
new file mode 100644 (file)
index 0000000..10d195b
--- /dev/null
@@ -0,0 +1,262 @@
+/*
+ * Copyright 2001-2003 Ximian, Inc
+ * Copyright 2003-2010 Novell, Inc.
+ * 
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sublicense, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ * 
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ * 
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+ * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+ * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+ * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+extern long long stat_copy_object_called_nursery;
+extern long long stat_objects_copied_nursery;
+
+extern long long stat_nursery_copy_object_failed_from_space;
+extern long long stat_nursery_copy_object_failed_forwarded;
+extern long long stat_nursery_copy_object_failed_pinned;
+
+extern long long stat_slots_allocated_in_vain;
+
+/*
+ * This function can be used even if the vtable of obj is not valid
+ * anymore, which is the case in the parallel collector.
+ */
+static void
+par_copy_object_no_checks (char *destination, MonoVTable *vt, void *obj, mword objsize, SgenGrayQueue *queue)
+{
+       static const void *copy_labels [] = { &&LAB_0, &&LAB_1, &&LAB_2, &&LAB_3, &&LAB_4, &&LAB_5, &&LAB_6, &&LAB_7, &&LAB_8 };
+
+       DEBUG (9, g_assert (vt->klass->inited));
+       DEBUG (9, fprintf (gc_debug_file, " (to %p, %s size: %lu)\n", destination, ((MonoObject*)obj)->vtable->klass->name, (unsigned long)objsize));
+       binary_protocol_copy (obj, destination, vt, objsize);
+
+       if (objsize <= sizeof (gpointer) * 8) {
+               mword *dest = (mword*)destination;
+               goto *copy_labels [objsize / sizeof (gpointer)];
+       LAB_8:
+               (dest) [7] = ((mword*)obj) [7];
+       LAB_7:
+               (dest) [6] = ((mword*)obj) [6];
+       LAB_6:
+               (dest) [5] = ((mword*)obj) [5];
+       LAB_5:
+               (dest) [4] = ((mword*)obj) [4];
+       LAB_4:
+               (dest) [3] = ((mword*)obj) [3];
+       LAB_3:
+               (dest) [2] = ((mword*)obj) [2];
+       LAB_2:
+               (dest) [1] = ((mword*)obj) [1];
+       LAB_1:
+               ;
+       LAB_0:
+               ;
+       } else {
+               /*can't trust memcpy doing word copies */
+               mono_gc_memmove (destination + sizeof (mword), (char*)obj + sizeof (mword), objsize - sizeof (mword));
+       }
+       /* adjust array->bounds */
+       DEBUG (9, g_assert (vt->gc_descr));
+       if (G_UNLIKELY (vt->rank && ((MonoArray*)obj)->bounds)) {
+               MonoArray *array = (MonoArray*)destination;
+               array->bounds = (MonoArrayBounds*)((char*)destination + ((char*)((MonoArray*)obj)->bounds - (char*)obj));
+               DEBUG (9, fprintf (gc_debug_file, "Array instance %p: size: %lu, rank: %d, length: %lu\n", array, (unsigned long)objsize, vt->rank, (unsigned long)mono_array_length (array)));
+       }
+       if (G_UNLIKELY (mono_profiler_events & MONO_PROFILE_GC_MOVES))
+               sgen_register_moved_object (obj, destination);
+       obj = destination;
+       if (queue) {
+               DEBUG (9, fprintf (gc_debug_file, "Enqueuing gray object %p (%s)\n", obj, sgen_safe_name (obj)));
+               GRAY_OBJECT_ENQUEUE (queue, obj);
+       }
+}
+
+static G_GNUC_UNUSED void*
+copy_object_no_checks (void *obj, SgenGrayQueue *queue)
+{
+       MonoVTable *vt = ((MonoObject*)obj)->vtable;
+       gboolean has_references = SGEN_VTABLE_HAS_REFERENCES (vt);
+       mword objsize = SGEN_ALIGN_UP (sgen_par_object_get_size (vt, (MonoObject*)obj));
+       char *destination = collector_serial_alloc_for_promotion (obj, objsize, has_references);
+
+       if (G_UNLIKELY (!destination)) {
+               collector_pin_object (obj, queue);
+               sgen_set_pinned_from_failed_allocation (objsize);
+               return obj;
+       }
+
+       *(MonoVTable**)destination = vt;
+       par_copy_object_no_checks (destination, vt, obj, objsize, has_references ? queue : NULL);
+
+       /* set the forwarding pointer */
+       SGEN_FORWARD_OBJECT (obj, destination);
+
+       return destination;
+}
+
+#ifdef GENERATE_COPY_FUNCTIONS
+
+/*
+ * This is how the copying happens from the nursery to the old generation.
+ * We assume that at this time all the pinned objects have been identified and
+ * marked as such.
+ * We run scan_object() for each pinned object so that each referenced
+ * objects if possible are copied. The new gray objects created can have
+ * scan_object() run on them right away, too.
+ * Then we run copy_object() for the precisely tracked roots. At this point
+ * all the roots are either gray or black. We run scan_object() on the gray
+ * objects until no more gray objects are created.
+ * At the end of the process we walk again the pinned list and we unmark
+ * the pinned flag. As we go we also create the list of free space for use
+ * in the next allocation runs.
+ *
+ * We need to remember objects from the old generation that point to the new one
+ * (or just addresses?).
+ *
+ * copy_object could be made into a macro once debugged (use inline for now).
+ */
+
+static void
+serial_copy_object (void **obj_slot, SgenGrayQueue *queue)
+{
+       char *forwarded;
+       char *obj = *obj_slot;
+
+       DEBUG (9, g_assert (current_collection_generation == GENERATION_NURSERY));
+
+       HEAVY_STAT (++stat_copy_object_called_nursery);
+
+       if (!sgen_ptr_in_nursery (obj)) {
+               HEAVY_STAT (++stat_nursery_copy_object_failed_from_space);
+               return;
+       }
+
+       DEBUG (9, fprintf (gc_debug_file, "Precise copy of %p from %p", obj, obj_slot));
+
+       /*
+        * Before we can copy the object we must make sure that we are
+        * allowed to, i.e. that the object not pinned, not already
+        * forwarded or belongs to the nursery To Space.
+        */
+
+       if ((forwarded = SGEN_OBJECT_IS_FORWARDED (obj))) {
+               DEBUG (9, g_assert ((*(MonoVTable**)SGEN_LOAD_VTABLE(obj))->gc_descr));
+               DEBUG (9, fprintf (gc_debug_file, " (already forwarded to %p)\n", forwarded));
+               HEAVY_STAT (++stat_nursery_copy_object_failed_forwarded);
+               *obj_slot = forwarded;
+               return;
+       }
+       if (SGEN_OBJECT_IS_PINNED (obj)) {
+               DEBUG (9, g_assert (((MonoVTable*)SGEN_LOAD_VTABLE(obj))->gc_descr));
+               DEBUG (9, fprintf (gc_debug_file, " (pinned, no change)\n"));
+               HEAVY_STAT (++stat_nursery_copy_object_failed_pinned);
+               return;
+       }
+
+       if (sgen_nursery_is_to_space (obj)) {
+               DEBUG (9, g_assert (((MonoVTable*)SGEN_LOAD_VTABLE(obj))->gc_descr));
+               DEBUG (9, fprintf (gc_debug_file, " (tospace, no change)\n"));
+               HEAVY_STAT (++stat_nursery_copy_object_failed_to_space);                
+               return;
+       }
+
+       HEAVY_STAT (++stat_objects_copied_nursery);
+
+       *obj_slot = copy_object_no_checks (obj, queue);
+}
+
+static void
+parallel_copy_object (void **obj_slot, SgenGrayQueue *queue)
+{
+       char *obj = *obj_slot;
+       mword vtable_word, objsize;
+       MonoVTable *vt;
+       void *destination;
+       gboolean has_references;
+
+       DEBUG (9, g_assert (current_collection_generation == GENERATION_NURSERY));
+
+       HEAVY_STAT (++stat_copy_object_called_nursery);
+
+       if (!sgen_ptr_in_nursery (obj)) {
+               HEAVY_STAT (++stat_nursery_copy_object_failed_from_space);
+               return;
+       }
+
+       vtable_word = *(mword*)obj;
+       vt = (MonoVTable*)(vtable_word & ~SGEN_VTABLE_BITS_MASK);
+
+       /*
+        * Before we can copy the object we must make sure that we are
+        * allowed to, i.e. that the object not pinned, not already
+        * forwarded and not in the nursery To Space.
+        */
+
+       if (vtable_word & SGEN_FORWARDED_BIT) {
+               HEAVY_STAT (++stat_nursery_copy_object_failed_forwarded);
+               *obj_slot = vt;
+               return;
+       }
+       if (vtable_word & SGEN_PINNED_BIT) {
+               HEAVY_STAT (++stat_nursery_copy_object_failed_pinned);
+               return;
+       }
+
+       if (sgen_nursery_is_to_space (obj)) {
+               HEAVY_STAT (++stat_nursery_copy_object_failed_to_space);                
+               return;
+       }
+
+       HEAVY_STAT (++stat_objects_copied_nursery);
+
+       objsize = SGEN_ALIGN_UP (sgen_par_object_get_size (vt, (MonoObject*)obj));
+       has_references = SGEN_VTABLE_HAS_REFERENCES (vt);
+
+       destination = collector_parallel_alloc_for_promotion (obj, objsize, has_references);
+
+       if (G_UNLIKELY (!destination)) {
+               sgen_parallel_pin_or_update (obj_slot, obj, vt, queue);
+               return;
+       }
+
+       *(MonoVTable**)destination = vt;
+
+       if (SGEN_CAS_PTR ((void*)obj, (void*)((mword)destination | SGEN_FORWARDED_BIT), vt) == vt) {
+               par_copy_object_no_checks (destination, vt, obj, objsize, has_references ? queue : NULL);
+               obj = destination;
+               *obj_slot = obj;
+       } else {
+               /* FIXME: unify with code in major_copy_or_mark_object() */
+
+               /* FIXME: Give destination back to the allocator. */
+               /*The major collector only needs the first word zeroed and nursery requires all bits to be. */
+               if (!sgen_ptr_in_nursery (destination))
+                       *(void**)destination = NULL;
+               else
+                       memset (destination, 0, objsize);
+
+               vtable_word = *(mword*)obj;
+               g_assert (vtable_word & SGEN_FORWARDED_BIT);
+
+               obj = (void*)(vtable_word & ~SGEN_VTABLE_BITS_MASK);
+
+               *obj_slot = obj;
+
+               HEAVY_STAT (++stat_slots_allocated_in_vain);
+       }
+}
+
+#endif
\ No newline at end of file
index 63e2db0a77706c8d95ce7f4ccb572e6edb7cd68a..2eab61e0c383b8d47e829e8a193417631af46d2c 100644 (file)
@@ -41,7 +41,7 @@
 
 #define object_is_forwarded    SGEN_OBJECT_IS_FORWARDED
 #define object_is_pinned       SGEN_OBJECT_IS_PINNED
-#define safe_object_get_size   mono_sgen_safe_object_get_size
+#define safe_object_get_size   sgen_safe_object_get_size
 
 void describe_ptr (char *ptr);
 void check_object (char *start);
@@ -71,10 +71,10 @@ describe_ptr (char *ptr)
        int type;
        char *start;
 
-       if (mono_sgen_ptr_in_nursery (ptr)) {
+       if (sgen_ptr_in_nursery (ptr)) {
                printf ("Pointer inside nursery.\n");
        } else {
-               if (mono_sgen_ptr_is_in_los (ptr, &start)) {
+               if (sgen_ptr_is_in_los (ptr, &start)) {
                        if (ptr == start)
                                printf ("Pointer is the start of object %p in LOS space.\n", start);
                        else
@@ -104,7 +104,7 @@ describe_ptr (char *ptr)
                printf ("VTable is invalid (empty).\n");
                return;
        }
-       if (mono_sgen_ptr_in_nursery (vtable)) {
+       if (sgen_ptr_in_nursery (vtable)) {
                printf ("VTable is invalid (points inside nursery).\n");
                return;
        }
@@ -127,8 +127,8 @@ static gboolean missing_remsets;
  */
 #undef HANDLE_PTR
 #define HANDLE_PTR(ptr,obj)    do {    \
-       if (*(ptr) && mono_sgen_ptr_in_nursery ((char*)*(ptr))) { \
-               if (!mono_sgen_get_remset ()->find_address ((char*)(ptr))) { \
+       if (*(ptr) && sgen_ptr_in_nursery ((char*)*(ptr))) { \
+               if (!sgen_get_remset ()->find_address ((char*)(ptr))) { \
                        fprintf (gc_debug_file, "Oldspace->newspace reference %p at offset %td in object %p (%s.%s) not found in remsets.\n", *(ptr), (char*)(ptr) - (char*)(obj), (obj), ((MonoObject*)(obj))->vtable->klass->name_space, ((MonoObject*)(obj))->vtable->klass->name); \
                        binary_protocol_missing_remset ((obj), (gpointer)LOAD_VTABLE ((obj)), (char*)(ptr) - (char*)(obj), *(ptr), (gpointer)LOAD_VTABLE(*(ptr)), object_is_pinned (*(ptr))); \
                        if (!object_is_pinned (*(ptr)))                                                         \
@@ -157,7 +157,7 @@ check_consistency_callback (char *start, size_t size, void *dummy)
  * Assumes the world is stopped.
  */
 void
-mono_sgen_check_consistency (void)
+sgen_check_consistency (void)
 {
        // Need to add more checks
 
@@ -168,7 +168,7 @@ mono_sgen_check_consistency (void)
        // Check that oldspace->newspace pointers are registered with the collector
        major_collector.iterate_objects (TRUE, TRUE, (IterateObjectCallbackFunc)check_consistency_callback, NULL);
 
-       mono_sgen_los_iterate_objects ((IterateObjectCallbackFunc)check_consistency_callback, NULL);
+       sgen_los_iterate_objects ((IterateObjectCallbackFunc)check_consistency_callback, NULL);
 
        DEBUG (1, fprintf (gc_debug_file, "Heap consistency check done.\n"));
 
@@ -191,17 +191,17 @@ check_major_refs_callback (char *start, size_t size, void *dummy)
 }
 
 void
-mono_sgen_check_major_refs (void)
+sgen_check_major_refs (void)
 {
        major_collector.iterate_objects (TRUE, TRUE, (IterateObjectCallbackFunc)check_major_refs_callback, NULL);
-       mono_sgen_los_iterate_objects ((IterateObjectCallbackFunc)check_major_refs_callback, NULL);
+       sgen_los_iterate_objects ((IterateObjectCallbackFunc)check_major_refs_callback, NULL);
 }
 
 /* Check that the reference is valid */
 #undef HANDLE_PTR
 #define HANDLE_PTR(ptr,obj)    do {    \
                if (*(ptr)) {   \
-                       g_assert (mono_sgen_safe_name (*(ptr)) != NULL);        \
+                       g_assert (sgen_safe_name (*(ptr)) != NULL);     \
                }       \
        } while (0)
 
index 5eb2d17436ad9376a4ef5651059ef2b07b10f2c6..5652cf9f2f4f1ebcb04a9498075fb5951a895646 100644 (file)
@@ -70,7 +70,7 @@ alloc_complex_descriptor (gsize *bitmap, int numbits)
        numbits = ALIGN_TO (numbits, GC_BITS_PER_WORD);
        nwords = numbits / GC_BITS_PER_WORD + 1;
 
-       mono_sgen_gc_lock ();
+       sgen_gc_lock ();
        res = complex_descriptors_next;
        /* linear search, so we don't have duplicates with domain load/unload
         * this should not be performance critical or we'd have bigger issues
@@ -86,7 +86,7 @@ alloc_complex_descriptor (gsize *bitmap, int numbits)
                                }
                        }
                        if (found) {
-                               mono_sgen_gc_unlock ();
+                               sgen_gc_unlock ();
                                return i;
                        }
                }
@@ -104,12 +104,12 @@ alloc_complex_descriptor (gsize *bitmap, int numbits)
                complex_descriptors [res + 1 + i] = bitmap [i];
                DEBUG (6, fprintf (gc_debug_file, "\tvalue: %p\n", (void*)complex_descriptors [res + 1 + i]));
        }
-       mono_sgen_gc_unlock ();
+       sgen_gc_unlock ();
        return res;
 }
 
 gsize*
-mono_sgen_get_complex_descriptor (mword desc)
+sgen_get_complex_descriptor (mword desc)
 {
        return complex_descriptors + (desc >> LOW_TYPE_BITS);
 }
@@ -324,13 +324,13 @@ mono_gc_make_root_descr_user (MonoGCRootMarkFunc marker)
 }
 
 void*
-mono_sgen_get_complex_descriptor_bitmap (mword desc)
+sgen_get_complex_descriptor_bitmap (mword desc)
 {
        return complex_descriptors + (desc >> ROOT_DESC_TYPE_SHIFT);
 }
 
 MonoGCRootMarkFunc
-mono_sgen_get_user_descriptor_func (mword desc)
+sgen_get_user_descriptor_func (mword desc)
 {
        return user_descriptors [desc >> ROOT_DESC_TYPE_SHIFT];
 }
index 92873367cbfb6d68412567b29194dc61c03e11b2..5524377e7f8eae65b7908a775533c48568417b7f 100644 (file)
@@ -115,13 +115,13 @@ enum {
        ROOT_DESC_TYPE_SHIFT = 3,
 };
 
-gsize* mono_sgen_get_complex_descriptor (mword desc) MONO_INTERNAL;
-void* mono_sgen_get_complex_descriptor_bitmap (mword desc) MONO_INTERNAL;
-MonoGCRootMarkFunc mono_sgen_get_user_descriptor_func (mword desc) MONO_INTERNAL;
+gsize* sgen_get_complex_descriptor (mword desc) MONO_INTERNAL;
+void* sgen_get_complex_descriptor_bitmap (mword desc) MONO_INTERNAL;
+MonoGCRootMarkFunc sgen_get_user_descriptor_func (mword desc) MONO_INTERNAL;
 
 
 static inline gboolean
-mono_sgen_gc_descr_has_references (mword desc)
+sgen_gc_descr_has_references (mword desc)
 {
        /*Both string and fixed size objects are encoded using a zero run RUN_LEN*/
        if ((desc & 0xffff0007) == DESC_TYPE_RUN_LENGTH)
@@ -137,8 +137,8 @@ mono_sgen_gc_descr_has_references (mword desc)
        return TRUE;
 }
 
-#define SGEN_VTABLE_HAS_REFERENCES(vt) (mono_sgen_gc_descr_has_references ((mword)((MonoVTable*)(vt))->gc_descr))
-#define SGEN_CLASS_HAS_REFERENCES(c)   (mono_sgen_gc_descr_has_references ((mword)(c)->gc_descr))
+#define SGEN_VTABLE_HAS_REFERENCES(vt) (sgen_gc_descr_has_references ((mword)((MonoVTable*)(vt))->gc_descr))
+#define SGEN_CLASS_HAS_REFERENCES(c)   (sgen_gc_descr_has_references ((mword)(c)->gc_descr))
 
 /* helper macros to scan and traverse objects, macros because we resue them in many functions */
 #define OBJ_RUN_LEN_SIZE(size,desc,obj) do { \
@@ -204,7 +204,7 @@ mono_sgen_gc_descr_has_references (mword desc)
 #define OBJ_COMPLEX_FOREACH_PTR(vt,obj)        do {    \
                /* there are pointers */        \
                void **_objptr = (void**)(obj); \
-               gsize *bitmap_data = mono_sgen_get_complex_descriptor ((desc)); \
+               gsize *bitmap_data = sgen_get_complex_descriptor ((desc)); \
                int bwords = (*bitmap_data) - 1;        \
                void **start_run = _objptr;     \
                bitmap_data++;  \
@@ -230,7 +230,7 @@ mono_sgen_gc_descr_has_references (mword desc)
 /* this one is untested */
 #define OBJ_COMPLEX_ARR_FOREACH_PTR(vt,obj)    do {    \
                /* there are pointers */        \
-               gsize *mbitmap_data = mono_sgen_get_complex_descriptor ((vt)->desc); \
+               gsize *mbitmap_data = sgen_get_complex_descriptor ((vt)->desc); \
                int mbwords = (*mbitmap_data++) - 1;    \
                int el_size = mono_array_element_size (vt->klass);      \
                char *e_start = (char*)(obj) +  G_STRUCT_OFFSET (MonoArray, vector);    \
index 54adfa9e2a7b9745ed739b62b651bcd55398d661..e07aac69059c23d53973959121518a7227541a89 100644 (file)
@@ -57,11 +57,11 @@ get_finalize_entry_hash_table (int generation)
 
 /* LOCKING: requires that the GC lock is held */
 void
-mono_sgen_mark_bridge_object (MonoObject *obj)
+sgen_mark_bridge_object (MonoObject *obj)
 {
        SgenHashTable *hash_table = get_finalize_entry_hash_table (ptr_in_nursery (obj) ? GENERATION_NURSERY : GENERATION_OLD);
 
-       mono_sgen_hash_table_set_key (hash_table, obj, tagged_object_apply (obj, BRIDGE_OBJECT_MARKED));
+       sgen_hash_table_set_key (hash_table, obj, tagged_object_apply (obj, BRIDGE_OBJECT_MARKED));
 }
 
 /* LOCKING: requires that the GC lock is held */
@@ -89,23 +89,23 @@ collect_bridge_objects (CopyOrMarkObjectFunc copy_func, char *start, char *end,
                        continue;
 
                /* Nursery says the object is dead. */
-               if (!object_is_fin_ready (object))
+               if (!sgen_gc_is_object_ready_for_finalization (object))
                        continue;
 
-               if (!mono_sgen_is_bridge_object (object))
+               if (!sgen_is_bridge_object (object))
                        continue;
 
                copy = (char*)object;
                copy_func ((void**)&copy, queue);
 
-               mono_sgen_bridge_register_finalized_object ((MonoObject*)copy);
+               sgen_bridge_register_finalized_object ((MonoObject*)copy);
                
                if (hash_table == &minor_finalizable_hash && !ptr_in_nursery (copy)) {
                        /* remove from the list */
                        SGEN_HASH_TABLE_FOREACH_REMOVE (TRUE);
 
                        /* insert it into the major hash */
-                       mono_sgen_hash_table_replace (&major_finalizable_hash, tagged_object_apply (copy, tag), NULL);
+                       sgen_hash_table_replace (&major_finalizable_hash, tagged_object_apply (copy, tag), NULL, NULL);
 
                        DEBUG (5, fprintf (gc_debug_file, "Promoting finalization of object %p (%s) (was at %p) to major table\n", copy, safe_name (copy), object));
 
@@ -133,7 +133,7 @@ finalize_in_range (CopyOrMarkObjectFunc copy_func, char *start, char *end, int g
                int tag = tagged_object_get_tag (object);
                object = tagged_object_get_object (object);
                if ((char*)object >= start && (char*)object < end && !major_collector.is_object_live ((char*)object)) {
-                       gboolean is_fin_ready = object_is_fin_ready (object);
+                       gboolean is_fin_ready = sgen_gc_is_object_ready_for_finalization (object);
                        MonoObject *copy = object;
                        copy_func ((void**)&copy, queue);
                        if (is_fin_ready) {
@@ -142,7 +142,7 @@ finalize_in_range (CopyOrMarkObjectFunc copy_func, char *start, char *end, int g
                                num_ready_finalizers++;
                                queue_finalization_entry (copy);
                                /* Make it survive */
-                               DEBUG (5, fprintf (gc_debug_file, "Queueing object for finalization: %p (%s) (was at %p) (%d/%d)\n", copy, safe_name (copy), object, num_ready_finalizers, mono_sgen_hash_table_num_entries (hash_table)));
+                               DEBUG (5, fprintf (gc_debug_file, "Queueing object for finalization: %p (%s) (was at %p) (%d/%d)\n", copy, safe_name (copy), object, num_ready_finalizers, sgen_hash_table_num_entries (hash_table)));
                                continue;
                        } else {
                                if (hash_table == &minor_finalizable_hash && !ptr_in_nursery (copy)) {
@@ -150,7 +150,7 @@ finalize_in_range (CopyOrMarkObjectFunc copy_func, char *start, char *end, int g
                                        SGEN_HASH_TABLE_FOREACH_REMOVE (TRUE);
 
                                        /* insert it into the major hash */
-                                       mono_sgen_hash_table_replace (&major_finalizable_hash, tagged_object_apply (copy, tag), NULL);
+                                       sgen_hash_table_replace (&major_finalizable_hash, tagged_object_apply (copy, tag), NULL, NULL);
 
                                        DEBUG (5, fprintf (gc_debug_file, "Promoting finalization of object %p (%s) (was at %p) to major table\n", copy, safe_name (copy), object));
 
@@ -177,10 +177,10 @@ register_for_finalization (MonoObject *obj, void *user_data, int generation)
        g_assert (user_data == NULL || user_data == mono_gc_run_finalize);
 
        if (user_data) {
-               if (mono_sgen_hash_table_replace (hash_table, obj, NULL))
+               if (sgen_hash_table_replace (hash_table, obj, NULL, NULL))
                        DEBUG (5, fprintf (gc_debug_file, "Added finalizer for object: %p (%s) (%d) to %s table\n", obj, obj->vtable->klass->name, hash_table->num_entries, generation_name (generation)));
        } else {
-               if (mono_sgen_hash_table_remove (hash_table, obj, NULL))
+               if (sgen_hash_table_remove (hash_table, obj, NULL))
                        DEBUG (5, fprintf (gc_debug_file, "Removed finalizer for object: %p (%s) (%d)\n", obj, obj->vtable->klass->name, hash_table->num_entries));
        }
 }
@@ -312,7 +312,7 @@ finalizers_for_domain (MonoDomain *domain, MonoObject **out_array, int out_size,
                        /* remove and put in out_array */
                        SGEN_HASH_TABLE_FOREACH_REMOVE (TRUE);
                        out_array [count ++] = object;
-                       DEBUG (5, fprintf (gc_debug_file, "Collecting object for finalization: %p (%s) (%d/%d)\n", object, safe_name (object), num_ready_finalizers, mono_sgen_hash_table_num_entries (hash_table)));
+                       DEBUG (5, fprintf (gc_debug_file, "Collecting object for finalization: %p (%s) (%d/%d)\n", object, safe_name (object), num_ready_finalizers, sgen_hash_table_num_entries (hash_table)));
                        if (count == out_size)
                                return count;
                        continue;
@@ -371,14 +371,14 @@ add_or_remove_disappearing_link (MonoObject *obj, void **link, int generation)
        SgenHashTable *hash_table = get_dislink_hash_table (generation);
 
        if (!obj) {
-               if (mono_sgen_hash_table_remove (hash_table, link, NULL)) {
+               if (sgen_hash_table_remove (hash_table, link, NULL)) {
                        DEBUG (5, fprintf (gc_debug_file, "Removed dislink %p (%d) from %s table\n",
                                        link, hash_table->num_entries, generation_name (generation)));
                }
                return;
        }
 
-       mono_sgen_hash_table_replace (hash_table, link, NULL);
+       sgen_hash_table_replace (hash_table, link, NULL, NULL);
        DEBUG (5, fprintf (gc_debug_file, "Added dislink for object: %p (%s) at %p to %s table\n",
                        obj, obj->vtable->klass->name, link, generation_name (generation)));
 }
@@ -408,7 +408,7 @@ null_link_in_range (CopyOrMarkObjectFunc copy_func, char *start, char *end, int
                        object = DISLINK_OBJECT (link);
 
                        if (object >= start && object < end && !major_collector.is_object_live (object)) {
-                               if (object_is_fin_ready (object)) {
+                               if (sgen_gc_is_object_ready_for_finalization (object)) {
                                        *link = NULL;
                                        DEBUG (5, fprintf (gc_debug_file, "Dislink nullified at %p to GCed object %p\n", link, object));
                                        SGEN_HASH_TABLE_FOREACH_REMOVE (TRUE);
@@ -474,6 +474,26 @@ null_links_for_domain (MonoDomain *domain, int generation)
        } SGEN_HASH_TABLE_FOREACH_END;
 }
 
+static void
+remove_finalizers_for_domain (MonoDomain *domain, int generation)
+{
+       SgenHashTable *hash_table = get_finalize_entry_hash_table (generation);
+       MonoObject *object;
+       gpointer dummy;
+
+       SGEN_HASH_TABLE_FOREACH (hash_table, object, dummy) {
+               int tag = tagged_object_get_tag (object);
+               object = tagged_object_get_object (object);
+
+               if (mono_object_domain (object) == domain) {
+                       DEBUG (5, fprintf (gc_debug_file, "Unregistering finalizer for object: %p (%s)\n", object, safe_name (object)));
+
+                       SGEN_HASH_TABLE_FOREACH_REMOVE (TRUE);
+                       continue;
+               }
+       } SGEN_HASH_TABLE_FOREACH_END;  
+}
+
 /* LOCKING: requires that the GC lock is held */
 static void
 process_dislink_stage_entry (MonoObject *obj, void *_link)
index 295922e320f08c5720819871b3d902d143c6c501..54add9ee3aad7758743f7161f1cbd719bd4fd991 100644 (file)
 #include "config.h"
 #ifdef HAVE_SGEN_GC
 
+#ifdef __MACH__
+#undef _XOPEN_SOURCE
+#define _XOPEN_SOURCE
+#define _DARWIN_C_SOURCE
+#endif
+
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>
 #endif
 #include <signal.h>
 #include <errno.h>
 #include <assert.h>
-#ifdef __MACH__
-#undef _XOPEN_SOURCE
-#endif
-#ifdef __MACH__
-#define _XOPEN_SOURCE
-#endif
 
 #include "metadata/sgen-gc.h"
 #include "metadata/metadata-internals.h"
@@ -296,9 +296,12 @@ long long stat_objects_copied_major = 0;
 long long stat_scan_object_called_nursery = 0;
 long long stat_scan_object_called_major = 0;
 
+long long stat_slots_allocated_in_vain;
+
 long long stat_nursery_copy_object_failed_from_space = 0;
 long long stat_nursery_copy_object_failed_forwarded = 0;
 long long stat_nursery_copy_object_failed_pinned = 0;
+long long stat_nursery_copy_object_failed_to_space = 0;
 
 static int stat_wbarrier_set_field = 0;
 static int stat_wbarrier_set_arrayref = 0;
@@ -373,7 +376,7 @@ struct _RootRecord {
 #define pin_object             SGEN_PIN_OBJECT
 #define unpin_object           SGEN_UNPIN_OBJECT
 
-#define ptr_in_nursery mono_sgen_ptr_in_nursery
+#define ptr_in_nursery sgen_ptr_in_nursery
 
 #define LOAD_VTABLE    SGEN_LOAD_VTABLE
 
@@ -384,10 +387,10 @@ safe_name (void* obj)
        return vt->klass->name;
 }
 
-#define safe_object_get_size   mono_sgen_safe_object_get_size
+#define safe_object_get_size   sgen_safe_object_get_size
 
 const char*
-mono_sgen_safe_name (void* obj)
+sgen_safe_name (void* obj)
 {
        return safe_name (obj);
 }
@@ -407,7 +410,6 @@ static gboolean use_cardtable;
 #define SCAN_START_SIZE        SGEN_SCAN_START_SIZE
 
 static mword pagesize = 4096;
-static mword nursery_size;
 int degraded_mode = 0;
 
 static mword bytes_pinned_from_failed_allocation = 0;
@@ -569,7 +571,7 @@ static mword allocated_heap;
 static mword objects_pinned;
 
 void
-mono_sgen_release_space (mword size, int space)
+sgen_release_space (mword size, int space)
 {
        allocated_heap -= size;
 }
@@ -581,7 +583,7 @@ available_free_space (void)
 }
 
 gboolean
-mono_sgen_try_alloc_space (mword size, int space)
+sgen_try_alloc_space (mword size, int space)
 {
        if (available_free_space () < size)
                return FALSE;
@@ -605,11 +607,11 @@ init_heap_size_limits (glong max_heap, glong soft_limit)
                exit (1);
        }
 
-       if (max_heap < nursery_size * 4) {
+       if (max_heap < sgen_nursery_size * 4) {
                fprintf (stderr, "max-heap-size must be at least 4 times larger than nursery size.\n");
                exit (1);
        }
-       max_heap_size = max_heap - nursery_size;
+       max_heap_size = max_heap - sgen_nursery_size;
 }
 
 /*
@@ -644,6 +646,7 @@ static void finalize_in_range (CopyOrMarkObjectFunc copy_func, char *start, char
 static void process_fin_stage_entries (void);
 static void null_link_in_range (CopyOrMarkObjectFunc copy_func, char *start, char *end, int generation, gboolean before_finalization, GrayQueue *queue);
 static void null_links_for_domain (MonoDomain *domain, int generation);
+static void remove_finalizers_for_domain (MonoDomain *domain, int generation);
 static void process_dislink_stage_entries (void);
 
 static void pin_from_roots (void *start_nursery, void *end_nursery, GrayQueue *queue);
@@ -663,16 +666,18 @@ static int mark_ephemerons_in_range (CopyOrMarkObjectFunc copy_func, char *start
 static void clear_unreachable_ephemerons (CopyOrMarkObjectFunc copy_func, char *start, char *end, GrayQueue *queue);
 static void null_ephemerons_for_domain (MonoDomain *domain);
 
+SgenObjectOperations current_object_ops;
 SgenMajorCollector major_collector;
+SgenMinorCollector sgen_minor_collector;
 static GrayQueue gray_queue;
 
 static SgenRemeberedSet remset;
 
 
-#define WORKERS_DISTRIBUTE_GRAY_QUEUE (mono_sgen_collection_is_parallel () ? mono_sgen_workers_get_distribute_gray_queue () : &gray_queue)
+#define WORKERS_DISTRIBUTE_GRAY_QUEUE (sgen_collection_is_parallel () ? sgen_workers_get_distribute_gray_queue () : &gray_queue)
 
 static SgenGrayQueue*
-mono_sgen_workers_get_job_gray_queue (WorkerData *worker_data)
+sgen_workers_get_job_gray_queue (WorkerData *worker_data)
 {
        return worker_data ? &worker_data->private_gray_queue : WORKERS_DISTRIBUTE_GRAY_QUEUE;
 }
@@ -810,7 +815,7 @@ scan_object_for_specific_ref (char *start, MonoObject *key)
 }
 
 void
-mono_sgen_scan_area_with_callback (char *start, char *end, IterateObjectCallbackFunc callback, void *data, gboolean allow_flags)
+sgen_scan_area_with_callback (char *start, char *end, IterateObjectCallbackFunc callback, void *data, gboolean allow_flags)
 {
        while (start < end) {
                size_t size;
@@ -883,7 +888,7 @@ scan_roots_for_specific_ref (MonoObject *key, int root_type)
                        }
                        return;
                case ROOT_DESC_COMPLEX: {
-                       gsize *bitmap_data = mono_sgen_get_complex_descriptor_bitmap (desc);
+                       gsize *bitmap_data = sgen_get_complex_descriptor_bitmap (desc);
                        int bwords = (*bitmap_data) - 1;
                        void **start_run = start_root;
                        bitmap_data++;
@@ -901,7 +906,7 @@ scan_roots_for_specific_ref (MonoObject *key, int root_type)
                        break;
                }
                case ROOT_DESC_USER: {
-                       MonoGCRootMarkFunc marker = mono_sgen_get_user_descriptor_func (desc);
+                       MonoGCRootMarkFunc marker = sgen_get_user_descriptor_func (desc);
                        marker (start_root, check_root_obj_specific_ref_from_marker);
                        break;
                }
@@ -924,12 +929,12 @@ mono_gc_scan_for_specific_ref (MonoObject *key, gboolean precise)
 
        scan_object_for_specific_ref_precise = precise;
 
-       mono_sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data,
+       sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data,
                        (IterateObjectCallbackFunc)scan_object_for_specific_ref_callback, key, TRUE);
 
        major_collector.iterate_objects (TRUE, TRUE, (IterateObjectCallbackFunc)scan_object_for_specific_ref_callback, key);
 
-       mono_sgen_los_iterate_objects ((IterateObjectCallbackFunc)scan_object_for_specific_ref_callback, key);
+       sgen_los_iterate_objects ((IterateObjectCallbackFunc)scan_object_for_specific_ref_callback, key);
 
        scan_roots_for_specific_ref (key, ROOT_TYPE_NORMAL);
        scan_roots_for_specific_ref (key, ROOT_TYPE_WBARRIER);
@@ -1007,7 +1012,7 @@ scan_for_registered_roots_in_domain (MonoDomain *domain, int root_type)
                        }
                        break;
                case ROOT_DESC_COMPLEX: {
-                       gsize *bitmap_data = mono_sgen_get_complex_descriptor_bitmap (desc);
+                       gsize *bitmap_data = sgen_get_complex_descriptor_bitmap (desc);
                        int bwords = (*bitmap_data) - 1;
                        void **start_run = start_root;
                        bitmap_data++;
@@ -1025,7 +1030,7 @@ scan_for_registered_roots_in_domain (MonoDomain *domain, int root_type)
                        break;
                }
                case ROOT_DESC_USER: {
-                       MonoGCRootMarkFunc marker = mono_sgen_get_user_descriptor_func (desc);
+                       MonoGCRootMarkFunc marker = sgen_get_user_descriptor_func (desc);
                        marker (start_root, check_obj_not_in_domain);
                        break;
                }
@@ -1044,7 +1049,7 @@ check_for_xdomain_refs (void)
 {
        LOSObject *bigobj;
 
-       mono_sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data,
+       sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data,
                        (IterateObjectCallbackFunc)scan_object_for_xdomain_refs, NULL, FALSE);
 
        major_collector.iterate_objects (TRUE, TRUE, (IterateObjectCallbackFunc)scan_object_for_xdomain_refs, NULL);
@@ -1117,7 +1122,7 @@ mono_gc_clear_domain (MonoDomain * domain)
        process_fin_stage_entries ();
        process_dislink_stage_entries ();
 
-       mono_sgen_clear_nursery_fragments ();
+       sgen_clear_nursery_fragments ();
 
        if (xdomain_checks && domain != mono_get_root_domain ()) {
                scan_for_registered_roots_in_domain (domain, ROOT_TYPE_NORMAL);
@@ -1125,9 +1130,6 @@ mono_gc_clear_domain (MonoDomain * domain)
                check_for_xdomain_refs ();
        }
 
-       mono_sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data,
-                       (IterateObjectCallbackFunc)clear_domain_process_minor_object_callback, domain, FALSE);
-
        /*Ephemerons and dislinks must be processed before LOS since they might end up pointing
        to memory returned to the OS.*/
        null_ephemerons_for_domain (domain);
@@ -1135,6 +1137,12 @@ mono_gc_clear_domain (MonoDomain * domain)
        for (i = GENERATION_NURSERY; i < GENERATION_MAX; ++i)
                null_links_for_domain (domain, i);
 
+       for (i = GENERATION_NURSERY; i < GENERATION_MAX; ++i)
+               remove_finalizers_for_domain (domain, i);
+
+       sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data,
+                       (IterateObjectCallbackFunc)clear_domain_process_minor_object_callback, domain, FALSE);
+
        /* We need two passes over major and large objects because
           freeing such objects might give their memory back to the OS
           (in the case of large objects) or obliterate its vtable
@@ -1157,7 +1165,7 @@ mono_gc_clear_domain (MonoDomain * domain)
                        bigobj = bigobj->next;
                        DEBUG (4, fprintf (gc_debug_file, "Freeing large object %p\n",
                                        bigobj->data));
-                       mono_sgen_los_free_object (to_free);
+                       sgen_los_free_object (to_free);
                        continue;
                }
                prev = bigobj;
@@ -1168,14 +1176,14 @@ mono_gc_clear_domain (MonoDomain * domain)
 
        if (G_UNLIKELY (do_pin_stats)) {
                if (domain == mono_get_root_domain ())
-                       mono_sgen_pin_stats_print_class_stats ();
+                       sgen_pin_stats_print_class_stats ();
        }
 
        UNLOCK_GC;
 }
 
 /*
- * mono_sgen_add_to_global_remset:
+ * sgen_add_to_global_remset:
  *
  *   The global remset contains locations which point into newspace after
  * a minor collection. This can happen if the objects they point to are pinned.
@@ -1184,26 +1192,25 @@ mono_gc_clear_domain (MonoDomain * domain)
  * lock must be held.  For serial collectors that is not necessary.
  */
 void
-mono_sgen_add_to_global_remset (gpointer ptr)
+sgen_add_to_global_remset (gpointer ptr)
 {
        remset.record_pointer (ptr);
 }
 
 /*
- * mono_sgen_drain_gray_stack:
+ * sgen_drain_gray_stack:
  *
  *   Scan objects in the gray stack until the stack is empty. This should be called
  * frequently after each object is copied, to achieve better locality and cache
  * usage.
  */
 gboolean
-mono_sgen_drain_gray_stack (GrayQueue *queue, int max_objs)
+sgen_drain_gray_stack (GrayQueue *queue, int max_objs)
 {
        char *obj;
+       ScanObjectFunc scan_func = current_object_ops.scan_object;
 
-       if (current_collection_generation == GENERATION_NURSERY) {
-               ScanObjectFunc scan_func = mono_sgen_get_minor_scan_object ();
-
+       if (max_objs == -1) {
                for (;;) {
                        GRAY_OBJECT_DEQUEUE (queue, obj);
                        if (!obj)
@@ -1214,16 +1221,13 @@ mono_sgen_drain_gray_stack (GrayQueue *queue, int max_objs)
        } else {
                int i;
 
-               if (mono_sgen_collection_is_parallel () && mono_sgen_workers_is_distributed_queue (queue))
-                       return TRUE;
-
                do {
                        for (i = 0; i != max_objs; ++i) {
                                GRAY_OBJECT_DEQUEUE (queue, obj);
                                if (!obj)
                                        return TRUE;
                                DEBUG (9, fprintf (gc_debug_file, "Precise gray object scan %p (%s)\n", obj, safe_name (obj)));
-                               major_collector.major_scan_object (obj, queue);
+                               scan_func (obj, queue);
                        }
                } while (max_objs < 0);
                return FALSE;
@@ -1249,7 +1253,7 @@ pin_objects_from_addresses (GCMemSection *section, void **start, void **end, voi
        int idx;
        void **definitely_pinned = start;
 
-       mono_sgen_nursery_allocator_prepare_for_pinning ();
+       sgen_nursery_allocator_prepare_for_pinning ();
 
        while (start < end) {
                addr = *start;
@@ -1306,7 +1310,7 @@ pin_objects_from_addresses (GCMemSection *section, void **start, void **end, voi
                                                pin_object (search_start);
                                                GRAY_OBJECT_ENQUEUE (queue, search_start);
                                                if (G_UNLIKELY (do_pin_stats))
-                                                       mono_sgen_pin_stats_register_object (search_start, last_obj_size);
+                                                       sgen_pin_stats_register_object (search_start, last_obj_size);
                                                definitely_pinned [count] = search_start;
                                                count++;
                                                break;
@@ -1335,7 +1339,7 @@ pin_objects_from_addresses (GCMemSection *section, void **start, void **end, voi
 }
 
 void
-mono_sgen_pin_objects_in_section (GCMemSection *section, GrayQueue *queue)
+sgen_pin_objects_in_section (GCMemSection *section, GrayQueue *queue)
 {
        int num_entries = section->pin_queue_num_entries;
        if (num_entries) {
@@ -1351,30 +1355,60 @@ mono_sgen_pin_objects_in_section (GCMemSection *section, GrayQueue *queue)
 
 
 void
-mono_sgen_pin_object (void *object, GrayQueue *queue)
+sgen_pin_object (void *object, GrayQueue *queue)
 {
-       if (mono_sgen_collection_is_parallel ()) {
+       if (sgen_collection_is_parallel ()) {
                LOCK_PIN_QUEUE;
                /*object arrives pinned*/
-               mono_sgen_pin_stage_ptr (object);
+               sgen_pin_stage_ptr (object);
                ++objects_pinned ;
                UNLOCK_PIN_QUEUE;
        } else {
                SGEN_PIN_OBJECT (object);
-               mono_sgen_pin_stage_ptr (object);
+               sgen_pin_stage_ptr (object);
                ++objects_pinned;
                if (G_UNLIKELY (do_pin_stats))
-                       mono_sgen_pin_stats_register_object (object, safe_object_get_size (object));
+                       sgen_pin_stats_register_object (object, safe_object_get_size (object));
        }
        GRAY_OBJECT_ENQUEUE (queue, object);
        binary_protocol_pin (object, (gpointer)LOAD_VTABLE (object), safe_object_get_size (object));
 }
 
+void
+sgen_parallel_pin_or_update (void **ptr, void *obj, MonoVTable *vt, SgenGrayQueue *queue)
+{
+       for (;;) {
+               mword vtable_word;
+               gboolean major_pinned = FALSE;
+
+               if (sgen_ptr_in_nursery (obj)) {
+                       if (SGEN_CAS_PTR (obj, (void*)((mword)vt | SGEN_PINNED_BIT), vt) == vt) {
+                               sgen_pin_object (obj, queue);
+                               break;
+                       }
+               } else {
+                       major_collector.pin_major_object (obj, queue);
+                       major_pinned = TRUE;
+               }
+
+               vtable_word = *(mword*)obj;
+               /*someone else forwarded it, update the pointer and bail out*/
+               if (vtable_word & SGEN_FORWARDED_BIT) {
+                       *ptr = (void*)(vtable_word & ~SGEN_VTABLE_BITS_MASK);
+                       break;
+               }
+
+               /*someone pinned it, nothing to do.*/
+               if (vtable_word & SGEN_PINNED_BIT || major_pinned)
+                       break;
+       }
+}
+
 /* Sort the addresses in array in increasing order.
  * Done using a by-the book heap sort. Which has decent and stable performance, is pretty cache efficient.
  */
 void
-mono_sgen_sort_addresses (void **array, int size)
+sgen_sort_addresses (void **array, int size)
 {
        int i;
        void *tmp;
@@ -1452,10 +1486,10 @@ conservatively_pin_objects_from (void **start, void **end, void *start_nursery,
                        mword addr = (mword)*start;
                        addr &= ~(ALLOC_ALIGN - 1);
                        if (addr >= (mword)start_nursery && addr < (mword)end_nursery)
-                               mono_sgen_pin_stage_ptr ((void*)addr);
+                               sgen_pin_stage_ptr ((void*)addr);
                        if (G_UNLIKELY (do_pin_stats)) { 
                                if (ptr_in_nursery ((void*)addr))
-                                       mono_sgen_pin_stats_register_address ((char*)addr, pin_type);
+                                       sgen_pin_stats_register_address ((char*)addr, pin_type);
                        }
                        DEBUG (6, if (count) fprintf (gc_debug_file, "Pinning address %p from %p\n", (void*)addr, start));
                        count++;
@@ -1561,14 +1595,14 @@ precisely_scan_objects_from (CopyOrMarkObjectFunc copy_func, void** start_root,
                        if ((desc & 1) && *start_root) {
                                copy_func (start_root, queue);
                                DEBUG (9, fprintf (gc_debug_file, "Overwrote root at %p with %p\n", start_root, *start_root));
-                               mono_sgen_drain_gray_stack (queue, -1);
+                               sgen_drain_gray_stack (queue, -1);
                        }
                        desc >>= 1;
                        start_root++;
                }
                return;
        case ROOT_DESC_COMPLEX: {
-               gsize *bitmap_data = mono_sgen_get_complex_descriptor_bitmap (desc);
+               gsize *bitmap_data = sgen_get_complex_descriptor_bitmap (desc);
                int bwords = (*bitmap_data) - 1;
                void **start_run = start_root;
                bitmap_data++;
@@ -1579,7 +1613,7 @@ precisely_scan_objects_from (CopyOrMarkObjectFunc copy_func, void** start_root,
                                if ((bmap & 1) && *objptr) {
                                        copy_func (objptr, queue);
                                        DEBUG (9, fprintf (gc_debug_file, "Overwrote root at %p with %p\n", objptr, *objptr));
-                                       mono_sgen_drain_gray_stack (queue, -1);
+                                       sgen_drain_gray_stack (queue, -1);
                                }
                                bmap >>= 1;
                                ++objptr;
@@ -1590,7 +1624,7 @@ precisely_scan_objects_from (CopyOrMarkObjectFunc copy_func, void** start_root,
        }
        case ROOT_DESC_USER: {
                UserCopyOrMarkData data = { copy_func, queue };
-               MonoGCRootMarkFunc marker = mono_sgen_get_user_descriptor_func (desc);
+               MonoGCRootMarkFunc marker = sgen_get_user_descriptor_func (desc);
                set_user_copy_or_mark_data (&data);
                marker (start_root, single_arg_user_copy_or_mark);
                set_user_copy_or_mark_data (NULL);
@@ -1611,7 +1645,7 @@ reset_heap_boundaries (void)
 }
 
 void
-mono_sgen_update_heap_boundaries (mword low, mword high)
+sgen_update_heap_boundaries (mword low, mword high)
 {
        mword old;
 
@@ -1640,7 +1674,7 @@ prot_flags_for_activate (int activate)
  * This must not require any lock.
  */
 void*
-mono_sgen_alloc_os_memory (size_t size, int activate)
+sgen_alloc_os_memory (size_t size, int activate)
 {
        void *ptr = mono_valloc (0, size, prot_flags_for_activate (activate));
        if (ptr) {
@@ -1652,7 +1686,7 @@ mono_sgen_alloc_os_memory (size_t size, int activate)
 
 /* size must be a power of 2 */
 void*
-mono_sgen_alloc_os_memory_aligned (mword size, mword alignment, gboolean activate)
+sgen_alloc_os_memory_aligned (mword size, mword alignment, gboolean activate)
 {
        void *ptr = mono_valloc_aligned (size, alignment, prot_flags_for_activate (activate));
        if (ptr) {
@@ -1663,10 +1697,10 @@ mono_sgen_alloc_os_memory_aligned (mword size, mword alignment, gboolean activat
 }
 
 /*
- * Free the memory returned by mono_sgen_alloc_os_memory (), returning it to the OS.
+ * Free the memory returned by sgen_alloc_os_memory (), returning it to the OS.
  */
 void
-mono_sgen_free_os_memory (void *addr, size_t size)
+sgen_free_os_memory (void *addr, size_t size)
 {
        mono_vfree (addr, size);
        /* FIXME: CAS */
@@ -1687,47 +1721,46 @@ alloc_nursery (void)
 
        if (nursery_section)
                return;
-       DEBUG (2, fprintf (gc_debug_file, "Allocating nursery size: %lu\n", (unsigned long)nursery_size));
+       DEBUG (2, fprintf (gc_debug_file, "Allocating nursery size: %lu\n", (unsigned long)sgen_nursery_size));
        /* later we will alloc a larger area for the nursery but only activate
         * what we need. The rest will be used as expansion if we have too many pinned
         * objects in the existing nursery.
         */
        /* FIXME: handle OOM */
-       section = mono_sgen_alloc_internal (INTERNAL_MEM_SECTION);
+       section = sgen_alloc_internal (INTERNAL_MEM_SECTION);
 
-       g_assert (nursery_size == DEFAULT_NURSERY_SIZE);
-       alloc_size = nursery_size;
+       alloc_size = sgen_nursery_size;
 #ifdef SGEN_ALIGN_NURSERY
        data = major_collector.alloc_heap (alloc_size, alloc_size, DEFAULT_NURSERY_BITS);
 #else
        data = major_collector.alloc_heap (alloc_size, 0, DEFAULT_NURSERY_BITS);
 #endif
-       mono_sgen_update_heap_boundaries ((mword)data, (mword)(data + nursery_size));
-       DEBUG (4, fprintf (gc_debug_file, "Expanding nursery size (%p-%p): %lu, total: %lu\n", data, data + alloc_size, (unsigned long)nursery_size, (unsigned long)total_alloc));
+       sgen_update_heap_boundaries ((mword)data, (mword)(data + sgen_nursery_size));
+       DEBUG (4, fprintf (gc_debug_file, "Expanding nursery size (%p-%p): %lu, total: %lu\n", data, data + alloc_size, (unsigned long)sgen_nursery_size, (unsigned long)total_alloc));
        section->data = section->next_data = data;
        section->size = alloc_size;
-       section->end_data = data + nursery_size;
+       section->end_data = data + sgen_nursery_size;
        scan_starts = (alloc_size + SCAN_START_SIZE - 1) / SCAN_START_SIZE;
-       section->scan_starts = mono_sgen_alloc_internal_dynamic (sizeof (char*) * scan_starts, INTERNAL_MEM_SCAN_STARTS);
+       section->scan_starts = sgen_alloc_internal_dynamic (sizeof (char*) * scan_starts, INTERNAL_MEM_SCAN_STARTS);
        section->num_scan_start = scan_starts;
        section->block.role = MEMORY_ROLE_GEN0;
        section->block.next = NULL;
 
        nursery_section = section;
 
-       mono_sgen_nursery_allocator_set_nursery_bounds (data, data + nursery_size);
+       sgen_nursery_allocator_set_nursery_bounds (data, data + sgen_nursery_size);
 }
 
 void*
 mono_gc_get_nursery (int *shift_bits, size_t *size)
 {
-       *size = nursery_size;
+       *size = sgen_nursery_size;
 #ifdef SGEN_ALIGN_NURSERY
        *shift_bits = DEFAULT_NURSERY_BITS;
 #else
        *shift_bits = -1;
 #endif
-       return mono_sgen_get_nursery_start ();
+       return sgen_get_nursery_start ();
 }
 
 void
@@ -1751,7 +1784,7 @@ mono_gc_precise_stack_mark_enabled (void)
 FILE *
 mono_gc_get_logfile (void)
 {
-       return mono_sgen_get_logfile ();
+       return sgen_get_logfile ();
 }
 
 static void
@@ -1800,7 +1833,7 @@ precisely_report_roots_from (GCRootReport *report, void** start_root, void** end
                }
                return;
        case ROOT_DESC_COMPLEX: {
-               gsize *bitmap_data = mono_sgen_get_complex_descriptor_bitmap (desc);
+               gsize *bitmap_data = sgen_get_complex_descriptor_bitmap (desc);
                int bwords = (*bitmap_data) - 1;
                void **start_run = start_root;
                bitmap_data++;
@@ -1819,7 +1852,7 @@ precisely_report_roots_from (GCRootReport *report, void** start_root, void** end
                break;
        }
        case ROOT_DESC_USER: {
-               MonoGCRootMarkFunc marker = mono_sgen_get_user_descriptor_func (desc);
+               MonoGCRootMarkFunc marker = sgen_get_user_descriptor_func (desc);
                root_report = report;
                marker (start_root, single_arg_report_root);
                break;
@@ -1879,49 +1912,20 @@ generation_name (int generation)
 static void
 stw_bridge_process (void)
 {
-       mono_sgen_bridge_processing_stw_step ();
+       sgen_bridge_processing_stw_step ();
 }
 
 static void
 bridge_process (void)
 {
-       mono_sgen_bridge_processing_finish ();
-}
-
-CopyOrMarkObjectFunc
-mono_sgen_get_copy_object (void)
-{
-       if (current_collection_generation == GENERATION_NURSERY) {
-               if (mono_sgen_collection_is_parallel ())
-                       return major_collector.copy_object;
-               else
-                       return major_collector.nopar_copy_object;
-       } else {
-               return major_collector.copy_or_mark_object;
-       }
+       sgen_bridge_processing_finish ();
 }
 
-ScanObjectFunc
-mono_sgen_get_minor_scan_object (void)
-{
-       g_assert (current_collection_generation == GENERATION_NURSERY);
-
-       if (mono_sgen_collection_is_parallel ())
-               return major_collector.minor_scan_object;
-       else
-               return major_collector.nopar_minor_scan_object;
+SgenObjectOperations *
+sgen_get_current_object_ops (void){
+       return &current_object_ops;
 }
 
-ScanVTypeFunc
-mono_sgen_get_minor_scan_vtype (void)
-{
-       g_assert (current_collection_generation == GENERATION_NURSERY);
-
-       if (mono_sgen_collection_is_parallel ())
-               return major_collector.minor_scan_vtype;
-       else
-               return major_collector.nopar_minor_scan_vtype;
-}
 
 static void
 finish_gray_stack (char *start_addr, char *end_addr, int generation, GrayQueue *queue)
@@ -1929,7 +1933,7 @@ finish_gray_stack (char *start_addr, char *end_addr, int generation, GrayQueue *
        TV_DECLARE (atv);
        TV_DECLARE (btv);
        int done_with_ephemerons, ephemeron_rounds = 0;
-       CopyOrMarkObjectFunc copy_func = mono_sgen_get_copy_object ();
+       CopyOrMarkObjectFunc copy_func = current_object_ops.copy_or_mark_object;
 
        /*
         * We copied all the reachable objects. Now it's the time to copy
@@ -1944,7 +1948,7 @@ finish_gray_stack (char *start_addr, char *end_addr, int generation, GrayQueue *
         *   To achieve better cache locality and cache usage, we drain the gray stack 
         * frequently, after each object is copied, and just finish the work here.
         */
-       mono_sgen_drain_gray_stack (queue, -1);
+       sgen_drain_gray_stack (queue, -1);
        TV_GETTIME (atv);
        DEBUG (2, fprintf (gc_debug_file, "%s generation done\n", generation_name (generation)));
 
@@ -1955,7 +1959,7 @@ finish_gray_stack (char *start_addr, char *end_addr, int generation, GrayQueue *
        We must reset the gathered bridges since their original block might be evacuated due to major
        fragmentation in the meanwhile and the bridge code should not have to deal with that.
        */
-       mono_sgen_bridge_reset_data ();
+       sgen_bridge_reset_data ();
 
        /*
         * Walk the ephemeron tables marking all values with reachable keys. This must be completely done
@@ -1965,21 +1969,26 @@ finish_gray_stack (char *start_addr, char *end_addr, int generation, GrayQueue *
        done_with_ephemerons = 0;
        do {
                done_with_ephemerons = mark_ephemerons_in_range (copy_func, start_addr, end_addr, queue);
-               mono_sgen_drain_gray_stack (queue, -1);
+               sgen_drain_gray_stack (queue, -1);
                ++ephemeron_rounds;
        } while (!done_with_ephemerons);
 
-       mono_sgen_scan_togglerefs (copy_func, start_addr, end_addr, queue);
+       sgen_scan_togglerefs (copy_func, start_addr, end_addr, queue);
        if (generation == GENERATION_OLD)
-               mono_sgen_scan_togglerefs (copy_func, mono_sgen_get_nursery_start (), mono_sgen_get_nursery_end (), queue);
+               sgen_scan_togglerefs (copy_func, sgen_get_nursery_start (), sgen_get_nursery_end (), queue);
 
-       if (mono_sgen_need_bridge_processing ()) {
+       if (sgen_need_bridge_processing ()) {
                collect_bridge_objects (copy_func, start_addr, end_addr, generation, queue);
                if (generation == GENERATION_OLD)
-                       collect_bridge_objects (copy_func, mono_sgen_get_nursery_start (), mono_sgen_get_nursery_end (), GENERATION_NURSERY, queue);
-               mono_sgen_drain_gray_stack (queue, -1);
+                       collect_bridge_objects (copy_func, sgen_get_nursery_start (), sgen_get_nursery_end (), GENERATION_NURSERY, queue);
        }
 
+       /*
+       Make sure we drain the gray stack before processing disappearing links and finalizers.
+       If we don't make sure it is empty we might wrongly see a live object as dead.
+       */
+       sgen_drain_gray_stack (queue, -1);
+
        /*
        We must clear weak links that don't track resurrection before processing object ready for
        finalization so they can be cleared before that.
@@ -1996,10 +2005,10 @@ finish_gray_stack (char *start_addr, char *end_addr, int generation, GrayQueue *
         */
        finalize_in_range (copy_func, start_addr, end_addr, generation, queue);
        if (generation == GENERATION_OLD)
-               finalize_in_range (copy_func, mono_sgen_get_nursery_start (), mono_sgen_get_nursery_end (), GENERATION_NURSERY, queue);
+               finalize_in_range (copy_func, sgen_get_nursery_start (), sgen_get_nursery_end (), GENERATION_NURSERY, queue);
        /* drain the new stack that might have been created */
        DEBUG (6, fprintf (gc_debug_file, "Precise scan of gray area post fin\n"));
-       mono_sgen_drain_gray_stack (queue, -1);
+       sgen_drain_gray_stack (queue, -1);
 
        /*
         * This must be done again after processing finalizable objects since CWL slots are cleared only after the key is finalized.
@@ -2007,7 +2016,7 @@ finish_gray_stack (char *start_addr, char *end_addr, int generation, GrayQueue *
        done_with_ephemerons = 0;
        do {
                done_with_ephemerons = mark_ephemerons_in_range (copy_func, start_addr, end_addr, queue);
-               mono_sgen_drain_gray_stack (queue, -1);
+               sgen_drain_gray_stack (queue, -1);
                ++ephemeron_rounds;
        } while (!done_with_ephemerons);
 
@@ -2028,21 +2037,21 @@ finish_gray_stack (char *start_addr, char *end_addr, int generation, GrayQueue *
         * GC a finalized object my lose the monitor because it is cleared before the finalizer is
         * called.
         */
-       g_assert (mono_sgen_gray_object_queue_is_empty (queue));
+       g_assert (sgen_gray_object_queue_is_empty (queue));
        for (;;) {
                null_link_in_range (copy_func, start_addr, end_addr, generation, FALSE, queue);
                if (generation == GENERATION_OLD)
                        null_link_in_range (copy_func, start_addr, end_addr, GENERATION_NURSERY, FALSE, queue);
-               if (mono_sgen_gray_object_queue_is_empty (queue))
+               if (sgen_gray_object_queue_is_empty (queue))
                        break;
-               mono_sgen_drain_gray_stack (queue, -1);
+               sgen_drain_gray_stack (queue, -1);
        }
 
-       g_assert (mono_sgen_gray_object_queue_is_empty (queue));
+       g_assert (sgen_gray_object_queue_is_empty (queue));
 }
 
 void
-mono_sgen_check_section_scan_starts (GCMemSection *section)
+sgen_check_section_scan_starts (GCMemSection *section)
 {
        int i;
        for (i = 0; i < section->num_scan_start; ++i) {
@@ -2058,7 +2067,7 @@ check_scan_starts (void)
 {
        if (!do_scan_starts_check)
                return;
-       mono_sgen_check_section_scan_starts (nursery_section);
+       sgen_check_section_scan_starts (nursery_section);
        major_collector.check_scan_starts ();
 }
 
@@ -2074,13 +2083,13 @@ scan_from_registered_roots (CopyOrMarkObjectFunc copy_func, char *addr_start, ch
 }
 
 void
-mono_sgen_dump_occupied (char *start, char *end, char *section_start)
+sgen_dump_occupied (char *start, char *end, char *section_start)
 {
        fprintf (heap_dump_file, "<occupied offset=\"%td\" size=\"%td\"/>\n", start - section_start, end - start);
 }
 
 void
-mono_sgen_dump_section (GCMemSection *section, const char *type)
+sgen_dump_section (GCMemSection *section, const char *type)
 {
        char *start = section->data;
        char *end = section->data + section->size;
@@ -2096,7 +2105,7 @@ mono_sgen_dump_section (GCMemSection *section, const char *type)
 
                if (!*(void**)start) {
                        if (occ_start) {
-                               mono_sgen_dump_occupied (occ_start, start, section->data);
+                               sgen_dump_occupied (occ_start, start, section->data);
                                occ_start = NULL;
                        }
                        start += sizeof (void*); /* should be ALLOC_ALIGN, really */
@@ -2123,7 +2132,7 @@ mono_sgen_dump_section (GCMemSection *section, const char *type)
                start += size;
        }
        if (occ_start)
-               mono_sgen_dump_occupied (occ_start, start, section->data);
+               sgen_dump_occupied (occ_start, start, section->data);
 
        fprintf (heap_dump_file, "</section>\n");
 }
@@ -2176,17 +2185,17 @@ dump_heap (const char *type, int num, const char *reason)
                fprintf (heap_dump_file, " reason=\"%s\"", reason);
        fprintf (heap_dump_file, ">\n");
        fprintf (heap_dump_file, "<other-mem-usage type=\"mempools\" size=\"%ld\"/>\n", mono_mempool_get_bytes_allocated ());
-       mono_sgen_dump_internal_mem_usage (heap_dump_file);
-       fprintf (heap_dump_file, "<pinned type=\"stack\" bytes=\"%zu\"/>\n", mono_sgen_pin_stats_get_pinned_byte_count (PIN_TYPE_STACK));
+       sgen_dump_internal_mem_usage (heap_dump_file);
+       fprintf (heap_dump_file, "<pinned type=\"stack\" bytes=\"%zu\"/>\n", sgen_pin_stats_get_pinned_byte_count (PIN_TYPE_STACK));
        /* fprintf (heap_dump_file, "<pinned type=\"static-data\" bytes=\"%d\"/>\n", pinned_byte_counts [PIN_TYPE_STATIC_DATA]); */
-       fprintf (heap_dump_file, "<pinned type=\"other\" bytes=\"%zu\"/>\n", mono_sgen_pin_stats_get_pinned_byte_count (PIN_TYPE_OTHER));
+       fprintf (heap_dump_file, "<pinned type=\"other\" bytes=\"%zu\"/>\n", sgen_pin_stats_get_pinned_byte_count (PIN_TYPE_OTHER));
 
        fprintf (heap_dump_file, "<pinned-objects>\n");
-       for (list = mono_sgen_pin_stats_get_object_list (); list; list = list->next)
+       for (list = sgen_pin_stats_get_object_list (); list; list = list->next)
                dump_object (list->obj, TRUE);
        fprintf (heap_dump_file, "</pinned-objects>\n");
 
-       mono_sgen_dump_section (nursery_section, "nursery");
+       sgen_dump_section (nursery_section, "nursery");
 
        major_collector.dump_heap (heap_dump_file);
 
@@ -2199,12 +2208,12 @@ dump_heap (const char *type, int num, const char *reason)
 }
 
 void
-mono_sgen_register_moved_object (void *obj, void *destination)
+sgen_register_moved_object (void *obj, void *destination)
 {
        g_assert (mono_profiler_events & MONO_PROFILE_GC_MOVES);
 
        /* FIXME: handle this for parallel collector */
-       g_assert (!mono_sgen_collection_is_parallel ());
+       g_assert (!sgen_collection_is_parallel ());
 
        if (moved_objects_idx == MOVED_OBJECTS_NUM) {
                mono_profiler_gc_moves (moved_objects, moved_objects_idx);
@@ -2267,12 +2276,15 @@ init_stats (void)
        mono_counters_register ("# scan_object() called (nursery)", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_scan_object_called_nursery);
        mono_counters_register ("# scan_object() called (major)", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_scan_object_called_major);
 
+       mono_counters_register ("Slots allocated in vain", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_slots_allocated_in_vain);
+
        mono_counters_register ("# nursery copy_object() failed from space", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_nursery_copy_object_failed_from_space);
        mono_counters_register ("# nursery copy_object() failed forwarded", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_nursery_copy_object_failed_forwarded);
        mono_counters_register ("# nursery copy_object() failed pinned", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_nursery_copy_object_failed_pinned);
+       mono_counters_register ("# nursery copy_object() failed to space", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_nursery_copy_object_failed_to_space);
 
-       mono_sgen_nursery_allocator_init_heavy_stats ();
-       mono_sgen_alloc_init_heavy_stats ();
+       sgen_nursery_allocator_init_heavy_stats ();
+       sgen_alloc_init_heavy_stats ();
 #endif
 
        inited = TRUE;
@@ -2354,11 +2366,11 @@ try_calculate_minor_collection_allowance (gboolean overwrite)
        if (debug_print_allowance) {
                mword old_major = last_collection_old_num_major_sections * major_collector.section_size;
 
-               fprintf (gc_debug_file, "Before collection: %ld bytes (%ld major, %ld LOS)\n",
+               fprintf (gc_debug_file, "Before collection: %td bytes (%td major, %td LOS)\n",
                                old_major + last_collection_old_los_memory_usage, old_major, last_collection_old_los_memory_usage);
-               fprintf (gc_debug_file, "After collection: %ld bytes (%ld major, %ld LOS)\n",
+               fprintf (gc_debug_file, "After collection: %td bytes (%td major, %td LOS)\n",
                                new_heap_size, new_major, last_collection_los_memory_usage);
-               fprintf (gc_debug_file, "Allowance: %ld bytes\n", minor_collection_allowance);
+               fprintf (gc_debug_file, "Allowance: %td bytes\n", minor_collection_allowance);
        }
 
        if (major_collector.have_computed_minor_collection_allowance)
@@ -2376,7 +2388,7 @@ need_major_collection (mword space_needed)
 }
 
 gboolean
-mono_sgen_need_major_collection (mword space_needed)
+sgen_need_major_collection (mword space_needed)
 {
        return need_major_collection (space_needed);
 }
@@ -2388,13 +2400,13 @@ reset_pinned_from_failed_allocation (void)
 }
 
 void
-mono_sgen_set_pinned_from_failed_allocation (mword objsize)
+sgen_set_pinned_from_failed_allocation (mword objsize)
 {
        bytes_pinned_from_failed_allocation += objsize;
 }
 
 gboolean
-mono_sgen_collection_is_parallel (void)
+sgen_collection_is_parallel (void)
 {
        switch (current_collection_generation) {
        case GENERATION_NURSERY:
@@ -2406,12 +2418,6 @@ mono_sgen_collection_is_parallel (void)
        }
 }
 
-gboolean
-mono_sgen_nursery_collection_is_parallel (void)
-{
-       return nursery_collection_is_parallel;
-}
-
 typedef struct
 {
        char *heap_start;
@@ -2423,7 +2429,7 @@ job_finish_remembered_set_scan (WorkerData *worker_data, void *job_data_untyped)
 {
        FinishRememberedSetScanJobData *job_data = job_data_untyped;
 
-       remset.finish_scan_remsets (job_data->heap_start, job_data->heap_end, mono_sgen_workers_get_job_gray_queue (worker_data));
+       remset.finish_scan_remsets (job_data->heap_start, job_data->heap_end, sgen_workers_get_job_gray_queue (worker_data));
 }
 
 typedef struct
@@ -2442,7 +2448,7 @@ job_scan_from_registered_roots (WorkerData *worker_data, void *job_data_untyped)
        scan_from_registered_roots (job_data->func,
                        job_data->heap_start, job_data->heap_end,
                        job_data->root_type,
-                       mono_sgen_workers_get_job_gray_queue (worker_data));
+                       sgen_workers_get_job_gray_queue (worker_data));
 }
 
 typedef struct
@@ -2457,7 +2463,7 @@ job_scan_thread_data (WorkerData *worker_data, void *job_data_untyped)
        ScanThreadDataJobData *job_data = job_data_untyped;
 
        scan_thread_data (job_data->heap_start, job_data->heap_end, TRUE,
-                       mono_sgen_workers_get_job_gray_queue (worker_data));
+                       sgen_workers_get_job_gray_queue (worker_data));
 }
 
 typedef struct
@@ -2470,9 +2476,9 @@ job_scan_finalizer_entries (WorkerData *worker_data, void *job_data_untyped)
 {
        ScanFinalizerEntriesJobData *job_data = job_data_untyped;
 
-       scan_finalizer_entries (mono_sgen_get_copy_object (),
+       scan_finalizer_entries (current_object_ops.copy_or_mark_object,
                        job_data->list,
-                       mono_sgen_workers_get_job_gray_queue (worker_data));
+                       sgen_workers_get_job_gray_queue (worker_data));
 }
 
 static void
@@ -2496,10 +2502,10 @@ verify_nursery (void)
                return;
 
        /*This cleans up unused fragments */
-       mono_sgen_nursery_allocator_prepare_for_pinning ();
+       sgen_nursery_allocator_prepare_for_pinning ();
 
-       hole_start = start = cur = mono_sgen_get_nursery_start ();
-       end = mono_sgen_get_nursery_end ();
+       hole_start = start = cur = sgen_get_nursery_start ();
+       end = sgen_get_nursery_end ();
 
        while (cur < end) {
                size_t ss, size;
@@ -2520,7 +2526,7 @@ verify_nursery (void)
                if (do_dump_nursery_content) {
                        if (cur > hole_start)
                                fprintf (gc_debug_file, "HOLE [%p %p %d]\n", hole_start, cur, (int)(cur - hole_start));
-                       fprintf (gc_debug_file, "OBJ  [%p %p %d %d %s %d]\n", cur, cur + size, (int)size, (int)ss, mono_sgen_safe_name ((MonoObject*)cur), (gpointer)LOAD_VTABLE (cur) == mono_sgen_get_array_fill_vtable ());
+                       fprintf (gc_debug_file, "OBJ  [%p %p %d %d %s %d]\n", cur, cur + size, (int)size, (int)ss, sgen_safe_name ((MonoObject*)cur), (gpointer)LOAD_VTABLE (cur) == sgen_get_array_fill_vtable ());
                }
                cur += size;
                hole_start = cur;
@@ -2556,29 +2562,32 @@ collect_nursery (size_t requested_size)
        mono_perfcounters->gc_collections0++;
 
        current_collection_generation = GENERATION_NURSERY;
-
+       if (sgen_collection_is_parallel ())
+               current_object_ops = sgen_minor_collector.parallel_ops;
+       else
+               current_object_ops = sgen_minor_collector.serial_ops;
+       
        reset_pinned_from_failed_allocation ();
 
        binary_protocol_collection (GENERATION_NURSERY);
        check_scan_starts ();
 
+       sgen_nursery_alloc_prepare_for_minor ();
+
        degraded_mode = 0;
        objects_pinned = 0;
-       nursery_next = mono_sgen_nursery_alloc_get_upper_alloc_bound ();
+       nursery_next = sgen_nursery_alloc_get_upper_alloc_bound ();
        /* FIXME: optimize later to use the higher address where an object can be present */
-       nursery_next = MAX (nursery_next, mono_sgen_get_nursery_end ());
+       nursery_next = MAX (nursery_next, sgen_get_nursery_end ());
 
-       DEBUG (1, fprintf (gc_debug_file, "Start nursery collection %d %p-%p, size: %d\n", stat_minor_gcs, mono_sgen_get_nursery_start (), nursery_next, (int)(nursery_next - mono_sgen_get_nursery_start ())));
-       max_garbage_amount = nursery_next - mono_sgen_get_nursery_start ();
+       DEBUG (1, fprintf (gc_debug_file, "Start nursery collection %d %p-%p, size: %d\n", stat_minor_gcs, sgen_get_nursery_start (), nursery_next, (int)(nursery_next - sgen_get_nursery_start ())));
+       max_garbage_amount = nursery_next - sgen_get_nursery_start ();
        g_assert (nursery_section->size >= max_garbage_amount);
 
        /* world must be stopped already */
        TV_GETTIME (all_atv);
        atv = all_atv;
 
-       /* Pinning no longer depends on clearing all nursery fragments */
-       mono_sgen_clear_current_nursery_fragment ();
-
        TV_GETTIME (btv);
        time_minor_pre_collection_fragment_clear += TV_ELAPSED (atv, btv);
 
@@ -2591,8 +2600,8 @@ collect_nursery (size_t requested_size)
 
        try_calculate_minor_collection_allowance (FALSE);
 
-       mono_sgen_gray_object_queue_init (&gray_queue);
-       mono_sgen_workers_init_distribute_gray_queue ();
+       sgen_gray_object_queue_init (&gray_queue);
+       sgen_workers_init_distribute_gray_queue ();
 
        stat_minor_gcs++;
        mono_stats.minor_gc_count ++;
@@ -2604,45 +2613,45 @@ collect_nursery (size_t requested_size)
        process_dislink_stage_entries ();
 
        /* pin from pinned handles */
-       mono_sgen_init_pinning ();
+       sgen_init_pinning ();
        mono_profiler_gc_event (MONO_GC_EVENT_MARK_START, 0);
-       pin_from_roots (mono_sgen_get_nursery_start (), nursery_next, WORKERS_DISTRIBUTE_GRAY_QUEUE);
+       pin_from_roots (sgen_get_nursery_start (), nursery_next, WORKERS_DISTRIBUTE_GRAY_QUEUE);
        /* identify pinned objects */
-       mono_sgen_optimize_pin_queue (0);
-       mono_sgen_pinning_setup_section (nursery_section);
-       mono_sgen_pin_objects_in_section (nursery_section, WORKERS_DISTRIBUTE_GRAY_QUEUE);      
-       mono_sgen_pinning_trim_queue_to_section (nursery_section);
+       sgen_optimize_pin_queue (0);
+       sgen_pinning_setup_section (nursery_section);
+       sgen_pin_objects_in_section (nursery_section, WORKERS_DISTRIBUTE_GRAY_QUEUE);   
+       sgen_pinning_trim_queue_to_section (nursery_section);
 
        TV_GETTIME (atv);
        time_minor_pinning += TV_ELAPSED (btv, atv);
-       DEBUG (2, fprintf (gc_debug_file, "Finding pinned pointers: %d in %d usecs\n", mono_sgen_get_pinned_count (), TV_ELAPSED (btv, atv)));
-       DEBUG (4, fprintf (gc_debug_file, "Start scan with %d pinned objects\n", mono_sgen_get_pinned_count ()));
+       DEBUG (2, fprintf (gc_debug_file, "Finding pinned pointers: %d in %d usecs\n", sgen_get_pinned_count (), TV_ELAPSED (btv, atv)));
+       DEBUG (4, fprintf (gc_debug_file, "Start scan with %d pinned objects\n", sgen_get_pinned_count ()));
 
        if (consistency_check_at_minor_collection)
-               mono_sgen_check_consistency ();
+               sgen_check_consistency ();
 
-       mono_sgen_workers_start_all_workers ();
+       sgen_workers_start_all_workers ();
 
        /*
         * Perform the sequential part of remembered set scanning.
         * This usually involves scanning global information that might later be produced by evacuation.
         */
        if (remset.begin_scan_remsets)
-               remset.begin_scan_remsets (mono_sgen_get_nursery_start (), nursery_next, WORKERS_DISTRIBUTE_GRAY_QUEUE);
+               remset.begin_scan_remsets (sgen_get_nursery_start (), nursery_next, WORKERS_DISTRIBUTE_GRAY_QUEUE);
 
-       mono_sgen_workers_start_marking ();
+       sgen_workers_start_marking ();
 
-       frssjd.heap_start = mono_sgen_get_nursery_start ();
+       frssjd.heap_start = sgen_get_nursery_start ();
        frssjd.heap_end = nursery_next;
-       mono_sgen_workers_enqueue_job (job_finish_remembered_set_scan, &frssjd);
+       sgen_workers_enqueue_job (job_finish_remembered_set_scan, &frssjd);
 
        /* we don't have complete write barrier yet, so we scan all the old generation sections */
        TV_GETTIME (btv);
        time_minor_scan_remsets += TV_ELAPSED (atv, btv);
        DEBUG (2, fprintf (gc_debug_file, "Old generation scan: %d usecs\n", TV_ELAPSED (atv, btv)));
 
-       if (!mono_sgen_collection_is_parallel ())
-               mono_sgen_drain_gray_stack (&gray_queue, -1);
+       if (!sgen_collection_is_parallel ())
+               sgen_drain_gray_stack (&gray_queue, -1);
 
        if (mono_profiler_get_events () & MONO_PROFILE_GC_ROOTS)
                report_registered_roots ();
@@ -2652,49 +2661,49 @@ collect_nursery (size_t requested_size)
        time_minor_scan_pinned += TV_ELAPSED (btv, atv);
 
        /* registered roots, this includes static fields */
-       scrrjd_normal.func = mono_sgen_collection_is_parallel () ? major_collector.copy_object : major_collector.nopar_copy_object;
-       scrrjd_normal.heap_start = mono_sgen_get_nursery_start ();
+       scrrjd_normal.func = current_object_ops.copy_or_mark_object;
+       scrrjd_normal.heap_start = sgen_get_nursery_start ();
        scrrjd_normal.heap_end = nursery_next;
        scrrjd_normal.root_type = ROOT_TYPE_NORMAL;
-       mono_sgen_workers_enqueue_job (job_scan_from_registered_roots, &scrrjd_normal);
+       sgen_workers_enqueue_job (job_scan_from_registered_roots, &scrrjd_normal);
 
-       scrrjd_wbarrier.func = mono_sgen_collection_is_parallel () ? major_collector.copy_object : major_collector.nopar_copy_object;
-       scrrjd_wbarrier.heap_start = mono_sgen_get_nursery_start ();
+       scrrjd_wbarrier.func = current_object_ops.copy_or_mark_object;
+       scrrjd_wbarrier.heap_start = sgen_get_nursery_start ();
        scrrjd_wbarrier.heap_end = nursery_next;
        scrrjd_wbarrier.root_type = ROOT_TYPE_WBARRIER;
-       mono_sgen_workers_enqueue_job (job_scan_from_registered_roots, &scrrjd_wbarrier);
+       sgen_workers_enqueue_job (job_scan_from_registered_roots, &scrrjd_wbarrier);
 
        TV_GETTIME (btv);
        time_minor_scan_registered_roots += TV_ELAPSED (atv, btv);
 
        /* thread data */
-       stdjd.heap_start = mono_sgen_get_nursery_start ();
+       stdjd.heap_start = sgen_get_nursery_start ();
        stdjd.heap_end = nursery_next;
-       mono_sgen_workers_enqueue_job (job_scan_thread_data, &stdjd);
+       sgen_workers_enqueue_job (job_scan_thread_data, &stdjd);
 
        TV_GETTIME (atv);
        time_minor_scan_thread_data += TV_ELAPSED (btv, atv);
        btv = atv;
 
-       if (mono_sgen_collection_is_parallel ()) {
-               while (!mono_sgen_gray_object_queue_is_empty (WORKERS_DISTRIBUTE_GRAY_QUEUE)) {
-                       mono_sgen_workers_distribute_gray_queue_sections ();
+       if (sgen_collection_is_parallel ()) {
+               while (!sgen_gray_object_queue_is_empty (WORKERS_DISTRIBUTE_GRAY_QUEUE)) {
+                       sgen_workers_distribute_gray_queue_sections ();
                        g_usleep (1000);
                }
        }
-       mono_sgen_workers_join ();
+       sgen_workers_join ();
 
-       if (mono_sgen_collection_is_parallel ())
-               g_assert (mono_sgen_gray_object_queue_is_empty (&gray_queue));
+       if (sgen_collection_is_parallel ())
+               g_assert (sgen_gray_object_queue_is_empty (&gray_queue));
 
        /* Scan the list of objects ready for finalization. If */
        sfejd_fin_ready.list = fin_ready_list;
-       mono_sgen_workers_enqueue_job (job_scan_finalizer_entries, &sfejd_fin_ready);
+       sgen_workers_enqueue_job (job_scan_finalizer_entries, &sfejd_fin_ready);
 
        sfejd_critical_fin.list = critical_fin_list;
-       mono_sgen_workers_enqueue_job (job_scan_finalizer_entries, &sfejd_critical_fin);
+       sgen_workers_enqueue_job (job_scan_finalizer_entries, &sfejd_critical_fin);
 
-       finish_gray_stack (mono_sgen_get_nursery_start (), nursery_next, GENERATION_NURSERY, &gray_queue);
+       finish_gray_stack (sgen_get_nursery_start (), nursery_next, GENERATION_NURSERY, &gray_queue);
        TV_GETTIME (atv);
        time_minor_finish_gray_stack += TV_ELAPSED (btv, atv);
        mono_profiler_gc_event (MONO_GC_EVENT_MARK_END, 0);
@@ -2705,11 +2714,11 @@ collect_nursery (size_t requested_size)
         * worker data here instead of earlier when we joined the
         * workers.
         */
-       mono_sgen_workers_reset_data ();
+       sgen_workers_reset_data ();
 
        if (objects_pinned) {
-               mono_sgen_optimize_pin_queue (0);
-               mono_sgen_pinning_setup_section (nursery_section);
+               sgen_optimize_pin_queue (0);
+               sgen_pinning_setup_section (nursery_section);
        }
 
        /* walk the pin_queue, build up the fragment list of free memory, unmark
@@ -2717,12 +2726,12 @@ collect_nursery (size_t requested_size)
         * next allocations.
         */
        mono_profiler_gc_event (MONO_GC_EVENT_RECLAIM_START, 0);
-       fragment_total = mono_sgen_build_nursery_fragments (nursery_section, nursery_section->pin_queue_start, nursery_section->pin_queue_num_entries);
+       fragment_total = sgen_build_nursery_fragments (nursery_section, nursery_section->pin_queue_start, nursery_section->pin_queue_num_entries);
        if (!fragment_total)
                degraded_mode = 1;
 
        /* Clear TLABs for all threads */
-       mono_sgen_clear_tlabs ();
+       sgen_clear_tlabs ();
 
        mono_profiler_gc_event (MONO_GC_EVENT_RECLAIM_END, 0);
        TV_GETTIME (btv);
@@ -2730,7 +2739,7 @@ collect_nursery (size_t requested_size)
        DEBUG (2, fprintf (gc_debug_file, "Fragment creation: %d usecs, %lu bytes available\n", TV_ELAPSED (atv, btv), (unsigned long)fragment_total));
 
        if (consistency_check_at_minor_collection)
-               mono_sgen_check_major_refs ();
+               sgen_check_major_refs ();
 
        major_collector.finish_nursery_collection ();
 
@@ -2741,14 +2750,14 @@ collect_nursery (size_t requested_size)
                dump_heap ("minor", stat_minor_gcs - 1, NULL);
 
        /* prepare the pin queue for the next collection */
-       mono_sgen_finish_pinning ();
+       sgen_finish_pinning ();
        if (fin_ready_list || critical_fin_list) {
                DEBUG (4, fprintf (gc_debug_file, "Finalizer-thread wakeup: ready %d\n", num_ready_finalizers));
                mono_gc_finalize_notify ();
        }
-       mono_sgen_pin_stats_reset ();
+       sgen_pin_stats_reset ();
 
-       g_assert (mono_sgen_gray_object_queue_is_empty (&gray_queue));
+       g_assert (sgen_gray_object_queue_is_empty (&gray_queue));
 
        if (remset.finish_minor_collection)
                remset.finish_minor_collection ();
@@ -2766,7 +2775,7 @@ collect_nursery (size_t requested_size)
 }
 
 void
-mono_sgen_collect_nursery_no_lock (size_t requested_size)
+sgen_collect_nursery_no_lock (size_t requested_size)
 {
        gint64 gc_start_time;
 
@@ -2801,6 +2810,8 @@ major_do_collection (const char *reason)
 
        mono_perfcounters->gc_collections1++;
 
+       current_object_ops = major_collector.major_ops;
+
        reset_pinned_from_failed_allocation ();
 
        last_collection_old_num_major_sections = major_collector.get_num_major_sections ();
@@ -2818,8 +2829,10 @@ major_do_collection (const char *reason)
 
        binary_protocol_collection (GENERATION_OLD);
        check_scan_starts ();
-       mono_sgen_gray_object_queue_init (&gray_queue);
-       mono_sgen_workers_init_distribute_gray_queue ();
+
+       sgen_gray_object_queue_init (&gray_queue);
+       sgen_workers_init_distribute_gray_queue ();
+       sgen_nursery_alloc_prepare_for_major (reason);
 
        degraded_mode = 0;
        DEBUG (1, fprintf (gc_debug_file, "Start major collection %d\n", stat_major_gcs));
@@ -2831,12 +2844,12 @@ major_do_collection (const char *reason)
        atv = all_atv;
 
        /* Pinning depends on this */
-       mono_sgen_clear_nursery_fragments ();
+       sgen_clear_nursery_fragments ();
 
        TV_GETTIME (btv);
        time_major_pre_collection_fragment_clear += TV_ELAPSED (atv, btv);
 
-       nursery_section->next_data = mono_sgen_get_nursery_end ();
+       nursery_section->next_data = sgen_get_nursery_end ();
        /* we should also coalesce scanning from sections close to each other
         * and deal with pointers outside of the sections later.
         */
@@ -2857,10 +2870,10 @@ major_do_collection (const char *reason)
        process_dislink_stage_entries ();
 
        TV_GETTIME (atv);
-       mono_sgen_init_pinning ();
+       sgen_init_pinning ();
        DEBUG (6, fprintf (gc_debug_file, "Collecting pinned addresses\n"));
        pin_from_roots ((void*)lowest_heap_address, (void*)highest_heap_address, WORKERS_DISTRIBUTE_GRAY_QUEUE);
-       mono_sgen_optimize_pin_queue (0);
+       sgen_optimize_pin_queue (0);
 
        /*
         * pin_queue now contains all candidate pointers, sorted and
@@ -2876,7 +2889,7 @@ major_do_collection (const char *reason)
         */
        DEBUG (6, fprintf (gc_debug_file, "Pinning from sections\n"));
        /* first pass for the sections */
-       mono_sgen_find_section_pin_queue_start_end (nursery_section);
+       sgen_find_section_pin_queue_start_end (nursery_section);
        major_collector.find_pin_queue_start_ends (WORKERS_DISTRIBUTE_GRAY_QUEUE);
        /* identify possible pointers to the insize of large objects */
        DEBUG (6, fprintf (gc_debug_file, "Pinning from large objects\n"));
@@ -2885,13 +2898,13 @@ major_do_collection (const char *reason)
                gboolean profile_roots = mono_profiler_get_events () & MONO_PROFILE_GC_ROOTS;
                GCRootReport report;
                report.count = 0;
-               if (mono_sgen_find_optimized_pin_queue_area (bigobj->data, (char*)bigobj->data + bigobj->size, &dummy)) {
+               if (sgen_find_optimized_pin_queue_area (bigobj->data, (char*)bigobj->data + bigobj->size, &dummy)) {
                        binary_protocol_pin (bigobj->data, (gpointer)LOAD_VTABLE (bigobj->data), safe_object_get_size (bigobj->data));
                        pin_object (bigobj->data);
                        /* FIXME: only enqueue if object has references */
                        GRAY_OBJECT_ENQUEUE (WORKERS_DISTRIBUTE_GRAY_QUEUE, bigobj->data);
                        if (G_UNLIKELY (do_pin_stats))
-                               mono_sgen_pin_stats_register_object ((char*) bigobj->data, safe_object_get_size ((MonoObject*) bigobj->data));
+                               sgen_pin_stats_register_object ((char*) bigobj->data, safe_object_get_size ((MonoObject*) bigobj->data));
                        DEBUG (6, fprintf (gc_debug_file, "Marked large object %p (%s) size: %lu from roots\n", bigobj->data, safe_name (bigobj->data), (unsigned long)bigobj->size));
                        
                        if (profile_roots)
@@ -2901,14 +2914,14 @@ major_do_collection (const char *reason)
                        notify_gc_roots (&report);
        }
        /* second pass for the sections */
-       mono_sgen_pin_objects_in_section (nursery_section, WORKERS_DISTRIBUTE_GRAY_QUEUE);
+       sgen_pin_objects_in_section (nursery_section, WORKERS_DISTRIBUTE_GRAY_QUEUE);
        major_collector.pin_objects (WORKERS_DISTRIBUTE_GRAY_QUEUE);
-       old_next_pin_slot = mono_sgen_get_pinned_count ();
+       old_next_pin_slot = sgen_get_pinned_count ();
 
        TV_GETTIME (btv);
        time_major_pinning += TV_ELAPSED (atv, btv);
-       DEBUG (2, fprintf (gc_debug_file, "Finding pinned pointers: %d in %d usecs\n", mono_sgen_get_pinned_count (), TV_ELAPSED (atv, btv)));
-       DEBUG (4, fprintf (gc_debug_file, "Start scan with %d pinned objects\n", mono_sgen_get_pinned_count ()));
+       DEBUG (2, fprintf (gc_debug_file, "Finding pinned pointers: %d in %d usecs\n", sgen_get_pinned_count (), TV_ELAPSED (atv, btv)));
+       DEBUG (4, fprintf (gc_debug_file, "Start scan with %d pinned objects\n", sgen_get_pinned_count ()));
 
        major_collector.init_to_space ();
 
@@ -2916,8 +2929,8 @@ major_do_collection (const char *reason)
        main_gc_thread = mono_native_thread_self ();
 #endif
 
-       mono_sgen_workers_start_all_workers ();
-       mono_sgen_workers_start_marking ();
+       sgen_workers_start_all_workers ();
+       sgen_workers_start_marking ();
 
        if (mono_profiler_get_events () & MONO_PROFILE_GC_ROOTS)
                report_registered_roots ();
@@ -2925,17 +2938,17 @@ major_do_collection (const char *reason)
        time_major_scan_pinned += TV_ELAPSED (btv, atv);
 
        /* registered roots, this includes static fields */
-       scrrjd_normal.func = major_collector.copy_or_mark_object;
+       scrrjd_normal.func = current_object_ops.copy_or_mark_object;
        scrrjd_normal.heap_start = heap_start;
        scrrjd_normal.heap_end = heap_end;
        scrrjd_normal.root_type = ROOT_TYPE_NORMAL;
-       mono_sgen_workers_enqueue_job (job_scan_from_registered_roots, &scrrjd_normal);
+       sgen_workers_enqueue_job (job_scan_from_registered_roots, &scrrjd_normal);
 
-       scrrjd_wbarrier.func = major_collector.copy_or_mark_object;
+       scrrjd_wbarrier.func = current_object_ops.copy_or_mark_object;
        scrrjd_wbarrier.heap_start = heap_start;
        scrrjd_wbarrier.heap_end = heap_end;
        scrrjd_wbarrier.root_type = ROOT_TYPE_WBARRIER;
-       mono_sgen_workers_enqueue_job (job_scan_from_registered_roots, &scrrjd_wbarrier);
+       sgen_workers_enqueue_job (job_scan_from_registered_roots, &scrrjd_wbarrier);
 
        TV_GETTIME (btv);
        time_major_scan_registered_roots += TV_ELAPSED (atv, btv);
@@ -2943,7 +2956,7 @@ major_do_collection (const char *reason)
        /* Threads */
        stdjd.heap_start = heap_start;
        stdjd.heap_end = heap_end;
-       mono_sgen_workers_enqueue_job (job_scan_thread_data, &stdjd);
+       sgen_workers_enqueue_job (job_scan_thread_data, &stdjd);
 
        TV_GETTIME (atv);
        time_major_scan_thread_data += TV_ELAPSED (btv, atv);
@@ -2956,10 +2969,10 @@ major_do_collection (const char *reason)
 
        /* scan the list of objects ready for finalization */
        sfejd_fin_ready.list = fin_ready_list;
-       mono_sgen_workers_enqueue_job (job_scan_finalizer_entries, &sfejd_fin_ready);
+       sgen_workers_enqueue_job (job_scan_finalizer_entries, &sfejd_fin_ready);
 
        sfejd_critical_fin.list = critical_fin_list;
-       mono_sgen_workers_enqueue_job (job_scan_finalizer_entries, &sfejd_critical_fin);
+       sgen_workers_enqueue_job (job_scan_finalizer_entries, &sfejd_critical_fin);
 
        TV_GETTIME (atv);
        time_major_scan_finalized += TV_ELAPSED (btv, atv);
@@ -2969,19 +2982,19 @@ major_do_collection (const char *reason)
        time_major_scan_big_objects += TV_ELAPSED (atv, btv);
 
        if (major_collector.is_parallel) {
-               while (!mono_sgen_gray_object_queue_is_empty (WORKERS_DISTRIBUTE_GRAY_QUEUE)) {
-                       mono_sgen_workers_distribute_gray_queue_sections ();
+               while (!sgen_gray_object_queue_is_empty (WORKERS_DISTRIBUTE_GRAY_QUEUE)) {
+                       sgen_workers_distribute_gray_queue_sections ();
                        g_usleep (1000);
                }
        }
-       mono_sgen_workers_join ();
+       sgen_workers_join ();
 
 #ifdef SGEN_DEBUG_INTERNAL_ALLOC
        main_gc_thread = NULL;
 #endif
 
        if (major_collector.is_parallel)
-               g_assert (mono_sgen_gray_object_queue_is_empty (&gray_queue));
+               g_assert (sgen_gray_object_queue_is_empty (&gray_queue));
 
        /* all the objects in the heap */
        finish_gray_stack (heap_start, heap_end, GENERATION_OLD, &gray_queue);
@@ -2994,25 +3007,25 @@ major_do_collection (const char *reason)
         * worker data here instead of earlier when we joined the
         * workers.
         */
-       mono_sgen_workers_reset_data ();
+       sgen_workers_reset_data ();
 
        if (objects_pinned) {
                /*This is slow, but we just OOM'd*/
-               mono_sgen_pin_queue_clear_discarded_entries (nursery_section, old_next_pin_slot);
-               mono_sgen_optimize_pin_queue (0);
-               mono_sgen_find_section_pin_queue_start_end (nursery_section);
+               sgen_pin_queue_clear_discarded_entries (nursery_section, old_next_pin_slot);
+               sgen_optimize_pin_queue (0);
+               sgen_find_section_pin_queue_start_end (nursery_section);
                objects_pinned = 0;
        }
 
        reset_heap_boundaries ();
-       mono_sgen_update_heap_boundaries ((mword)mono_sgen_get_nursery_start (), (mword)mono_sgen_get_nursery_end ());
+       sgen_update_heap_boundaries ((mword)sgen_get_nursery_start (), (mword)sgen_get_nursery_end ());
 
        /* sweep the big objects list */
        prevbo = NULL;
        for (bigobj = los_object_list; bigobj;) {
                if (object_is_pinned (bigobj->data)) {
                        unpin_object (bigobj->data);
-                       mono_sgen_update_heap_boundaries ((mword)bigobj->data, (mword)bigobj->data + bigobj->size);
+                       sgen_update_heap_boundaries ((mword)bigobj->data, (mword)bigobj->data + bigobj->size);
                } else {
                        LOSObject *to_free;
                        /* not referenced anywhere, so we can free it */
@@ -3022,7 +3035,7 @@ major_do_collection (const char *reason)
                                los_object_list = bigobj->next;
                        to_free = bigobj;
                        bigobj = bigobj->next;
-                       mono_sgen_los_free_object (to_free);
+                       sgen_los_free_object (to_free);
                        continue;
                }
                prevbo = bigobj;
@@ -3032,7 +3045,7 @@ major_do_collection (const char *reason)
        TV_GETTIME (btv);
        time_major_free_bigobjs += TV_ELAPSED (atv, btv);
 
-       mono_sgen_los_sweep ();
+       sgen_los_sweep ();
 
        TV_GETTIME (atv);
        time_major_los_sweep += TV_ELAPSED (btv, atv);
@@ -3046,11 +3059,11 @@ major_do_collection (const char *reason)
         * pinned objects as we go, memzero() the empty fragments so they are ready for the
         * next allocations.
         */
-       if (!mono_sgen_build_nursery_fragments (nursery_section, nursery_section->pin_queue_start, nursery_section->pin_queue_num_entries))
+       if (!sgen_build_nursery_fragments (nursery_section, nursery_section->pin_queue_start, nursery_section->pin_queue_num_entries))
                degraded_mode = 1;
 
        /* Clear TLABs for all threads */
-       mono_sgen_clear_tlabs ();
+       sgen_clear_tlabs ();
 
        TV_GETTIME (atv);
        time_major_fragment_creation += TV_ELAPSED (btv, atv);
@@ -3062,15 +3075,15 @@ major_do_collection (const char *reason)
                dump_heap ("major", stat_major_gcs - 1, reason);
 
        /* prepare the pin queue for the next collection */
-       mono_sgen_finish_pinning ();
+       sgen_finish_pinning ();
 
        if (fin_ready_list || critical_fin_list) {
                DEBUG (4, fprintf (gc_debug_file, "Finalizer-thread wakeup: ready %d\n", num_ready_finalizers));
                mono_gc_finalize_notify ();
        }
-       mono_sgen_pin_stats_reset ();
+       sgen_pin_stats_reset ();
 
-       g_assert (mono_sgen_gray_object_queue_is_empty (&gray_queue));
+       g_assert (sgen_gray_object_queue_is_empty (&gray_queue));
 
        try_calculate_minor_collection_allowance (TRUE);
 
@@ -3160,10 +3173,10 @@ minor_collect_or_expand_inner (size_t size)
                        mono_trace_message (MONO_TRACE_GC, "minor gc took %d usecs", total_gc_time / 10);
                
                /* this also sets the proper pointers for the next allocation */
-               if (!mono_sgen_can_alloc_size (size)) {
+               if (!sgen_can_alloc_size (size)) {
                        /* TypeBuilder and MonoMethod are killing mcs with fragmentation */
-                       DEBUG (1, fprintf (gc_debug_file, "nursery collection didn't find enough room for %zd alloc (%d pinned)\n", size, mono_sgen_get_pinned_count ()));
-                       mono_sgen_dump_pin_queue ();
+                       DEBUG (1, fprintf (gc_debug_file, "nursery collection didn't find enough room for %zd alloc (%d pinned)\n", size, sgen_get_pinned_count ()));
+                       sgen_dump_pin_queue ();
                        degraded_mode = 1;
                }
                mono_profiler_gc_event (MONO_GC_EVENT_END, 0);
@@ -3172,7 +3185,7 @@ minor_collect_or_expand_inner (size_t size)
 }
 
 void
-mono_sgen_minor_collect_or_expand_inner (size_t size)
+sgen_minor_collect_or_expand_inner (size_t size)
 {
        minor_collect_or_expand_inner (size);
 }
@@ -3193,7 +3206,7 @@ G_GNUC_UNUSED static void
 report_internal_mem_usage (void)
 {
        printf ("Internal memory usage:\n");
-       mono_sgen_report_internal_mem_usage ();
+       sgen_report_internal_mem_usage ();
        printf ("Pinned memory usage:\n");
        major_collector.report_pinned_memory_usage ();
 }
@@ -3205,17 +3218,26 @@ report_internal_mem_usage (void)
  */
 
 /*
- * this is valid for the nursery: if the object has been forwarded it means it's
- * still refrenced from a root. If it is pinned it's still alive as well.
+ * If the object has been forwarded it means it's still referenced from a root. 
+ * If it is pinned it's still alive as well.
+ * A LOS object is only alive if we have pinned it.
  * Return TRUE if @obj is ready to be finalized.
  */
-#define object_is_fin_ready(obj) (!object_is_pinned (obj) && !object_is_forwarded (obj))
-
+static inline gboolean
+sgen_is_object_alive (void *object)
+{
+       if (ptr_in_nursery (object))
+               return sgen_nursery_is_object_alive (object);
+       /* Oldgen objects can be pinned and forwarded too */
+       if (SGEN_OBJECT_IS_PINNED (object) || SGEN_OBJECT_IS_FORWARDED (object))
+               return TRUE;
+       return major_collector.is_object_live (object);
+}
 
 gboolean
-mono_sgen_gc_is_object_ready_for_finalization (void *object)
+sgen_gc_is_object_ready_for_finalization (void *object)
 {
-       return !major_collector.is_object_live (object) && object_is_fin_ready (object);
+       return !sgen_is_object_alive (object);
 }
 
 static gboolean
@@ -3233,7 +3255,7 @@ has_critical_finalizer (MonoObject *obj)
 
 static void
 queue_finalization_entry (MonoObject *obj) {
-       FinalizeReadyEntry *entry = mono_sgen_alloc_internal (INTERNAL_MEM_FINALIZE_READY_ENTRY);
+       FinalizeReadyEntry *entry = sgen_alloc_internal (INTERNAL_MEM_FINALIZE_READY_ENTRY);
        entry->object = obj;
        if (has_critical_finalizer (obj)) {
                entry->next = critical_fin_list;
@@ -3244,22 +3266,24 @@ queue_finalization_entry (MonoObject *obj) {
        }
 }
 
-static int
+static inline int
 object_is_reachable (char *object, char *start, char *end)
 {
        /*This happens for non nursery objects during minor collections. We just treat all objects as alive.*/
        if (object < start || object >= end)
                return TRUE;
-       return !object_is_fin_ready (object) || major_collector.is_object_live (object);
+
+       return sgen_is_object_alive (object);
 }
 
 #include "sgen-fin-weak-hash.c"
 
 gboolean
-mono_sgen_object_is_live (void *obj)
+sgen_object_is_live (void *obj)
 {
        if (ptr_in_nursery (obj))
                return object_is_pinned (obj);
+       /* FIXME This is semantically wrong! All tenured object are considered alive during a nursery collection. */
        if (current_collection_generation == GENERATION_NURSERY)
                return FALSE;
        return major_collector.is_object_live (obj);
@@ -3283,7 +3307,7 @@ null_ephemerons_for_domain (MonoDomain *domain)
                                ephemeron_list = current->next;
 
                        current = current->next;
-                       mono_sgen_free_internal (tmp, INTERNAL_MEM_EPHEMERON_LINK);
+                       sgen_free_internal (tmp, INTERNAL_MEM_EPHEMERON_LINK);
                } else {
                        prev = current;
                        current = current->next;
@@ -3315,7 +3339,7 @@ clear_unreachable_ephemerons (CopyOrMarkObjectFunc copy_func, char *start, char
                                ephemeron_list = current->next;
 
                        current = current->next;
-                       mono_sgen_free_internal (tmp, INTERNAL_MEM_EPHEMERON_LINK);
+                       sgen_free_internal (tmp, INTERNAL_MEM_EPHEMERON_LINK);
 
                        continue;
                }
@@ -3353,11 +3377,11 @@ clear_unreachable_ephemerons (CopyOrMarkObjectFunc copy_func, char *start, char
                        if (was_promoted) {
                                if (ptr_in_nursery (key)) {/*key was not promoted*/
                                        DEBUG (5, fprintf (gc_debug_file, "\tAdded remset to key %p\n", key));
-                                       mono_sgen_add_to_global_remset (&cur->key);
+                                       sgen_add_to_global_remset (&cur->key);
                                }
                                if (ptr_in_nursery (cur->value)) {/*value was not promoted*/
                                        DEBUG (5, fprintf (gc_debug_file, "\tAdded remset to value %p\n", cur->value));
-                                       mono_sgen_add_to_global_remset (&cur->value);
+                                       sgen_add_to_global_remset (&cur->value);
                                }
                        }
                }
@@ -3455,7 +3479,7 @@ mono_gc_invoke_finalizers (void)
                                        e = e->next;
                                e->next = entry->next;
                        }
-                       mono_sgen_free_internal (entry, INTERNAL_MEM_FINALIZE_READY_ENTRY);
+                       sgen_free_internal (entry, INTERNAL_MEM_FINALIZE_READY_ENTRY);
                        entry = NULL;
                }
 
@@ -3510,13 +3534,13 @@ mono_gc_add_memory_pressure (gint64 value)
 }
 
 void
-mono_sgen_register_major_sections_alloced (int num_sections)
+sgen_register_major_sections_alloced (int num_sections)
 {
        minor_collection_sections_alloced += num_sections;
 }
 
 mword
-mono_sgen_get_minor_collection_allowance (void)
+sgen_get_minor_collection_allowance (void)
 {
        return minor_collection_allowance;
 }
@@ -3537,7 +3561,7 @@ mono_gc_register_root_inner (char *start, size_t size, void *descr, int root_typ
        int i;
        LOCK_GC;
        for (i = 0; i < ROOT_TYPE_NUM; ++i) {
-               RootRecord *root = mono_sgen_hash_table_lookup (&roots_hash [i], start);
+               RootRecord *root = sgen_hash_table_lookup (&roots_hash [i], start);
                /* we allow changing the size and the descriptor (for thread statics etc) */
                if (root) {
                        size_t old_size = root->end_root - start;
@@ -3555,7 +3579,7 @@ mono_gc_register_root_inner (char *start, size_t size, void *descr, int root_typ
        new_root.end_root = start + size;
        new_root.root_desc = (mword)descr;
 
-       mono_sgen_hash_table_replace (&roots_hash [root_type], start, &new_root);
+       sgen_hash_table_replace (&roots_hash [root_type], start, &new_root, NULL);
        roots_size += size;
 
        DEBUG (3, fprintf (gc_debug_file, "Added root for range: %p-%p, descr: %p  (%d/%d bytes)\n", start, new_root.end_root, descr, (int)size, (int)roots_size));
@@ -3584,7 +3608,7 @@ mono_gc_deregister_root (char* addr)
 
        LOCK_GC;
        for (root_type = 0; root_type < ROOT_TYPE_NUM; ++root_type) {
-               if (mono_sgen_hash_table_remove (&roots_hash [root_type], addr, &root))
+               if (sgen_hash_table_remove (&roots_hash [root_type], addr, &root))
                        roots_size -= (root.end_root - addr);
        }
        UNLOCK_GC;
@@ -3596,7 +3620,7 @@ mono_gc_deregister_root (char* addr)
  * ######################################################################
  */
 
-unsigned int mono_sgen_global_stop_count = 0;
+unsigned int sgen_global_stop_count = 0;
 
 #ifdef USE_MONO_CTX
 static MonoContext cur_thread_ctx = {0};
@@ -3627,7 +3651,7 @@ update_current_thread_stack (void *start)
 }
 
 void
-mono_sgen_fill_thread_info_for_suspend (SgenThreadInfo *info)
+sgen_fill_thread_info_for_suspend (SgenThreadInfo *info)
 {
        if (remset.fill_thread_info_for_suspend)
                remset.fill_thread_info_for_suspend (info);
@@ -3649,12 +3673,12 @@ restart_threads_until_none_in_managed_allocator (void)
                   allocator */
                FOREACH_THREAD_SAFE (info) {
                        gboolean result;
-                       if (info->skip || info->gc_disabled)
+                       if (info->skip || info->gc_disabled || !info->joined_stw)
                                continue;
                        if (!info->thread_is_dying && (!info->stack_start || info->in_critical_region ||
                                        is_ip_in_managed_allocator (info->stopped_domain, info->stopped_ip))) {
                                binary_protocol_thread_restart ((gpointer)mono_thread_info_get_tid (info));
-                               result = mono_sgen_resume_thread (info);
+                               result = sgen_resume_thread (info);
                                if (result) {
                                        ++restart_count;
                                } else {
@@ -3675,7 +3699,7 @@ restart_threads_until_none_in_managed_allocator (void)
                        break;
 
                /* wait for the threads to signal their restart */
-               mono_sgen_wait_for_suspend_ack (restart_count);
+               sgen_wait_for_suspend_ack (restart_count);
 
                if (sleep_duration < 0) {
 #ifdef HOST_WIN32
@@ -3694,7 +3718,7 @@ restart_threads_until_none_in_managed_allocator (void)
                        gboolean result;
                        if (info->skip || info->stopped_ip == NULL)
                                continue;
-                       result = mono_sgen_suspend_thread (info);
+                       result = sgen_suspend_thread (info);
 
                        if (result) {
                                ++restarted_count;
@@ -3706,7 +3730,7 @@ restart_threads_until_none_in_managed_allocator (void)
                num_threads_died += restart_count - restarted_count;
                /* wait for the threads to signal their suspension
                   again */
-               mono_sgen_wait_for_suspend_ack (restart_count);
+               sgen_wait_for_suspend_ack (restarted_count);
        }
 
        return num_threads_died;
@@ -3733,22 +3757,25 @@ static unsigned long max_pause_usec = 0;
 static int
 stop_world (int generation)
 {
-       int count;
+       int count, dead;
 
        /*XXX this is the right stop, thought might not be the nicest place to put it*/
-       mono_sgen_process_togglerefs ();
+       sgen_process_togglerefs ();
 
        mono_profiler_gc_event (MONO_GC_EVENT_PRE_STOP_WORLD, generation);
        acquire_gc_locks ();
 
        update_current_thread_stack (&count);
 
-       mono_sgen_global_stop_count++;
-       DEBUG (3, fprintf (gc_debug_file, "stopping world n %d from %p %p\n", mono_sgen_global_stop_count, mono_thread_info_current (), (gpointer)mono_native_thread_id_get ()));
+       sgen_global_stop_count++;
+       DEBUG (3, fprintf (gc_debug_file, "stopping world n %d from %p %p\n", sgen_global_stop_count, mono_thread_info_current (), (gpointer)mono_native_thread_id_get ()));
        TV_GETTIME (stop_world_time);
-       count = mono_sgen_thread_handshake (TRUE);
-       count -= restart_threads_until_none_in_managed_allocator ();
-       g_assert (count >= 0);
+       count = sgen_thread_handshake (TRUE);
+       dead = restart_threads_until_none_in_managed_allocator ();
+       if (count < dead)
+               g_error ("More threads have died (%d) that been initialy suspended %d", dead, count);
+       count -= dead;
+
        DEBUG (3, fprintf (gc_debug_file, "world stopped %d thread(s)\n", count));
        mono_profiler_gc_event (MONO_GC_EVENT_POST_STOP_WORLD, generation);
 
@@ -3788,7 +3815,7 @@ restart_world (int generation)
        stw_bridge_process ();
        release_gc_locks ();
 
-       count = mono_sgen_thread_handshake (FALSE);
+       count = sgen_thread_handshake (FALSE);
        TV_GETTIME (end_sw);
        usec = TV_ELAPSED (stop_world_time, end_sw);
        max_pause_usec = MAX (usec, max_pause_usec);
@@ -3820,7 +3847,7 @@ restart_world (int generation)
 }
 
 int
-mono_sgen_get_current_collection_generation (void)
+sgen_get_current_collection_generation (void)
 {
        return current_collection_generation;
 }
@@ -3850,15 +3877,7 @@ void*
 mono_gc_scan_object (void *obj)
 {
        UserCopyOrMarkData *data = mono_native_tls_get_value (user_copy_or_mark_key);
-
-       if (current_collection_generation == GENERATION_NURSERY) {
-               if (mono_sgen_collection_is_parallel ())
-                       major_collector.copy_object (&obj, data->queue);
-               else
-                       major_collector.nopar_copy_object (&obj, data->queue);
-       } else {
-               major_collector.copy_or_mark_object (&obj, data->queue);
-       }
+       current_object_ops.copy_or_mark_object (&obj, data->queue);
        return obj;
 }
 
@@ -3882,7 +3901,13 @@ scan_thread_data (void *start_nursery, void *end_nursery, gboolean precise, Gray
                        DEBUG (3, fprintf (gc_debug_file, "GC disabled for thread %p, range: %p-%p, size: %td\n", info, info->stack_start, info->stack_end, (char*)info->stack_end - (char*)info->stack_start));
                        continue;
                }
-               DEBUG (3, fprintf (gc_debug_file, "Scanning thread %p, range: %p-%p, size: %ld, pinned=%d\n", info, info->stack_start, info->stack_end, (char*)info->stack_end - (char*)info->stack_start, mono_sgen_get_pinned_count ()));
+
+               if (!info->joined_stw) {
+                       DEBUG (3, fprintf (gc_debug_file, "Skipping thread not seen in STW %p, range: %p-%p, size: %td\n", info, info->stack_start, info->stack_end, (char*)info->stack_end - (char*)info->stack_start));
+                       continue;
+               }
+               
+               DEBUG (3, fprintf (gc_debug_file, "Scanning thread %p, range: %p-%p, size: %td, pinned=%d\n", info, info->stack_start, info->stack_end, (char*)info->stack_end - (char*)info->stack_start, sgen_get_pinned_count ()));
                if (!info->thread_is_dying) {
                        if (gc_callbacks.thread_mark_func && !conservative_stack_mark) {
                                UserCopyOrMarkData data = { NULL, queue };
@@ -3970,6 +3995,7 @@ sgen_thread_register (SgenThreadInfo* info, void *addr)
        info->signal = 0;
 #endif
        info->skip = 0;
+       info->joined_stw = FALSE;
        info->doing_handshake = FALSE;
        info->thread_is_dying = FALSE;
        info->stack_start = NULL;
@@ -3983,7 +4009,7 @@ sgen_thread_register (SgenThreadInfo* info, void *addr)
        info->stopped_regs = NULL;
 #endif
 
-       mono_sgen_init_tlab_info (info);
+       sgen_init_tlab_info (info);
 
        binary_protocol_thread_register ((gpointer)mono_thread_info_get_tid (info));
 
@@ -4037,7 +4063,7 @@ sgen_thread_register (SgenThreadInfo* info, void *addr)
 }
 
 static void
-mono_sgen_wbarrier_cleanup_thread (SgenThreadInfo *p)
+sgen_wbarrier_cleanup_thread (SgenThreadInfo *p)
 {
        if (remset.cleanup_thread)
                remset.cleanup_thread (p);
@@ -4081,7 +4107,7 @@ sgen_thread_unregister (SgenThreadInfo *p)
        LOCK_GC;
 #else
        while (!TRYLOCK_GC) {
-               if (!mono_sgen_park_current_thread_if_doing_handshake (p))
+               if (!sgen_park_current_thread_if_doing_handshake (p))
                        g_usleep (50);
        }
 #endif
@@ -4097,7 +4123,7 @@ sgen_thread_unregister (SgenThreadInfo *p)
                gc_callbacks.thread_detach_func (p->runtime_data);
                p->runtime_data = NULL;
        }
-       mono_sgen_wbarrier_cleanup_thread (p);
+       sgen_wbarrier_cleanup_thread (p);
 
        mono_threads_unregister_current_thread (p);
        UNLOCK_GC;
@@ -4257,14 +4283,14 @@ find_object_for_ptr (char *ptr)
 {
        if (ptr >= nursery_section->data && ptr < nursery_section->end_data) {
                found_obj = NULL;
-               mono_sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data,
+               sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data,
                                find_object_for_ptr_callback, ptr, TRUE);
                if (found_obj)
                        return found_obj;
        }
 
        found_obj = NULL;
-       mono_sgen_los_iterate_objects (find_object_for_ptr_callback, ptr);
+       sgen_los_iterate_objects (find_object_for_ptr_callback, ptr);
        if (found_obj)
                return found_obj;
 
@@ -4318,7 +4344,7 @@ mono_gc_wbarrier_generic_store (gpointer ptr, MonoObject* value)
        *(void**)ptr = value;
        if (ptr_in_nursery (value))
                mono_gc_wbarrier_generic_nostore (ptr);
-       mono_sgen_dummy_use (value);
+       sgen_dummy_use (value);
 }
 
 void mono_gc_wbarrier_value_copy_bitmap (gpointer _dest, gpointer _src, int size, unsigned bitmap)
@@ -4486,11 +4512,11 @@ mono_gc_walk_heap (int flags, MonoGCReferences callback, void *data)
        hwi.callback = callback;
        hwi.data = data;
 
-       mono_sgen_clear_nursery_fragments ();
-       mono_sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data, walk_references, &hwi, FALSE);
+       sgen_clear_nursery_fragments ();
+       sgen_scan_area_with_callback (nursery_section->data, nursery_section->end_data, walk_references, &hwi, FALSE);
 
        major_collector.iterate_objects (TRUE, TRUE, walk_references, &hwi);
-       mono_sgen_los_iterate_objects (walk_references, &hwi);
+       sgen_los_iterate_objects (walk_references, &hwi);
 
        return 0;
 }
@@ -4614,7 +4640,7 @@ mono_gc_ephemeron_array_add (MonoObject *obj)
 
        LOCK_GC;
 
-       node = mono_sgen_alloc_internal (INTERNAL_MEM_EPHEMERON_LINK);
+       node = sgen_alloc_internal (INTERNAL_MEM_EPHEMERON_LINK);
        if (!node) {
                UNLOCK_GC;
                return FALSE;
@@ -4662,6 +4688,7 @@ mono_gc_base_init (void)
        char *env;
        char **opts, **ptr;
        char *major_collector_opt = NULL;
+       char *minor_collector_opt = NULL;
        glong max_heap = 0;
        glong soft_limit = 0;
        int num_workers;
@@ -4713,6 +4740,9 @@ mono_gc_base_init (void)
                        if (g_str_has_prefix (opt, "major=")) {
                                opt = strchr (opt, '=') + 1;
                                major_collector_opt = g_strdup (opt);
+                       } else if (g_str_has_prefix (opt, "minor=")) {
+                               opt = strchr (opt, '=') + 1;
+                               minor_collector_opt = g_strdup (opt);
                        }
                }
        } else {
@@ -4720,15 +4750,15 @@ mono_gc_base_init (void)
        }
 
        init_stats ();
-       mono_sgen_init_internal_allocator ();
-       mono_sgen_init_nursery_allocator ();
+       sgen_init_internal_allocator ();
+       sgen_init_nursery_allocator ();
 
-       mono_sgen_register_fixed_internal_mem_type (INTERNAL_MEM_SECTION, SGEN_SIZEOF_GC_MEM_SECTION);
-       mono_sgen_register_fixed_internal_mem_type (INTERNAL_MEM_FINALIZE_READY_ENTRY, sizeof (FinalizeReadyEntry));
-       mono_sgen_register_fixed_internal_mem_type (INTERNAL_MEM_GRAY_QUEUE, sizeof (GrayQueueSection));
+       sgen_register_fixed_internal_mem_type (INTERNAL_MEM_SECTION, SGEN_SIZEOF_GC_MEM_SECTION);
+       sgen_register_fixed_internal_mem_type (INTERNAL_MEM_FINALIZE_READY_ENTRY, sizeof (FinalizeReadyEntry));
+       sgen_register_fixed_internal_mem_type (INTERNAL_MEM_GRAY_QUEUE, sizeof (GrayQueueSection));
        g_assert (sizeof (GenericStoreRememberedSet) == sizeof (gpointer) * STORE_REMSET_BUFFER_SIZE);
-       mono_sgen_register_fixed_internal_mem_type (INTERNAL_MEM_STORE_REMSET, sizeof (GenericStoreRememberedSet));
-       mono_sgen_register_fixed_internal_mem_type (INTERNAL_MEM_EPHEMERON_LINK, sizeof (EphemeronLinkNode));
+       sgen_register_fixed_internal_mem_type (INTERNAL_MEM_STORE_REMSET, sizeof (GenericStoreRememberedSet));
+       sgen_register_fixed_internal_mem_type (INTERNAL_MEM_EPHEMERON_LINK, sizeof (EphemeronLinkNode));
 
 #ifndef HAVE_KW_THREAD
        mono_native_tls_alloc (&thread_info_key, NULL);
@@ -4739,20 +4769,33 @@ mono_gc_base_init (void)
         * it inits the small id which is required for hazard pointer
         * operations.
         */
-       mono_sgen_os_init ();
+       sgen_os_init ();
 
        mono_thread_info_attach (&dummy);
 
+       if (!minor_collector_opt) {
+               sgen_simple_nursery_init (&sgen_minor_collector);
+       } else {
+               if (!strcmp (minor_collector_opt, "simple"))
+                       sgen_simple_nursery_init (&sgen_minor_collector);
+               else if (!strcmp (minor_collector_opt, "split"))
+                       sgen_split_nursery_init (&sgen_minor_collector);
+               else {
+                       fprintf (stderr, "Unknown minor collector `%s'.\n", minor_collector_opt);
+                       exit (1);
+               }
+       }
+
        if (!major_collector_opt || !strcmp (major_collector_opt, "marksweep")) {
-               mono_sgen_marksweep_init (&major_collector);
+               sgen_marksweep_init (&major_collector);
        } else if (!major_collector_opt || !strcmp (major_collector_opt, "marksweep-fixed")) {
-               mono_sgen_marksweep_fixed_init (&major_collector);
+               sgen_marksweep_fixed_init (&major_collector);
        } else if (!major_collector_opt || !strcmp (major_collector_opt, "marksweep-par")) {
-               mono_sgen_marksweep_par_init (&major_collector);
+               sgen_marksweep_par_init (&major_collector);
        } else if (!major_collector_opt || !strcmp (major_collector_opt, "marksweep-fixed-par")) {
-               mono_sgen_marksweep_fixed_par_init (&major_collector);
+               sgen_marksweep_fixed_par_init (&major_collector);
        } else if (!strcmp (major_collector_opt, "copying")) {
-               mono_sgen_copying_init (&major_collector);
+               sgen_copying_init (&major_collector);
        } else {
                fprintf (stderr, "Unknown major collector `%s'.\n", major_collector_opt);
                exit (1);
@@ -4774,11 +4817,16 @@ mono_gc_base_init (void)
        conservative_stack_mark = TRUE;
 #endif
 
+       sgen_nursery_size = DEFAULT_NURSERY_SIZE;
+       minor_collection_allowance = MIN_MINOR_COLLECTION_ALLOWANCE;
+
        if (opts) {
                for (ptr = opts; *ptr; ++ptr) {
                        char *opt = *ptr;
                        if (g_str_has_prefix (opt, "major="))
                                continue;
+                       if (g_str_has_prefix (opt, "minor="))
+                               continue;
                        if (g_str_has_prefix (opt, "wbarrier=")) {
                                opt = strchr (opt, '=') + 1;
                                if (strcmp (opt, "remset") == 0) {
@@ -4854,7 +4902,7 @@ mono_gc_base_init (void)
                        }
                        if (g_str_has_prefix (opt, "bridge=")) {
                                opt = strchr (opt, '=') + 1;
-                               mono_sgen_register_test_bridge_callbacks (g_strdup (opt));
+                               sgen_register_test_bridge_callbacks (g_strdup (opt));
                                continue;
                        }
 #ifdef USER_CONFIG
@@ -4862,7 +4910,7 @@ mono_gc_base_init (void)
                                long val;
                                opt = strchr (opt, '=') + 1;
                                if (*opt && mono_gc_parse_environment_string_extract_number (opt, &val)) {
-                                       mono_sgen_nursery_size = val;
+                                       sgen_nursery_size = val;
 #ifdef SGEN_ALIGN_NURSERY
                                        if ((val & (val - 1))) {
                                                fprintf (stderr, "The nursery size must be a power of two.\n");
@@ -4874,8 +4922,8 @@ mono_gc_base_init (void)
                                                exit (1);
                                        }
 
-                                       mono_sgen_nursery_bits = 0;
-                                       while (1 << (++ mono_sgen_nursery_bits) != mono_sgen_nursery_size)
+                                       sgen_nursery_bits = 0;
+                                       while (1 << (++ sgen_nursery_bits) != sgen_nursery_size)
                                                ;
 #endif
                                } else {
@@ -4885,30 +4933,38 @@ mono_gc_base_init (void)
                                continue;
                        }
 #endif
-                       if (!(major_collector.handle_gc_param && major_collector.handle_gc_param (opt))) {
-                               fprintf (stderr, "MONO_GC_PARAMS must be a comma-delimited list of one or more of the following:\n");
-                               fprintf (stderr, "  max-heap-size=N (where N is an integer, possibly with a k, m or a g suffix)\n");
-                               fprintf (stderr, "  soft-heap-limit=n (where N is an integer, possibly with a k, m or a g suffix)\n");
-                               fprintf (stderr, "  nursery-size=N (where N is an integer, possibly with a k, m or a g suffix)\n");
-                               fprintf (stderr, "  major=COLLECTOR (where COLLECTOR is `marksweep', `marksweep-par' or `copying')\n");
-                               fprintf (stderr, "  wbarrier=WBARRIER (where WBARRIER is `remset' or `cardtable')\n");
-                               fprintf (stderr, "  stack-mark=MARK-METHOD (where MARK-METHOD is 'precise' or 'conservative')\n");
-                               if (major_collector.print_gc_param_usage)
-                                       major_collector.print_gc_param_usage ();
-                               exit (1);
-                       }
+                       if (major_collector.handle_gc_param && major_collector.handle_gc_param (opt))
+                               continue;
+
+                       if (sgen_minor_collector.handle_gc_param && sgen_minor_collector.handle_gc_param (opt))
+                               continue;
+
+                       fprintf (stderr, "MONO_GC_PARAMS must be a comma-delimited list of one or more of the following:\n");
+                       fprintf (stderr, "  max-heap-size=N (where N is an integer, possibly with a k, m or a g suffix)\n");
+                       fprintf (stderr, "  soft-heap-limit=n (where N is an integer, possibly with a k, m or a g suffix)\n");
+                       fprintf (stderr, "  nursery-size=N (where N is an integer, possibly with a k, m or a g suffix)\n");
+                       fprintf (stderr, "  major=COLLECTOR (where COLLECTOR is `marksweep', `marksweep-par' or `copying')\n");
+                       fprintf (stderr, "  minor=COLLECTOR (where COLLECTOR is `simple' or `split')\n");
+                       fprintf (stderr, "  wbarrier=WBARRIER (where WBARRIER is `remset' or `cardtable')\n");
+                       fprintf (stderr, "  stack-mark=MARK-METHOD (where MARK-METHOD is 'precise' or 'conservative')\n");
+                       if (major_collector.print_gc_param_usage)
+                               major_collector.print_gc_param_usage ();
+                       if (sgen_minor_collector.print_gc_param_usage)
+                               sgen_minor_collector.print_gc_param_usage ();
+                       exit (1);
                }
                g_strfreev (opts);
        }
 
        if (major_collector.is_parallel)
-               mono_sgen_workers_init (num_workers);
+               sgen_workers_init (num_workers);
 
        if (major_collector_opt)
                g_free (major_collector_opt);
 
-       nursery_size = DEFAULT_NURSERY_SIZE;
-       minor_collection_allowance = MIN_MINOR_COLLECTION_ALLOWANCE;
+       if (minor_collector_opt)
+               g_free (minor_collector_opt);
+
        init_heap_size_limits (max_heap, soft_limit);
 
        alloc_nursery ();
@@ -5011,7 +5067,7 @@ mono_gc_base_init (void)
                sgen_card_table_init (&remset);
        else
 #endif
-               mono_sgen_ssb_init (&remset);
+               sgen_ssb_init (&remset);
 
        if (remset.register_thread)
                remset.register_thread (mono_thread_info_current ());
@@ -5030,7 +5086,7 @@ static MonoMethod *write_barrier_method;
 static gboolean
 mono_gc_is_critical_method (MonoMethod *method)
 {
-       return (method == write_barrier_method || mono_sgen_is_managed_allocator (method));
+       return (method == write_barrier_method || sgen_is_managed_allocator (method));
 }
 
 static gboolean
@@ -5064,7 +5120,7 @@ emit_nursery_check (MonoMethodBuilder *mb, int *nursery_check_return_labels)
        mono_mb_emit_ldarg (mb, 0);
        mono_mb_emit_icon (mb, DEFAULT_NURSERY_BITS);
        mono_mb_emit_byte (mb, CEE_SHR_UN);
-       mono_mb_emit_icon (mb, (mword)mono_sgen_get_nursery_start () >> DEFAULT_NURSERY_BITS);
+       mono_mb_emit_icon (mb, (mword)sgen_get_nursery_start () >> DEFAULT_NURSERY_BITS);
        nursery_check_return_labels [0] = mono_mb_emit_branch (mb, CEE_BEQ);
 
        // if (!ptr_in_nursery (*ptr)) return;
@@ -5072,20 +5128,20 @@ emit_nursery_check (MonoMethodBuilder *mb, int *nursery_check_return_labels)
        mono_mb_emit_byte (mb, CEE_LDIND_I);
        mono_mb_emit_icon (mb, DEFAULT_NURSERY_BITS);
        mono_mb_emit_byte (mb, CEE_SHR_UN);
-       mono_mb_emit_icon (mb, (mword)mono_sgen_get_nursery_start () >> DEFAULT_NURSERY_BITS);
+       mono_mb_emit_icon (mb, (mword)sgen_get_nursery_start () >> DEFAULT_NURSERY_BITS);
        nursery_check_return_labels [1] = mono_mb_emit_branch (mb, CEE_BNE_UN);
 #else
        int label_continue1, label_continue2;
        int dereferenced_var;
 
-       // if (ptr < (mono_sgen_get_nursery_start ())) goto continue;
+       // if (ptr < (sgen_get_nursery_start ())) goto continue;
        mono_mb_emit_ldarg (mb, 0);
-       mono_mb_emit_ptr (mb, (gpointer) mono_sgen_get_nursery_start ());
+       mono_mb_emit_ptr (mb, (gpointer) sgen_get_nursery_start ());
        label_continue_1 = mono_mb_emit_branch (mb, CEE_BLT);
 
-       // if (ptr >= mono_sgen_get_nursery_end ())) goto continue;
+       // if (ptr >= sgen_get_nursery_end ())) goto continue;
        mono_mb_emit_ldarg (mb, 0);
-       mono_mb_emit_ptr (mb, (gpointer) mono_sgen_get_nursery_end ());
+       mono_mb_emit_ptr (mb, (gpointer) sgen_get_nursery_end ());
        label_continue_2 = mono_mb_emit_branch (mb, CEE_BGE);
 
        // Otherwise return
@@ -5101,14 +5157,14 @@ emit_nursery_check (MonoMethodBuilder *mb, int *nursery_check_return_labels)
        mono_mb_emit_byte (mb, CEE_LDIND_I);
        mono_mb_emit_stloc (mb, dereferenced_var);
 
-       // if (*ptr < mono_sgen_get_nursery_start ()) return;
+       // if (*ptr < sgen_get_nursery_start ()) return;
        mono_mb_emit_ldloc (mb, dereferenced_var);
-       mono_mb_emit_ptr (mb, (gpointer) mono_sgen_get_nursery_start ());
+       mono_mb_emit_ptr (mb, (gpointer) sgen_get_nursery_start ());
        nursery_check_return_labels [1] = mono_mb_emit_branch (mb, CEE_BLT);
 
-       // if (*ptr >= mono_sgen_get_nursery_end ()) return;
+       // if (*ptr >= sgen_get_nursery_end ()) return;
        mono_mb_emit_ldloc (mb, dereferenced_var);
-       mono_mb_emit_ptr (mb, (gpointer) mono_sgen_get_nursery_end ());
+       mono_mb_emit_ptr (mb, (gpointer) sgen_get_nursery_end ());
        nursery_check_return_labels [2] = mono_mb_emit_branch (mb, CEE_BGE);
 #endif 
 }
@@ -5319,7 +5375,7 @@ mono_gc_is_disabled (void)
 }
 
 void
-mono_sgen_debug_printf (int level, const char *format, ...)
+sgen_debug_printf (int level, const char *format, ...)
 {
        va_list ap;
 
@@ -5332,7 +5388,7 @@ mono_sgen_debug_printf (int level, const char *format, ...)
 }
 
 FILE*
-mono_sgen_get_logfile (void)
+sgen_get_logfile (void)
 {
        return gc_debug_file;
 }
@@ -5345,13 +5401,13 @@ BOOL APIENTRY mono_gc_dllmain (HMODULE module_handle, DWORD reason, LPVOID reser
 #endif
 
 NurseryClearPolicy
-mono_sgen_get_nursery_clear_policy (void)
+sgen_get_nursery_clear_policy (void)
 {
        return nursery_clear_policy;
 }
 
 MonoVTable*
-mono_sgen_get_array_fill_vtable (void)
+sgen_get_array_fill_vtable (void)
 {
        if (!array_fill_vtable) {
                static MonoClass klass;
@@ -5378,13 +5434,13 @@ mono_sgen_get_array_fill_vtable (void)
 }
 
 void
-mono_sgen_gc_lock (void)
+sgen_gc_lock (void)
 {
        LOCK_GC;
 }
 
 void
-mono_sgen_gc_unlock (void)
+sgen_gc_unlock (void)
 {
        UNLOCK_GC;
 }
@@ -5402,7 +5458,7 @@ sgen_major_collector_scan_card_table (SgenGrayQueue *queue)
 }
 
 SgenMajorCollector*
-mono_sgen_get_major_collector (void)
+sgen_get_major_collector (void)
 {
        return &major_collector;
 }
@@ -5417,7 +5473,7 @@ void mono_gc_set_skip_thread (gboolean skip)
 }
 
 SgenRemeberedSet*
-mono_sgen_get_remset (void)
+sgen_get_remset (void)
 {
        return &remset;
 }
@@ -5425,9 +5481,15 @@ mono_sgen_get_remset (void)
 guint
 mono_gc_get_vtable_bits (MonoClass *class)
 {
-       if (mono_sgen_need_bridge_processing () && mono_sgen_is_bridge_class (class))
+       if (sgen_need_bridge_processing () && sgen_is_bridge_class (class))
                return SGEN_GC_BIT_BRIDGE_OBJECT;
        return 0;
 }
 
+void
+mono_gc_register_altstack (gpointer stack, gint32 stack_size, gpointer altstack, gint32 altstack_size)
+{
+       // FIXME:
+}
+
 #endif /* HAVE_SGEN_GC */
index a330a39ca78e1f31263d26f4a4801c30195be935..31a83d53101d3782150a77860c25006dc510f4e0 100644 (file)
@@ -62,7 +62,7 @@ typedef enum {
        CLEAR_AT_TLAB_CREATION
 } NurseryClearPolicy;
 
-NurseryClearPolicy mono_sgen_get_nursery_clear_policy (void) MONO_INTERNAL;
+NurseryClearPolicy sgen_get_nursery_clear_policy (void) MONO_INTERNAL;
 
 #define SGEN_TV_DECLARE(name) gint64 name
 #define SGEN_TV_GETTIME(tv) tv = mono_100ns_ticks ()
@@ -113,6 +113,7 @@ struct _SgenThreadInfo {
 #endif
        int skip;
        volatile int in_critical_region;
+       gboolean joined_stw;
        gboolean doing_handshake;
        gboolean thread_is_dying;
        gboolean gc_disabled;
@@ -238,7 +239,7 @@ extern FILE* gc_debug_file;
 
 extern int current_collection_generation;
 
-extern unsigned int mono_sgen_global_stop_count;
+extern unsigned int sgen_global_stop_count;
 
 #define SGEN_ALLOC_ALIGN               8
 #define SGEN_ALLOC_ALIGN_BITS  3
@@ -254,12 +255,12 @@ extern unsigned int mono_sgen_global_stop_count;
 #ifdef USER_CONFIG
 
 /* good sizes are 512KB-1MB: larger ones increase a lot memzeroing time */
-#define DEFAULT_NURSERY_SIZE (mono_sgen_nursery_size)
-extern int mono_sgen_nursery_size MONO_INTERNAL;
+#define DEFAULT_NURSERY_SIZE (sgen_nursery_size)
+extern int sgen_nursery_size MONO_INTERNAL;
 #ifdef SGEN_ALIGN_NURSERY
 /* The number of trailing 0 bits in DEFAULT_NURSERY_SIZE */
-#define DEFAULT_NURSERY_BITS (mono_sgen_nursery_bits)
-extern int mono_sgen_nursery_bits MONO_INTERNAL;
+#define DEFAULT_NURSERY_BITS (sgen_nursery_bits)
+extern int sgen_nursery_bits MONO_INTERNAL;
 #endif
 
 #else
@@ -275,28 +276,27 @@ extern int mono_sgen_nursery_bits MONO_INTERNAL;
 #define DEFAULT_NURSERY_BITS -1
 #endif
 
-extern char *mono_sgen_nursery_start MONO_INTERNAL;
-extern char *mono_sgen_nursery_end MONO_INTERNAL;
+extern char *sgen_nursery_start MONO_INTERNAL;
+extern char *sgen_nursery_end MONO_INTERNAL;
 
 static inline gboolean
-mono_sgen_ptr_in_nursery (void *p)
+sgen_ptr_in_nursery (void *p)
 {
-       return SGEN_PTR_IN_NURSERY ((p), DEFAULT_NURSERY_BITS, mono_sgen_nursery_start, mono_sgen_nursery_end);
+       return SGEN_PTR_IN_NURSERY ((p), DEFAULT_NURSERY_BITS, sgen_nursery_start, sgen_nursery_end);
 }
 
 static inline char*
-mono_sgen_get_nursery_start (void)
+sgen_get_nursery_start (void)
 {
-       return mono_sgen_nursery_start;
+       return sgen_nursery_start;
 }
 
 static inline char*
-mono_sgen_get_nursery_end (void)
+sgen_get_nursery_end (void)
 {
-       return mono_sgen_nursery_end;
+       return sgen_nursery_end;
 }
 
-
 /* Structure that corresponds to a MonoVTable: desc is a mword so requires
  * no cast from a pointer to an integer
  */
@@ -339,17 +339,13 @@ typedef struct {
  */
 #define SGEN_LOAD_VTABLE(addr) ((*(mword*)(addr)) & ~SGEN_VTABLE_BITS_MASK)
 
-typedef void (*CopyOrMarkObjectFunc) (void**, SgenGrayQueue*);
-typedef void (*ScanObjectFunc) (char*, SgenGrayQueue*);
-typedef void (*ScanVTypeFunc) (char*, mword desc, SgenGrayQueue*);
-
 #if SGEN_MAX_DEBUG_LEVEL >= 9
-#define GRAY_OBJECT_ENQUEUE mono_sgen_gray_object_enqueue
-#define GRAY_OBJECT_DEQUEUE(queue,o) ((o) = mono_sgen_gray_object_dequeue ((queue)))
+#define GRAY_OBJECT_ENQUEUE sgen_gray_object_enqueue
+#define GRAY_OBJECT_DEQUEUE(queue,o) ((o) = sgen_gray_object_dequeue ((queue)))
 #else
 #define GRAY_OBJECT_ENQUEUE(queue,o) do {                              \
                if (G_UNLIKELY (!(queue)->first || (queue)->first->end == SGEN_GRAY_QUEUE_SECTION_SIZE)) \
-                       mono_sgen_gray_object_enqueue ((queue), (o));   \
+                       sgen_gray_object_enqueue ((queue), (o));        \
                else                                                    \
                        (queue)->first->objects [(queue)->first->end++] = (o); \
                PREFETCH ((o));                                         \
@@ -358,7 +354,7 @@ typedef void (*ScanVTypeFunc) (char*, mword desc, SgenGrayQueue*);
                if (!(queue)->first)                                    \
                        (o) = NULL;                                     \
                else if (G_UNLIKELY ((queue)->first->end == 1))         \
-                       (o) = mono_sgen_gray_object_dequeue ((queue));          \
+                       (o) = sgen_gray_object_dequeue ((queue));               \
                else                                                    \
                        (o) = (queue)->first->objects [--(queue)->first->end]; \
        } while (0)
@@ -373,30 +369,30 @@ enum {
 
 typedef void (*IterateObjectCallbackFunc) (char*, size_t, void*);
 
-void* mono_sgen_alloc_os_memory (size_t size, int activate) MONO_INTERNAL;
-void* mono_sgen_alloc_os_memory_aligned (mword size, mword alignment, gboolean activate) MONO_INTERNAL;
-void mono_sgen_free_os_memory (void *addr, size_t size) MONO_INTERNAL;
+void* sgen_alloc_os_memory (size_t size, int activate) MONO_INTERNAL;
+void* sgen_alloc_os_memory_aligned (mword size, mword alignment, gboolean activate) MONO_INTERNAL;
+void sgen_free_os_memory (void *addr, size_t size) MONO_INTERNAL;
 
-int mono_sgen_thread_handshake (BOOL suspend) MONO_INTERNAL;
-gboolean mono_sgen_suspend_thread (SgenThreadInfo *info) MONO_INTERNAL;
-gboolean mono_sgen_resume_thread (SgenThreadInfo *info) MONO_INTERNAL;
-void mono_sgen_wait_for_suspend_ack (int count) MONO_INTERNAL;
-gboolean mono_sgen_park_current_thread_if_doing_handshake (SgenThreadInfo *p) MONO_INTERNAL;
-void mono_sgen_os_init (void) MONO_INTERNAL;
+int sgen_thread_handshake (BOOL suspend) MONO_INTERNAL;
+gboolean sgen_suspend_thread (SgenThreadInfo *info) MONO_INTERNAL;
+gboolean sgen_resume_thread (SgenThreadInfo *info) MONO_INTERNAL;
+void sgen_wait_for_suspend_ack (int count) MONO_INTERNAL;
+gboolean sgen_park_current_thread_if_doing_handshake (SgenThreadInfo *p) MONO_INTERNAL;
+void sgen_os_init (void) MONO_INTERNAL;
 
-void mono_sgen_fill_thread_info_for_suspend (SgenThreadInfo *info) MONO_INTERNAL;
+void sgen_fill_thread_info_for_suspend (SgenThreadInfo *info) MONO_INTERNAL;
 
-gboolean mono_sgen_is_worker_thread (MonoNativeThreadId thread) MONO_INTERNAL;
+gboolean sgen_is_worker_thread (MonoNativeThreadId thread) MONO_INTERNAL;
 
-void mono_sgen_update_heap_boundaries (mword low, mword high) MONO_INTERNAL;
+void sgen_update_heap_boundaries (mword low, mword high) MONO_INTERNAL;
 
-void mono_sgen_register_major_sections_alloced (int num_sections) MONO_INTERNAL;
-mword mono_sgen_get_minor_collection_allowance (void) MONO_INTERNAL;
+void sgen_register_major_sections_alloced (int num_sections) MONO_INTERNAL;
+mword sgen_get_minor_collection_allowance (void) MONO_INTERNAL;
 
-void mono_sgen_scan_area_with_callback (char *start, char *end, IterateObjectCallbackFunc callback, void *data, gboolean allow_flags) MONO_INTERNAL;
-void mono_sgen_check_section_scan_starts (GCMemSection *section) MONO_INTERNAL;
+void sgen_scan_area_with_callback (char *start, char *end, IterateObjectCallbackFunc callback, void *data, gboolean allow_flags) MONO_INTERNAL;
+void sgen_check_section_scan_starts (GCMemSection *section) MONO_INTERNAL;
 
-/* Keep in sync with mono_sgen_dump_internal_mem_usage() in dump_heap()! */
+/* Keep in sync with sgen_dump_internal_mem_usage() in dump_heap()! */
 enum {
        INTERNAL_MEM_PIN_QUEUE,
        INTERNAL_MEM_FRAGMENT,
@@ -439,8 +435,8 @@ enum {
        GENERATION_MAX
 };
 
-void mono_sgen_init_internal_allocator (void) MONO_INTERNAL;
-void mono_sgen_init_pinned_allocator (void) MONO_INTERNAL;
+void sgen_init_internal_allocator (void) MONO_INTERNAL;
+void sgen_init_pinned_allocator (void) MONO_INTERNAL;
 
 typedef struct _ObjectList ObjectList;
 struct _ObjectList {
@@ -448,53 +444,165 @@ struct _ObjectList {
        ObjectList *next;
 };
 
-void mono_sgen_report_internal_mem_usage (void) MONO_INTERNAL;
-void mono_sgen_report_pinned_mem_usage (SgenPinnedAllocator *alc) MONO_INTERNAL;
-void mono_sgen_dump_internal_mem_usage (FILE *heap_dump_file) MONO_INTERNAL;
-void mono_sgen_dump_section (GCMemSection *section, const char *type) MONO_INTERNAL;
-void mono_sgen_dump_occupied (char *start, char *end, char *section_start) MONO_INTERNAL;
+void sgen_report_internal_mem_usage (void) MONO_INTERNAL;
+void sgen_report_pinned_mem_usage (SgenPinnedAllocator *alc) MONO_INTERNAL;
+void sgen_dump_internal_mem_usage (FILE *heap_dump_file) MONO_INTERNAL;
+void sgen_dump_section (GCMemSection *section, const char *type) MONO_INTERNAL;
+void sgen_dump_occupied (char *start, char *end, char *section_start) MONO_INTERNAL;
 
-void mono_sgen_register_moved_object (void *obj, void *destination) MONO_INTERNAL;
+void sgen_register_moved_object (void *obj, void *destination) MONO_INTERNAL;
 
-void mono_sgen_register_fixed_internal_mem_type (int type, size_t size) MONO_INTERNAL;
+void sgen_register_fixed_internal_mem_type (int type, size_t size) MONO_INTERNAL;
 
-void* mono_sgen_alloc_internal (int type) MONO_INTERNAL;
-void mono_sgen_free_internal (void *addr, int type) MONO_INTERNAL;
+void* sgen_alloc_internal (int type) MONO_INTERNAL;
+void sgen_free_internal (void *addr, int type) MONO_INTERNAL;
 
-void* mono_sgen_alloc_internal_dynamic (size_t size, int type) MONO_INTERNAL;
-void mono_sgen_free_internal_dynamic (void *addr, size_t size, int type) MONO_INTERNAL;
+void* sgen_alloc_internal_dynamic (size_t size, int type) MONO_INTERNAL;
+void sgen_free_internal_dynamic (void *addr, size_t size, int type) MONO_INTERNAL;
 
-void* mono_sgen_alloc_pinned (SgenPinnedAllocator *allocator, size_t size) MONO_INTERNAL;
-void mono_sgen_free_pinned (SgenPinnedAllocator *allocator, void *addr, size_t size) MONO_INTERNAL;
+void* sgen_alloc_pinned (SgenPinnedAllocator *allocator, size_t size) MONO_INTERNAL;
+void sgen_free_pinned (SgenPinnedAllocator *allocator, void *addr, size_t size) MONO_INTERNAL;
 
 
-void mono_sgen_debug_printf (int level, const char *format, ...) MONO_INTERNAL;
+void sgen_debug_printf (int level, const char *format, ...) MONO_INTERNAL;
 
-gboolean mono_sgen_parse_environment_string_extract_number (const char *str, glong *out) MONO_INTERNAL;
+gboolean sgen_parse_environment_string_extract_number (const char *str, glong *out) MONO_INTERNAL;
 
-void mono_sgen_pinned_scan_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFunc callback, void *callback_data) MONO_INTERNAL;
-void mono_sgen_pinned_scan_pinned_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFunc callback, void *callback_data) MONO_INTERNAL;
+void sgen_pinned_scan_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFunc callback, void *callback_data) MONO_INTERNAL;
+void sgen_pinned_scan_pinned_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFunc callback, void *callback_data) MONO_INTERNAL;
 
-void mono_sgen_pinned_update_heap_boundaries (SgenPinnedAllocator *alc) MONO_INTERNAL;
+void sgen_pinned_update_heap_boundaries (SgenPinnedAllocator *alc) MONO_INTERNAL;
 
-void** mono_sgen_find_optimized_pin_queue_area (void *start, void *end, int *num) MONO_INTERNAL;
-void mono_sgen_find_section_pin_queue_start_end (GCMemSection *section) MONO_INTERNAL;
-void mono_sgen_pin_objects_in_section (GCMemSection *section, SgenGrayQueue *queue) MONO_INTERNAL;
+void** sgen_find_optimized_pin_queue_area (void *start, void *end, int *num) MONO_INTERNAL;
+void sgen_find_section_pin_queue_start_end (GCMemSection *section) MONO_INTERNAL;
+void sgen_pin_objects_in_section (GCMemSection *section, SgenGrayQueue *queue) MONO_INTERNAL;
 
-void mono_sgen_pin_stats_register_object (char *obj, size_t size);
-void mono_sgen_pin_stats_register_global_remset (char *obj);
-void mono_sgen_pin_stats_print_class_stats (void);
+void sgen_pin_stats_register_object (char *obj, size_t size);
+void sgen_pin_stats_register_global_remset (char *obj);
+void sgen_pin_stats_print_class_stats (void);
 
-void mono_sgen_sort_addresses (void **array, int size) MONO_INTERNAL;
-void mono_sgen_add_to_global_remset (gpointer ptr) MONO_INTERNAL;
+void sgen_sort_addresses (void **array, int size) MONO_INTERNAL;
+void sgen_add_to_global_remset (gpointer ptr) MONO_INTERNAL;
 
-int mono_sgen_get_current_collection_generation (void) MONO_INTERNAL;
-gboolean mono_sgen_nursery_collection_is_parallel (void) MONO_INTERNAL;
-CopyOrMarkObjectFunc mono_sgen_get_copy_object (void) MONO_INTERNAL;
-ScanObjectFunc mono_sgen_get_minor_scan_object (void) MONO_INTERNAL;
-ScanVTypeFunc mono_sgen_get_minor_scan_vtype (void) MONO_INTERNAL;
-gboolean mono_sgen_collection_is_parallel (void) MONO_INTERNAL;
+typedef void (*CopyOrMarkObjectFunc) (void**, SgenGrayQueue*);
+typedef void (*ScanObjectFunc) (char*, SgenGrayQueue*);
+typedef void (*ScanVTypeFunc) (char*, mword desc, SgenGrayQueue*);
+
+int sgen_get_current_collection_generation (void) MONO_INTERNAL;
+gboolean sgen_collection_is_parallel (void) MONO_INTERNAL;
+
+typedef struct {
+       CopyOrMarkObjectFunc copy_or_mark_object;
+       ScanObjectFunc scan_object;
+       ScanVTypeFunc scan_vtype;
+       /*FIXME add allocation function? */
+} SgenObjectOperations;
+
+SgenObjectOperations *sgen_get_current_object_ops (void) MONO_INTERNAL;
+
+typedef struct _SgenFragment SgenFragment;
+
+struct _SgenFragment {
+       SgenFragment *next;
+       char *fragment_start;
+       char *fragment_next; /* the current soft limit for allocation */
+       char *fragment_end;
+       SgenFragment *next_in_order; /* We use a different entry for all active fragments so we can avoid SMR. */
+};
 
+typedef struct {
+       SgenFragment *alloc_head; /* List head to be used when allocating memory. Walk with fragment_next. */
+       SgenFragment *region_head; /* List head of the region used by this allocator. Walk with next_in_order. */
+} SgenFragmentAllocator;
+
+void sgen_fragment_allocator_add (SgenFragmentAllocator *allocator, char *start, char *end) MONO_INTERNAL;
+void sgen_fragment_allocator_release (SgenFragmentAllocator *allocator) MONO_INTERNAL;
+void* sgen_fragment_allocator_serial_alloc (SgenFragmentAllocator *allocator, size_t size) MONO_INTERNAL;
+void* sgen_fragment_allocator_par_alloc (SgenFragmentAllocator *allocator, size_t size) MONO_INTERNAL;
+void* sgen_fragment_allocator_serial_range_alloc (SgenFragmentAllocator *allocator, size_t desired_size, size_t minimum_size, size_t *out_alloc_size) MONO_INTERNAL;
+void* sgen_fragment_allocator_par_range_alloc (SgenFragmentAllocator *allocator, size_t desired_size, size_t minimum_size, size_t *out_alloc_size) MONO_INTERNAL;
+SgenFragment* sgen_fragment_allocator_alloc (void) MONO_INTERNAL;
+void sgen_clear_allocator_fragments (SgenFragmentAllocator *allocator) MONO_INTERNAL;
+void sgen_clear_range (char *start, char *end) MONO_INTERNAL;
+
+
+/*
+This is a space/speed compromise as we need to make sure the from/to space check is both O(1)
+and only hit cache hot memory. On a 4Mb nursery it requires 1024 bytes, or 3% of your average
+L1 cache. On small configs with a 512kb nursery, this goes to 0.4%.
+
+Experimental results on how much space we waste with a 4Mb nursery:
+
+Note that the wastage applies to the half nursery, or 2Mb:
+
+Test 1 (compiling corlib):
+9: avg: 3.1k
+8: avg: 1.6k
+
+*/
+#define SGEN_TO_SPACE_GRANULE_BITS 9
+#define SGEN_TO_SPACE_GRANULE_IN_BYTES (1 << SGEN_TO_SPACE_GRANULE_BITS)
+
+extern char *sgen_space_bitmap MONO_INTERNAL;
+extern int sgen_space_bitmap_size MONO_INTERNAL;
+
+static inline gboolean
+sgen_nursery_is_to_space (char *object)
+{
+       int idx = (object - sgen_nursery_start) >> SGEN_TO_SPACE_GRANULE_BITS;
+       int byte = idx / 8;
+       int bit = idx & 0x7;
+
+       /* FIXME put those asserts under a non default level */
+       g_assert (sgen_ptr_in_nursery (object));
+       g_assert (byte < sgen_space_bitmap_size);
+
+       return (sgen_space_bitmap [byte] & (1 << bit)) != 0;
+}
+
+static inline gboolean
+sgen_nursery_is_from_space (char *object)
+{
+       return !sgen_nursery_is_to_space (object);
+}
+
+static inline gboolean
+sgen_nursery_is_object_alive (char *obj)
+{
+       /* FIXME put this asserts under a non default level */
+       g_assert (sgen_ptr_in_nursery (obj));
+
+       if (sgen_nursery_is_to_space (obj))
+               return TRUE;
+
+       if (SGEN_OBJECT_IS_PINNED (obj) || SGEN_OBJECT_IS_FORWARDED (obj))
+               return TRUE;
+
+       return FALSE;
+}
+
+typedef struct {
+       char* (*alloc_for_promotion) (char *obj, size_t objsize, gboolean has_references);
+       char* (*par_alloc_for_promotion) (char *obj, size_t objsize, gboolean has_references);
+
+       SgenObjectOperations serial_ops;
+       SgenObjectOperations parallel_ops;
+
+       void (*prepare_to_space) (char *to_space_bitmap, int space_bitmap_size);
+       void (*clear_fragments) (void);
+       SgenFragment* (*build_fragments_get_exclude_head) (void);
+       void (*build_fragments_release_exclude_head) (void);
+       void (*build_fragments_finish) (SgenFragmentAllocator *allocator);
+       void (*init_nursery) (SgenFragmentAllocator *allocator, char *start, char *end);
+
+       gboolean (*handle_gc_param) (const char *opt); /* Optional */
+       void (*print_gc_param_usage) (void); /* Optional */
+} SgenMinorCollector;
+
+extern SgenMinorCollector sgen_minor_collector;
+
+void sgen_simple_nursery_init (SgenMinorCollector *collector) MONO_INTERNAL;
+void sgen_split_nursery_init (SgenMinorCollector *collector) MONO_INTERNAL;
 
 typedef void (*sgen_cardtable_block_callback) (mword start, mword size);
 void sgen_major_collector_iterate_live_block_ranges (sgen_cardtable_block_callback callback) MONO_INTERNAL;
@@ -515,20 +623,17 @@ struct _SgenMajorCollector {
        gboolean (*is_object_live) (char *obj);
        void* (*alloc_small_pinned_obj) (size_t size, gboolean has_references);
        void* (*alloc_degraded) (MonoVTable *vtable, size_t size);
-       void (*copy_or_mark_object) (void **obj_slot, SgenGrayQueue *queue);
-       void (*minor_scan_object) (char *start, SgenGrayQueue *queue);
-       void (*nopar_minor_scan_object) (char *start, SgenGrayQueue *queue);
-       void (*minor_scan_vtype) (char *start, mword desc, SgenGrayQueue *queue);
-       void (*nopar_minor_scan_vtype) (char *start, mword desc, SgenGrayQueue *queue);
-       void (*major_scan_object) (char *start, SgenGrayQueue *queue);
-       void (*copy_object) (void **obj_slot, SgenGrayQueue *queue);
-       void (*nopar_copy_object) (void **obj_slot, SgenGrayQueue *queue);
+
+       SgenObjectOperations major_ops;
+
        void* (*alloc_object) (int size, gboolean has_references);
+       void* (*par_alloc_object) (int size, gboolean has_references);
        void (*free_pinned_object) (char *obj, size_t size);
        void (*iterate_objects) (gboolean non_pinned, gboolean pinned, IterateObjectCallbackFunc callback, void *data);
        void (*free_non_pinned_object) (char *obj, size_t size);
        void (*find_pin_queue_start_ends) (SgenGrayQueue *queue);
        void (*pin_objects) (SgenGrayQueue *queue);
+       void (*pin_major_object) (char *obj, SgenGrayQueue *queue);
        void (*scan_card_table) (SgenGrayQueue *queue);
        void (*iterate_live_block_ranges) (sgen_cardtable_block_callback callback);
        void (*init_to_space) (void);
@@ -556,12 +661,12 @@ struct _SgenMajorCollector {
 
 extern SgenMajorCollector major_collector;
 
-void mono_sgen_marksweep_init (SgenMajorCollector *collector) MONO_INTERNAL;
-void mono_sgen_marksweep_fixed_init (SgenMajorCollector *collector) MONO_INTERNAL;
-void mono_sgen_marksweep_par_init (SgenMajorCollector *collector) MONO_INTERNAL;
-void mono_sgen_marksweep_fixed_par_init (SgenMajorCollector *collector) MONO_INTERNAL;
-void mono_sgen_copying_init (SgenMajorCollector *collector) MONO_INTERNAL;
-SgenMajorCollector* mono_sgen_get_major_collector (void) MONO_INTERNAL;
+void sgen_marksweep_init (SgenMajorCollector *collector) MONO_INTERNAL;
+void sgen_marksweep_fixed_init (SgenMajorCollector *collector) MONO_INTERNAL;
+void sgen_marksweep_par_init (SgenMajorCollector *collector) MONO_INTERNAL;
+void sgen_marksweep_fixed_par_init (SgenMajorCollector *collector) MONO_INTERNAL;
+void sgen_copying_init (SgenMajorCollector *collector) MONO_INTERNAL;
+SgenMajorCollector* sgen_get_major_collector (void) MONO_INTERNAL;
 
 
 typedef struct {
@@ -586,7 +691,7 @@ typedef struct {
        gboolean (*find_address) (char *addr);
 } SgenRemeberedSet;
 
-SgenRemeberedSet *mono_sgen_get_remset (void) MONO_INTERNAL;
+SgenRemeberedSet *sgen_get_remset (void) MONO_INTERNAL;
 
 static guint /*__attribute__((noinline)) not sure if this hint is a good idea*/
 slow_object_get_size (MonoVTable *vtable, MonoObject* o)
@@ -620,7 +725,7 @@ slow_object_get_size (MonoVTable *vtable, MonoObject* o)
  * collector.
  */
 static inline guint
-mono_sgen_par_object_get_size (MonoVTable *vtable, MonoObject* o)
+sgen_par_object_get_size (MonoVTable *vtable, MonoObject* o)
 {
        mword descr = (mword)vtable->gc_descr;
        mword type = descr & 0x7;
@@ -647,51 +752,52 @@ mono_sgen_par_object_get_size (MonoVTable *vtable, MonoObject* o)
 }
 
 static inline guint
-mono_sgen_safe_object_get_size (MonoObject *obj)
+sgen_safe_object_get_size (MonoObject *obj)
 {
        char *forwarded;
 
        if ((forwarded = SGEN_OBJECT_IS_FORWARDED (obj)))
                obj = (MonoObject*)forwarded;
 
-       return mono_sgen_par_object_get_size ((MonoVTable*)SGEN_LOAD_VTABLE (obj), obj);
+       return sgen_par_object_get_size ((MonoVTable*)SGEN_LOAD_VTABLE (obj), obj);
 }
 
-const char* mono_sgen_safe_name (void* obj) MONO_INTERNAL;
+const char* sgen_safe_name (void* obj) MONO_INTERNAL;
 
-gboolean mono_sgen_object_is_live (void *obj) MONO_INTERNAL;
+gboolean sgen_object_is_live (void *obj) MONO_INTERNAL;
 
-gboolean mono_sgen_need_bridge_processing (void) MONO_INTERNAL;
-void mono_sgen_bridge_reset_data (void) MONO_INTERNAL;
-void mono_sgen_bridge_processing_stw_step (void) MONO_INTERNAL;
-void mono_sgen_bridge_processing_finish (void) MONO_INTERNAL;
-void mono_sgen_register_test_bridge_callbacks (const char *bridge_class_name) MONO_INTERNAL;
-gboolean mono_sgen_is_bridge_object (MonoObject *obj) MONO_INTERNAL;
-gboolean mono_sgen_is_bridge_class (MonoClass *class) MONO_INTERNAL;
-void mono_sgen_mark_bridge_object (MonoObject *obj) MONO_INTERNAL;
-void mono_sgen_bridge_register_finalized_object (MonoObject *object) MONO_INTERNAL;
+gboolean sgen_need_bridge_processing (void) MONO_INTERNAL;
+void sgen_bridge_reset_data (void) MONO_INTERNAL;
+void sgen_bridge_processing_stw_step (void) MONO_INTERNAL;
+void sgen_bridge_processing_finish (void) MONO_INTERNAL;
+void sgen_register_test_bridge_callbacks (const char *bridge_class_name) MONO_INTERNAL;
+gboolean sgen_is_bridge_object (MonoObject *obj) MONO_INTERNAL;
+gboolean sgen_is_bridge_class (MonoClass *class) MONO_INTERNAL;
+void sgen_mark_bridge_object (MonoObject *obj) MONO_INTERNAL;
+void sgen_bridge_register_finalized_object (MonoObject *object) MONO_INTERNAL;
 
-void mono_sgen_scan_togglerefs (CopyOrMarkObjectFunc copy_func, char *start, char *end, SgenGrayQueue *queue) MONO_INTERNAL;
-void mono_sgen_process_togglerefs (void) MONO_INTERNAL;
+void sgen_scan_togglerefs (CopyOrMarkObjectFunc copy_func, char *start, char *end, SgenGrayQueue *queue) MONO_INTERNAL;
+void sgen_process_togglerefs (void) MONO_INTERNAL;
 
 
-gboolean mono_sgen_gc_is_object_ready_for_finalization (void *object) MONO_INTERNAL;
-void mono_sgen_gc_lock (void) MONO_INTERNAL;
-void mono_sgen_gc_unlock (void) MONO_INTERNAL;
+gboolean sgen_gc_is_object_ready_for_finalization (void *object) MONO_INTERNAL;
+void sgen_gc_lock (void) MONO_INTERNAL;
+void sgen_gc_unlock (void) MONO_INTERNAL;
 
 enum {
        SPACE_MAJOR,
        SPACE_LOS
 };
 
-gboolean mono_sgen_try_alloc_space (mword size, int space) MONO_INTERNAL;
-void mono_sgen_release_space (mword size, int space) MONO_INTERNAL;
-void mono_sgen_pin_object (void *object, SgenGrayQueue *queue) MONO_INTERNAL;
+gboolean sgen_try_alloc_space (mword size, int space) MONO_INTERNAL;
+void sgen_release_space (mword size, int space) MONO_INTERNAL;
+void sgen_pin_object (void *object, SgenGrayQueue *queue) MONO_INTERNAL;
+void sgen_parallel_pin_or_update (void **ptr, void *obj, MonoVTable *vt, SgenGrayQueue *queue) MONO_INTERNAL;
 void sgen_collect_major_no_lock (const char *reason) MONO_INTERNAL;
-void mono_sgen_collect_nursery_no_lock (size_t requested_size) MONO_INTERNAL;
-void mono_sgen_minor_collect_or_expand_inner (size_t size) MONO_INTERNAL;
-gboolean mono_sgen_need_major_collection (mword space_needed) MONO_INTERNAL;
-void mono_sgen_set_pinned_from_failed_allocation (mword objsize) MONO_INTERNAL;
+void sgen_collect_nursery_no_lock (size_t requested_size) MONO_INTERNAL;
+void sgen_minor_collect_or_expand_inner (size_t size) MONO_INTERNAL;
+gboolean sgen_need_major_collection (mword space_needed) MONO_INTERNAL;
+void sgen_set_pinned_from_failed_allocation (mword objsize) MONO_INTERNAL;
 
 /* LOS */
 
@@ -709,32 +815,37 @@ struct _LOSObject {
 extern LOSObject *los_object_list;
 extern mword los_memory_usage;
 
-void mono_sgen_los_free_object (LOSObject *obj) MONO_INTERNAL;
-void* mono_sgen_los_alloc_large_inner (MonoVTable *vtable, size_t size) MONO_INTERNAL;
-void mono_sgen_los_sweep (void) MONO_INTERNAL;
-gboolean mono_sgen_ptr_is_in_los (char *ptr, char **start) MONO_INTERNAL;
-void mono_sgen_los_iterate_objects (IterateObjectCallbackFunc cb, void *user_data) MONO_INTERNAL;
-void mono_sgen_los_iterate_live_block_ranges (sgen_cardtable_block_callback callback) MONO_INTERNAL;
-void mono_sgen_los_scan_card_table (SgenGrayQueue *queue) MONO_INTERNAL;
+void sgen_los_free_object (LOSObject *obj) MONO_INTERNAL;
+void* sgen_los_alloc_large_inner (MonoVTable *vtable, size_t size) MONO_INTERNAL;
+void sgen_los_sweep (void) MONO_INTERNAL;
+gboolean sgen_ptr_is_in_los (char *ptr, char **start) MONO_INTERNAL;
+void sgen_los_iterate_objects (IterateObjectCallbackFunc cb, void *user_data) MONO_INTERNAL;
+void sgen_los_iterate_live_block_ranges (sgen_cardtable_block_callback callback) MONO_INTERNAL;
+void sgen_los_scan_card_table (SgenGrayQueue *queue) MONO_INTERNAL;
 void sgen_major_collector_scan_card_table (SgenGrayQueue *queue) MONO_INTERNAL;
-FILE *mono_sgen_get_logfile (void) MONO_INTERNAL;
+FILE *sgen_get_logfile (void) MONO_INTERNAL;
 
 /* nursery allocator */
 
-void mono_sgen_clear_nursery_fragments (void) MONO_INTERNAL;
-void mono_sgen_nursery_allocator_prepare_for_pinning (void) MONO_INTERNAL;
-void mono_sgen_clear_current_nursery_fragment (void) MONO_INTERNAL;
-void mono_sgen_nursery_allocator_set_nursery_bounds (char *nursery_start, char *nursery_end) MONO_INTERNAL;
-mword mono_sgen_build_nursery_fragments (GCMemSection *nursery_section, void **start, int num_entries) MONO_INTERNAL;
-void mono_sgen_init_nursery_allocator (void) MONO_INTERNAL;
-void mono_sgen_nursery_allocator_init_heavy_stats (void) MONO_INTERNAL;
-void mono_sgen_alloc_init_heavy_stats (void) MONO_INTERNAL;
-char* mono_sgen_nursery_alloc_get_upper_alloc_bound (void) MONO_INTERNAL;
-void* mono_sgen_nursery_alloc (size_t size) MONO_INTERNAL;
-void* mono_sgen_nursery_alloc_range (size_t size, size_t min_size, int *out_alloc_size) MONO_INTERNAL;
-MonoVTable* mono_sgen_get_array_fill_vtable (void) MONO_INTERNAL;
-gboolean mono_sgen_can_alloc_size (size_t size) MONO_INTERNAL;
-void mono_sgen_nursery_retire_region (void *address, ptrdiff_t size) MONO_INTERNAL;
+void sgen_clear_nursery_fragments (void) MONO_INTERNAL;
+void sgen_nursery_allocator_prepare_for_pinning (void) MONO_INTERNAL;
+void sgen_nursery_allocator_set_nursery_bounds (char *nursery_start, char *nursery_end) MONO_INTERNAL;
+mword sgen_build_nursery_fragments (GCMemSection *nursery_section, void **start, int num_entries) MONO_INTERNAL;
+void sgen_init_nursery_allocator (void) MONO_INTERNAL;
+void sgen_nursery_allocator_init_heavy_stats (void) MONO_INTERNAL;
+void sgen_alloc_init_heavy_stats (void) MONO_INTERNAL;
+char* sgen_nursery_alloc_get_upper_alloc_bound (void) MONO_INTERNAL;
+void* sgen_nursery_alloc (size_t size) MONO_INTERNAL;
+void* sgen_nursery_alloc_range (size_t size, size_t min_size, size_t *out_alloc_size) MONO_INTERNAL;
+MonoVTable* sgen_get_array_fill_vtable (void) MONO_INTERNAL;
+gboolean sgen_can_alloc_size (size_t size) MONO_INTERNAL;
+void sgen_nursery_retire_region (void *address, ptrdiff_t size) MONO_INTERNAL;
+
+void sgen_nursery_alloc_prepare_for_minor (void) MONO_INTERNAL;
+void sgen_nursery_alloc_prepare_for_major (const char *reason) MONO_INTERNAL;
+
+char* sgen_alloc_for_promotion (char *obj, size_t objsize, gboolean has_references) MONO_INTERNAL;
+char* sgen_par_alloc_for_promotion (char *obj, size_t objsize, gboolean has_references) MONO_INTERNAL;
 
 /* hash tables */
 
@@ -759,15 +870,15 @@ typedef struct {
 #define SGEN_HASH_TABLE_INIT(table_type,entry_type,data_size,hash_func,equal_func)     { (table_type), (entry_type), (data_size), (hash_func), (equal_func), NULL, 0, 0 }
 #define SGEN_HASH_TABLE_ENTRY_SIZE(data_size)                  ((data_size) + sizeof (SgenHashTableEntry*) + sizeof (gpointer))
 
-gpointer mono_sgen_hash_table_lookup (SgenHashTable *table, gpointer key) MONO_INTERNAL;
-gboolean mono_sgen_hash_table_replace (SgenHashTable *table, gpointer key, gpointer data) MONO_INTERNAL;
-gboolean mono_sgen_hash_table_set_value (SgenHashTable *table, gpointer key, gpointer data) MONO_INTERNAL;
-gboolean mono_sgen_hash_table_set_key (SgenHashTable *hash_table, gpointer old_key, gpointer new_key) MONO_INTERNAL;
-gboolean mono_sgen_hash_table_remove (SgenHashTable *table, gpointer key, gpointer data_return) MONO_INTERNAL;
+gpointer sgen_hash_table_lookup (SgenHashTable *table, gpointer key) MONO_INTERNAL;
+gboolean sgen_hash_table_replace (SgenHashTable *table, gpointer key, gpointer new_value, gpointer old_value) MONO_INTERNAL;
+gboolean sgen_hash_table_set_value (SgenHashTable *table, gpointer key, gpointer new_value, gpointer old_value) MONO_INTERNAL;
+gboolean sgen_hash_table_set_key (SgenHashTable *hash_table, gpointer old_key, gpointer new_key) MONO_INTERNAL;
+gboolean sgen_hash_table_remove (SgenHashTable *table, gpointer key, gpointer data_return) MONO_INTERNAL;
 
-void mono_sgen_hash_table_clean (SgenHashTable *table) MONO_INTERNAL;
+void sgen_hash_table_clean (SgenHashTable *table) MONO_INTERNAL;
 
-#define mono_sgen_hash_table_num_entries(h)    ((h)->num_entries)
+#define sgen_hash_table_num_entries(h) ((h)->num_entries)
 
 #define SGEN_HASH_TABLE_FOREACH(h,k,v) do {                            \
                SgenHashTable *__hash_table = (h);                      \
@@ -787,7 +898,7 @@ void mono_sgen_hash_table_clean (SgenHashTable *table) MONO_INTERNAL;
                __next = __iter;        \
                --__hash_table->num_entries;                            \
                if ((free))                                             \
-                       mono_sgen_free_internal (__entry, __hash_table->entry_mem_type); \
+                       sgen_free_internal (__entry, __hash_table->entry_mem_type); \
        } while (0)
 
 #define SGEN_HASH_TABLE_FOREACH_SET_KEY(k)     ((__entry)->key = (k))
@@ -885,7 +996,7 @@ extern int do_pin_stats;
 /* Nursery helpers. */
 
 static inline void
-mono_sgen_set_nursery_scan_start (char *p)
+sgen_set_nursery_scan_start (char *p)
 {
        int idx = (p - (char*)nursery_section->data) / SGEN_SCAN_START_SIZE;
        char *old = nursery_section->scan_starts [idx];
@@ -903,14 +1014,14 @@ typedef enum {
        ATYPE_NUM
 } SgenAllocatorType;
 
-void mono_sgen_init_tlab_info (SgenThreadInfo* info);
-void mono_sgen_clear_tlabs (void);
-gboolean mono_sgen_is_managed_allocator (MonoMethod *method);
+void sgen_init_tlab_info (SgenThreadInfo* info);
+void sgen_clear_tlabs (void);
+gboolean sgen_is_managed_allocator (MonoMethod *method);
 
 /* Debug support */
 
-void mono_sgen_check_consistency (void);
-void mono_sgen_check_major_refs (void);
+void sgen_check_consistency (void);
+void sgen_check_major_refs (void);
 
 
 /* Write barrier support */
@@ -919,7 +1030,7 @@ void mono_sgen_check_major_refs (void);
  * This causes the compile to extend the liveness of 'v' till the call to dummy_use
  */
 static inline void
-mono_sgen_dummy_use (gpointer v) {
+sgen_dummy_use (gpointer v) {
 #if defined(__GNUC__)
        __asm__ volatile ("" : "=r"(v) : "r"(v));
 #elif defined(_MSC_VER)
@@ -928,7 +1039,7 @@ mono_sgen_dummy_use (gpointer v) {
                and eax, eax;
        };
 #else
-#error "Implement mono_sgen_dummy_use for your compiler"
+#error "Implement sgen_dummy_use for your compiler"
 #endif
 }
 
index 04f81019254a650b2c96702c93184710b095c22b..04c66b5d0bfc0be7679afba21593e87eff6840d1 100644 (file)
@@ -30,7 +30,7 @@
 #define GRAY_QUEUE_LENGTH_LIMIT        64
 
 void
-mono_sgen_gray_object_alloc_queue_section (SgenGrayQueue *queue)
+sgen_gray_object_alloc_queue_section (SgenGrayQueue *queue)
 {
        GrayQueueSection *section;
 
@@ -43,7 +43,7 @@ mono_sgen_gray_object_alloc_queue_section (SgenGrayQueue *queue)
                queue->free_list = section->next;
        } else {
                /* Allocate a new section */
-               section = mono_sgen_alloc_internal (INTERNAL_MEM_GRAY_QUEUE);
+               section = sgen_alloc_internal (INTERNAL_MEM_GRAY_QUEUE);
        }
 
        section->end = 0;
@@ -54,9 +54,9 @@ mono_sgen_gray_object_alloc_queue_section (SgenGrayQueue *queue)
 }
 
 void
-mono_sgen_gray_object_free_queue_section (GrayQueueSection *section)
+sgen_gray_object_free_queue_section (GrayQueueSection *section)
 {
-       mono_sgen_free_internal (section, INTERNAL_MEM_GRAY_QUEUE);
+       sgen_free_internal (section, INTERNAL_MEM_GRAY_QUEUE);
 }
 
 /*
@@ -66,11 +66,11 @@ mono_sgen_gray_object_free_queue_section (GrayQueueSection *section)
  */
 
 void
-mono_sgen_gray_object_enqueue (SgenGrayQueue *queue, char *obj)
+sgen_gray_object_enqueue (SgenGrayQueue *queue, char *obj)
 {
        DEBUG (9, g_assert (obj));
        if (G_UNLIKELY (!queue->first || queue->first->end == SGEN_GRAY_QUEUE_SECTION_SIZE))
-               mono_sgen_gray_object_alloc_queue_section (queue);
+               sgen_gray_object_alloc_queue_section (queue);
        DEBUG (9, g_assert (queue->first && queue->first->end < SGEN_GRAY_QUEUE_SECTION_SIZE));
        queue->first->objects [queue->first->end++] = obj;
 
@@ -78,11 +78,11 @@ mono_sgen_gray_object_enqueue (SgenGrayQueue *queue, char *obj)
 }
 
 char*
-mono_sgen_gray_object_dequeue (SgenGrayQueue *queue)
+sgen_gray_object_dequeue (SgenGrayQueue *queue)
 {
        char *obj;
 
-       if (mono_sgen_gray_object_queue_is_empty (queue))
+       if (sgen_gray_object_queue_is_empty (queue))
                return NULL;
 
        DEBUG (9, g_assert (queue->first->end));
@@ -102,7 +102,7 @@ mono_sgen_gray_object_dequeue (SgenGrayQueue *queue)
 }
 
 GrayQueueSection*
-mono_sgen_gray_object_dequeue_section (SgenGrayQueue *queue)
+sgen_gray_object_dequeue_section (SgenGrayQueue *queue)
 {
        GrayQueueSection *section;
 
@@ -118,19 +118,19 @@ mono_sgen_gray_object_dequeue_section (SgenGrayQueue *queue)
 }
 
 void
-mono_sgen_gray_object_enqueue_section (SgenGrayQueue *queue, GrayQueueSection *section)
+sgen_gray_object_enqueue_section (SgenGrayQueue *queue, GrayQueueSection *section)
 {
        section->next = queue->first;
        queue->first = section;
 }
 
 void
-mono_sgen_gray_object_queue_init (SgenGrayQueue *queue)
+sgen_gray_object_queue_init (SgenGrayQueue *queue)
 {
        GrayQueueSection *section, *next;
        int i;
 
-       g_assert (mono_sgen_gray_object_queue_is_empty (queue));
+       g_assert (sgen_gray_object_queue_is_empty (queue));
        DEBUG (9, g_assert (queue->balance == 0));
 
        /* Free the extra sections allocated during the last collection */
@@ -142,14 +142,14 @@ mono_sgen_gray_object_queue_init (SgenGrayQueue *queue)
        while (section->next) {
                next = section->next;
                section->next = next->next;
-               mono_sgen_gray_object_free_queue_section (next);
+               sgen_gray_object_free_queue_section (next);
        }
 }
 
 void
-mono_sgen_gray_object_queue_init_with_alloc_prepare (SgenGrayQueue *queue, GrayQueueAllocPrepareFunc func, void *data)
+sgen_gray_object_queue_init_with_alloc_prepare (SgenGrayQueue *queue, GrayQueueAllocPrepareFunc func, void *data)
 {
-       mono_sgen_gray_object_queue_init (queue);
+       sgen_gray_object_queue_init (queue);
        queue->alloc_prepare_func = func;
        queue->alloc_prepare_data = data;
 }
index 2d4e76a138a87ecf004c68aba84d18662bb12f78..c69ab41d2a50b4846de54e7a5477964b0a6c1197 100644 (file)
@@ -48,18 +48,18 @@ struct _SgenGrayQueue {
        void *alloc_prepare_data;
 };
 
-void mono_sgen_gray_object_enqueue (SgenGrayQueue *queue, char *obj) MONO_INTERNAL;
-char* mono_sgen_gray_object_dequeue (SgenGrayQueue *queue) MONO_INTERNAL;
-GrayQueueSection* mono_sgen_gray_object_dequeue_section (SgenGrayQueue *queue) MONO_INTERNAL;
-void mono_sgen_gray_object_enqueue_section (SgenGrayQueue *queue, GrayQueueSection *section) MONO_INTERNAL;
-void mono_sgen_gray_object_queue_init (SgenGrayQueue *queue) MONO_INTERNAL;
-void mono_sgen_gray_object_queue_init_with_alloc_prepare (SgenGrayQueue *queue, GrayQueueAllocPrepareFunc func, void *data) MONO_INTERNAL;
-void mono_sgen_gray_object_alloc_queue_section (SgenGrayQueue *queue) MONO_INTERNAL;
-void mono_sgen_gray_object_free_queue_section (GrayQueueSection *section) MONO_INTERNAL;
-gboolean mono_sgen_drain_gray_stack (SgenGrayQueue *queue, int max_objs) MONO_INTERNAL;
+void sgen_gray_object_enqueue (SgenGrayQueue *queue, char *obj) MONO_INTERNAL;
+char* sgen_gray_object_dequeue (SgenGrayQueue *queue) MONO_INTERNAL;
+GrayQueueSection* sgen_gray_object_dequeue_section (SgenGrayQueue *queue) MONO_INTERNAL;
+void sgen_gray_object_enqueue_section (SgenGrayQueue *queue, GrayQueueSection *section) MONO_INTERNAL;
+void sgen_gray_object_queue_init (SgenGrayQueue *queue) MONO_INTERNAL;
+void sgen_gray_object_queue_init_with_alloc_prepare (SgenGrayQueue *queue, GrayQueueAllocPrepareFunc func, void *data) MONO_INTERNAL;
+void sgen_gray_object_alloc_queue_section (SgenGrayQueue *queue) MONO_INTERNAL;
+void sgen_gray_object_free_queue_section (GrayQueueSection *section) MONO_INTERNAL;
+gboolean sgen_drain_gray_stack (SgenGrayQueue *queue, int max_objs) MONO_INTERNAL;
 
 static inline gboolean
-mono_sgen_gray_object_queue_is_empty (SgenGrayQueue *queue)
+sgen_gray_object_queue_is_empty (SgenGrayQueue *queue)
 {
        return queue->first == NULL;
 }
index 8d1204371f515352033dc3786419d39b3b24075c..af829a2f262c491c9ca239fe527ddeee657484aa 100644 (file)
@@ -37,14 +37,14 @@ rehash (SgenHashTable *hash_table)
        SgenHashTableEntry *entry, *next;
 
        if (!old_hash) {
-               mono_sgen_register_fixed_internal_mem_type (hash_table->entry_mem_type,
+               sgen_register_fixed_internal_mem_type (hash_table->entry_mem_type,
                                sizeof (SgenHashTableEntry*) + sizeof (gpointer) + hash_table->data_size);
                new_size = 13;
        } else {
                new_size = g_spaced_primes_closest (hash_table->num_entries);
        }
 
-       new_hash = mono_sgen_alloc_internal_dynamic (new_size * sizeof (SgenHashTableEntry*), hash_table->table_mem_type);
+       new_hash = sgen_alloc_internal_dynamic (new_size * sizeof (SgenHashTableEntry*), hash_table->table_mem_type);
        for (i = 0; i < old_hash_size; ++i) {
                for (entry = old_hash [i]; entry; entry = next) {
                        hash = hash_table->hash_func (entry->key) % new_size;
@@ -53,7 +53,7 @@ rehash (SgenHashTable *hash_table)
                        new_hash [hash] = entry;
                }
        }
-       mono_sgen_free_internal_dynamic (old_hash, old_hash_size * sizeof (SgenHashTableEntry*), hash_table->table_mem_type);
+       sgen_free_internal_dynamic (old_hash, old_hash_size * sizeof (SgenHashTableEntry*), hash_table->table_mem_type);
        hash_table->table = new_hash;
        hash_table->size = new_size;
 }
@@ -87,7 +87,7 @@ lookup (SgenHashTable *hash_table, gpointer key, guint *_hash)
 }
 
 gpointer
-mono_sgen_hash_table_lookup (SgenHashTable *hash_table, gpointer key)
+sgen_hash_table_lookup (SgenHashTable *hash_table, gpointer key)
 {
        SgenHashTableEntry *entry = lookup (hash_table, key, NULL);
        if (!entry)
@@ -96,7 +96,7 @@ mono_sgen_hash_table_lookup (SgenHashTable *hash_table, gpointer key)
 }
 
 gboolean
-mono_sgen_hash_table_replace (SgenHashTable *hash_table, gpointer key, gpointer data)
+sgen_hash_table_replace (SgenHashTable *hash_table, gpointer key, gpointer new_value, gpointer old_value)
 {
        guint hash;
        SgenHashTableEntry *entry;
@@ -105,13 +105,15 @@ mono_sgen_hash_table_replace (SgenHashTable *hash_table, gpointer key, gpointer
        entry = lookup (hash_table, key, &hash);
 
        if (entry) {
-               memcpy (entry->data, data, hash_table->data_size);
+               if (old_value)
+                       memcpy (old_value, entry->data, hash_table->data_size); 
+               memcpy (entry->data, new_value, hash_table->data_size);
                return FALSE;
        }
 
-       entry = mono_sgen_alloc_internal (hash_table->entry_mem_type);
+       entry = sgen_alloc_internal (hash_table->entry_mem_type);
        entry->key = key;
-       memcpy (entry->data, data, hash_table->data_size);
+       memcpy (entry->data, new_value, hash_table->data_size);
 
        entry->next = hash_table->table [hash];
        hash_table->table [hash] = entry;
@@ -122,7 +124,7 @@ mono_sgen_hash_table_replace (SgenHashTable *hash_table, gpointer key, gpointer
 }
 
 gboolean
-mono_sgen_hash_table_set_value (SgenHashTable *hash_table, gpointer key, gpointer data)
+sgen_hash_table_set_value (SgenHashTable *hash_table, gpointer key, gpointer new_value, gpointer old_value)
 {
        guint hash;
        SgenHashTableEntry *entry;
@@ -130,7 +132,9 @@ mono_sgen_hash_table_set_value (SgenHashTable *hash_table, gpointer key, gpointe
        entry = lookup (hash_table, key, &hash);
 
        if (entry) {
-               memcpy (entry->data, data, hash_table->data_size);
+               if (old_value)
+                       memcpy (old_value, entry->data, hash_table->data_size);
+               memcpy (entry->data, new_value, hash_table->data_size);
                return TRUE;
        }
 
@@ -138,7 +142,7 @@ mono_sgen_hash_table_set_value (SgenHashTable *hash_table, gpointer key, gpointe
 }
 
 gboolean
-mono_sgen_hash_table_set_key (SgenHashTable *hash_table, gpointer old_key, gpointer new_key)
+sgen_hash_table_set_key (SgenHashTable *hash_table, gpointer old_key, gpointer new_key)
 {
        guint hash;
        SgenHashTableEntry *entry;
@@ -154,7 +158,7 @@ mono_sgen_hash_table_set_key (SgenHashTable *hash_table, gpointer old_key, gpoin
 }
 
 gboolean
-mono_sgen_hash_table_remove (SgenHashTable *hash_table, gpointer key, gpointer data_return)
+sgen_hash_table_remove (SgenHashTable *hash_table, gpointer key, gpointer data_return)
 {
        SgenHashTableEntry *entry, *prev;
        guint hash;
@@ -176,7 +180,7 @@ mono_sgen_hash_table_remove (SgenHashTable *hash_table, gpointer key, gpointer d
                        if (data_return)
                                memcpy (data_return, entry->data, hash_table->data_size);
 
-                       mono_sgen_free_internal (entry, hash_table->entry_mem_type);
+                       sgen_free_internal (entry, hash_table->entry_mem_type);
 
                        return TRUE;
                }
@@ -187,7 +191,7 @@ mono_sgen_hash_table_remove (SgenHashTable *hash_table, gpointer key, gpointer d
 }
 
 void
-mono_sgen_hash_table_clean (SgenHashTable *hash_table)
+sgen_hash_table_clean (SgenHashTable *hash_table)
 {
        guint i;
 
@@ -201,12 +205,12 @@ mono_sgen_hash_table_clean (SgenHashTable *hash_table)
                SgenHashTableEntry *entry = hash_table->table [i];
                while (entry) {
                        SgenHashTableEntry *next = entry->next;
-                       mono_sgen_free_internal (entry, hash_table->entry_mem_type);
+                       sgen_free_internal (entry, hash_table->entry_mem_type);
                        entry = next;
                }
        }
 
-       mono_sgen_free_internal_dynamic (hash_table->table, hash_table->size * sizeof (SgenHashTableEntry*), hash_table->table_mem_type);
+       sgen_free_internal_dynamic (hash_table->table, hash_table->size * sizeof (SgenHashTableEntry*), hash_table->table_mem_type);
 
        hash_table->table = NULL;
        hash_table->size = 0;
index c3f5767cd172e0b7e3646cffee8e805c0f6ed2e9..c499236a2c5088a7334607ca20443048950542c6 100644 (file)
@@ -65,7 +65,7 @@ index_for_size (size_t size)
 static int fixed_type_allocator_indexes [INTERNAL_MEM_MAX];
 
 void
-mono_sgen_register_fixed_internal_mem_type (int type, size_t size)
+sgen_register_fixed_internal_mem_type (int type, size_t size)
 {
        int slot;
 
@@ -81,13 +81,13 @@ mono_sgen_register_fixed_internal_mem_type (int type, size_t size)
 }
 
 void*
-mono_sgen_alloc_internal_dynamic (size_t size, int type)
+sgen_alloc_internal_dynamic (size_t size, int type)
 {
        int index;
        void *p;
 
        if (size > allocator_sizes [NUM_ALLOCATORS - 1])
-               return mono_sgen_alloc_os_memory (size, TRUE);
+               return sgen_alloc_os_memory (size, TRUE);
 
        index = index_for_size (size);
 
@@ -97,7 +97,7 @@ mono_sgen_alloc_internal_dynamic (size_t size, int type)
 }
 
 void
-mono_sgen_free_internal_dynamic (void *addr, size_t size, int type)
+sgen_free_internal_dynamic (void *addr, size_t size, int type)
 {
        int index;
 
@@ -105,7 +105,7 @@ mono_sgen_free_internal_dynamic (void *addr, size_t size, int type)
                return;
 
        if (size > allocator_sizes [NUM_ALLOCATORS - 1])
-               return mono_sgen_free_os_memory (addr, size);
+               return sgen_free_os_memory (addr, size);
 
        index = index_for_size (size);
 
@@ -113,7 +113,7 @@ mono_sgen_free_internal_dynamic (void *addr, size_t size, int type)
 }
 
 void*
-mono_sgen_alloc_internal (int type)
+sgen_alloc_internal (int type)
 {
        int index = fixed_type_allocator_indexes [type];
        void *p;
@@ -124,7 +124,7 @@ mono_sgen_alloc_internal (int type)
 }
 
 void
-mono_sgen_free_internal (void *addr, int type)
+sgen_free_internal (void *addr, int type)
 {
        int index;
 
@@ -138,7 +138,7 @@ mono_sgen_free_internal (void *addr, int type)
 }
 
 void
-mono_sgen_dump_internal_mem_usage (FILE *heap_dump_file)
+sgen_dump_internal_mem_usage (FILE *heap_dump_file)
 {
        /*
        static char const *internal_mem_names [] = { "pin-queue", "fragment", "section", "scan-starts",
@@ -160,14 +160,14 @@ mono_sgen_dump_internal_mem_usage (FILE *heap_dump_file)
 }
 
 void
-mono_sgen_report_internal_mem_usage (void)
+sgen_report_internal_mem_usage (void)
 {
        /* FIXME: implement */
        printf ("not implemented yet\n");
 }
 
 void
-mono_sgen_init_internal_allocator (void)
+sgen_init_internal_allocator (void)
 {
        int i;
 
index 67266ae0e6669b4e2fe1719c04c0419006973ad0..86183a0e8f6c3739c8a6dfed73deaeaa64e05a3c 100644 (file)
@@ -241,10 +241,10 @@ get_los_section_memory (size_t size)
        if (free_chunks)
                return (LOSObject*)free_chunks;
 
-       if (!mono_sgen_try_alloc_space (LOS_SECTION_SIZE, SPACE_LOS))
+       if (!sgen_try_alloc_space (LOS_SECTION_SIZE, SPACE_LOS))
                return NULL;
 
-       section = mono_sgen_alloc_os_memory_aligned (LOS_SECTION_SIZE, LOS_SECTION_SIZE, TRUE);
+       section = sgen_alloc_os_memory_aligned (LOS_SECTION_SIZE, LOS_SECTION_SIZE, TRUE);
 
        if (!section)
                return NULL;
@@ -304,7 +304,7 @@ free_los_section_memory (LOSObject *obj, size_t size)
 static int pagesize;
 
 void
-mono_sgen_los_free_object (LOSObject *obj)
+sgen_los_free_object (LOSObject *obj)
 {
 #ifndef LOS_DUMMY
        size_t size = obj->size;
@@ -323,8 +323,8 @@ mono_sgen_los_free_object (LOSObject *obj)
                size += sizeof (LOSObject);
                size += pagesize - 1;
                size &= ~(pagesize - 1);
-               mono_sgen_free_os_memory (obj, size);
-               mono_sgen_release_space (size, SPACE_LOS);
+               sgen_free_os_memory (obj, size);
+               sgen_release_space (size, SPACE_LOS);
        } else {
                free_los_section_memory (obj, size + sizeof (LOSObject));
 #ifdef LOS_CONSISTENCY_CHECKS
@@ -342,7 +342,7 @@ mono_sgen_los_free_object (LOSObject *obj)
  * and we avoid the memcpy overhead.
  */
 void*
-mono_sgen_los_alloc_large_inner (MonoVTable *vtable, size_t size)
+sgen_los_alloc_large_inner (MonoVTable *vtable, size_t size)
 {
        LOSObject *obj = NULL;
        void **vtslot;
@@ -351,14 +351,14 @@ mono_sgen_los_alloc_large_inner (MonoVTable *vtable, size_t size)
 
 #ifdef LOS_DUMMY
        if (!los_segment)
-               los_segment = mono_sgen_alloc_os_memory (LOS_SEGMENT_SIZE, TRUE);
+               los_segment = sgen_alloc_os_memory (LOS_SEGMENT_SIZE, TRUE);
        los_segment_index = ALIGN_UP (los_segment_index);
 
        obj = (LOSObject*)(los_segment + los_segment_index);
        los_segment_index += size + sizeof (LOSObject);
        g_assert (los_segment_index <= LOS_SEGMENT_SIZE);
 #else
-       if (mono_sgen_need_major_collection (size)) {
+       if (sgen_need_major_collection (size)) {
                DEBUG (4, fprintf (gc_debug_file, "Should trigger major collection: req size %zd (los already: %lu, limit: %lu)\n", size, (unsigned long)los_memory_usage, (unsigned long)next_los_collection));
                sgen_collect_major_no_lock ("LOS overflow");
        }
@@ -374,8 +374,8 @@ mono_sgen_los_alloc_large_inner (MonoVTable *vtable, size_t size)
                alloc_size += sizeof (LOSObject);
                alloc_size += pagesize - 1;
                alloc_size &= ~(pagesize - 1);
-               if (mono_sgen_try_alloc_space (alloc_size, SPACE_LOS)) {
-                       obj = mono_sgen_alloc_os_memory (alloc_size, TRUE);
+               if (sgen_try_alloc_space (alloc_size, SPACE_LOS)) {
+                       obj = sgen_alloc_os_memory (alloc_size, TRUE);
                        if (obj)
                                obj->huge_object = TRUE;
                }
@@ -392,7 +392,7 @@ mono_sgen_los_alloc_large_inner (MonoVTable *vtable, size_t size)
        obj->size = size;
        vtslot = (void**)obj->data;
        *vtslot = vtable;
-       mono_sgen_update_heap_boundaries ((mword)obj->data, (mword)obj->data + size);
+       sgen_update_heap_boundaries ((mword)obj->data, (mword)obj->data + size);
        obj->next = los_object_list;
        los_object_list = obj;
        los_memory_usage += size;
@@ -408,7 +408,7 @@ mono_sgen_los_alloc_large_inner (MonoVTable *vtable, size_t size)
 }
 
 void
-mono_sgen_los_sweep (void)
+sgen_los_sweep (void)
 {
        LOSSection *section, *prev;
        int i;
@@ -426,8 +426,8 @@ mono_sgen_los_sweep (void)
                                prev->next = next;
                        else
                                los_sections = next;
-                       mono_sgen_free_os_memory (section, LOS_SECTION_SIZE);
-                       mono_sgen_release_space (LOS_SECTION_SIZE, SPACE_LOS);
+                       sgen_free_os_memory (section, LOS_SECTION_SIZE);
+                       sgen_release_space (LOS_SECTION_SIZE, SPACE_LOS);
                        section = next;
                        --los_num_sections;
                        continue;
@@ -468,7 +468,7 @@ mono_sgen_los_sweep (void)
 }
 
 gboolean
-mono_sgen_ptr_is_in_los (char *ptr, char **start)
+sgen_ptr_is_in_los (char *ptr, char **start)
 {
        LOSObject *obj;
 
@@ -485,7 +485,7 @@ mono_sgen_ptr_is_in_los (char *ptr, char **start)
 }
 
 void
-mono_sgen_los_iterate_objects (IterateObjectCallbackFunc cb, void *user_data)
+sgen_los_iterate_objects (IterateObjectCallbackFunc cb, void *user_data)
 {
        LOSObject *obj;
 
@@ -494,7 +494,7 @@ mono_sgen_los_iterate_objects (IterateObjectCallbackFunc cb, void *user_data)
 }
 
 void
-mono_sgen_los_iterate_live_block_ranges (sgen_cardtable_block_callback callback)
+sgen_los_iterate_live_block_ranges (sgen_cardtable_block_callback callback)
 {
        LOSObject *obj;
        for (obj = los_object_list; obj; obj = obj->next) {
@@ -506,7 +506,7 @@ mono_sgen_los_iterate_live_block_ranges (sgen_cardtable_block_callback callback)
 
 #ifdef SGEN_HAVE_CARDTABLE
 void
-mono_sgen_los_scan_card_table (SgenGrayQueue *queue)
+sgen_los_scan_card_table (SgenGrayQueue *queue)
 {
        LOSObject *obj;
 
index 40bbe2561fb3695dca1f3f22542b5927b505d4d8..ba2a5013f9585283576b321cd60f1e844e6e0f38 100644 (file)
  * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
  * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  */
-extern long long stat_copy_object_called_nursery;
-extern long long stat_objects_copied_nursery;
 
-extern long long stat_nursery_copy_object_failed_from_space;
-extern long long stat_nursery_copy_object_failed_forwarded;
-extern long long stat_nursery_copy_object_failed_pinned;
+#define collector_pin_object(obj, queue) do { \
+       if (sgen_ptr_in_nursery (obj)) {        \
+               sgen_pin_object (obj, queue);   \
+       } else {        \
+               g_assert (objsize <= SGEN_MAX_SMALL_OBJ_SIZE);  \
+               pin_major_object (obj, queue);  \
+       }       \
+} while (0)
 
-/*
- * This function can be used even if the vtable of obj is not valid
- * anymore, which is the case in the parallel collector.
- */
-static void
-par_copy_object_no_checks (char *destination, MonoVTable *vt, void *obj, mword objsize, SgenGrayQueue *queue)
-{
-       static const void *copy_labels [] = { &&LAB_0, &&LAB_1, &&LAB_2, &&LAB_3, &&LAB_4, &&LAB_5, &&LAB_6, &&LAB_7, &&LAB_8 };
-
-       DEBUG (9, g_assert (vt->klass->inited));
-       DEBUG (9, fprintf (gc_debug_file, " (to %p, %s size: %lu)\n", destination, ((MonoObject*)obj)->vtable->klass->name, (unsigned long)objsize));
-       binary_protocol_copy (obj, destination, vt, objsize);
-
-       if (objsize <= sizeof (gpointer) * 8) {
-               mword *dest = (mword*)destination;
-               goto *copy_labels [objsize / sizeof (gpointer)];
-       LAB_8:
-               (dest) [7] = ((mword*)obj) [7];
-       LAB_7:
-               (dest) [6] = ((mword*)obj) [6];
-       LAB_6:
-               (dest) [5] = ((mword*)obj) [5];
-       LAB_5:
-               (dest) [4] = ((mword*)obj) [4];
-       LAB_4:
-               (dest) [3] = ((mword*)obj) [3];
-       LAB_3:
-               (dest) [2] = ((mword*)obj) [2];
-       LAB_2:
-               (dest) [1] = ((mword*)obj) [1];
-       LAB_1:
-               ;
-       LAB_0:
-               ;
-       } else {
-               /*can't trust memcpy doing word copies */
-               mono_gc_memmove (destination + sizeof (mword), (char*)obj + sizeof (mword), objsize - sizeof (mword));
-       }
-       /* adjust array->bounds */
-       DEBUG (9, g_assert (vt->gc_descr));
-       if (G_UNLIKELY (vt->rank && ((MonoArray*)obj)->bounds)) {
-               MonoArray *array = (MonoArray*)destination;
-               array->bounds = (MonoArrayBounds*)((char*)destination + ((char*)((MonoArray*)obj)->bounds - (char*)obj));
-               DEBUG (9, fprintf (gc_debug_file, "Array instance %p: size: %lu, rank: %d, length: %lu\n", array, (unsigned long)objsize, vt->rank, (unsigned long)mono_array_length (array)));
-       }
-       if (G_UNLIKELY (mono_profiler_events & MONO_PROFILE_GC_MOVES))
-               mono_sgen_register_moved_object (obj, destination);
-       obj = destination;
-       if (queue) {
-               DEBUG (9, fprintf (gc_debug_file, "Enqueuing gray object %p (%s)\n", obj, mono_sgen_safe_name (obj)));
-               GRAY_OBJECT_ENQUEUE (queue, obj);
-       }
-}
-
-static void*
-copy_object_no_checks (void *obj, SgenGrayQueue *queue)
-{
-       MonoVTable *vt = ((MonoObject*)obj)->vtable;
-       gboolean has_references = SGEN_VTABLE_HAS_REFERENCES (vt);
-       mword objsize = SGEN_ALIGN_UP (mono_sgen_par_object_get_size (vt, (MonoObject*)obj));
-       char *destination = major_alloc_object (objsize, has_references);
-
-       if (G_UNLIKELY (!destination)) {
-               if (mono_sgen_ptr_in_nursery (obj)) {
-                       mono_sgen_pin_object (obj, queue);
-               } else {
-                       g_assert (objsize <= SGEN_MAX_SMALL_OBJ_SIZE);
-                       pin_major_object (obj, queue);
-               }
-               mono_sgen_set_pinned_from_failed_allocation (objsize);
-               return obj;
-       }
-
-       *(MonoVTable**)destination = vt;
-       par_copy_object_no_checks (destination, vt, obj, objsize, has_references ? queue : NULL);
-
-       /* set the forwarding pointer */
-       SGEN_FORWARD_OBJECT (obj, destination);
-
-       return destination;
-}
-
-/*
- * This is how the copying happens from the nursery to the old generation.
- * We assume that at this time all the pinned objects have been identified and
- * marked as such.
- * We run scan_object() for each pinned object so that each referenced
- * objects if possible are copied. The new gray objects created can have
- * scan_object() run on them right away, too.
- * Then we run copy_object() for the precisely tracked roots. At this point
- * all the roots are either gray or black. We run scan_object() on the gray
- * objects until no more gray objects are created.
- * At the end of the process we walk again the pinned list and we unmark
- * the pinned flag. As we go we also create the list of free space for use
- * in the next allocation runs.
- *
- * We need to remember objects from the old generation that point to the new one
- * (or just addresses?).
- *
- * copy_object could be made into a macro once debugged (use inline for now).
- */
-
-static void
-nopar_copy_object (void **obj_slot, SgenGrayQueue *queue)
-{
-       char *forwarded;
-       char *obj = *obj_slot;
-
-       DEBUG (9, g_assert (current_collection_generation == GENERATION_NURSERY));
-
-       HEAVY_STAT (++stat_copy_object_called_nursery);
-
-       if (!mono_sgen_ptr_in_nursery (obj)) {
-               HEAVY_STAT (++stat_nursery_copy_object_failed_from_space);
-               return;
-       }
-
-       DEBUG (9, fprintf (gc_debug_file, "Precise copy of %p from %p", obj, obj_slot));
-
-       /*
-        * Before we can copy the object we must make sure that we are
-        * allowed to, i.e. that the object not pinned or not already
-        * forwarded.
-        */
-
-       if ((forwarded = SGEN_OBJECT_IS_FORWARDED (obj))) {
-               DEBUG (9, g_assert (((MonoVTable*)SGEN_LOAD_VTABLE(obj))->gc_descr));
-               DEBUG (9, fprintf (gc_debug_file, " (already forwarded to %p)\n", forwarded));
-               HEAVY_STAT (++stat_nursery_copy_object_failed_forwarded);
-               *obj_slot = forwarded;
-               return;
-       }
-       if (SGEN_OBJECT_IS_PINNED (obj)) {
-               DEBUG (9, g_assert (((MonoVTable*)SGEN_LOAD_VTABLE(obj))->gc_descr));
-               DEBUG (9, fprintf (gc_debug_file, " (pinned, no change)\n"));
-               HEAVY_STAT (++stat_nursery_copy_object_failed_pinned);
-               return;
-       }
-
-       HEAVY_STAT (++stat_objects_copied_nursery);
-
-       *obj_slot = copy_object_no_checks (obj, queue);
-}
-
-#ifdef SGEN_PARALLEL_MARK
-static void
-copy_object (void **obj_slot, SgenGrayQueue *queue)
-{
-       char *obj = *obj_slot;
-       mword vtable_word, objsize;
-       MonoVTable *vt;
-       void *destination;
-       gboolean has_references;
-
-       DEBUG (9, g_assert (current_collection_generation == GENERATION_NURSERY));
-
-       HEAVY_STAT (++stat_copy_object_called_nursery);
-
-       if (!mono_sgen_ptr_in_nursery (obj)) {
-               HEAVY_STAT (++stat_nursery_copy_object_failed_from_space);
-               return;
-       }
-
-       vtable_word = *(mword*)obj;
-       vt = (MonoVTable*)(vtable_word & ~SGEN_VTABLE_BITS_MASK);
-
-       /*
-        * Before we can copy the object we must make sure that we are
-        * allowed to, i.e. that the object not pinned or not already
-        * forwarded.
-        */
-
-       if (vtable_word & SGEN_FORWARDED_BIT) {
-               HEAVY_STAT (++stat_nursery_copy_object_failed_forwarded);
-               *obj_slot = vt;
-               return;
-       }
-       if (vtable_word & SGEN_PINNED_BIT) {
-               HEAVY_STAT (++stat_nursery_copy_object_failed_pinned);
-               return;
-       }
-
-       HEAVY_STAT (++stat_objects_copied_nursery);
-
-       objsize = SGEN_ALIGN_UP (mono_sgen_par_object_get_size (vt, (MonoObject*)obj));
-       has_references = SGEN_VTABLE_HAS_REFERENCES (vt);
-
-       destination = alloc_obj_par (objsize, FALSE, has_references);
-
-       if (G_UNLIKELY (!destination)) {
-               pin_or_update_par (obj_slot, obj, vt, queue);
-               return;
-       }
-
-       *(MonoVTable**)destination = vt;
-
-       if (SGEN_CAS_PTR ((void*)obj, (void*)((mword)destination | SGEN_FORWARDED_BIT), vt) == vt) {
-               par_copy_object_no_checks (destination, vt, obj, objsize, has_references ? queue : NULL);
-               obj = destination;
-               *obj_slot = obj;
-       } else {
-               /* FIXME: unify with code in major_copy_or_mark_object() */
-
-               /* FIXME: Give destination back to the allocator. */
-               *(void**)destination = NULL;
-
-               vtable_word = *(mword*)obj;
-               g_assert (vtable_word & SGEN_FORWARDED_BIT);
-
-               obj = (void*)(vtable_word & ~SGEN_VTABLE_BITS_MASK);
-
-               *obj_slot = obj;
+#define collector_serial_alloc_for_promotion sgen_minor_collector.alloc_for_promotion
+#define collector_parallel_alloc_for_promotion sgen_minor_collector.par_alloc_for_promotion
 
-               ++stat_slots_allocated_in_vain;
-       }
-}
-#else
-static void
-copy_object (void **obj_slot, SgenGrayQueue *queue)
-{
-       nopar_copy_object (obj_slot, queue);
-}
-#endif
 
-#define FILL_COLLECTOR_COPY_OBJECT(collector)  do {                    \
-               (collector)->copy_object = copy_object;                 \
-               (collector)->nopar_copy_object = nopar_copy_object;     \
-       } while (0)
+#include "sgen-copy-object.h"
\ No newline at end of file
index d91a4f76d812300115aae22f089b91c16896d6c0..b0827543d4c9988616ccccf11bcbba9bd6c884f9 100644 (file)
@@ -97,9 +97,9 @@ static void*
 major_alloc_heap (mword nursery_size, mword nursery_align, int the_nursery_bits)
 {
        if (nursery_align)
-               nursery_start = mono_sgen_alloc_os_memory_aligned (nursery_size, nursery_align, TRUE);
+               nursery_start = sgen_alloc_os_memory_aligned (nursery_size, nursery_align, TRUE);
        else
-               nursery_start = mono_sgen_alloc_os_memory (nursery_size, TRUE);
+               nursery_start = sgen_alloc_os_memory (nursery_size, TRUE);
 
        nursery_end = nursery_start + nursery_size;
        nursery_bits = the_nursery_bits;
@@ -116,7 +116,7 @@ obj_is_from_pinned_alloc (char *p)
 static void
 free_pinned_object (char *obj, size_t size)
 {
-       mono_sgen_free_pinned (&pinned_allocator, obj, size);
+       sgen_free_pinned (&pinned_allocator, obj, size);
 }
 
 /*
@@ -128,15 +128,15 @@ alloc_major_section (void)
        GCMemSection *section;
        int scan_starts;
 
-       section = mono_sgen_alloc_os_memory_aligned (MAJOR_SECTION_SIZE, MAJOR_SECTION_SIZE, TRUE);
+       section = sgen_alloc_os_memory_aligned (MAJOR_SECTION_SIZE, MAJOR_SECTION_SIZE, TRUE);
        section->next_data = section->data = (char*)section + SGEN_SIZEOF_GC_MEM_SECTION;
        g_assert (!((mword)section->data & 7));
        section->size = MAJOR_SECTION_SIZE - SGEN_SIZEOF_GC_MEM_SECTION;
        section->end_data = section->data + section->size;
-       mono_sgen_update_heap_boundaries ((mword)section->data, (mword)section->end_data);
-       DEBUG (3, fprintf (gc_debug_file, "New major heap section: (%p-%p), total: %ld\n", section->data, section->end_data, mono_gc_get_heap_size ()));
+       sgen_update_heap_boundaries ((mword)section->data, (mword)section->end_data);
+       DEBUG (3, fprintf (gc_debug_file, "New major heap section: (%p-%p), total: %lld\n", section->data, section->end_data, mono_gc_get_heap_size ()));
        scan_starts = (section->size + SGEN_SCAN_START_SIZE - 1) / SGEN_SCAN_START_SIZE;
-       section->scan_starts = mono_sgen_alloc_internal_dynamic (sizeof (char*) * scan_starts, INTERNAL_MEM_SCAN_STARTS);
+       section->scan_starts = sgen_alloc_internal_dynamic (sizeof (char*) * scan_starts, INTERNAL_MEM_SCAN_STARTS);
        section->num_scan_start = scan_starts;
        section->block.role = MEMORY_ROLE_GEN1;
        section->is_to_space = TRUE;
@@ -154,9 +154,9 @@ static void
 free_major_section (GCMemSection *section)
 {
        DEBUG (3, fprintf (gc_debug_file, "Freed major section %p (%p-%p)\n", section, section->data, section->end_data));
-       mono_sgen_free_internal_dynamic (section->scan_starts,
+       sgen_free_internal_dynamic (section->scan_starts,
                        (section->size + SGEN_SCAN_START_SIZE - 1) / SGEN_SCAN_START_SIZE * sizeof (char*), INTERNAL_MEM_SCAN_STARTS);
-       mono_sgen_free_os_memory (section, MAJOR_SECTION_SIZE);
+       sgen_free_os_memory (section, MAJOR_SECTION_SIZE);
 
        --num_major_sections;
 }
@@ -228,7 +228,7 @@ major_is_object_live (char *obj)
        if (ptr_in_nursery (obj))
                return FALSE;
 
-       objsize = SGEN_ALIGN_UP (mono_sgen_safe_object_get_size ((MonoObject*)obj));
+       objsize = SGEN_ALIGN_UP (sgen_safe_object_get_size ((MonoObject*)obj));
 
        /* LOS */
        if (objsize > SGEN_MAX_SMALL_OBJ_SIZE)
@@ -246,7 +246,7 @@ major_is_object_live (char *obj)
 static void*
 major_alloc_small_pinned_obj (size_t size, gboolean has_references)
 {
-       return mono_sgen_alloc_pinned (&pinned_allocator, size);
+       return sgen_alloc_pinned (&pinned_allocator, size);
 }
 
 /*
@@ -271,7 +271,7 @@ major_alloc_degraded (MonoVTable *vtable, size_t size)
                section->is_to_space = FALSE;
                /* FIXME: handle OOM */
                p = (void**)section->next_data;
-               mono_sgen_register_major_sections_alloced (1);
+               sgen_register_major_sections_alloced (1);
        }
        section->next_data += size;
        DEBUG (3, fprintf (gc_debug_file, "Allocated (degraded) object %p, vtable: %p (%s), size: %zd in section %p\n", p, vtable, vtable->klass->name, size, section));
@@ -279,7 +279,11 @@ major_alloc_degraded (MonoVTable *vtable, size_t size)
        return p;
 }
 
-#define pin_major_object       mono_sgen_pin_object
+static inline void
+pin_major_object (char *obj, SgenGrayQueue *queue)
+{
+       sgen_pin_object (obj, queue);
+}
 
 #include "sgen-major-copy-object.h"
 
@@ -310,8 +314,8 @@ major_copy_or_mark_object (void **obj_slot, SgenGrayQueue *queue)
         *
         * Before we can copy the object we must make sure that we are
         * allowed to, i.e. that the object not pinned, not already
-        * forwarded and doesn't belong to the LOS, a pinned chunk, or
-        * a to-space section.
+        * forwarded, not in the nursery To Space and doesn't belong
+        * to the LOS, a pinned chunk, or a to-space section.
         *
         * We are usually called for to-space objects (5) when we have
         * two remset entries for the same reference.  The first entry
@@ -335,8 +339,12 @@ major_copy_or_mark_object (void **obj_slot, SgenGrayQueue *queue)
                return;
        }
 
-       if (ptr_in_nursery (obj))
+       if (ptr_in_nursery (obj)) {
+               /* A To Space object is already on its final destination for the current collection. */
+               if (sgen_nursery_is_to_space (obj))
+                       return;
                goto copy;
+       }
 
        /*
         * At this point we know obj is not pinned, not forwarded and
@@ -354,13 +362,13 @@ major_copy_or_mark_object (void **obj_slot, SgenGrayQueue *queue)
         * see whether it's a pinned chunk or a major heap section.
         */
 
-       objsize = SGEN_ALIGN_UP (mono_sgen_safe_object_get_size ((MonoObject*)obj));
+       objsize = SGEN_ALIGN_UP (sgen_safe_object_get_size ((MonoObject*)obj));
 
        if (G_UNLIKELY (objsize > SGEN_MAX_SMALL_OBJ_SIZE || obj_is_from_pinned_alloc (obj))) {
                if (SGEN_OBJECT_IS_PINNED (obj))
                        return;
-               DEBUG (9, fprintf (gc_debug_file, " (marked LOS/Pinned %p (%s), size: %zd)\n", obj, mono_sgen_safe_name (obj), objsize));
-               binary_protocol_pin (obj, (gpointer)SGEN_LOAD_VTABLE (obj), mono_sgen_safe_object_get_size ((MonoObject*)obj));
+               DEBUG (9, fprintf (gc_debug_file, " (marked LOS/Pinned %p (%s), size: %td)\n", obj, sgen_safe_name (obj), objsize));
+               binary_protocol_pin (obj, (gpointer)SGEN_LOAD_VTABLE (obj), sgen_safe_object_get_size ((MonoObject*)obj));
                SGEN_PIN_OBJECT (obj);
                GRAY_OBJECT_ENQUEUE (queue, obj);
                HEAVY_STAT (++stat_major_copy_object_failed_large_pinned);
@@ -416,7 +424,7 @@ build_section_fragments (GCMemSection *section)
                        binary_protocol_empty (frag_start, frag_size);
                        memset (frag_start, 0, frag_size);
                }
-               frag_size = SGEN_ALIGN_UP (mono_sgen_safe_object_get_size ((MonoObject*)section->pin_queue_start [i]));
+               frag_size = SGEN_ALIGN_UP (sgen_safe_object_get_size ((MonoObject*)section->pin_queue_start [i]));
                frag_start = (char*)section->pin_queue_start [i] + frag_size;
                section->next_data = MAX (section->next_data, frag_start);
        }
@@ -433,9 +441,9 @@ sweep_pinned_objects_callback (char *ptr, size_t size, void *data)
 {
        if (SGEN_OBJECT_IS_PINNED (ptr)) {
                SGEN_UNPIN_OBJECT (ptr);
-               DEBUG (6, fprintf (gc_debug_file, "Unmarked pinned object %p (%s)\n", ptr, mono_sgen_safe_name (ptr)));
+               DEBUG (6, fprintf (gc_debug_file, "Unmarked pinned object %p (%s)\n", ptr, sgen_safe_name (ptr)));
        } else {
-               DEBUG (6, fprintf (gc_debug_file, "Freeing unmarked pinned object %p (%s)\n", ptr, mono_sgen_safe_name (ptr)));
+               DEBUG (6, fprintf (gc_debug_file, "Freeing unmarked pinned object %p (%s)\n", ptr, sgen_safe_name (ptr)));
                free_pinned_object (ptr, size);
        }
 }
@@ -443,7 +451,7 @@ sweep_pinned_objects_callback (char *ptr, size_t size, void *data)
 static void
 sweep_pinned_objects (void)
 {
-       mono_sgen_pinned_scan_objects (&pinned_allocator, sweep_pinned_objects_callback, NULL);
+       sgen_pinned_scan_objects (&pinned_allocator, sweep_pinned_objects_callback, NULL);
 }
 
 static void
@@ -452,10 +460,10 @@ major_iterate_objects (gboolean non_pinned, gboolean pinned, IterateObjectCallba
        if (non_pinned) {
                GCMemSection *section;
                for (section = section_list; section; section = section->block.next)
-                       mono_sgen_scan_area_with_callback (section->data, section->end_data, callback, data, FALSE);
+                       sgen_scan_area_with_callback (section->data, section->end_data, callback, data, FALSE);
        }
        if (pinned)
-               mono_sgen_pinned_scan_objects (&pinned_allocator, callback, data);
+               sgen_pinned_scan_objects (&pinned_allocator, callback, data);
 }
 
 static void
@@ -467,12 +475,12 @@ major_free_non_pinned_object (char *obj, size_t size)
 static void
 pin_pinned_object_callback (void *addr, size_t slot_size, SgenGrayQueue *queue)
 {
-       binary_protocol_pin (addr, (gpointer)SGEN_LOAD_VTABLE (addr), mono_sgen_safe_object_get_size ((MonoObject*)addr));
+       binary_protocol_pin (addr, (gpointer)SGEN_LOAD_VTABLE (addr), sgen_safe_object_get_size ((MonoObject*)addr));
        if (!SGEN_OBJECT_IS_PINNED (addr))
-               mono_sgen_pin_stats_register_object ((char*) addr, mono_sgen_safe_object_get_size ((MonoObject*) addr));
+               sgen_pin_stats_register_object ((char*) addr, sgen_safe_object_get_size ((MonoObject*) addr));
        SGEN_PIN_OBJECT (addr);
        GRAY_OBJECT_ENQUEUE (queue, addr);
-       DEBUG (6, fprintf (gc_debug_file, "Marked pinned object %p (%s) from roots\n", addr, mono_sgen_safe_name (addr)));
+       DEBUG (6, fprintf (gc_debug_file, "Marked pinned object %p (%s) from roots\n", addr, sgen_safe_name (addr)));
 }
 
 static void
@@ -481,8 +489,8 @@ major_find_pin_queue_start_ends (SgenGrayQueue *queue)
        GCMemSection *section;
 
        for (section = section_list; section; section = section->block.next)
-               mono_sgen_find_section_pin_queue_start_end (section);
-       mono_sgen_pinned_scan_pinned_objects (&pinned_allocator, (IterateObjectCallbackFunc)pin_pinned_object_callback, queue);
+               sgen_find_section_pin_queue_start_end (section);
+       sgen_pinned_scan_pinned_objects (&pinned_allocator, (IterateObjectCallbackFunc)pin_pinned_object_callback, queue);
 }
 
 static void
@@ -491,7 +499,7 @@ major_pin_objects (SgenGrayQueue *queue)
        GCMemSection *section;
 
        for (section = section_list; section; section = section->block.next)
-               mono_sgen_pin_objects_in_section (section, queue);
+               sgen_pin_objects_in_section (section, queue);
 }
 
 static void
@@ -511,7 +519,7 @@ major_sweep (void)
        /* unpin objects from the pinned chunks and free the unmarked ones */
        sweep_pinned_objects ();
 
-       mono_sgen_pinned_update_heap_boundaries (&pinned_allocator);
+       sgen_pinned_update_heap_boundaries (&pinned_allocator);
 
        /* free the unused sections */
        prev_section = NULL;
@@ -545,7 +553,7 @@ major_sweep (void)
                section = section->block.next;
 
        update:
-               mono_sgen_update_heap_boundaries ((mword)this_section->data, (mword)this_section->data + this_section->size);
+               sgen_update_heap_boundaries ((mword)this_section->data, (mword)this_section->data + this_section->size);
        }
 
        have_swept = TRUE;
@@ -556,7 +564,7 @@ major_check_scan_starts (void)
 {
        GCMemSection *section;
        for (section = section_list; section; section = section->block.next)
-               mono_sgen_check_section_scan_starts (section);
+               sgen_check_section_scan_starts (section);
 }
 
 static void
@@ -564,7 +572,7 @@ major_dump_heap (FILE *heap_dump_file)
 {
        GCMemSection *section;
        for (section = section_list; section; section = section->block.next)
-               mono_sgen_dump_section (section, "old");
+               sgen_dump_section (section, "old");
        /* FIXME: dump pinned sections, too */
 }
 
@@ -612,7 +620,7 @@ major_finish_nursery_collection (void)
                section->is_to_space = FALSE;
 
        sections_alloced = num_major_sections - old_num_major_sections;
-       mono_sgen_register_major_sections_alloced (sections_alloced);
+       sgen_register_major_sections_alloced (sections_alloced);
 }
 
 static void
@@ -635,7 +643,7 @@ major_ptr_is_in_non_pinned_space (char *ptr)
 static void
 major_report_pinned_memory_usage (void)
 {
-       mono_sgen_report_pinned_mem_usage (&pinned_allocator);
+       sgen_report_pinned_mem_usage (&pinned_allocator);
 }
 
 static int
@@ -645,7 +653,7 @@ get_num_major_sections (void)
 }
 
 void
-mono_sgen_copying_init (SgenMajorCollector *collector)
+sgen_copying_init (SgenMajorCollector *collector)
 {
 #ifdef HEAVY_STATISTICS
        mono_counters_register ("# major copy_object() failed forwarded", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_major_copy_object_failed_forwarded);
@@ -664,13 +672,13 @@ mono_sgen_copying_init (SgenMajorCollector *collector)
        collector->is_object_live = major_is_object_live;
        collector->alloc_small_pinned_obj = major_alloc_small_pinned_obj;
        collector->alloc_degraded = major_alloc_degraded;
-       collector->copy_or_mark_object = major_copy_or_mark_object;
        collector->alloc_object = major_alloc_object;
        collector->free_pinned_object = free_pinned_object;
        collector->iterate_objects = major_iterate_objects;
        collector->free_non_pinned_object = major_free_non_pinned_object;
        collector->find_pin_queue_start_ends = major_find_pin_queue_start_ends;
        collector->pin_objects = major_pin_objects;
+       collector->pin_major_object = pin_major_object;
        collector->init_to_space = major_init_to_space;
        collector->sweep = major_sweep;
        collector->check_scan_starts = major_check_scan_starts;
@@ -686,8 +694,8 @@ mono_sgen_copying_init (SgenMajorCollector *collector)
        collector->handle_gc_param = NULL;
        collector->print_gc_param_usage = NULL;
 
-       FILL_COLLECTOR_COPY_OBJECT (collector);
-       FILL_COLLECTOR_SCAN_OBJECT (collector);
+       collector->major_ops.copy_or_mark_object = major_copy_or_mark_object;
+       collector->major_ops.scan_object = major_scan_object;
 }
 
 #endif
index d254915064c22cc9daa4d9cc242589778ea094ce..9266a6cae241dfd8e1de79f08d200937dd8b9f14 100644 (file)
  * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
  * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  */
-extern long long stat_scan_object_called_nursery;
 extern long long stat_scan_object_called_major;
 
-#undef HANDLE_PTR
-#define HANDLE_PTR(ptr,obj)    do {    \
-               void *__old = *(ptr);   \
-               void *__copy;           \
-               if (__old) {    \
-                       copy_object ((ptr), queue);     \
-                       __copy = *(ptr);        \
-                       DEBUG (9, if (__old != __copy) fprintf (gc_debug_file, "Overwrote field at %p with %p (was: %p)\n", (ptr), *(ptr), __old));     \
-                       if (G_UNLIKELY (mono_sgen_ptr_in_nursery (__copy) && !mono_sgen_ptr_in_nursery ((ptr)))) \
-                               mono_sgen_add_to_global_remset ((ptr)); \
-               }       \
-       } while (0)
-
-/*
- * Scan the object pointed to by @start for references to
- * other objects between @from_start and @from_end and copy
- * them to the gray_objects area.
- */
-static void
-minor_scan_object (char *start, SgenGrayQueue *queue)
-{
-#include "sgen-scan-object.h"
-
-       HEAVY_STAT (++stat_scan_object_called_nursery);
-}
-
-/*
- * scan_vtype:
- *
- * Scan the valuetype pointed to by START, described by DESC for references to
- * other objects between @from_start and @from_end and copy them to the gray_objects area.
- * Returns a pointer to the end of the object.
- */
-static void
-minor_scan_vtype (char *start, mword desc, SgenGrayQueue *queue)
-{
-       /* The descriptors include info about the MonoObject header as well */
-       start -= sizeof (MonoObject);
-
-#define SCAN_OBJECT_NOVTABLE
-#include "sgen-scan-object.h"
-}
-
-#undef HANDLE_PTR
-#define HANDLE_PTR(ptr,obj)    do {    \
-               void *__old = *(ptr);   \
-               void *__copy;           \
-               if (__old) {    \
-                       nopar_copy_object ((ptr), queue);       \
-                       __copy = *(ptr);        \
-                       DEBUG (9, if (__old != __copy) fprintf (gc_debug_file, "Overwrote field at %p with %p (was: %p)\n", (ptr), *(ptr), __old));     \
-                       if (G_UNLIKELY (mono_sgen_ptr_in_nursery (__copy) && !mono_sgen_ptr_in_nursery ((ptr)))) \
-                               mono_sgen_add_to_global_remset ((ptr)); \
-               }       \
-       } while (0)
-
-static void
-nopar_minor_scan_object (char *start, SgenGrayQueue *queue)
-{
-#include "sgen-scan-object.h"
-
-       HEAVY_STAT (++stat_scan_object_called_nursery);
-}
-
-static void
-nopar_minor_scan_vtype (char *start, mword desc, SgenGrayQueue *queue)
-{
-       /* The descriptors include info about the MonoObject header as well */
-       start -= sizeof (MonoObject);
-
-#define SCAN_OBJECT_NOVTABLE
-#include "sgen-scan-object.h"
-}
-
 #ifdef FIXED_HEAP
 #define PREFETCH_DYNAMIC_HEAP(addr)
 #else
@@ -112,9 +37,9 @@ nopar_minor_scan_vtype (char *start, mword desc, SgenGrayQueue *queue)
                        PREFETCH_DYNAMIC_HEAP (__old);                  \
                        major_copy_or_mark_object ((ptr), queue);       \
                        __copy = *(ptr);                                \
-                       DEBUG (9, if (__old != __copy) mono_sgen_debug_printf (9, "Overwrote field at %p with %p (was: %p)\n", (ptr), *(ptr), __old)); \
-                       if (G_UNLIKELY (mono_sgen_ptr_in_nursery (__copy) && !mono_sgen_ptr_in_nursery ((ptr)))) \
-                               mono_sgen_add_to_global_remset ((ptr)); \
+                       DEBUG (9, if (__old != __copy) sgen_debug_printf (9, "Overwrote field at %p with %p (was: %p)\n", (ptr), *(ptr), __old)); \
+                       if (G_UNLIKELY (sgen_ptr_in_nursery (__copy) && !sgen_ptr_in_nursery ((ptr)))) \
+                               sgen_add_to_global_remset ((ptr));      \
                }                                                       \
        } while (0)
 
@@ -125,11 +50,3 @@ major_scan_object (char *start, SgenGrayQueue *queue)
 
        HEAVY_STAT (++stat_scan_object_called_major);
 }
-
-#define FILL_COLLECTOR_SCAN_OBJECT(collector)  do {                    \
-               (collector)->major_scan_object = major_scan_object;     \
-               (collector)->minor_scan_object = minor_scan_object;     \
-               (collector)->nopar_minor_scan_object = nopar_minor_scan_object; \
-               (collector)->minor_scan_vtype = minor_scan_vtype;       \
-               (collector)->nopar_minor_scan_vtype = nopar_minor_scan_vtype; \
-       } while (0)
index 7098576736649a12b33dd63b655c5c12b9fdb52e..343f71e04b5f82b919acdc17c5f3c7f286904f8c 100644 (file)
@@ -217,9 +217,6 @@ static long long stat_major_blocks_alloced = 0;
 static long long stat_major_blocks_freed = 0;
 static long long stat_major_objects_evacuated = 0;
 static long long stat_time_wait_for_sweep = 0;
-#ifdef SGEN_PARALLEL_MARK
-static long long stat_slots_allocated_in_vain = 0;
-#endif
 
 static gboolean ms_sweep_in_progress = FALSE;
 static MonoNativeThreadId ms_sweep_thread;
@@ -279,7 +276,7 @@ ms_find_block_obj_size_index (int size)
        for (i = 0; i < num_block_obj_sizes; ++i)
                if (block_obj_sizes [i] >= size)
                        return i;
-       g_assert_not_reached ();
+       g_error ("no object of size %d\n", size);
 }
 
 #define FREE_BLOCKS_FROM(lists,p,r)    (lists [((p) ? MS_BLOCK_FLAG_PINNED : 0) | ((r) ? MS_BLOCK_FLAG_REFS : 0)])
@@ -313,11 +310,11 @@ major_alloc_heap (mword nursery_size, mword nursery_align, int the_nursery_bits)
        if (nursery_align)
                g_assert (nursery_align % MS_BLOCK_SIZE == 0);
 
-       nursery_start = mono_sgen_alloc_os_memory_aligned (alloc_size, nursery_align ? nursery_align : MS_BLOCK_SIZE, TRUE);
+       nursery_start = sgen_alloc_os_memory_aligned (alloc_size, nursery_align ? nursery_align : MS_BLOCK_SIZE, TRUE);
        ms_heap_start = nursery_start + nursery_size;
        ms_heap_end = ms_heap_start + major_heap_size;
 
-       block_infos = mono_sgen_alloc_internal_dynamic (sizeof (MSBlockInfo) * ms_heap_num_blocks, INTERNAL_MEM_MS_BLOCK_INFO);
+       block_infos = sgen_alloc_internal_dynamic (sizeof (MSBlockInfo) * ms_heap_num_blocks, INTERNAL_MEM_MS_BLOCK_INFO);
 
        for (i = 0; i < ms_heap_num_blocks; ++i) {
                block_infos [i].block = ms_heap_start + i * MS_BLOCK_SIZE;
@@ -338,9 +335,9 @@ major_alloc_heap (mword nursery_size, mword nursery_align, int the_nursery_bits)
 {
        char *start;
        if (nursery_align)
-               start = mono_sgen_alloc_os_memory_aligned (nursery_size, nursery_align, TRUE);
+               start = sgen_alloc_os_memory_aligned (nursery_size, nursery_align, TRUE);
        else
-               start = mono_sgen_alloc_os_memory (nursery_size, TRUE);
+               start = sgen_alloc_os_memory (nursery_size, TRUE);
 
        return start;
 }
@@ -349,7 +346,7 @@ major_alloc_heap (mword nursery_size, mword nursery_align, int the_nursery_bits)
 static void
 update_heap_boundaries_for_block (MSBlockInfo *block)
 {
-       mono_sgen_update_heap_boundaries ((mword)block->block, (mword)block->block + MS_BLOCK_SIZE);
+       sgen_update_heap_boundaries ((mword)block->block, (mword)block->block + MS_BLOCK_SIZE);
 }
 
 #ifdef FIXED_HEAP
@@ -379,7 +376,7 @@ ms_free_block (MSBlockInfo *block)
        empty_blocks = block;
        block->used = FALSE;
        block->zeroed = FALSE;
-       mono_sgen_release_space (MS_BLOCK_SIZE, SPACE_MAJOR);
+       sgen_release_space (MS_BLOCK_SIZE, SPACE_MAJOR);
 }
 #else
 static void*
@@ -391,7 +388,7 @@ ms_get_empty_block (void)
 
  retry:
        if (!empty_blocks) {
-               p = mono_sgen_alloc_os_memory_aligned (MS_BLOCK_SIZE * MS_BLOCK_ALLOC_NUM, MS_BLOCK_SIZE, TRUE);
+               p = sgen_alloc_os_memory_aligned (MS_BLOCK_SIZE * MS_BLOCK_ALLOC_NUM, MS_BLOCK_SIZE, TRUE);
 
                for (i = 0; i < MS_BLOCK_ALLOC_NUM; ++i) {
                        block = p;
@@ -434,7 +431,7 @@ ms_free_block (void *block)
 {
        void *empty;
 
-       mono_sgen_release_space (MS_BLOCK_SIZE, SPACE_MAJOR);
+       sgen_release_space (MS_BLOCK_SIZE, SPACE_MAJOR);
        memset (block, 0, MS_BLOCK_SIZE);
 
        do {
@@ -551,13 +548,13 @@ ms_alloc_block (int size_index, gboolean pinned, gboolean has_references)
        char *obj_start;
        int i;
 
-       if (!mono_sgen_try_alloc_space (MS_BLOCK_SIZE, SPACE_MAJOR))
+       if (!sgen_try_alloc_space (MS_BLOCK_SIZE, SPACE_MAJOR))
                return FALSE;
 
 #ifdef FIXED_HEAP
        info = ms_get_empty_block ();
 #else
-       info = mono_sgen_alloc_internal (INTERNAL_MEM_MS_BLOCK_INFO);
+       info = sgen_alloc_internal (INTERNAL_MEM_MS_BLOCK_INFO);
 #endif
 
        DEBUG (9, g_assert (count >= 2));
@@ -567,7 +564,7 @@ ms_alloc_block (int size_index, gboolean pinned, gboolean has_references)
        info->pinned = pinned;
        info->has_references = has_references;
        info->has_pinned = pinned;
-       info->is_to_space = (mono_sgen_get_current_collection_generation () == GENERATION_OLD);
+       info->is_to_space = (sgen_get_current_collection_generation () == GENERATION_OLD); /*FIXME WHY??? */
 #ifndef FIXED_HEAP
        info->block = ms_get_empty_block ();
 
@@ -714,6 +711,12 @@ alloc_obj_par (int size, gboolean pinned, gboolean has_references)
 
        return obj;
 }
+
+static void*
+major_par_alloc_object (int size, gboolean has_references)
+{
+       return alloc_obj_par (size, FALSE, has_references);
+}
 #endif
 
 static void*
@@ -829,7 +832,7 @@ major_alloc_degraded (MonoVTable *vtable, size_t size)
                HEAVY_STAT (++stat_objects_alloced_degraded);
                HEAVY_STAT (stat_bytes_alloced_degraded += size);
                g_assert (num_major_sections >= old_num_sections);
-               mono_sgen_register_major_sections_alloced (num_major_sections - old_num_sections);
+               sgen_register_major_sections_alloced (num_major_sections - old_num_sections);
        }
        return obj;
 }
@@ -850,7 +853,7 @@ major_is_object_live (char *obj)
        mword objsize;
 #endif
 
-       if (mono_sgen_ptr_in_nursery (obj))
+       if (sgen_ptr_in_nursery (obj))
                return FALSE;
 
 #ifdef FIXED_HEAP
@@ -858,7 +861,7 @@ major_is_object_live (char *obj)
        if (!MS_PTR_IN_SMALL_MAJOR_HEAP (obj))
                return FALSE;
 #else
-       objsize = SGEN_ALIGN_UP (mono_sgen_safe_object_get_size ((MonoObject*)obj));
+       objsize = SGEN_ALIGN_UP (sgen_safe_object_get_size ((MonoObject*)obj));
 
        /* LOS */
        if (objsize > SGEN_MAX_SMALL_OBJ_SIZE)
@@ -955,7 +958,7 @@ major_dump_heap (FILE *heap_dump_file)
                                        start = i;
                        } else {
                                if (start >= 0) {
-                                       mono_sgen_dump_occupied (MS_BLOCK_OBJ (block, start), MS_BLOCK_OBJ (block, i), block->block);
+                                       sgen_dump_occupied (MS_BLOCK_OBJ (block, start), MS_BLOCK_OBJ (block, i), block->block);
                                        start = -1;
                                }
                        }
@@ -974,7 +977,7 @@ major_dump_heap (FILE *heap_dump_file)
                        MS_SET_MARK_BIT ((block), __word, __bit);       \
                        if ((block)->has_references)                    \
                                GRAY_OBJECT_ENQUEUE ((queue), (obj));   \
-                       binary_protocol_mark ((obj), (gpointer)LOAD_VTABLE ((obj)), mono_sgen_safe_object_get_size ((MonoObject*)(obj))); \
+                       binary_protocol_mark ((obj), (gpointer)LOAD_VTABLE ((obj)), sgen_safe_object_get_size ((MonoObject*)(obj))); \
                }                                                       \
        } while (0)
 #define MS_MARK_OBJECT_AND_ENQUEUE(obj,block,queue) do {               \
@@ -985,7 +988,7 @@ major_dump_heap (FILE *heap_dump_file)
                        MS_SET_MARK_BIT ((block), __word, __bit);       \
                        if ((block)->has_references)                    \
                                GRAY_OBJECT_ENQUEUE ((queue), (obj));   \
-                       binary_protocol_mark ((obj), (gpointer)LOAD_VTABLE ((obj)), mono_sgen_safe_object_get_size ((MonoObject*)(obj))); \
+                       binary_protocol_mark ((obj), (gpointer)LOAD_VTABLE ((obj)), sgen_safe_object_get_size ((MonoObject*)(obj))); \
                }                                                       \
        } while (0)
 #define MS_PAR_MARK_OBJECT_AND_ENQUEUE(obj,block,queue) do {           \
@@ -997,50 +1000,18 @@ major_dump_heap (FILE *heap_dump_file)
                if (!__was_marked) {                                    \
                        if ((block)->has_references)                    \
                                GRAY_OBJECT_ENQUEUE ((queue), (obj));   \
-                       binary_protocol_mark ((obj), (gpointer)LOAD_VTABLE ((obj)), mono_sgen_safe_object_get_size ((MonoObject*)(obj))); \
+                       binary_protocol_mark ((obj), (gpointer)LOAD_VTABLE ((obj)), sgen_safe_object_get_size ((MonoObject*)(obj))); \
                }                                                       \
        } while (0)
 
 static void
-pin_major_object (void *obj, SgenGrayQueue *queue)
+pin_major_object (char *obj, SgenGrayQueue *queue)
 {
        MSBlockInfo *block = MS_BLOCK_FOR_OBJ (obj);
        block->has_pinned = TRUE;
        MS_MARK_OBJECT_AND_ENQUEUE (obj, block, queue);
 }
 
-#ifdef SGEN_PARALLEL_MARK
-static void
-pin_or_update_par (void **ptr, void *obj, MonoVTable *vt, SgenGrayQueue *queue)
-{
-       for (;;) {
-               mword vtable_word;
-               gboolean major_pinned = FALSE;
-
-               if (mono_sgen_ptr_in_nursery (obj)) {
-                       if (SGEN_CAS_PTR (obj, (void*)((mword)vt | SGEN_PINNED_BIT), vt) == vt) {
-                               mono_sgen_pin_object (obj, queue);
-                               break;
-                       }
-               } else {
-                       pin_major_object (obj, queue);
-                       major_pinned = TRUE;
-               }
-
-               vtable_word = *(mword*)obj;
-               /*someone else forwarded it, update the pointer and bail out*/
-               if (vtable_word & SGEN_FORWARDED_BIT) {
-                       *ptr = (void*)(vtable_word & ~SGEN_VTABLE_BITS_MASK);
-                       break;
-               }
-
-               /*someone pinned it, nothing to do.*/
-               if (vtable_word & SGEN_PINNED_BIT || major_pinned)
-                       break;
-       }
-}
-#endif
-
 #include "sgen-major-copy-object.h"
 
 #ifdef SGEN_PARALLEL_MARK
@@ -1057,7 +1028,7 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
        DEBUG (9, g_assert (obj));
        DEBUG (9, g_assert (current_collection_generation == GENERATION_OLD));
 
-       if (mono_sgen_ptr_in_nursery (obj)) {
+       if (sgen_ptr_in_nursery (obj)) {
                int word, bit;
                gboolean has_references;
                void *destination;
@@ -1072,23 +1043,27 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
                if (vtable_word & SGEN_PINNED_BIT)
                        return;
 
+               /* An object in the nursery To Space has already been copied and grayed. Nothing to do. */
+               if (sgen_nursery_is_to_space (obj))
+                       return;
+
                HEAVY_STAT (++stat_objects_copied_major);
 
        do_copy_object:
-               objsize = SGEN_ALIGN_UP (mono_sgen_par_object_get_size (vt, (MonoObject*)obj));
+               objsize = SGEN_ALIGN_UP (sgen_par_object_get_size (vt, (MonoObject*)obj));
                has_references = SGEN_VTABLE_HAS_REFERENCES (vt);
 
-               destination = alloc_obj_par (objsize, FALSE, has_references);
+               destination = sgen_minor_collector.par_alloc_for_promotion (obj, objsize, has_references);
                if (G_UNLIKELY (!destination)) {
-                       if (!mono_sgen_ptr_in_nursery (obj)) {
+                       if (!sgen_ptr_in_nursery (obj)) {
                                int size_index;
                                block = MS_BLOCK_FOR_OBJ (obj);
                                size_index = block->obj_size_index;
                                evacuate_block_obj_sizes [size_index] = FALSE;
                        }
 
-                       pin_or_update_par (ptr, obj, vt, queue);
-                       mono_sgen_set_pinned_from_failed_allocation (objsize);
+                       sgen_parallel_pin_or_update (ptr, obj, vt, queue);
+                       sgen_set_pinned_from_failed_allocation (objsize);
                        return;
                }
 
@@ -1111,11 +1086,15 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
                         * FIXME: If we make major_alloc_object() give
                         * us the block info, too, we won't have to
                         * re-fetch it here.
+                        *
+                        * FIXME (2): We should rework this to avoid all those nursery checks.
                         */
-                       block = MS_BLOCK_FOR_OBJ (obj);
-                       MS_CALC_MARK_BIT (word, bit, obj);
-                       DEBUG (9, g_assert (!MS_MARK_BIT (block, word, bit)));
-                       MS_PAR_SET_MARK_BIT (was_marked, block, word, bit);
+                       if (!sgen_ptr_in_nursery (obj)) { /*marking a nursery object is pretty stupid.*/
+                               block = MS_BLOCK_FOR_OBJ (obj);
+                               MS_CALC_MARK_BIT (word, bit, obj);
+                               DEBUG (9, g_assert (!MS_MARK_BIT (block, word, bit)));
+                               MS_PAR_SET_MARK_BIT (was_marked, block, word, bit);
+                       }
                } else {
                        /*
                         * FIXME: We have allocated destination, but
@@ -1131,7 +1110,7 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
 
                        *ptr = obj;
 
-                       ++stat_slots_allocated_in_vain;
+                       HEAVY_STAT (++stat_slots_allocated_in_vain);
                }
        } else {
 #ifdef FIXED_HEAP
@@ -1145,7 +1124,7 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
                        *ptr = (void*)vt;
                        return;
                }
-               objsize = SGEN_ALIGN_UP (mono_sgen_par_object_get_size (vt, (MonoObject*)obj));
+               objsize = SGEN_ALIGN_UP (sgen_par_object_get_size (vt, (MonoObject*)obj));
 
                if (objsize <= SGEN_MAX_SMALL_OBJ_SIZE)
 #endif
@@ -1184,7 +1163,7 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
 
                        if (vtable_word & SGEN_PINNED_BIT)
                                return;
-                       binary_protocol_pin (obj, vt, mono_sgen_safe_object_get_size ((MonoObject*)obj));
+                       binary_protocol_pin (obj, vt, sgen_safe_object_get_size ((MonoObject*)obj));
                        if (SGEN_CAS_PTR (obj, (void*)(vtable_word | SGEN_PINNED_BIT), (void*)vtable_word) == (void*)vtable_word) {
                                if (SGEN_VTABLE_HAS_REFERENCES (vt))
                                        GRAY_OBJECT_ENQUEUE (queue, obj);
@@ -1206,7 +1185,7 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
        DEBUG (9, g_assert (obj));
        DEBUG (9, g_assert (current_collection_generation == GENERATION_OLD));
 
-       if (mono_sgen_ptr_in_nursery (obj)) {
+       if (sgen_ptr_in_nursery (obj)) {
                int word, bit;
                char *forwarded, *old_obj;
 
@@ -1217,6 +1196,10 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
                if (SGEN_OBJECT_IS_PINNED (obj))
                        return;
 
+               /* An object in the nursery To Space has already been copied and grayed. Nothing to do. */
+               if (sgen_nursery_is_to_space (obj))
+                       return;
+
                HEAVY_STAT (++stat_objects_copied_major);
 
        do_copy_object:
@@ -1224,7 +1207,7 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
                obj = copy_object_no_checks (obj, queue);
                if (G_UNLIKELY (old_obj == obj)) {
                        /*If we fail to evacuate an object we just stop doing it for a given block size as all other will surely fail too.*/
-                       if (!mono_sgen_ptr_in_nursery (obj)) {
+                       if (!sgen_ptr_in_nursery (obj)) {
                                int size_index;
                                block = MS_BLOCK_FOR_OBJ (obj);
                                size_index = block->obj_size_index;
@@ -1240,11 +1223,15 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
                 * we have that, we can let the allocation function
                 * give us the block info, too, and we won't have to
                 * re-fetch it.
+                *
+                * FIXME (2): We should rework this to avoid all those nursery checks.
                 */
-               block = MS_BLOCK_FOR_OBJ (obj);
-               MS_CALC_MARK_BIT (word, bit, obj);
-               DEBUG (9, g_assert (!MS_MARK_BIT (block, word, bit)));
-               MS_SET_MARK_BIT (block, word, bit);
+               if (!sgen_ptr_in_nursery (obj)) { /*marking a nursery object is pretty stupid.*/
+                       block = MS_BLOCK_FOR_OBJ (obj);
+                       MS_CALC_MARK_BIT (word, bit, obj);
+                       DEBUG (9, g_assert (!MS_MARK_BIT (block, word, bit)));
+                       MS_SET_MARK_BIT (block, word, bit);
+               }
        } else {
                char *forwarded;
 #ifdef FIXED_HEAP
@@ -1265,7 +1252,7 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
                        return;
                }
 
-               objsize = SGEN_ALIGN_UP (mono_sgen_safe_object_get_size ((MonoObject*)obj));
+               objsize = SGEN_ALIGN_UP (sgen_safe_object_get_size ((MonoObject*)obj));
 
                if (objsize <= SGEN_MAX_SMALL_OBJ_SIZE)
 #endif
@@ -1303,7 +1290,7 @@ major_copy_or_mark_object (void **ptr, SgenGrayQueue *queue)
                } else {
                        if (SGEN_OBJECT_IS_PINNED (obj))
                                return;
-                       binary_protocol_pin (obj, (gpointer)SGEN_LOAD_VTABLE (obj), mono_sgen_safe_object_get_size ((MonoObject*)obj));
+                       binary_protocol_pin (obj, (gpointer)SGEN_LOAD_VTABLE (obj), sgen_safe_object_get_size ((MonoObject*)obj));
                        SGEN_PIN_OBJECT (obj);
                        /* FIXME: only enqueue if object has references */
                        GRAY_OBJECT_ENQUEUE (queue, obj);
@@ -1438,7 +1425,7 @@ ms_sweep (void)
 #else
                        ms_free_block (block->block);
 
-                       mono_sgen_free_internal (block, INTERNAL_MEM_MS_BLOCK_INFO);
+                       sgen_free_internal (block, INTERNAL_MEM_MS_BLOCK_INFO);
 #endif
 
                        --num_major_sections;
@@ -1471,7 +1458,7 @@ ms_sweep_thread_func (void *dummy)
 
                while ((result = MONO_SEM_WAIT (&ms_sweep_cmd_semaphore)) != 0) {
                        if (errno != EINTR)
-                               g_error ("MONO_SEM_WAIT");
+                               g_error ("MONO_SEM_WAIT FAILED with %d errno %d (%s)", result, errno, strerror (errno));
                }
 
                ms_sweep ();
@@ -1586,7 +1573,7 @@ major_finish_nursery_collection (void)
 #ifdef MARKSWEEP_CONSISTENCY_CHECK
        consistency_check ();
 #endif
-       mono_sgen_register_major_sections_alloced (num_major_sections - old_num_major_sections);
+       sgen_register_major_sections_alloced (num_major_sections - old_num_major_sections);
 }
 
 static void
@@ -1615,7 +1602,7 @@ static void
 major_have_computer_minor_collection_allowance (void)
 {
 #ifndef FIXED_HEAP
-       int section_reserve = mono_sgen_get_minor_collection_allowance () / MS_BLOCK_SIZE;
+       int section_reserve = sgen_get_minor_collection_allowance () / MS_BLOCK_SIZE;
 
        g_assert (have_swept);
        ms_wait_for_sweep_done ();
@@ -1631,7 +1618,7 @@ major_have_computer_minor_collection_allowance (void)
 
        while (num_empty_blocks > section_reserve) {
                void *next = *(void**)empty_blocks;
-               mono_sgen_free_os_memory (empty_blocks, MS_BLOCK_SIZE);
+               sgen_free_os_memory (empty_blocks, MS_BLOCK_SIZE);
                empty_blocks = next;
                /*
                 * Needs not be atomic because this is running
@@ -1650,7 +1637,7 @@ major_find_pin_queue_start_ends (SgenGrayQueue *queue)
        MSBlockInfo *block;
 
        FOREACH_BLOCK (block) {
-               block->pin_queue_start = mono_sgen_find_optimized_pin_queue_area (block->block + MS_BLOCK_SKIP, block->block + MS_BLOCK_SIZE,
+               block->pin_queue_start = sgen_find_optimized_pin_queue_area (block->block + MS_BLOCK_SKIP, block->block + MS_BLOCK_SIZE,
                                &block->pin_queue_num_entries);
        } END_FOREACH_BLOCK;
 }
@@ -1818,6 +1805,7 @@ static void
 major_scan_card_table (SgenGrayQueue *queue)
 {
        MSBlockInfo *block;
+       ScanObjectFunc scan_func = sgen_get_current_object_ops ()->scan_object;
 
        FOREACH_BLOCK (block) {
                int block_obj_size;
@@ -1857,7 +1845,6 @@ major_scan_card_table (SgenGrayQueue *queue)
                                obj += block_obj_size;
                        }
                } else {
-                       ScanObjectFunc scan_func = mono_sgen_get_minor_scan_object ();
                        guint8 *card_data, *card_base;
                        guint8 *card_data_end;
 
@@ -1921,7 +1908,7 @@ alloc_free_block_lists (MSBlockInfo ***lists)
 {
        int i;
        for (i = 0; i < MS_BLOCK_TYPE_MAX; ++i)
-               lists [i] = mono_sgen_alloc_internal_dynamic (sizeof (MSBlockInfo*) * num_block_obj_sizes, INTERNAL_MEM_MS_TABLES);
+               lists [i] = sgen_alloc_internal_dynamic (sizeof (MSBlockInfo*) * num_block_obj_sizes, INTERNAL_MEM_MS_TABLES);
 }
 
 #ifdef SGEN_PARALLEL_MARK
@@ -1973,7 +1960,7 @@ static void
 post_param_init (void)
 {
        if (concurrent_sweep) {
-               if (mono_native_thread_create (&ms_sweep_thread, ms_sweep_thread_func, NULL)) {
+               if (!mono_native_thread_create (&ms_sweep_thread, ms_sweep_thread_func, NULL)) {
                        fprintf (stderr, "Error: Could not create sweep thread.\n");
                        exit (1);
                }
@@ -1983,15 +1970,15 @@ post_param_init (void)
 void
 #ifdef SGEN_PARALLEL_MARK
 #ifdef FIXED_HEAP
-mono_sgen_marksweep_fixed_par_init
+sgen_marksweep_fixed_par_init
 #else
-mono_sgen_marksweep_par_init
+sgen_marksweep_par_init
 #endif
 #else
 #ifdef FIXED_HEAP
-mono_sgen_marksweep_fixed_init
+sgen_marksweep_fixed_init
 #else
-mono_sgen_marksweep_init
+sgen_marksweep_init
 #endif
 #endif
        (SgenMajorCollector *collector)
@@ -1999,14 +1986,14 @@ mono_sgen_marksweep_init
        int i;
 
 #ifndef FIXED_HEAP
-       mono_sgen_register_fixed_internal_mem_type (INTERNAL_MEM_MS_BLOCK_INFO, sizeof (MSBlockInfo));
+       sgen_register_fixed_internal_mem_type (INTERNAL_MEM_MS_BLOCK_INFO, sizeof (MSBlockInfo));
 #endif
 
        num_block_obj_sizes = ms_calculate_block_obj_sizes (MS_BLOCK_OBJ_SIZE_FACTOR, NULL);
-       block_obj_sizes = mono_sgen_alloc_internal_dynamic (sizeof (int) * num_block_obj_sizes, INTERNAL_MEM_MS_TABLES);
+       block_obj_sizes = sgen_alloc_internal_dynamic (sizeof (int) * num_block_obj_sizes, INTERNAL_MEM_MS_TABLES);
        ms_calculate_block_obj_sizes (MS_BLOCK_OBJ_SIZE_FACTOR, block_obj_sizes);
 
-       evacuate_block_obj_sizes = mono_sgen_alloc_internal_dynamic (sizeof (gboolean) * num_block_obj_sizes, INTERNAL_MEM_MS_TABLES);
+       evacuate_block_obj_sizes = sgen_alloc_internal_dynamic (sizeof (gboolean) * num_block_obj_sizes, INTERNAL_MEM_MS_TABLES);
        for (i = 0; i < num_block_obj_sizes; ++i)
                evacuate_block_obj_sizes [i] = FALSE;
 
@@ -2035,8 +2022,6 @@ mono_sgen_marksweep_init
        mono_counters_register ("# major objects evacuated", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_major_objects_evacuated);
        mono_counters_register ("Wait for sweep time", MONO_COUNTER_GC | MONO_COUNTER_TIME_INTERVAL, &stat_time_wait_for_sweep);
 #ifdef SGEN_PARALLEL_MARK
-       mono_counters_register ("Slots allocated in vain", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_slots_allocated_in_vain);
-
 #ifndef HAVE_KW_THREAD
        mono_native_tls_alloc (&workers_free_block_lists_key, NULL);
 #endif
@@ -2066,13 +2051,17 @@ mono_sgen_marksweep_init
        collector->is_object_live = major_is_object_live;
        collector->alloc_small_pinned_obj = major_alloc_small_pinned_obj;
        collector->alloc_degraded = major_alloc_degraded;
-       collector->copy_or_mark_object = major_copy_or_mark_object;
+
        collector->alloc_object = major_alloc_object;
+#ifdef SGEN_PARALLEL_MARK
+       collector->par_alloc_object = major_par_alloc_object;
+#endif
        collector->free_pinned_object = free_pinned_object;
        collector->iterate_objects = major_iterate_objects;
        collector->free_non_pinned_object = major_free_non_pinned_object;
        collector->find_pin_queue_start_ends = major_find_pin_queue_start_ends;
        collector->pin_objects = major_pin_objects;
+       collector->pin_major_object = pin_major_object;
 #ifdef SGEN_HAVE_CARDTABLE
        collector->scan_card_table = major_scan_card_table;
        collector->iterate_live_block_ranges = (void*)(void*) major_iterate_live_block_ranges;
@@ -2096,8 +2085,8 @@ mono_sgen_marksweep_init
        collector->is_worker_thread = major_is_worker_thread;
        collector->post_param_init = post_param_init;
 
-       FILL_COLLECTOR_COPY_OBJECT (collector);
-       FILL_COLLECTOR_SCAN_OBJECT (collector);
+       collector->major_ops.copy_or_mark_object = major_copy_or_mark_object;
+       collector->major_ops.scan_object = major_scan_object;
 
 #ifdef SGEN_HAVE_CARDTABLE
        /*cardtable requires major pages to be 8 cards aligned*/
diff --git a/mono/metadata/sgen-minor-copy-object.h b/mono/metadata/sgen-minor-copy-object.h
new file mode 100644 (file)
index 0000000..0546201
--- /dev/null
@@ -0,0 +1,37 @@
+/*
+ * Copyright 2001-2003 Ximian, Inc
+ * Copyright 2003-2010 Novell, Inc.
+ * 
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sublicense, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ * 
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ * 
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+ * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+ * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+ * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+#define collector_pin_object(obj, queue) sgen_pin_object (obj, queue);
+#define collector_serial_alloc_for_promotion alloc_for_promotion
+#define collector_parallel_alloc_for_promotion par_alloc_for_promotion
+
+#define GENERATE_COPY_FUNCTIONS 1
+
+
+#include "sgen-copy-object.h"
+
+#define FILL_MINOR_COLLECTOR_COPY_OBJECT(collector)    do {                    \
+               (collector)->serial_ops.copy_or_mark_object = serial_copy_object;                       \
+               (collector)->parallel_ops.copy_or_mark_object = parallel_copy_object;   \
+       } while (0)
diff --git a/mono/metadata/sgen-minor-scan-object.h b/mono/metadata/sgen-minor-scan-object.h
new file mode 100644 (file)
index 0000000..2430673
--- /dev/null
@@ -0,0 +1,105 @@
+/*
+ * Copyright 2001-2003 Ximian, Inc
+ * Copyright 2003-2010 Novell, Inc.
+ * 
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sublicense, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ * 
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ * 
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+ * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+ * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+ * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+extern long long stat_scan_object_called_nursery;
+
+#undef HANDLE_PTR
+#define HANDLE_PTR(ptr,obj)    do {    \
+               void *__old = *(ptr);   \
+               void *__copy;           \
+               if (__old) {    \
+                       parallel_copy_object ((ptr), queue);    \
+                       __copy = *(ptr);        \
+                       DEBUG (9, if (__old != __copy) fprintf (gc_debug_file, "Overwrote field at %p with %p (was: %p)\n", (ptr), *(ptr), __old));     \
+                       if (G_UNLIKELY (sgen_ptr_in_nursery (__copy) && !sgen_ptr_in_nursery ((ptr)))) \
+                               sgen_add_to_global_remset ((ptr));      \
+               }       \
+       } while (0)
+
+/*
+ * Scan the object pointed to by @start for references to
+ * other objects between @from_start and @from_end and copy
+ * them to the gray_objects area.
+ */
+static void
+parallel_scan_object (char *start, SgenGrayQueue *queue)
+{
+#include "sgen-scan-object.h"
+
+       HEAVY_STAT (++stat_scan_object_called_nursery);
+}
+
+/*
+ * scan_vtype:
+ *
+ * Scan the valuetype pointed to by START, described by DESC for references to
+ * other objects between @from_start and @from_end and copy them to the gray_objects area.
+ * Returns a pointer to the end of the object.
+ */
+static void
+parallel_scan_vtype (char *start, mword desc, SgenGrayQueue *queue)
+{
+       /* The descriptors include info about the MonoObject header as well */
+       start -= sizeof (MonoObject);
+
+#define SCAN_OBJECT_NOVTABLE
+#include "sgen-scan-object.h"
+}
+
+#undef HANDLE_PTR
+#define HANDLE_PTR(ptr,obj)    do {    \
+               void *__old = *(ptr);   \
+               void *__copy;           \
+               if (__old) {    \
+                       serial_copy_object ((ptr), queue);      \
+                       __copy = *(ptr);        \
+                       DEBUG (9, if (__old != __copy) fprintf (gc_debug_file, "Overwrote field at %p with %p (was: %p)\n", (ptr), *(ptr), __old));     \
+                       if (G_UNLIKELY (sgen_ptr_in_nursery (__copy) && !sgen_ptr_in_nursery ((ptr)))) \
+                               sgen_add_to_global_remset ((ptr));      \
+               }       \
+       } while (0)
+
+static void
+serial_scan_object (char *start, SgenGrayQueue *queue)
+{
+#include "sgen-scan-object.h"
+
+       HEAVY_STAT (++stat_scan_object_called_nursery);
+}
+
+static void
+serial_scan_vtype (char *start, mword desc, SgenGrayQueue *queue)
+{
+       /* The descriptors include info about the MonoObject header as well */
+       start -= sizeof (MonoObject);
+
+#define SCAN_OBJECT_NOVTABLE
+#include "sgen-scan-object.h"
+}
+
+#define FILL_MINOR_COLLECTOR_SCAN_OBJECT(collector)    do {                    \
+               (collector)->parallel_ops.scan_object = parallel_scan_object;   \
+               (collector)->parallel_ops.scan_vtype = parallel_scan_vtype;     \
+               (collector)->serial_ops.scan_object = serial_scan_object;       \
+               (collector)->serial_ops.scan_vtype = serial_scan_vtype; \
+       } while (0)
index cf1cf6f8087bb6f89b71a7ecb5645d4a352f8b08..75f99fac78615c20d326ce1f91a2f6c1e4c75e35 100644 (file)
 #define _XOPEN_SOURCE
 #endif
 
-/*
-TODO:
-cleanup the code that readies the nursery for pinning/collection
-       this means removing all remaining memseting and use phony objects
-       all around. Have a separate fragments head so we can process all
-       of them together.
-*/
 #include "metadata/sgen-gc.h"
 #include "metadata/metadata-internals.h"
 #include "metadata/class-internals.h"
@@ -98,41 +91,30 @@ cleanup the code that readies the nursery for pinning/collection
 #include "utils/mono-proclib.h"
 #include "utils/mono-threads.h"
 
-
-typedef struct _Fragment Fragment;
-
-struct _Fragment {
-       Fragment *next;
-       char *fragment_start;
-       char *fragment_next; /* the current soft limit for allocation */
-       char *fragment_end;
-       Fragment *next_in_order; /* We use a different entry for all active fragments so we can avoid SMR. */
-};
-
 /* Enable it so nursery allocation diagnostic data is collected */
 //#define NALLOC_DEBUG 1
 
-/* fragments that are free and ready to be used for allocation */
-static Fragment *nursery_fragments = NULL;
-static Fragment *nursery_fragments_start = NULL;
+/* The mutator allocs from here. */
+SgenFragmentAllocator mutator_allocator;
+
 /* freeelist of fragment structures */
-static Fragment *fragment_freelist = NULL;
+static SgenFragment *fragment_freelist = NULL;
 
 /* Allocator cursors */
 static char *nursery_last_pinned_end = NULL;
 
-char *mono_sgen_nursery_start;
-char *mono_sgen_nursery_end;
+char *sgen_nursery_start;
+char *sgen_nursery_end;
 
 #ifdef USER_CONFIG
-int mono_sgen_nursery_size = (1 << 22);
+int sgen_nursery_size = (1 << 22);
 #ifdef SGEN_ALIGN_NURSERY
-int mono_sgen_nursery_bits = 22;
+int sgen_nursery_bits = 22;
 #endif
 #endif
 
-
-static void mono_sgen_clear_range (char *start, char *end);
+char *sgen_space_bitmap MONO_INTERNAL;
+int sgen_space_bitmap_size MONO_INTERNAL;
 
 #ifdef HEAVY_STATISTICS
 
@@ -286,38 +268,39 @@ get_mark (gpointer n)
 }
 
 /*MUST be called with world stopped*/
-static Fragment*
-alloc_fragment (void)
+SgenFragment*
+sgen_fragment_allocator_alloc (void)
 {
-       Fragment *frag = fragment_freelist;
+       SgenFragment *frag = fragment_freelist;
        if (frag) {
                fragment_freelist = frag->next_in_order;
                frag->next = frag->next_in_order = NULL;
                return frag;
        }
-       frag = mono_sgen_alloc_internal (INTERNAL_MEM_FRAGMENT);
+       frag = sgen_alloc_internal (INTERNAL_MEM_FRAGMENT);
        frag->next = frag->next_in_order = NULL;
        return frag;
 }
 
-static void
-add_fragment (char *start, char *end)
+void
+sgen_fragment_allocator_add (SgenFragmentAllocator *allocator, char *start, char *end)
 {
-       Fragment *fragment;
+       SgenFragment *fragment;
 
-       fragment = alloc_fragment ();
+       fragment = sgen_fragment_allocator_alloc ();
        fragment->fragment_start = start;
        fragment->fragment_next = start;
        fragment->fragment_end = end;
-       fragment->next_in_order = fragment->next = unmask (nursery_fragments);
+       fragment->next_in_order = fragment->next = unmask (allocator->region_head);
 
-       nursery_fragments_start = nursery_fragments = fragment;
+       allocator->region_head = allocator->alloc_head = fragment;
+       g_assert (fragment->fragment_end > fragment->fragment_start);
 }
 
-static void
-release_fragment_list (Fragment **root)
+void
+sgen_fragment_allocator_release (SgenFragmentAllocator *allocator)
 {
-       Fragment *last = *root;
+       SgenFragment *last = allocator->region_head;
        if (!last)
                return;
 
@@ -325,21 +308,25 @@ release_fragment_list (Fragment **root)
        for (; last->next_in_order; last = last->next_in_order) ;
 
        last->next_in_order = fragment_freelist;
-       fragment_freelist = *root;
-       *root = NULL;
+       fragment_freelist = allocator->region_head;
+       allocator->alloc_head = allocator->region_head = NULL;
 }
 
-static Fragment**
-find_previous_pointer_fragment (Fragment *frag)
+static SgenFragment**
+find_previous_pointer_fragment (SgenFragmentAllocator *allocator, SgenFragment *frag)
 {
-       Fragment **prev;
-       Fragment *cur, *next;
+       SgenFragment **prev;
+       SgenFragment *cur, *next;
+#ifdef NALLOC_DEBUG
        int count = 0;
+#endif
 
 try_again:
-       prev = &nursery_fragments;
+       prev = &allocator->alloc_head;
+#ifdef NALLOC_DEBUG
        if (count++ > 5)
                printf ("retry count for fppf is %d\n", count);
+#endif
 
        cur = unmask (*prev);
 
@@ -376,7 +363,7 @@ try_again:
 }
 
 static gboolean
-claim_remaining_size (Fragment *frag, char *alloc_end)
+claim_remaining_size (SgenFragment *frag, char *alloc_end)
 {
        /* All space used, nothing to claim. */
        if (frag->fragment_end <= alloc_end)
@@ -387,7 +374,7 @@ claim_remaining_size (Fragment *frag, char *alloc_end)
 }
 
 static void*
-alloc_from_fragment (Fragment *frag, size_t size)
+par_alloc_from_fragment (SgenFragmentAllocator *allocator, SgenFragment *frag, size_t size)
 {
        char *p = frag->fragment_next;
        char *end = p + size;
@@ -402,7 +389,7 @@ alloc_from_fragment (Fragment *frag, size_t size)
                return NULL;
 
        if (frag->fragment_end - end < SGEN_MAX_NURSERY_WASTE) {
-               Fragment *next, **prev_ptr;
+               SgenFragment *next, **prev_ptr;
                
                /*
                 * Before we clean the remaining nursery, we must claim the remaining space
@@ -410,15 +397,15 @@ alloc_from_fragment (Fragment *frag, size_t size)
                 * allocating from this dying fragment as it doesn't respect SGEN_MAX_NURSERY_WASTE
                 * when doing second chance allocation.
                 */
-               if (mono_sgen_get_nursery_clear_policy () == CLEAR_AT_TLAB_CREATION && claim_remaining_size (frag, end)) {
-                       mono_sgen_clear_range (end, frag->fragment_end);
+               if (sgen_get_nursery_clear_policy () == CLEAR_AT_TLAB_CREATION && claim_remaining_size (frag, end)) {
+                       sgen_clear_range (end, frag->fragment_end);
                        HEAVY_STAT (InterlockedExchangeAdd (&stat_wasted_bytes_trailer, frag->fragment_end - end));
 #ifdef NALLOC_DEBUG
                        add_alloc_record (end, frag->fragment_end - end, BLOCK_ZEROING);
 #endif
                }
 
-               prev_ptr = find_previous_pointer_fragment (frag);
+               prev_ptr = find_previous_pointer_fragment (allocator, frag);
 
                /*Use Michaels linked list remove*/
 
@@ -442,7 +429,7 @@ alloc_from_fragment (Fragment *frag, size_t size)
 
                        /* Fail if the previous node was deleted and its CAS wins */
                        if (InterlockedCompareExchangePointer ((volatile gpointer*)prev_ptr, next, frag) != frag) {
-                               prev_ptr = find_previous_pointer_fragment (frag);
+                               prev_ptr = find_previous_pointer_fragment (allocator, frag);
                                continue;
                        }
                        break;
@@ -452,32 +439,230 @@ alloc_from_fragment (Fragment *frag, size_t size)
        return p;
 }
 
-void
-mono_sgen_clear_current_nursery_fragment (void)
+static void*
+serial_alloc_from_fragment (SgenFragment **previous, SgenFragment *frag, size_t size)
 {
+       char *p = frag->fragment_next;
+       char *end = p + size;
+
+       if (end > frag->fragment_end)
+               return NULL;
+
+       frag->fragment_next = end;
+
+       if (frag->fragment_end - end < SGEN_MAX_NURSERY_WASTE) {
+               *previous = frag->next;
+               
+               /* Clear the remaining space, pinning depends on this. FIXME move this to use phony arrays */
+               memset (end, 0, frag->fragment_end - end);
+
+               *previous = frag->next;
+       }
+
+       return p;
 }
 
-/* Clear all remaining nursery fragments */
-void
-mono_sgen_clear_nursery_fragments (void)
+void*
+sgen_fragment_allocator_par_alloc (SgenFragmentAllocator *allocator, size_t size)
+{
+       SgenFragment *frag;
+
+#ifdef NALLOC_DEBUG
+       InterlockedIncrement (&alloc_count);
+#endif
+
+restart:
+       for (frag = unmask (allocator->alloc_head); unmask (frag); frag = unmask (frag->next)) {
+               HEAVY_STAT (InterlockedIncrement (&stat_alloc_iterations));
+
+               if (size <= (frag->fragment_end - frag->fragment_next)) {
+                       void *p = par_alloc_from_fragment (allocator, frag, size);
+                       if (!p) {
+                               HEAVY_STAT (InterlockedIncrement (&stat_alloc_retries));
+                               goto restart;
+                       }
+#ifdef NALLOC_DEBUG
+                       add_alloc_record (p, size, FIXED_ALLOC);
+#endif
+                       return p;
+               }
+       }
+       return NULL;
+}
+
+void*
+sgen_fragment_allocator_serial_alloc (SgenFragmentAllocator *allocator, size_t size)
 {
-       Fragment *frag;
+       SgenFragment *frag;
+       SgenFragment **previous;
+#ifdef NALLOC_DEBUG
+       InterlockedIncrement (&alloc_count);
+#endif
+
+       previous = &allocator->alloc_head;
 
-       if (mono_sgen_get_nursery_clear_policy () == CLEAR_AT_TLAB_CREATION) {
-               mono_sgen_clear_current_nursery_fragment ();
+       for (frag = *previous; frag; frag = *previous) {
+               char *p = serial_alloc_from_fragment (previous, frag, size);
+
+               HEAVY_STAT (InterlockedIncrement (&stat_alloc_iterations));
 
-               for (frag = unmask (nursery_fragments); frag; frag = unmask (frag->next)) {
-                       DEBUG (4, fprintf (gc_debug_file, "Clear nursery frag %p-%p\n", frag->fragment_next, frag->fragment_end));
-                       mono_sgen_clear_range (frag->fragment_next, frag->fragment_end);
+               if (p) {
 #ifdef NALLOC_DEBUG
-                       add_alloc_record (frag->fragment_next, frag->fragment_end - frag->fragment_next, CLEAR_NURSERY_FRAGS);
+                       add_alloc_record (p, size, FIXED_ALLOC);
 #endif
+                       return p;
                }
+               previous = &frag->next;
        }
+       return NULL;
 }
 
-static void
-mono_sgen_clear_range (char *start, char *end)
+void*
+sgen_fragment_allocator_serial_range_alloc (SgenFragmentAllocator *allocator, size_t desired_size, size_t minimum_size, size_t *out_alloc_size)
+{
+       SgenFragment *frag, **previous, *min_frag = NULL, **prev_min_frag = NULL;
+       size_t current_minimum = minimum_size;
+
+#ifdef NALLOC_DEBUG
+       InterlockedIncrement (&alloc_count);
+#endif
+
+       previous = &allocator->alloc_head;
+
+       for (frag = *previous; frag; frag = *previous) {
+               size_t frag_size = frag->fragment_end - frag->fragment_next;
+
+               HEAVY_STAT (InterlockedIncrement (&stat_alloc_range_iterations));
+
+               if (desired_size <= frag_size) {
+                       void *p;
+                       *out_alloc_size = desired_size;
+
+                       p = serial_alloc_from_fragment (previous, frag, desired_size);
+#ifdef NALLOC_DEBUG
+                       add_alloc_record (p, desired_size, RANGE_ALLOC);
+#endif
+                       return p;
+               }
+               if (current_minimum <= frag_size) {
+                       min_frag = frag;
+                       prev_min_frag = previous;
+                       current_minimum = frag_size;
+               }
+               previous = &frag->next;
+       }
+
+       if (min_frag) {
+               void *p;
+               size_t frag_size = min_frag->fragment_end - min_frag->fragment_next;
+               *out_alloc_size = frag_size;
+
+               p = serial_alloc_from_fragment (prev_min_frag, min_frag, frag_size);
+
+#ifdef NALLOC_DEBUG
+               add_alloc_record (p, frag_size, RANGE_ALLOC);
+#endif
+               return p;
+       }
+
+       return NULL;
+}
+
+void*
+sgen_fragment_allocator_par_range_alloc (SgenFragmentAllocator *allocator, size_t desired_size, size_t minimum_size, size_t *out_alloc_size)
+{
+       SgenFragment *frag, *min_frag;
+       size_t current_minimum;
+
+restart:
+       min_frag = NULL;
+       current_minimum = minimum_size;
+
+#ifdef NALLOC_DEBUG
+       InterlockedIncrement (&alloc_count);
+#endif
+
+       for (frag = unmask (allocator->alloc_head); frag; frag = unmask (frag->next)) {
+               int frag_size = frag->fragment_end - frag->fragment_next;
+
+               HEAVY_STAT (InterlockedIncrement (&stat_alloc_range_iterations));
+
+               if (desired_size <= frag_size) {
+                       void *p;
+                       *out_alloc_size = desired_size;
+
+                       p = par_alloc_from_fragment (allocator, frag, desired_size);
+                       if (!p) {
+                               HEAVY_STAT (InterlockedIncrement (&stat_alloc_range_retries));
+                               goto restart;
+                       }
+#ifdef NALLOC_DEBUG
+                       add_alloc_record (p, desired_size, RANGE_ALLOC);
+#endif
+                       return p;
+               }
+               if (current_minimum <= frag_size) {
+                       min_frag = frag;
+                       current_minimum = frag_size;
+               }
+       }
+
+       /* The second fragment_next read should be ordered in respect to the first code block */
+       mono_memory_barrier ();
+
+       if (min_frag) {
+               void *p;
+               int frag_size;
+
+               frag_size = min_frag->fragment_end - min_frag->fragment_next;
+               if (frag_size < minimum_size)
+                       goto restart;
+
+               *out_alloc_size = frag_size;
+
+               mono_memory_barrier ();
+               p = par_alloc_from_fragment (allocator, min_frag, frag_size);
+
+               /*XXX restarting here is quite dubious given this is already second chance allocation. */
+               if (!p) {
+                       HEAVY_STAT (InterlockedIncrement (&stat_alloc_retries));
+                       goto restart;
+               }
+#ifdef NALLOC_DEBUG
+               add_alloc_record (p, frag_size, RANGE_ALLOC);
+#endif
+               return p;
+       }
+
+       return NULL;
+}
+
+void
+sgen_clear_allocator_fragments (SgenFragmentAllocator *allocator)
+{
+       SgenFragment *frag;
+
+       for (frag = unmask (allocator->alloc_head); frag; frag = unmask (frag->next)) {
+               DEBUG (4, fprintf (gc_debug_file, "Clear nursery frag %p-%p\n", frag->fragment_next, frag->fragment_end));
+               sgen_clear_range (frag->fragment_next, frag->fragment_end);
+#ifdef NALLOC_DEBUG
+               add_alloc_record (frag->fragment_next, frag->fragment_end - frag->fragment_next, CLEAR_NURSERY_FRAGS);
+#endif
+       }       
+}
+
+/* Clear all remaining nursery fragments */
+void
+sgen_clear_nursery_fragments (void)
+{
+       if (sgen_get_nursery_clear_policy () == CLEAR_AT_TLAB_CREATION) {
+               sgen_clear_allocator_fragments (&mutator_allocator);
+               sgen_minor_collector.clear_fragments ();
+       }
+}
+
+void
+sgen_clear_range (char *start, char *end)
 {
        MonoArray *o;
        size_t size = end - start;
@@ -488,31 +673,20 @@ mono_sgen_clear_range (char *start, char *end)
        }
 
        o = (MonoArray*)start;
-       o->obj.vtable = mono_sgen_get_array_fill_vtable ();
+       o->obj.vtable = sgen_get_array_fill_vtable ();
        /* Mark this as not a real object */
        o->obj.synchronisation = GINT_TO_POINTER (-1);
        o->bounds = NULL;
        o->max_length = size - sizeof (MonoArray);
-       mono_sgen_set_nursery_scan_start (start);
-       g_assert (start + mono_sgen_safe_object_get_size ((MonoObject*)o) == end);
+       sgen_set_nursery_scan_start (start);
+       g_assert (start + sgen_safe_object_get_size ((MonoObject*)o) == end);
 }
 
 void
-mono_sgen_nursery_allocator_prepare_for_pinning (void)
+sgen_nursery_allocator_prepare_for_pinning (void)
 {
-       Fragment *frag;
-
-       /*
-        * The code below starts the search from an entry in scan_starts, which might point into a nursery
-        * fragment containing random data. Clearing the nursery fragments takes a lot of time, and searching
-        * though them too, so lay arrays at each location inside a fragment where a search can start:
-        * - scan_locations[i]
-        * - start_nursery
-        * - the start of each fragment (the last_obj + last_obj case)
-        * The third encompasses the first two, since scan_locations [i] can't point inside a nursery fragment.
-        */
-       for (frag = unmask (nursery_fragments); frag; frag = unmask (frag->next))
-               mono_sgen_clear_range (frag->fragment_next, frag->fragment_end);
+       sgen_clear_allocator_fragments (&mutator_allocator);
+       sgen_minor_collector.clear_fragments ();
 }
 
 static mword fragment_total = 0;
@@ -522,14 +696,14 @@ static mword fragment_total = 0;
  * allocation.
  */
 static void
-add_nursery_frag (size_t frag_size, char* frag_start, char* frag_end)
+add_nursery_frag (SgenFragmentAllocator *allocator, size_t frag_size, char* frag_start, char* frag_end)
 {
        DEBUG (4, fprintf (gc_debug_file, "Found empty fragment: %p-%p, size: %zd\n", frag_start, frag_end, frag_size));
        binary_protocol_empty (frag_start, frag_size);
        /* Not worth dealing with smaller fragments: need to tune */
        if (frag_size >= SGEN_MAX_NURSERY_WASTE) {
                /* memsetting just the first chunk start is bound to provide better cache locality */
-               if (mono_sgen_get_nursery_clear_policy () == CLEAR_AT_GC)
+               if (sgen_get_nursery_clear_policy () == CLEAR_AT_GC)
                        memset (frag_start, 0, frag_size);
 
 #ifdef NALLOC_DEBUG
@@ -537,87 +711,139 @@ add_nursery_frag (size_t frag_size, char* frag_start, char* frag_end)
                printf ("\tfragment [%p %p] size %zd\n", frag_start, frag_end, frag_size);
                */
 #endif
-               add_fragment (frag_start, frag_end);
+               sgen_fragment_allocator_add (allocator, frag_start, frag_end);
                fragment_total += frag_size;
        } else {
                /* Clear unused fragments, pinning depends on this */
-               mono_sgen_clear_range (frag_start, frag_end);
+               sgen_clear_range (frag_start, frag_end);
                HEAVY_STAT (InterlockedExchangeAdd (&stat_wasted_bytes_small_areas, frag_size));
        }
 }
 
+static void
+fragment_list_reverse (SgenFragmentAllocator *allocator)
+{
+       SgenFragment *prev = NULL, *list = allocator->region_head;
+       while (list) {
+               SgenFragment *next = list->next;
+               list->next = prev;
+               list->next_in_order = prev;
+               prev = list;
+               list = next;
+       }
+
+       allocator->region_head = allocator->alloc_head = prev;
+}
+
 mword
-mono_sgen_build_nursery_fragments (GCMemSection *nursery_section, void **start, int num_entries)
+sgen_build_nursery_fragments (GCMemSection *nursery_section, void **start, int num_entries)
 {
        char *frag_start, *frag_end;
        size_t frag_size;
-       int i;
+       int i = 0;
+       SgenFragment *frags_ranges;
 
 #ifdef NALLOC_DEBUG
        reset_alloc_records ();
 #endif
+       /*The mutator fragments are done. We no longer need them. */
+       sgen_fragment_allocator_release (&mutator_allocator);
 
-       release_fragment_list (&nursery_fragments_start);
-       nursery_fragments = NULL;
-
-       frag_start = mono_sgen_nursery_start;
+       frag_start = sgen_nursery_start;
        fragment_total = 0;
+
+       /* The current nursery might give us a fragment list to exclude [start, next[*/
+       frags_ranges = sgen_minor_collector.build_fragments_get_exclude_head ();
+
        /* clear scan starts */
        memset (nursery_section->scan_starts, 0, nursery_section->num_scan_start * sizeof (gpointer));
-       for (i = 0; i < num_entries; ++i) {
-               frag_end = start [i];
-               /* remove the pin bit from pinned objects */
-               SGEN_UNPIN_OBJECT (frag_end);
-               mono_sgen_set_nursery_scan_start (frag_end);
+
+       while (i < num_entries || frags_ranges) {
+               char *addr0, *addr1;
+               size_t size;
+               SgenFragment *last_frag = NULL;
+
+               addr0 = addr1 = sgen_nursery_end;
+               if (i < num_entries)
+                       addr0 = start [i];
+               if (frags_ranges)
+                       addr1 = frags_ranges->fragment_start;
+
+               if (addr0 < addr1) {
+                       SGEN_UNPIN_OBJECT (addr0);
+                       sgen_set_nursery_scan_start (addr0);
+                       frag_end = addr0;
+                       size = SGEN_ALIGN_UP (sgen_safe_object_get_size ((MonoObject*)addr0));
+                       ++i;
+               } else {
+                       frag_end = addr1;
+                       size = frags_ranges->fragment_next - addr1;
+                       last_frag = frags_ranges;
+                       frags_ranges = frags_ranges->next_in_order;
+               }
+
                frag_size = frag_end - frag_start;
-               if (frag_size)
-                       add_nursery_frag (frag_size, frag_start, frag_end);
-               frag_size = SGEN_ALIGN_UP (mono_sgen_safe_object_get_size ((MonoObject*)start [i]));
+
+               if (size == 0)
+                       continue;
+
+               g_assert (frag_size >= 0);
+               g_assert (size > 0);
+               if (frag_size && size)
+                       add_nursery_frag (&mutator_allocator, frag_size, frag_start, frag_end); 
+
+               frag_size = size;
 #ifdef NALLOC_DEBUG
                add_alloc_record (start [i], frag_size, PINNING);
 #endif
-               frag_start = (char*)start [i] + frag_size;
+               frag_start = frag_end + frag_size;
        }
+
        nursery_last_pinned_end = frag_start;
-       frag_end = mono_sgen_nursery_end;
+       frag_end = sgen_nursery_end;
        frag_size = frag_end - frag_start;
        if (frag_size)
-               add_nursery_frag (frag_size, frag_start, frag_end);
-       if (!unmask (nursery_fragments)) {
+               add_nursery_frag (&mutator_allocator, frag_size, frag_start, frag_end);
+
+       /* Now it's safe to release the fragments exclude list. */
+       sgen_minor_collector.build_fragments_release_exclude_head ();
+
+       /* First we reorder the fragment list to be in ascending address order. This makes H/W prefetchers happier. */
+       fragment_list_reverse (&mutator_allocator);
+
+       /*The collector might want to do something with the final nursery fragment list.*/
+       sgen_minor_collector.build_fragments_finish (&mutator_allocator);
+
+       if (!unmask (mutator_allocator.alloc_head)) {
                DEBUG (1, fprintf (gc_debug_file, "Nursery fully pinned (%d)\n", num_entries));
                for (i = 0; i < num_entries; ++i) {
-                       DEBUG (3, fprintf (gc_debug_file, "Bastard pinning obj %p (%s), size: %d\n", start [i], mono_sgen_safe_name (start [i]), mono_sgen_safe_object_get_size (start [i])));
+                       DEBUG (3, fprintf (gc_debug_file, "Bastard pinning obj %p (%s), size: %d\n", start [i], sgen_safe_name (start [i]), sgen_safe_object_get_size (start [i])));
                }
        }
        return fragment_total;
 }
 
 char *
-mono_sgen_nursery_alloc_get_upper_alloc_bound (void)
+sgen_nursery_alloc_get_upper_alloc_bound (void)
 {
-       char *p = NULL;
-       Fragment *frag;
-
-       for (frag = unmask (nursery_fragments); frag; frag = unmask (frag->next))
-               p = MAX (p, frag->fragment_next);
-
-       return MAX (p, nursery_last_pinned_end);
+       /*FIXME we need to calculate the collector upper bound as well, but this must be done in the previous GC. */
+       return sgen_nursery_end;
 }
 
 /*** Nursery memory allocation ***/
 void
-mono_sgen_nursery_retire_region (void *address, ptrdiff_t size)
+sgen_nursery_retire_region (void *address, ptrdiff_t size)
 {
        HEAVY_STAT (InterlockedExchangeAdd (&stat_wasted_bytes_discarded_fragments, size));
 }
 
 gboolean
-mono_sgen_can_alloc_size (size_t size)
+sgen_can_alloc_size (size_t size)
 {
-       Fragment *frag;
+       SgenFragment *frag;
        size = SGEN_ALIGN_UP (size);
 
-       for (frag = unmask (nursery_fragments); frag; frag = unmask (frag->next)) {
+       for (frag = unmask (mutator_allocator.alloc_head); frag; frag = unmask (frag->next)) {
                if ((frag->fragment_end - frag->fragment_next) >= size)
                        return TRUE;
        }
@@ -625,103 +851,24 @@ mono_sgen_can_alloc_size (size_t size)
 }
 
 void*
-mono_sgen_nursery_alloc (size_t size)
+sgen_nursery_alloc (size_t size)
 {
-       Fragment *frag;
        DEBUG (4, fprintf (gc_debug_file, "Searching nursery for size: %zd\n", size));
        size = SGEN_ALIGN_UP (size);
 
        HEAVY_STAT (InterlockedIncrement (&stat_nursery_alloc_requests));
 
-#ifdef NALLOC_DEBUG
-       InterlockedIncrement (&alloc_count);
-#endif
-
-restart:
-       for (frag = unmask (nursery_fragments); frag; frag = unmask (frag->next)) {
-               HEAVY_STAT (InterlockedIncrement (&stat_alloc_iterations));
-
-               if (size <= (frag->fragment_end - frag->fragment_next)) {
-                       void *p = alloc_from_fragment (frag, size);
-                       if (!p) {
-                               HEAVY_STAT (InterlockedIncrement (&stat_alloc_retries));
-                               goto restart;
-                       }
-#ifdef NALLOC_DEBUG
-                       add_alloc_record (p, size, FIXED_ALLOC);
-#endif
-                       return p;
-               }
-       }
-       return NULL;
+       return sgen_fragment_allocator_par_alloc (&mutator_allocator, size);
 }
 
 void*
-mono_sgen_nursery_alloc_range (size_t desired_size, size_t minimum_size, int *out_alloc_size)
+sgen_nursery_alloc_range (size_t desired_size, size_t minimum_size, size_t *out_alloc_size)
 {
-       Fragment *frag, *min_frag;
        DEBUG (4, fprintf (gc_debug_file, "Searching for byte range desired size: %zd minimum size %zd\n", desired_size, minimum_size));
 
        HEAVY_STAT (InterlockedIncrement (&stat_nursery_alloc_range_requests));
 
-restart:
-       min_frag = NULL;
-
-#ifdef NALLOC_DEBUG
-       InterlockedIncrement (&alloc_count);
-#endif
-
-       for (frag = unmask (nursery_fragments); frag; frag = unmask (frag->next)) {
-               int frag_size = frag->fragment_end - frag->fragment_next;
-
-               HEAVY_STAT (InterlockedIncrement (&stat_alloc_range_iterations));
-
-               if (desired_size <= frag_size) {
-                       void *p;
-                       *out_alloc_size = desired_size;
-
-                       p = alloc_from_fragment (frag, desired_size);
-                       if (!p) {
-                               HEAVY_STAT (InterlockedIncrement (&stat_alloc_range_retries));
-                               goto restart;
-                       }
-#ifdef NALLOC_DEBUG
-                       add_alloc_record (p, desired_size, RANGE_ALLOC);
-#endif
-                       return p;
-               }
-               if (minimum_size <= frag_size)
-                       min_frag = frag;
-       }
-
-       /* The second fragment_next read should be ordered in respect to the first code block */
-       mono_memory_barrier ();
-
-       if (min_frag) {
-               void *p;
-               int frag_size;
-
-               frag_size = min_frag->fragment_end - min_frag->fragment_next;
-               if (frag_size < minimum_size)
-                       goto restart;
-
-               *out_alloc_size = frag_size;
-
-               mono_memory_barrier ();
-               p = alloc_from_fragment (min_frag, frag_size);
-
-               /*XXX restarting here is quite dubious given this is already second chance allocation. */
-               if (!p) {
-                       HEAVY_STAT (InterlockedIncrement (&stat_alloc_retries));
-                       goto restart;
-               }
-#ifdef NALLOC_DEBUG
-               add_alloc_record (p, frag_size, RANGE_ALLOC);
-#endif
-               return p;
-       }
-
-       return NULL;
+       return sgen_fragment_allocator_par_range_alloc (&mutator_allocator, desired_size, minimum_size, out_alloc_size);
 }
 
 /*** Initialization ***/
@@ -729,7 +876,7 @@ restart:
 #ifdef HEAVY_STATISTICS
 
 void
-mono_sgen_nursery_allocator_init_heavy_stats (void)
+sgen_nursery_allocator_init_heavy_stats (void)
 {
        mono_counters_register ("bytes wasted trailer fragments", MONO_COUNTER_GC | MONO_COUNTER_INT, &stat_wasted_bytes_trailer);
        mono_counters_register ("bytes wasted small areas", MONO_COUNTER_GC | MONO_COUNTER_INT, &stat_wasted_bytes_small_areas);
@@ -747,21 +894,37 @@ mono_sgen_nursery_allocator_init_heavy_stats (void)
 #endif
 
 void
-mono_sgen_init_nursery_allocator (void)
+sgen_init_nursery_allocator (void)
 {
-       mono_sgen_register_fixed_internal_mem_type (INTERNAL_MEM_FRAGMENT, sizeof (Fragment));
+       sgen_register_fixed_internal_mem_type (INTERNAL_MEM_FRAGMENT, sizeof (SgenFragment));
 #ifdef NALLOC_DEBUG
-       alloc_records = mono_sgen_alloc_os_memory (sizeof (AllocRecord) * ALLOC_RECORD_COUNT, TRUE);
+       alloc_records = sgen_alloc_os_memory (sizeof (AllocRecord) * ALLOC_RECORD_COUNT, TRUE);
 #endif
 }
 
 void
-mono_sgen_nursery_allocator_set_nursery_bounds (char *start, char *end)
+sgen_nursery_alloc_prepare_for_minor (void)
 {
+       sgen_minor_collector.prepare_to_space (sgen_space_bitmap, sgen_space_bitmap_size);
+}
+
+void
+sgen_nursery_alloc_prepare_for_major (const char *reason)
+{
+       sgen_minor_collector.prepare_to_space (sgen_space_bitmap, sgen_space_bitmap_size);
+}
+
+void
+sgen_nursery_allocator_set_nursery_bounds (char *start, char *end)
+{
+       sgen_nursery_start = start;
+       sgen_nursery_end = end;
+
+       sgen_space_bitmap_size = (end - start) / (SGEN_TO_SPACE_GRANULE_IN_BYTES * 8);
+       sgen_space_bitmap = g_malloc0 (sgen_space_bitmap_size);
+
        /* Setup the single first large fragment */
-       add_fragment (start, end);
-       mono_sgen_nursery_start = start;
-       mono_sgen_nursery_end = end;
+       sgen_minor_collector.init_nursery (&mutator_allocator, start, end);
 }
 
 #endif
index af138e9fe9d354c3ad48b2108fe326edcf642120..56e0ffef0feb692f2ff5c1389e05f1797c3e9f7c 100644 (file)
 
 #if defined(__MACH__) && MONO_MACH_ARCH_SUPPORTED
 gboolean
-mono_sgen_resume_thread (SgenThreadInfo *info)
+sgen_resume_thread (SgenThreadInfo *info)
 {
        return thread_resume (info->mach_port) == KERN_SUCCESS;
 }
 
 gboolean
-mono_sgen_suspend_thread (SgenThreadInfo *info)
+sgen_suspend_thread (SgenThreadInfo *info)
 {
        mach_msg_type_number_t num_state;
        thread_state_t state;
@@ -101,14 +101,14 @@ mono_sgen_suspend_thread (SgenThreadInfo *info)
 }
 
 void
-mono_sgen_wait_for_suspend_ack (int count)
+sgen_wait_for_suspend_ack (int count)
 {
     /* mach thread_resume is synchronous so we dont need to wait for them */
 }
 
 /* LOCKING: assumes the GC lock is held */
 int
-mono_sgen_thread_handshake (BOOL suspend)
+sgen_thread_handshake (BOOL suspend)
 {
        SgenThreadInfo *cur_thread = mono_thread_info_current ();
        kern_return_t ret;
@@ -117,7 +117,9 @@ mono_sgen_thread_handshake (BOOL suspend)
        int count = 0;
 
        FOREACH_THREAD_SAFE (info) {
-               if (info == cur_thread || mono_sgen_is_worker_thread (mono_thread_info_get_tid (info)))
+               info->joined_stw = suspend;
+
+               if (info == cur_thread || sgen_is_worker_thread (mono_thread_info_get_tid (info)))
                        continue;
                if (info->gc_disabled)
                        continue;
@@ -126,7 +128,7 @@ mono_sgen_thread_handshake (BOOL suspend)
                        g_assert (!info->doing_handshake);
                        info->doing_handshake = TRUE;
 
-                       if (!mono_sgen_suspend_thread (info))
+                       if (!sgen_suspend_thread (info))
                                continue;
                } else {
                        g_assert (info->doing_handshake);
@@ -142,7 +144,7 @@ mono_sgen_thread_handshake (BOOL suspend)
 }
 
 void
-mono_sgen_os_init (void)
+sgen_os_init (void)
 {
 }
 
index 5a1f53dbc982a798153f754b68e5202fdffd6cc7..cc75c3a3530b0ebb6c600e842cae1c49ca7ef203 100644 (file)
@@ -51,6 +51,7 @@ static MonoSemType suspend_ack_semaphore;
 static MonoSemType *suspend_ack_semaphore_ptr;
 
 static sigset_t suspend_signal_mask;
+static sigset_t suspend_ack_signal_mask;
 
 static void
 suspend_thread (SgenThreadInfo *info, void *context)
@@ -67,12 +68,12 @@ suspend_thread (SgenThreadInfo *info, void *context)
 
        info->stopped_domain = mono_domain_get ();
        info->stopped_ip = context ? (gpointer) ARCH_SIGCTX_IP (context) : NULL;
-       stop_count = mono_sgen_global_stop_count;
+       stop_count = sgen_global_stop_count;
        /* duplicate signal */
        if (0 && info->stop_count == stop_count)
                return;
 
-       mono_sgen_fill_thread_info_for_suspend (info);
+       sgen_fill_thread_info_for_suspend (info);
 
        stack_start = context ? (char*) ARCH_SIGCTX_SP (context) - REDZONE_SIZE : NULL;
        /* If stack_start is not within the limits, then don't set it
@@ -104,6 +105,14 @@ suspend_thread (SgenThreadInfo *info, void *context)
                mono_gc_get_gc_callbacks ()->thread_suspend_func (info->runtime_data, context);
 
        DEBUG (4, fprintf (gc_debug_file, "Posting suspend_ack_semaphore for suspend from %p %p\n", info, (gpointer)mono_native_thread_id_get ()));
+
+       /*
+       Block the restart signal. 
+       We need to block the restart signal while posting to the suspend_ack semaphore or we race to sigsuspend,
+       which might miss the signal and get stuck.
+       */
+       pthread_sigmask (SIG_BLOCK, &suspend_ack_signal_mask, NULL);
+
        /* notify the waiting thread */
        MONO_SEM_POST (suspend_ack_semaphore_ptr);
        info->stop_count = stop_count;
@@ -114,6 +123,9 @@ suspend_thread (SgenThreadInfo *info, void *context)
                sigsuspend (&suspend_signal_mask);
        } while (info->signal != restart_signal_num && info->doing_handshake);
 
+       /* Unblock the restart signal. */
+       pthread_sigmask (SIG_UNBLOCK, &suspend_ack_signal_mask, NULL);
+
        DEBUG (4, fprintf (gc_debug_file, "Posting suspend_ack_semaphore for resume from %p %p\n", info, (gpointer)mono_native_thread_id_get ()));
        /* notify the waiting thread */
        MONO_SEM_POST (suspend_ack_semaphore_ptr);
@@ -145,6 +157,15 @@ restart_handler (int sig)
        int old_errno = errno;
 
        info = mono_thread_info_current ();
+       /*
+       If the thread info is null is means we're currently in the process of cleaning up,
+       the pthread destructor has already kicked in and it has explicitly invoked the suspend handler.
+       
+       This means this thread has been suspended, TLS is dead, so the only option we have is to
+       rely on pthread_self () and seatch over the thread list.
+       */
+       if (!info)
+               info = mono_thread_info_lookup (pthread_self ());
 
        /*
         * If a thread is dying there might be no thread info.  In
@@ -154,38 +175,37 @@ restart_handler (int sig)
                info->signal = restart_signal_num;
                DEBUG (4, fprintf (gc_debug_file, "Restart handler in %p %p\n", info, (gpointer)mono_native_thread_id_get ()));
        }
-
        errno = old_errno;
 }
 
 gboolean
-mono_sgen_resume_thread (SgenThreadInfo *info)
+sgen_resume_thread (SgenThreadInfo *info)
 {
        return mono_threads_pthread_kill (info, restart_signal_num) == 0;
 }
 
 gboolean
-mono_sgen_suspend_thread (SgenThreadInfo *info)
+sgen_suspend_thread (SgenThreadInfo *info)
 {
        return mono_threads_pthread_kill (info, suspend_signal_num) == 0;
 }
 
 void
-mono_sgen_wait_for_suspend_ack (int count)
+sgen_wait_for_suspend_ack (int count)
 {
        int i, result;
 
        for (i = 0; i < count; ++i) {
                while ((result = MONO_SEM_WAIT (suspend_ack_semaphore_ptr)) != 0) {
                        if (errno != EINTR) {
-                               g_error ("sem_wait ()");
+                               g_error ("MONO_SEM_WAIT FAILED with %d errno %d (%s)", result, errno, strerror (errno));
                        }
                }
        }
 }
 
 gboolean
-mono_sgen_park_current_thread_if_doing_handshake (SgenThreadInfo *p)
+sgen_park_current_thread_if_doing_handshake (SgenThreadInfo *p)
 {
     if (!p->doing_handshake)
            return FALSE;
@@ -195,7 +215,7 @@ mono_sgen_park_current_thread_if_doing_handshake (SgenThreadInfo *p)
 }
 
 int
-mono_sgen_thread_handshake (BOOL suspend)
+sgen_thread_handshake (BOOL suspend)
 {
        int count, result;
        SgenThreadInfo *info;
@@ -205,6 +225,7 @@ mono_sgen_thread_handshake (BOOL suspend)
 
        count = 0;
        FOREACH_THREAD_SAFE (info) {
+               info->joined_stw = suspend;
                if (mono_native_thread_id_equals (mono_thread_info_get_tid (info), me)) {
                        continue;
                }
@@ -227,13 +248,13 @@ mono_sgen_thread_handshake (BOOL suspend)
                }
        } END_FOREACH_THREAD_SAFE
 
-       mono_sgen_wait_for_suspend_ack (count);
+       sgen_wait_for_suspend_ack (count);
 
        return count;
 }
 
 void
-mono_sgen_os_init (void)
+sgen_os_init (void)
 {
        struct sigaction sinfo;
 
@@ -254,6 +275,10 @@ mono_sgen_os_init (void)
 
        sigfillset (&suspend_signal_mask);
        sigdelset (&suspend_signal_mask, restart_signal_num);
+
+       sigemptyset (&suspend_ack_signal_mask);
+       sigaddset (&suspend_ack_signal_mask, restart_signal_num);
+       
 }
 
 int
index 355ab6ef033e43426307e21184f9fb4cd2f3358a..a8a9d17b3f3a2046d3fb3a2ebe9d0206c956adb3 100644 (file)
@@ -8,7 +8,7 @@
 #include "metadata/gc-internal.h"
 
 gboolean
-mono_sgen_resume_thread (SgenThreadInfo *info)
+sgen_resume_thread (SgenThreadInfo *info)
 {
        DWORD id = mono_thread_info_get_tid (info);
        HANDLE handle = OpenThread (THREAD_ALL_ACCESS, FALSE, id);
@@ -25,7 +25,7 @@ mono_sgen_resume_thread (SgenThreadInfo *info)
 }
 
 gboolean
-mono_sgen_suspend_thread (SgenThreadInfo *info)
+sgen_suspend_thread (SgenThreadInfo *info)
 {
        DWORD id = mono_thread_info_get_tid (info);
        HANDLE handle = OpenThread (THREAD_ALL_ACCESS, FALSE, id);
@@ -78,19 +78,20 @@ mono_sgen_suspend_thread (SgenThreadInfo *info)
 }
 
 void
-mono_sgen_wait_for_suspend_ack (int count)
+sgen_wait_for_suspend_ack (int count)
 {
        /* Win32 suspend/resume is synchronous, so we don't need to wait for anything */
 }
 
 int
-mono_sgen_thread_handshake (BOOL suspend)
+sgen_thread_handshake (BOOL suspend)
 {
        SgenThreadInfo *info;
        SgenThreadInfo *current = mono_thread_info_current ();
        int count = 0;
 
        FOREACH_THREAD_SAFE (info) {
+               info->joined_stw = suspend;
                if (info == current)
                        continue;
                if (info->gc_disabled)
@@ -99,23 +100,22 @@ mono_sgen_thread_handshake (BOOL suspend)
                        g_assert (!info->doing_handshake);
                        info->doing_handshake = TRUE;
 
-                       if (!mono_sgen_suspend_thread (info))
+                       if (!sgen_suspend_thread (info))
                                continue;
                } else {
                        g_assert (info->doing_handshake);
                        info->doing_handshake = FALSE;
 
-                       if (!mono_sgen_resume_thread (info))
+                       if (!sgen_resume_thread (info))
                                continue;
                }
-
                ++count;
        } END_FOREACH_THREAD_SAFE
        return count;
 }
 
 void
-mono_sgen_os_init (void)
+sgen_os_init (void)
 {
 }
 
index 61e30cbb1552f5d7fd81040b33d84020ba95b1c7..5240cdee2b1d0f926ddab6dc104e65f12d74fe85 100644 (file)
@@ -157,7 +157,7 @@ report_pinned_chunk (SgenPinnedChunk *chunk, int seq) {
  * Debug reporting.
  */
 void
-mono_sgen_report_pinned_mem_usage (SgenPinnedAllocator *alc)
+sgen_report_pinned_mem_usage (SgenPinnedAllocator *alc)
 {
        SgenPinnedChunk *chunk;
        int i = 0;
@@ -216,10 +216,10 @@ alloc_pinned_chunk (SgenPinnedAllocator *alc)
        int offset;
        int size = SGEN_PINNED_CHUNK_SIZE;
 
-       chunk = mono_sgen_alloc_os_memory_aligned (size, size, TRUE);
+       chunk = sgen_alloc_os_memory_aligned (size, size, TRUE);
        chunk->block.role = MEMORY_ROLE_PINNED;
 
-       mono_sgen_update_heap_boundaries ((mword)chunk, ((mword)chunk + size));
+       sgen_update_heap_boundaries ((mword)chunk, ((mword)chunk + size));
 
        pinned_chunk_bytes_alloced += size;
 
@@ -238,7 +238,7 @@ alloc_pinned_chunk (SgenPinnedAllocator *alc)
        chunk->page_sizes [0] = PINNED_FIRST_SLOT_SIZE;
        build_freelist (alc, chunk, slot_for_size (PINNED_FIRST_SLOT_SIZE), PINNED_FIRST_SLOT_SIZE,
                        chunk->start_data, ((char*)chunk + FREELIST_PAGESIZE));
-       mono_sgen_debug_printf (4, "Allocated pinned chunk %p, size: %d\n", chunk, size);
+       sgen_debug_printf (4, "Allocated pinned chunk %p, size: %d\n", chunk, size);
 
        chunk->block.next = alc->chunk_list;
        alc->chunk_list = chunk;
@@ -317,7 +317,7 @@ alloc_from_slot (SgenPinnedAllocator *alc, int slot)
 
 /* used for the GC-internal data structures */
 void*
-mono_sgen_alloc_pinned (SgenPinnedAllocator *alc, size_t size)
+sgen_alloc_pinned (SgenPinnedAllocator *alc, size_t size)
 {
        int slot;
        void *res = NULL;
@@ -328,7 +328,7 @@ mono_sgen_alloc_pinned (SgenPinnedAllocator *alc, size_t size)
                LargePinnedMemHeader *mh;
 
                size += sizeof (LargePinnedMemHeader);
-               mh = mono_sgen_alloc_os_memory (size, TRUE);
+               mh = sgen_alloc_os_memory (size, TRUE);
                mh->magic = LARGE_PINNED_MEM_HEADER_MAGIC;
                mh->size = size;
                /* FIXME: do a CAS here */
@@ -364,7 +364,7 @@ free_from_slot (SgenPinnedAllocator *alc, void *addr, int slot)
 }
 
 void
-mono_sgen_free_pinned (SgenPinnedAllocator *alc, void *addr, size_t size)
+sgen_free_pinned (SgenPinnedAllocator *alc, void *addr, size_t size)
 {
        LargePinnedMemHeader *mh;
 
@@ -382,11 +382,11 @@ mono_sgen_free_pinned (SgenPinnedAllocator *alc, void *addr, size_t size)
        g_assert (mh->size == size + sizeof (LargePinnedMemHeader));
        /* FIXME: do a CAS */
        large_pinned_bytes_alloced -= mh->size;
-       mono_sgen_free_os_memory (mh, mh->size);
+       sgen_free_os_memory (mh, mh->size);
 }
 
 void
-mono_sgen_init_pinned_allocator (void)
+sgen_init_pinned_allocator (void)
 {
        g_assert (SGEN_PINNED_FREELIST_NUM_SLOTS == sizeof (freelist_sizes) / sizeof (freelist_sizes [0]));
 
@@ -396,7 +396,7 @@ mono_sgen_init_pinned_allocator (void)
 }
 
 void
-mono_sgen_pinned_scan_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFunc callback, void *callback_data)
+sgen_pinned_scan_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFunc callback, void *callback_data)
 {
        SgenPinnedChunk *chunk;
        int i, obj_size;
@@ -405,14 +405,14 @@ mono_sgen_pinned_scan_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFu
        void *end_chunk;
        for (chunk = alc->chunk_list; chunk; chunk = chunk->block.next) {
                end_chunk = (char*)chunk + chunk->num_pages * FREELIST_PAGESIZE;
-               mono_sgen_debug_printf (6, "Scanning pinned chunk %p (range: %p-%p)\n", chunk, chunk->start_data, end_chunk);
+               sgen_debug_printf (6, "Scanning pinned chunk %p (range: %p-%p)\n", chunk, chunk->start_data, end_chunk);
                for (i = 0; i < chunk->num_pages; ++i) {
                        obj_size = chunk->page_sizes [i];
                        if (!obj_size)
                                continue;
                        p = i? (char*)chunk + i * FREELIST_PAGESIZE: chunk->start_data;
                        endp = i? p + FREELIST_PAGESIZE: (char*)chunk + FREELIST_PAGESIZE;
-                       mono_sgen_debug_printf (6, "Page %d (size: %d, range: %p-%p)\n", i, obj_size, p, endp);
+                       sgen_debug_printf (6, "Page %d (size: %d, range: %p-%p)\n", i, obj_size, p, endp);
                        while (p + obj_size <= endp) {
                                ptr = (void**)p;
                                /* if the first word (the vtable) is outside the chunk we have an object */
@@ -425,12 +425,12 @@ mono_sgen_pinned_scan_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFu
 }
 
 void
-mono_sgen_pinned_update_heap_boundaries (SgenPinnedAllocator *alc)
+sgen_pinned_update_heap_boundaries (SgenPinnedAllocator *alc)
 {
        SgenPinnedChunk *chunk;
        for (chunk = alc->chunk_list; chunk; chunk = chunk->block.next) {
                char *end_chunk = (char*)chunk + chunk->num_pages * FREELIST_PAGESIZE;
-               mono_sgen_update_heap_boundaries ((mword)chunk, (mword)end_chunk);
+               sgen_update_heap_boundaries ((mword)chunk, (mword)end_chunk);
        }
 }
 
@@ -477,15 +477,15 @@ mark_pinned_from_addresses (SgenPinnedChunk *chunk, void **start, void **end, It
 }
 
 void
-mono_sgen_pinned_scan_pinned_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFunc callback, void *callback_data)
+sgen_pinned_scan_pinned_objects (SgenPinnedAllocator *alc, IterateObjectCallbackFunc callback, void *callback_data)
 {
        SgenPinnedChunk *chunk;
 
        /* look for pinned addresses for pinned-alloc objects */
-       mono_sgen_debug_printf (6, "Pinning from pinned-alloc objects\n");
+       sgen_debug_printf (6, "Pinning from pinned-alloc objects\n");
        for (chunk = alc->chunk_list; chunk; chunk = chunk->block.next) {
                int num_pinned;
-               void **pinned = mono_sgen_find_optimized_pin_queue_area (chunk->start_data,
+               void **pinned = sgen_find_optimized_pin_queue_area (chunk->start_data,
                                (char*)chunk + chunk->num_pages * FREELIST_PAGESIZE, &num_pinned);
                if (num_pinned)
                        mark_pinned_from_addresses (chunk, pinned, pinned + num_pinned, callback, callback_data);
index c831757fa7c88f3f81d0ac6bb2addfa23e87ca9e..6b798f2ce6b2658f88ff382b8694af335f146eff 100644 (file)
@@ -61,11 +61,11 @@ pin_stats_tree_free (PinStatAddress *node)
                return;
        pin_stats_tree_free (node->left);
        pin_stats_tree_free (node->right);
-       mono_sgen_free_internal_dynamic (node, sizeof (PinStatAddress), INTERNAL_MEM_STATISTICS);
+       sgen_free_internal_dynamic (node, sizeof (PinStatAddress), INTERNAL_MEM_STATISTICS);
 }
 
 void
-mono_sgen_pin_stats_reset (void)
+sgen_pin_stats_reset (void)
 {
        int i;
        pin_stats_tree_free (pin_stat_addresses);
@@ -74,13 +74,13 @@ mono_sgen_pin_stats_reset (void)
                pinned_byte_counts [i] = 0;
        while (pinned_objects) {
                ObjectList *next = pinned_objects->next;
-               mono_sgen_free_internal_dynamic (pinned_objects, sizeof (ObjectList), INTERNAL_MEM_STATISTICS);
+               sgen_free_internal_dynamic (pinned_objects, sizeof (ObjectList), INTERNAL_MEM_STATISTICS);
                pinned_objects = next;
        }
 }
 
 void
-mono_sgen_pin_stats_register_address (char *addr, int pin_type)
+sgen_pin_stats_register_address (char *addr, int pin_type)
 {
        PinStatAddress **node_ptr = &pin_stat_addresses;
        PinStatAddress *node;
@@ -98,7 +98,7 @@ mono_sgen_pin_stats_register_address (char *addr, int pin_type)
                        node_ptr = &node->right;
        }
 
-       node = mono_sgen_alloc_internal_dynamic (sizeof (PinStatAddress), INTERNAL_MEM_STATISTICS);
+       node = sgen_alloc_internal_dynamic (sizeof (PinStatAddress), INTERNAL_MEM_STATISTICS);
        node->addr = addr;
        node->pin_types = pin_type_bit;
        node->left = node->right = NULL;
@@ -131,13 +131,13 @@ static gpointer
 lookup_class_entry (SgenHashTable *hash_table, MonoClass *class, gpointer empty_entry)
 {
        char *name = g_strdup_printf ("%s.%s", class->name_space, class->name);
-       gpointer entry = mono_sgen_hash_table_lookup (hash_table, name);
+       gpointer entry = sgen_hash_table_lookup (hash_table, name);
 
        if (entry) {
                g_free (name);
        } else {
-               mono_sgen_hash_table_replace (hash_table, name, empty_entry);
-               entry = mono_sgen_hash_table_lookup (hash_table, name);
+               sgen_hash_table_replace (hash_table, name, empty_entry, NULL);
+               entry = sgen_hash_table_lookup (hash_table, name);
        }
 
        return entry;
@@ -160,12 +160,12 @@ register_class (MonoClass *class, int pin_types)
 }
 
 void
-mono_sgen_pin_stats_register_object (char *obj, size_t size)
+sgen_pin_stats_register_object (char *obj, size_t size)
 {
        int pin_types = 0;
        ObjectList *list;
 
-       list = mono_sgen_alloc_internal_dynamic (sizeof (ObjectList), INTERNAL_MEM_STATISTICS);
+       list = sgen_alloc_internal_dynamic (sizeof (ObjectList), INTERNAL_MEM_STATISTICS);
        pin_stats_count_object_from_tree (obj, size, pin_stat_addresses, &pin_types);
        list->obj = (MonoObject*)obj;
        list->next = pinned_objects;
@@ -176,7 +176,7 @@ mono_sgen_pin_stats_register_object (char *obj, size_t size)
 }
 
 void
-mono_sgen_pin_stats_register_global_remset (char *obj)
+sgen_pin_stats_register_global_remset (char *obj)
 {
        GlobalRemsetClassEntry empty_entry;
        GlobalRemsetClassEntry *entry;
@@ -188,7 +188,7 @@ mono_sgen_pin_stats_register_global_remset (char *obj)
 }
 
 void
-mono_sgen_pin_stats_print_class_stats (void)
+sgen_pin_stats_print_class_stats (void)
 {
        char *name;
        PinnedClassEntry *pinned_entry;
@@ -210,13 +210,13 @@ mono_sgen_pin_stats_print_class_stats (void)
 }
 
 size_t
-mono_sgen_pin_stats_get_pinned_byte_count (int pin_type)
+sgen_pin_stats_get_pinned_byte_count (int pin_type)
 {
        return pinned_byte_counts [pin_type];
 }
 
 ObjectList*
-mono_sgen_pin_stats_get_object_list (void)
+sgen_pin_stats_get_object_list (void)
 {
        return pinned_objects;
 }
index 10f7d2a336116bc1aba5f8b294ae3a47e5d36404..68e8cf46e8745edbfe1dbd738d325f46d79f1039 100644 (file)
@@ -37,13 +37,13 @@ static int last_num_pinned = 0;
 static void *pin_hash_filter [PIN_HASH_SIZE];
 
 void
-mono_sgen_init_pinning (void)
+sgen_init_pinning (void)
 {
        memset (pin_hash_filter, 0, sizeof (pin_hash_filter));
 }
 
 void
-mono_sgen_finish_pinning (void)
+sgen_finish_pinning (void)
 {
        last_num_pinned = next_pin_slot;
        next_pin_slot = 0;
@@ -53,16 +53,16 @@ static void
 realloc_pin_queue (void)
 {
        int new_size = pin_queue_size? pin_queue_size + pin_queue_size/2: 1024;
-       void **new_pin = mono_sgen_alloc_internal_dynamic (sizeof (void*) * new_size, INTERNAL_MEM_PIN_QUEUE);
+       void **new_pin = sgen_alloc_internal_dynamic (sizeof (void*) * new_size, INTERNAL_MEM_PIN_QUEUE);
        memcpy (new_pin, pin_queue, sizeof (void*) * next_pin_slot);
-       mono_sgen_free_internal_dynamic (pin_queue, sizeof (void*) * pin_queue_size, INTERNAL_MEM_PIN_QUEUE);
+       sgen_free_internal_dynamic (pin_queue, sizeof (void*) * pin_queue_size, INTERNAL_MEM_PIN_QUEUE);
        pin_queue = new_pin;
        pin_queue_size = new_size;
        DEBUG (4, fprintf (gc_debug_file, "Reallocated pin queue to size: %d\n", new_size));
 }
 
 void
-mono_sgen_pin_stage_ptr (void *ptr)
+sgen_pin_stage_ptr (void *ptr)
 {
        /*very simple multiplicative hash function, tons better than simple and'ng */ 
        int hash_idx = ((mword)ptr * 1737350767) & (PIN_HASH_SIZE - 1);
@@ -93,7 +93,7 @@ optimized_pin_queue_search (void *addr)
 }
 
 void**
-mono_sgen_find_optimized_pin_queue_area (void *start, void *end, int *num)
+sgen_find_optimized_pin_queue_area (void *start, void *end, int *num)
 {
        int first, last;
        first = optimized_pin_queue_search (start);
@@ -105,29 +105,29 @@ mono_sgen_find_optimized_pin_queue_area (void *start, void *end, int *num)
 }
 
 void
-mono_sgen_find_section_pin_queue_start_end (GCMemSection *section)
+sgen_find_section_pin_queue_start_end (GCMemSection *section)
 {
        DEBUG (6, fprintf (gc_debug_file, "Pinning from section %p (%p-%p)\n", section, section->data, section->end_data));
-       section->pin_queue_start = mono_sgen_find_optimized_pin_queue_area (section->data, section->end_data, &section->pin_queue_num_entries);
+       section->pin_queue_start = sgen_find_optimized_pin_queue_area (section->data, section->end_data, &section->pin_queue_num_entries);
        DEBUG (6, fprintf (gc_debug_file, "Found %d pinning addresses in section %p\n", section->pin_queue_num_entries, section));
 }
 
 /*This will setup the given section for the while pin queue. */
 void
-mono_sgen_pinning_setup_section (GCMemSection *section)
+sgen_pinning_setup_section (GCMemSection *section)
 {
        section->pin_queue_start = pin_queue;
        section->pin_queue_num_entries = next_pin_slot;
 }
 
 void
-mono_sgen_pinning_trim_queue_to_section (GCMemSection *section)
+sgen_pinning_trim_queue_to_section (GCMemSection *section)
 {
        next_pin_slot = section->pin_queue_num_entries;
 }
 
 void
-mono_sgen_pin_queue_clear_discarded_entries (GCMemSection *section, int max_pin_slot)
+sgen_pin_queue_clear_discarded_entries (GCMemSection *section, int max_pin_slot)
 {
        void **start = section->pin_queue_start + section->pin_queue_num_entries;
        void **end = pin_queue + max_pin_slot;
@@ -161,14 +161,14 @@ print_nursery_gaps (void* start_nursery, void *end_nursery)
 
 /* reduce the info in the pin queue, removing duplicate pointers and sorting them */
 void
-mono_sgen_optimize_pin_queue (int start_slot)
+sgen_optimize_pin_queue (int start_slot)
 {
        void **start, **cur, **end;
        /* sort and uniq pin_queue: we just sort and we let the rest discard multiple values */
        /* it may be better to keep ranges of pinned memory instead of individually pinning objects */
        DEBUG (5, fprintf (gc_debug_file, "Sorting pin queue, size: %d\n", next_pin_slot));
        if ((next_pin_slot - start_slot) > 1)
-               mono_sgen_sort_addresses (pin_queue + start_slot, next_pin_slot - start_slot);
+               sgen_sort_addresses (pin_queue + start_slot, next_pin_slot - start_slot);
        start = cur = pin_queue + start_slot;
        end = pin_queue + next_pin_slot;
        while (cur < end) {
@@ -183,18 +183,18 @@ mono_sgen_optimize_pin_queue (int start_slot)
 }
 
 int
-mono_sgen_get_pinned_count (void)
+sgen_get_pinned_count (void)
 {
        return next_pin_slot;
 }
 
 void
-mono_sgen_dump_pin_queue (void)
+sgen_dump_pin_queue (void)
 {
        int i;
 
        for (i = 0; i < last_num_pinned; ++i) {
-               DEBUG (3, fprintf (gc_debug_file, "Bastard pinning obj %p (%s), size: %d\n", pin_queue [i], mono_sgen_safe_name (pin_queue [i]), mono_sgen_safe_object_get_size (pin_queue [i])));
+               DEBUG (3, fprintf (gc_debug_file, "Bastard pinning obj %p (%s), size: %d\n", pin_queue [i], sgen_safe_name (pin_queue [i]), sgen_safe_object_get_size (pin_queue [i])));
        }       
 }
 
index c9ef0004e44cfd52236c0fde5c7b5556e8b11e92..40474bb9644c51820af74b3c9762e9ce6ad6fa59 100644 (file)
@@ -1,6 +1,4 @@
 /*
-void
-mono_sgen_pinning_trim_queue_to_section (GCMemSection *section)
  * Copyright 2011 Xamarin Inc (http://www.xamarin.com)
  *
  * Permission is hereby granted, free of charge, to any person obtaining
@@ -32,22 +30,22 @@ enum {
        PIN_TYPE_MAX
 };
 
-void mono_sgen_pin_stage_ptr (void *ptr) MONO_INTERNAL;
-void mono_sgen_optimize_pin_queue (int start_slot) MONO_INTERNAL;
-void mono_sgen_init_pinning (void) MONO_INTERNAL;
-void mono_sgen_finish_pinning (void) MONO_INTERNAL;
-void mono_sgen_pin_queue_clear_discarded_entries (GCMemSection *section, int max_pin_slot) MONO_INTERNAL;
-int mono_sgen_get_pinned_count (void) MONO_INTERNAL;
-void mono_sgen_pinning_setup_section (GCMemSection *section) MONO_INTERNAL;
-void mono_sgen_pinning_trim_queue_to_section (GCMemSection *section) MONO_INTERNAL;
+void sgen_pin_stage_ptr (void *ptr) MONO_INTERNAL;
+void sgen_optimize_pin_queue (int start_slot) MONO_INTERNAL;
+void sgen_init_pinning (void) MONO_INTERNAL;
+void sgen_finish_pinning (void) MONO_INTERNAL;
+void sgen_pin_queue_clear_discarded_entries (GCMemSection *section, int max_pin_slot) MONO_INTERNAL;
+int sgen_get_pinned_count (void) MONO_INTERNAL;
+void sgen_pinning_setup_section (GCMemSection *section) MONO_INTERNAL;
+void sgen_pinning_trim_queue_to_section (GCMemSection *section) MONO_INTERNAL;
 
-void mono_sgen_dump_pin_queue (void) MONO_INTERNAL;
+void sgen_dump_pin_queue (void) MONO_INTERNAL;
 
 /* Pinning stats */
 
-void mono_sgen_pin_stats_register_address (char *addr, int pin_type) MONO_INTERNAL;
-size_t mono_sgen_pin_stats_get_pinned_byte_count (int pin_type) MONO_INTERNAL;
-ObjectList *mono_sgen_pin_stats_get_object_list (void) MONO_INTERNAL;
-void mono_sgen_pin_stats_reset (void) MONO_INTERNAL;
+void sgen_pin_stats_register_address (char *addr, int pin_type) MONO_INTERNAL;
+size_t sgen_pin_stats_get_pinned_byte_count (int pin_type) MONO_INTERNAL;
+ObjectList *sgen_pin_stats_get_object_list (void) MONO_INTERNAL;
+void sgen_pin_stats_reset (void) MONO_INTERNAL;
 
 #endif
index 270d86842c5f661e5a982f5704e511f0b3da2033..0cd38e07f50cc36e48777e430eb0b92e4f6749b7 100644 (file)
@@ -66,7 +66,7 @@ binary_protocol_flush_buffers_rec (BinaryProtocolBuffer *buffer)
        g_assert (buffer->index > 0);
        fwrite (buffer->buffer, 1, buffer->index, binary_protocol_file);
 
-       mono_sgen_free_os_memory (buffer, sizeof (BinaryProtocolBuffer));
+       sgen_free_os_memory (buffer, sizeof (BinaryProtocolBuffer));
 }
 
 void
@@ -94,12 +94,12 @@ binary_protocol_get_buffer (int length)
        if (buffer && buffer->index + length <= BINARY_PROTOCOL_BUFFER_SIZE)
                return buffer;
 
-       new_buffer = mono_sgen_alloc_os_memory (sizeof (BinaryProtocolBuffer), TRUE);
+       new_buffer = sgen_alloc_os_memory (sizeof (BinaryProtocolBuffer), TRUE);
        new_buffer->next = buffer;
        new_buffer->index = 0;
 
        if (InterlockedCompareExchangePointer ((void**)&binary_protocol_buffers, new_buffer, buffer) != buffer) {
-               mono_sgen_free_os_memory (new_buffer, sizeof (BinaryProtocolBuffer));
+               sgen_free_os_memory (new_buffer, sizeof (BinaryProtocolBuffer));
                goto retry;
        }
 
diff --git a/mono/metadata/sgen-simple-nursery.c b/mono/metadata/sgen-simple-nursery.c
new file mode 100644 (file)
index 0000000..3f07688
--- /dev/null
@@ -0,0 +1,107 @@
+/*
+ * sgen-simple-nursery.c: Simple always promote nursery.
+ *
+ *
+ * SGen is licensed under the terms of the MIT X11 license
+ *
+ * Copyright 2001-2003 Ximian, Inc
+ * Copyright 2003-2010 Novell, Inc.
+ * Copyright 2011 Xamarin Inc (http://www.xamarin.com)
+ * 
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sublicense, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ * 
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ * 
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+ * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+ * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+ * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+#include "config.h"
+#ifdef HAVE_SGEN_GC
+
+#include "metadata/profiler-private.h"
+
+#include "metadata/sgen-gc.h"
+#include "metadata/sgen-protocol.h"
+
+static inline char*
+alloc_for_promotion (char *obj, size_t objsize, gboolean has_references)
+{
+       return major_collector.alloc_object (objsize, has_references);
+}
+
+static inline char*
+par_alloc_for_promotion (char *obj, size_t objsize, gboolean has_references)
+{
+       return major_collector.par_alloc_object (objsize, has_references);
+}
+
+static SgenFragment*
+build_fragments_get_exclude_head (void)
+{
+       return NULL;
+}
+
+static void
+build_fragments_release_exclude_head (void)
+{
+}
+
+static void
+build_fragments_finish (SgenFragmentAllocator *allocator)
+{
+}
+
+static void
+prepare_to_space (char *to_space_bitmap, int space_bitmap_size)
+{
+}
+
+static void
+clear_fragments (void)
+{      
+}
+
+static void
+init_nursery (SgenFragmentAllocator *allocator, char *start, char *end)
+{
+       sgen_fragment_allocator_add (allocator, start, end);
+}
+
+
+/******************************************Copy/Scan functins ************************************************/
+
+#include "sgen-minor-copy-object.h"
+#include "sgen-minor-scan-object.h"
+
+void
+sgen_simple_nursery_init (SgenMinorCollector *collector)
+{
+       collector->alloc_for_promotion = alloc_for_promotion;
+       collector->par_alloc_for_promotion = par_alloc_for_promotion;
+
+       collector->prepare_to_space = prepare_to_space;
+       collector->clear_fragments = clear_fragments;
+       collector->build_fragments_get_exclude_head = build_fragments_get_exclude_head;
+       collector->build_fragments_release_exclude_head = build_fragments_release_exclude_head;
+       collector->build_fragments_finish = build_fragments_finish;
+       collector->init_nursery = init_nursery;
+
+       FILL_MINOR_COLLECTOR_COPY_OBJECT (collector);
+       FILL_MINOR_COLLECTOR_SCAN_OBJECT (collector);
+}
+
+
+#endif
\ No newline at end of file
diff --git a/mono/metadata/sgen-split-nursery.c b/mono/metadata/sgen-split-nursery.c
new file mode 100644 (file)
index 0000000..492570b
--- /dev/null
@@ -0,0 +1,523 @@
+/*
+ * sgen-splliy-nursery.c: 3-space based nursery collector.
+ *
+ * Author:
+ *     Rodrigo Kumpera Kumpera <kumpera@gmail.com>
+ *
+ * SGen is licensed under the terms of the MIT X11 license
+ *
+ * Copyright 2001-2003 Ximian, Inc
+ * Copyright 2003-2010 Novell, Inc.
+ * Copyright 2011-2012 Xamarin Inc (http://www.xamarin.com)
+ * 
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sublicense, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ * 
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ * 
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+ * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+ * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+ * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+#include "config.h"
+#ifdef HAVE_SGEN_GC
+
+#include "metadata/profiler-private.h"
+
+#include "metadata/sgen-gc.h"
+#include "metadata/sgen-protocol.h"
+
+/*
+The nursery is logically divided into 3 spaces: Allocator space and two Survivor spaces.
+
+Objects are born (allocated by the mutator) in the Allocator Space.
+
+The Survivor spaces are divided in a copying collector style From and To spaces.
+The hole of each space switch on each collection.
+
+On each collection we process objects from the nursery this way:
+Objects from the Allocator Space are evacuated into the To Space.
+Objects from the Survivor From Space are evacuated into the old generation.
+
+
+The nursery is physically divided in two parts, set by the promotion barrier.
+
+The Allocator Space takes the botton part of the nursery.
+
+The Survivor spaces are intermingled in the top part of the nursery. It's done
+this way since the required size for the To Space depends on the survivor rate
+of objects from the Allocator Space. 
+
+During a collection when the object scan function see a nursery object it must
+determine if the object needs to be evacuated or left in place. Originally, this
+check was done by checking if a forwarding pointer is installed, but now an object
+can be in the To Space, it won't have a forwarding pointer and it must be left in place.
+
+In order to solve that we classify nursery memory been either in the From Space or in
+the To Space. Since the Allocator Space has the same behavior as the Survivor From Space
+they are unified for this purpoise - a bit confusing at first.
+
+This from/to classification is done on a larger granule than object to make the check efficient
+and, due to that, we must make sure that all fragemnts used to allocate memory from the To Space
+are naturally aligned in both ends to that granule to avoid wronly classifying a From Space object.
+
+TODO:
+-The promotion barrier is statically defined to 50% of the nursery, it should be dinamically adjusted based
+on survival rates;
+-We apply the same promotion policy to all objects, finalizable ones should age longer in the nursery;
+-We apply the same promotion policy to all stages of a collection, maybe we should promote more aggressively
+objects from non-stack roots, specially those found in the remembered set;
+-Fix our major collection trigger to happen before we do a minor GC and collect the nursery only once.
+-Make the serial fragment allocator fast path inlineable
+-Make aging threshold be based on survival rates and survivor occupancy;
+-Change promotion barrier to be size and not address based;
+-Pre allocate memory for young ages to make sure that on overflow only the older suffer;
+-Get rid of par_alloc_buffer_refill_mutex so to the parallel collection of the nursery doesn't suck;
+*/
+
+/*FIXME Move this to a separate header. */
+#define _toi(ptr) ((size_t)ptr)
+#define make_ptr_mask(bits) ((1 << bits) - 1)
+#define align_down(ptr, bits) ((void*)(_toi(ptr) & ~make_ptr_mask (bits)))
+#define align_up(ptr, bits) ((void*) ((_toi(ptr) + make_ptr_mask (bits)) & ~make_ptr_mask (bits)))
+
+/*
+Even though the effective max age is 255, aging that much doesn't make sense.
+It might even make sense to use nimbles for age recording.
+*/
+#define MAX_AGE 15
+
+typedef struct {
+       char *next;
+       char *end;
+} AgeAllocationBuffer;
+
+/* Limits the ammount of memory the mutator can have. */
+static char *promotion_barrier;
+
+/*
+Promotion age and alloc ratio are the two nursery knobs to control
+how much effort we want to spend on young objects.
+
+Allocation ratio should be the inverse of the expected survivor rate.
+The more objects surviver, the smaller the alloc ratio much be so we can
+age all objects.
+
+Promote age depends on how much effort we want to spend aging objects before
+we promote them to the old generation. If addional ages don't somewhat improve
+mortality, it's better avoid as they increase the cost of minor collections.
+
+*/
+
+
+/*
+If we're evacuating an object with this age or more, promote it.
+Age is the number of surviving collections of an object.
+*/
+static int promote_age = 2;
+
+/*
+Initial ratio of allocation and survivor spaces.
+This should be read as the fraction of the whole nursery dedicated
+for the allocator space.
+*/
+static float alloc_ratio = 60.f/100.f;
+
+
+static char *region_age;
+static int region_age_size;
+static AgeAllocationBuffer age_alloc_buffers [MAX_AGE];
+
+/* The collector allocs from here. */
+static SgenFragmentAllocator collector_allocator;
+
+static LOCK_DECLARE (par_alloc_buffer_refill_mutex);
+
+static inline int
+get_object_age (char *object)
+{
+       int idx = (object - sgen_nursery_start) >> SGEN_TO_SPACE_GRANULE_BITS;
+       return region_age [idx];
+}
+
+static inline void
+set_object_age (char *object, int age)
+{
+       int idx = (object - sgen_nursery_start) >> SGEN_TO_SPACE_GRANULE_BITS;
+       region_age [idx] = age;
+}
+
+static void
+set_age_in_range (char *start, char *end, int age)
+{
+       char *region_start;
+       int region_idx, length;
+       region_idx = (start - sgen_nursery_start) >> SGEN_TO_SPACE_GRANULE_BITS;
+       region_start = &region_age [region_idx];
+       length = (end - start) >> SGEN_TO_SPACE_GRANULE_BITS;
+       memset (region_start, age, length);
+}
+
+static inline void
+mark_bit (char *space_bitmap, char *pos)
+{
+       int idx = (pos - sgen_nursery_start) >> SGEN_TO_SPACE_GRANULE_BITS;
+       int byte = idx / 8;
+       int bit = idx & 0x7;
+
+       g_assert (byte < sgen_space_bitmap_size);
+       space_bitmap [byte] |= 1 << bit;
+}
+
+static void
+mark_bits_in_range (char *space_bitmap, char *start, char *end)
+{
+       start = align_down (start, SGEN_TO_SPACE_GRANULE_BITS);
+       end = align_up (end, SGEN_TO_SPACE_GRANULE_BITS);
+
+       for (;start < end; start += SGEN_TO_SPACE_GRANULE_IN_BYTES)
+               mark_bit (space_bitmap, start);
+}
+
+static void
+fragment_list_split (SgenFragmentAllocator *allocator)
+{
+       SgenFragment *prev = NULL, *list = allocator->region_head;
+
+       while (list) {
+               if (list->fragment_end > promotion_barrier) {
+                       if (list->fragment_start < promotion_barrier) {
+                               SgenFragment *res = sgen_fragment_allocator_alloc ();
+
+                               res->fragment_start = promotion_barrier;
+                               res->fragment_next = promotion_barrier;
+                               res->fragment_end = list->fragment_end;
+                               res->next = list->next;
+                               res->next_in_order = list->next_in_order;
+                               g_assert (res->fragment_end > res->fragment_start);
+
+                               list->fragment_end = promotion_barrier;
+                               list->next = list->next_in_order = NULL;
+                               set_age_in_range (list->fragment_start, list->fragment_end, 0);
+
+                               allocator->region_head = allocator->alloc_head = res;
+                               return;
+                       } else {
+                               if (prev)
+                                       prev->next = prev->next_in_order = NULL;
+                               allocator->region_head = allocator->alloc_head = list;
+                               return;
+                       }
+               }
+               set_age_in_range (list->fragment_start, list->fragment_end, 0);
+               prev = list;
+               list = list->next;
+       }
+       allocator->region_head = allocator->alloc_head = NULL;
+}
+
+/******************************************Minor Collector API ************************************************/
+
+#define AGE_ALLOC_BUFFER_MIN_SIZE SGEN_TO_SPACE_GRANULE_IN_BYTES
+#define AGE_ALLOC_BUFFER_DESIRED_SIZE (SGEN_TO_SPACE_GRANULE_IN_BYTES * 8)
+
+static char*
+alloc_for_promotion_slow_path (int age, size_t objsize)
+{
+       char *p;
+       size_t allocated_size;
+       size_t aligned_objsize = (size_t)align_up (objsize, SGEN_TO_SPACE_GRANULE_BITS);
+
+       p = sgen_fragment_allocator_serial_range_alloc (
+               &collector_allocator,
+               MAX (aligned_objsize, AGE_ALLOC_BUFFER_DESIRED_SIZE),
+               MAX (aligned_objsize, AGE_ALLOC_BUFFER_MIN_SIZE),
+               &allocated_size);
+       if (p) {
+               set_age_in_range (p, p + allocated_size, age);
+               sgen_clear_range (age_alloc_buffers [age].next, age_alloc_buffers [age].end);
+               age_alloc_buffers [age].next = p + objsize;
+               age_alloc_buffers [age].end = p + allocated_size;
+       }
+       return p;
+}
+
+static inline char*
+alloc_for_promotion (char *obj, size_t objsize, gboolean has_references)
+{
+       char *p = NULL;
+       int age;
+
+       age = get_object_age (obj);
+       if (age >= promote_age)
+               return major_collector.alloc_object (objsize, has_references);
+
+       /* Promote! */
+       ++age;
+
+       p = age_alloc_buffers [age].next;
+       if (G_LIKELY (p + objsize <= age_alloc_buffers [age].end)) {
+        age_alloc_buffers [age].next += objsize;
+       } else {
+               p = alloc_for_promotion_slow_path (age, objsize);
+               if (!p)
+                       p = major_collector.alloc_object (objsize, has_references);
+       }
+
+       return p;
+}
+
+static char*
+par_alloc_for_promotion_slow_path (int age, size_t objsize)
+{
+       char *p;
+       size_t allocated_size;
+       size_t aligned_objsize = (size_t)align_up (objsize, SGEN_TO_SPACE_GRANULE_BITS);
+
+       mono_mutex_lock (&par_alloc_buffer_refill_mutex);
+
+restart:
+       p = age_alloc_buffers [age].next;
+       if (G_LIKELY (p + objsize <= age_alloc_buffers [age].end)) {
+               if (SGEN_CAS_PTR ((void*)&age_alloc_buffers [age].next, p + objsize, p) != p)
+                       goto restart;
+       } else {
+               /*Reclaim remaining space*/
+               char *end = age_alloc_buffers [age].end;
+               do {
+                       p = age_alloc_buffers [age].next;
+               } while (SGEN_CAS_PTR ((void*)&age_alloc_buffers [age].next, end, p) != p);
+               sgen_clear_range (p, end);
+
+               /* By setting end to NULL we make sure no other thread can advance while we're updating.*/
+               age_alloc_buffers [age].end = NULL;
+               mono_memory_barrier ();
+
+               p = sgen_fragment_allocator_par_range_alloc (
+                       &collector_allocator,
+                       MAX (aligned_objsize, AGE_ALLOC_BUFFER_DESIRED_SIZE),
+                       MAX (aligned_objsize, AGE_ALLOC_BUFFER_MIN_SIZE),
+                       &allocated_size);
+               if (p) {
+                       set_age_in_range (p, p + allocated_size, age);
+                       sgen_clear_range (age_alloc_buffers [age].next, age_alloc_buffers [age].end);
+                       age_alloc_buffers [age].next = p + objsize;
+                       age_alloc_buffers [age].end = p + allocated_size;
+               }
+       }
+
+       mono_mutex_unlock (&par_alloc_buffer_refill_mutex);
+       return p;
+}
+
+static inline char*
+par_alloc_for_promotion (char *obj, size_t objsize, gboolean has_references)
+{
+       char *p;
+       int age;
+
+       age = get_object_age (obj);
+       if (age >= promote_age)
+               return major_collector.par_alloc_object (objsize, has_references);
+
+restart:
+       p = age_alloc_buffers [age].next;
+       if (G_LIKELY (p + objsize <= age_alloc_buffers [age].end)) {
+               if (SGEN_CAS_PTR ((void*)&age_alloc_buffers [age].next, p + objsize, p) != p)
+                       goto restart;
+       } else {
+               p = par_alloc_for_promotion_slow_path (age, objsize);
+
+               /* Have we failed to promote to the nursery, lets just evacuate it to old gen. */
+               if (!p)
+                       p = major_collector.par_alloc_object (objsize, has_references);                 
+       }
+
+       return p;
+}
+
+static char*
+minor_alloc_for_promotion (char *obj, size_t objsize, gboolean has_references)
+{
+       /*
+       We only need to check for a non-nursery object if we're doing a major collection.
+       */
+       if (!sgen_ptr_in_nursery (obj))
+               return major_collector.alloc_object (objsize, has_references);
+
+       return alloc_for_promotion (obj, objsize, has_references);
+}
+
+static char*
+minor_par_alloc_for_promotion (char *obj, size_t objsize, gboolean has_references)
+{
+       /*
+       We only need to check for a non-nursery object if we're doing a major collection.
+       */
+       if (!sgen_ptr_in_nursery (obj))
+               return major_collector.par_alloc_object (objsize, has_references);
+
+       return par_alloc_for_promotion (obj, objsize, has_references);
+}
+
+static SgenFragment*
+build_fragments_get_exclude_head (void)
+{
+       int i;
+       for (i = 0; i < MAX_AGE; ++i)
+               sgen_clear_range (age_alloc_buffers [i].next, age_alloc_buffers [i].end);
+
+       return collector_allocator.region_head;
+}
+
+static void
+build_fragments_release_exclude_head (void)
+{
+       sgen_fragment_allocator_release (&collector_allocator);
+}
+
+static void
+build_fragments_finish (SgenFragmentAllocator *allocator)
+{
+       /* We split the fragment list based on the promotion barrier. */
+       collector_allocator = *allocator;
+       fragment_list_split (&collector_allocator);
+}
+
+static void
+prepare_to_space (char *to_space_bitmap, int space_bitmap_size)
+{
+       SgenFragment **previous, *frag;
+
+       memset (to_space_bitmap, 0, space_bitmap_size);
+       memset (age_alloc_buffers, 0, sizeof (age_alloc_buffers));
+
+       previous = &collector_allocator.alloc_head;
+
+       for (frag = *previous; frag; frag = *previous) {
+               char *start = align_up (frag->fragment_next, SGEN_TO_SPACE_GRANULE_BITS);
+               char *end = align_down (frag->fragment_end, SGEN_TO_SPACE_GRANULE_BITS);
+
+               /* Fragment is too small to be usable. */
+               if ((end - start) < SGEN_MAX_NURSERY_WASTE) {
+                       sgen_clear_range (frag->fragment_next, frag->fragment_end);
+                       frag->fragment_next = frag->fragment_end = frag->fragment_start;
+                       *previous = frag->next;
+                       continue;
+               }
+
+               /*
+               We need to insert 3 phony objects so the fragments build step can correctly
+               walk the nursery.
+               */
+
+               /* Clean the fragment range. */
+               sgen_clear_range (start, end);
+               /* We need a phony object in between the original fragment start and the effective one. */
+               if (start != frag->fragment_next)
+                       sgen_clear_range (frag->fragment_next, start);
+               /* We need an phony object in between the new fragment end and the original fragment end. */
+               if (end != frag->fragment_end)
+                       sgen_clear_range (end, frag->fragment_end);
+
+               frag->fragment_start = frag->fragment_next = start;
+               frag->fragment_end = end;
+               mark_bits_in_range (to_space_bitmap, start, end);
+               previous = &frag->next;
+       }
+}
+
+static void
+clear_fragments (void)
+{
+       sgen_clear_allocator_fragments (&collector_allocator);
+}
+
+static void
+init_nursery (SgenFragmentAllocator *allocator, char *start, char *end)
+{
+       int alloc_quote = (int)((end - start) * alloc_ratio);
+       promotion_barrier = align_down (start + alloc_quote, 3);
+       sgen_fragment_allocator_add (allocator, start, promotion_barrier);
+       sgen_fragment_allocator_add (&collector_allocator, promotion_barrier, end);
+
+       region_age_size = (end - start) >> SGEN_TO_SPACE_GRANULE_BITS;
+       region_age = g_malloc0 (region_age_size);
+}
+
+static gboolean
+handle_gc_param (const char *opt)
+{
+       if (g_str_has_prefix (opt, "alloc-ratio=")) {
+               const char *arg = strchr (opt, '=') + 1;
+               int percentage = atoi (arg);
+               if (percentage < 1 || percentage > 100) {
+                       fprintf (stderr, "alloc-ratio must be an integer in the range 1-100.\n");
+                       exit (1);
+               }
+               alloc_ratio = (float)percentage / 100.0f;
+               return TRUE;
+       }
+
+       if (g_str_has_prefix (opt, "promotion-age=")) {
+               const char *arg = strchr (opt, '=') + 1;
+               promote_age = atoi (arg);
+               if (promote_age < 1 || promote_age >= MAX_AGE) {
+                       fprintf (stderr, "promotion-age must be an integer in the range 1-%d.\n", MAX_AGE - 1);
+                       exit (1);
+               }
+               return TRUE;
+       }
+       return FALSE;
+}
+
+static void
+print_gc_param_usage (void)
+{
+       fprintf (stderr,
+                       ""
+                       "  alloc-ratio=P (where P is a percentage, an integer in 1-100)\n"
+                       "  promotion-age=P (where P is a number, an integer in 1-%d)\n",
+                       MAX_AGE - 1
+                       );
+}
+
+/******************************************Copy/Scan functins ************************************************/
+
+#include "sgen-minor-copy-object.h"
+#include "sgen-minor-scan-object.h"
+
+
+void
+sgen_split_nursery_init (SgenMinorCollector *collector)
+{
+       collector->alloc_for_promotion = minor_alloc_for_promotion;
+       collector->par_alloc_for_promotion = minor_par_alloc_for_promotion;
+
+       collector->prepare_to_space = prepare_to_space;
+       collector->clear_fragments = clear_fragments;
+       collector->build_fragments_get_exclude_head = build_fragments_get_exclude_head;
+       collector->build_fragments_release_exclude_head = build_fragments_release_exclude_head;
+       collector->build_fragments_finish = build_fragments_finish;
+       collector->init_nursery = init_nursery;
+       collector->handle_gc_param = handle_gc_param;
+       collector->print_gc_param_usage = print_gc_param_usage;
+
+       FILL_MINOR_COLLECTOR_COPY_OBJECT (collector);
+       FILL_MINOR_COLLECTOR_SCAN_OBJECT (collector);
+       LOCK_INIT (par_alloc_buffer_refill_mutex);
+}
+
+
+#endif
\ No newline at end of file
index 65f0c6da55349dbeec632934bffbd5f31797c1c0..0b7519a27289df19bec4e1ab614852b02a4a5d17 100644 (file)
@@ -90,7 +90,7 @@ remset_byte_size (RememberedSet *remset)
 static void
 add_generic_store_remset_from_buffer (gpointer *buffer)
 {
-       GenericStoreRememberedSet *remset = mono_sgen_alloc_internal (INTERNAL_MEM_STORE_REMSET);
+       GenericStoreRememberedSet *remset = sgen_alloc_internal (INTERNAL_MEM_STORE_REMSET);
        memcpy (remset->data, buffer + 1, sizeof (gpointer) * (STORE_REMSET_BUFFER_SIZE - 1));
        remset->next = generic_store_remsets;
        generic_store_remsets = remset;
@@ -114,9 +114,9 @@ evacuate_remset_buffer (void)
  * and doesn't waste any alloc paddin space.
  */
 static RememberedSet*
-mono_sgen_alloc_remset (int size, gpointer id, gboolean global)
+sgen_alloc_remset (int size, gpointer id, gboolean global)
 {
-       RememberedSet* res = mono_sgen_alloc_internal_dynamic (sizeof (RememberedSet) + (size * sizeof (gpointer)), INTERNAL_MEM_REMSET);
+       RememberedSet* res = sgen_alloc_internal_dynamic (sizeof (RememberedSet) + (size * sizeof (gpointer)), INTERNAL_MEM_REMSET);
        res->store_next = res->data;
        res->end_set = res->data + size;
        res->next = NULL;
@@ -127,7 +127,7 @@ mono_sgen_alloc_remset (int size, gpointer id, gboolean global)
 
 
 static void
-mono_sgen_ssb_wbarrier_set_field (MonoObject *obj, gpointer field_ptr, MonoObject* value)
+sgen_ssb_wbarrier_set_field (MonoObject *obj, gpointer field_ptr, MonoObject* value)
 {
        RememberedSet *rs;
        TLAB_ACCESS_INIT;
@@ -140,7 +140,7 @@ mono_sgen_ssb_wbarrier_set_field (MonoObject *obj, gpointer field_ptr, MonoObjec
                UNLOCK_GC;
                return;
        }
-       rs = mono_sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
+       rs = sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
        rs->next = REMEMBERED_SET;
        REMEMBERED_SET = rs;
 #ifdef HAVE_KW_THREAD
@@ -152,7 +152,7 @@ mono_sgen_ssb_wbarrier_set_field (MonoObject *obj, gpointer field_ptr, MonoObjec
 }
 
 static void
-mono_sgen_ssb_wbarrier_set_arrayref (MonoArray *arr, gpointer slot_ptr, MonoObject* value)
+sgen_ssb_wbarrier_set_arrayref (MonoArray *arr, gpointer slot_ptr, MonoObject* value)
 {
        RememberedSet *rs;
        TLAB_ACCESS_INIT;
@@ -165,7 +165,7 @@ mono_sgen_ssb_wbarrier_set_arrayref (MonoArray *arr, gpointer slot_ptr, MonoObje
                UNLOCK_GC;
                return;
        }
-       rs = mono_sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
+       rs = sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
        rs->next = REMEMBERED_SET;
        REMEMBERED_SET = rs;
 #ifdef HAVE_KW_THREAD
@@ -177,7 +177,7 @@ mono_sgen_ssb_wbarrier_set_arrayref (MonoArray *arr, gpointer slot_ptr, MonoObje
 }
 
 static void
-mono_sgen_ssb_wbarrier_arrayref_copy (gpointer dest_ptr, gpointer src_ptr, int count)
+sgen_ssb_wbarrier_arrayref_copy (gpointer dest_ptr, gpointer src_ptr, int count)
 {
        RememberedSet *rs;
        TLAB_ACCESS_INIT;
@@ -192,7 +192,7 @@ mono_sgen_ssb_wbarrier_arrayref_copy (gpointer dest_ptr, gpointer src_ptr, int c
                UNLOCK_GC;
                return;
        }
-       rs = mono_sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
+       rs = sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
        rs->next = REMEMBERED_SET;
        REMEMBERED_SET = rs;
 #ifdef HAVE_KW_THREAD
@@ -205,7 +205,7 @@ mono_sgen_ssb_wbarrier_arrayref_copy (gpointer dest_ptr, gpointer src_ptr, int c
 }
 
 static void
-mono_sgen_ssb_wbarrier_value_copy (gpointer dest, gpointer src, int count, MonoClass *klass)
+sgen_ssb_wbarrier_value_copy (gpointer dest, gpointer src, int count, MonoClass *klass)
 {
        RememberedSet *rs;
        size_t element_size = mono_class_value_size (klass, NULL);
@@ -226,7 +226,7 @@ mono_sgen_ssb_wbarrier_value_copy (gpointer dest, gpointer src, int count, MonoC
                UNLOCK_GC;
                return;
        }
-       rs = mono_sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
+       rs = sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
        rs->next = REMEMBERED_SET;
        REMEMBERED_SET = rs;
 #ifdef HAVE_KW_THREAD
@@ -240,7 +240,7 @@ mono_sgen_ssb_wbarrier_value_copy (gpointer dest, gpointer src, int count, MonoC
 }      
 
 static void
-mono_sgen_ssb_wbarrier_object_copy (MonoObject* obj, MonoObject *src)
+sgen_ssb_wbarrier_object_copy (MonoObject* obj, MonoObject *src)
 {
        int size;
        RememberedSet *rs;
@@ -261,7 +261,7 @@ mono_sgen_ssb_wbarrier_object_copy (MonoObject* obj, MonoObject *src)
                UNLOCK_GC;
                return;
        }
-       rs = mono_sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
+       rs = sgen_alloc_remset (rs->end_set - rs->data, (void*)1, FALSE);
        rs->next = REMEMBERED_SET;
        REMEMBERED_SET = rs;
 
@@ -273,7 +273,7 @@ mono_sgen_ssb_wbarrier_object_copy (MonoObject* obj, MonoObject *src)
 }
 
 static void
-mono_sgen_ssb_wbarrier_generic_nostore (gpointer ptr)
+sgen_ssb_wbarrier_generic_nostore (gpointer ptr)
 {
        gpointer *buffer;
        int index;
@@ -365,7 +365,7 @@ remset_stats (void)
        for (remset = global_remset; remset; remset = remset->next)
                size += remset->store_next - remset->data;
 
-       bumper = addresses = mono_sgen_alloc_internal_dynamic (sizeof (mword) * size, INTERNAL_MEM_STATISTICS);
+       bumper = addresses = sgen_alloc_internal_dynamic (sizeof (mword) * size, INTERNAL_MEM_STATISTICS);
 
        FOREACH_THREAD (info) {
                for (remset = info->remset; remset; remset = remset->next)
@@ -380,7 +380,7 @@ remset_stats (void)
 
        stat_store_remsets += bumper - addresses;
 
-       mono_sgen_sort_addresses ((void**)addresses, bumper - addresses);
+       sgen_sort_addresses ((void**)addresses, bumper - addresses);
        p = addresses;
        r = addresses + 1;
        while (r < bumper) {
@@ -391,7 +391,7 @@ remset_stats (void)
 
        stat_store_remsets_unique += p - addresses;
 
-       mono_sgen_free_internal_dynamic (addresses, sizeof (mword) * size, INTERNAL_MEM_STATISTICS);
+       sgen_free_internal_dynamic (addresses, sizeof (mword) * size, INTERNAL_MEM_STATISTICS);
 }
 #endif
 
@@ -415,43 +415,46 @@ handle_remset (mword *p, void *start_nursery, void *end_nursery, gboolean global
                //__builtin_prefetch (ptr);
                if (((void*)ptr < start_nursery || (void*)ptr >= end_nursery)) {
                        gpointer old = *ptr;
-                       major_collector.copy_object (ptr, queue);
+
+                       sgen_get_current_object_ops ()->copy_or_mark_object (ptr, queue);
                        DEBUG (9, fprintf (gc_debug_file, "Overwrote remset at %p with %p\n", ptr, *ptr));
                        if (old)
-                               binary_protocol_ptr_update (ptr, old, *ptr, (gpointer)LOAD_VTABLE (*ptr), mono_sgen_safe_object_get_size (*ptr));
+                               binary_protocol_ptr_update (ptr, old, *ptr, (gpointer)LOAD_VTABLE (*ptr), sgen_safe_object_get_size (*ptr));
                        if (!global && *ptr >= start_nursery && *ptr < end_nursery) {
                                /*
                                 * If the object is pinned, each reference to it from nonpinned objects
                                 * becomes part of the global remset, which can grow very large.
                                 */
-                               DEBUG (9, fprintf (gc_debug_file, "Add to global remset because of pinning %p (%p %s)\n", ptr, *ptr, mono_sgen_safe_name (*ptr)));
-                               mono_sgen_add_to_global_remset (ptr);
+                               DEBUG (9, fprintf (gc_debug_file, "Add to global remset because of pinning %p (%p %s)\n", ptr, *ptr, sgen_safe_name (*ptr)));
+                               sgen_add_to_global_remset (ptr);
                        }
                } else {
                        DEBUG (9, fprintf (gc_debug_file, "Skipping remset at %p holding %p\n", ptr, *ptr));
                }
                return p + 1;
-       case REMSET_RANGE:
+       case REMSET_RANGE: {
+               CopyOrMarkObjectFunc copy_func = sgen_get_current_object_ops ()->copy_or_mark_object;
+
                ptr = (void**)(*p & ~REMSET_TYPE_MASK);
                if (((void*)ptr >= start_nursery && (void*)ptr < end_nursery))
                        return p + 2;
                count = p [1];
                while (count-- > 0) {
-                       major_collector.copy_object (ptr, queue);
+                       copy_func (ptr, queue);
                        DEBUG (9, fprintf (gc_debug_file, "Overwrote remset at %p with %p (count: %d)\n", ptr, *ptr, (int)count));
                        if (!global && *ptr >= start_nursery && *ptr < end_nursery)
-                               mono_sgen_add_to_global_remset (ptr);
+                               sgen_add_to_global_remset (ptr);
                        ++ptr;
                }
                return p + 2;
+       }
        case REMSET_OBJECT:
                ptr = (void**)(*p & ~REMSET_TYPE_MASK);
                if (((void*)ptr >= start_nursery && (void*)ptr < end_nursery))
                        return p + 1;
-               mono_sgen_get_minor_scan_object () ((char*)ptr, queue);
+               sgen_get_current_object_ops ()->scan_object ((char*)ptr, queue);
                return p + 1;
        case REMSET_VTYPE: {
-               ScanVTypeFunc scan_vtype = mono_sgen_get_minor_scan_vtype ();
                size_t skip_size;
 
                ptr = (void**)(*p & ~REMSET_TYPE_MASK);
@@ -461,7 +464,7 @@ handle_remset (mword *p, void *start_nursery, void *end_nursery, gboolean global
                count = p [2];
                skip_size = p [3];
                while (count-- > 0) {
-                       scan_vtype ((char*)ptr, desc, queue);
+                       sgen_get_current_object_ops ()->scan_vtype ((char*)ptr, desc, queue);
                        ptr = (void**)((char*)ptr + skip_size);
                }
                return p + 4;
@@ -473,7 +476,7 @@ handle_remset (mword *p, void *start_nursery, void *end_nursery, gboolean global
 }
 
 static void
-mono_sgen_ssb_begin_scan_remsets (void *start_nursery, void *end_nursery, SgenGrayQueue *queue)
+sgen_ssb_begin_scan_remsets (void *start_nursery, void *end_nursery, SgenGrayQueue *queue)
 {
        RememberedSet *remset;
        mword *p, *next_p, *store_pos;
@@ -500,7 +503,7 @@ mono_sgen_ssb_begin_scan_remsets (void *start_nursery, void *end_nursery, SgenGr
                         *
                         * Since all global remsets are location remsets, we don't need to unmask the pointer.
                         */
-                       if (mono_sgen_ptr_in_nursery (*ptr)) {
+                       if (sgen_ptr_in_nursery (*ptr)) {
                                *store_pos ++ = p [0];
                                HEAVY_STAT (++stat_global_remsets_readded);
                        }
@@ -512,7 +515,7 @@ mono_sgen_ssb_begin_scan_remsets (void *start_nursery, void *end_nursery, SgenGr
 }
 
 static void
-mono_sgen_ssb_finish_scan_remsets (void *start_nursery, void *end_nursery, SgenGrayQueue *queue)
+sgen_ssb_finish_scan_remsets (void *start_nursery, void *end_nursery, SgenGrayQueue *queue)
 {
        int i;
        SgenThreadInfo *info;
@@ -535,7 +538,7 @@ mono_sgen_ssb_finish_scan_remsets (void *start_nursery, void *end_nursery, SgenG
                                handle_remset ((mword*)&addr, start_nursery, end_nursery, FALSE, queue);
                }
 
-               mono_sgen_free_internal (store_remset, INTERNAL_MEM_STORE_REMSET);
+               sgen_free_internal (store_remset, INTERNAL_MEM_STORE_REMSET);
 
                store_remset = next;
        }
@@ -554,7 +557,7 @@ mono_sgen_ssb_finish_scan_remsets (void *start_nursery, void *end_nursery, SgenG
                        remset->next = NULL;
                        if (remset != info->remset) {
                                DEBUG (4, fprintf (gc_debug_file, "Freed remset at %p\n", remset->data));
-                               mono_sgen_free_internal_dynamic (remset, remset_byte_size (remset), INTERNAL_MEM_REMSET);
+                               sgen_free_internal_dynamic (remset, remset_byte_size (remset), INTERNAL_MEM_REMSET);
                        }
                }
                for (j = 0; j < *info->store_remset_buffer_index_addr; ++j)
@@ -571,14 +574,14 @@ mono_sgen_ssb_finish_scan_remsets (void *start_nursery, void *end_nursery, SgenG
                        p = handle_remset (p, start_nursery, end_nursery, FALSE, queue);
                next = remset->next;
                DEBUG (4, fprintf (gc_debug_file, "Freed remset at %p\n", remset->data));
-               mono_sgen_free_internal_dynamic (remset, remset_byte_size (remset), INTERNAL_MEM_REMSET);
+               sgen_free_internal_dynamic (remset, remset_byte_size (remset), INTERNAL_MEM_REMSET);
                freed_thread_remsets = next;
        }
 }
 
 
 static void
-mono_sgen_ssb_cleanup_thread (SgenThreadInfo *p)
+sgen_ssb_cleanup_thread (SgenThreadInfo *p)
 {
        RememberedSet *rset;
 
@@ -595,7 +598,7 @@ mono_sgen_ssb_cleanup_thread (SgenThreadInfo *p)
 
        if (*p->store_remset_buffer_index_addr)
                add_generic_store_remset_from_buffer (*p->store_remset_buffer_addr);
-       mono_sgen_free_internal (*p->store_remset_buffer_addr, INTERNAL_MEM_STORE_REMSET);
+       sgen_free_internal (*p->store_remset_buffer_addr, INTERNAL_MEM_STORE_REMSET);
 
        /*
         * This is currently not strictly required, but we do it
@@ -610,25 +613,25 @@ mono_sgen_ssb_cleanup_thread (SgenThreadInfo *p)
 }
 
 static void
-mono_sgen_ssb_register_thread (SgenThreadInfo *info)
+sgen_ssb_register_thread (SgenThreadInfo *info)
 {
 #ifndef HAVE_KW_THREAD
        SgenThreadInfo *__thread_info__ = info;
 #endif
 
-       info->remset = mono_sgen_alloc_remset (DEFAULT_REMSET_SIZE, info, FALSE);
+       info->remset = sgen_alloc_remset (DEFAULT_REMSET_SIZE, info, FALSE);
        mono_native_tls_set_value (remembered_set_key, info->remset);
 #ifdef HAVE_KW_THREAD
        remembered_set = info->remset;
 #endif
 
-       STORE_REMSET_BUFFER = mono_sgen_alloc_internal (INTERNAL_MEM_STORE_REMSET);
+       STORE_REMSET_BUFFER = sgen_alloc_internal (INTERNAL_MEM_STORE_REMSET);
        STORE_REMSET_BUFFER_INDEX = 0;
 }
 
 #ifdef HAVE_KW_THREAD
 static void
-mono_sgen_ssb_fill_thread_info_for_suspend (SgenThreadInfo *info)
+sgen_ssb_fill_thread_info_for_suspend (SgenThreadInfo *info)
 {
        /* update the remset info in the thread data structure */
        info->remset = remembered_set;
@@ -636,7 +639,7 @@ mono_sgen_ssb_fill_thread_info_for_suspend (SgenThreadInfo *info)
 #endif
 
 static void
-mono_sgen_ssb_prepare_for_minor_collection (void)
+sgen_ssb_prepare_for_minor_collection (void)
 {
        memset (global_remset_cache, 0, sizeof (global_remset_cache));
 }
@@ -647,12 +650,12 @@ mono_sgen_ssb_prepare_for_minor_collection (void)
  * during the copy.
  */
 static void
-mono_sgen_ssb_prepare_for_major_collection (void)
+sgen_ssb_prepare_for_major_collection (void)
 {
        SgenThreadInfo *info;
        RememberedSet *remset, *next;
        
-       mono_sgen_ssb_prepare_for_minor_collection ();
+       sgen_ssb_prepare_for_minor_collection ();
 
        /* the global list */
        for (remset = global_remset; remset; remset = next) {
@@ -661,13 +664,13 @@ mono_sgen_ssb_prepare_for_major_collection (void)
                remset->next = NULL;
                if (remset != global_remset) {
                        DEBUG (4, fprintf (gc_debug_file, "Freed remset at %p\n", remset->data));
-                       mono_sgen_free_internal_dynamic (remset, remset_byte_size (remset), INTERNAL_MEM_REMSET);
+                       sgen_free_internal_dynamic (remset, remset_byte_size (remset), INTERNAL_MEM_REMSET);
                }
        }
        /* the generic store ones */
        while (generic_store_remsets) {
                GenericStoreRememberedSet *gs_next = generic_store_remsets->next;
-               mono_sgen_free_internal (generic_store_remsets, INTERNAL_MEM_STORE_REMSET);
+               sgen_free_internal (generic_store_remsets, INTERNAL_MEM_STORE_REMSET);
                generic_store_remsets = gs_next;
        }
        /* the per-thread ones */
@@ -678,7 +681,7 @@ mono_sgen_ssb_prepare_for_major_collection (void)
                        remset->next = NULL;
                        if (remset != info->remset) {
                                DEBUG (3, fprintf (gc_debug_file, "Freed remset at %p\n", remset->data));
-                               mono_sgen_free_internal_dynamic (remset, remset_byte_size (remset), INTERNAL_MEM_REMSET);
+                               sgen_free_internal_dynamic (remset, remset_byte_size (remset), INTERNAL_MEM_REMSET);
                        }
                }
                clear_thread_store_remset_buffer (info);
@@ -688,7 +691,7 @@ mono_sgen_ssb_prepare_for_major_collection (void)
        while (freed_thread_remsets) {
                next = freed_thread_remsets->next;
                DEBUG (4, fprintf (gc_debug_file, "Freed remset at %p\n", freed_thread_remsets->data));
-               mono_sgen_free_internal_dynamic (freed_thread_remsets, remset_byte_size (freed_thread_remsets), INTERNAL_MEM_REMSET);
+               sgen_free_internal_dynamic (freed_thread_remsets, remset_byte_size (freed_thread_remsets), INTERNAL_MEM_REMSET);
                freed_thread_remsets = next;
        }
 }
@@ -731,13 +734,13 @@ global_remset_location_was_not_added (gpointer ptr)
 }
 
 static void
-mono_sgen_ssb_record_pointer (gpointer ptr)
+sgen_ssb_record_pointer (gpointer ptr)
 {
        RememberedSet *rs;
-       gboolean lock = mono_sgen_collection_is_parallel ();
+       gboolean lock = sgen_collection_is_parallel ();
        gpointer obj = *(gpointer*)ptr;
 
-       g_assert (!mono_sgen_ptr_in_nursery (ptr) && mono_sgen_ptr_in_nursery (obj));
+       g_assert (!sgen_ptr_in_nursery (ptr) && sgen_ptr_in_nursery (obj));
 
        if (lock)
                LOCK_GLOBAL_REMSET;
@@ -746,7 +749,7 @@ mono_sgen_ssb_record_pointer (gpointer ptr)
                goto done;
 
        if (G_UNLIKELY (do_pin_stats))
-               mono_sgen_pin_stats_register_global_remset (obj);
+               sgen_pin_stats_register_global_remset (obj);
 
        DEBUG (8, fprintf (gc_debug_file, "Adding global remset for %p\n", ptr));
        binary_protocol_global_remset (ptr, *(gpointer*)ptr, (gpointer)LOAD_VTABLE (obj));
@@ -761,7 +764,7 @@ mono_sgen_ssb_record_pointer (gpointer ptr)
                *(global_remset->store_next++) = (mword)ptr;
                goto done;
        }
-       rs = mono_sgen_alloc_remset (global_remset->end_set - global_remset->data, NULL, TRUE);
+       rs = sgen_alloc_remset (global_remset->end_set - global_remset->data, NULL, TRUE);
        rs->next = global_remset;
        global_remset = rs;
        *(global_remset->store_next++) = (mword)ptr;
@@ -806,7 +809,7 @@ find_in_remset_loc (mword *p, char *addr, gboolean *found)
                return p + 2;
        case REMSET_OBJECT:
                ptr = (void**)(*p & ~REMSET_TYPE_MASK);
-               count = mono_sgen_safe_object_get_size ((MonoObject*)ptr); 
+               count = sgen_safe_object_get_size ((MonoObject*)ptr); 
                count = SGEN_ALIGN_UP (count);
                count /= sizeof (mword);
                if ((void**)addr >= ptr && (void**)addr < ptr + count)
@@ -834,7 +837,7 @@ find_in_remset_loc (mword *p, char *addr, gboolean *found)
  * Return whenever ADDR occurs in the remembered sets
  */
 static gboolean
-mono_sgen_ssb_find_address (char *addr)
+sgen_ssb_find_address (char *addr)
 {
        int i;
        SgenThreadInfo *info;
@@ -893,11 +896,11 @@ mono_sgen_ssb_find_address (char *addr)
 
 
 void
-mono_sgen_ssb_init (SgenRemeberedSet *remset)
+sgen_ssb_init (SgenRemeberedSet *remset)
 {
        LOCK_INIT (global_remset_mutex);
 
-       global_remset = mono_sgen_alloc_remset (1024, NULL, FALSE);
+       global_remset = sgen_alloc_remset (1024, NULL, FALSE);
        global_remset->next = NULL;
 
        mono_native_tls_alloc (&remembered_set_key, NULL);
@@ -916,26 +919,26 @@ mono_sgen_ssb_init (SgenRemeberedSet *remset)
        mono_counters_register ("Global remsets discarded", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_global_remsets_discarded);
 #endif
 
-       remset->wbarrier_set_field = mono_sgen_ssb_wbarrier_set_field;
-       remset->wbarrier_set_arrayref = mono_sgen_ssb_wbarrier_set_arrayref;
-       remset->wbarrier_arrayref_copy = mono_sgen_ssb_wbarrier_arrayref_copy;
-       remset->wbarrier_value_copy = mono_sgen_ssb_wbarrier_value_copy;
-       remset->wbarrier_object_copy = mono_sgen_ssb_wbarrier_object_copy;
-       remset->wbarrier_generic_nostore = mono_sgen_ssb_wbarrier_generic_nostore;
-       remset->record_pointer = mono_sgen_ssb_record_pointer;
+       remset->wbarrier_set_field = sgen_ssb_wbarrier_set_field;
+       remset->wbarrier_set_arrayref = sgen_ssb_wbarrier_set_arrayref;
+       remset->wbarrier_arrayref_copy = sgen_ssb_wbarrier_arrayref_copy;
+       remset->wbarrier_value_copy = sgen_ssb_wbarrier_value_copy;
+       remset->wbarrier_object_copy = sgen_ssb_wbarrier_object_copy;
+       remset->wbarrier_generic_nostore = sgen_ssb_wbarrier_generic_nostore;
+       remset->record_pointer = sgen_ssb_record_pointer;
 
-       remset->begin_scan_remsets = mono_sgen_ssb_begin_scan_remsets;
-       remset->finish_scan_remsets = mono_sgen_ssb_finish_scan_remsets;
+       remset->begin_scan_remsets = sgen_ssb_begin_scan_remsets;
+       remset->finish_scan_remsets = sgen_ssb_finish_scan_remsets;
 
-       remset->register_thread = mono_sgen_ssb_register_thread;
-       remset->cleanup_thread = mono_sgen_ssb_cleanup_thread;
+       remset->register_thread = sgen_ssb_register_thread;
+       remset->cleanup_thread = sgen_ssb_cleanup_thread;
 #ifdef HAVE_KW_THREAD
-       remset->fill_thread_info_for_suspend = mono_sgen_ssb_fill_thread_info_for_suspend;
+       remset->fill_thread_info_for_suspend = sgen_ssb_fill_thread_info_for_suspend;
 #endif
 
-       remset->prepare_for_minor_collection = mono_sgen_ssb_prepare_for_minor_collection;
-       remset->prepare_for_major_collection = mono_sgen_ssb_prepare_for_major_collection;
+       remset->prepare_for_minor_collection = sgen_ssb_prepare_for_minor_collection;
+       remset->prepare_for_major_collection = sgen_ssb_prepare_for_major_collection;
 
-       remset->find_address = mono_sgen_ssb_find_address;
+       remset->find_address = sgen_ssb_find_address;
 }
 #endif
index 7187a3514276d78a285471c5580941f2aac9f795..601443dbf7d3643380b50628e6a10b6997e56155 100644 (file)
@@ -24,7 +24,7 @@
 #ifndef __MONO_SGEN_SSB_H__
 #define __MONO_SGEN_SSB_H__
 
-void mono_sgen_ssb_init (SgenRemeberedSet *remset) MONO_INTERNAL;
+void sgen_ssb_init (SgenRemeberedSet *remset) MONO_INTERNAL;
 
 #endif
 
index 0665da797a8cd0d24c663f5b1ea5ab92a337d879..0721c188bf131a9d46e00a85a54f1082c3d86042 100644 (file)
@@ -48,7 +48,7 @@ static int toogleref_array_size;
 static int toogleref_array_capacity;
 
 void
-mono_sgen_process_togglerefs (void)
+sgen_process_togglerefs (void)
 {
        int i, w;
        int toggle_ref_counts [3] = { 0 };
@@ -98,7 +98,7 @@ mono_sgen_process_togglerefs (void)
 }
 
 void
-mono_sgen_scan_togglerefs (CopyOrMarkObjectFunc copy_func, char *start, char *end, SgenGrayQueue *queue)
+sgen_scan_togglerefs (CopyOrMarkObjectFunc copy_func, char *start, char *end, SgenGrayQueue *queue)
 {
        int i;
 
@@ -115,7 +115,7 @@ mono_sgen_scan_togglerefs (CopyOrMarkObjectFunc copy_func, char *start, char *en
                        char *object = toggleref_array [i].weak_ref;
 
                        if (object >= start && object < end) {
-                               if (mono_sgen_gc_is_object_ready_for_finalization (object)) {
+                               if (sgen_gc_is_object_ready_for_finalization (object)) {
                                        DEBUG (6, fprintf (gc_debug_file, "\tcleaning weak slot %d\n", i));
                                        toggleref_array [i].weak_ref = NULL; /* We defer compaction to only happen on the callback step. */
                                } else {
@@ -132,7 +132,7 @@ ensure_toggleref_capacity (int capacity)
 {
        if (!toggleref_array) {
                toogleref_array_capacity = 32;
-               toggleref_array = mono_sgen_alloc_internal_dynamic (
+               toggleref_array = sgen_alloc_internal_dynamic (
                        toogleref_array_capacity * sizeof (MonoGCToggleRef),
                        INTERNAL_MEM_TOGGLEREF_DATA);   
        }
@@ -142,13 +142,13 @@ ensure_toggleref_capacity (int capacity)
                while (toogleref_array_capacity < toogleref_array_size + capacity)
                        toogleref_array_size *= 2;
                
-               tmp = mono_sgen_alloc_internal_dynamic (
+               tmp = sgen_alloc_internal_dynamic (
                        toogleref_array_capacity * sizeof (MonoGCToggleRef),
                        INTERNAL_MEM_TOGGLEREF_DATA);
 
                memcpy (tmp, toggleref_array, toogleref_array_size * sizeof (MonoGCToggleRef));
 
-               mono_sgen_free_internal_dynamic (toggleref_array, old_capacity * sizeof (MonoGCToggleRef), INTERNAL_MEM_TOGGLEREF_DATA);
+               sgen_free_internal_dynamic (toggleref_array, old_capacity * sizeof (MonoGCToggleRef), INTERNAL_MEM_TOGGLEREF_DATA);
                toggleref_array = tmp;
        }
 }
@@ -169,7 +169,7 @@ mono_gc_toggleref_add (MonoObject *object, mono_bool strong_ref)
 
        DEBUG (4, fprintf (gc_debug_file, "Adding toggleref %p %d\n", object, strong_ref));
 
-       mono_sgen_gc_lock ();
+       sgen_gc_lock ();
 
        ensure_toggleref_capacity (1);
        if (strong_ref)
@@ -177,7 +177,7 @@ mono_gc_toggleref_add (MonoObject *object, mono_bool strong_ref)
        else
                toggleref_array [toogleref_array_size++].weak_ref = object;
 
-       mono_sgen_gc_unlock ();
+       sgen_gc_unlock ();
 }
 
 /**
index 359c47d9d7adea92b90510adc9c4c8488f20a868..8a1d210c26e96f350ebe63543f3a5ee3d2cf6431 100644 (file)
@@ -97,17 +97,17 @@ workers_wait (void)
 }
 
 void
-mono_sgen_workers_enqueue_job (JobFunc func, void *data)
+sgen_workers_enqueue_job (JobFunc func, void *data)
 {
        int num_entries;
        JobQueueEntry *entry;
 
-       if (!mono_sgen_collection_is_parallel ()) {
+       if (!sgen_collection_is_parallel ()) {
                func (NULL, data);
                return;
        }
 
-       entry = mono_sgen_alloc_internal (INTERNAL_MEM_JOB_QUEUE_ENTRY);
+       entry = sgen_alloc_internal (INTERNAL_MEM_JOB_QUEUE_ENTRY);
        entry->func = func;
        entry->data = data;
 
@@ -125,7 +125,7 @@ workers_dequeue_and_do_job (WorkerData *data)
 {
        JobQueueEntry *entry;
 
-       g_assert (mono_sgen_collection_is_parallel ());
+       g_assert (sgen_collection_is_parallel ());
 
        if (!workers_job_queue_num_entries)
                return FALSE;
@@ -142,7 +142,7 @@ workers_dequeue_and_do_job (WorkerData *data)
                return FALSE;
 
        entry->func (data, entry->data);
-       mono_sgen_free_internal (entry, INTERNAL_MEM_JOB_QUEUE_ENTRY);
+       sgen_free_internal (entry, INTERNAL_MEM_JOB_QUEUE_ENTRY);
        return TRUE;
 }
 
@@ -167,7 +167,7 @@ workers_steal (WorkerData *data, WorkerData *victim_data, gboolean lock)
                int m = MIN (SGEN_GRAY_QUEUE_SECTION_SIZE, n);
                n -= m;
 
-               mono_sgen_gray_object_alloc_queue_section (queue);
+               sgen_gray_object_alloc_queue_section (queue);
                memcpy (queue->first->objects,
                                victim_data->stealable_stack + victim_data->stealable_stack_fill - num + n,
                                sizeof (char*) * m);
@@ -196,7 +196,7 @@ workers_get_work (WorkerData *data)
 {
        int i;
 
-       g_assert (mono_sgen_gray_object_queue_is_empty (&data->private_gray_queue));
+       g_assert (sgen_gray_object_queue_is_empty (&data->private_gray_queue));
 
        /* Try to steal from our own stack. */
        if (workers_steal (data, data, TRUE))
@@ -216,7 +216,7 @@ workers_get_work (WorkerData *data)
        }
 
        /* Nobody to steal from */
-       g_assert (mono_sgen_gray_object_queue_is_empty (&data->private_gray_queue));
+       g_assert (sgen_gray_object_queue_is_empty (&data->private_gray_queue));
        return FALSE;
 }
 
@@ -240,7 +240,7 @@ workers_gray_queue_share_redirect (SgenGrayQueue *queue)
        mono_mutex_lock (&data->stealable_stack_mutex);
 
        while (data->stealable_stack_fill < STEALABLE_STACK_SIZE &&
-                       (section = mono_sgen_gray_object_dequeue_section (queue))) {
+                       (section = sgen_gray_object_dequeue_section (queue))) {
                int num = MIN (section->end, STEALABLE_STACK_SIZE - data->stealable_stack_fill);
 
                memcpy (data->stealable_stack + data->stealable_stack_fill,
@@ -251,12 +251,12 @@ workers_gray_queue_share_redirect (SgenGrayQueue *queue)
                data->stealable_stack_fill += num;
 
                if (section->end)
-                       mono_sgen_gray_object_enqueue_section (queue, section);
+                       sgen_gray_object_enqueue_section (queue, section);
                else
-                       mono_sgen_gray_object_free_queue_section (section);
+                       sgen_gray_object_free_queue_section (section);
        }
 
-       if (data != &workers_gc_thread_data && mono_sgen_gray_object_queue_is_empty (queue))
+       if (data != &workers_gc_thread_data && sgen_gray_object_queue_is_empty (queue))
                workers_steal (data, data, FALSE);
 
        mono_mutex_unlock (&data->stealable_stack_mutex);
@@ -272,10 +272,10 @@ workers_thread_func (void *data_untyped)
 
        mono_thread_info_register_small_id ();
 
-       if (mono_sgen_get_major_collector ()->init_worker_thread)
-               mono_sgen_get_major_collector ()->init_worker_thread (data->major_collector_data);
+       if (sgen_get_major_collector ()->init_worker_thread)
+               sgen_get_major_collector ()->init_worker_thread (data->major_collector_data);
 
-       mono_sgen_gray_object_queue_init_with_alloc_prepare (&data->private_gray_queue,
+       sgen_gray_object_queue_init_with_alloc_prepare (&data->private_gray_queue,
                        workers_gray_queue_share_redirect, data);
 
        for (;;) {
@@ -286,14 +286,14 @@ workers_thread_func (void *data_untyped)
                        /* FIXME: maybe distribute the gray queue here? */
                }
 
-               if (workers_marking && (!mono_sgen_gray_object_queue_is_empty (&data->private_gray_queue) || workers_get_work (data))) {
-                       g_assert (!mono_sgen_gray_object_queue_is_empty (&data->private_gray_queue));
+               if (workers_marking && (!sgen_gray_object_queue_is_empty (&data->private_gray_queue) || workers_get_work (data))) {
+                       g_assert (!sgen_gray_object_queue_is_empty (&data->private_gray_queue));
 
-                       while (!mono_sgen_drain_gray_stack (&data->private_gray_queue, 32))
+                       while (!sgen_drain_gray_stack (&data->private_gray_queue, 32))
                                workers_gray_queue_share_redirect (&data->private_gray_queue);
-                       g_assert (mono_sgen_gray_object_queue_is_empty (&data->private_gray_queue));
+                       g_assert (sgen_gray_object_queue_is_empty (&data->private_gray_queue));
 
-                       mono_sgen_gray_object_queue_init (&data->private_gray_queue);
+                       sgen_gray_object_queue_init (&data->private_gray_queue);
 
                        did_work = TRUE;
                }
@@ -307,61 +307,61 @@ workers_thread_func (void *data_untyped)
 }
 
 void
-mono_sgen_workers_distribute_gray_queue_sections (void)
+sgen_workers_distribute_gray_queue_sections (void)
 {
-       if (!mono_sgen_collection_is_parallel ())
+       if (!sgen_collection_is_parallel ())
                return;
 
        workers_gray_queue_share_redirect (&workers_distribute_gray_queue);
 }
 
 void
-mono_sgen_workers_init_distribute_gray_queue (void)
+sgen_workers_init_distribute_gray_queue (void)
 {
-       if (!mono_sgen_collection_is_parallel ())
+       if (!sgen_collection_is_parallel ())
                return;
 
-       mono_sgen_gray_object_queue_init (&workers_distribute_gray_queue);
+       sgen_gray_object_queue_init (&workers_distribute_gray_queue);
 }
 
 void
-mono_sgen_workers_init (int num_workers)
+sgen_workers_init (int num_workers)
 {
        int i;
 
-       if (!mono_sgen_get_major_collector ()->is_parallel)
+       if (!sgen_get_major_collector ()->is_parallel)
                return;
 
        //g_print ("initing %d workers\n", num_workers);
 
        workers_num = num_workers;
 
-       workers_data = mono_sgen_alloc_internal_dynamic (sizeof (WorkerData) * num_workers, INTERNAL_MEM_WORKER_DATA);
+       workers_data = sgen_alloc_internal_dynamic (sizeof (WorkerData) * num_workers, INTERNAL_MEM_WORKER_DATA);
        memset (workers_data, 0, sizeof (WorkerData) * num_workers);
 
        MONO_SEM_INIT (&workers_waiting_sem, 0);
        MONO_SEM_INIT (&workers_done_sem, 0);
 
-       mono_sgen_gray_object_queue_init_with_alloc_prepare (&workers_distribute_gray_queue,
+       sgen_gray_object_queue_init_with_alloc_prepare (&workers_distribute_gray_queue,
                        workers_gray_queue_share_redirect, &workers_gc_thread_data);
        mono_mutex_init (&workers_gc_thread_data.stealable_stack_mutex, NULL);
        workers_gc_thread_data.stealable_stack_fill = 0;
 
-       if (mono_sgen_get_major_collector ()->alloc_worker_data)
-               workers_gc_thread_data.major_collector_data = mono_sgen_get_major_collector ()->alloc_worker_data ();
+       if (sgen_get_major_collector ()->alloc_worker_data)
+               workers_gc_thread_data.major_collector_data = sgen_get_major_collector ()->alloc_worker_data ();
 
        for (i = 0; i < workers_num; ++i) {
                /* private gray queue is inited by the thread itself */
                mono_mutex_init (&workers_data [i].stealable_stack_mutex, NULL);
                workers_data [i].stealable_stack_fill = 0;
 
-               if (mono_sgen_get_major_collector ()->alloc_worker_data)
-                       workers_data [i].major_collector_data = mono_sgen_get_major_collector ()->alloc_worker_data ();
+               if (sgen_get_major_collector ()->alloc_worker_data)
+                       workers_data [i].major_collector_data = sgen_get_major_collector ()->alloc_worker_data ();
        }
 
        LOCK_INIT (workers_job_queue_mutex);
 
-       mono_sgen_register_fixed_internal_mem_type (INTERNAL_MEM_JOB_QUEUE_ENTRY, sizeof (JobQueueEntry));
+       sgen_register_fixed_internal_mem_type (INTERNAL_MEM_JOB_QUEUE_ENTRY, sizeof (JobQueueEntry));
 
        mono_counters_register ("Stolen from self lock", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_workers_stolen_from_self_lock);
        mono_counters_register ("Stolen from self no lock", MONO_COUNTER_GC | MONO_COUNTER_LONG, &stat_workers_stolen_from_self_no_lock);
@@ -381,15 +381,15 @@ workers_start_worker (int index)
 }
 
 void
-mono_sgen_workers_start_all_workers (void)
+sgen_workers_start_all_workers (void)
 {
        int i;
 
-       if (!mono_sgen_collection_is_parallel ())
+       if (!sgen_collection_is_parallel ())
                return;
 
-       if (mono_sgen_get_major_collector ()->init_worker_thread)
-               mono_sgen_get_major_collector ()->init_worker_thread (workers_gc_thread_data.major_collector_data);
+       if (sgen_get_major_collector ()->init_worker_thread)
+               sgen_get_major_collector ()->init_worker_thread (workers_gc_thread_data.major_collector_data);
 
        g_assert (!workers_gc_in_progress);
        workers_gc_in_progress = TRUE;
@@ -409,9 +409,9 @@ mono_sgen_workers_start_all_workers (void)
 }
 
 void
-mono_sgen_workers_start_marking (void)
+sgen_workers_start_marking (void)
 {
-       if (!mono_sgen_collection_is_parallel ())
+       if (!sgen_collection_is_parallel ())
                return;
 
        g_assert (workers_started && workers_gc_in_progress);
@@ -423,15 +423,15 @@ mono_sgen_workers_start_marking (void)
 }
 
 void
-mono_sgen_workers_join (void)
+sgen_workers_join (void)
 {
        int i;
 
-       if (!mono_sgen_collection_is_parallel ())
+       if (!sgen_collection_is_parallel ())
                return;
 
-       g_assert (mono_sgen_gray_object_queue_is_empty (&workers_gc_thread_data.private_gray_queue));
-       g_assert (mono_sgen_gray_object_queue_is_empty (&workers_distribute_gray_queue));
+       g_assert (sgen_gray_object_queue_is_empty (&workers_gc_thread_data.private_gray_queue));
+       g_assert (sgen_gray_object_queue_is_empty (&workers_distribute_gray_queue));
 
        g_assert (workers_gc_in_progress);
        workers_gc_in_progress = FALSE;
@@ -449,27 +449,27 @@ mono_sgen_workers_join (void)
        MONO_SEM_WAIT (&workers_done_sem);
        workers_marking = FALSE;
 
-       if (mono_sgen_get_major_collector ()->reset_worker_data) {
+       if (sgen_get_major_collector ()->reset_worker_data) {
                for (i = 0; i < workers_num; ++i)
-                       mono_sgen_get_major_collector ()->reset_worker_data (workers_data [i].major_collector_data);
+                       sgen_get_major_collector ()->reset_worker_data (workers_data [i].major_collector_data);
        }
 
        g_assert (workers_done_posted);
 
        g_assert (!workers_gc_thread_data.stealable_stack_fill);
-       g_assert (mono_sgen_gray_object_queue_is_empty (&workers_gc_thread_data.private_gray_queue));
+       g_assert (sgen_gray_object_queue_is_empty (&workers_gc_thread_data.private_gray_queue));
        for (i = 0; i < workers_num; ++i) {
                g_assert (!workers_data [i].stealable_stack_fill);
-               g_assert (mono_sgen_gray_object_queue_is_empty (&workers_data [i].private_gray_queue));
+               g_assert (sgen_gray_object_queue_is_empty (&workers_data [i].private_gray_queue));
        }
 }
 
 gboolean
-mono_sgen_is_worker_thread (MonoNativeThreadId thread)
+sgen_is_worker_thread (MonoNativeThreadId thread)
 {
        int i;
 
-       if (mono_sgen_get_major_collector ()->is_worker_thread && mono_sgen_get_major_collector ()->is_worker_thread (thread))
+       if (sgen_get_major_collector ()->is_worker_thread && sgen_get_major_collector ()->is_worker_thread (thread))
                return TRUE;
 
        for (i = 0; i < workers_num; ++i) {
@@ -480,22 +480,22 @@ mono_sgen_is_worker_thread (MonoNativeThreadId thread)
 }
 
 gboolean
-mono_sgen_workers_is_distributed_queue (SgenGrayQueue *queue)
+sgen_workers_is_distributed_queue (SgenGrayQueue *queue)
 {
        return queue == &workers_distribute_gray_queue;
 }
 
 SgenGrayQueue*
-mono_sgen_workers_get_distribute_gray_queue (void)
+sgen_workers_get_distribute_gray_queue (void)
 {
        return &workers_distribute_gray_queue;
 }
 
 void
-mono_sgen_workers_reset_data (void)
+sgen_workers_reset_data (void)
 {
-       if (mono_sgen_get_major_collector ()->reset_worker_data)
-               mono_sgen_get_major_collector ()->reset_worker_data (workers_gc_thread_data.major_collector_data);
+       if (sgen_get_major_collector ()->reset_worker_data)
+               sgen_get_major_collector ()->reset_worker_data (workers_gc_thread_data.major_collector_data);
 
 }
 #endif
index afe052c7436e56d2e817cd8ccb38c1fd2d391ec4..78416eab29f80ccb5dba5f3ed258fe70cad6c219 100644 (file)
@@ -48,15 +48,15 @@ struct _JobQueueEntry {
        volatile JobQueueEntry *next;
 };
 
-void mono_sgen_workers_init (int num_workers) MONO_INTERNAL;
-void mono_sgen_workers_start_all_workers (void) MONO_INTERNAL;
-void mono_sgen_workers_init_distribute_gray_queue (void) MONO_INTERNAL;
-void mono_sgen_workers_enqueue_job (JobFunc func, void *data) MONO_INTERNAL;
-void mono_sgen_workers_start_marking (void) MONO_INTERNAL;
-void mono_sgen_workers_distribute_gray_queue_sections (void) MONO_INTERNAL;
-void mono_sgen_workers_reset_data (void) MONO_INTERNAL;
-void mono_sgen_workers_join (void) MONO_INTERNAL;
-gboolean mono_sgen_workers_is_distributed_queue (SgenGrayQueue *queue) MONO_INTERNAL;
-SgenGrayQueue* mono_sgen_workers_get_distribute_gray_queue (void) MONO_INTERNAL;
+void sgen_workers_init (int num_workers) MONO_INTERNAL;
+void sgen_workers_start_all_workers (void) MONO_INTERNAL;
+void sgen_workers_init_distribute_gray_queue (void) MONO_INTERNAL;
+void sgen_workers_enqueue_job (JobFunc func, void *data) MONO_INTERNAL;
+void sgen_workers_start_marking (void) MONO_INTERNAL;
+void sgen_workers_distribute_gray_queue_sections (void) MONO_INTERNAL;
+void sgen_workers_reset_data (void) MONO_INTERNAL;
+void sgen_workers_join (void) MONO_INTERNAL;
+gboolean sgen_workers_is_distributed_queue (SgenGrayQueue *queue) MONO_INTERNAL;
+SgenGrayQueue* sgen_workers_get_distribute_gray_queue (void) MONO_INTERNAL;
 
 #endif
index 10e9330b6fbac9578f11f77adeb1c5a34071e98f..9d73ccdeb305ec3d353259fd537bf1e2f451ec7c 100644 (file)
@@ -3,5 +3,6 @@
 
 void mono_thread_pool_remove_socket (int sock) MONO_INTERNAL;
 gboolean mono_thread_pool_is_queue_array (MonoArray *o) MONO_INTERNAL;
+void mono_internal_thread_unhandled_exception (MonoObject* exc) MONO_INTERNAL;
 
 #endif
index db6243b2133d2ca20b41d809a4321f74b78b74f2..089df523fa97d9ee2ba9d3d279bb989eec10fcb5 100644 (file)
@@ -1374,7 +1374,7 @@ async_invoke_thread (gpointer data)
 
        mono_profiler_thread_start (thread->tid);
        name = (tp->is_io) ? "IO Threadpool worker" : "Threadpool worker";
-       ves_icall_System_Threading_Thread_SetName_internal (thread, mono_string_new (mono_domain_get (), name));
+       mono_thread_set_name_internal (thread, mono_string_new (mono_domain_get (), name), FALSE);
 
        if (tp_start_func)
                tp_start_func (tp_hooks_user_data);
@@ -1440,20 +1440,8 @@ async_invoke_thread (gpointer data)
                                        exc = mono_async_invoke (tp, ar);
                                        if (tp_item_end_func)
                                                tp_item_end_func (tp_item_user_data);
-                                       if (exc && mono_runtime_unhandled_exception_policy_get () == MONO_UNHANDLED_POLICY_CURRENT) {
-                                               gboolean unloaded;
-                                               MonoClass *klass;
-
-                                               klass = exc->vtable->klass;
-                                               unloaded = is_appdomainunloaded_exception (exc->vtable->domain, klass);
-                                               if (!unloaded && klass != mono_defaults.threadabortexception_class) {
-                                                       mono_unhandled_exception (exc);
-                                                       if (mono_environment_exitcode_get () == 1)
-                                                               exit (255);
-                                               }
-                                               if (klass == mono_defaults.threadabortexception_class)
-                                                       mono_thread_internal_reset_abort (thread);
-                                       }
+                                       if (exc)
+                                               mono_internal_thread_unhandled_exception (exc);
                                        if (is_socket && tp->is_io) {
                                                MonoSocketAsyncResult *state = (MonoSocketAsyncResult *) data;
 
@@ -1485,9 +1473,18 @@ async_invoke_thread (gpointer data)
                while (!must_die && !data && n_naps < 4) {
                        gboolean res;
 
+                       InterlockedIncrement (&tp->waiting);
+
+                       // Another thread may have added a job into its wsq since the last call to dequeue_or_steal
+                       // Check all the queues again before entering the wait loop
+                       dequeue_or_steal (tp, &data, wsq);
+                       if (data) {
+                               InterlockedDecrement (&tp->waiting);
+                               break;
+                       }
+
                        mono_gc_set_skip_thread (TRUE);
 
-                       InterlockedIncrement (&tp->waiting);
 #if defined(__OpenBSD__)
                        while (mono_cq_count (tp->queue) == 0 && (res = mono_sem_wait (&tp->new_job, TRUE)) == -1) {// && errno == EINTR) {
 #else
@@ -1645,3 +1642,21 @@ mono_install_threadpool_item_hooks (MonoThreadPoolItemFunc begin_func, MonoThrea
        tp_item_user_data = user_data;
 }
 
+void
+mono_internal_thread_unhandled_exception (MonoObject* exc)
+{
+       if (mono_runtime_unhandled_exception_policy_get () == MONO_UNHANDLED_POLICY_CURRENT) {
+               gboolean unloaded;
+               MonoClass *klass;
+
+               klass = exc->vtable->klass;
+               unloaded = is_appdomainunloaded_exception (exc->vtable->domain, klass);
+               if (!unloaded && klass != mono_defaults.threadabortexception_class) {
+                       mono_unhandled_exception (exc);
+                       if (mono_environment_exitcode_get () == 1)
+                               exit (255);
+               }
+               if (klass == mono_defaults.threadabortexception_class)
+                mono_thread_internal_reset_abort (mono_thread_internal_current ());
+       }
+}
index 7f945bc017a7721ebb2ea3b6170194b9f8dea8ff..26ab1f4df16c9f5594ec25cb71b7b2947425d8e4 100644 (file)
@@ -189,6 +189,8 @@ MonoException* mono_thread_get_undeniable_exception (void);
 
 MonoException* mono_thread_get_and_clear_pending_exception (void) MONO_INTERNAL;
 
+void mono_thread_set_name_internal (MonoInternalThread *this_obj, MonoString *name, gboolean managed) MONO_INTERNAL;
+
 void mono_threads_install_notify_pending_exc (MonoThreadNotifyPendingExcFunc func) MONO_INTERNAL;
 
 MonoObject* mono_thread_get_execution_context (void) MONO_INTERNAL;
index 9ee0bb46bb7949c1e52c440c39ac81cecda1e59b..ab0c84651e2e85f4950298e111367643e4f0c75c 100644 (file)
@@ -918,6 +918,8 @@ mono_thread_detach (MonoThread *thread)
 
        THREAD_DEBUG (g_message ("%s: mono_thread_detach for %p (%"G_GSIZE_FORMAT")", __func__, thread, (gsize)thread->internal_thread->tid));
        
+       mono_profiler_thread_end (thread->internal_thread->tid);
+
        thread_cleanup (thread->internal_thread);
 
        SET_CURRENT_OBJECT (NULL);
@@ -1206,13 +1208,13 @@ ves_icall_System_Threading_Thread_GetName_internal (MonoInternalThread *this_obj
 }
 
 void 
-ves_icall_System_Threading_Thread_SetName_internal (MonoInternalThread *this_obj, MonoString *name)
+mono_thread_set_name_internal (MonoInternalThread *this_obj, MonoString *name, gboolean managed)
 {
        ensure_synch_cs_set (this_obj);
        
        EnterCriticalSection (this_obj->synch_cs);
-       
-       if (this_obj->name) {
+
+       if (this_obj->flags & MONO_THREAD_FLAG_NAME_SET) {
                LeaveCriticalSection (this_obj->synch_cs);
                
                mono_raise_exception (mono_get_exception_invalid_operation ("Thread.Name can only be set once."));
@@ -1225,6 +1227,9 @@ ves_icall_System_Threading_Thread_SetName_internal (MonoInternalThread *this_obj
        }
        else
                this_obj->name = NULL;
+
+       if (managed)
+               this_obj->flags |= MONO_THREAD_FLAG_NAME_SET;
        
        LeaveCriticalSection (this_obj->synch_cs);
        if (this_obj->name) {
@@ -1234,6 +1239,12 @@ ves_icall_System_Threading_Thread_SetName_internal (MonoInternalThread *this_obj
        }
 }
 
+void 
+ves_icall_System_Threading_Thread_SetName_internal (MonoInternalThread *this_obj, MonoString *name)
+{
+       mono_thread_set_name_internal (this_obj, name, TRUE);
+}
+
 /* If the array is already in the requested domain, we just return it,
    otherwise we return a copy in that domain. */
 static MonoArray*
index e4b48e7b26f1806df68d01a79c3e92a3a8070673..a88f66b949930ba4ffe663692c85dcbe72704862 100644 (file)
@@ -4575,6 +4575,13 @@ merge_stacks (VerifyContext *ctx, ILCodeDesc *from, ILCodeDesc *to, gboolean sta
                                mono_error_cleanup (&error);
                                goto end_verify;
                        }
+                       mono_class_setup_interfaces (new_class, &error);
+                       if (!mono_error_ok (&error)) {
+                               CODE_NOT_VERIFIABLE (ctx, g_strdup_printf ("Cannot merge stacks due to a TypeLoadException %s at 0x%04x", mono_error_get_message (&error), ctx->ip_offset));
+                               mono_error_cleanup (&error);
+                               goto end_verify;
+                       }
+
                        for (j = 0; j < old_class->interface_count; ++j) {
                                for (k = 0; k < new_class->interface_count; ++k) {
                                        if (mono_metadata_type_equal (&old_class->interfaces [j]->byval_arg, &new_class->interfaces [k]->byval_arg)) {
@@ -4584,6 +4591,33 @@ merge_stacks (VerifyContext *ctx, ILCodeDesc *from, ILCodeDesc *to, gboolean sta
                                }
                        }
 
+                       /* if old class is an interface that new class implements */
+                       if (old_class->flags & TYPE_ATTRIBUTE_INTERFACE) {
+                               if (verifier_class_is_assignable_from (old_class, new_class)) {
+                                       match_class = old_class;
+                                       goto match_found;       
+                               }
+                               for (j = 0; j < old_class->interface_count; ++j) {
+                                       if (verifier_class_is_assignable_from (old_class->interfaces [j], new_class)) {
+                                               match_class = old_class->interfaces [j];
+                                               goto match_found;       
+                                       }
+                               }
+                       }
+
+                       if (new_class->flags & TYPE_ATTRIBUTE_INTERFACE) {
+                               if (verifier_class_is_assignable_from (new_class, old_class)) {
+                                       match_class = new_class;
+                                       goto match_found;       
+                               }
+                               for (j = 0; j < new_class->interface_count; ++j) {
+                                       if (verifier_class_is_assignable_from (new_class->interfaces [j], old_class)) {
+                                               match_class = new_class->interfaces [j];
+                                               goto match_found;       
+                                       }
+                               }
+                       }
+
                        //No decent super type found, use object
                        match_class = mono_defaults.object_class;
                        goto match_found;
index cbc9bbb905a4f785f546cb2ddc39d816283cc493..eee3604facaca452b4855348613a1d4dff035221 100644 (file)
@@ -101,11 +101,14 @@ boehm_static_libraries = libmono-static.la
 boehm_binaries  = mono
 endif
 
+if DISABLE_EXECUTABLES
+else
 if HOST_WIN32
 bin_PROGRAMS = $(boehm_binaries) $(sgen_binaries) monow
 else
 bin_PROGRAMS = $(boehm_binaries) $(sgen_binaries)
 endif
+endif
 
 noinst_PROGRAMS = genmdesc
 
@@ -114,7 +117,12 @@ shared_libraries = $(boehm_libraries) $(sgen_libraries)
 endif
 
 lib_LTLIBRARIES = $(shared_libraries)
+
+if DISABLE_EXECUTABLES
+noinst_LTLIBRARIES =
+else
 noinst_LTLIBRARIES = $(boehm_static_libraries) $(sgen_static_libraries)
+endif
 
 if MOONLIGHT
 noinst_LTLIBRARIES += libmono-moon.la
@@ -129,7 +137,7 @@ lib_LTLIBRARIES += libmono-llvm.la
 libmono_llvm_la_SOURCES = mini-llvm.c mini-llvm-cpp.cpp
 libmono_llvm_la_LIBADD = $(LLVM_LIBS) $(LLVM_LDFLAGS)
 if PLATFORM_DARWIN
-libmono_llvm_la_LDFLAGS=-undefined suppress
+libmono_llvm_la_LDFLAGS=-Wl,-undefined -Wl,suppress -Wl,-flat_namespace
 else
 libmono_llvm_la_LIBADD += $(top_builddir)/mono/mini/libmono-$(API_VER).la $(libs)
 endif
index 7116794a8d47415eff86487009c02bb169f02109..9ef854d52ec7eef2286f4e0724075bfd90ac5168 100644 (file)
@@ -2259,6 +2259,8 @@ encode_method_ref (MonoAotCompile *acfg, MonoMethod *method, guint8 *buf, guint8
                        if (info->subtype == WRAPPER_SUBTYPE_ICALL_WRAPPER) {
                                strcpy ((char*)p, method->name);
                                p += strlen (method->name) + 1;
+                       } else if (info->subtype == WRAPPER_SUBTYPE_NATIVE_FUNC_AOT) {
+                               encode_method_ref (acfg, info->d.managed_to_native.method, p, &p);
                        } else {
                                g_assert (info->subtype == WRAPPER_SUBTYPE_NONE);
                                encode_method_ref (acfg, info->d.managed_to_native.method, p, &p);
@@ -2963,6 +2965,7 @@ add_wrappers (MonoAotCompile *acfg)
        /* delegate-invoke wrappers */
        for (i = 0; i < acfg->image->tables [MONO_TABLE_TYPEDEF].rows; ++i) {
                MonoClass *klass;
+               MonoCustomAttrInfo *cattr;
                
                token = MONO_TOKEN_TYPE_DEF | (i + 1);
                klass = mono_class_get (acfg->image, token);
@@ -2986,6 +2989,18 @@ add_wrappers (MonoAotCompile *acfg)
                        method = mono_class_get_method_from_name_flags (klass, "EndInvoke", -1, 0);
                        if (method)
                                add_method (acfg, mono_marshal_get_delegate_end_invoke (method));
+
+                       cattr = mono_custom_attrs_from_class (klass);
+
+                       if (cattr) {
+                               int j;
+
+                               for (j = 0; j < cattr->num_attrs; ++j)
+                                       if (cattr->attrs [j].ctor && !strcmp (cattr->attrs [j].ctor->klass->name, "MonoNativeFunctionWrapperAttribute"))
+                                               break;
+                               if (j < cattr->num_attrs)
+                                       add_method (acfg, mono_marshal_get_native_func_wrapper_aot (klass));
+                       }
                }
        }
 
index 21a67ba800e1a2494b7070909fae887d0a88a0f7..707deccb52be3c66c615beb2388dc95d083ed655 100644 (file)
@@ -804,7 +804,8 @@ decode_method_ref_with_target (MonoAotModule *module, MethodRef *ref, MonoMethod
                                kind = decode_value (p, &p);
 
                                /* Can't decode this */
-                               g_assert (target);
+                               if (!target)
+                                       return FALSE;
                                if (target->wrapper_type == MONO_WRAPPER_STELEMREF) {
                                        info = mono_marshal_get_wrapper_info (target);
 
@@ -840,7 +841,8 @@ decode_method_ref_with_target (MonoAotModule *module, MethodRef *ref, MonoMethod
                                if (!klass)
                                        return FALSE;
 
-                               g_assert (target);
+                               if (!target)
+                                       return FALSE;
                                if (klass != target->klass)
                                        return FALSE;
 
@@ -891,7 +893,8 @@ decode_method_ref_with_target (MonoAotModule *module, MethodRef *ref, MonoMethod
                                if (!m)
                                        return FALSE;
 
-                               g_assert (target);
+                               if (!target)
+                                       return FALSE;
                                g_assert (target->wrapper_type == MONO_WRAPPER_MANAGED_TO_MANAGED);
 
                                info = mono_marshal_get_wrapper_info (target);
@@ -908,7 +911,8 @@ decode_method_ref_with_target (MonoAotModule *module, MethodRef *ref, MonoMethod
                        char *name;
 
                        if (subtype == WRAPPER_SUBTYPE_ICALL_WRAPPER) {
-                               g_assert (target);
+                               if (!target)
+                                       return FALSE;
 
                                name = (char*)p;
                                if (strcmp (target->name, name) != 0)
@@ -921,7 +925,8 @@ decode_method_ref_with_target (MonoAotModule *module, MethodRef *ref, MonoMethod
                                        return FALSE;
 
                                /* This should only happen when looking for an extra method */
-                               g_assert (target);
+                               if (!target)
+                                       return FALSE;
                                if (mono_marshal_method_from_wrapper (target) == m)
                                        ref->method = target;
                                else
@@ -943,7 +948,8 @@ decode_method_ref_with_target (MonoAotModule *module, MethodRef *ref, MonoMethod
                case MONO_WRAPPER_RUNTIME_INVOKE: {
                        int subtype = decode_value (p, &p);
 
-                       g_assert (target);
+                       if (!target)
+                               return FALSE;
 
                        if (subtype == WRAPPER_SUBTYPE_RUNTIME_INVOKE_DYNAMIC) {
                                if (strcmp (target->name, "runtime_invoke_dynamic") != 0)
@@ -978,7 +984,8 @@ decode_method_ref_with_target (MonoAotModule *module, MethodRef *ref, MonoMethod
                         * These wrappers are associated with a signature, not with a method.
                         * Since we can't decode them into methods, they need a target method.
                         */
-                       g_assert (target);
+                       if (!target)
+                               return FALSE;
 
                        if (sig_matches_target (module, target, p, &p))
                                ref->method = target;
@@ -1939,7 +1946,7 @@ decode_llvm_mono_eh_frame (MonoAotModule *amodule, MonoDomain *domain,
        guint8 *fde, *cie, *code_start, *code_end;
        int version, fde_count;
        gint32 *table;
-       int i, j, pos, left, right, offset, offset1, offset2, code_len;
+       int i, j, pos, left, right, offset, offset1, offset2, code_len, func_encoding;
        MonoJitExceptionInfo *ei;
        guint32 fde_len, ei_len, nested_len, nindex;
        gpointer *type_info;
@@ -1954,8 +1961,14 @@ decode_llvm_mono_eh_frame (MonoAotModule *amodule, MonoDomain *domain,
 
        /* Header */
        version = *p;
-       g_assert (version == 1);
+       g_assert (version == 1 || version == 2);
        p ++;
+       if (version == 2) {
+               func_encoding = *p;
+               p ++;
+       } else {
+               func_encoding = DW_EH_PE_pcrel;
+       }
        p = ALIGN_PTR_TO (p, 4);
 
        fde_count = *(guint32*)p;
@@ -1974,11 +1987,23 @@ decode_llvm_mono_eh_frame (MonoAotModule *amodule, MonoDomain *domain,
                pos = (left + right) / 2;
 
                offset1 = table [(pos * 2)];
-               if (pos + 1 == fde_count)
+               if (pos + 1 == fde_count) {
                        /* FIXME: */
                        offset2 = amodule->code_end - amodule->code;
-               else
+               } else {
+                       /* Encoded as DW_EH_PE_pcrel, but relative to mono_eh_frame */
                        offset2 = table [(pos + 1) * 2];
+               }
+
+               if (func_encoding == DW_EH_PE_absptr) {
+                       /*
+                        * Encoded as DW_EH_PE_absptr, because the ios linker can move functions inside object files to make thumb work,
+                        * so the offsets between two symbols in the text segment are not assembler constant.
+                        */
+                       g_assert (sizeof(gpointer) == 4);
+                       offset1 -= (gint32)(gsize)amodule->mono_eh_frame;
+                       offset2 -= (gint32)(gsize)amodule->mono_eh_frame;
+               }
 
                if (offset < offset1)
                        right = pos;
@@ -1988,13 +2013,22 @@ decode_llvm_mono_eh_frame (MonoAotModule *amodule, MonoDomain *domain,
                        break;
        }
 
-       code_start = amodule->mono_eh_frame + table [(pos * 2)];
-       /* This won't overflow because there is +1 entry in the table */
-       code_end = amodule->mono_eh_frame + table [(pos * 2) + 2];
+       if (func_encoding == DW_EH_PE_absptr) {
+               code_start = (gpointer)(gsize)table [(pos * 2)];
+               code_end = (gpointer)(gsize)table [(pos * 2) + 2];
+       } else {
+               code_start = amodule->mono_eh_frame + table [(pos * 2)];
+               /* This won't overflow because there is +1 entry in the table */
+               code_end = amodule->mono_eh_frame + table [(pos * 2) + 2];
+       }
        code_len = code_end - code_start;
 
        g_assert (code >= code_start && code < code_end);
 
+       if (amodule->thumb_end && (guint8*)code_start < amodule->thumb_end)
+               /* Clear thumb flag */
+               code_start = (guint8*)(((mgreg_t)code_start) & ~1);
+
        fde = amodule->mono_eh_frame + table [(pos * 2) + 1];   
        /* This won't overflow because there is +1 entry in the table */
        fde_len = table [(pos * 2) + 2 + 1] - table [(pos * 2) + 1];
@@ -2484,6 +2518,9 @@ mono_aot_find_jit_info (MonoDomain *domain, MonoImage *image, gpointer addr)
        code_offsets = amodule->sorted_code_offsets;
        offsets_len = amodule->sorted_code_offsets_len;
 
+       if (offsets_len > 0 && (offset < code_offsets [0] || offset >= (amodule->code_end - amodule->code)))
+               return NULL;
+
        /* Binary search in the sorted_code_offsets table */
        left = 0;
        right = offsets_len;
@@ -2556,9 +2593,14 @@ mono_aot_find_jit_info (MonoDomain *domain, MonoImage *image, gpointer addr)
 
                        p = amodule->blob + table [(pos * 2) + 1];
                        is_wrapper = decode_value (p, &p);
+                       if (is_wrapper)
+                               /* Happens when a random address is passed in which matches a not-yey called wrapper encoded using its name */
+                               return NULL;
                        g_assert (!is_wrapper);
                        method = decode_resolve_method_ref (amodule, p, &p);
-                       g_assert (method);
+                       if (!method)
+                               /* Ditto */
+                               return NULL;
                } else {
                        token = mono_metadata_make_token (MONO_TABLE_METHOD, method_index + 1);
                        method = mono_get_method (image, token, NULL);
index b24a426545a0edd24e4cab2a67a8d6bc449bd291..5073f284dbba6372124b5223d80f0338431cb3db 100644 (file)
@@ -178,6 +178,7 @@ s390_move: len:48 dest:b src1:b
 s390_setf4ret: dest:f src1:f len:4
 sbb: dest:i src1:i src2:i len:6
 sbb_imm: dest:i src1:i len:14
+seq_point: len:36
 sext_i4: dest:i src1:i len:4
 zext_i4: dest:i src1:i len:4
 shl_imm: dest:i src1:i len:10
index 6d022b138455c6cd727c43be084376de47730947..b207335b23e2d84f916ef5785bddffb72daf3928 100644 (file)
@@ -128,8 +128,14 @@ typedef struct
         * method.
         */
        MonoMethod *actual_method;
+       /*
+        * This is the method which is visible to debugger clients. Same as method,
+        * except for native-to-managed wrappers.
+        */
+       MonoMethod *api_method;
        MonoContext ctx;
        MonoDebugMethodJitInfo *jit;
+       MonoJitInfo *ji;
        int flags;
        mgreg_t *reg_locations [MONO_MAX_IREGS];
        /*
@@ -270,7 +276,7 @@ typedef struct {
 #define HEADER_LENGTH 11
 
 #define MAJOR_VERSION 2
-#define MINOR_VERSION 17
+#define MINOR_VERSION 18
 
 typedef enum {
        CMD_SET_VM = 1,
@@ -739,6 +745,8 @@ static void finish_agent_init (gboolean on_startup);
 
 static void process_profiler_event (EventKind event, gpointer arg);
 
+static void invalidate_frames (DebuggerTlsData *tls);
+
 #ifndef DISABLE_SOCKET_TRANSPORT
 static void
 register_socket_transport (void);
@@ -1185,7 +1193,7 @@ socket_transport_connect (const char *address)
 
                        addrlen = sizeof (addr);
                        memset (&addr, 0, sizeof (addr));
-                       res = getsockname (sfd, &addr, &addrlen);
+                       res = getsockname (sfd, (struct sockaddr*)&addr, &addrlen);
                        g_assert (res == 0);
 
                        host = (char*)"127.0.0.1";
@@ -2290,7 +2298,6 @@ get_last_frame (StackFrameInfo *info, MonoContext *ctx, gpointer user_data)
                /* Store the context/lmf for the frame above the last frame */
                memcpy (&data->ctx, ctx, sizeof (MonoContext));
                data->lmf = info->lmf;
-
                return TRUE;
        }
 }
@@ -2342,7 +2349,7 @@ thread_interrupt (DebuggerTlsData *tls, MonoThreadInfo *info, void *sigctx, Mono
        if (info)
                tid = mono_thread_info_get_tid (info);
        else
-               tid = GetCurrentThreadId ();
+               tid = (MonoNativeThreadId)GetCurrentThreadId ();
 
        // FIXME: Races when the thread leaves managed code before hitting a single step
        // event.
@@ -2451,15 +2458,23 @@ static void CALLBACK notify_thread_apc (ULONG_PTR param)
 /*
  * reset_native_thread_suspend_state:
  * 
- *   Reset the suspended flag on native threads
+ *   Reset the suspended flag and state on native threads
  */
 static void
 reset_native_thread_suspend_state (gpointer key, gpointer value, gpointer user_data)
 {
        DebuggerTlsData *tls = value;
 
-       if (!tls->really_suspended && tls->suspended)
+       if (!tls->really_suspended && tls->suspended) {
                tls->suspended = FALSE;
+               /*
+                * The thread might still be running if it was executing native code, so the state won't be invalided by
+                * suspend_current ().
+                */
+               tls->context.valid = FALSE;
+               tls->async_state.valid = FALSE;
+               invalidate_frames (tls);
+       }
 }
 
 /*
@@ -2768,7 +2783,7 @@ suspend_current (void)
        /* The frame info becomes invalid after a resume */
        tls->context.valid = FALSE;
        tls->async_state.valid = FALSE;
-       invalidate_frames (NULL);
+       invalidate_frames (tls);
 }
 
 static void
@@ -2948,7 +2963,7 @@ process_frame (StackFrameInfo *info, MonoContext *ctx, gpointer user_data)
 {
        ComputeFramesUserData *ud = user_data;
        StackFrame *frame;
-       MonoMethod *method, *actual_method;
+       MonoMethod *method, *actual_method, *api_method;
        SeqPoint *sp;
        int flags = 0;
 
@@ -2966,6 +2981,7 @@ process_frame (StackFrameInfo *info, MonoContext *ctx, gpointer user_data)
        else
                method = info->method;
        actual_method = info->actual_method;
+       api_method = method;
 
        if (!method)
                return FALSE;
@@ -2990,19 +3006,21 @@ process_frame (StackFrameInfo *info, MonoContext *ctx, gpointer user_data)
                if (!CHECK_PROTOCOL_VERSION (2, 17))
                        /* Older clients can't handle this flag */
                        return FALSE;
-               method = mono_marshal_method_from_wrapper (method);
-               if (!method)
+               api_method = mono_marshal_method_from_wrapper (method);
+               if (!api_method)
                        return FALSE;
-               actual_method = method;
+               actual_method = api_method;
                flags |= FRAME_FLAG_NATIVE_TRANSITION;
        }
 
        frame = g_new0 (StackFrame, 1);
        frame->method = method;
        frame->actual_method = actual_method;
+       frame->api_method = api_method;
        frame->il_offset = info->il_offset;
        frame->native_offset = info->native_offset;
        frame->flags = flags;
+       frame->ji = info->ji;
        if (info->reg_locations)
                memcpy (frame->reg_locations, info->reg_locations, MONO_MAX_IREGS * sizeof (mgreg_t*));
        if (ctx) {
@@ -3623,13 +3641,15 @@ thread_end (MonoProfiler *prof, uintptr_t tid)
        mono_loader_lock ();
        thread = mono_g_hash_table_lookup (tid_to_thread, (gpointer)tid);
        if (thread) {
-               tls = mono_g_hash_table_lookup (thread_to_tls, thread);
-               /* FIXME: Maybe we need to free this instead, but some code can't handle that */
-               tls->terminated = TRUE;
                mono_g_hash_table_remove (tid_to_thread_obj, (gpointer)tid);
-               /* Can't remove from tid_to_thread, as that would defeat the check in thread_start () */
-               MONO_GC_UNREGISTER_ROOT (tls->thread);
-               tls->thread = NULL;
+               tls = mono_g_hash_table_lookup (thread_to_tls, thread);
+               if (tls) {
+                       /* FIXME: Maybe we need to free this instead, but some code can't handle that */
+                       tls->terminated = TRUE;
+                       /* Can't remove from tid_to_thread, as that would defeat the check in thread_start () */
+                       MONO_GC_UNREGISTER_ROOT (tls->thread);
+                       tls->thread = NULL;
+               }
        }
        mono_loader_unlock ();
 
@@ -4277,8 +4297,6 @@ process_breakpoint_inner (DebuggerTlsData *tls)
        ss_reqs = g_ptr_array_new ();
        ss_reqs_orig = g_ptr_array_new ();
 
-       DEBUG(1, fprintf (log_file, "[%p] Breakpoint hit, method=%s, ip=%p, offset=0x%x.\n", (gpointer)GetCurrentThreadId (), ji->method->name, ip, native_offset));
-
        mono_loader_lock ();
 
        /*
@@ -4287,6 +4305,8 @@ process_breakpoint_inner (DebuggerTlsData *tls)
         */
        sp = find_prev_seq_point_for_native_offset (mono_domain_get (), ji->method, native_offset, &info);
 
+       DEBUG(1, fprintf (log_file, "[%p] Breakpoint hit, method=%s, ip=%p, offset=0x%x, sp il offset=0x%x.\n", (gpointer)GetCurrentThreadId (), ji->method->name, ip, native_offset, sp ? sp->il_offset : -1));
+
        bp = NULL;
        for (i = 0; i < breakpoints->len; ++i) {
                bp = g_ptr_array_index (breakpoints, i);
@@ -4329,9 +4349,11 @@ process_breakpoint_inner (DebuggerTlsData *tls)
                        if (minfo)
                                loc = mono_debug_symfile_lookup_location (minfo, sp->il_offset);
 
-                       if (!loc || (loc && ji->method == ss_req->last_method && loc->row == ss_req->last_line))
+                       if (!loc || (loc && ji->method == ss_req->last_method && loc->row == ss_req->last_line)) {
                                /* Have to continue single stepping */
+                               DEBUG(1, fprintf (log_file, "[%p] Same source line, continuing single stepping.\n", (gpointer)GetCurrentThreadId ()));
                                hit = FALSE;
+                       }
                                
                        if (loc) {
                                ss_req->last_method = ji->method;
@@ -4439,7 +4461,6 @@ mono_debugger_agent_breakpoint_hit (void *sigctx)
         * problems, like the original signal is disabled, libgc can't handle altstack, etc.
         * So set up the signal context to return to the real breakpoint handler function.
         */
-
        resume_from_signal_handler (sigctx, process_breakpoint);
 }
 
@@ -4768,7 +4789,7 @@ ss_stop (SingleStepReq *ss_req)
 static void
 ss_start (SingleStepReq *ss_req, MonoMethod *method, SeqPoint *sp, MonoSeqPointInfo *info, MonoContext *ctx, DebuggerTlsData *tls, gboolean step_to_catch)
 {
-       int i, frame_index;
+       int i, j, frame_index;
        SeqPoint *next_sp;
        MonoBreakpoint *bp;
        gboolean enable_global = FALSE;
@@ -4785,7 +4806,7 @@ ss_start (SingleStepReq *ss_req, MonoMethod *method, SeqPoint *sp, MonoSeqPointI
        } else {
                frame_index = 1;
 
-               if ((!sp || sp->next_len == 0 || ss_req->depth == STEP_DEPTH_OUT) && ctx) {
+               if ((!sp || sp->next_len == 0 || ss_req->depth == STEP_DEPTH_OUT || ss_req->depth == STEP_DEPTH_OVER) && ctx) {
                        /* Need parent frames */
                        if (!tls->context.valid)
                                mono_thread_state_init_from_monoctx (&tls->context, ctx);
@@ -4807,6 +4828,8 @@ ss_start (SingleStepReq *ss_req, MonoMethod *method, SeqPoint *sp, MonoSeqPointI
                                if (sp && sp->next_len != 0)
                                        break;
                        }
+                       // There could be method calls before the next seq point in the caller when using nested calls
+                       //enable_global = TRUE;
                } else {
                        while (sp && sp->next_len == 0) {
                                sp = NULL;
@@ -4829,6 +4852,27 @@ ss_start (SingleStepReq *ss_req, MonoMethod *method, SeqPoint *sp, MonoSeqPointI
                        }
                }
 
+               if (ss_req->depth == STEP_DEPTH_OVER) {
+                       /* Need to stop in catch clauses as well */
+                       for (i = 0; i < tls->frame_count; ++i) {
+                               StackFrame *frame = tls->frames [i];
+
+                               if (frame->ji) {
+                                       MonoJitInfo *jinfo = frame->ji;
+                                       for (j = 0; j < jinfo->num_clauses; ++j) {
+                                               MonoJitExceptionInfo *ei = &jinfo->clauses [j];
+
+                                               sp = find_next_seq_point_for_native_offset (frame->domain, frame->method, (char*)ei->handler_start - (char*)jinfo->code_start, NULL);
+                                               if (sp) {
+                                                       bp = set_breakpoint (frame->method, sp->il_offset, ss_req->req, NULL);
+                                                       ss_req->bps = g_slist_append (ss_req->bps, bp);
+                                               }
+                                       }
+                               }
+                       }
+               }
+
+
                if (ss_req->depth == STEP_DEPTH_INTO) {
                        /* Enable global stepping so we stop at method entry too */
                        enable_global = TRUE;
@@ -5314,11 +5358,29 @@ buffer_add_value (Buffer *buf, MonoType *t, void *addr, MonoDomain *domain)
        buffer_add_value_full (buf, t, addr, domain, FALSE);
 }
 
+static gboolean
+obj_is_of_type (MonoObject *obj, MonoType *t)
+{
+       MonoClass *klass = obj->vtable->klass;
+       if (!mono_class_is_assignable_from (mono_class_from_mono_type (t), klass)) {
+               if (klass == mono_defaults.transparent_proxy_class) {
+                       klass = ((MonoTransparentProxy *)obj)->remote_class->proxy_class;
+                       if (mono_class_is_assignable_from (mono_class_from_mono_type (t), klass)) {
+                               return TRUE;
+                       }
+               }
+               return FALSE;
+       }
+       return TRUE;
+}
+
 static ErrorCode
-decode_value (MonoType *t, MonoDomain *domain, guint8 *addr, guint8 *buf, guint8 **endbuf, guint8 *limit)
+decode_value (MonoType *t, MonoDomain *domain, guint8 *addr, guint8 *buf, guint8 **endbuf, guint8 *limit);
+
+static ErrorCode
+decode_value_internal (MonoType *t, int type, MonoDomain *domain, guint8 *addr, guint8 *buf, guint8 **endbuf, guint8 *limit)
 {
        int err;
-       int type = decode_byte (buf, &buf, limit);
 
        if (type != t->type && !MONO_TYPE_IS_REFERENCE (t) &&
                !(t->type == MONO_TYPE_I && type == MONO_TYPE_VALUETYPE) &&
@@ -5431,8 +5493,12 @@ decode_value (MonoType *t, MonoDomain *domain, guint8 *addr, guint8 *buf, guint8
                                if (err)
                                        return err;
 
-                               if (obj && !mono_class_is_assignable_from (mono_class_from_mono_type (t), obj->vtable->klass))
-                                       return ERR_INVALID_ARGUMENT;
+                               if (obj) {
+                                       if (!obj_is_of_type (obj, t)) {
+                                               DEBUG (1, fprintf (log_file, "Expected type '%s', got '%s'\n", mono_type_full_name (t), obj->vtable->klass->name));
+                                               return ERR_INVALID_ARGUMENT;
+                                       }
+                               }
                                if (obj && obj->vtable->domain != domain)
                                        return ERR_INVALID_ARGUMENT;
 
@@ -5453,6 +5519,47 @@ decode_value (MonoType *t, MonoDomain *domain, guint8 *addr, guint8 *buf, guint8
        return 0;
 }
 
+static ErrorCode
+decode_value (MonoType *t, MonoDomain *domain, guint8 *addr, guint8 *buf, guint8 **endbuf, guint8 *limit)
+{
+       int err;
+       int type = decode_byte (buf, &buf, limit);
+
+       if (t->type == MONO_TYPE_GENERICINST && mono_class_is_nullable (mono_class_from_mono_type (t))) {
+               MonoType *targ = t->data.generic_class->context.class_inst->type_argv [0];
+               guint8 *nullable_buf;
+
+               /*
+                * First try decoding it as a Nullable`1
+                */
+               err = decode_value_internal (t, type, domain, addr, buf, endbuf, limit);
+               if (!err)
+                       return err;
+
+               /*
+                * Then try decoding as a primitive value or null.
+                */
+               if (targ->type == type) {
+                       nullable_buf = g_malloc (mono_class_instance_size (mono_class_from_mono_type (targ)));
+                       err = decode_value_internal (targ, type, domain, nullable_buf, buf, endbuf, limit);
+                       if (err) {
+                               g_free (nullable_buf);
+                               return err;
+                       }
+                       mono_nullable_init (addr, mono_value_box (domain, mono_class_from_mono_type (targ), nullable_buf), mono_class_from_mono_type (t));
+                       g_free (nullable_buf);
+                       *endbuf = buf;
+                       return ERR_NONE;
+               } else if (type == VALUE_TYPE_ID_NULL) {
+                       mono_nullable_init (addr, NULL, mono_class_from_mono_type (t));
+                       *endbuf = buf;
+                       return ERR_NONE;
+               }
+       }
+
+       return decode_value_internal (t, type, domain, addr, buf, endbuf, limit);
+}
+
 static void
 add_var (Buffer *buf, MonoType *t, MonoDebugVarInfo *var, MonoContext *ctx, MonoDomain *domain, gboolean as_vtype)
 {
@@ -5527,6 +5634,9 @@ set_var (MonoType *t, MonoDebugVarInfo *var, MonoContext *ctx, MonoDomain *domai
                        g_assert_not_reached ();
                }
 
+               if (t->byref)
+                       NOT_IMPLEMENTED;
+
                /* Set value on the stack or in the return ctx */
                if (reg_locations [reg]) {
                        /* Saved on the stack */
@@ -5552,8 +5662,15 @@ set_var (MonoType *t, MonoDebugVarInfo *var, MonoContext *ctx, MonoDomain *domai
 
                //printf ("[R%d+%d] = %p\n", reg, var->offset, addr);
 
+               if (t->byref) {
+                       addr = *(guint8**)addr;
+
+                       if (!addr)
+                               break;
+               }
+                       
                // FIXME: Write barriers
-               memcpy (addr, val, size);
+               mono_gc_memmove (addr, val, size);
                break;
        case MONO_DEBUG_VAR_ADDRESS_MODE_DEAD:
                NOT_IMPLEMENTED;
@@ -5748,7 +5865,7 @@ do_invoke_method (DebuggerTlsData *tls, Buffer *buf, InvokeData *invoke)
                }
        }
 
-       if (this && !mono_class_is_assignable_from (m->klass, this->vtable->klass))
+       if (this && !obj_is_of_type (this, &m->klass->byval_arg))
                return ERR_INVALID_ARGUMENT;
 
        nargs = decode_int (p, &p, end);
@@ -5856,12 +5973,14 @@ do_invoke_method (DebuggerTlsData *tls, Buffer *buf, InvokeData *invoke)
                                buffer_add_value (buf, &mono_defaults.void_class->byval_arg, NULL, domain);
                } else if (MONO_TYPE_IS_REFERENCE (sig->ret)) {
                        buffer_add_value (buf, sig->ret, &res, domain);
-               } else if (mono_class_from_mono_type (sig->ret)->valuetype) {
+               } else if (mono_class_from_mono_type (sig->ret)->valuetype || sig->ret->type == MONO_TYPE_PTR || sig->ret->type == MONO_TYPE_FNPTR) {
                        if (mono_class_is_nullable (mono_class_from_mono_type (sig->ret))) {
-                               if (!res)
-                                       buffer_add_value (buf, &mono_defaults.object_class->byval_arg, &res, domain);
-                               else
-                                       buffer_add_value (buf, sig->ret, mono_object_unbox (res), domain);
+                               MonoClass *k = mono_class_from_mono_type (sig->ret);
+                               guint8 *nullable_buf = g_alloca (mono_class_value_size (k, NULL));
+
+                               g_assert (nullable_buf);
+                               mono_nullable_init (nullable_buf, res, k);
+                               buffer_add_value (buf, sig->ret, nullable_buf, domain);
                        } else {
                                g_assert (res);
                                buffer_add_value (buf, sig->ret, mono_object_unbox (res), domain);
@@ -6192,7 +6311,7 @@ vm_commands (int command, int id, guint8 *p, guint8 *end, Buffer *buf)
                 * resumed.
                 */
                if (tls->pending_invoke)
-                       NOT_IMPLEMENTED;
+                       return ERR_NOT_SUSPENDED;
                tls->pending_invoke = g_new0 (InvokeData, 1);
                tls->pending_invoke->id = id;
                tls->pending_invoke->flags = flags;
@@ -6778,7 +6897,7 @@ assembly_commands (int command, guint8 *p, guint8 *end, Buffer *buf)
                break;
        }
        case CMD_ASSEMBLY_GET_OBJECT: {
-               MonoObject *o = (MonoObject*)mono_assembly_get_object (mono_domain_get (), ass);
+               MonoObject *o = (MonoObject*)mono_assembly_get_object (domain, ass);
                buffer_add_objid (buf, o);
                break;
        }
@@ -7262,7 +7381,7 @@ type_commands_internal (int command, MonoClass *klass, MonoDomain *domain, guint
                break;
        }
        case CMD_TYPE_GET_OBJECT: {
-               MonoObject *o = (MonoObject*)mono_type_get_object (mono_domain_get (), &klass->byval_arg);
+               MonoObject *o = (MonoObject*)mono_type_get_object (domain, &klass->byval_arg);
                buffer_add_objid (buf, o);
                break;
        }
@@ -7462,7 +7581,7 @@ method_commands_internal (int command, MonoMethod *method, MonoDomain *domain, g
                        buffer_add_string (buf, source_file);
                }
                buffer_add_int (buf, n_il_offsets);
-               DEBUG (10, printf ("Line number table for method %s:\n", mono_method_full_name (method,  TRUE)));
+               DEBUG (10, fprintf (log_file, "Line number table for method %s:\n", mono_method_full_name (method,  TRUE)));
                for (i = 0; i < n_il_offsets; ++i) {
                        const char *srcfile = "";
 
@@ -7470,7 +7589,7 @@ method_commands_internal (int command, MonoMethod *method, MonoDomain *domain, g
                                MonoDebugSourceInfo *sinfo = g_ptr_array_index (source_file_list, source_files [i]);
                                srcfile = sinfo->source_file;
                        }
-                       DEBUG (10, printf ("IL%x -> %s:%d\n", il_offsets [i], srcfile, line_numbers [i]));
+                       DEBUG (10, fprintf (log_file, "IL%x -> %s:%d\n", il_offsets [i], srcfile, line_numbers [i]));
                        buffer_add_int (buf, il_offsets [i]);
                        buffer_add_int (buf, line_numbers [i]);
                        if (CHECK_PROTOCOL_VERSION (2, 13))
@@ -7632,12 +7751,34 @@ method_commands_internal (int command, MonoMethod *method, MonoDomain *domain, g
                header = mono_method_get_header (method);
                if (!header) {
                        buffer_add_int (buf, 0);
+
+                       if (CHECK_PROTOCOL_VERSION (2, 18))
+                               buffer_add_int (buf, 0);
                } else {
                        buffer_add_int (buf, header->code_size);
                        for (i = 0; i < header->code_size; ++i)
                                buffer_add_byte (buf, header->code [i]);
+
+                       if (CHECK_PROTOCOL_VERSION (2, 18)) {
+                               buffer_add_int (buf, header->num_clauses);
+                               for (i = 0; i < header->num_clauses; ++i) {
+                                       MonoExceptionClause *clause = &header->clauses [i];
+
+                                       buffer_add_int (buf, clause->flags);
+                                       buffer_add_int (buf, clause->try_offset);
+                                       buffer_add_int (buf, clause->try_len);
+                                       buffer_add_int (buf, clause->handler_offset);
+                                       buffer_add_int (buf, clause->handler_len);
+                                       if (clause->flags == MONO_EXCEPTION_CLAUSE_NONE)
+                                               buffer_add_typeid (buf, domain, clause->data.catch_class);
+                                       else if (clause->flags == MONO_EXCEPTION_CLAUSE_FILTER)
+                                               buffer_add_int (buf, clause->data.filter_offset);
+                               }
+                       }
+
+                       mono_metadata_free_mh (header);
                }
-               mono_metadata_free_mh (header);
+
                break;
        }
        case CMD_METHOD_RESOLVE_TOKEN: {
@@ -7877,14 +8018,14 @@ frame_commands (int command, guint8 *p, guint8 *end, Buffer *buf)
                return ERR_INVALID_FRAMEID;
 
        if (!frame->jit) {
-               frame->jit = mono_debug_find_method (frame->method, frame->domain);
-               if (!frame->jit && frame->method->is_inflated)
-                       frame->jit = mono_debug_find_method (mono_method_get_declaring_generic_method (frame->method), frame->domain);
+               frame->jit = mono_debug_find_method (frame->api_method, frame->domain);
+               if (!frame->jit && frame->api_method->is_inflated)
+                       frame->jit = mono_debug_find_method (mono_method_get_declaring_generic_method (frame->api_method), frame->domain);
                if (!frame->jit) {
                        char *s;
 
                        /* This could happen for aot images with no jit debug info */
-                       s = mono_method_full_name (frame->method, TRUE);
+                       s = mono_method_full_name (frame->api_method, TRUE);
                        DEBUG (1, fprintf (log_file, "[dbg] No debug information found for '%s'.\n", s));
                        g_free (s);
                        return ERR_ABSENT_INFORMATION;
@@ -7928,7 +8069,7 @@ frame_commands (int command, guint8 *p, guint8 *end, Buffer *buf)
                break;
        }
        case CMD_STACK_FRAME_GET_THIS: {
-               if (frame->method->klass->valuetype) {
+               if (frame->api_method->klass->valuetype) {
                        if (!sig->hasthis) {
                                MonoObject *p = NULL;
                                buffer_add_value (buf, &mono_defaults.object_class->byval_arg, &p, frame->domain);
@@ -7940,7 +8081,7 @@ frame_commands (int command, guint8 *p, guint8 *end, Buffer *buf)
                                MonoObject *p = NULL;
                                buffer_add_value (buf, &frame->actual_method->klass->byval_arg, &p, frame->domain);
                        } else {
-                               add_var (buf, &frame->method->klass->byval_arg, jit->this_var, &frame->ctx, frame->domain, TRUE);
+                               add_var (buf, &frame->api_method->klass->byval_arg, jit->this_var, &frame->ctx, frame->domain, TRUE);
                        }
                }
                break;
@@ -8117,7 +8258,8 @@ object_commands (int command, guint8 *p, guint8 *end, Buffer *buf)
 
        switch (command) {
        case CMD_OBJECT_REF_GET_TYPE:
-               buffer_add_typeid (buf, obj->vtable->domain, obj->vtable->klass);
+               /* This handles transparent proxies too */
+               buffer_add_typeid (buf, obj->vtable->domain, mono_class_from_mono_type (((MonoReflectionType*)obj->vtable->type)->type));
                break;
        case CMD_OBJECT_REF_GET_VALUES:
                len = decode_int (p, &p, end);
@@ -8207,7 +8349,7 @@ object_commands (int command, guint8 *p, guint8 *end, Buffer *buf)
                buffer_add_domainid (buf, obj->vtable->domain);
                break;
        case CMD_OBJECT_REF_GET_INFO:
-               buffer_add_typeid (buf, obj->vtable->domain, obj->vtable->klass);
+               buffer_add_typeid (buf, obj->vtable->domain, mono_class_from_mono_type (((MonoReflectionType*)obj->vtable->type)->type));
                buffer_add_domainid (buf, obj->vtable->domain);
                break;
        default:
index 40106503986ffe01b8b3c732d968b9b74b247275..e01a6d304ccb02606d373579d53df702dcc77e64 100644 (file)
@@ -834,10 +834,11 @@ typedef struct CompileAllThreadArgs {
        MonoAssembly *ass;
        int verbose;
        guint32 opts;
+       guint32 recompilation_times;
 } CompileAllThreadArgs;
 
 static void
-compile_all_methods_thread_main (CompileAllThreadArgs *args)
+compile_all_methods_thread_main_inner (CompileAllThreadArgs *args)
 {
        MonoAssembly *ass = args->ass;
        int verbose = args->verbose;
@@ -895,13 +896,22 @@ compile_all_methods_thread_main (CompileAllThreadArgs *args)
 }
 
 static void
-compile_all_methods (MonoAssembly *ass, int verbose, guint32 opts)
+compile_all_methods_thread_main (CompileAllThreadArgs *args)
+{
+       guint32 i;
+       for (i = 0; i < args->recompilation_times; ++i)
+               compile_all_methods_thread_main_inner (args);
+}
+
+static void
+compile_all_methods (MonoAssembly *ass, int verbose, guint32 opts, guint32 recompilation_times)
 {
        CompileAllThreadArgs args;
 
        args.ass = ass;
        args.verbose = verbose;
        args.opts = opts;
+       args.recompilation_times = recompilation_times;
 
        /* 
         * Need to create a mono thread since compilation might trigger
@@ -1081,7 +1091,7 @@ mini_usage_jitdeveloper (void)
                 "    --break METHOD         Inserts a breakpoint at METHOD entry\n"
                 "    --break-at-bb METHOD N Inserts a breakpoint in METHOD at BB N\n"
                 "    --compile METHOD       Just compile METHOD in assembly\n"
-                "    --compile-all          Compiles all the methods in the assembly\n"
+                "    --compile-all=N        Compiles all the methods in the assembly multiple times (default: 1)\n"
                 "    --ncompile N           Number of times to compile METHOD (default: 1)\n"
                 "    --print-vtable         Print the vtable of all used classes\n"
                 "    --regression           Runs the regression test contained in the assembly\n"
@@ -1332,6 +1342,12 @@ mono_jit_parse_options (int argc, char * argv[])
                        
                        if (!mono_debugger_insert_breakpoint (argv [++i], FALSE))
                                fprintf (stderr, "Error: invalid method name '%s'\n", argv [i]);
+               } else if (strcmp (argv [i], "--llvm") == 0) {
+#ifndef MONO_ARCH_LLVM_SUPPORTED
+                       fprintf (stderr, "Mono Warning: --llvm not supported on this platform.\n");
+#else
+                       mono_use_llvm = TRUE;
+#endif
                } else {
                        fprintf (stderr, "Unsupported command line option: '%s'\n", argv [i]);
                        exit (1);
@@ -1389,7 +1405,7 @@ mono_main (int argc, char* argv[])
        const char* aname, *mname = NULL;
        char *config_file = NULL;
        int i, count = 1;
-       guint32 opt, action = DO_EXEC;
+       guint32 opt, action = DO_EXEC, recompilation_times = 1;
        MonoGraphOptions mono_graph_options = 0;
        int mini_verbose = 0;
        gboolean enable_profile = FALSE;
@@ -1423,22 +1439,6 @@ mono_main (int argc, char* argv[])
        if (!g_thread_supported ())
                g_thread_init (NULL);
 
-       if (mono_running_on_valgrind () && getenv ("MONO_VALGRIND_LEAK_CHECK")) {
-               GMemVTable mem_vtable;
-
-               /* 
-                * Instruct glib to use the system allocation functions so valgrind
-                * can track the memory allocated by the g_... functions.
-                */
-               memset (&mem_vtable, 0, sizeof (mem_vtable));
-               mem_vtable.malloc = malloc;
-               mem_vtable.realloc = realloc;
-               mem_vtable.free = free;
-               mem_vtable.calloc = calloc;
-
-               g_mem_set_vtable (&mem_vtable);
-       }
-
        g_log_set_always_fatal (G_LOG_LEVEL_ERROR);
        g_log_set_fatal_mask (G_LOG_DOMAIN, G_LOG_LEVEL_ERROR);
 
@@ -1455,7 +1455,7 @@ mono_main (int argc, char* argv[])
                        char *build = mono_get_runtime_build_info ();
                        char *gc_descr;
 
-                       g_print ("Mono JIT compiler version %s\nCopyright (C) 2002-2011 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com\n", build);
+                       g_print ("Mono JIT compiler version %s\nCopyright (C) 2002-2012 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com\n", build);
                        g_free (build);
                        g_print (info);
                        gc_descr = mono_gc_get_description ();
@@ -1601,6 +1601,9 @@ mono_main (int argc, char* argv[])
                        mono_compile_aot = TRUE;
                        aot_options = &argv [i][6];
 #endif
+               } else if (strncmp (argv [i], "--compile-all=", 14) == 0) {
+                       action = DO_COMPILE;
+                       recompilation_times = atoi (argv [i] + 14);
                } else if (strcmp (argv [i], "--compile-all") == 0) {
                        action = DO_COMPILE;
                } else if (strncmp (argv [i], "--runtime=", 10) == 0) {
@@ -1955,7 +1958,7 @@ mono_main (int argc, char* argv[])
                i = mono_environment_exitcode_get ();
                return i;
        } else if (action == DO_COMPILE) {
-               compile_all_methods (assembly, mini_verbose, opt);
+               compile_all_methods (assembly, mini_verbose, opt, recompilation_times);
                mini_cleanup (domain);
                return 0;
        } else if (action == DO_DEBUGGER) {
index 986fe5d1d502e59ff6aba0195e6a1b38b63a6fd5..1506972c78aeab7dab20127b7ac8b2f69839b026 100644 (file)
@@ -1758,7 +1758,7 @@ static void
 asm_writer_emit_symbol_diff (MonoImageWriter *acfg, const char *end, const char* start, int offset)
 {
 #ifdef TARGET_ASM_APPLE
-       char symbol [128];
+       //char symbol [128];
 #endif
 
        if (acfg->mode != EMIT_LONG) {
index 3ea25c37c857e1a17f6e6a38f414949cc3419a54..7ebb9faf169b40cfdf10de16c2b17fa23b34e7b9 100644 (file)
@@ -52,6 +52,7 @@
 #include <mono/metadata/monitor.h>
 #include <mono/metadata/profiler-private.h>
 #include <mono/metadata/profiler.h>
+#include <mono/metadata/debug-mono-symfile.h>
 #include <mono/utils/mono-compiler.h>
 #include <mono/utils/mono-memory-model.h>
 #include <mono/metadata/mono-basic-block.h>
@@ -347,6 +348,8 @@ mono_create_helper_signatures (void)
 
 #define LOAD_ERROR do { if (mini_get_debug_options ()->break_on_unverified) G_BREAKPOINT (); else goto load_error; } while (0)
 
+#define TYPE_LOAD_ERROR(klass) do { if (mini_get_debug_options ()->break_on_unverified) G_BREAKPOINT (); else { cfg->exception_ptr = klass; goto load_error; } } while (0)
+
 #define GET_BBLOCK(cfg,tblock,ip) do { \
                (tblock) = cfg->cil_offset_to_bb [(ip) - cfg->cil_start]; \
                if (!(tblock)) {        \
@@ -3063,6 +3066,17 @@ emit_generic_class_init (MonoCompile *cfg, MonoClass *klass)
 #endif
 }
 
+static void
+emit_seq_point (MonoCompile *cfg, MonoMethod *method, guint8* ip, gboolean intr_loc)
+{
+       MonoInst *ins;
+
+       if (cfg->gen_seq_points && cfg->method == method) {
+               NEW_SEQ_POINT (cfg, ins, ip - cfg->header->code, intr_loc);
+               MONO_ADD_INS (cfg->cbb, ins);
+       }
+}
+
 static void
 save_cast_details (MonoCompile *cfg, MonoClass *klass, int obj_reg)
 {
@@ -5764,8 +5778,10 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
        gboolean dont_verify, dont_verify_stloc, readonly = FALSE;
        int context_used;
        gboolean init_locals, seq_points, skip_dead_blocks;
-       gboolean disable_inline;
+       gboolean disable_inline, sym_seq_points = FALSE;
        MonoInst *cached_tls_addr = NULL;
+       MonoDebugMethodInfo *minfo;
+       MonoBitSet *seq_point_locs = NULL;
 
        disable_inline = is_jit_optimizer_disabled (method);
 
@@ -5809,6 +5825,23 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
        seq_points = cfg->gen_seq_points && cfg->method == method;
 
+       if (cfg->gen_seq_points && cfg->method == method) {
+               minfo = mono_debug_lookup_method (method);
+               if (minfo) {
+                       int i, n_il_offsets;
+                       int *il_offsets;
+                       int *line_numbers;
+
+                       mono_debug_symfile_get_line_numbers_full (minfo, NULL, NULL, &n_il_offsets, &il_offsets, &line_numbers, NULL);
+                       seq_point_locs = mono_bitset_mem_new (mono_mempool_alloc0 (cfg->mempool, mono_bitset_alloc_size (header->code_size, 0)), header->code_size, 0);
+                       sym_seq_points = TRUE;
+                       for (i = 0; i < n_il_offsets; ++i) {
+                               if (il_offsets [i] < header->code_size)
+                                       mono_bitset_set_fast (seq_point_locs, il_offsets [i]);
+                       }
+               }
+       }
+
        /* 
         * Methods without init_locals set could cause asserts in various passes
         * (#497220).
@@ -6264,7 +6297,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                 * Currently, we generate these automatically at points where the IL
                 * stack is empty.
                 */
-               if (seq_points && sp == stack_start) {
+               if (seq_points && ((sp == stack_start) || (sym_seq_points && mono_bitset_test_fast (seq_point_locs, ip - header->code)))) {
                        /*
                         * Make methods interruptable at the beginning, and at the targets of
                         * backward branches.
@@ -6305,7 +6338,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
                switch (*ip) {
                case CEE_NOP:
-                       if (seq_points && sp != stack_start) {
+                       if (seq_points && !sym_seq_points && sp != stack_start) {
                                /*
                                 * The C# compiler uses these nops to notify the JIT that it should
                                 * insert seq points.
@@ -6663,6 +6696,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                        MonoInst *vtable_arg = NULL;
                        gboolean check_this = FALSE;
                        gboolean supported_tail_call = FALSE;
+                       gboolean need_seq_point = FALSE;
 
                        CHECK_OPSIZE (5);
                        token = read32 (ip + 1);
@@ -6727,7 +6761,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                        cmethod = mini_get_method (cfg, method, token, NULL, generic_context);
                                        cil_method = cmethod;
                                }
-
+                                       
                                if (!cmethod || mono_loader_get_last_error ())
                                        LOAD_ERROR;
                                if (!dont_verify && !cfg->skip_visibility) {
@@ -6762,7 +6796,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
                                if (!cmethod->klass->inited)
                                        if (!mono_class_init (cmethod->klass))
-                                               LOAD_ERROR;
+                                               TYPE_LOAD_ERROR (cmethod->klass);
 
                                if (cmethod->iflags & METHOD_IMPL_ATTRIBUTE_INTERNAL_CALL &&
                                    mini_class_is_system_array (cmethod->klass)) {
@@ -6787,6 +6821,21 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
                                mono_save_token_info (cfg, image, token, cil_method);
 
+                               if (!MONO_TYPE_IS_VOID (fsig->ret) && !sym_seq_points) {
+                                       /*
+                                        * Need to emit an implicit seq point after every non-void call so single stepping through nested calls like
+                                        * foo (bar (), baz ())
+                                        * works correctly. MS does this also:
+                                        * http://stackoverflow.com/questions/6937198/making-your-net-language-step-correctly-in-the-debugger
+                                        * The problem with this approach is that the debugger will stop after all calls returning a value,
+                                        * even for simple cases, like:
+                                        * int i = foo ();
+                                        */
+                                       /* Special case a few common successor opcodes */
+                                       if (!(ip + 5 < end && ip [5] == CEE_POP))
+                                               need_seq_point = TRUE;
+                               }
+
                                n = fsig->param_count + fsig->hasthis;
 
                                if (mono_security_get_mode () == MONO_SECURITY_MODE_CAS) {
@@ -7010,6 +7059,8 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
                                ip += 5;
                                ins_flag = 0;
+                               if (need_seq_point)
+                                       emit_seq_point (cfg, method, ip, FALSE);
                                break;
                        }
 
@@ -7053,6 +7104,8 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
                                ip += 5;
                                ins_flag = 0;
+                               if (need_seq_point)
+                                       emit_seq_point (cfg, method, ip, FALSE);
                                break;
                        }
 
@@ -7077,12 +7130,15 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                        cfg->real_offset += 5;
                                        bblock = cfg->cbb;
 
-                                       if (!MONO_TYPE_IS_VOID (fsig->ret))
+                                       if (!MONO_TYPE_IS_VOID (fsig->ret)) {
                                                /* *sp is already set by inline_method */
                                                sp++;
+                                       }
 
                                        inline_costs += costs;
                                        ins_flag = 0;
+                                       if (need_seq_point)
+                                               emit_seq_point (cfg, method, ip, FALSE);
                                        break;
                                }
                        }
@@ -7187,6 +7243,8 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
                                ip += 5;
                                ins_flag = 0;
+                               if (need_seq_point)
+                                       emit_seq_point (cfg, method, ip, FALSE);
                                break;
                        }
                                        
@@ -7232,6 +7290,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
                                ip += 5;
                                ins_flag = 0;
+                               emit_seq_point (cfg, method, ip, FALSE);
                                break;
                        }
 
@@ -7244,6 +7303,8 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
                                ip += 5;
                                ins_flag = 0;
+                               if (need_seq_point)
+                                       emit_seq_point (cfg, method, ip, FALSE);
                                break;
                        }
 
@@ -7333,6 +7394,8 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
 
                        ip += 5;
                        ins_flag = 0;
+                       if (need_seq_point)
+                               emit_seq_point (cfg, method, ip, FALSE);
                        break;
                }
                case CEE_RET:
@@ -7345,9 +7408,15 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                 * (test case: test_0_inline_throw ()).
                                 */
                                if (return_var && cfg->cbb->in_count) {
+                                       MonoType *ret_type = mono_method_signature (method)->ret;
+
                                        MonoInst *store;
                                        CHECK_STACK (1);
                                        --sp;
+
+                                       if ((method->wrapper_type == MONO_WRAPPER_DYNAMIC_METHOD || method->wrapper_type == MONO_WRAPPER_NONE) && target_type_is_incompatible (cfg, ret_type, *sp))
+                                               UNVERIFIED;
+
                                        //g_assert (returnvar != -1);
                                        EMIT_NEW_TEMPSTORE (cfg, store, return_var->inst_c0, *sp);
                                        cfg->ret_var_set = TRUE;
@@ -7356,7 +7425,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                if (cfg->ret) {
                                        MonoType *ret_type = mono_method_signature (method)->ret;
 
-                                       if (seq_points) {
+                                       if (seq_points && !sym_seq_points) {
                                                /* 
                                                 * Place a seq point here too even through the IL stack is not
                                                 * empty, so a step over on
@@ -8092,7 +8161,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                        mono_save_token_info (cfg, image, token, cmethod);
 
                        if (!mono_class_init (cmethod->klass))
-                               LOAD_ERROR;
+                               TYPE_LOAD_ERROR (cmethod->klass);
 
                        if (cfg->generic_sharing_context)
                                context_used = mono_method_check_context_used (cmethod);
@@ -9246,7 +9315,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                        ins->sreg1 = sp [0]->dreg;
                                        ins->inst_newa_class = klass;
                                        ins->type = STACK_OBJ;
-                                       ins->klass = klass;
+                                       ins->klass = array_type;
                                        MONO_ADD_INS (cfg->cbb, ins);
                                        cfg->flags |= MONO_CFG_HAS_ARRAY_ACCESS;
                                        cfg->cbb->has_array_access = TRUE;
index 9e9af931519dd70f130100e8f6285b12802e7617..3e926c59de292e1489303d02f9ff2d67a8cb753b 100644 (file)
@@ -8012,6 +8012,8 @@ mono_arch_finish_init (void)
                appdomain_tls_offset = -1;
        if (lmf_tls_offset >= 64)
                lmf_tls_offset = -1;
+       if (lmf_addr_tls_offset >= 64)
+               lmf_addr_tls_offset = -1;
 #else
 #ifdef MONO_XEN_OPT
        optimize_for_xen = access ("/proc/xen", F_OK) == 0;
index 9d4fa72af3b01ec1ccdf428e7c522a67534eef4d..79062b31421ba1ac34983fd40c80c714e1a88c8d 100644 (file)
@@ -2680,7 +2680,7 @@ branch_cc_table [] = {
        ARMCOND_LO
 };
 
-#define NEW_INS(cfg,dest,op) do {       \
+#define ADD_NEW_INS(cfg,dest,op) do {       \
                MONO_INST_NEW ((cfg), (dest), (op)); \
         mono_bblock_insert_before_ins (bb, ins, (dest)); \
        } while (0)
@@ -2782,7 +2782,7 @@ loop_start:
                case OP_IOR_IMM:
                case OP_IXOR_IMM:
                        if ((imm8 = mono_arm_is_rotated_imm8 (ins->inst_imm, &rot_amount)) < 0) {
-                               NEW_INS (cfg, temp, OP_ICONST);
+                               ADD_NEW_INS (cfg, temp, OP_ICONST);
                                temp->inst_c0 = ins->inst_imm;
                                temp->dreg = mono_alloc_ireg (cfg);
                                ins->sreg2 = temp->dreg;
@@ -2809,7 +2809,7 @@ loop_start:
                                ins->inst_imm = imm8;
                                break;
                        }
-                       NEW_INS (cfg, temp, OP_ICONST);
+                       ADD_NEW_INS (cfg, temp, OP_ICONST);
                        temp->inst_c0 = ins->inst_imm;
                        temp->dreg = mono_alloc_ireg (cfg);
                        ins->sreg2 = temp->dreg;
@@ -2824,7 +2824,7 @@ loop_start:
                                ins->next->opcode = OP_COND_EXC_NC;
                        break;
                case OP_LOCALLOC_IMM:
-                       NEW_INS (cfg, temp, OP_ICONST);
+                       ADD_NEW_INS (cfg, temp, OP_ICONST);
                        temp->inst_c0 = ins->inst_imm;
                        temp->dreg = mono_alloc_ireg (cfg);
                        ins->sreg1 = temp->dreg;
@@ -2841,7 +2841,7 @@ loop_start:
                         */
                        if (arm_is_imm12 (ins->inst_offset))
                                break;
-                       NEW_INS (cfg, temp, OP_ICONST);
+                       ADD_NEW_INS (cfg, temp, OP_ICONST);
                        temp->inst_c0 = ins->inst_offset;
                        temp->dreg = mono_alloc_ireg (cfg);
                        ins->sreg2 = temp->dreg;
@@ -2852,7 +2852,7 @@ loop_start:
                case OP_LOADI1_MEMBASE:
                        if (arm_is_imm8 (ins->inst_offset))
                                break;
-                       NEW_INS (cfg, temp, OP_ICONST);
+                       ADD_NEW_INS (cfg, temp, OP_ICONST);
                        temp->inst_c0 = ins->inst_offset;
                        temp->dreg = mono_alloc_ireg (cfg);
                        ins->sreg2 = temp->dreg;
@@ -2864,23 +2864,34 @@ loop_start:
                                break;
                        low_imm = ins->inst_offset & 0x1ff;
                        if ((imm8 = mono_arm_is_rotated_imm8 (ins->inst_offset & ~0x1ff, &rot_amount)) >= 0) {
-                               NEW_INS (cfg, temp, OP_ADD_IMM);
+                               ADD_NEW_INS (cfg, temp, OP_ADD_IMM);
                                temp->inst_imm = ins->inst_offset & ~0x1ff;
                                temp->sreg1 = ins->inst_basereg;
                                temp->dreg = mono_alloc_ireg (cfg);
                                ins->inst_basereg = temp->dreg;
                                ins->inst_offset = low_imm;
-                               break;
+                       } else {
+                               MonoInst *add_ins;
+
+                               ADD_NEW_INS (cfg, temp, OP_ICONST);
+                               temp->inst_c0 = ins->inst_offset;
+                               temp->dreg = mono_alloc_ireg (cfg);
+
+                               ADD_NEW_INS (cfg, add_ins, OP_IADD);
+                               add_ins->sreg1 = ins->inst_basereg;
+                               add_ins->sreg2 = temp->dreg;
+                               add_ins->dreg = mono_alloc_ireg (cfg);
+
+                               ins->inst_basereg = add_ins->dreg;
+                               ins->inst_offset = 0;
                        }
-                       /* VFP/FPA doesn't have indexed load instructions */
-                       g_assert_not_reached ();
                        break;
                case OP_STORE_MEMBASE_REG:
                case OP_STOREI4_MEMBASE_REG:
                case OP_STOREI1_MEMBASE_REG:
                        if (arm_is_imm12 (ins->inst_offset))
                                break;
-                       NEW_INS (cfg, temp, OP_ICONST);
+                       ADD_NEW_INS (cfg, temp, OP_ICONST);
                        temp->inst_c0 = ins->inst_offset;
                        temp->dreg = mono_alloc_ireg (cfg);
                        ins->sreg2 = temp->dreg;
@@ -2889,7 +2900,7 @@ loop_start:
                case OP_STOREI2_MEMBASE_REG:
                        if (arm_is_imm8 (ins->inst_offset))
                                break;
-                       NEW_INS (cfg, temp, OP_ICONST);
+                       ADD_NEW_INS (cfg, temp, OP_ICONST);
                        temp->inst_c0 = ins->inst_offset;
                        temp->dreg = mono_alloc_ireg (cfg);
                        ins->sreg2 = temp->dreg;
@@ -2901,23 +2912,33 @@ loop_start:
                                break;
                        low_imm = ins->inst_offset & 0x1ff;
                        if ((imm8 = mono_arm_is_rotated_imm8 (ins->inst_offset & ~ 0x1ff, &rot_amount)) >= 0 && arm_is_fpimm8 (low_imm)) {
-                               NEW_INS (cfg, temp, OP_ADD_IMM);
+                               ADD_NEW_INS (cfg, temp, OP_ADD_IMM);
                                temp->inst_imm = ins->inst_offset & ~0x1ff;
                                temp->sreg1 = ins->inst_destbasereg;
                                temp->dreg = mono_alloc_ireg (cfg);
                                ins->inst_destbasereg = temp->dreg;
                                ins->inst_offset = low_imm;
-                               break;
+                       } else {
+                               MonoInst *add_ins;
+
+                               ADD_NEW_INS (cfg, temp, OP_ICONST);
+                               temp->inst_c0 = ins->inst_offset;
+                               temp->dreg = mono_alloc_ireg (cfg);
+
+                               ADD_NEW_INS (cfg, add_ins, OP_IADD);
+                               add_ins->sreg1 = ins->inst_destbasereg;
+                               add_ins->sreg2 = temp->dreg;
+                               add_ins->dreg = mono_alloc_ireg (cfg);
+
+                               ins->inst_destbasereg = add_ins->dreg;
+                               ins->inst_offset = 0;
                        }
-                       /*g_print ("fail with: %d (%d, %d)\n", ins->inst_offset, ins->inst_offset & ~0x1ff, low_imm);*/
-                       /* VFP/FPA doesn't have indexed store instructions */
-                       g_assert_not_reached ();
                        break;
                case OP_STORE_MEMBASE_IMM:
                case OP_STOREI1_MEMBASE_IMM:
                case OP_STOREI2_MEMBASE_IMM:
                case OP_STOREI4_MEMBASE_IMM:
-                       NEW_INS (cfg, temp, OP_ICONST);
+                       ADD_NEW_INS (cfg, temp, OP_ICONST);
                        temp->inst_c0 = ins->inst_imm;
                        temp->dreg = mono_alloc_ireg (cfg);
                        ins->sreg1 = temp->dreg;
index 6a58d726318c54cf2daaaf29bd49a94d6fc70574..be4b65fcdfa47daa5bf47301cdc1f8602dd0fa84 100644 (file)
@@ -2174,8 +2174,7 @@ mono_local_regalloc (MonoCompile *cfg, MonoBasicBlock *bb)
                                        MONO_INST_NEW (cfg, fxch, OP_X86_FXCH);
                                        fxch->inst_imm = sp - 1 - i;
 
-                                       prev->next = fxch;
-                                       fxch->next = ins;
+                                       mono_bblock_insert_after_ins (bb, prev, fxch);
                                        prev = fxch;
 
                                        tmp = fpstack [sp - 1];
@@ -2189,8 +2188,7 @@ mono_local_regalloc (MonoCompile *cfg, MonoBasicBlock *bb)
                                MONO_INST_NEW (cfg, fxch, OP_X86_FXCH);
                                fxch->inst_imm = 1;
 
-                               prev->next = fxch;
-                               fxch->next = ins;
+                               mono_bblock_insert_after_ins (bb, prev, fxch);
                                prev = fxch;
 
                                tmp = fpstack [sp - 1];
@@ -2214,8 +2212,7 @@ mono_local_regalloc (MonoCompile *cfg, MonoBasicBlock *bb)
                                        MONO_INST_NEW (cfg, fxch, OP_X86_FXCH);
                                        fxch->inst_imm = sp - 1 - i;
 
-                                       prev->next = fxch;
-                                       fxch->next = ins;
+                                       mono_bblock_insert_after_ins (bb, prev, fxch);
                                        prev = fxch;
 
                                        tmp = fpstack [sp - 1];
@@ -2242,8 +2239,7 @@ mono_local_regalloc (MonoCompile *cfg, MonoBasicBlock *bb)
                                        MONO_INST_NEW (cfg, fxch, OP_X86_FXCH);
                                        fxch->inst_imm = sp - 1 - i;
 
-                                       prev->next = fxch;
-                                       fxch->next = ins;
+                                       mono_bblock_insert_after_ins (bb, prev, fxch);
                                        prev = fxch;
 
                                        tmp = fpstack [sp - 1];
index 6250b25ab7f3269c709ffa2600552695e04c54f6..e6b6a1770a1eae853d7cd5c0e81fd20c2e20b8c6 100644 (file)
@@ -96,6 +96,15 @@ typedef struct {
 /* The exception port */
 static mach_port_t mach_exception_port = VM_MAP_NULL;
 
+kern_return_t
+catch_exception_raise (
+       mach_port_t exception_port,
+       mach_port_t thread,
+       mach_port_t task,
+       exception_type_t exception,
+       exception_data_t code,
+       mach_msg_type_number_t code_count);
+
 /*
  * Implicitly called by exc_server. Must be public.
  *
@@ -159,7 +168,7 @@ mach_exception_thread (void *arg)
 }
 
 static void
-macosx_register_exception_handler ()
+macosx_register_exception_handler (void)
 {
        mach_port_t task;
        pthread_attr_t attr;
@@ -201,6 +210,8 @@ macosx_register_exception_handler ()
 /* This is #define'd by Boehm GC to _GC_dlopen. */
 #undef dlopen
 
+void* dlopen(const char* path, int mode);
+
 void
 mono_runtime_install_handlers (void)
 {
index f1bcea88166f58a16281e7d63577d7467a2af4d8..2da4058d2985e3f1e18efe9efef8799323400984 100644 (file)
@@ -1937,6 +1937,8 @@ mono_setup_altstack (MonoJitTlsData *tls)
        sa.ss_flags = SS_ONSTACK;
 #endif
        g_assert (sigaltstack (&sa, NULL) == 0);
+
+       mono_gc_register_altstack ((char*)tls->stack_ovf_guard_base + tls->stack_ovf_guard_size, (char*)staddr + stsize - ((char*)tls->stack_ovf_guard_base + tls->stack_ovf_guard_size), tls->signal_stack, tls->signal_stack_size);
 }
 
 void
index dae43f06b77a75ebf602244ca16f36f29dd4004f..2c4e80782ff39321df53be457883452c18282c47 100644 (file)
@@ -4589,7 +4589,7 @@ mono_llvm_emit_call (MonoCompile *cfg, MonoCallInst *call)
                switch (ainfo->storage) {
                case LLVMArgInIReg:
                case LLVMArgInFPReg: {
-                       MonoType *t = (sig->hasthis && i == 0) ? &mono_defaults.int_class->byval_arg : sig->params [i - sig->hasthis];
+                       MonoType *t = (sig->hasthis && i == 0) ? &mono_get_intptr_class ()->byval_arg : sig->params [i - sig->hasthis];
 
                        if (!t->byref && (t->type == MONO_TYPE_R8 || t->type == MONO_TYPE_R4)) {
                                MONO_INST_NEW (cfg, ins, OP_FMOVE);
index ce973673b167130b3c3568526ac7985e724a7f9e..aa99f26c8d3968c9c109a766a2656089de0c0b63 100644 (file)
@@ -7,6 +7,11 @@
 int mono_llvm_load (const char* bpath) MONO_INTERNAL;
 
 #ifdef MONO_LLVM_IN_MINI
+
+#ifdef __MACH__
+#include <mach-o/dyld.h>
+#endif
+
 typedef void (*MonoLLVMVoidFunc)(void);
 typedef void (*MonoLLVMCFGFunc)(MonoCompile *cfg);
 typedef void (*MonoLLVMEmitCallFunc)(MonoCompile *cfg, MonoCallInst *call);
@@ -91,16 +96,31 @@ mono_llvm_load (const char* bpath)
        char buf [4096];
        int binl;
        binl = readlink ("/proc/self/exe", buf, sizeof (buf)-1);
+#ifdef __MACH__
+       if (binl == -1) {
+               uint32_t bsize = sizeof (buf);
+               if (_NSGetExecutablePath (buf, &bsize) == 0) {
+                       binl = strlen (buf);
+               }
+       }
+#endif
        if (binl != -1) {
                char *base;
                char *name;
                buf [binl] = 0;
                base = g_path_get_dirname (buf);
                name = g_strdup_printf ("%s/.libs", base);
-               g_free (base);
                err = NULL;
                llvm_lib = try_llvm_load (name, &err);
                g_free (name);
+               if (!llvm_lib) {
+                       char *newbase = g_path_get_dirname (base);
+                       name = g_strdup_printf ("%s/lib", newbase);
+                       err = NULL;
+                       llvm_lib = try_llvm_load (name, &err);
+                       g_free (name);
+               }
+               g_free (base);
        }
        if (!llvm_lib) {
                llvm_lib = try_llvm_load (NULL, &err);
index 67fbe4b44a81d677838d440aefe18a5aabf3f47f..25984f8b9824be16cbffa1572277a691fe1678a0 100644 (file)
@@ -4518,7 +4518,7 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
 
                /* floating point opcodes */
                case OP_R8CONST: {
-                       if (*((float *) ins->inst_p0) == 0) {
+                       if (*((double *) ins->inst_p0) == 0) {
                                s390_lzdr (code, ins->dreg);
                        } else {
                                s390_basr  (code, s390_r13, 0);
index f93e9bcefb8827927e1f5623b48c940e29f9a730..1d5be3190da6ae669686d365b8226e45ef936234 100644 (file)
@@ -92,6 +92,24 @@ typedef struct {
 #define mono_add_unwind_op_same_value(op_list,code,buf,reg) do { (op_list) = g_slist_append ((op_list), mono_create_unwind_op ((code) - (buf), DW_CFA_same_value, (reg), 0)); } while (0)
 #define mono_add_unwind_op_offset(op_list,code,buf,reg,offset) do { (op_list) = g_slist_append ((op_list), mono_create_unwind_op ((code) - (buf), DW_CFA_offset, (reg), (offset))); } while (0)
 
+/* Pointer Encoding in the .eh_frame */
+enum {
+       DW_EH_PE_absptr = 0x00,
+       DW_EH_PE_omit = 0xff,
+
+       DW_EH_PE_udata4 = 0x03,
+       DW_EH_PE_sdata4 = 0x0b,
+       DW_EH_PE_sdata8 = 0x0c,
+
+       DW_EH_PE_pcrel = 0x10,
+       DW_EH_PE_textrel = 0x20,
+       DW_EH_PE_datarel = 0x30,
+       DW_EH_PE_funcrel = 0x40,
+       DW_EH_PE_aligned = 0x50,
+
+       DW_EH_PE_indirect = 0x80
+};
+
 int
 mono_hw_reg_to_dwarf_reg (int reg) MONO_INTERNAL;
 
index fe68ceede1e778944aca2b2a3eb7ee7df40b640c..f5d39433f4b7fa79c6aafa5bc916521a7af26047 100644 (file)
@@ -2285,11 +2285,12 @@ mono_x86_have_tls_get (void)
 #ifdef __APPLE__
        static gboolean have_tls_get = FALSE;
        static gboolean inited = FALSE;
+       guint32 *ins;
 
        if (inited)
                return have_tls_get;
 
-       guint32 *ins = (guint32*)pthread_getspecific;
+       ins = (guint32*)pthread_getspecific;
        /*
         * We're looking for these two instructions:
         *
index 56ba2485e8e8c451ba0ca9b0b235f41abb5ef833..5805f5e7ebd790c98dac6649a62a8102980e01d5 100644 (file)
@@ -238,7 +238,9 @@ typedef struct {
 
 #define MONO_ARCH_HAVE_DECOMPOSE_LONG_OPTS 1
 
+#ifndef TARGET_WIN32
 #define MONO_ARCH_AOT_SUPPORTED 1
+#endif
 
 #define MONO_ARCH_ENABLE_MONITOR_IL_FASTPATH 1
 
index 7e10007aa057ac600303dc4a5e33e101818ed37c..cae58bd73b13f571bfb3e04abb68cd29afc49828 100644 (file)
@@ -3171,10 +3171,16 @@ mono_resolve_patch_target (MonoMethod *method, MonoDomain *domain, guint8 *code,
        case MONO_PATCH_INFO_ICALL_ADDR:
                /* run_cctors == 0 -> AOT */
                if (patch_info->data.method->flags & METHOD_ATTRIBUTE_PINVOKE_IMPL) {
+                       const char *exc_class;
+                       const char *exc_arg;
+
                        if (run_cctors) {
-                               target = mono_lookup_pinvoke_call (patch_info->data.method, NULL, NULL);
-                               if (!target)
+                               target = mono_lookup_pinvoke_call (patch_info->data.method, &exc_class, &exc_arg);
+                               if (!target) {
+                                       if (mono_aot_only)
+                                               mono_raise_exception (mono_exception_from_name_msg (mono_defaults.corlib, "System", exc_class, exc_arg));
                                        g_error ("Unable to resolve pinvoke method '%s' Re-run with MONO_LOG_LEVEL=debug for more information.\n", mono_method_full_name (patch_info->data.method, TRUE));
+                               }
                        } else {
                                target = NULL;
                        }
@@ -6473,6 +6479,7 @@ mini_init (const char *filename, const char *runtime_version)
        if (mono_aot_only) {
                /* This helps catch code allocation requests */
                mono_code_manager_set_read_only (domain->code_mp);
+               mono_marshal_use_aot_wrappers (TRUE);
        }
 
 #ifdef MONO_ARCH_HAVE_IMT
index 55b938b9afa309476266ee7ddf4bd53eee0d79f2..11caa60166c115018f96ac558e85ac15bbdab1c2 100644 (file)
@@ -613,24 +613,6 @@ decode_cie_op (guint8 *p, guint8 **endp)
        *endp = p;
 }
 
-/* Pointer Encoding in the .eh_frame */
-enum {
-       DW_EH_PE_absptr = 0x00,
-       DW_EH_PE_omit = 0xff,
-
-       DW_EH_PE_udata4 = 0x03,
-       DW_EH_PE_sdata4 = 0x0b,
-       DW_EH_PE_sdata8 = 0x0c,
-
-       DW_EH_PE_pcrel = 0x10,
-       DW_EH_PE_textrel = 0x20,
-       DW_EH_PE_datarel = 0x30,
-       DW_EH_PE_funcrel = 0x40,
-       DW_EH_PE_aligned = 0x50,
-
-       DW_EH_PE_indirect = 0x80
-};
-
 static gint64
 read_encoded_val (guint32 encoding, guint8 *p, guint8 **endp)
 {
index a2e9c7f2390642c405e83ad45cc0d35423f74f0b..621986f55bd219784a1bedde0e30dec1e5cd657e 100644 (file)
@@ -10,5 +10,6 @@
 /*.so
 /*.exe
 /*.mdb
+/*.mlpd
 /TAGS
 /mprof-report
index cc3d41474d0ea8d252cc34a6ff4ce602efd7b94d..58c0b98da2479de9d324a3e03c141416a5bf32c3 100644 (file)
@@ -16,6 +16,7 @@
 #include <stdlib.h>
 #include <string.h>
 #include <assert.h>
+#include <glib.h>
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>
 #endif
@@ -1858,6 +1859,15 @@ helper_thread (void* arg)
                tv.tv_sec = 1;
                tv.tv_usec = 0;
                len = select (max_fd + 1, &rfds, NULL, NULL, &tv);
+               
+               if (len < 0) {
+                       if (errno == EINTR)
+                               continue;
+                       
+                       g_warning ("Error in proflog server: %s", strerror (errno));
+                       return NULL;
+               }
+               
                if (FD_ISSET (prof->pipes [0], &rfds)) {
                        char c;
                        int r = read (prof->pipes [0], &c, 1);
index 97ef3f5ff8a7c0817947fba206315a88328af372..f1776e8458c0f16028557363972ba97fcd6aefec 100644 (file)
@@ -238,6 +238,7 @@ BASE_TEST_CS_SRC=           \
        finalizer-abort.cs      \
        finalizer-exception.cs  \
        finalizer-exit.cs       \
+       finalizer-thread.cs     \
        main-exit.cs    \
        main-returns-abort-resetabort.cs        \
        main-returns-background-abort-resetabort.cs     \
@@ -379,7 +380,9 @@ BASE_TEST_CS_SRC=           \
        bug-696593.cs   \
        bug-705140.cs   \
        bug-1147.cs     \
-       bug-bxc-795.cs
+       mono-path.cs    \
+       bug-bxc-795.cs  \
+       bug-3903.cs
 
 TEST_CS_SRC_DIST=      \
        $(BASE_TEST_CS_SRC)     \
@@ -390,6 +393,7 @@ TEST_CS_SRC_DIST=   \
 TEST_CS_SRC_GEN = \
        runtime-invoke.gen.cs \
        imt_big_iface_test.cs
+       
 
 if AMD64
 TEST_CS_SRC = $(BASE_TEST_CS_SRC) $(TEST_CS_SRC_GEN) async-exc-compilation.cs finally_guard.cs
@@ -747,14 +751,20 @@ sgen-regular-tests: $(SGEN_TESTS)
                echo "Testing $$fn ...";        \
                MONO_GC_PARAMS=major=marksweep-par MONO_ENV_OPTIONS="--gc=sgen" $(RUNTIME) $$fn > $$fn.stdout || exit 1;        \
                MONO_ENV_OPTIONS="--gc=sgen"                                    $(RUNTIME) $$fn > $$fn.stdout || exit 1;        \
+               MONO_GC_PARAMS=major=marksweep-par,minor=split MONO_ENV_OPTIONS="--gc=sgen" $(RUNTIME) $$fn > $$fn.stdout || exit 1;    \
+               MONO_GC_PARAMS=minor=split MONO_ENV_OPTIONS="--gc=sgen"                     $(RUNTIME) $$fn > $$fn.stdout || exit 1;    \
+               MONO_GC_PARAMS=major=marksweep,concurrent-sweep MONO_ENV_OPTIONS="--gc=sgen" $(RUNTIME) $$fn > $$fn.stdout || exit 1;   \
+               MONO_GC_PARAMS=minor=split,major=marksweep,concurrent-sweep MONO_ENV_OPTIONS="--gc=sgen" $(RUNTIME) $$fn > $$fn.stdout || exit 1;       \
        done
 
 
 sgen-tests: sgen-regular-tests sgen-bridge.exe sgen-bridge-major-fragmentation.exe
        @echo "Testing sgen-bridge.exe ...";    \
        MONO_GC_PARAMS=bridge=Bridge MONO_ENV_OPTIONS="--gc=sgen" $(RUNTIME) sgen-bridge.exe > sgen-bridge.exe.stdout 2> sgen-bridge.exe.stderr
+       MONO_GC_PARAMS=bridge=Bridge,minor=split MONO_ENV_OPTIONS="--gc=sgen" $(RUNTIME) sgen-bridge.exe > sgen-bridge.exe.stdout 2> sgen-bridge.exe.stderr
        @echo "Testing sgen-bridge-major-fragmentation.exe ...";        \
        MONO_GC_PARAMS=bridge=Bridge MONO_ENV_OPTIONS="--gc=sgen" $(RUNTIME) sgen-bridge-major-fragmentation.exe > sgen-bridge-major-fragmentation.exe.stdout 2> sgen-bridge-major-fragmentation.exe.stderr
+       MONO_GC_PARAMS=bridge=Bridge,minor=split MONO_ENV_OPTIONS="--gc=sgen" $(RUNTIME) sgen-bridge-major-fragmentation.exe > sgen-bridge-major-fragmentation.exe.stdout 2> sgen-bridge-major-fragmentation.exe.stderr
 
 
 # Generated tests for runtime invoke
@@ -880,6 +890,9 @@ generic-delegate2-lib.2.dll : generic-delegate2-lib.2.il
 generic-delegate2.2.exe : generic-delegate2.2.cs generic-delegate2-lib.2.dll
        $(MCS) -r:generic-delegate2-lib.2.dll -out:$@ $(srcdir)/generic-delegate2.2.cs
 
+bug-3903.exe: bug-3903.cs
+       $(MCS) -sdk:2 $(srcdir)/bug-3903.cs -out:$@
+
 gshared: test-generic-sharing
 
 gshared-aot:
diff --git a/mono/tests/bug-3903.cs b/mono/tests/bug-3903.cs
new file mode 100644 (file)
index 0000000..ad3a00d
--- /dev/null
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+
+struct Foo
+{
+}
+
+
+public class TestClass
+{
+    public static int Main ()
+    {
+        Foo[][] array = new Foo[][] { new Foo[0] };
+               IEnumerable<object> aa1 = array;
+               foreach (var x in aa1) Console.WriteLine (x);
+               aa1.GetEnumerator ().ToString ();
+
+               int[] array2 = new int[10];
+               IEnumerable<uint> aa2 = (uint[])(object)array2;
+               foreach (var x in aa2) Console.WriteLine (x);
+               aa2.GetEnumerator ().ToString ();
+
+        // The next line will crash
+        List<object> list = array.Cast<object>().Select((arg) => arg).ToList();
+               return 0;
+    }
+}
index b5be6e8de5445f524f0bf95008d9e1fae2182f4e..08e9880f87716ca673fa4e96456c38241475f9f9 100644 (file)
@@ -8,6 +8,7 @@ using System;
 using System.Runtime.CompilerServices;
 using System.Runtime.InteropServices;
 
+
 public class Tests
 {
 
@@ -473,6 +474,11 @@ public class Tests
                        if (TestITest (itest) != 0)
                                return 175;
 
+                       itest = (ITest)System.Activator.CreateInstance (typeof(TestActivatorClass));
+
+                       if (TestITest (itest) != 0)
+                               return 176;
+
                        #endregion // Runtime Callable Wrapper Tests
 
                        #region COM Callable Wrapper Tests
@@ -653,6 +659,13 @@ public class Tests
                                }
                        }
                        #endregion // SafeArray Tests
+
+                       #region COM Visible Test
+                       TestVisible test_vis = new TestVisible();
+                       IntPtr pDisp = Marshal.GetIDispatchForObject(test_vis);
+                       if (pDisp == IntPtr.Zero)
+                               return 200;
+                       #endregion 
                }
 
         return 0;
@@ -803,6 +816,20 @@ public class Tests
                }
        }
 
+       [System.Runtime.InteropServices.GuidAttribute ("00000000-0000-0000-0000-000000000003")]
+       public class TestActivatorClass : _TestClass
+       {
+               static TestActivatorClass ()
+               {
+                       ExtensibleClassFactory.RegisterObjectCreationCallback (new ObjectCreationDelegate (CreateObject)); ;
+               }
+               private static System.IntPtr CreateObject (System.IntPtr aggr)
+               {
+                       IntPtr pUnk3;
+                       mono_test_marshal_com_object_create (out pUnk3);
+                       return pUnk3;
+               }
+       }
 
        delegate void SByteInDelegate (sbyte val);
        delegate void ByteInDelegate (byte val);
@@ -1214,3 +1241,7 @@ public class Tests
                return 0;
        }
 }
+
+public class TestVisible
+{
+}
index 595bdebe3af3d5e1cf372e0ab1434bb9b00e1869..d11e1696f1487540efebaa76a63c95f769e0e5c1 100644 (file)
@@ -1,39 +1,24 @@
-
-using System; 
-using System.Collections; 
+using System;
 using System.Threading;
 
-public class foo  { 
-       public static LocalDataStoreSlot dataslot = Thread.AllocateDataSlot();
-       public static int final_count=0;
+public class FinalizerException {
+       ~FinalizerException () {
+               throw new Exception ();
+       }
 
-       ~foo() { 
-               // Demonstrate that this is still the same thread
-               string ID=(string)Thread.GetData(dataslot);
-               if(ID==null) {
-                       Console.WriteLine("Set ID: foo");
-                       Thread.SetData(dataslot, "foo");
-               }
+       public static int Main () { 
+               AppDomain.CurrentDomain.UnhandledException += (sender, args) => {
+                       Console.WriteLine ("caught");
+                       Environment.Exit (0);
+               };
 
-               // Don't run forever
-               if(final_count++>10) {
-                       Environment.Exit(0);
-               }
+               new FinalizerException ();
 
-               Console.WriteLine("finalizer thread ID: {0}", (string)Thread.GetData(dataslot));
-               throw new SystemException("wibble");
-       } 
+               GC.Collect ();
+               GC.WaitForPendingFinalizers ();
 
-       public static int Main() { 
-               ArrayList list = new ArrayList (); 
-               Thread.SetData(dataslot, "ID is wibble");
-               Environment.ExitCode = 2;
-               while(true) { 
-                       foo instance = new foo(); 
-                       list.Add (new WeakReference(instance)); 
-                       Thread.Sleep (0);
-               }
-               return 1;
-       } 
-} 
+               Thread.Sleep (Timeout.Infinite); // infinite wait so we don't race against the unhandled exception callback
 
+               return 2;
+       }
+}
diff --git a/mono/tests/finalizer-thread.cs b/mono/tests/finalizer-thread.cs
new file mode 100644 (file)
index 0000000..afcbaf1
--- /dev/null
@@ -0,0 +1,41 @@
+
+using System; 
+using System.Collections; 
+using System.Threading;
+
+public class foo  { 
+       public static LocalDataStoreSlot dataslot = Thread.AllocateDataSlot();
+       public static int final_count=0;
+
+       ~foo() { 
+               // Demonstrate that this is still the same thread
+               string ID=(string)Thread.GetData(dataslot);
+               if(ID==null) {
+                       Console.WriteLine("Set ID: foo");
+                       Thread.SetData(dataslot, "foo");
+               }
+
+               // Don't run forever
+               if(final_count++>10) {
+                       Environment.Exit(0);
+               }
+
+               Console.WriteLine("finalizer thread ID: {0}", (string)Thread.GetData(dataslot));
+
+               if ((string)Thread.GetData(dataslot) != "foo")
+                       throw new Exception ();
+       } 
+
+       public static int Main() { 
+               ArrayList list = new ArrayList (); 
+               Thread.SetData(dataslot, "ID is wibble");
+               Environment.ExitCode = 2;
+               while(true) { 
+                       foo instance = new foo(); 
+                       list.Add (new WeakReference(instance)); 
+                       Thread.Sleep (0);
+               }
+               return 1;
+       } 
+} 
+
index 89eb310c73ee7a78a49b73a8606027fa1537f032..4b3f431467fad705d9afb10b9e7370f6387efea6 100644 (file)
@@ -1,38 +1,64 @@
 using System;
 using System.Threading;
-using System.Collections;
-
-class T {
+using System.Linq;
 
+public class Tests
+{
        static bool finished = false;
 
-       static void segv () {
-               while (true) {
-                       if (finished)
-                               break;
+       static void fault () {
+               while (!finished) {
+                       object o = null;
                        try {
-                               object o = null;
                                o.ToString ();
-                       } catch (NullReferenceException) {
+                       } catch {
                        }
                }
        }
 
-       static void Main (string[] args) {
-               /* Test for running a GC while executing a SIGSEGV handler on an altstack */
-               Thread t = new Thread (delegate () { 
-                               segv ();
-                       });
+       static void gc (int niter) {
+               int i = 0;
+               while (i < niter) {
+                       i ++;
+                       if (i % 100 == 0)
+                               Console.Write (".");
+                       GC.Collect ();
+               }
+               finished = true;
+               Console.WriteLine ();
+       }
+
+       static void test (bool main, int niter) {
+               finished = false;
 
-               t.Start ();
+               if (main) {
+                       var t = new Thread (delegate () {
+                                       gc (niter);
+                               });
+                       t.Start ();
 
-               for (int i = 0; i < 100000; ++i) {
-                       new ArrayList ();
+                       fault ();
+               } else {
+                       var t = new Thread (delegate () {
+                                       fault ();
+                               });
+                       t.Start ();
+
+                       gc (niter);
                }
+       }
 
-               finished = true;
+       public static void Main (String[] args) {
+               /* Test for running a GC while executing a SIGSEGV handler on an altstack */
+               int niter;
+
+               if (args.Length > 0)
+                       niter = Int32.Parse (args [0]);
+               else
+                       niter = 1000;
 
-               t.Join ();
+               test (false, niter);
+               test (true, niter);
        }
 }
 
index d710537588dff8e1619671ee57757fddb6f03527..21c30f3ea52ad8cc5b06275e8e796c36ae0afe20 100644 (file)
@@ -1096,6 +1096,22 @@ mono_test_marshal_stringbuilder_out_unicode (gunichar2 **s)
        return 0;
 }
 
+LIBTEST_API int STDCALL
+mono_test_marshal_stringbuilder_ref (char **s)
+{
+       const char m[] = "This is my message.  Isn't it nice?";
+       char *str;
+
+       if (strcmp (*s, "ABC"))
+               return 1;
+
+       str = marshal_alloc (strlen (m) + 1);
+       memcpy (str, m, strlen (m) + 1);
+       
+       *s = str;
+       return 0;
+}
+
 typedef struct {
 #ifndef __GNUC__
     char a;
@@ -1408,6 +1424,8 @@ string_marshal_test2 (char **str)
        if (strcmp (*str, "TEST1"))
                return -1;
 
+       *str = marshal_strdup ("TEST2");
+
        return 0;
 }
 
@@ -3276,7 +3294,7 @@ mono_test_marshal_ccw_itest (MonoComObject *pUnk)
 /* thunks.cs:TestStruct */
 typedef struct _TestStruct {
        int A;
-       double B ALIGN(8);  /* align according to  mono's struct layout */
+       double B;
 } TestStruct;
 
 /* Searches for mono symbols in all loaded modules */
diff --git a/mono/tests/mono-path.cs b/mono/tests/mono-path.cs
new file mode 100644 (file)
index 0000000..8f60e11
--- /dev/null
@@ -0,0 +1,47 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Diagnostics;
+using System.Runtime.InteropServices;
+
+public class Program
+{
+       static bool failure;
+
+       [DllImport ("__Internal")]
+       static extern string mono_path_canonicalize (string input);
+
+       static void CanonicalizeAssert (string input, string expected)
+       {
+               string actual = mono_path_canonicalize (input);
+               if (expected != actual) {
+                       failure = true;
+                       Console.WriteLine ("ERROR: Expected canonicalization of '{0}' to be '{1}', but it was '{2}'.", input, expected, actual);
+               } else {
+                       Console.WriteLine ("SUCCESS: Canonicalization of '{0}' => '{1}'", input, actual);
+               }
+       }
+       
+       static void CanonicalizeTest ()
+       {
+               bool isWindows = !(((int)Environment.OSVersion.Platform == 4) || ((int)Environment.OSVersion.Platform == 128));
+
+               if (!isWindows) {
+                       CanonicalizeAssert ("", Environment.CurrentDirectory);
+                       CanonicalizeAssert ("/", "/");
+                       CanonicalizeAssert ("/..", "/");
+                       CanonicalizeAssert ("/foo", "/foo");
+                       CanonicalizeAssert ("/foo/././", "/foo");
+                       CanonicalizeAssert ("/../../foo", "/foo");
+                       CanonicalizeAssert ("/foo/", "/foo");
+                       CanonicalizeAssert ("/foo/../../../", "/");
+                       CanonicalizeAssert ("/foo/../../..", "/");
+               }
+       }
+       
+       public static int Main()
+       {
+               CanonicalizeTest ();
+               return failure ? 1 : 0;
+       }
+}
\ No newline at end of file
index 826b91e1f8f7d4b38f48a062cf624f18b42ed516..d600170061792bf6acad84010be8ce204d6a6f4a 100644 (file)
@@ -288,6 +288,9 @@ public class Tests {
        [DllImport ("libtest", EntryPoint="mono_test_marshal_stringbuilder_out")]
        public static extern void mono_test_marshal_stringbuilder_out (out StringBuilder sb);
 
+       [DllImport ("libtest", EntryPoint="mono_test_marshal_stringbuilder_ref")]
+       public static extern int mono_test_marshal_stringbuilder_ref (ref StringBuilder sb);
+
        [DllImport ("libtest", EntryPoint="mono_test_marshal_stringbuilder_out_unicode", CharSet=CharSet.Unicode)]
        public static extern void mono_test_marshal_stringbuilder_out_unicode (out StringBuilder sb);
 
@@ -816,6 +819,18 @@ public class Tests {
                return 0;
        }
 
+       public static int test_0_marshal_stringbuilder_ref () {
+               StringBuilder sb = new StringBuilder ();
+               sb.Append ("ABC");
+               int res = mono_test_marshal_stringbuilder_ref (ref sb);
+               if (res != 0)
+                       return 1;
+               
+               if (sb.ToString () != "This is my message.  Isn't it nice?")
+                       return 2;  
+               return 0;
+       }
+
        public static int test_0_marshal_empty_string_array () {
                return mono_test_marshal_empty_string_array (null);
        }
@@ -1275,7 +1290,12 @@ public class Tests {
        public static int test_0_marshal_byref_string () {
                string res = "TEST1";
 
-               return string_marshal_test2 (ref res);
+               int r = string_marshal_test2 (ref res);
+               if (r != 0)
+                       return 1;
+               if (res != "TEST2")
+                       return 2;
+               return 0;
        }
 
        public static int test_0_marshal_null_string () {
index f8df7d22b16363b407448a04dcaf0d3f6750ff18..efdff2b00fb5eec2342d73b017bdc86fbcc4c9bf 100644 (file)
@@ -198,6 +198,40 @@ public class Tests {
                return success ? 0 : 1;
        }
 
+       public static int test_0_regress_4413 () {
+               // Check that thread abort exceptions originating in another thread are not automatically rethrown
+               object o = new object ();
+               Thread t = null;
+               Action a = delegate () {
+                       t = Thread.CurrentThread;
+                       lock (o) {
+                               Monitor.Pulse (o);
+                       }
+                       while (true) {
+                               Thread.Sleep (1000);
+                       }
+               };
+               var ar = a.BeginInvoke (null, null);
+               lock (o) {
+                       Monitor.Wait (o);
+               }
+
+               t.Abort ();
+
+               try {
+                       try {
+                               a.EndInvoke (ar);
+                       } catch (ThreadAbortException) {
+                       }
+               } catch (ThreadAbortException) {
+                       // This will fail
+                       Thread.ResetAbort ();
+                       return 1;
+               }
+
+               return 0;
+       }
+
        public static void Run ()
        {
                try {
index e04c3dfe8b9f46519816c61b90b9a835e9f2c44d..88b5d25a71904ff89e0923b1b7f967034f0b3c34 100644 (file)
@@ -33,6 +33,8 @@
 
 /* For Native Client, the above is not true.  Since there is no getcwd we fill */
 /* in the file being passed in relative to '.' and don't resolve it            */
+
+/* There are a couple of tests for this method in mono/test/mono-path.cs */
 gchar *
 mono_path_canonicalize (const char *path)
 {
@@ -90,7 +92,20 @@ mono_path_canonicalize (const char *path)
 #endif
        
        if (dest != lastpos) strcpy (dest, lastpos);
-       return g_strreverse (abspath);
+       
+       g_strreverse (abspath);
+
+       /* We strip away all trailing dir separators. This is not correct for the root directory,
+        * since we'll return an empty string, so re-append a dir separator if there is none in the
+        * result */
+       if (strchr (abspath, G_DIR_SEPARATOR) == NULL) {
+               int len = strlen (abspath);
+               abspath = g_realloc (abspath, len + 2);
+               abspath [len] = G_DIR_SEPARATOR;
+               abspath [len+1] = 0;
+       }
+
+       return abspath;
 }
 
 /*
index b009fa8a6ec105f2c87b39ef3bee9ce879d53278..720ee399e49852d528596e431404a0a8e9584c98 100644 (file)
@@ -58,6 +58,7 @@ typedef struct {
        void *arg;
        MonoSemType registered;
        gboolean suspend;
+       HANDLE suspend_event;
 } ThreadStartInfo;
 
 static DWORD WINAPI
@@ -68,14 +69,19 @@ inner_start_thread (LPVOID arg)
        int post_result;
        LPTHREAD_START_ROUTINE start_func = start_info->start_routine;
        DWORD result;
+       gboolean suspend = start_info->suspend;
+       HANDLE suspend_event = start_info->suspend_event;
 
        mono_thread_info_attach (&result);
 
        post_result = MONO_SEM_POST (&(start_info->registered));
        g_assert (!post_result);
 
-       if (start_info->suspend)
-               SuspendThread (GetCurrentThread ());
+       if (suspend)
+       {
+               WaitForSingleObject (suspend_event, INFINITE); /* caller will suspend the thread before setting the event. */
+               CloseHandle (suspend_event);
+       }
 
        result = start_func (t_arg);
 
@@ -99,6 +105,12 @@ mono_threads_CreateThread (LPSECURITY_ATTRIBUTES attributes, SIZE_T stack_size,
        start_info->start_routine = start_routine;
        start_info->suspend = creation_flags & CREATE_SUSPENDED;
        creation_flags &= ~CREATE_SUSPENDED;
+       if (start_info->suspend)
+       {
+               start_info->suspend_event = CreateEvent (NULL, TRUE, FALSE, NULL);
+               if (!start_info->suspend_event)
+                       return NULL;
+       }
 
        result = CreateThread (attributes, stack_size, inner_start_thread, start_info, creation_flags, thread_id);
 
@@ -106,7 +118,14 @@ mono_threads_CreateThread (LPSECURITY_ATTRIBUTES attributes, SIZE_T stack_size,
                while (MONO_SEM_WAIT (&(start_info->registered)) != 0) {
                        /*if (EINTR != errno) ABORT("sem_wait failed"); */
                }
+               if (start_info->suspend)
+               {
+                       g_assert (SuspendThread (result) != (DWORD)-1);
+                       SetEvent (start_info->suspend_event);
+               }
        }
+       else if (start_info->suspend)
+               CloseHandle (start_info->suspend_event);
        MONO_SEM_DESTROY (&(start_info->registered));
        g_free (start_info);
        return result;
index fc9ad206c83b39782ef6ac3279b008de5916eff9..708e485017c1fce347a87ce877fa3937a6f76399 100644 (file)
@@ -16,6 +16,7 @@
  * OF THIS SOFTWARE OR ITS FITNESS FOR ANY PARTICULAR PURPOSE.
  *
  ***************************************************************/
+#include "config.h"
 #include "strtod.h"
 #include <glib.h>
 #define freedtoa __freedtoa
  * #define NO_ERRNO if strtod should not assign errno = ERANGE when
  *     the result overflows to +-Infinity or underflows to 0.
  */
-#if defined(i386) || defined(mips) && defined(MIPSEL) || defined (__arm__)
+#if defined(TARGET_X86) || defined(mips) && defined(MIPSEL) || defined (__arm__)
 
 #   define IEEE_8087
 
-#elif defined(__x86_64__) || defined(__alpha__)
+#elif defined(TARGET_AMD64) || defined(__alpha__)
 
 #   define IEEE_8087
 
index 53123b6b7e878bf4ab959ce0457b9fcfa5bdce94..510a508b239a060dd63d1295a212db8e3d531206 100644 (file)
@@ -440,6 +440,7 @@ class MsbuildGenerator {
                        StrongNameKeyContainer = value;
                        return true;
                case "/delaysign+":
+               case "/delaysign":
                        StrongNameDelaySign = true;
                        return true;
                case "/delaysign-":
index 642cee55928fde950047bfd95ad13204dec39682..0659e5398b6042dfd47344c9568db5bc0a4fd67b 100644 (file)
@@ -53,7 +53,7 @@
     <project dir="class/Mono.Security" library="Mono.Security-basic">
       <boot>true</boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:BOOTSTRAP_BASIC -nowarn:1699 /noconfig -r:System.dll -unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:BOOTSTRAP_BASIC -nowarn:1699 /noconfig -r:System.dll -unsafe -nowarn:1030</flags>
       <output>Mono.Security.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/basic/tmp/Mono.Security.dll</library_output>
@@ -73,7 +73,7 @@
     <project dir="class/corlib" library="corlib-build">
       <boot>true</boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -debug /noconfig -resource:resources/collation.core.bin -resource:resources/collation.tailoring.bin -resource:resources/collation.cjkCHS.bin -resource:resources/collation.cjkCHT.bin -resource:resources/collation.cjkJA.bin -resource:resources/collation.cjkKO.bin -resource:resources/collation.cjkKOlv2.bin --runtime:v4</flags>
+      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build /noconfig -resource:resources/collation.core.bin -resource:resources/collation.tailoring.bin -resource:resources/collation.cjkCHS.bin -resource:resources/collation.cjkCHT.bin -resource:resources/collation.cjkJA.bin -resource:resources/collation.cjkKO.bin -resource:resources/collation.cjkKOlv2.bin --runtime:v4</flags>
       <output>mscorlib.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/build/tmp/mscorlib.dll</library_output>
@@ -83,7 +83,7 @@
     <project dir="class/System" library="System-build">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll -debug /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -d:XML_DEP -r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -d:XML_DEP -r:System.Xml.dll</flags>
       <output>System.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/build/tmp/System.dll</library_output>
@@ -93,7 +93,7 @@
     <project dir="class/System.XML" library="System.Xml-build">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642</flags>
       <output>System.Xml.dll</output>
       <built_sources>System.Xml.XPath/Parser.cs Mono.Xml.Xsl/PatternParser.cs Mono.Xml.Xsl/PatternTokenizer.cs</built_sources>
       <library_output>./../../class/lib/build/tmp/System.Xml.dll</library_output>
     <project dir="class/System" library="System-build">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll -debug /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -d:XML_DEP -r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -d:XML_DEP -r:System.Xml.dll</flags>
       <output>System.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/build/tmp/System.dll</library_output>
     <project dir="class/Mono.Security" library="Mono.Security-build">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll -debug /noconfig -r:System.dll -unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll /noconfig -r:System.dll -unsafe -nowarn:1030</flags>
       <output>Mono.Security.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/build/tmp/Mono.Security.dll</library_output>
     <project dir="class/Mono.Posix" library="Mono.Posix-build">
       <boot>true</boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /nowarn:0618,612</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll /noconfig /unsafe /r:mscorlib.dll /r:System.dll /nowarn:0618,612</flags>
       <output>Mono.Posix.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/build/Mono.Posix.dll</library_output>
     <project dir="class/System.Core" library="System.Core-build">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll -debug /noconfig -d:INSIDE_SYSCORE -d:LIBC /r:mscorlib.dll /r:System.dll -unsafe -d:NET_3_5 -nowarn:1720 -d:CODEPLEX_40 -r:Mono.Posix.dll -unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll /noconfig -d:INSIDE_SYSCORE -d:LIBC /r:mscorlib.dll /r:System.dll -unsafe -d:NET_3_5 -nowarn:1720 -d:CODEPLEX_40 -r:Mono.Posix.dll -unsafe</flags>
       <output>System.Core.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/build/System.Core.dll</library_output>
     <project dir="mcs" library="mcs-build">
       <boot></boot>
       <mcs>MONO_PATH=./../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -lib:./../class/lib/build -d:STATIC,NO_SYMBOL_WRITER -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../class/lib/build -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -lib:./../class/lib/build -debug -d:STATIC,NO_SYMBOL_WRITER -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../class/lib/build -r:mscorlib.dll /noconfig</flags>
       <output>mcs.exe</output>
       <built_sources>cs-parser.cs</built_sources>
       <library_output>mcs.exe</library_output>
     <project dir="tools/gacutil" library="gacutil-build">
       <boot></boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -r:Mono.Security.dll -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -r:Mono.Security.dll -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll /noconfig</flags>
       <output>gacutil.exe</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/build/gacutil.exe</library_output>
     <project dir="tools/culevel" library="culevel-build">
       <boot></boot>
       <mcs>MONO_PATH=./../../class/lib/basic: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/basic/basic.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/build -r:mscorlib.dll /noconfig</flags>
       <output>culevel.exe</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/build/culevel.exe</library_output>
     <project dir="class/corlib" library="corlib-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -debug -r:./../../class/lib/net_2_0/mscorlib.dll -debug+ -debug:full -nowarn:168,219,618,672 -unsafe -r:./../../class/lib/net_2_0/Mono.Posix.dll -define:MONO_DATACONVERTER_STATIC_METHODS</flags>
+      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -debug -r:./../../class/lib/net_2_0/mscorlib.dll -debug+ -debug:full -nowarn:168,219,618,672 -unsafe -r:Mono.Posix.dll -r:System.Core.dll -define:MONO_DATACONVERTER_STATIC_METHODS</flags>
       <output>corlib_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>corlib_test_net_2_0.dll</library_output>
     <project dir="class/System" library="System-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
       <output>System_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System_test_net_2_0.dll</library_output>
     <project dir="class/System.XML" library="System.Xml-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -define:CONFIGURATION_DEP -r:System.Configuration.dll -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -define:CONFIGURATION_DEP -r:System.Configuration.dll -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data.dll -r:System.Core.dll -r:System.Configuration</flags>
       <output>System.Xml_test_net_2_0.dll</output>
       <built_sources>System.Xml.XPath/Parser.cs Mono.Xml.Xsl/PatternParser.cs Mono.Xml.Xsl/PatternTokenizer.cs</built_sources>
       <library_output>System.Xml_test_net_2_0.dll</library_output>
     <project dir="class/Mono.Security" library="Mono.Security-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -unsafe -nowarn:1030</flags>
       <output>Mono.Security.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/tmp/Mono.Security.dll</library_output>
     <project dir="class/Mono.Security" library="Mono.Security-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.Security.dll -r:System.dll -unsafe -nowarn:169,219,618,672</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.Security.dll -r:System.dll -unsafe -nowarn:1030 -nowarn:169,219,618,672</flags>
       <output>Mono.Security_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Security_test_net_2_0.dll</library_output>
     <project dir="class/System" library="System-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
       <output>System_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System_test_net_2_0.dll</library_output>
     <project dir="class/System.Configuration" library="System.Configuration-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll -nowarn:618</flags>
       <output>System.Configuration.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/tmp/System.Configuration.dll</library_output>
     <project dir="class/System.Configuration" library="System.Configuration-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Configuration.dll -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Configuration.dll -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll -nowarn:618</flags>
       <output>System.Configuration_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Configuration_test_net_2_0.dll</library_output>
     <project dir="class/System" library="System-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
       <output>System_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System_test_net_2_0.dll</library_output>
     <project dir="class/System.XML" library="System.Xml-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -define:CONFIGURATION_DEP -r:System.Configuration.dll -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -define:CONFIGURATION_DEP -r:System.Configuration.dll -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data.dll -r:System.Core.dll -r:System.Configuration</flags>
       <output>System.Xml_test_net_2_0.dll</output>
       <built_sources>System.Xml.XPath/Parser.cs Mono.Xml.Xsl/PatternParser.cs Mono.Xml.Xsl/PatternTokenizer.cs</built_sources>
       <library_output>System.Xml_test_net_2_0.dll</library_output>
     <project dir="class/System.Data" library="System.Data-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Data.dll -nowarn:649 -unsafe -r:mscorlib.dll -r:./../../class/lib/net_2_0/System.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -r:Mono.Data.Tds.dll -r:System.Configuration.dll -r:System.Transactions.dll -nowarn:618,169,612,219,168</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Data.dll -nowarn:649 -unsafe -r:mscorlib.dll -r:./../../class/lib/net_2_0/System.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -r:Mono.Data.Tds.dll -r:System.Configuration.dll -r:System.Transactions.dll -r:System.Core.dll -nowarn:618,169,612,219,168</flags>
       <output>System.Data_test_net_2_0.dll</output>
       <built_sources>Mono.Data.SqlExpressions/Parser.cs</built_sources>
       <library_output>System.Data_test_net_2_0.dll</library_output>
     <project dir="class/Mono.WebBrowser" library="Mono.WebBrowser-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -debug+ -nowarn:108</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -warn:1</flags>
       <output>Mono.WebBrowser.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/Mono.WebBrowser.dll</library_output>
     <project dir="class/Managed.Windows.Forms" library="System.Windows.Forms-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Drawing.dll /r:Accessibility.dll /r:System.Data.dll /r:Mono.Posix.dll /r:Mono.WebBrowser @System.Windows.Forms.dll.resources -debug -nowarn:618,612,809 /r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Drawing.dll /r:Accessibility.dll /r:System.Data.dll /r:Mono.Posix.dll /r:Mono.WebBrowser /r:System.Configuration.dll @System.Windows.Forms.dll.resources -nowarn:618,612,809</flags>
       <output>System.Windows.Forms.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/System.Windows.Forms.dll</library_output>
     <project dir="class/Managed.Windows.Forms" library="System.Windows.Forms-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Windows.Forms.dll /r:System.Data.dll /r:System.Drawing.dll /r:Accessibility.dll -resource:Test/resources/a.cur,a.cur -resource:Test/resources/32x32.ico,32x32.ico -nowarn:618,612</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Windows.Forms.dll /r:System.Data.dll /r:System.Drawing.dll /r:Accessibility.dll -r:System.dll -r:System.Xml.dll -resource:Test/resources/a.cur,a.cur -resource:Test/resources/32x32.ico,32x32.ico -nowarn:618,612</flags>
       <output>System.Windows.Forms_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Windows.Forms_test_net_2_0.dll</library_output>
     <project dir="class/System.Design" library="System.Design-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Design.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Design.dll /r:System.dll</flags>
       <output>System.Design_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Design_test_net_2_0.dll</library_output>
     <project dir="class/PEAPI" library="PEAPI-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll -nowarn:414,618</flags>
       <output>PEAPI.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/PEAPI.dll</library_output>
     <project dir="class/Npgsql" library="Npgsql-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:Mono.Security.dll @Npgsql.dll.resources</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:Mono.Security.dll -warn:1 @Npgsql.dll.resources</flags>
       <output>Npgsql.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/Npgsql.dll</library_output>
     <project dir="class/Novell.Directory.Ldap" library="Novell.Directory.Ldap-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /nowarn:649 /nowarn:169 /nowarn:219 /nowarn:168 -r:mscorlib.dll -r:System.dll -r:Mono.Security.dll /res:Novell.Directory.Ldap.Utilclass/ResultCodeMessages.resources</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -warn:1 -nowarn:612 -r:mscorlib.dll -r:System.dll -r:Mono.Security.dll /res:Novell.Directory.Ldap.Utilclass/ResultCodeMessages.resources</flags>
       <output>Novell.Directory.Ldap.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/Novell.Directory.Ldap.dll</library_output>
     <project dir="class/RabbitMQ.Client/src/client" library="RabbitMQ.Client-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Xml.dll -nowarn:618</flags>
       <output>RabbitMQ.Client.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../../class/lib/net_2_0/RabbitMQ.Client.dll</library_output>
     <project dir="class/Mono.Messaging.RabbitMQ" library="Mono.Messaging.RabbitMQ-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client -nowarn:618</flags>
       <output>Mono.Messaging.RabbitMQ.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/Mono.Messaging.RabbitMQ.dll</library_output>
     <project dir="class/Mono.Messaging.RabbitMQ" library="Mono.Messaging.RabbitMQ-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.Messaging.RabbitMQ.dll /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client -nowarn:0618 -nowarn:219 -nowarn:169 /r:nunit.mocks.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.Messaging.RabbitMQ.dll /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client -nowarn:618 -nowarn:0618 -nowarn:219 -nowarn:169 /r:nunit.mocks.dll</flags>
       <output>Mono.Messaging.RabbitMQ_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Messaging.RabbitMQ_test_net_2_0.dll</library_output>
     <project dir="class/System.Design" library="System.Design-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Design.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Design.dll /r:System.dll</flags>
       <output>System.Design_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Design_test_net_2_0.dll</library_output>
     <project dir="class/ICSharpCode.SharpZipLib" library="ICSharpCode.SharpZipLib-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll -warn:1</flags>
       <output>ICSharpCode.SharpZipLib.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/ICSharpCode.SharpZipLib.dll</library_output>
     <project dir="class/Mono.Http" library="Mono.Http-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:ICSharpCode.SharpZipLib.dll -r:Mono.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:ICSharpCode.SharpZipLib.dll -r:Mono.Security.dll -nowarn:618</flags>
       <output>Mono.Http.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/Mono.Http.dll</library_output>
     <project dir="class/IBM.Data.DB2" library="IBM.Data.DB2-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll -warn:1</flags>
       <output>IBM.Data.DB2.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/IBM.Data.DB2.dll</library_output>
     <project dir="class/Mono.Debugger.Soft" library="Mono.Debugger.Soft-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.Debugger.Soft.dll /r:Mono.Cecil.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.Debugger.Soft.dll /r:Mono.Cecil.dll /r:System.dll /r:System.Core.dll</flags>
       <output>Mono.Debugger.Soft_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Debugger.Soft_test_net_2_0.dll</library_output>
     <project dir="class/Microsoft.Build.Utilities" library="Microsoft.Build.Utilities-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Microsoft.Build.Utilities.dll /r:Microsoft.Build.Framework.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Microsoft.Build.Utilities.dll /r:Microsoft.Build.Framework.dll -r:System.dll</flags>
       <output>Microsoft.Build.Utilities_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Utilities_test_net_2_0.dll</library_output>
     <project dir="class/Microsoft.Build.Engine" library="Microsoft.Build.Engine-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.dll /r:System.Xml.dll</flags>
       <output>Microsoft.Build.Engine_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Engine_test_net_2_0.dll</library_output>
     <project dir="class/Microsoft.Build.Tasks" library="Microsoft.Build.Tasks-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Microsoft.Build.Tasks.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Microsoft.Build.Tasks.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.dll /r:System.Core.dll</flags>
       <output>Microsoft.Build.Tasks_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Tasks_test_net_2_0.dll</library_output>
     <project dir="class/System.Data.Linq" library="System.Data.Linq-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY -d:NET_3_5 -nowarn:1720</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY -warn:1 -d:NET_3_5 -nowarn:1720</flags>
       <output>System.Data.Linq.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/System.Data.Linq.dll</library_output>
     <project dir="class/System.Data.Linq" library="System.Data.Linq-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Data.Linq.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY -d:NET_3_5 -nowarn:1720</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Data.Linq.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY -warn:1 -d:NET_3_5 -nowarn:1720</flags>
       <output>System.Data.Linq_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Data.Linq_test_net_2_0.dll</library_output>
     <project dir="class/System.Web.DynamicData" library="System.Web.DynamicData-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Web.DynamicData.dll /r:System.dll /r:System.Core.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.dll /r:System.Data.Linq.dll /r:System.Drawing.dll /r:System.Web.dll /r:System.Web.Extensions.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll -d:NET_3_5 -r:System.ComponentModel.DataAnnotations.dll -r:System.Configuration.dll /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx.cs,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx.cs /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx.cs,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx.cs /resource:Test/WebPages/DynamicData/Content/Images/Back.gif,MonoTests.WebPages.DynamicData.Content.Images.Back.gif /resource:Test/WebPages/DynamicData/Content/Images/header_back.gif,MonoTests.WebPages.DynamicData.Content.Images.header_back.gif /resource:Test/WebPages/DynamicData/Content/Images/PgFirst.gif,MonoTests.WebPages.DynamicData.Content.Images.PgFirst.gif /resource:Test/WebPages/DynamicData/Content/Images/PgLast.gif,MonoTests.WebPages.DynamicData.Content.Images.PgLast.gif /resource:Test/WebPages/DynamicData/Content/Images/PgNext.gif,MonoTests.WebPages.DynamicData.Content.Images.PgNext.gif /resource:Test/WebPages/DynamicData/Content/Images/PgPrev.gif,MonoTests.WebPages.DynamicData.Content.Images.PgPrev.gif /resource:Test/WebPages/DynamicData/Content/Images/plus.gif,MonoTests.WebPages.DynamicData.Content.Images.plus.gif /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx.cs /resource:Test/WebPages/DynamicData/web.config,MonoTests.WebPages.DynamicData.web.config /resource:Test/WebPages/Global.asax,MonoTests.WebPages.Global.asax /resource:Test/WebPages/ListView_DynamicControl_01.aspx,MonoTests.WebPages.ListView_DynamicControl_01.aspx /resource:Test/WebPages/ListView_DynamicControl_01.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_01.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_02.aspx,MonoTests.WebPages.ListView_DynamicControl_02.aspx /resource:Test/WebPages/ListView_DynamicControl_02.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_02.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_03.aspx,MonoTests.WebPages.ListView_DynamicControl_03.aspx /resource:Test/WebPages/ListView_DynamicControl_03.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_03.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_04.aspx,MonoTests.WebPages.ListView_DynamicControl_04.aspx /resource:Test/WebPages/ListView_DynamicControl_04.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_04.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_05.aspx,MonoTests.WebPages.ListView_DynamicControl_05.aspx /resource:Test/WebPages/ListView_DynamicControl_05.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_05.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_06.aspx,MonoTests.WebPages.ListView_DynamicControl_06.aspx /resource:Test/WebPages/ListView_DynamicControl_06.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_06.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_07.aspx,MonoTests.WebPages.ListView_DynamicControl_07.aspx /resource:Test/WebPages/ListView_DynamicControl_07.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_07.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_08.aspx,MonoTests.WebPages.ListView_DynamicControl_08.aspx /resource:Test/WebPages/ListView_DynamicControl_08.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_08.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_09.aspx,MonoTests.WebPages.ListView_DynamicControl_09.aspx /resource:Test/WebPages/ListView_DynamicControl_09.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_09.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_10.aspx,MonoTests.WebPages.ListView_DynamicControl_10.aspx /resource:Test/WebPages/ListView_DynamicControl_10.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_10.aspx.cs /resource:Test/WebPages/DynamicValidator_01.aspx,MonoTests.WebPages.DynamicValidator_01.aspx /resource:Test/WebPages/DynamicValidator_01.aspx.cs,MonoTests.WebPages.DynamicValidator_01.aspx.cs /resource:Test/WebPages/DynamicValidator_02.aspx,MonoTests.WebPages.DynamicValidator_02.aspx /resource:Test/WebPages/DynamicValidator_02.aspx.cs,MonoTests.WebPages.DynamicValidator_02.aspx.cs /resource:Test/WebPages/Site.css,MonoTests.WebPages.Site.css /resource:Test/WebPages/Site.master,MonoTests.WebPages.Site.master /resource:Test/WebPages/Site.master.cs,MonoTests.WebPages.Site.master.cs /resource:Test/WebPages/web.config.2.0,MonoTests.WebPages.web.config.2.0 /resource:Test/WebPages/web.config.4.0,MonoTests.WebPages.web.config.4.0 -r:SystemWebTestShim.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Web.DynamicData.dll /r:System.dll /r:System.Core.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.dll /r:System.Data.Linq.dll /r:System.Drawing.dll /r:System.Web.dll /r:System.Web.Extensions.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll -d:NET_3_5 -r:System.ComponentModel.DataAnnotations.dll -r:System.Configuration.dll /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx.cs,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx.cs /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx.cs,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx.cs /resource:Test/WebPages/DynamicData/Content/Images/Back.gif,MonoTests.WebPages.DynamicData.Content.Images.Back.gif /resource:Test/WebPages/DynamicData/Content/Images/header_back.gif,MonoTests.WebPages.DynamicData.Content.Images.header_back.gif /resource:Test/WebPages/DynamicData/Content/Images/PgFirst.gif,MonoTests.WebPages.DynamicData.Content.Images.PgFirst.gif /resource:Test/WebPages/DynamicData/Content/Images/PgLast.gif,MonoTests.WebPages.DynamicData.Content.Images.PgLast.gif /resource:Test/WebPages/DynamicData/Content/Images/PgNext.gif,MonoTests.WebPages.DynamicData.Content.Images.PgNext.gif /resource:Test/WebPages/DynamicData/Content/Images/PgPrev.gif,MonoTests.WebPages.DynamicData.Content.Images.PgPrev.gif /resource:Test/WebPages/DynamicData/Content/Images/plus.gif,MonoTests.WebPages.DynamicData.Content.Images.plus.gif /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx.cs /resource:Test/WebPages/DynamicData/web.config,MonoTests.WebPages.DynamicData.web.config /resource:Test/WebPages/Global.asax,MonoTests.WebPages.Global.asax /resource:Test/WebPages/ListView_DynamicControl_01.aspx,MonoTests.WebPages.ListView_DynamicControl_01.aspx /resource:Test/WebPages/ListView_DynamicControl_01.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_01.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_02.aspx,MonoTests.WebPages.ListView_DynamicControl_02.aspx /resource:Test/WebPages/ListView_DynamicControl_02.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_02.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_03.aspx,MonoTests.WebPages.ListView_DynamicControl_03.aspx /resource:Test/WebPages/ListView_DynamicControl_03.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_03.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_04.aspx,MonoTests.WebPages.ListView_DynamicControl_04.aspx /resource:Test/WebPages/ListView_DynamicControl_04.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_04.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_05.aspx,MonoTests.WebPages.ListView_DynamicControl_05.aspx /resource:Test/WebPages/ListView_DynamicControl_05.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_05.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_06.aspx,MonoTests.WebPages.ListView_DynamicControl_06.aspx /resource:Test/WebPages/ListView_DynamicControl_06.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_06.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_07.aspx,MonoTests.WebPages.ListView_DynamicControl_07.aspx /resource:Test/WebPages/ListView_DynamicControl_07.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_07.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_08.aspx,MonoTests.WebPages.ListView_DynamicControl_08.aspx /resource:Test/WebPages/ListView_DynamicControl_08.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_08.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_09.aspx,MonoTests.WebPages.ListView_DynamicControl_09.aspx /resource:Test/WebPages/ListView_DynamicControl_09.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_09.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_10.aspx,MonoTests.WebPages.ListView_DynamicControl_10.aspx /resource:Test/WebPages/ListView_DynamicControl_10.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_10.aspx.cs /resource:Test/WebPages/DynamicValidator_01.aspx,MonoTests.WebPages.DynamicValidator_01.aspx /resource:Test/WebPages/DynamicValidator_01.aspx.cs,MonoTests.WebPages.DynamicValidator_01.aspx.cs /resource:Test/WebPages/DynamicValidator_02.aspx,MonoTests.WebPages.DynamicValidator_02.aspx /resource:Test/WebPages/DynamicValidator_02.aspx.cs,MonoTests.WebPages.DynamicValidator_02.aspx.cs /resource:Test/WebPages/Site.css,MonoTests.WebPages.Site.css /resource:Test/WebPages/Site.master,MonoTests.WebPages.Site.master /resource:Test/WebPages/Site.master.cs,MonoTests.WebPages.Site.master.cs /resource:Test/WebPages/web.config.2.0,MonoTests.WebPages.web.config.2.0 /resource:Test/WebPages/web.config.4.0,MonoTests.WebPages.web.config.4.0 -r:SystemWebTestShim.dll -r:System.Xml.dll</flags>
       <output>System.Web.DynamicData_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Web.DynamicData_test_net_2_0.dll</library_output>
       <fx_version>2.0</fx_version>
       <response>./../../build/deps/System.ServiceModel.Web_test_net_2_0.dll.response</response>
     </project>
-    <project dir="class/System.Web.Mvc" library="System.Web.Mvc-net_2_0">
-      <boot>false</boot>
-      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll /resource:System.Web.Mvc/Resources/MvcResources.resources,System.Web.Mvc.Resources.MvcResources.resources -d:NET_3_5 -d:MONO</flags>
-      <output>System.Web.Mvc.dll</output>
-      <built_sources></built_sources>
-      <library_output>./../../class/compat/net_2_0/tmp/System.Web.Mvc.dll</library_output>
-      <fx_version>2.0</fx_version>
-      <response>System.Web.Mvc.dll.sources</response>
-    </project>
     <project dir="class/System.Web.Mvc2" library="System.Web.Mvc2-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /warnaserror- /noconfig /keyfile:../winfx.pub /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.Linq.dll /resource:System.Web.Mvc/Resources/MvcResources.resources,System.Web.Mvc.Resources.MvcResources.resources -d:NET_3_5 -d:MONO</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /warn:1 /keyfile:../winfx.pub /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.Linq.dll /resource:System.Web.Mvc/Resources/MvcResources.resources,System.Web.Mvc.Resources.MvcResources.resources -d:NET_3_5 -d:MONO</flags>
       <output>System.Web.Mvc.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/tmp/System.Web.Mvc.dll</library_output>
     <project dir="class/Mono.C5" library="Mono.C5-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll -nowarn:169,219,414,1030,3001,3005,3006</flags>
       <output>Mono.C5.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/Mono.C5.dll</library_output>
     <project dir="class/Mono.C5" library="Mono.C5-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.C5.dll /r:mscorlib.dll /r:System.dll -nowarn:169 -nowarn:0618 -nowarn:219 -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.C5.dll /r:mscorlib.dll /r:System.dll -nowarn:169,219,414,1030,3001,3005,3006 -nowarn:0618 -nowarn:219 -nowarn:169</flags>
       <output>Mono.C5_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.C5_test_net_2_0.dll</library_output>
     <project dir="class/Mono.Options" library="Mono.Options-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.Options.dll /r:Mono.Posix.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.Options.dll /r:Mono.Posix.dll /r:System.dll /r:System.Core.dll</flags>
       <output>Mono.Options_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Options_test_net_2_0.dll</library_output>
     <project dir="class/Mono.CSharp" library="Mono.CSharp-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:System.Core.dll -r:System.Xml -r:System</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -r:System.Core.dll -r:System.Xml.dll -r:System.dll</flags>
       <output>Mono.CSharp.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/Mono.CSharp.dll</library_output>
     <project dir="class/Mono.CSharp" library="Mono.CSharp-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.CSharp.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/Mono.CSharp.dll -r:System.Core.dll</flags>
       <output>Mono.CSharp_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.CSharp_test_net_2_0.dll</library_output>
     <project dir="class/WindowsBase" library="WindowsBase-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -unsafe -r:System -r:System.Xml -d:NET_3_0</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -unsafe -r:System.dll -r:System.Xml.dll -d:NET_3_0</flags>
       <output>WindowsBase.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/WindowsBase.dll</library_output>
     <project dir="class/WindowsBase" library="WindowsBase-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/WindowsBase.dll -unsafe -r:WindowsBase.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/WindowsBase.dll -unsafe -r:WindowsBase.dll -r:System.dll -r:System.Xml.dll -r:System.Core.dll</flags>
       <output>WindowsBase_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>WindowsBase_test_net_2_0.dll</library_output>
     <project dir="class/System.Data.Services.Client" library="System.Data.Services.Client-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -d:NET_3_5 -r:System.dll -r:System.Core.dll -r:System.Xml.Linq.dll -r:System.Data.dll -r:System.Xml.dll -warn:2 -r:WindowsBase</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -d:NET_3_5 -r:System.dll -r:System.Core.dll -r:System.Xml.Linq.dll -r:System.Data.dll -r:System.Xml.dll -resource:Client/System.Data.Services.Client.resources -warn:2 -r:WindowsBase</flags>
       <output>System.Data.Services.Client.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_2_0/System.Data.Services.Client.dll</library_output>
     <project dir="class/System.Data.Services" library="System.Data.Services-tests-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Data.Services.dll -r:System.ServiceModel</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_2_0/System.Data.Services.dll -r:System.ServiceModel.dll -r:System.Core.dll</flags>
       <output>System.Data.Services_test_net_2_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Data.Services_test_net_2_0.dll</library_output>
       <fx_version>2.0</fx_version>
       <response>./../../build/deps/System.Data.Services_test_net_2_0.dll.response</response>
     </project>
+    <project dir="class/System.Web.Mvc" library="System.Web.Mvc-net_2_0">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll /resource:System.Web.Mvc/Resources/MvcResources.resources,System.Web.Mvc.Resources.MvcResources.resources -d:NET_3_5 -d:MONO</flags>
+      <output>System.Web.Mvc.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/compat/net_2_0/tmp/System.Web.Mvc.dll</library_output>
+      <fx_version>2.0</fx_version>
+      <response>System.Web.Mvc.dll.sources</response>
+    </project>
     <project dir="nunit24/NUnit.Framework/framework" library="NUnit.Framework-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig -debug /r:System.Xml.dll /r:System.dll /d:StronglyNamedAssembly</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /r:System.Xml.dll /r:System.dll /d:StronglyNamedAssembly -warn:1</flags>
       <output>nunit.framework.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_2_0/nunit.framework.dll</library_output>
     <project dir="nunit20/NUnitCore/core" library="nunit.core-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -debug -r:nunit.framework.dll -r:nunit.core.interfaces.dll -r:System.dll /d:StronglyNamedAssembly -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -r:nunit.framework.dll -r:nunit.core.interfaces.dll -r:System.dll /d:StronglyNamedAssembly -warn:1 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig</flags>
       <output>nunit.core.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_2_0/nunit.core.dll</library_output>
     <project dir="nunit24/ClientUtilities/util" library="nunit.util-net_2_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /resource:Transform.resources,NUnit.Util.Transform.resources -r:nunit.core.dll -r:nunit.core.interfaces.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Remoting.dll /d:MONO /d:StronglyNamedAssembly -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /resource:Transform.resources,NUnit.Util.Transform.resources -r:nunit.core.dll -r:nunit.core.interfaces.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Remoting.dll /d:MONO /d:StronglyNamedAssembly -warn:1 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig</flags>
       <output>nunit.util.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_2_0/nunit.util.dll</library_output>
       <fx_version>2.0</fx_version>
       <response>xbuild.exe.sources</response>
     </project>
-    <project dir="tools/monodoc" library="monodoc-net_2_0">
-      <boot>false</boot>
-      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /nowarn:618,612,672,809 -optimize -d:NET_1_1 -d:NET_2_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug /noconfig /codepage:utf8 /nowarn:169,164,162,168,219,618,612 /r:Commons.Xml.Relaxng /resource:../../docs/monodoc.xml,monodoc.xml /resource:Resources/base.css,base.css /resource:Resources/ecmaspec-html-css.xsl,ecmaspec-html-css.xsl /resource:Resources/ecmaspec-html.xsl,ecmaspec-html.xsl /resource:Resources/ecmaspec.css,ecmaspec.css /resource:Resources/helper.js,helper.js /resource:Resources/home.html,home.html /resource:Resources/Lminus.gif,Lminus.gif /resource:Resources/Lplus.gif,Lplus.gif /resource:Resources/mdoc-html-format.xsl,mdoc-html-format.xsl /resource:Resources/mdoc-html-utils.xsl,mdoc-html-utils.xsl /resource:Resources/mdoc-sections-css.xsl,mdoc-sections-css.xsl /resource:Resources/mdoc-sections.xsl,mdoc-sections.xsl /resource:Resources/mono-ecma-css.xsl,mono-ecma-css.xsl /resource:Resources/mono-ecma-impl.xsl,mono-ecma-impl.xsl /resource:Resources/mono-ecma.css,mono-ecma.css /resource:Resources/mono-ecma.xsl,mono-ecma.xsl /resource:Resources/images/bc_bg.png,bc_bg.png /resource:Resources/images/bc_separator.png,bc_separator.png /resource:Resources/images/error.png,error.png /resource:Resources/images/hatch.png,hatch.png /resource:Resources/images/headerbg.png,headerbg.png /resource:Resources/images/help.png,help.png /resource:Resources/images/house.png,house.png /resource:Resources/images/members.png,members.png /resource:Resources/images/namespace.png,namespace.png /resource:Resources/images/privclass.png,privclass.png /resource:Resources/images/privdelegate.png,privdelegate.png /resource:Resources/images/privenumeration.png,privenumeration.png /resource:Resources/images/privevent.png,privevent.png /resource:Resources/images/privextension.png,privextension.png /resource:Resources/images/privfield.png,privfield.png /resource:Resources/images/privinterface.png,privinterface.png /resource:Resources/images/privmethod.png,privmethod.png /resource:Resources/images/privproperty.png,privproperty.png /resource:Resources/images/privstructure.png,privstructure.png /resource:Resources/images/protclass.png,protclass.png /resource:Resources/images/protdelegate.png,protdelegate.png /resource:Resources/images/protenumeration.png,protenumeration.png /resource:Resources/images/protevent.png,protevent.png /resource:Resources/images/protextension.png,protextension.png /resource:Resources/images/protfield.png,protfield.png /resource:Resources/images/protinterface.png,protinterface.png /resource:Resources/images/protmethod.png,protmethod.png /resource:Resources/images/protproperty.png,protproperty.png /resource:Resources/images/protstructure.png,protstructure.png /resource:Resources/images/pubclass.png,pubclass.png /resource:Resources/images/pubdelegate.png,pubdelegate.png /resource:Resources/images/pubenumeration.png,pubenumeration.png /resource:Resources/images/pubevent.png,pubevent.png /resource:Resources/images/pubextension.png,pubextension.png /resource:Resources/images/pubfield.png,pubfield.png /resource:Resources/images/pubinterface.png,pubinterface.png /resource:Resources/images/pubmethod.png,pubmethod.png /resource:Resources/images/pubproperty.png,pubproperty.png /resource:Resources/images/pubstructure.png,pubstructure.png /resource:Resources/images/reference.png,reference.png /resource:Resources/images/treebg.png,treebg.png /r:ICSharpCode.SharpZipLib /r:mscorlib.dll /r:System.dll /r:System.Core.dll /r:System.Web /r:System.Web.Services /r:System.Xml.dll /r:System.Configuration.dll</flags>
-      <output>monodoc.dll</output>
-      <built_sources></built_sources>
-      <library_output>./../../class/lib/net_2_0/monodoc.dll</library_output>
-      <fx_version>2.0</fx_version>
-      <response>monodoc.dll.sources</response>
-    </project>
     <project dir="class/Microsoft.Build.Framework" library="Microsoft.Build.Framework-net_3_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
     <project dir="class/Microsoft.Build.Utilities" library="Microsoft.Build.Utilities-tests-net_3_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_3_5 -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_3_5/Microsoft.Build.Utilities.v3.5.dll /r:./../../class/lib/net_3_5/Microsoft.Build.Framework.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_3_5 -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_3_5/Microsoft.Build.Utilities.v3.5.dll /r:./../../class/lib/net_3_5/Microsoft.Build.Framework.dll -r:System.dll</flags>
       <output>Microsoft.Build.Utilities_test_net_3_5.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Utilities_test_net_3_5.dll</library_output>
     <project dir="class/Microsoft.Build.Engine" library="Microsoft.Build.Engine-tests-net_3_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_3_5 -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_3_5/Microsoft.Build.Engine.dll /r:./../../class/lib/net_3_5/Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v3.5.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_3_5 -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_3_5/Microsoft.Build.Engine.dll /r:./../../class/lib/net_3_5/Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v3.5.dll /r:System.Xml.dll</flags>
       <output>Microsoft.Build.Engine_test_net_3_5.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Engine_test_net_3_5.dll</library_output>
     <project dir="class/Microsoft.Build.Tasks" library="Microsoft.Build.Tasks-tests-net_3_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_3_5 -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_3_5/Microsoft.Build.Tasks.v3.5.dll /r:./../../class/lib/net_3_5/Microsoft.Build.Engine.dll /r:./../../class/lib/net_3_5/Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v3.5.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_3_5 -lib:./../../class/lib/net_2_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_3_5/Microsoft.Build.Tasks.v3.5.dll /r:./../../class/lib/net_3_5/Microsoft.Build.Engine.dll /r:./../../class/lib/net_3_5/Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v3.5.dll /r:System.Core.dll</flags>
       <output>Microsoft.Build.Tasks_test_net_3_5.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Tasks_test_net_3_5.dll</library_output>
     <project dir="class/corlib" library="corlib-net_4_0">
       <boot>true</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -debug /noconfig -resource:resources/collation.core.bin -resource:resources/collation.tailoring.bin -resource:resources/collation.cjkCHS.bin -resource:resources/collation.cjkCHT.bin -resource:resources/collation.cjkJA.bin -resource:resources/collation.cjkKO.bin -resource:resources/collation.cjkKOlv2.bin --runtime:v4</flags>
+      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 /noconfig -resource:resources/collation.core.bin -resource:resources/collation.tailoring.bin -resource:resources/collation.cjkCHS.bin -resource:resources/collation.cjkCHT.bin -resource:resources/collation.cjkJA.bin -resource:resources/collation.cjkKO.bin -resource:resources/collation.cjkKOlv2.bin --runtime:v4</flags>
       <output>mscorlib.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/mscorlib.dll</library_output>
     <project dir="class/corlib" library="corlib-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -debug -r:./../../class/lib/net_4_0/mscorlib.dll -debug+ -debug:full -nowarn:168,219,618,672 -unsafe -r:./../../class/lib/net_4_0/Mono.Posix.dll -define:MONO_DATACONVERTER_STATIC_METHODS</flags>
+      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:./../../class/lib/net_4_0/mscorlib.dll -debug+ -debug:full -nowarn:168,219,618,672 -unsafe -r:Mono.Posix.dll -r:System.Core.dll -define:MONO_DATACONVERTER_STATIC_METHODS</flags>
       <output>corlib_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>corlib_test_net_4_0.dll</library_output>
     <project dir="class/System" library="System-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -r:PrebuiltSystem=../lib/net_4_0/System.dll -d:XML_DEP -r:System.Xml.dll -d:SECURITY_DEP -r:Mono.Security.dll -d:CONFIGURATION_DEP -r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -r:PrebuiltSystem=../lib/net_4_0/System.dll -d:XML_DEP -r:System.Xml.dll -d:SECURITY_DEP -r:Mono.Security.dll -d:CONFIGURATION_DEP -r:System.Configuration.dll</flags>
       <output>System.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.dll</library_output>
     <project dir="class/System" library="System-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
       <output>System_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System_test_net_4_0.dll</library_output>
     <project dir="class/System.XML" library="System.Xml-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642</flags>
       <output>System.Xml.dll</output>
       <built_sources>System.Xml.XPath/Parser.cs Mono.Xml.Xsl/PatternParser.cs Mono.Xml.Xsl/PatternTokenizer.cs</built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.Xml.dll</library_output>
     <project dir="class/System.XML" library="System.Xml-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data.dll -r:System.Core.dll</flags>
       <output>System.Xml_test_net_4_0.dll</output>
       <built_sources>System.Xml.XPath/Parser.cs Mono.Xml.Xsl/PatternParser.cs Mono.Xml.Xsl/PatternTokenizer.cs</built_sources>
       <library_output>System.Xml_test_net_4_0.dll</library_output>
     <project dir="class/Mono.CompilerServices.SymbolWriter" library="Mono.CompilerServices.SymbolWriter-net_4_0">
       <boot>true</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll</flags>
       <output>Mono.CompilerServices.SymbolWriter.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/Mono.CompilerServices.SymbolWriter.dll</library_output>
     <project dir="class/Mono.Posix" library="Mono.Posix-net_4_0">
       <boot>true</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /nowarn:0618,612</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /unsafe /r:mscorlib.dll /r:System.dll /nowarn:0618,612</flags>
       <output>Mono.Posix.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Posix.dll</library_output>
     <project dir="class/Mono.Posix" library="Mono.Posix-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.Posix.dll /r:Mono.Posix.dll /r:System.dll /nowarn:0219,0618</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.Posix.dll /r:Mono.Posix.dll /r:System.dll /nowarn:0219,0618</flags>
       <output>Mono.Posix_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Posix_test_net_4_0.dll</library_output>
     <project dir="class/System.Core" library="System.Core-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -d:INSIDE_SYSCORE -d:LIBC /r:mscorlib.dll /r:System.dll -unsafe -d:NET_3_5 -nowarn:1720 -d:CODEPLEX_40 -r:Mono.Posix.dll -unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -d:INSIDE_SYSCORE -d:LIBC /r:mscorlib.dll /r:System.dll -unsafe -d:NET_3_5 -nowarn:1720 -d:CODEPLEX_40 -r:Mono.Posix.dll -unsafe</flags>
       <output>System.Core.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Core.dll</library_output>
     <project dir="class/System.Core" library="System.Core-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Core.dll -d:INSIDE_SYSCORE -d:LIBC /r:mscorlib.dll /r:System.dll -unsafe -d:NET_3_5 -nowarn:1720 -d:CODEPLEX_40 -r:Mono.Posix.dll -unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Core.dll -d:INSIDE_SYSCORE -d:LIBC /r:mscorlib.dll /r:System.dll -unsafe -d:NET_3_5 -nowarn:1720 -d:CODEPLEX_40 -r:Mono.Posix.dll -unsafe</flags>
       <output>System.Core_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Core_test_net_4_0.dll</library_output>
     <project dir="class/Mono.Security" library="Mono.Security-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -unsafe -nowarn:1030</flags>
       <output>Mono.Security.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/Mono.Security.dll</library_output>
     <project dir="class/Mono.Security" library="Mono.Security-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.Security.dll -r:System.dll -unsafe -nowarn:169,219,618,672</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.Security.dll -r:System.dll -unsafe -nowarn:1030 -nowarn:169,219,618,672</flags>
       <output>Mono.Security_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Security_test_net_4_0.dll</library_output>
     <project dir="class/System" library="System-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -r:PrebuiltSystem=../lib/net_4_0/System.dll -d:XML_DEP -r:System.Xml.dll -d:SECURITY_DEP -r:Mono.Security.dll -d:CONFIGURATION_DEP -r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -r:PrebuiltSystem=../lib/net_4_0/System.dll -d:XML_DEP -r:System.Xml.dll -d:SECURITY_DEP -r:Mono.Security.dll -d:CONFIGURATION_DEP -r:System.Configuration.dll</flags>
       <output>System.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.dll</library_output>
     <project dir="class/System" library="System-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
       <output>System_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System_test_net_4_0.dll</library_output>
     <project dir="class/System.Security" library="System.Security-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -nowarn:618 -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:Mono.Security.dll -nowarn:414 -d:SECURITY_DEP</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -nowarn:618 -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:Mono.Security.dll -nowarn:414 -d:SECURITY_DEP</flags>
       <output>System.Security.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Security.dll</library_output>
     <project dir="class/System.Security" library="System.Security-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Security.dll -nowarn:618 -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:Mono.Security.dll -nowarn:414 -d:SECURITY_DEP -nowarn:169,219,1595 -nowarn:168,183,414</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Security.dll -nowarn:618 -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:Mono.Security.dll -nowarn:414 -d:SECURITY_DEP -nowarn:169,219,1595 -nowarn:168,183,414</flags>
       <output>System.Security_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Security_test_net_4_0.dll</library_output>
     <project dir="class/System.Configuration" library="System.Configuration-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll -nowarn:618</flags>
       <output>System.Configuration.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.Configuration.dll</library_output>
     <project dir="class/System.Configuration" library="System.Configuration-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Configuration.dll -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Configuration.dll -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll -nowarn:618</flags>
       <output>System.Configuration_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Configuration_test_net_4_0.dll</library_output>
     <project dir="class/System" library="System-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -r:PrebuiltSystem=../lib/net_4_0/System.dll -d:XML_DEP -r:System.Xml.dll -d:SECURITY_DEP -r:Mono.Security.dll -d:CONFIGURATION_DEP -r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -nowarn:618 -d:CONFIGURATION_2_0 -unsafe -resource:resources/Asterisk.wav -resource:resources/Beep.wav -resource:resources/Exclamation.wav -resource:resources/Hand.wav -resource:resources/Question.wav -r:PrebuiltSystem=../lib/net_4_0/System.dll -d:XML_DEP -r:System.Xml.dll -d:SECURITY_DEP -r:Mono.Security.dll -d:CONFIGURATION_DEP -r:System.Configuration.dll</flags>
       <output>System.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.dll</library_output>
     <project dir="class/System" library="System-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
       <output>System_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System_test_net_4_0.dll</library_output>
     <project dir="class/System.XML" library="System.Xml-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642</flags>
       <output>System.Xml.dll</output>
       <built_sources>System.Xml.XPath/Parser.cs Mono.Xml.Xsl/PatternParser.cs Mono.Xml.Xsl/PatternTokenizer.cs</built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.Xml.dll</library_output>
     <project dir="class/System.XML" library="System.Xml-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data.dll -r:System.Core.dll</flags>
       <output>System.Xml_test_net_4_0.dll</output>
       <built_sources>System.Xml.XPath/Parser.cs Mono.Xml.Xsl/PatternParser.cs Mono.Xml.Xsl/PatternTokenizer.cs</built_sources>
       <library_output>System.Xml_test_net_4_0.dll</library_output>
     <project dir="class/I18N/Common" library="I18N-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /r:mscorlib.dll /unsafe /define:DISABLE_UNSAFE -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /r:mscorlib.dll /unsafe /define:DISABLE_UNSAFE -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>I18N.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_4_0/tmp/I18N.dll</library_output>
     <project dir="class/I18N/West" library="I18N.West-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>I18N.West.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_4_0/tmp/I18N.West.dll</library_output>
     <project dir="class/I18N/West" library="I18N.West-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../../class/lib/net_4_0/I18N.West.dll</flags>
+      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../../class/lib/net_4_0/I18N.West.dll</flags>
       <output>I18N.West_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>I18N.West_test_net_4_0.dll</library_output>
     <project dir="class/I18N/MidEast" library="I18N.MidEast-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>I18N.MidEast.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_4_0/tmp/I18N.MidEast.dll</library_output>
     <project dir="class/I18N/Other" library="I18N.Other-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>I18N.Other.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_4_0/tmp/I18N.Other.dll</library_output>
     <project dir="class/I18N/Rare" library="I18N.Rare-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /r:mscorlib.dll /r:I18N.dll /unsafe -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>I18N.Rare.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_4_0/tmp/I18N.Rare.dll</library_output>
     <project dir="class/I18N/CJK" library="I18N.CJK-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /unsafe /resource:big5.table /resource:gb2312.table /resource:jis.table /resource:ks.table /resource:gb18030.table /r:mscorlib.dll /r:I18N.dll /define:DISABLE_UNSAFE -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /unsafe /resource:big5.table /resource:gb2312.table /resource:jis.table /resource:ks.table /resource:gb18030.table /r:mscorlib.dll /r:I18N.dll /define:DISABLE_UNSAFE -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>I18N.CJK.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_4_0/tmp/I18N.CJK.dll</library_output>
     <project dir="class/I18N/CJK" library="I18N.CJK-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /unsafe /resource:big5.table /resource:gb2312.table /resource:jis.table /resource:ks.table /resource:gb18030.table /r:mscorlib.dll /r:I18N.dll /define:DISABLE_UNSAFE -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../../class/lib/net_4_0/I18N.CJK.dll</flags>
+      <flags>/codepage:65001 /unsafe /resource:big5.table /resource:gb2312.table /resource:jis.table /resource:ks.table /resource:gb18030.table /r:mscorlib.dll /r:I18N.dll /define:DISABLE_UNSAFE -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../../class/lib/net_4_0/I18N.CJK.dll</flags>
       <output>I18N.CJK_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>I18N.CJK_test_net_4_0.dll</library_output>
     <project dir="tools/resgen" library="resgen-net_4_0">
       <boot></boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>resgen.exe</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/resgen.exe</library_output>
     <project dir="class/System.Drawing" library="System.Drawing-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll -resource:Assembly/Mono.ico,Mono.ico -resource:Assembly/Information.ico,Information.ico -resource:Assembly/Error.ico,Error.ico -resource:Assembly/Warning.ico,Warning.ico -resource:Assembly/Question.ico,Question.ico</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /unsafe /r:mscorlib.dll /r:System.dll -resource:Assembly/Mono.ico,Mono.ico -resource:Assembly/Information.ico,Information.ico -resource:Assembly/Error.ico,Error.ico -resource:Assembly/Warning.ico,Warning.ico -resource:Assembly/Question.ico,Question.ico</flags>
       <output>System.Drawing.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Drawing.dll</library_output>
     <project dir="class/System.Drawing" library="System.Drawing-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Drawing.dll /unsafe /r:mscorlib.dll /r:System.dll -resource:Assembly/Mono.ico,Mono.ico -resource:Assembly/Information.ico,Information.ico -resource:Assembly/Error.ico,Error.ico -resource:Assembly/Warning.ico,Warning.ico -resource:Assembly/Question.ico,Question.ico -define:TEST -resource:Test/resources/indexed.png,indexed.png -r:System.Drawing.dll -r:System.Runtime.Serialization.Formatters.Soap.dll -r:System.Xml.dll -nowarn:0618 -nowarn:219 -nowarn:169 -nowarn:1595</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Drawing.dll /unsafe /r:mscorlib.dll /r:System.dll -resource:Assembly/Mono.ico,Mono.ico -resource:Assembly/Information.ico,Information.ico -resource:Assembly/Error.ico,Error.ico -resource:Assembly/Warning.ico,Warning.ico -resource:Assembly/Question.ico,Question.ico -define:TEST -resource:Test/resources/indexed.png,indexed.png -r:System.Drawing.dll -r:System.Runtime.Serialization.Formatters.Soap.dll -r:System.Xml.dll -nowarn:0618 -nowarn:219 -nowarn:169 -nowarn:1595</flags>
       <output>System.Drawing_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Drawing_test_net_4_0.dll</library_output>
     <project dir="class/System.Transactions" library="System.Transactions-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Configuration.dll</flags>
       <output>System.Transactions.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Transactions.dll</library_output>
     <project dir="class/System.Transactions" library="System.Transactions-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Transactions.dll /nowarn:1595 /r:mscorlib.dll /r:System.dll /r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Transactions.dll /nowarn:1595 /r:mscorlib.dll /r:System.dll /r:System.Configuration.dll</flags>
       <output>System.Transactions_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Transactions_test_net_4_0.dll</library_output>
     <project dir="class/System.EnterpriseServices" library="System.EnterpriseServices-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /nowarn:0168 /nowarn:0162 /r:mscorlib.dll /r:System.Transactions.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /nowarn:0168 /nowarn:0162 /r:mscorlib.dll /r:System.Transactions.dll</flags>
       <output>System.EnterpriseServices.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.EnterpriseServices.dll</library_output>
     <project dir="class/Mono.Data.Tds" library="Mono.Data.Tds-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:Mono.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:Mono.Security.dll</flags>
       <output>Mono.Data.Tds.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Data.Tds.dll</library_output>
     <project dir="class/System.Data" library="System.Data-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -nowarn:649 -unsafe -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -r:Mono.Data.Tds.dll -r:System.Configuration.dll -r:System.Transactions.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -nowarn:649 -unsafe -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -r:Mono.Data.Tds.dll -r:System.Configuration.dll -r:System.Transactions.dll</flags>
       <output>System.Data.dll</output>
       <built_sources>Mono.Data.SqlExpressions/Parser.cs</built_sources>
       <library_output>./../../class/lib/net_4_0/System.Data.dll</library_output>
     <project dir="class/System.Data" library="System.Data-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Data.dll -nowarn:649 -unsafe -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -r:Mono.Data.Tds.dll -r:System.Configuration.dll -r:System.Transactions.dll -nowarn:618,169,612,219,168</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Data.dll -nowarn:649 -unsafe -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -r:Mono.Data.Tds.dll -r:System.Configuration.dll -r:System.Transactions.dll -r:System.Core.dll -nowarn:618,169,612,219,168</flags>
       <output>System.Data_test_net_4_0.dll</output>
       <built_sources>Mono.Data.SqlExpressions/Parser.cs</built_sources>
       <library_output>System.Data_test_net_4_0.dll</library_output>
     <project dir="class/Accessibility" library="Accessibility-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll</flags>
       <output>Accessibility.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Accessibility.dll</library_output>
     <project dir="class/Mono.WebBrowser" library="Mono.WebBrowser-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -debug+ -nowarn:108</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -warn:1</flags>
       <output>Mono.WebBrowser.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.WebBrowser.dll</library_output>
     <project dir="class/Managed.Windows.Forms" library="System.Windows.Forms-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Drawing.dll /r:Accessibility.dll /r:System.Data.dll /r:Mono.Posix.dll /r:Mono.WebBrowser @System.Windows.Forms.dll.resources -debug -nowarn:618,612,809 /r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Drawing.dll /r:Accessibility.dll /r:System.Data.dll /r:Mono.Posix.dll /r:Mono.WebBrowser /r:System.Configuration.dll @System.Windows.Forms.dll.resources -nowarn:618,612,809</flags>
       <output>System.Windows.Forms.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Windows.Forms.dll</library_output>
     <project dir="class/Managed.Windows.Forms" library="System.Windows.Forms-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Windows.Forms.dll /r:System.Data.dll /r:System.Drawing.dll /r:Accessibility.dll -resource:Test/resources/a.cur,a.cur -resource:Test/resources/32x32.ico,32x32.ico -nowarn:618,612</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Windows.Forms.dll /r:System.Data.dll /r:System.Drawing.dll /r:Accessibility.dll -r:System.dll -r:System.Xml.dll -resource:Test/resources/a.cur,a.cur -resource:Test/resources/32x32.ico,32x32.ico -nowarn:618,612</flags>
       <output>System.Windows.Forms_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Windows.Forms_test_net_4_0.dll</library_output>
     <project dir="class/Mono.Data.Sqlite" library="Mono.Data.Sqlite-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /unsafe /r:System.dll /r:System.Data.dll /r:System.Transactions.dll /r:System.Xml.dll -resource:resources/SR.resources -resource:resources/SQLiteCommand.bmp -resource:resources/SQLiteConnection.bmp -resource:resources/SQLiteDataAdapter.bmp -d:SQLITE_STANDARD</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /unsafe /r:System.dll /r:System.Data.dll /r:System.Transactions.dll /r:System.Xml.dll -resource:resources/SR.resources -resource:resources/SQLiteCommand.bmp -resource:resources/SQLiteConnection.bmp -resource:resources/SQLiteDataAdapter.bmp -d:SQLITE_STANDARD</flags>
       <output>Mono.Data.Sqlite.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Data.Sqlite.dll</library_output>
     <project dir="class/Mono.Data.Sqlite" library="Mono.Data.Sqlite-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.Data.Sqlite.dll /unsafe /r:System.dll /r:System.Data.dll /r:System.Transactions.dll /r:System.Xml.dll -resource:resources/SR.resources -resource:resources/SQLiteCommand.bmp -resource:resources/SQLiteConnection.bmp -resource:resources/SQLiteDataAdapter.bmp -d:SQLITE_STANDARD /nowarn:618</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.Data.Sqlite.dll /unsafe /r:System.dll /r:System.Data.dll /r:System.Transactions.dll /r:System.Xml.dll -resource:resources/SR.resources -resource:resources/SQLiteCommand.bmp -resource:resources/SQLiteConnection.bmp -resource:resources/SQLiteDataAdapter.bmp -d:SQLITE_STANDARD /nowarn:618</flags>
       <output>Mono.Data.Sqlite_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Data.Sqlite_test_net_4_0.dll</library_output>
     <project dir="class/System.Web.ApplicationServices" library="System.Web.ApplicationServices-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Configuration.dll -d:SYSTEM_WEB_APPLICATIONSERVICES</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Configuration.dll -d:SYSTEM_WEB_APPLICATIONSERVICES</flags>
       <output>System.Web.ApplicationServices.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Web.ApplicationServices.dll</library_output>
     <project dir="class/System.Web" library="System.Web-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll</flags>
       <output>System.Web.dll</output>
       <built_sources>System.Web/UplevelHelper.cs</built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.Web.dll</library_output>
     <project dir="class/System.Web" library="System.Web-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Web.dll -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll -doc:System.Web_test_net_4_0.xml -nowarn:219,169,1591 -r:SystemWebTestShim.dll /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Global.asax /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.ashx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.master /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx.cs /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMaster.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config.4.0 /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/sub_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_02.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_03.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_04.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_05.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_06.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_07.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_08.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_09.sitemap /resource:Test/mainsoft/NunitWebResources/menuclass.aspx /resource:Test/mainsoft/NunitWebResources/FormView.aspx /resource:Test/mainsoft/NunitWebResources/PostBackMenuTest.aspx /resource:Test/mainsoft/NunitWebResources/PageWithStyleSheet.aspx /resource:Test/mainsoft/NunitWebResources/PageWithTheme.aspx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.ascx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.aspx /resource:Test/mainsoft/NunitWebResources/RunTimeSetTheme.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyBind.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyControl.ascx /resource:Test/mainsoft/NunitWebResources/Theme1.skin /resource:Test/mainsoft/NunitWebResources/Theme2.skin /resource:Test/mainsoft/NunitWebResources/UrlProperty.aspx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx.cs /resource:Test/mainsoft/NunitWebResources/Web.sitemap /resource:Test/mainsoft/NunitWebResources/WizardTest.skin /resource:Test/mainsoft/NunitWebResources/FooterTemplateTest.aspx /resource:Test/mainsoft/NunitWebResources/DataGrid.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_2.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_3.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewDataActions.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewProperties1.aspx /resource:Test/mainsoft/NunitWebResources/Bluehills.jpg /resource:Test/mainsoft/NunitWebResources/FormViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_2.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_3.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_4.aspx /resource:Test/mainsoft/NunitWebResources/FormViewInsertEditDelete.aspx /resource:Test/mainsoft/NunitWebResources/GridViewUpdate.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xml /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xsl /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest1.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest2.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest3.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest4.aspx /resource:Test/mainsoft/NunitWebResources/LoginViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/WebControl.config /resource:Test/mainsoft/NunitWebResources/WebLogin.config /resource:Test/mainsoft/NunitWebResources/CallbackTest1.aspx /resource:Test/mainsoft/NunitWebResources/CallbackTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest1.aspx /resource:Test/mainsoft/NunitWebResources/ClientScript.js /resource:Test/mainsoft/NunitWebResources/EvalTest.aspx /resource:Test/mainsoft/NunitWebResources/TemplateUserControl.ascx /resource:Test/mainsoft/NunitWebResources/WebMapping.config /resource:Test/mainsoft/NunitWebResources/Mapping.aspx /resource:Test/mainsoft/NunitWebResources/Mapping1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting2.aspx /resource:Test/mainsoft/NunitWebResources/MyDerived.master /resource:Test/mainsoft/NunitWebResources/MyPageWithDerivedMaster.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest1.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest2.aspx /resource:Test/mainsoft/NunitWebResources/PageLifecycleTest.aspx /resource:Test/mainsoft/NunitWebResources/PageValidationTest.aspx /resource:Test/mainsoft/NunitWebResources/AsyncPage.aspx /resource:Test/mainsoft/NunitWebResources/PageCultureTest.aspx /resource:Test/mainsoft/NunitWebResources/adapters.browser /resource:Test/mainsoft/NunitWebResources/NoEventValidation.aspx /resource:Test/mainsoft/NunitWebResources/ListControlPage.aspx /resource:Test/mainsoft/NunitWebResources/TextBoxTestlPage.aspx /resource:Test/mainsoft/NunitWebResources/ClearErrorOnError.aspx /resource:Test/mainsoft/NunitWebResources/RedirectOnError.aspx /resource:Test/mainsoft/NunitWebResources/TestCapability.browser /resource:Test/mainsoft/NunitWebResources/PageWithAdapter.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind5.aspx /resource:Test/mainsoft/NunitWebResources/ReadWritePropertyControl.ascx /resource:Test/mainsoft/MainsoftWebTest/nunitweb_config.xml /resource:Test/mainsoft/NunitWebResources/TemplateControlParsingTest.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.master /resource:Test/mainsoft/NunitWebResources/MissingMasterFile.aspx /resource:Test/mainsoft/NunitWebResources/CustomSectionEmptyCollection.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx.cs /resource:Test/mainsoft/NunitWebResources/LoginDisplayRememberMe.aspx /resource:Test/mainsoft/NunitWebResources/NoBindForMethodsWithBindInName.aspx /resource:Test/mainsoft/NunitWebResources/LinkInHeadWithEmbeddedExpression.aspx /resource:Test/mainsoft/NunitWebResources/ExpressionInListControl.aspx /resource:Test/mainsoft/NunitWebResources/ServerSideControlsInScriptBlock.aspx /resource:Test/mainsoft/NunitWebResources/ServerControlInClientSideComment.aspx /resource:Test/mainsoft/NunitWebResources/PreprocessorDirectivesInMarkup.aspx /resource:Test/mainsoft/NunitWebResources/UnquotedAngleBrackets.aspx /resource:Test/mainsoft/NunitWebResources/FullTagsInText.aspx /resource:Test/mainsoft/NunitWebResources/TagsExpressionsAndCommentsInText.aspx /resource:Test/mainsoft/NunitWebResources/NewlineInCodeExpression.aspx /resource:Test/mainsoft/NunitWebResources/DuplicateControlsInClientComment.aspx /resource:Test/mainsoft/NunitWebResources/TagsNestedInClientTag.aspx /resource:Test/mainsoft/NunitWebResources/ConditionalClientComments.aspx /resource:Test/mainsoft/NunitWebResources/OneLetterIdentifierInCodeRender.aspx /resource:Test/mainsoft/NunitWebResources/GlobalResourcesLocalization.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx.cs /resource:Test/mainsoft/NunitWebResources/NestedParserFileText.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CorrectConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx.cs /resource:Test/mainsoft/NunitWebResources/ChangePasswordContainer_FindControl.aspx /resource:Test/mainsoft/NunitWebResources/TagWithExpressionWithinAttribute.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug578770.aspx /resource:Test/mainsoft/NunitWebResources/EnumConverter_Bug578586.aspx /resource:Test/mainsoft/NunitWebResources/ButtonColor_Bug325489.aspx /resource:Test/mainsoft/NunitWebResources/SqlDataSource_OnInit_Bug572781.aspx /resource:Test/mainsoft/NunitWebResources/FormViewPagerVisibility.aspx /resource:Test/mainsoft/NunitWebResources/OverridenControlsPropertyAndPostBack_Bug594238.aspx /resource:Test/mainsoft/NunitWebResources/GlobalizationEncodingName.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_0.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_5.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_6.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_7.aspx /resource:Test/mainsoft/NunitWebResources/GridView_Bug595567.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug600415.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx.cs /resource:Test/mainsoft/NunitWebResources/HtmlTitleCodeRender_Bug662918.aspx /resource:Test/mainsoft/NunitWebResources/App_Code/EnumConverterControl.cs,App_Code/EnumConverterControl.cs /resource:Test/mainsoft/NunitWebResources/App_Code/MyContainer.cs,App_Code/MyContainer.cs /resource:Test/mainsoft/NunitWebResources/App_Code/CustomCheckBoxColumn.cs,App_Code/CustomCheckBoxColumn.cs /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.resx,App_GlobalResources/Common.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.fr-FR.resx,App_GlobalResources/Common.fr-FR.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Resource1.resx,App_GlobalResources/Resource1.resx</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Web.dll -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll -doc:System.Web_test_net_4_0.xml -nowarn:219,169,1591 -r:SystemWebTestShim.dll /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Global.asax /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.ashx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.master /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx.cs /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMaster.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config.4.0 /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/sub_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_02.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_03.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_04.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_05.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_06.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_07.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_08.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_09.sitemap /resource:Test/mainsoft/NunitWebResources/menuclass.aspx /resource:Test/mainsoft/NunitWebResources/FormView.aspx /resource:Test/mainsoft/NunitWebResources/PostBackMenuTest.aspx /resource:Test/mainsoft/NunitWebResources/PageWithStyleSheet.aspx /resource:Test/mainsoft/NunitWebResources/PageWithTheme.aspx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.ascx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.aspx /resource:Test/mainsoft/NunitWebResources/RunTimeSetTheme.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyBind.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyControl.ascx /resource:Test/mainsoft/NunitWebResources/Theme1.skin /resource:Test/mainsoft/NunitWebResources/Theme2.skin /resource:Test/mainsoft/NunitWebResources/UrlProperty.aspx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx.cs /resource:Test/mainsoft/NunitWebResources/Web.sitemap /resource:Test/mainsoft/NunitWebResources/WizardTest.skin /resource:Test/mainsoft/NunitWebResources/FooterTemplateTest.aspx /resource:Test/mainsoft/NunitWebResources/DataGrid.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_2.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_3.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewDataActions.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewProperties1.aspx /resource:Test/mainsoft/NunitWebResources/Bluehills.jpg /resource:Test/mainsoft/NunitWebResources/FormViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_2.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_3.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_4.aspx /resource:Test/mainsoft/NunitWebResources/FormViewInsertEditDelete.aspx /resource:Test/mainsoft/NunitWebResources/GridViewUpdate.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xml /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xsl /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest1.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest2.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest3.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest4.aspx /resource:Test/mainsoft/NunitWebResources/LoginViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/WebControl.config /resource:Test/mainsoft/NunitWebResources/WebLogin.config /resource:Test/mainsoft/NunitWebResources/CallbackTest1.aspx /resource:Test/mainsoft/NunitWebResources/CallbackTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest1.aspx /resource:Test/mainsoft/NunitWebResources/ClientScript.js /resource:Test/mainsoft/NunitWebResources/EvalTest.aspx /resource:Test/mainsoft/NunitWebResources/TemplateUserControl.ascx /resource:Test/mainsoft/NunitWebResources/WebMapping.config /resource:Test/mainsoft/NunitWebResources/Mapping.aspx /resource:Test/mainsoft/NunitWebResources/Mapping1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting2.aspx /resource:Test/mainsoft/NunitWebResources/MyDerived.master /resource:Test/mainsoft/NunitWebResources/MyPageWithDerivedMaster.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest1.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest2.aspx /resource:Test/mainsoft/NunitWebResources/PageLifecycleTest.aspx /resource:Test/mainsoft/NunitWebResources/PageValidationTest.aspx /resource:Test/mainsoft/NunitWebResources/AsyncPage.aspx /resource:Test/mainsoft/NunitWebResources/PageCultureTest.aspx /resource:Test/mainsoft/NunitWebResources/adapters.browser /resource:Test/mainsoft/NunitWebResources/NoEventValidation.aspx /resource:Test/mainsoft/NunitWebResources/ListControlPage.aspx /resource:Test/mainsoft/NunitWebResources/TextBoxTestlPage.aspx /resource:Test/mainsoft/NunitWebResources/ClearErrorOnError.aspx /resource:Test/mainsoft/NunitWebResources/RedirectOnError.aspx /resource:Test/mainsoft/NunitWebResources/TestCapability.browser /resource:Test/mainsoft/NunitWebResources/PageWithAdapter.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind5.aspx /resource:Test/mainsoft/NunitWebResources/ReadWritePropertyControl.ascx /resource:Test/mainsoft/MainsoftWebTest/nunitweb_config.xml /resource:Test/mainsoft/NunitWebResources/TemplateControlParsingTest.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.master /resource:Test/mainsoft/NunitWebResources/MissingMasterFile.aspx /resource:Test/mainsoft/NunitWebResources/CustomSectionEmptyCollection.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx.cs /resource:Test/mainsoft/NunitWebResources/LoginDisplayRememberMe.aspx /resource:Test/mainsoft/NunitWebResources/NoBindForMethodsWithBindInName.aspx /resource:Test/mainsoft/NunitWebResources/LinkInHeadWithEmbeddedExpression.aspx /resource:Test/mainsoft/NunitWebResources/ExpressionInListControl.aspx /resource:Test/mainsoft/NunitWebResources/ServerSideControlsInScriptBlock.aspx /resource:Test/mainsoft/NunitWebResources/ServerControlInClientSideComment.aspx /resource:Test/mainsoft/NunitWebResources/PreprocessorDirectivesInMarkup.aspx /resource:Test/mainsoft/NunitWebResources/UnquotedAngleBrackets.aspx /resource:Test/mainsoft/NunitWebResources/FullTagsInText.aspx /resource:Test/mainsoft/NunitWebResources/TagsExpressionsAndCommentsInText.aspx /resource:Test/mainsoft/NunitWebResources/NewlineInCodeExpression.aspx /resource:Test/mainsoft/NunitWebResources/DuplicateControlsInClientComment.aspx /resource:Test/mainsoft/NunitWebResources/TagsNestedInClientTag.aspx /resource:Test/mainsoft/NunitWebResources/ConditionalClientComments.aspx /resource:Test/mainsoft/NunitWebResources/OneLetterIdentifierInCodeRender.aspx /resource:Test/mainsoft/NunitWebResources/GlobalResourcesLocalization.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx.cs /resource:Test/mainsoft/NunitWebResources/NestedParserFileText.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CorrectConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx.cs /resource:Test/mainsoft/NunitWebResources/ChangePasswordContainer_FindControl.aspx /resource:Test/mainsoft/NunitWebResources/TagWithExpressionWithinAttribute.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug578770.aspx /resource:Test/mainsoft/NunitWebResources/EnumConverter_Bug578586.aspx /resource:Test/mainsoft/NunitWebResources/ButtonColor_Bug325489.aspx /resource:Test/mainsoft/NunitWebResources/SqlDataSource_OnInit_Bug572781.aspx /resource:Test/mainsoft/NunitWebResources/FormViewPagerVisibility.aspx /resource:Test/mainsoft/NunitWebResources/OverridenControlsPropertyAndPostBack_Bug594238.aspx /resource:Test/mainsoft/NunitWebResources/GlobalizationEncodingName.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_0.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_5.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_6.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_7.aspx /resource:Test/mainsoft/NunitWebResources/GridView_Bug595567.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug600415.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx.cs /resource:Test/mainsoft/NunitWebResources/HtmlTitleCodeRender_Bug662918.aspx /resource:Test/mainsoft/NunitWebResources/App_Code/EnumConverterControl.cs,App_Code/EnumConverterControl.cs /resource:Test/mainsoft/NunitWebResources/App_Code/MyContainer.cs,App_Code/MyContainer.cs /resource:Test/mainsoft/NunitWebResources/App_Code/CustomCheckBoxColumn.cs,App_Code/CustomCheckBoxColumn.cs /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.resx,App_GlobalResources/Common.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.fr-FR.resx,App_GlobalResources/Common.fr-FR.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Resource1.resx,App_GlobalResources/Resource1.resx</flags>
       <output>System.Web_test_net_4_0.dll</output>
       <built_sources>System.Web/UplevelHelper.cs</built_sources>
       <library_output>System.Web_test_net_4_0.dll</library_output>
     <project dir="class/Mono.Web" library="Mono.Web-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Configuration.dll</flags>
       <output>Mono.Web.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Web.dll</library_output>
     <project dir="class/System.Web.Services" library="System.Web.Services-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -nowarn:649 -nowarn:169 -r:mscorlib.dll -r:System.dll -r:System.EnterpriseServices.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Configuration.dll -resource:System.Web.Services.Description/wsdl-1.1.xsd,wsdl-1.1.xsd -resource:System.Web.Services.Description/wsdl-1.1-soap.xsd,wsdl-1.1-soap.xsd -resource:System.Web.Services.Description/web-reference.xsd,web-reference.xsd</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -nowarn:649 -nowarn:169 -r:mscorlib.dll -r:System.dll -r:System.EnterpriseServices.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Configuration.dll -resource:System.Web.Services.Description/wsdl-1.1.xsd,wsdl-1.1.xsd -resource:System.Web.Services.Description/wsdl-1.1-soap.xsd,wsdl-1.1-soap.xsd -resource:System.Web.Services.Description/web-reference.xsd,web-reference.xsd</flags>
       <output>System.Web.Services.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Web.Services.dll</library_output>
     <project dir="class/System.Web.Services" library="System.Web.Services-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Web.Services.dll -nowarn:649 -nowarn:169 -r:mscorlib.dll -r:System.dll -r:System.EnterpriseServices.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Configuration.dll -resource:System.Web.Services.Description/wsdl-1.1.xsd,wsdl-1.1.xsd -resource:System.Web.Services.Description/wsdl-1.1-soap.xsd,wsdl-1.1-soap.xsd -resource:System.Web.Services.Description/web-reference.xsd,web-reference.xsd -nowarn:618</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Web.Services.dll -nowarn:649 -nowarn:169 -r:mscorlib.dll -r:System.dll -r:System.EnterpriseServices.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Configuration.dll -resource:System.Web.Services.Description/wsdl-1.1.xsd,wsdl-1.1.xsd -resource:System.Web.Services.Description/wsdl-1.1-soap.xsd,wsdl-1.1-soap.xsd -resource:System.Web.Services.Description/web-reference.xsd,web-reference.xsd -nowarn:618</flags>
       <output>System.Web.Services_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Web.Services_test_net_4_0.dll</library_output>
     <project dir="class/System.Web" library="System.Web-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll</flags>
       <output>System.Web.dll</output>
       <built_sources>System.Web/UplevelHelper.cs</built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.Web.dll</library_output>
     <project dir="class/System.Web" library="System.Web-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Web.dll -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll -doc:System.Web_test_net_4_0.xml -nowarn:219,169,1591 -r:SystemWebTestShim.dll /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Global.asax /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.ashx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.master /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx.cs /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMaster.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config.4.0 /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/sub_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_02.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_03.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_04.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_05.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_06.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_07.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_08.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_09.sitemap /resource:Test/mainsoft/NunitWebResources/menuclass.aspx /resource:Test/mainsoft/NunitWebResources/FormView.aspx /resource:Test/mainsoft/NunitWebResources/PostBackMenuTest.aspx /resource:Test/mainsoft/NunitWebResources/PageWithStyleSheet.aspx /resource:Test/mainsoft/NunitWebResources/PageWithTheme.aspx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.ascx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.aspx /resource:Test/mainsoft/NunitWebResources/RunTimeSetTheme.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyBind.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyControl.ascx /resource:Test/mainsoft/NunitWebResources/Theme1.skin /resource:Test/mainsoft/NunitWebResources/Theme2.skin /resource:Test/mainsoft/NunitWebResources/UrlProperty.aspx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx.cs /resource:Test/mainsoft/NunitWebResources/Web.sitemap /resource:Test/mainsoft/NunitWebResources/WizardTest.skin /resource:Test/mainsoft/NunitWebResources/FooterTemplateTest.aspx /resource:Test/mainsoft/NunitWebResources/DataGrid.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_2.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_3.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewDataActions.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewProperties1.aspx /resource:Test/mainsoft/NunitWebResources/Bluehills.jpg /resource:Test/mainsoft/NunitWebResources/FormViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_2.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_3.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_4.aspx /resource:Test/mainsoft/NunitWebResources/FormViewInsertEditDelete.aspx /resource:Test/mainsoft/NunitWebResources/GridViewUpdate.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xml /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xsl /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest1.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest2.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest3.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest4.aspx /resource:Test/mainsoft/NunitWebResources/LoginViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/WebControl.config /resource:Test/mainsoft/NunitWebResources/WebLogin.config /resource:Test/mainsoft/NunitWebResources/CallbackTest1.aspx /resource:Test/mainsoft/NunitWebResources/CallbackTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest1.aspx /resource:Test/mainsoft/NunitWebResources/ClientScript.js /resource:Test/mainsoft/NunitWebResources/EvalTest.aspx /resource:Test/mainsoft/NunitWebResources/TemplateUserControl.ascx /resource:Test/mainsoft/NunitWebResources/WebMapping.config /resource:Test/mainsoft/NunitWebResources/Mapping.aspx /resource:Test/mainsoft/NunitWebResources/Mapping1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting2.aspx /resource:Test/mainsoft/NunitWebResources/MyDerived.master /resource:Test/mainsoft/NunitWebResources/MyPageWithDerivedMaster.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest1.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest2.aspx /resource:Test/mainsoft/NunitWebResources/PageLifecycleTest.aspx /resource:Test/mainsoft/NunitWebResources/PageValidationTest.aspx /resource:Test/mainsoft/NunitWebResources/AsyncPage.aspx /resource:Test/mainsoft/NunitWebResources/PageCultureTest.aspx /resource:Test/mainsoft/NunitWebResources/adapters.browser /resource:Test/mainsoft/NunitWebResources/NoEventValidation.aspx /resource:Test/mainsoft/NunitWebResources/ListControlPage.aspx /resource:Test/mainsoft/NunitWebResources/TextBoxTestlPage.aspx /resource:Test/mainsoft/NunitWebResources/ClearErrorOnError.aspx /resource:Test/mainsoft/NunitWebResources/RedirectOnError.aspx /resource:Test/mainsoft/NunitWebResources/TestCapability.browser /resource:Test/mainsoft/NunitWebResources/PageWithAdapter.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind5.aspx /resource:Test/mainsoft/NunitWebResources/ReadWritePropertyControl.ascx /resource:Test/mainsoft/MainsoftWebTest/nunitweb_config.xml /resource:Test/mainsoft/NunitWebResources/TemplateControlParsingTest.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.master /resource:Test/mainsoft/NunitWebResources/MissingMasterFile.aspx /resource:Test/mainsoft/NunitWebResources/CustomSectionEmptyCollection.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx.cs /resource:Test/mainsoft/NunitWebResources/LoginDisplayRememberMe.aspx /resource:Test/mainsoft/NunitWebResources/NoBindForMethodsWithBindInName.aspx /resource:Test/mainsoft/NunitWebResources/LinkInHeadWithEmbeddedExpression.aspx /resource:Test/mainsoft/NunitWebResources/ExpressionInListControl.aspx /resource:Test/mainsoft/NunitWebResources/ServerSideControlsInScriptBlock.aspx /resource:Test/mainsoft/NunitWebResources/ServerControlInClientSideComment.aspx /resource:Test/mainsoft/NunitWebResources/PreprocessorDirectivesInMarkup.aspx /resource:Test/mainsoft/NunitWebResources/UnquotedAngleBrackets.aspx /resource:Test/mainsoft/NunitWebResources/FullTagsInText.aspx /resource:Test/mainsoft/NunitWebResources/TagsExpressionsAndCommentsInText.aspx /resource:Test/mainsoft/NunitWebResources/NewlineInCodeExpression.aspx /resource:Test/mainsoft/NunitWebResources/DuplicateControlsInClientComment.aspx /resource:Test/mainsoft/NunitWebResources/TagsNestedInClientTag.aspx /resource:Test/mainsoft/NunitWebResources/ConditionalClientComments.aspx /resource:Test/mainsoft/NunitWebResources/OneLetterIdentifierInCodeRender.aspx /resource:Test/mainsoft/NunitWebResources/GlobalResourcesLocalization.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx.cs /resource:Test/mainsoft/NunitWebResources/NestedParserFileText.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CorrectConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx.cs /resource:Test/mainsoft/NunitWebResources/ChangePasswordContainer_FindControl.aspx /resource:Test/mainsoft/NunitWebResources/TagWithExpressionWithinAttribute.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug578770.aspx /resource:Test/mainsoft/NunitWebResources/EnumConverter_Bug578586.aspx /resource:Test/mainsoft/NunitWebResources/ButtonColor_Bug325489.aspx /resource:Test/mainsoft/NunitWebResources/SqlDataSource_OnInit_Bug572781.aspx /resource:Test/mainsoft/NunitWebResources/FormViewPagerVisibility.aspx /resource:Test/mainsoft/NunitWebResources/OverridenControlsPropertyAndPostBack_Bug594238.aspx /resource:Test/mainsoft/NunitWebResources/GlobalizationEncodingName.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_0.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_5.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_6.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_7.aspx /resource:Test/mainsoft/NunitWebResources/GridView_Bug595567.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug600415.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx.cs /resource:Test/mainsoft/NunitWebResources/HtmlTitleCodeRender_Bug662918.aspx /resource:Test/mainsoft/NunitWebResources/App_Code/EnumConverterControl.cs,App_Code/EnumConverterControl.cs /resource:Test/mainsoft/NunitWebResources/App_Code/MyContainer.cs,App_Code/MyContainer.cs /resource:Test/mainsoft/NunitWebResources/App_Code/CustomCheckBoxColumn.cs,App_Code/CustomCheckBoxColumn.cs /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.resx,App_GlobalResources/Common.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.fr-FR.resx,App_GlobalResources/Common.fr-FR.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Resource1.resx,App_GlobalResources/Resource1.resx</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Web.dll -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll -doc:System.Web_test_net_4_0.xml -nowarn:219,169,1591 -r:SystemWebTestShim.dll /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Global.asax /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.ashx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.master /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx.cs /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMaster.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config.4.0 /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/sub_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_02.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_03.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_04.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_05.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_06.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_07.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_08.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_09.sitemap /resource:Test/mainsoft/NunitWebResources/menuclass.aspx /resource:Test/mainsoft/NunitWebResources/FormView.aspx /resource:Test/mainsoft/NunitWebResources/PostBackMenuTest.aspx /resource:Test/mainsoft/NunitWebResources/PageWithStyleSheet.aspx /resource:Test/mainsoft/NunitWebResources/PageWithTheme.aspx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.ascx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.aspx /resource:Test/mainsoft/NunitWebResources/RunTimeSetTheme.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyBind.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyControl.ascx /resource:Test/mainsoft/NunitWebResources/Theme1.skin /resource:Test/mainsoft/NunitWebResources/Theme2.skin /resource:Test/mainsoft/NunitWebResources/UrlProperty.aspx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx.cs /resource:Test/mainsoft/NunitWebResources/Web.sitemap /resource:Test/mainsoft/NunitWebResources/WizardTest.skin /resource:Test/mainsoft/NunitWebResources/FooterTemplateTest.aspx /resource:Test/mainsoft/NunitWebResources/DataGrid.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_2.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_3.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewDataActions.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewProperties1.aspx /resource:Test/mainsoft/NunitWebResources/Bluehills.jpg /resource:Test/mainsoft/NunitWebResources/FormViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_2.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_3.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_4.aspx /resource:Test/mainsoft/NunitWebResources/FormViewInsertEditDelete.aspx /resource:Test/mainsoft/NunitWebResources/GridViewUpdate.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xml /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xsl /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest1.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest2.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest3.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest4.aspx /resource:Test/mainsoft/NunitWebResources/LoginViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/WebControl.config /resource:Test/mainsoft/NunitWebResources/WebLogin.config /resource:Test/mainsoft/NunitWebResources/CallbackTest1.aspx /resource:Test/mainsoft/NunitWebResources/CallbackTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest1.aspx /resource:Test/mainsoft/NunitWebResources/ClientScript.js /resource:Test/mainsoft/NunitWebResources/EvalTest.aspx /resource:Test/mainsoft/NunitWebResources/TemplateUserControl.ascx /resource:Test/mainsoft/NunitWebResources/WebMapping.config /resource:Test/mainsoft/NunitWebResources/Mapping.aspx /resource:Test/mainsoft/NunitWebResources/Mapping1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting2.aspx /resource:Test/mainsoft/NunitWebResources/MyDerived.master /resource:Test/mainsoft/NunitWebResources/MyPageWithDerivedMaster.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest1.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest2.aspx /resource:Test/mainsoft/NunitWebResources/PageLifecycleTest.aspx /resource:Test/mainsoft/NunitWebResources/PageValidationTest.aspx /resource:Test/mainsoft/NunitWebResources/AsyncPage.aspx /resource:Test/mainsoft/NunitWebResources/PageCultureTest.aspx /resource:Test/mainsoft/NunitWebResources/adapters.browser /resource:Test/mainsoft/NunitWebResources/NoEventValidation.aspx /resource:Test/mainsoft/NunitWebResources/ListControlPage.aspx /resource:Test/mainsoft/NunitWebResources/TextBoxTestlPage.aspx /resource:Test/mainsoft/NunitWebResources/ClearErrorOnError.aspx /resource:Test/mainsoft/NunitWebResources/RedirectOnError.aspx /resource:Test/mainsoft/NunitWebResources/TestCapability.browser /resource:Test/mainsoft/NunitWebResources/PageWithAdapter.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind5.aspx /resource:Test/mainsoft/NunitWebResources/ReadWritePropertyControl.ascx /resource:Test/mainsoft/MainsoftWebTest/nunitweb_config.xml /resource:Test/mainsoft/NunitWebResources/TemplateControlParsingTest.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.master /resource:Test/mainsoft/NunitWebResources/MissingMasterFile.aspx /resource:Test/mainsoft/NunitWebResources/CustomSectionEmptyCollection.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx.cs /resource:Test/mainsoft/NunitWebResources/LoginDisplayRememberMe.aspx /resource:Test/mainsoft/NunitWebResources/NoBindForMethodsWithBindInName.aspx /resource:Test/mainsoft/NunitWebResources/LinkInHeadWithEmbeddedExpression.aspx /resource:Test/mainsoft/NunitWebResources/ExpressionInListControl.aspx /resource:Test/mainsoft/NunitWebResources/ServerSideControlsInScriptBlock.aspx /resource:Test/mainsoft/NunitWebResources/ServerControlInClientSideComment.aspx /resource:Test/mainsoft/NunitWebResources/PreprocessorDirectivesInMarkup.aspx /resource:Test/mainsoft/NunitWebResources/UnquotedAngleBrackets.aspx /resource:Test/mainsoft/NunitWebResources/FullTagsInText.aspx /resource:Test/mainsoft/NunitWebResources/TagsExpressionsAndCommentsInText.aspx /resource:Test/mainsoft/NunitWebResources/NewlineInCodeExpression.aspx /resource:Test/mainsoft/NunitWebResources/DuplicateControlsInClientComment.aspx /resource:Test/mainsoft/NunitWebResources/TagsNestedInClientTag.aspx /resource:Test/mainsoft/NunitWebResources/ConditionalClientComments.aspx /resource:Test/mainsoft/NunitWebResources/OneLetterIdentifierInCodeRender.aspx /resource:Test/mainsoft/NunitWebResources/GlobalResourcesLocalization.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx.cs /resource:Test/mainsoft/NunitWebResources/NestedParserFileText.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CorrectConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx.cs /resource:Test/mainsoft/NunitWebResources/ChangePasswordContainer_FindControl.aspx /resource:Test/mainsoft/NunitWebResources/TagWithExpressionWithinAttribute.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug578770.aspx /resource:Test/mainsoft/NunitWebResources/EnumConverter_Bug578586.aspx /resource:Test/mainsoft/NunitWebResources/ButtonColor_Bug325489.aspx /resource:Test/mainsoft/NunitWebResources/SqlDataSource_OnInit_Bug572781.aspx /resource:Test/mainsoft/NunitWebResources/FormViewPagerVisibility.aspx /resource:Test/mainsoft/NunitWebResources/OverridenControlsPropertyAndPostBack_Bug594238.aspx /resource:Test/mainsoft/NunitWebResources/GlobalizationEncodingName.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_0.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_5.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_6.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_7.aspx /resource:Test/mainsoft/NunitWebResources/GridView_Bug595567.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug600415.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx.cs /resource:Test/mainsoft/NunitWebResources/HtmlTitleCodeRender_Bug662918.aspx /resource:Test/mainsoft/NunitWebResources/App_Code/EnumConverterControl.cs,App_Code/EnumConverterControl.cs /resource:Test/mainsoft/NunitWebResources/App_Code/MyContainer.cs,App_Code/MyContainer.cs /resource:Test/mainsoft/NunitWebResources/App_Code/CustomCheckBoxColumn.cs,App_Code/CustomCheckBoxColumn.cs /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.resx,App_GlobalResources/Common.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.fr-FR.resx,App_GlobalResources/Common.fr-FR.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Resource1.resx,App_GlobalResources/Resource1.resx</flags>
       <output>System.Web_test_net_4_0.dll</output>
       <built_sources>System.Web/UplevelHelper.cs</built_sources>
       <library_output>System.Web_test_net_4_0.dll</library_output>
     <project dir="class/System.Runtime.Serialization.Formatters.Soap" library="System.Runtime.Serialization.Formatters.Soap-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.Xml.dll</flags>
       <output>System.Runtime.Serialization.Formatters.Soap.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Runtime.Serialization.Formatters.Soap.dll</library_output>
     <project dir="class/System.Runtime.Serialization.Formatters.Soap" library="System.Runtime.Serialization.Formatters.Soap-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Runtime.Serialization.Formatters.Soap.dll /r:mscorlib.dll /r:System.Xml.dll -nowarn:0618 -nowarn:219 -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Runtime.Serialization.Formatters.Soap.dll /r:mscorlib.dll /r:System.Xml.dll -nowarn:0618 -nowarn:219 -nowarn:169</flags>
       <output>System.Runtime.Serialization.Formatters.Soap_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Runtime.Serialization.Formatters.Soap_test_net_4_0.dll</library_output>
     <project dir="class/System.Runtime.Remoting" library="System.Runtime.Remoting-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Web.dll /r:System.Xml.dll /r:System.Runtime.Serialization.Formatters.Soap.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Web.dll /r:System.Xml.dll /r:System.Runtime.Serialization.Formatters.Soap.dll</flags>
       <output>System.Runtime.Remoting.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Runtime.Remoting.dll</library_output>
     <project dir="class/System.Runtime.Remoting" library="System.Runtime.Remoting-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Runtime.Remoting.dll /r:mscorlib.dll /r:System.dll /r:System.Web.dll /r:System.Xml.dll /r:System.Runtime.Serialization.Formatters.Soap.dll -nowarn:618 /r:System.Runtime.Remoting.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Runtime.Remoting.dll /r:mscorlib.dll /r:System.dll /r:System.Web.dll /r:System.Xml.dll /r:System.Runtime.Serialization.Formatters.Soap.dll -nowarn:618 /r:System.Runtime.Remoting.dll</flags>
       <output>System.Runtime.Remoting_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Runtime.Remoting_test_net_4_0.dll</library_output>
     <project dir="class/System.Configuration.Install" library="System.Configuration.Install-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll</flags>
       <output>System.Configuration.Install.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Configuration.Install.dll</library_output>
     <project dir="class/System.Management" library="System.Management-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Configuration.Install.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Configuration.Install.dll</flags>
       <output>System.Management.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Management.dll</library_output>
     <project dir="class/System.Data.OracleClient" library="System.Data.OracleClient-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:System.EnterpriseServices.dll /r:System.Drawing.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:System.EnterpriseServices.dll /r:System.Drawing.dll</flags>
       <output>System.Data.OracleClient.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Data.OracleClient.dll</library_output>
     <project dir="class/System.Data.OracleClient" library="System.Data.OracleClient-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Data.OracleClient.dll /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:System.EnterpriseServices.dll /r:System.Drawing.dll /nowarn:618</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Data.OracleClient.dll /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:System.EnterpriseServices.dll /r:System.Drawing.dll /nowarn:618</flags>
       <output>System.Data.OracleClient_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Data.OracleClient_test_net_4_0.dll</library_output>
     <project dir="class/Microsoft.VisualC" library="Microsoft.VisualC-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll</flags>
       <output>Microsoft.VisualC.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Microsoft.VisualC.dll</library_output>
     <project dir="class/Cscompmgd" library="Cscompmgd-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll</flags>
       <output>cscompmgd.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/cscompmgd.dll</library_output>
     <project dir="class/Cscompmgd" library="Cscompmgd-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/cscompmgd.dll /r:mscorlib.dll /r:System.dll -nowarn:0618 -nowarn:219 -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/cscompmgd.dll /r:mscorlib.dll /r:System.dll -nowarn:0618 -nowarn:219 -nowarn:169</flags>
       <output>Cscompmgd_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Cscompmgd_test_net_4_0.dll</library_output>
     <project dir="class/System.Design" library="System.Design-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Windows.Forms.dll -r:System.Drawing.dll -r:Accessibility.dll -r:System.Data.dll -r:System.Configuration.dll -define:DRAWING_DESIGN_DEP -r:System.Drawing.Design.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Windows.Forms.dll -r:System.Drawing.dll -r:Accessibility.dll -r:System.Data.dll -r:System.Configuration.dll -define:DRAWING_DESIGN_DEP -r:System.Drawing.Design.dll</flags>
       <output>System.Design.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.Design.dll</library_output>
     <project dir="class/System.Design" library="System.Design-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Design.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Design.dll /r:System.dll</flags>
       <output>System.Design_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Design_test_net_4_0.dll</library_output>
     <project dir="class/PEAPI" library="PEAPI-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll -nowarn:414,618</flags>
       <output>PEAPI.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/PEAPI.dll</library_output>
     <project dir="class/Npgsql" library="Npgsql-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:Mono.Security.dll @Npgsql.dll.resources</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:Mono.Security.dll -warn:1 @Npgsql.dll.resources</flags>
       <output>Npgsql.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Npgsql.dll</library_output>
     <project dir="class/Npgsql" library="Npgsql-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Npgsql.dll /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Data.dll -nowarn:0618 -nowarn:219 -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Npgsql.dll /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Data.dll -nowarn:0618 -nowarn:219 -nowarn:169</flags>
       <output>Npgsql_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Npgsql_test_net_4_0.dll</library_output>
     <project dir="class/Commons.Xml.Relaxng" library="Commons.Xml.Relaxng-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /resource:resources/relaxng.rng,relaxng.rng</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /resource:resources/relaxng.rng,relaxng.rng</flags>
       <output>Commons.Xml.Relaxng.dll</output>
       <built_sources>Commons.Xml.Relaxng.Rnc/RncParser.cs</built_sources>
       <library_output>./../../class/lib/net_4_0/Commons.Xml.Relaxng.dll</library_output>
     <project dir="class/Commons.Xml.Relaxng" library="Commons.Xml.Relaxng-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Commons.Xml.Relaxng.dll /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /resource:resources/relaxng.rng,relaxng.rng -nowarn:0618 -nowarn:219 -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Commons.Xml.Relaxng.dll /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /resource:resources/relaxng.rng,relaxng.rng -nowarn:0618 -nowarn:219 -nowarn:169</flags>
       <output>Commons.Xml.Relaxng_test_net_4_0.dll</output>
       <built_sources>Commons.Xml.Relaxng.Rnc/RncParser.cs</built_sources>
       <library_output>Commons.Xml.Relaxng_test_net_4_0.dll</library_output>
     <project dir="class/Novell.Directory.Ldap" library="Novell.Directory.Ldap-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /nowarn:649 /nowarn:169 /nowarn:219 /nowarn:168 -r:mscorlib.dll -r:System.dll -r:Mono.Security.dll /res:Novell.Directory.Ldap.Utilclass/ResultCodeMessages.resources</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -warn:1 -nowarn:612 -r:mscorlib.dll -r:System.dll -r:Mono.Security.dll /res:Novell.Directory.Ldap.Utilclass/ResultCodeMessages.resources</flags>
       <output>Novell.Directory.Ldap.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Novell.Directory.Ldap.dll</library_output>
     <project dir="class/Novell.Directory.Ldap" library="Novell.Directory.Ldap-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Novell.Directory.Ldap.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Novell.Directory.Ldap.dll</flags>
       <output>Novell.Directory.Ldap_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Novell.Directory.Ldap_test_net_4_0.dll</library_output>
     <project dir="class/Mono.Security.Win32" library="Mono.Security.Win32-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /unsafe</flags>
       <output>Mono.Security.Win32.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Security.Win32.dll</library_output>
     <project dir="class/System.DirectoryServices" library="System.DirectoryServices-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:Novell.Directory.Ldap.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:Novell.Directory.Ldap.dll</flags>
       <output>System.DirectoryServices.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.DirectoryServices.dll</library_output>
     <project dir="class/System.DirectoryServices" library="System.DirectoryServices-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.DirectoryServices.dll /r:mscorlib.dll /r:System.dll /r:Novell.Directory.Ldap.dll -nowarn:0618 -nowarn:219 -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.DirectoryServices.dll /r:mscorlib.dll /r:System.dll /r:Novell.Directory.Ldap.dll -nowarn:0618 -nowarn:219 -nowarn:169</flags>
       <output>System.DirectoryServices_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.DirectoryServices_test_net_4_0.dll</library_output>
     <project dir="class/RabbitMQ.Client/src/apigen" library="RabbitMQ.Client.Apigen-net_4_0">
       <boot></boot>
       <mcs>MONO_PATH=./../../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /r:System.dll /r:System.Xml.dll /main:RabbitMQ.Client.Apigen.Apigen -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /r:System.dll /r:System.Xml.dll /main:RabbitMQ.Client.Apigen.Apigen -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>RabbitMQ.Client.Apigen.exe</output>
       <built_sources></built_sources>
       <library_output>./../../../../class/lib/net_4_0/RabbitMQ.Client.Apigen.exe</library_output>
     <project dir="class/RabbitMQ.Client/src/client" library="RabbitMQ.Client-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Xml.dll -nowarn:618</flags>
       <output>RabbitMQ.Client.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../../class/lib/net_4_0/RabbitMQ.Client.dll</library_output>
     <project dir="class/Mono.Messaging" library="Mono.Messaging-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll /r:System.Configuration</flags>
       <output>Mono.Messaging.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Messaging.dll</library_output>
     <project dir="class/Mono.Messaging" library="Mono.Messaging-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.Messaging.dll /r:System.dll /r:System.Configuration -nowarn:0618 -nowarn:219 -nowarn:169 /r:System.Messaging.dll /r:nunit.mocks.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.Messaging.dll /r:System.dll /r:System.Configuration -nowarn:0618 -nowarn:219 -nowarn:169 /r:System.Messaging.dll /r:nunit.mocks.dll</flags>
       <output>Mono.Messaging_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Messaging_test_net_4_0.dll</library_output>
     <project dir="class/System.Messaging" library="System.Messaging-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /resource:System.Messaging/MessageQueue.resx /r:System.dll /r:System.Configuration.Install.dll /r:System.Drawing.dll /r:System.Windows.Forms.dll /r:System.Xml /r:Mono.Messaging.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /resource:System.Messaging/MessageQueue.resx /r:System.dll /r:System.Configuration.Install.dll /r:System.Drawing.dll /r:System.Windows.Forms.dll /r:System.Xml /r:Mono.Messaging.dll</flags>
       <output>System.Messaging.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Messaging.dll</library_output>
     <project dir="class/System.Messaging" library="System.Messaging-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Messaging.dll /resource:System.Messaging/MessageQueue.resx /r:System.dll /r:System.Configuration.Install.dll /r:System.Drawing.dll /r:System.Windows.Forms.dll /r:System.Xml /r:Mono.Messaging.dll -nowarn:0618 -nowarn:219 -nowarn:169 /r:nunit.mocks.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Messaging.dll /resource:System.Messaging/MessageQueue.resx /r:System.dll /r:System.Configuration.Install.dll /r:System.Drawing.dll /r:System.Windows.Forms.dll /r:System.Xml /r:Mono.Messaging.dll -nowarn:0618 -nowarn:219 -nowarn:169 /r:nunit.mocks.dll</flags>
       <output>System.Messaging_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Messaging_test_net_4_0.dll</library_output>
     <project dir="class/Mono.Messaging.RabbitMQ" library="Mono.Messaging.RabbitMQ-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client -nowarn:618</flags>
       <output>Mono.Messaging.RabbitMQ.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Messaging.RabbitMQ.dll</library_output>
     <project dir="class/Mono.Messaging.RabbitMQ" library="Mono.Messaging.RabbitMQ-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.Messaging.RabbitMQ.dll /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client -nowarn:0618 -nowarn:219 -nowarn:169 /r:nunit.mocks.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.Messaging.RabbitMQ.dll /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client -nowarn:618 -nowarn:0618 -nowarn:219 -nowarn:169 /r:nunit.mocks.dll</flags>
       <output>Mono.Messaging.RabbitMQ_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Messaging.RabbitMQ_test_net_4_0.dll</library_output>
     <project dir="class/System.ServiceProcess" library="System.ServiceProcess-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Configuration.Install.dll /r:System.Windows.Forms.dll /nowarn:0618</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll /r:System.Configuration.Install.dll /r:System.Windows.Forms.dll /nowarn:0618</flags>
       <output>System.ServiceProcess.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.ServiceProcess.dll</library_output>
     <project dir="class/System.ServiceProcess" library="System.ServiceProcess-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.ServiceProcess.dll /r:System.dll /r:System.Configuration.Install.dll /r:System.Windows.Forms.dll /nowarn:0618</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.ServiceProcess.dll /r:System.dll /r:System.Configuration.Install.dll /r:System.Windows.Forms.dll /nowarn:0618</flags>
       <output>System.ServiceProcess_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.ServiceProcess_test_net_4_0.dll</library_output>
     <project dir="class/System.Drawing.Design" library="System.Drawing.Design-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Drawing.dll /r:System.Windows.Forms.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Drawing.dll /r:System.Windows.Forms.dll</flags>
       <output>System.Drawing.Design.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Drawing.Design.dll</library_output>
     <project dir="class/System.Design" library="System.Design-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Windows.Forms.dll -r:System.Drawing.dll -r:Accessibility.dll -r:System.Data.dll -r:System.Configuration.dll -define:DRAWING_DESIGN_DEP -r:System.Drawing.Design.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Windows.Forms.dll -r:System.Drawing.dll -r:Accessibility.dll -r:System.Data.dll -r:System.Configuration.dll -define:DRAWING_DESIGN_DEP -r:System.Drawing.Design.dll</flags>
       <output>System.Design.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.Design.dll</library_output>
     <project dir="class/System.Design" library="System.Design-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Design.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Design.dll /r:System.dll</flags>
       <output>System.Design_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Design_test_net_4_0.dll</library_output>
     <project dir="class/ICSharpCode.SharpZipLib" library="ICSharpCode.SharpZipLib-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll -warn:1</flags>
       <output>ICSharpCode.SharpZipLib.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/ICSharpCode.SharpZipLib.dll</library_output>
     <project dir="class/Mono.Http" library="Mono.Http-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:ICSharpCode.SharpZipLib.dll -r:Mono.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:ICSharpCode.SharpZipLib.dll -r:Mono.Security.dll -nowarn:618</flags>
       <output>Mono.Http.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Http.dll</library_output>
     <project dir="class/Mono.Cairo" library="Mono.Cairo-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>Mono.Cairo.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Cairo.dll</library_output>
     <project dir="class/IBM.Data.DB2" library="IBM.Data.DB2-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll -warn:1</flags>
       <output>IBM.Data.DB2.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/IBM.Data.DB2.dll</library_output>
     <project dir="class/CustomMarshalers" library="CustomMarshalers-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll</flags>
       <output>CustomMarshalers.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/CustomMarshalers.dll</library_output>
     <project dir="class/OpenSystem.C" library="OpenSystem.C-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>OpenSystem.C.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/OpenSystem.C.dll</library_output>
     <project dir="class/Mono.Cecil" library="Mono.Cecil-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll -keyfile:../mono.snk -r:System.Core.dll -d:NET_3_5</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll -keyfile:../mono.snk -r:System.Core.dll -d:NET_3_5</flags>
       <output>Mono.Cecil.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Cecil.dll</library_output>
     <project dir="class/Mono.Cecil.Mdb" library="Mono.Cecil.Mdb-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:./../../class/lib/net_4_0/Mono.Cecil.dll /d:CECIL -keyfile:../mono.snk</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:./../../class/lib/net_4_0/Mono.Cecil.dll /d:CECIL -keyfile:../mono.snk</flags>
       <output>Mono.Cecil.Mdb.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Cecil.Mdb.dll</library_output>
     <project dir="class/Mono.Debugger.Soft" library="Mono.Debugger.Soft-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:Mono.Cecil.dll /r:System.Core.dll /unsafe -D:MONO_DATACONVERTER_STATIC_METHODS -keyfile:../mono.snk</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:Mono.Cecil.dll /r:System.Core.dll /unsafe -D:MONO_DATACONVERTER_STATIC_METHODS -keyfile:../mono.snk</flags>
       <output>Mono.Debugger.Soft.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Debugger.Soft.dll</library_output>
     <project dir="class/Mono.Debugger.Soft" library="Mono.Debugger.Soft-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.Debugger.Soft.dll /r:Mono.Cecil.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.Debugger.Soft.dll /r:Mono.Cecil.dll /r:System.dll /r:System.Core.dll</flags>
       <output>Mono.Debugger.Soft_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Debugger.Soft_test_net_4_0.dll</library_output>
     <project dir="class/SystemWebTestShim" library="SystemWebTestShim-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.Web.dll -r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.Web.dll -r:System.dll</flags>
       <output>SystemWebTestShim.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/SystemWebTestShim.dll</library_output>
     <project dir="class/Microsoft.Build.Framework" library="Microsoft.Build.Framework-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll</flags>
       <output>Microsoft.Build.Framework.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Microsoft.Build.Framework.dll</library_output>
     <project dir="class/Microsoft.Build.Framework" library="Microsoft.Build.Framework-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Microsoft.Build.Framework.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Microsoft.Build.Framework.dll</flags>
       <output>Microsoft.Build.Framework_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Framework_test_net_4_0.dll</library_output>
     <project dir="class/Microsoft.Build.Utilities" library="Microsoft.Build.Utilities-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:Microsoft.Build.Framework.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:Microsoft.Build.Framework.dll</flags>
       <output>Microsoft.Build.Utilities.v4.0.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Microsoft.Build.Utilities.v4.0.dll</library_output>
     <project dir="class/Microsoft.Build.Utilities" library="Microsoft.Build.Utilities-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Microsoft.Build.Utilities.v4.0.dll /r:Microsoft.Build.Framework.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Microsoft.Build.Utilities.v4.0.dll /r:Microsoft.Build.Framework.dll -r:System.dll</flags>
       <output>Microsoft.Build.Utilities_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Utilities_test_net_4_0.dll</library_output>
     <project dir="class/Microsoft.Build.Engine" library="Microsoft.Build.Engine-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll</flags>
       <output>Microsoft.Build.Engine.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Microsoft.Build.Engine.dll</library_output>
     <project dir="class/Microsoft.Build.Engine" library="Microsoft.Build.Engine-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll /r:System.Xml.dll</flags>
       <output>Microsoft.Build.Engine_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Engine_test_net_4_0.dll</library_output>
     <project dir="class/Microsoft.Build.Tasks" library="Microsoft.Build.Tasks-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Windows.Forms.dll /r:Microsoft.Build.Utilities.v4.0.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Engine.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Windows.Forms.dll /r:Microsoft.Build.Utilities.v4.0.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Engine.dll</flags>
       <output>Microsoft.Build.Tasks.v4.0.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Microsoft.Build.Tasks.v4.0.dll</library_output>
     <project dir="class/Microsoft.Build.Tasks" library="Microsoft.Build.Tasks-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Microsoft.Build.Tasks.v4.0.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Microsoft.Build.Tasks.v4.0.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll /r:System.Core.dll</flags>
       <output>Microsoft.Build.Tasks_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Tasks_test_net_4_0.dll</library_output>
     <project dir="class/System.Xml.Linq" library="System.Xml.Linq-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Core.dll -r:System.Xml.dll -d:NET_3_5 -nowarn:1720</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Core.dll -r:System.Xml.dll -d:NET_3_5 -nowarn:1720</flags>
       <output>System.Xml.Linq.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Xml.Linq.dll</library_output>
     <project dir="class/System.Xml.Linq" library="System.Xml.Linq-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Xml.Linq.dll -r:System.dll -r:System.Core.dll -r:System.Xml.dll -d:NET_3_5 -nowarn:1720</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Xml.Linq.dll -r:System.dll -r:System.Core.dll -r:System.Xml.dll -d:NET_3_5 -nowarn:1720</flags>
       <output>System.Xml.Linq_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Xml.Linq_test_net_4_0.dll</library_output>
     <project dir="class/System.Runtime.Serialization" library="System.Runtime.Serialization-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /nowarn:168,169,219,414 /r:System.dll /r:System.Xml.dll /r:System.Core.dll /resource:resources/mstypes.schema /d:NET_3_0 /r:System.Data.dll /r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /nowarn:168,169,219,414 /r:System.dll /r:System.Xml.dll /r:System.Core.dll /resource:resources/mstypes.schema /d:NET_3_0 /r:System.Data.dll /r:System.Configuration.dll</flags>
       <output>System.Runtime.Serialization.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Runtime.Serialization.dll</library_output>
     <project dir="class/System.Runtime.Serialization" library="System.Runtime.Serialization-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Runtime.Serialization.dll /nowarn:168,169,219,414 /r:System.dll /r:System.Xml.dll /r:System.Core.dll /resource:resources/mstypes.schema /d:NET_3_0 /r:System.Data.dll /r:System.Configuration.dll /r:System.ServiceModel.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Runtime.Serialization.dll /nowarn:168,169,219,414 /r:System.dll /r:System.Xml.dll /r:System.Core.dll /resource:resources/mstypes.schema /d:NET_3_0 /r:System.Data.dll /r:System.Configuration.dll /r:System.ServiceModel.dll</flags>
       <output>System.Runtime.Serialization_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Runtime.Serialization_test_net_4_0.dll</library_output>
     <project dir="class/System.Data.DataSetExtensions" library="System.Data.DataSetExtensions-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.Core.dll -r:System.dll -r:System.Data.dll -r:System.Xml.dll -r:System.Web.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.Core.dll -r:System.dll -r:System.Data.dll -r:System.Xml.dll -r:System.Web.dll</flags>
       <output>System.Data.DataSetExtensions.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Data.DataSetExtensions.dll</library_output>
     <project dir="class/System.Data.DataSetExtensions" library="System.Data.DataSetExtensions-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Data.DataSetExtensions.dll -r:mscorlib.dll -r:System.Core.dll -r:System.dll -r:System.Data.dll -r:System.Xml.dll -r:System.Web.dll -doc:System.Data.DataSetExtensions_test_net_4_0.xml -nowarn:219 -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Data.DataSetExtensions.dll -r:mscorlib.dll -r:System.Core.dll -r:System.dll -r:System.Data.dll -r:System.Xml.dll -r:System.Web.dll -doc:System.Data.DataSetExtensions_test_net_4_0.xml -nowarn:219 -nowarn:169</flags>
       <output>System.Data.DataSetExtensions_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Data.DataSetExtensions_test_net_4_0.dll</library_output>
     <project dir="class/System.Data.Linq" library="System.Data.Linq-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY -warn:1</flags>
       <output>System.Data.Linq.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Data.Linq.dll</library_output>
     <project dir="class/System.Data.Linq" library="System.Data.Linq-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Data.Linq.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Data.Linq.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY -warn:1</flags>
       <output>System.Data.Linq_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Data.Linq_test_net_4_0.dll</library_output>
     <project dir="class/System.Web" library="System.Web-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll</flags>
       <output>System.Web.dll</output>
       <built_sources>System.Web/UplevelHelper.cs</built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/System.Web.dll</library_output>
     <project dir="class/System.Web" library="System.Web-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Web.dll -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll -doc:System.Web_test_net_4_0.xml -nowarn:219,169,1591 -r:SystemWebTestShim.dll /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Global.asax /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.ashx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.master /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx.cs /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMaster.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config.4.0 /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/sub_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_02.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_03.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_04.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_05.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_06.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_07.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_08.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_09.sitemap /resource:Test/mainsoft/NunitWebResources/menuclass.aspx /resource:Test/mainsoft/NunitWebResources/FormView.aspx /resource:Test/mainsoft/NunitWebResources/PostBackMenuTest.aspx /resource:Test/mainsoft/NunitWebResources/PageWithStyleSheet.aspx /resource:Test/mainsoft/NunitWebResources/PageWithTheme.aspx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.ascx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.aspx /resource:Test/mainsoft/NunitWebResources/RunTimeSetTheme.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyBind.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyControl.ascx /resource:Test/mainsoft/NunitWebResources/Theme1.skin /resource:Test/mainsoft/NunitWebResources/Theme2.skin /resource:Test/mainsoft/NunitWebResources/UrlProperty.aspx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx.cs /resource:Test/mainsoft/NunitWebResources/Web.sitemap /resource:Test/mainsoft/NunitWebResources/WizardTest.skin /resource:Test/mainsoft/NunitWebResources/FooterTemplateTest.aspx /resource:Test/mainsoft/NunitWebResources/DataGrid.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_2.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_3.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewDataActions.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewProperties1.aspx /resource:Test/mainsoft/NunitWebResources/Bluehills.jpg /resource:Test/mainsoft/NunitWebResources/FormViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_2.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_3.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_4.aspx /resource:Test/mainsoft/NunitWebResources/FormViewInsertEditDelete.aspx /resource:Test/mainsoft/NunitWebResources/GridViewUpdate.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xml /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xsl /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest1.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest2.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest3.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest4.aspx /resource:Test/mainsoft/NunitWebResources/LoginViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/WebControl.config /resource:Test/mainsoft/NunitWebResources/WebLogin.config /resource:Test/mainsoft/NunitWebResources/CallbackTest1.aspx /resource:Test/mainsoft/NunitWebResources/CallbackTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest1.aspx /resource:Test/mainsoft/NunitWebResources/ClientScript.js /resource:Test/mainsoft/NunitWebResources/EvalTest.aspx /resource:Test/mainsoft/NunitWebResources/TemplateUserControl.ascx /resource:Test/mainsoft/NunitWebResources/WebMapping.config /resource:Test/mainsoft/NunitWebResources/Mapping.aspx /resource:Test/mainsoft/NunitWebResources/Mapping1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting2.aspx /resource:Test/mainsoft/NunitWebResources/MyDerived.master /resource:Test/mainsoft/NunitWebResources/MyPageWithDerivedMaster.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest1.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest2.aspx /resource:Test/mainsoft/NunitWebResources/PageLifecycleTest.aspx /resource:Test/mainsoft/NunitWebResources/PageValidationTest.aspx /resource:Test/mainsoft/NunitWebResources/AsyncPage.aspx /resource:Test/mainsoft/NunitWebResources/PageCultureTest.aspx /resource:Test/mainsoft/NunitWebResources/adapters.browser /resource:Test/mainsoft/NunitWebResources/NoEventValidation.aspx /resource:Test/mainsoft/NunitWebResources/ListControlPage.aspx /resource:Test/mainsoft/NunitWebResources/TextBoxTestlPage.aspx /resource:Test/mainsoft/NunitWebResources/ClearErrorOnError.aspx /resource:Test/mainsoft/NunitWebResources/RedirectOnError.aspx /resource:Test/mainsoft/NunitWebResources/TestCapability.browser /resource:Test/mainsoft/NunitWebResources/PageWithAdapter.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind5.aspx /resource:Test/mainsoft/NunitWebResources/ReadWritePropertyControl.ascx /resource:Test/mainsoft/MainsoftWebTest/nunitweb_config.xml /resource:Test/mainsoft/NunitWebResources/TemplateControlParsingTest.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.master /resource:Test/mainsoft/NunitWebResources/MissingMasterFile.aspx /resource:Test/mainsoft/NunitWebResources/CustomSectionEmptyCollection.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx.cs /resource:Test/mainsoft/NunitWebResources/LoginDisplayRememberMe.aspx /resource:Test/mainsoft/NunitWebResources/NoBindForMethodsWithBindInName.aspx /resource:Test/mainsoft/NunitWebResources/LinkInHeadWithEmbeddedExpression.aspx /resource:Test/mainsoft/NunitWebResources/ExpressionInListControl.aspx /resource:Test/mainsoft/NunitWebResources/ServerSideControlsInScriptBlock.aspx /resource:Test/mainsoft/NunitWebResources/ServerControlInClientSideComment.aspx /resource:Test/mainsoft/NunitWebResources/PreprocessorDirectivesInMarkup.aspx /resource:Test/mainsoft/NunitWebResources/UnquotedAngleBrackets.aspx /resource:Test/mainsoft/NunitWebResources/FullTagsInText.aspx /resource:Test/mainsoft/NunitWebResources/TagsExpressionsAndCommentsInText.aspx /resource:Test/mainsoft/NunitWebResources/NewlineInCodeExpression.aspx /resource:Test/mainsoft/NunitWebResources/DuplicateControlsInClientComment.aspx /resource:Test/mainsoft/NunitWebResources/TagsNestedInClientTag.aspx /resource:Test/mainsoft/NunitWebResources/ConditionalClientComments.aspx /resource:Test/mainsoft/NunitWebResources/OneLetterIdentifierInCodeRender.aspx /resource:Test/mainsoft/NunitWebResources/GlobalResourcesLocalization.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx.cs /resource:Test/mainsoft/NunitWebResources/NestedParserFileText.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CorrectConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx.cs /resource:Test/mainsoft/NunitWebResources/ChangePasswordContainer_FindControl.aspx /resource:Test/mainsoft/NunitWebResources/TagWithExpressionWithinAttribute.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug578770.aspx /resource:Test/mainsoft/NunitWebResources/EnumConverter_Bug578586.aspx /resource:Test/mainsoft/NunitWebResources/ButtonColor_Bug325489.aspx /resource:Test/mainsoft/NunitWebResources/SqlDataSource_OnInit_Bug572781.aspx /resource:Test/mainsoft/NunitWebResources/FormViewPagerVisibility.aspx /resource:Test/mainsoft/NunitWebResources/OverridenControlsPropertyAndPostBack_Bug594238.aspx /resource:Test/mainsoft/NunitWebResources/GlobalizationEncodingName.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_0.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_5.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_6.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_7.aspx /resource:Test/mainsoft/NunitWebResources/GridView_Bug595567.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug600415.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx.cs /resource:Test/mainsoft/NunitWebResources/HtmlTitleCodeRender_Bug662918.aspx /resource:Test/mainsoft/NunitWebResources/App_Code/EnumConverterControl.cs,App_Code/EnumConverterControl.cs /resource:Test/mainsoft/NunitWebResources/App_Code/MyContainer.cs,App_Code/MyContainer.cs /resource:Test/mainsoft/NunitWebResources/App_Code/CustomCheckBoxColumn.cs,App_Code/CustomCheckBoxColumn.cs /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.resx,App_GlobalResources/Common.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.fr-FR.resx,App_GlobalResources/Common.fr-FR.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Resource1.resx,App_GlobalResources/Resource1.resx</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Web.dll -unsafe -nowarn:612,618 -r:mscorlib.dll -r:System.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -d:INSIDE_SYSTEM_WEB -nowarn:618 -r:System.Configuration.dll -r:Mono.Data.Sqlite.dll -r:System.Web.ApplicationServices.dll /resource:resources/TranslationResources.resources /resource:resources/WebUIValidation.js /resource:resources/folder.gif /resource:resources/file.gif /resource:resources/computer.gif /resource:resources/arrow_minus.gif /resource:resources/arrow_noexpand.gif /resource:resources/arrow_plus.gif /resource:resources/arrow_up.gif /resource:resources/arrow_down.gif /resource:resources/box_full.gif /resource:resources/box_empty.gif /resource:resources/box_minus.gif /resource:resources/box_noexpand.gif /resource:resources/box_plus.gif /resource:resources/contact.gif /resource:resources/dot_empty.gif /resource:resources/dot_full.gif /resource:resources/dots.gif /resource:resources/inbox.gif /resource:resources/star_empty.gif /resource:resources/star_full.gif /resource:resources/warning.gif /resource:resources/TreeView_noexpand.gif /resource:resources/TreeView_dash.gif /resource:resources/TreeView_dashminus.gif /resource:resources/TreeView_dashplus.gif /resource:resources/TreeView_i.gif /resource:resources/TreeView_l.gif /resource:resources/TreeView_lminus.gif /resource:resources/TreeView_lplus.gif /resource:resources/TreeView_minus.gif /resource:resources/TreeView_plus.gif /resource:resources/TreeView_r.gif /resource:resources/TreeView_rminus.gif /resource:resources/TreeView_rplus.gif /resource:resources/TreeView_t.gif /resource:resources/TreeView_tminus.gif /resource:resources/TreeView_tplus.gif /resource:resources/transparent.gif /resource:resources/webform.js /resource:resources/WebUIValidation_2.0.js /resource:resources/ErrorTemplateCommon_Top.html /resource:resources/DefaultErrorTemplate_CustomErrorDefault.html /resource:resources/ErrorTemplateCommon_Bottom.html /resource:resources/DefaultErrorTemplate_StandardPage.html /resource:resources/HtmlizedExceptionPage_Top.html /resource:resources/HtmlizedExceptionPage_FileLongSource.html /resource:resources/HtmlizedExceptionPage_FileShortSource.html /resource:resources/HtmlizedExceptionPage_CompilerOutput.html /resource:System.Web.UI.WebControls/GridView.js /resource:System.Web.UI.WebControls/DetailsView.js /resource:System.Web.UI.WebControls/TreeView.js /resource:System.Web.UI.WebControls/Menu.js /resource:System.Web.UI.WebControls/MenuModern.js -define:WEBSERVICES_DEP -r:System.Web.Services.dll -define:MONOWEB_DEP -r:Mono.Web.dll -define:SYSTEMCORE_DEP -r:System.Core.dll -doc:System.Web_test_net_4_0.xml -nowarn:219,169,1591 -r:SystemWebTestShim.dll /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Global.asax /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.ashx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/My.master /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx.cs /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMaster.aspx /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/Web.mono.config.4.0 /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/sub_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_01.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_02.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_03.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_04.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_05.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_06.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_07.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_08.sitemap /resource:Test/mainsoft/NunitWeb/NunitWeb/Resources/test_map_09.sitemap /resource:Test/mainsoft/NunitWebResources/menuclass.aspx /resource:Test/mainsoft/NunitWebResources/FormView.aspx /resource:Test/mainsoft/NunitWebResources/PostBackMenuTest.aspx /resource:Test/mainsoft/NunitWebResources/PageWithStyleSheet.aspx /resource:Test/mainsoft/NunitWebResources/PageWithTheme.aspx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.ascx /resource:Test/mainsoft/NunitWebResources/ResolveUrl.aspx /resource:Test/mainsoft/NunitWebResources/RunTimeSetTheme.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyBind.aspx /resource:Test/mainsoft/NunitWebResources/ReadOnlyPropertyControl.ascx /resource:Test/mainsoft/NunitWebResources/Theme1.skin /resource:Test/mainsoft/NunitWebResources/Theme2.skin /resource:Test/mainsoft/NunitWebResources/UrlProperty.aspx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx /resource:Test/mainsoft/NunitWebResources/UrlProperty.ascx.cs /resource:Test/mainsoft/NunitWebResources/Web.sitemap /resource:Test/mainsoft/NunitWebResources/WizardTest.skin /resource:Test/mainsoft/NunitWebResources/FooterTemplateTest.aspx /resource:Test/mainsoft/NunitWebResources/DataGrid.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_2.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewTemplates_3.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewDataActions.aspx /resource:Test/mainsoft/NunitWebResources/DetailsViewProperties1.aspx /resource:Test/mainsoft/NunitWebResources/Bluehills.jpg /resource:Test/mainsoft/NunitWebResources/FormViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_2.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_3.aspx /resource:Test/mainsoft/NunitWebResources/FormViewTest1_4.aspx /resource:Test/mainsoft/NunitWebResources/FormViewInsertEditDelete.aspx /resource:Test/mainsoft/NunitWebResources/GridViewUpdate.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xml /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest.xsl /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest1.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest2.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest3.aspx /resource:Test/mainsoft/NunitWebResources/XMLDataSourceTest4.aspx /resource:Test/mainsoft/NunitWebResources/LoginViewTest1.aspx /resource:Test/mainsoft/NunitWebResources/WebControl.config /resource:Test/mainsoft/NunitWebResources/WebLogin.config /resource:Test/mainsoft/NunitWebResources/CallbackTest1.aspx /resource:Test/mainsoft/NunitWebResources/CallbackTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest2.aspx /resource:Test/mainsoft/NunitWebResources/EventValidationTest1.aspx /resource:Test/mainsoft/NunitWebResources/ClientScript.js /resource:Test/mainsoft/NunitWebResources/EvalTest.aspx /resource:Test/mainsoft/NunitWebResources/TemplateUserControl.ascx /resource:Test/mainsoft/NunitWebResources/WebMapping.config /resource:Test/mainsoft/NunitWebResources/Mapping.aspx /resource:Test/mainsoft/NunitWebResources/Mapping1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting1.aspx /resource:Test/mainsoft/NunitWebResources/CrossPagePosting2.aspx /resource:Test/mainsoft/NunitWebResources/MyDerived.master /resource:Test/mainsoft/NunitWebResources/MyPageWithDerivedMaster.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest1.aspx /resource:Test/mainsoft/NunitWebResources/MasterTypeTest2.aspx /resource:Test/mainsoft/NunitWebResources/PageLifecycleTest.aspx /resource:Test/mainsoft/NunitWebResources/PageValidationTest.aspx /resource:Test/mainsoft/NunitWebResources/AsyncPage.aspx /resource:Test/mainsoft/NunitWebResources/PageCultureTest.aspx /resource:Test/mainsoft/NunitWebResources/adapters.browser /resource:Test/mainsoft/NunitWebResources/NoEventValidation.aspx /resource:Test/mainsoft/NunitWebResources/ListControlPage.aspx /resource:Test/mainsoft/NunitWebResources/TextBoxTestlPage.aspx /resource:Test/mainsoft/NunitWebResources/ClearErrorOnError.aspx /resource:Test/mainsoft/NunitWebResources/RedirectOnError.aspx /resource:Test/mainsoft/NunitWebResources/TestCapability.browser /resource:Test/mainsoft/NunitWebResources/PageWithAdapter.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/InvalidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind1.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind2.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind3.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind4.aspx /resource:Test/mainsoft/NunitWebResources/ValidPropertyBind5.aspx /resource:Test/mainsoft/NunitWebResources/ReadWritePropertyControl.ascx /resource:Test/mainsoft/MainsoftWebTest/nunitweb_config.xml /resource:Test/mainsoft/NunitWebResources/TemplateControlParsingTest.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.aspx /resource:Test/mainsoft/NunitWebResources/ContentPlaceHolderInTemplate.master /resource:Test/mainsoft/NunitWebResources/MissingMasterFile.aspx /resource:Test/mainsoft/NunitWebResources/CustomSectionEmptyCollection.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx /resource:Test/mainsoft/NunitWebResources/NoDoubleOnInitOnRemoveAdd.aspx.cs /resource:Test/mainsoft/NunitWebResources/LoginDisplayRememberMe.aspx /resource:Test/mainsoft/NunitWebResources/NoBindForMethodsWithBindInName.aspx /resource:Test/mainsoft/NunitWebResources/LinkInHeadWithEmbeddedExpression.aspx /resource:Test/mainsoft/NunitWebResources/ExpressionInListControl.aspx /resource:Test/mainsoft/NunitWebResources/ServerSideControlsInScriptBlock.aspx /resource:Test/mainsoft/NunitWebResources/ServerControlInClientSideComment.aspx /resource:Test/mainsoft/NunitWebResources/PreprocessorDirectivesInMarkup.aspx /resource:Test/mainsoft/NunitWebResources/UnquotedAngleBrackets.aspx /resource:Test/mainsoft/NunitWebResources/FullTagsInText.aspx /resource:Test/mainsoft/NunitWebResources/TagsExpressionsAndCommentsInText.aspx /resource:Test/mainsoft/NunitWebResources/NewlineInCodeExpression.aspx /resource:Test/mainsoft/NunitWebResources/DuplicateControlsInClientComment.aspx /resource:Test/mainsoft/NunitWebResources/TagsNestedInClientTag.aspx /resource:Test/mainsoft/NunitWebResources/ConditionalClientComments.aspx /resource:Test/mainsoft/NunitWebResources/OneLetterIdentifierInCodeRender.aspx /resource:Test/mainsoft/NunitWebResources/GlobalResourcesLocalization.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx /resource:Test/mainsoft/NunitWebResources/TableSections_Bug551666.aspx.cs /resource:Test/mainsoft/NunitWebResources/NestedParserFileText.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CorrectConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx /resource:Test/mainsoft/NunitWebResources/StateFormatter_CollectionConverter.aspx.cs /resource:Test/mainsoft/NunitWebResources/ChangePasswordContainer_FindControl.aspx /resource:Test/mainsoft/NunitWebResources/TagWithExpressionWithinAttribute.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug377703_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug578770.aspx /resource:Test/mainsoft/NunitWebResources/EnumConverter_Bug578586.aspx /resource:Test/mainsoft/NunitWebResources/ButtonColor_Bug325489.aspx /resource:Test/mainsoft/NunitWebResources/SqlDataSource_OnInit_Bug572781.aspx /resource:Test/mainsoft/NunitWebResources/FormViewPagerVisibility.aspx /resource:Test/mainsoft/NunitWebResources/OverridenControlsPropertyAndPostBack_Bug594238.aspx /resource:Test/mainsoft/NunitWebResources/GlobalizationEncodingName.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_0.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_1.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_2.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_5.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_6.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxField_Bug595568_7.aspx /resource:Test/mainsoft/NunitWebResources/GridView_Bug595567.aspx /resource:Test/mainsoft/NunitWebResources/CheckBoxList_Bug600415.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx /resource:Test/mainsoft/NunitWebResources/BoundField_Bug646505.aspx.cs /resource:Test/mainsoft/NunitWebResources/HtmlTitleCodeRender_Bug662918.aspx /resource:Test/mainsoft/NunitWebResources/App_Code/EnumConverterControl.cs,App_Code/EnumConverterControl.cs /resource:Test/mainsoft/NunitWebResources/App_Code/MyContainer.cs,App_Code/MyContainer.cs /resource:Test/mainsoft/NunitWebResources/App_Code/CustomCheckBoxColumn.cs,App_Code/CustomCheckBoxColumn.cs /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.resx,App_GlobalResources/Common.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Common.fr-FR.resx,App_GlobalResources/Common.fr-FR.resx /resource:Test/mainsoft/NunitWebResources/App_GlobalResources/Resource1.resx,App_GlobalResources/Resource1.resx</flags>
       <output>System.Web_test_net_4_0.dll</output>
       <built_sources>System.Web/UplevelHelper.cs</built_sources>
       <library_output>System.Web_test_net_4_0.dll</library_output>
     <project dir="class/System.Web.Abstractions" library="System.Web.Abstractions-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Web.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll /r:System.Core.dll /r:System.Web.dll</flags>
       <output>System.Web.Abstractions.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Web.Abstractions.dll</library_output>
     <project dir="class/System.Web.Abstractions" library="System.Web.Abstractions-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Web.Abstractions.dll /r:System.dll /r:System.Core.dll /r:System.Web.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Web.Abstractions.dll /r:System.dll /r:System.Core.dll /r:System.Web.dll</flags>
       <output>System.Web.Abstractions_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Web.Abstractions_test_net_4_0.dll</library_output>
     <project dir="class/System.Web.Routing" library="System.Web.Routing-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Web.dll /r:System.Web.Abstractions.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll /r:System.Core.dll /r:System.Web.dll /r:System.Web.Abstractions.dll</flags>
       <output>System.Web.Routing.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Web.Routing.dll</library_output>
     <project dir="class/System.Web.Routing" library="System.Web.Routing-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Web.Routing.dll /r:System.dll /r:System.Core.dll /r:System.Web.dll /r:System.Web.Abstractions.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Web.Routing.dll /r:System.dll /r:System.Core.dll /r:System.Web.dll /r:System.Web.Abstractions.dll</flags>
       <output>System.Web.Routing_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Web.Routing_test_net_4_0.dll</library_output>
     <project dir="class/System.IdentityModel" library="System.IdentityModel-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /d:NET_3_0 /r:System.dll /r:System.Xml.dll /r:System.Security.dll /r:System.Web.dll /r:System.Configuration.dll /r:Mono.Security.dll /r:System.Runtime.Serialization.dll -r:System.Web.ApplicationServices.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /d:NET_3_0 /r:System.dll /r:System.Xml.dll /r:System.Security.dll /r:System.Web.dll /r:System.Configuration.dll /r:Mono.Security.dll /r:System.Runtime.Serialization.dll -r:System.Web.ApplicationServices.dll</flags>
       <output>System.IdentityModel.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.IdentityModel.dll</library_output>
     <project dir="class/System.IdentityModel" library="System.IdentityModel-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.IdentityModel.dll /d:NET_3_0 /r:System.dll /r:System.Xml.dll /r:System.Security.dll /r:System.Web.dll /r:System.Configuration.dll /r:Mono.Security.dll /r:System.Runtime.Serialization.dll -r:System.Web.ApplicationServices.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.IdentityModel.dll /d:NET_3_0 /r:System.dll /r:System.Xml.dll /r:System.Security.dll /r:System.Web.dll /r:System.Configuration.dll /r:Mono.Security.dll /r:System.Runtime.Serialization.dll -r:System.Web.ApplicationServices.dll</flags>
       <output>System.IdentityModel_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.IdentityModel_test_net_4_0.dll</library_output>
     <project dir="class/System.IdentityModel.Selectors" library="System.IdentityModel.Selectors-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /d:NET_3_0 /r:System.dll /r:System.Xml.dll /r:System.Security.dll /r:System.Runtime.Serialization.dll /r:System.IdentityModel.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /d:NET_3_0 /r:System.dll /r:System.Xml.dll /r:System.Security.dll /r:System.Runtime.Serialization.dll /r:System.IdentityModel.dll</flags>
       <output>System.IdentityModel.Selectors.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.IdentityModel.Selectors.dll</library_output>
     <project dir="class/System.ServiceModel" library="System.ServiceModel-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /nowarn:414,169,67,3005,436,219,618 /unsafe /d:TRACE /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.Runtime.Serialization.dll /resource:resources/WS-Addressing.schema /resource:resources/ws-addr.xsd /d:NET_3_0 /r:System.Configuration.dll /r:System.Data.dll /r:System.Security.dll /r:System.IdentityModel.dll /r:System.IdentityModel.Selectors.dll /r:System.Transactions.dll /r:System.Messaging.dll /r:System.Web.dll /r:System.Web.Services.dll /r:Mono.Security.dll /r:System.Web.ApplicationServices.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /nowarn:414,169,67,3005,436,219,618 /unsafe /d:TRACE /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.Runtime.Serialization.dll /resource:resources/WS-Addressing.schema /resource:resources/ws-addr.xsd /d:NET_3_0 /r:System.Configuration.dll /r:System.Data.dll /r:System.Security.dll /r:System.IdentityModel.dll /r:System.IdentityModel.Selectors.dll /r:System.Transactions.dll /r:System.Messaging.dll /r:System.Web.dll /r:System.Web.Services.dll /r:Mono.Security.dll /r:System.Web.ApplicationServices.dll</flags>
       <output>System.ServiceModel.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.ServiceModel.dll</library_output>
     <project dir="class/System.ServiceModel" library="System.ServiceModel-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.ServiceModel.dll /nowarn:414,169,67,3005,436,219,618 /unsafe /d:TRACE /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.Runtime.Serialization.dll /resource:resources/WS-Addressing.schema /resource:resources/ws-addr.xsd /d:NET_3_0 /r:System.Configuration.dll /r:System.Data.dll /r:System.Security.dll /r:System.IdentityModel.dll /r:System.IdentityModel.Selectors.dll /r:System.Transactions.dll /r:System.Messaging.dll /r:System.Web.dll /r:System.Web.Services.dll /r:Mono.Security.dll /r:System.Web.ApplicationServices.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.ServiceModel.dll /nowarn:414,169,67,3005,436,219,618 /unsafe /d:TRACE /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.Runtime.Serialization.dll /resource:resources/WS-Addressing.schema /resource:resources/ws-addr.xsd /d:NET_3_0 /r:System.Configuration.dll /r:System.Data.dll /r:System.Security.dll /r:System.IdentityModel.dll /r:System.IdentityModel.Selectors.dll /r:System.Transactions.dll /r:System.Messaging.dll /r:System.Web.dll /r:System.Web.Services.dll /r:Mono.Security.dll /r:System.Web.ApplicationServices.dll</flags>
       <output>System.ServiceModel_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.ServiceModel_test_net_4_0.dll</library_output>
     <project dir="class/System.Web.Extensions" library="System.Web.Extensions-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -unsafe -define:NET_3_5 -define:SYSTEM_WEB_EXTENSIONS -r:mscorlib.dll -r:System.dll -r:System.Core.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Data.Linq.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Web.Services.dll -r:System.Configuration.dll -r:System.EnterpriseServices.dll -r:System.ServiceModel.dll -r:System.Web.ApplicationServices.dll /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.js</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -unsafe -define:NET_3_5 -define:SYSTEM_WEB_EXTENSIONS -r:mscorlib.dll -r:System.dll -r:System.Core.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Data.Linq.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Web.Services.dll -r:System.Configuration.dll -r:System.EnterpriseServices.dll -r:System.ServiceModel.dll -r:System.Web.ApplicationServices.dll /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.js</flags>
       <output>System.Web.Extensions.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Web.Extensions.dll</library_output>
     <project dir="class/System.Web.Extensions" library="System.Web.Extensions-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Web.Extensions.dll -unsafe -define:NET_3_5 -define:SYSTEM_WEB_EXTENSIONS -r:mscorlib.dll -r:System.dll -r:System.Core.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Data.Linq.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Web.Services.dll -r:System.Configuration.dll -r:System.EnterpriseServices.dll -r:System.ServiceModel.dll -r:System.Web.ApplicationServices.dll /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.js -doc:System.Web.Extensions_test_net_4_0.xml -nowarn:219,169,1591 /resource:Test/resources/Web.mono.config /resource:Test/resources/profile.config.4.5 /resource:Test/resources/profile.config.4.0 /resource:Test/resources/profile.config.2.0 /resource:Test/resources/ListViewSort.aspx /resource:Test/resources/ListViewTest.aspx /resource:Test/resources/ListViewTotalRowCount_Bug535701_1.aspx /resource:Test/resources/ListViewTotalRowCount_Bug535701_2.aspx /resource:Test/resources/ListViewTotalRowCount_Bug604053.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx.cs /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/Global.asax /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/My.ashx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithDerivedMaster.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMaster.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMasterInvalidPlaceHolder.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyDerived.master /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/My.master -r:SystemWebTestShim.dll -define:SYSTEM_WEB_EXTENSIONS</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Web.Extensions.dll -unsafe -define:NET_3_5 -define:SYSTEM_WEB_EXTENSIONS -r:mscorlib.dll -r:System.dll -r:System.Core.dll -r:System.Drawing.dll -r:System.Data.dll -r:System.Data.Linq.dll -r:System.Xml.dll -r:System.Web.dll -r:System.Web.Services.dll -r:System.Configuration.dll -r:System.EnterpriseServices.dll -r:System.ServiceModel.dll -r:System.Web.ApplicationServices.dll /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.debug.js /resource:../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.js -doc:System.Web.Extensions_test_net_4_0.xml -nowarn:219,169,1591 /resource:Test/resources/Web.mono.config /resource:Test/resources/profile.config.4.5 /resource:Test/resources/profile.config.4.0 /resource:Test/resources/profile.config.2.0 /resource:Test/resources/ListViewSort.aspx /resource:Test/resources/ListViewTest.aspx /resource:Test/resources/ListViewTotalRowCount_Bug535701_1.aspx /resource:Test/resources/ListViewTotalRowCount_Bug535701_2.aspx /resource:Test/resources/ListViewTotalRowCount_Bug604053.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx.cs /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/Global.asax /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/My.ashx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPage.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithDerivedMaster.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMaster.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyPageWithMasterInvalidPlaceHolder.aspx /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/MyDerived.master /resource:../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/My.master -r:SystemWebTestShim.dll -define:SYSTEM_WEB_EXTENSIONS</flags>
       <output>System.Web.Extensions_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Web.Extensions_test_net_4_0.dll</library_output>
     <project dir="class/System.Web.Extensions.Design" library="System.Web.Extensions.Design-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -define:NET_3_5 -r:System.dll -r:System.Design.dll -r:System.Drawing.dll -r:System.Windows.Forms.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -define:NET_3_5 -r:System.dll -r:System.Design.dll -r:System.Drawing.dll -r:System.Windows.Forms.dll</flags>
       <output>System.Web.Extensions.Design.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Web.Extensions.Design.dll</library_output>
     <project dir="class/System.ComponentModel.DataAnnotations" library="System.ComponentModel.DataAnnotations-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Data.dll /r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll /r:System.Core.dll /r:System.Data.dll /r:System.Xml.dll</flags>
       <output>System.ComponentModel.DataAnnotations.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.ComponentModel.DataAnnotations.dll</library_output>
     <project dir="class/System.ComponentModel.DataAnnotations" library="System.ComponentModel.DataAnnotations-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.ComponentModel.DataAnnotations.dll /r:System.dll /r:System.Core.dll /r:System.Data.dll /r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.ComponentModel.DataAnnotations.dll /r:System.dll /r:System.Core.dll /r:System.Data.dll /r:System.Xml.dll</flags>
       <output>System.ComponentModel.DataAnnotations_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.ComponentModel.DataAnnotations_test_net_4_0.dll</library_output>
     <project dir="class/System.Web.DynamicData" library="System.Web.DynamicData-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.dll /r:System.Data.Linq.dll /r:System.Drawing.dll /r:System.Web.dll /r:System.Web.Extensions.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll -r:System.Web.ApplicationServices.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll /r:System.Core.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.dll /r:System.Data.Linq.dll /r:System.Drawing.dll /r:System.Web.dll /r:System.Web.Extensions.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll -r:System.Web.ApplicationServices.dll</flags>
       <output>System.Web.DynamicData.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Web.DynamicData.dll</library_output>
     <project dir="class/System.Web.DynamicData" library="System.Web.DynamicData-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Web.DynamicData.dll /r:System.dll /r:System.Core.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.dll /r:System.Data.Linq.dll /r:System.Drawing.dll /r:System.Web.dll /r:System.Web.Extensions.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll -r:System.Web.ApplicationServices.dll -r:System.ComponentModel.DataAnnotations.dll -r:System.Configuration.dll /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx.cs,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx.cs /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx.cs,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx.cs /resource:Test/WebPages/DynamicData/Content/Images/Back.gif,MonoTests.WebPages.DynamicData.Content.Images.Back.gif /resource:Test/WebPages/DynamicData/Content/Images/header_back.gif,MonoTests.WebPages.DynamicData.Content.Images.header_back.gif /resource:Test/WebPages/DynamicData/Content/Images/PgFirst.gif,MonoTests.WebPages.DynamicData.Content.Images.PgFirst.gif /resource:Test/WebPages/DynamicData/Content/Images/PgLast.gif,MonoTests.WebPages.DynamicData.Content.Images.PgLast.gif /resource:Test/WebPages/DynamicData/Content/Images/PgNext.gif,MonoTests.WebPages.DynamicData.Content.Images.PgNext.gif /resource:Test/WebPages/DynamicData/Content/Images/PgPrev.gif,MonoTests.WebPages.DynamicData.Content.Images.PgPrev.gif /resource:Test/WebPages/DynamicData/Content/Images/plus.gif,MonoTests.WebPages.DynamicData.Content.Images.plus.gif /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx.cs /resource:Test/WebPages/DynamicData/web.config,MonoTests.WebPages.DynamicData.web.config /resource:Test/WebPages/Global.asax,MonoTests.WebPages.Global.asax /resource:Test/WebPages/ListView_DynamicControl_01.aspx,MonoTests.WebPages.ListView_DynamicControl_01.aspx /resource:Test/WebPages/ListView_DynamicControl_01.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_01.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_02.aspx,MonoTests.WebPages.ListView_DynamicControl_02.aspx /resource:Test/WebPages/ListView_DynamicControl_02.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_02.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_03.aspx,MonoTests.WebPages.ListView_DynamicControl_03.aspx /resource:Test/WebPages/ListView_DynamicControl_03.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_03.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_04.aspx,MonoTests.WebPages.ListView_DynamicControl_04.aspx /resource:Test/WebPages/ListView_DynamicControl_04.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_04.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_05.aspx,MonoTests.WebPages.ListView_DynamicControl_05.aspx /resource:Test/WebPages/ListView_DynamicControl_05.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_05.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_06.aspx,MonoTests.WebPages.ListView_DynamicControl_06.aspx /resource:Test/WebPages/ListView_DynamicControl_06.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_06.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_07.aspx,MonoTests.WebPages.ListView_DynamicControl_07.aspx /resource:Test/WebPages/ListView_DynamicControl_07.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_07.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_08.aspx,MonoTests.WebPages.ListView_DynamicControl_08.aspx /resource:Test/WebPages/ListView_DynamicControl_08.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_08.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_09.aspx,MonoTests.WebPages.ListView_DynamicControl_09.aspx /resource:Test/WebPages/ListView_DynamicControl_09.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_09.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_10.aspx,MonoTests.WebPages.ListView_DynamicControl_10.aspx /resource:Test/WebPages/ListView_DynamicControl_10.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_10.aspx.cs /resource:Test/WebPages/DynamicValidator_01.aspx,MonoTests.WebPages.DynamicValidator_01.aspx /resource:Test/WebPages/DynamicValidator_01.aspx.cs,MonoTests.WebPages.DynamicValidator_01.aspx.cs /resource:Test/WebPages/DynamicValidator_02.aspx,MonoTests.WebPages.DynamicValidator_02.aspx /resource:Test/WebPages/DynamicValidator_02.aspx.cs,MonoTests.WebPages.DynamicValidator_02.aspx.cs /resource:Test/WebPages/Site.css,MonoTests.WebPages.Site.css /resource:Test/WebPages/Site.master,MonoTests.WebPages.Site.master /resource:Test/WebPages/Site.master.cs,MonoTests.WebPages.Site.master.cs /resource:Test/WebPages/web.config.2.0,MonoTests.WebPages.web.config.2.0 /resource:Test/WebPages/web.config.4.0,MonoTests.WebPages.web.config.4.0 -r:SystemWebTestShim.dll -r:System.Web.ApplicationServices.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Web.DynamicData.dll /r:System.dll /r:System.Core.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.dll /r:System.Data.Linq.dll /r:System.Drawing.dll /r:System.Web.dll /r:System.Web.Extensions.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll -r:System.Web.ApplicationServices.dll -r:System.ComponentModel.DataAnnotations.dll -r:System.Configuration.dll /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx.cs,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx.cs /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx.cs,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx.cs /resource:Test/WebPages/DynamicData/Content/Images/Back.gif,MonoTests.WebPages.DynamicData.Content.Images.Back.gif /resource:Test/WebPages/DynamicData/Content/Images/header_back.gif,MonoTests.WebPages.DynamicData.Content.Images.header_back.gif /resource:Test/WebPages/DynamicData/Content/Images/PgFirst.gif,MonoTests.WebPages.DynamicData.Content.Images.PgFirst.gif /resource:Test/WebPages/DynamicData/Content/Images/PgLast.gif,MonoTests.WebPages.DynamicData.Content.Images.PgLast.gif /resource:Test/WebPages/DynamicData/Content/Images/PgNext.gif,MonoTests.WebPages.DynamicData.Content.Images.PgNext.gif /resource:Test/WebPages/DynamicData/Content/Images/PgPrev.gif,MonoTests.WebPages.DynamicData.Content.Images.PgPrev.gif /resource:Test/WebPages/DynamicData/Content/Images/plus.gif,MonoTests.WebPages.DynamicData.Content.Images.plus.gif /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx.cs /resource:Test/WebPages/DynamicData/web.config,MonoTests.WebPages.DynamicData.web.config /resource:Test/WebPages/Global.asax,MonoTests.WebPages.Global.asax /resource:Test/WebPages/ListView_DynamicControl_01.aspx,MonoTests.WebPages.ListView_DynamicControl_01.aspx /resource:Test/WebPages/ListView_DynamicControl_01.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_01.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_02.aspx,MonoTests.WebPages.ListView_DynamicControl_02.aspx /resource:Test/WebPages/ListView_DynamicControl_02.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_02.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_03.aspx,MonoTests.WebPages.ListView_DynamicControl_03.aspx /resource:Test/WebPages/ListView_DynamicControl_03.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_03.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_04.aspx,MonoTests.WebPages.ListView_DynamicControl_04.aspx /resource:Test/WebPages/ListView_DynamicControl_04.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_04.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_05.aspx,MonoTests.WebPages.ListView_DynamicControl_05.aspx /resource:Test/WebPages/ListView_DynamicControl_05.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_05.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_06.aspx,MonoTests.WebPages.ListView_DynamicControl_06.aspx /resource:Test/WebPages/ListView_DynamicControl_06.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_06.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_07.aspx,MonoTests.WebPages.ListView_DynamicControl_07.aspx /resource:Test/WebPages/ListView_DynamicControl_07.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_07.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_08.aspx,MonoTests.WebPages.ListView_DynamicControl_08.aspx /resource:Test/WebPages/ListView_DynamicControl_08.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_08.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_09.aspx,MonoTests.WebPages.ListView_DynamicControl_09.aspx /resource:Test/WebPages/ListView_DynamicControl_09.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_09.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_10.aspx,MonoTests.WebPages.ListView_DynamicControl_10.aspx /resource:Test/WebPages/ListView_DynamicControl_10.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_10.aspx.cs /resource:Test/WebPages/DynamicValidator_01.aspx,MonoTests.WebPages.DynamicValidator_01.aspx /resource:Test/WebPages/DynamicValidator_01.aspx.cs,MonoTests.WebPages.DynamicValidator_01.aspx.cs /resource:Test/WebPages/DynamicValidator_02.aspx,MonoTests.WebPages.DynamicValidator_02.aspx /resource:Test/WebPages/DynamicValidator_02.aspx.cs,MonoTests.WebPages.DynamicValidator_02.aspx.cs /resource:Test/WebPages/Site.css,MonoTests.WebPages.Site.css /resource:Test/WebPages/Site.master,MonoTests.WebPages.Site.master /resource:Test/WebPages/Site.master.cs,MonoTests.WebPages.Site.master.cs /resource:Test/WebPages/web.config.2.0,MonoTests.WebPages.web.config.2.0 /resource:Test/WebPages/web.config.4.0,MonoTests.WebPages.web.config.4.0 -r:SystemWebTestShim.dll -r:System.Xml.dll -r:System.Web.ApplicationServices.dll</flags>
       <output>System.Web.DynamicData_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Web.DynamicData_test_net_4_0.dll</library_output>
     <project dir="class/System.ServiceModel.Web" library="System.ServiceModel.Web-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll -r:System.Web.Extensions.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll -r:System.Web.Extensions.dll</flags>
       <output>System.ServiceModel.Web.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.ServiceModel.Web.dll</library_output>
     <project dir="class/System.ServiceModel.Web" library="System.ServiceModel.Web-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.ServiceModel.Web.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll -r:System.Web.Extensions.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.ServiceModel.Web.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll -r:System.Web.Extensions.dll</flags>
       <output>System.ServiceModel.Web_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.ServiceModel.Web_test_net_4_0.dll</library_output>
       <fx_version>4.0</fx_version>
       <response>./../../build/deps/System.ServiceModel.Web_test_net_4_0.dll.response</response>
     </project>
-    <project dir="class/System.Web.Mvc" library="System.Web.Mvc-net_4_0">
-      <boot>false</boot>
-      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll</flags>
-      <output>dummy-System.Web.Mvc.dll</output>
-      <built_sources></built_sources>
-      <library_output>./../../class/compat/net_4_0/tmp/dummy-System.Web.Mvc.dll</library_output>
-      <fx_version>4.0</fx_version>
-      <response>System.Web.Mvc.dll.sources</response>
-    </project>
     <project dir="class/System.Web.Mvc2" library="System.Web.Mvc2-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /warnaserror- /noconfig /keyfile:../winfx.pub /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.Linq.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /warn:1 /keyfile:../winfx.pub /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.Linq.dll</flags>
       <output>dummy-System.Web.Mvc.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/dummy-System.Web.Mvc.dll</library_output>
     <project dir="class/Mono.C5" library="Mono.C5-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll -nowarn:169,219,414,1030,3001,3005,3006</flags>
       <output>Mono.C5.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.C5.dll</library_output>
     <project dir="class/Mono.C5" library="Mono.C5-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.C5.dll /r:mscorlib.dll /r:System.dll -nowarn:169 -nowarn:0618 -nowarn:219 -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.C5.dll /r:mscorlib.dll /r:System.dll -nowarn:169,219,414,1030,3001,3005,3006 -nowarn:0618 -nowarn:219 -nowarn:169</flags>
       <output>Mono.C5_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.C5_test_net_4_0.dll</library_output>
     <project dir="class/Mono.Management" library="Mono.Management-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:Mono.Posix.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:Mono.Posix.dll</flags>
       <output>Mono.Management.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/tmp/Mono.Management.dll</library_output>
     <project dir="class/Mono.Options" library="Mono.Options-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll</flags>
       <output>Mono.Options.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Options.dll</library_output>
     <project dir="class/Mono.Options" library="Mono.Options-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.Options.dll /r:Mono.Posix.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.Options.dll /r:Mono.Posix.dll /r:System.dll /r:System.Core.dll</flags>
       <output>Mono.Options_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Options_test_net_4_0.dll</library_output>
     <project dir="class/Mono.Simd" library="Mono.Simd-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.Core.dll /unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.Core.dll /unsafe</flags>
       <output>Mono.Simd.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Simd.dll</library_output>
     <project dir="class/Mono.Tasklets" library="Mono.Tasklets-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig</flags>
       <output>Mono.Tasklets.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Tasklets.dll</library_output>
     <project dir="class/System.Dynamic" library="System.Dynamic-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -unsafe -d:CODEPLEX_40 -r:System.Core.dll -r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -unsafe -d:CODEPLEX_40 -r:System.Core.dll -r:System.dll -nowarn:414,169</flags>
       <output>System.Dynamic.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Dynamic.dll</library_output>
     <project dir="class/Mono.CSharp" library="Mono.CSharp-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.Core.dll -r:System.Xml -r:System</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.Core.dll -r:System.Xml.dll -r:System.dll</flags>
       <output>Mono.CSharp.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.CSharp.dll</library_output>
     <project dir="class/Mono.CSharp" library="Mono.CSharp-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.CSharp.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.CSharp.dll -r:System.Core.dll</flags>
       <output>Mono.CSharp_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.CSharp_test_net_4_0.dll</library_output>
     <project dir="class/Moonlight.Build.Tasks" library="Moonlight.Build.Tasks-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll /r:Microsoft.Build.Tasks.v4.0.dll /r:ICSharpCode.SharpZipLib.dll -resource:Moonlight.Build.Tasks/PreviewTemplate.html</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll /r:Microsoft.Build.Tasks.v4.0.dll /r:ICSharpCode.SharpZipLib.dll -resource:Moonlight.Build.Tasks/PreviewTemplate.html</flags>
       <output>Moonlight.Build.Tasks.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Moonlight.Build.Tasks.dll</library_output>
     <project dir="class/System.Net" library="System.Net-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -unsafe -r:System.dll -r:System.Core.dll -r:System.Xml.dll -d:NET_2_1 -d:NET_2_0 -d:NET_1_1 -d:NET_3_5 -nowarn:1720</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -unsafe -r:System.dll -r:System.Core.dll -r:System.Xml.dll -d:NET_2_1 -d:NET_2_0 -d:NET_1_1 -d:NET_3_5 -nowarn:1720</flags>
       <output>System.Net.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Net.dll</library_output>
     <project dir="class/System.Numerics" library="System.Numerics-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll</flags>
       <output>System.Numerics.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Numerics.dll</library_output>
     <project dir="class/System.Numerics" library="System.Numerics-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Numerics.dll -r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Numerics.dll -r:System.dll</flags>
       <output>System.Numerics_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Numerics_test_net_4_0.dll</library_output>
     <project dir="class/Microsoft.CSharp" library="Microsoft.CSharp-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.Core.dll -r:Mono.CSharp.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.Core.dll -r:Mono.CSharp.dll</flags>
       <output>Microsoft.CSharp.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Microsoft.CSharp.dll</library_output>
     <project dir="class/Microsoft.Build" library="Microsoft.Build-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:mscorlib.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll</flags>
       <output>Microsoft.Build.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Microsoft.Build.dll</library_output>
     <project dir="class/Microsoft.Build" library="Microsoft.Build-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Microsoft.Build.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Microsoft.Build.dll</flags>
       <output>Microsoft.Build_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build_test_net_4_0.dll</library_output>
     <project dir="class/System.Windows.Forms.DataVisualization" library="System.Windows.Forms.DataVisualization-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System -r:System.Drawing -r:System.Windows.Forms -r:System.Core</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System -r:System.Drawing -r:System.Windows.Forms -r:System.Core</flags>
       <output>System.Windows.Forms.DataVisualization.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Windows.Forms.DataVisualization.dll</library_output>
     <project dir="class/System.Xaml" library="System.Xaml-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Xml.dll /r:System.Core.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /r:System.dll /r:System.Xml.dll /r:System.Core.dll</flags>
       <output>System.Xaml.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Xaml.dll</library_output>
     <project dir="class/System.Xaml" library="System.Xaml-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Xaml.dll /r:System.dll /r:System.Xml.dll /r:System.Core.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Xaml.dll /r:System.dll /r:System.Xml.dll /r:System.Core.dll</flags>
       <output>System.Xaml_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Xaml_test_net_4_0.dll</library_output>
     <project dir="class/WindowsBase" library="WindowsBase-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -unsafe -r:System -r:System.Xml -r:System.Xaml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -unsafe -r:System.dll -r:System.Xml.dll -r:System.Xaml.dll</flags>
       <output>WindowsBase.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/WindowsBase.dll</library_output>
     <project dir="class/WindowsBase" library="WindowsBase-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/WindowsBase.dll -unsafe -r:WindowsBase.dll -r:System.Xaml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/WindowsBase.dll -unsafe -r:WindowsBase.dll -r:System.dll -r:System.Xml.dll -r:System.Core.dll -r:System.Xaml.dll</flags>
       <output>WindowsBase_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>WindowsBase_test_net_4_0.dll</library_output>
     <project dir="class/System.ServiceModel.Routing" library="System.ServiceModel.Routing-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll</flags>
       <output>System.ServiceModel.Routing.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.ServiceModel.Routing.dll</library_output>
     <project dir="class/System.ServiceModel.Discovery" library="System.ServiceModel.Discovery-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -r:System.Xml.Linq.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -r:System.Xml.Linq.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll</flags>
       <output>System.ServiceModel.Discovery.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.ServiceModel.Discovery.dll</library_output>
     <project dir="class/System.ServiceModel.Discovery" library="System.ServiceModel.Discovery-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.ServiceModel.Discovery.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -r:System.Xml.Linq.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.ServiceModel.Discovery.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.ServiceModel.dll -r:System.Core.dll -r:System.Xml.Linq.dll -d:NET_3_5 -d:NET_3_0 -r:System.Configuration.dll</flags>
       <output>System.ServiceModel.Discovery_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.ServiceModel.Discovery_test_net_4_0.dll</library_output>
     <project dir="class/System.Runtime.Caching" library="System.Runtime.Caching-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Data.dll -r:System.Configuration.dll -r:System.Core.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Data.dll -r:System.Configuration.dll -r:System.Core.dll</flags>
       <output>System.Runtime.Caching.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Runtime.Caching.dll</library_output>
     <project dir="class/System.Runtime.Caching" library="System.Runtime.Caching-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Runtime.Caching.dll -r:System.dll -r:System.Data.dll -r:System.Configuration.dll -r:System.Core.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Runtime.Caching.dll -r:System.dll -r:System.Data.dll -r:System.Configuration.dll -r:System.Core.dll</flags>
       <output>System.Runtime.Caching_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Runtime.Caching_test_net_4_0.dll</library_output>
     <project dir="class/System.Runtime.DurableInstancing" library="System.Runtime.DurableInstancing-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.Core.dll -r:System.Xml.Linq.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.Core.dll -r:System.Xml.Linq.dll</flags>
       <output>System.Runtime.DurableInstancing.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Runtime.DurableInstancing.dll</library_output>
     <project dir="class/System.Runtime.DurableInstancing" library="System.Runtime.DurableInstancing-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Runtime.DurableInstancing.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.Core.dll -r:System.Xml.Linq.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Runtime.DurableInstancing.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.Core.dll -r:System.Xml.Linq.dll</flags>
       <output>System.Runtime.DurableInstancing_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Runtime.DurableInstancing_test_net_4_0.dll</library_output>
       <fx_version>4.0</fx_version>
       <response>./../../build/deps/System.Runtime.DurableInstancing_test_net_4_0.dll.response</response>
     </project>
-    <project dir="class/Mono.CodeContracts" library="Mono.CodeContracts-net_4_0">
-      <boot>false</boot>
-      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System -r:System.Core -r:Mono.Cecil.dll -r:Mono.Cecil.Mdb.dll</flags>
-      <output>Mono.CodeContracts.dll</output>
-      <built_sources></built_sources>
-      <library_output>./../../class/lib/net_4_0/Mono.CodeContracts.dll</library_output>
-      <fx_version>4.0</fx_version>
-      <response>Mono.CodeContracts.dll.sources</response>
-    </project>
-    <project dir="class/Mono.CodeContracts" library="Mono.CodeContracts-tests-net_4_0">
-      <boot>false</boot>
-      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.CodeContracts.dll</flags>
-      <output>Mono.CodeContracts_test_net_4_0.dll</output>
-      <built_sources></built_sources>
-      <library_output>Mono.CodeContracts_test_net_4_0.dll</library_output>
-      <fx_version>4.0</fx_version>
-      <response>./../../build/deps/Mono.CodeContracts_test_net_4_0.dll.response</response>
-    </project>
     <project dir="class/Mono.Parallel" library="Mono.Parallel-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -d:INSIDE_MONO_PARALLEL -r:mscorlib.dll -r:System.Core.dll -r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -d:INSIDE_MONO_PARALLEL -r:mscorlib.dll -r:System.Core.dll -r:System.dll</flags>
       <output>Mono.Parallel.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Mono.Parallel.dll</library_output>
     <project dir="class/Mono.Parallel" library="Mono.Parallel-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/Mono.Parallel.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/Mono.Parallel.dll</flags>
       <output>Mono.Parallel_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Parallel_test_net_4_0.dll</library_output>
     <project dir="class/Microsoft.Web.Infrastructure" library="Microsoft.Web.Infrastructure-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Configuration.dll -r:System.Web.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Configuration.dll -r:System.Web.dll</flags>
       <output>Microsoft.Web.Infrastructure.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/Microsoft.Web.Infrastructure.dll</library_output>
     <project dir="class/WebMatrix.Data" library="WebMatrix.Data-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Data.dll -r:System.Core.dll -r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:mscorlib.dll -r:System.dll -r:System.Data.dll -r:System.Core.dll -r:System.Configuration.dll</flags>
       <output>WebMatrix.Data.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/WebMatrix.Data.dll</library_output>
     <project dir="class/WebMatrix.Data" library="WebMatrix.Data-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/WebMatrix.Data.dll -r:System.dll -r:System.Data.dll -r:Mono.Data.Sqlite.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/WebMatrix.Data.dll -r:System.dll -r:System.Data.dll -r:Mono.Data.Sqlite.dll</flags>
       <output>WebMatrix.Data_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>WebMatrix.Data_test_net_4_0.dll</library_output>
     <project dir="class/System.Data.Services.Client" library="System.Data.Services.Client-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -d:NET_3_5 -r:System.dll -r:System.Core.dll -r:System.Xml.Linq.dll -r:System.Data.dll -r:System.Xml.dll -warn:2 -r:WindowsBase</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -d:NET_3_5 -r:System.dll -r:System.Core.dll -r:System.Xml.Linq.dll -r:System.Data.dll -r:System.Xml.dll -resource:Client/System.Data.Services.Client.resources -warn:2 -r:WindowsBase</flags>
       <output>System.Data.Services.Client.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Data.Services.Client.dll</library_output>
     <project dir="class/System.Data.Services" library="System.Data.Services-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -d:NET_3_5 -r:System.dll -r:System.Core.dll -r:System.ServiceModel.dll -r:System.ServiceModel.Web.dll -r:System.Data.Services.Client.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -d:NET_3_5 -r:System.dll -r:System.Core.dll -r:System.ServiceModel.dll -r:System.ServiceModel.Web.dll -r:System.Data.Services.Client.dll</flags>
       <output>System.Data.Services.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Data.Services.dll</library_output>
     <project dir="class/System.Data.Services" library="System.Data.Services-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Data.Services.dll -r:System.ServiceModel</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Data.Services.dll -r:System.ServiceModel.dll -r:System.Core.dll</flags>
       <output>System.Data.Services_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Data.Services_test_net_4_0.dll</library_output>
     <project dir="class/System.Json" library="System.Json-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.ServiceModel.Web.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig /d:ASPNETMVC -keyfile:../winfx.pub -delaysign /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.Runtime.Serialization.dll /r:System.ServiceModel.Web.dll /resource:System.Json.Properties.Resources.resources /r:Microsoft.CSharp.dll</flags>
       <output>System.Json.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.Json.dll</library_output>
     <project dir="class/System.Json" library="System.Json-tests-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_0/System.Json.dll /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.ServiceModel.Web.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -r:./../../class/lib/net_4_0/System.Json.dll /d:ASPNETMVC -keyfile:../winfx.pub -delaysign /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.Runtime.Serialization.dll /r:System.ServiceModel.Web.dll /resource:System.Json.Properties.Resources.resources /r:Microsoft.CSharp.dll</flags>
       <output>System.Json_test_net_4_0.dll</output>
       <built_sources></built_sources>
       <library_output>System.Json_test_net_4_0.dll</library_output>
     <project dir="class/System.ComponentModel.Composition" library="System.ComponentModel.Composition-net_4_0">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Core.dll -d:CLR40 -resource:Microsoft.Internal.Strings.resources</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_0 -r:mscorlib.dll /noconfig -r:System.dll -r:System.Core.dll -d:CLR40 -resource:Microsoft.Internal.Strings.resources</flags>
       <output>System.ComponentModel.Composition.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_0/System.ComponentModel.Composition.dll</library_output>
     <project dir="mcs" library="mcs-net_4_5">
       <boot></boot>
       <mcs>MONO_PATH=./../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -lib:./../class/lib/build -d:STATIC,NO_SYMBOL_WRITER -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -lib:./../class/lib/build -debug -d:STATIC,NO_SYMBOL_WRITER -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
       <output>mcs.exe</output>
       <built_sources>cs-parser.cs</built_sources>
       <library_output>mcs.exe</library_output>
     <project dir="class/corlib" library="corlib-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -debug -r:./../../class/lib/net_4_5/mscorlib.dll -debug+ -debug:full -nowarn:168,219,618,672 -unsafe -r:./../../class/lib/net_4_5/Mono.Posix.dll -define:MONO_DATACONVERTER_STATIC_METHODS</flags>
+      <flags>/codepage:65001 -unsafe -nostdlib -nowarn:612,618 -d:INSIDE_CORLIB -d:LIBC -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -debug -r:./../../class/lib/net_4_5/mscorlib.dll -debug+ -debug:full -nowarn:168,219,618,672 -unsafe -r:Mono.Posix.dll -r:System.Core.dll -define:MONO_DATACONVERTER_STATIC_METHODS</flags>
       <output>corlib_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>corlib_test_net_4_5.dll</library_output>
     <project dir="class/System" library="System-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
       <output>System_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System_test_net_4_5.dll</library_output>
     <project dir="class/System.XML" library="System.Xml-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data.dll -r:System.Core.dll</flags>
       <output>System.Xml_test_net_4_5.dll</output>
       <built_sources>System.Xml.XPath/Parser.cs Mono.Xml.Xsl/PatternParser.cs Mono.Xml.Xsl/PatternTokenizer.cs</built_sources>
       <library_output>System.Xml_test_net_4_5.dll</library_output>
     <project dir="class/Mono.Security" library="Mono.Security-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.dll -unsafe</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.dll -unsafe -nowarn:1030</flags>
       <output>Mono.Security.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/tmp/Mono.Security.dll</library_output>
     <project dir="class/Mono.Security" library="Mono.Security-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.Security.dll -r:System.dll -unsafe -nowarn:169,219,618,672</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.Security.dll -r:System.dll -unsafe -nowarn:1030 -nowarn:169,219,618,672</flags>
       <output>Mono.Security_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Security_test_net_4_5.dll</library_output>
     <project dir="class/System" library="System-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
       <output>System_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System_test_net_4_5.dll</library_output>
     <project dir="class/System.Configuration" library="System.Configuration-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll -nowarn:618</flags>
       <output>System.Configuration.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/tmp/System.Configuration.dll</library_output>
     <project dir="class/System.Configuration" library="System.Configuration-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Configuration.dll -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Configuration.dll -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Security.dll -nowarn:618</flags>
       <output>System.Configuration_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System.Configuration_test_net_4_5.dll</library_output>
     <project dir="class/System" library="System-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.dll -r:System.Drawing.dll -r:Mono.Security.dll -r:System.Data -r:System.Xml.dll -r:System.Core.dll -nowarn:1595 -nowarn:0618 -nowarn:219 -nowarn:67 -nowarn:169 -nowarn:612 -resource:Test/System/test-uri-props.txt,test-uri-props.txt -resource:Test/System/test-uri-props-manual.txt,test-uri-props-manual.txt -resource:Test/System/test-uri-relative-props.txt,test-uri-relative-props.txt -r:System.Configuration</flags>
       <output>System_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System_test_net_4_5.dll</library_output>
     <project dir="class/System.XML" library="System.Xml-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Xml.dll -r:mscorlib.dll -r:System.dll -nowarn:0618,0612,0642 -nowarn:0618 -nowarn:219 -nowarn:169 -r:System.Data.dll -r:System.Core.dll</flags>
       <output>System.Xml_test_net_4_5.dll</output>
       <built_sources>System.Xml.XPath/Parser.cs Mono.Xml.Xsl/PatternParser.cs Mono.Xml.Xsl/PatternTokenizer.cs</built_sources>
       <library_output>System.Xml_test_net_4_5.dll</library_output>
     <project dir="class/System.Data" library="System.Data-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Data.dll -nowarn:649 -unsafe -r:mscorlib.dll -r:./../../class/lib/net_4_5/System.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -r:Mono.Data.Tds.dll -r:System.Configuration.dll -r:System.Transactions.dll -nowarn:618,169,612,219,168</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Data.dll -nowarn:649 -unsafe -r:mscorlib.dll -r:./../../class/lib/net_4_5/System.dll -r:System.Xml.dll -r:System.EnterpriseServices.dll -r:Mono.Data.Tds.dll -r:System.Configuration.dll -r:System.Transactions.dll -r:System.Core.dll -nowarn:618,169,612,219,168</flags>
       <output>System.Data_test_net_4_5.dll</output>
       <built_sources>Mono.Data.SqlExpressions/Parser.cs</built_sources>
       <library_output>System.Data_test_net_4_5.dll</library_output>
     <project dir="class/Mono.WebBrowser" library="Mono.WebBrowser-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.dll -debug+ -nowarn:108</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.dll -warn:1</flags>
       <output>Mono.WebBrowser.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/Mono.WebBrowser.dll</library_output>
     <project dir="class/Managed.Windows.Forms" library="System.Windows.Forms-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Drawing.dll /r:Accessibility.dll /r:System.Data.dll /r:Mono.Posix.dll /r:Mono.WebBrowser @System.Windows.Forms.dll.resources -debug -nowarn:618,612,809 /r:System.Configuration.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Drawing.dll /r:Accessibility.dll /r:System.Data.dll /r:Mono.Posix.dll /r:Mono.WebBrowser /r:System.Configuration.dll @System.Windows.Forms.dll.resources -nowarn:618,612,809</flags>
       <output>System.Windows.Forms.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/System.Windows.Forms.dll</library_output>
     <project dir="class/Managed.Windows.Forms" library="System.Windows.Forms-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Windows.Forms.dll /r:System.Data.dll /r:System.Drawing.dll /r:Accessibility.dll -resource:Test/resources/a.cur,a.cur -resource:Test/resources/32x32.ico,32x32.ico -nowarn:618,612</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Windows.Forms.dll /r:System.Data.dll /r:System.Drawing.dll /r:Accessibility.dll -r:System.dll -r:System.Xml.dll -resource:Test/resources/a.cur,a.cur -resource:Test/resources/32x32.ico,32x32.ico -nowarn:618,612</flags>
       <output>System.Windows.Forms_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System.Windows.Forms_test_net_4_5.dll</library_output>
     <project dir="class/System.Design" library="System.Design-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Design.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Design.dll /r:System.dll</flags>
       <output>System.Design_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System.Design_test_net_4_5.dll</library_output>
     <project dir="class/PEAPI" library="PEAPI-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll -nowarn:414,618</flags>
       <output>PEAPI.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/PEAPI.dll</library_output>
     <project dir="class/Npgsql" library="Npgsql-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:Mono.Security.dll @Npgsql.dll.resources</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll /r:Mono.Security.dll -warn:1 @Npgsql.dll.resources</flags>
       <output>Npgsql.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/Npgsql.dll</library_output>
     <project dir="class/Novell.Directory.Ldap" library="Novell.Directory.Ldap-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /nowarn:649 /nowarn:169 /nowarn:219 /nowarn:168 -r:mscorlib.dll -r:System.dll -r:Mono.Security.dll /res:Novell.Directory.Ldap.Utilclass/ResultCodeMessages.resources</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -warn:1 -nowarn:612 -r:mscorlib.dll -r:System.dll -r:Mono.Security.dll /res:Novell.Directory.Ldap.Utilclass/ResultCodeMessages.resources</flags>
       <output>Novell.Directory.Ldap.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/Novell.Directory.Ldap.dll</library_output>
     <project dir="class/RabbitMQ.Client/src/client" library="RabbitMQ.Client-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Xml.dll -nowarn:618</flags>
       <output>RabbitMQ.Client.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../../class/lib/net_4_5/RabbitMQ.Client.dll</library_output>
     <project dir="class/Mono.Messaging.RabbitMQ" library="Mono.Messaging.RabbitMQ-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client -nowarn:618</flags>
       <output>Mono.Messaging.RabbitMQ.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/Mono.Messaging.RabbitMQ.dll</library_output>
     <project dir="class/Mono.Messaging.RabbitMQ" library="Mono.Messaging.RabbitMQ-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.Messaging.RabbitMQ.dll /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client -nowarn:0618 -nowarn:219 -nowarn:169 /r:nunit.mocks.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.Messaging.RabbitMQ.dll /r:System.dll /r:System.Messaging.dll /r:Mono.Messaging.dll /r:RabbitMQ.Client -nowarn:618 -nowarn:0618 -nowarn:219 -nowarn:169 /r:nunit.mocks.dll</flags>
       <output>Mono.Messaging.RabbitMQ_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Messaging.RabbitMQ_test_net_4_5.dll</library_output>
     <project dir="class/System.Design" library="System.Design-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Design.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Design.dll /r:System.dll</flags>
       <output>System.Design_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System.Design_test_net_4_5.dll</library_output>
     <project dir="class/ICSharpCode.SharpZipLib" library="ICSharpCode.SharpZipLib-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll /r:System.Xml.dll -warn:1</flags>
       <output>ICSharpCode.SharpZipLib.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/ICSharpCode.SharpZipLib.dll</library_output>
     <project dir="class/Mono.Http" library="Mono.Http-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:ICSharpCode.SharpZipLib.dll -r:Mono.Security.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:mscorlib.dll -r:System.dll -r:System.Xml.dll -r:System.Web.dll -r:ICSharpCode.SharpZipLib.dll -r:Mono.Security.dll -nowarn:618</flags>
       <output>Mono.Http.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/Mono.Http.dll</library_output>
     <project dir="class/IBM.Data.DB2" library="IBM.Data.DB2-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /unsafe /r:mscorlib.dll /r:System.dll /r:System.Xml.dll /r:System.Data.dll -warn:1</flags>
       <output>IBM.Data.DB2.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/IBM.Data.DB2.dll</library_output>
     <project dir="class/Mono.Debugger.Soft" library="Mono.Debugger.Soft-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.Debugger.Soft.dll /r:Mono.Cecil.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.Debugger.Soft.dll /r:Mono.Cecil.dll /r:System.dll /r:System.Core.dll</flags>
       <output>Mono.Debugger.Soft_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Debugger.Soft_test_net_4_5.dll</library_output>
     <project dir="class/Microsoft.Build.Utilities" library="Microsoft.Build.Utilities-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Microsoft.Build.Utilities.v4.0.dll /r:Microsoft.Build.Framework.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Microsoft.Build.Utilities.v4.0.dll /r:Microsoft.Build.Framework.dll -r:System.dll</flags>
       <output>Microsoft.Build.Utilities_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Utilities_test_net_4_5.dll</library_output>
     <project dir="class/Microsoft.Build.Engine" library="Microsoft.Build.Engine-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll /r:System.Xml.dll</flags>
       <output>Microsoft.Build.Engine_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Engine_test_net_4_5.dll</library_output>
     <project dir="class/Microsoft.Build.Tasks" library="Microsoft.Build.Tasks-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Microsoft.Build.Tasks.v4.0.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Microsoft.Build.Tasks.v4.0.dll /r:Microsoft.Build.Engine.dll /r:Microsoft.Build.Framework.dll /r:Microsoft.Build.Utilities.v4.0.dll /r:System.Core.dll</flags>
       <output>Microsoft.Build.Tasks_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>Microsoft.Build.Tasks_test_net_4_5.dll</library_output>
     <project dir="class/System.Data.Linq" library="System.Data.Linq-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY -warn:1</flags>
       <output>System.Data.Linq.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/System.Data.Linq.dll</library_output>
     <project dir="class/System.Data.Linq" library="System.Data.Linq-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Data.Linq.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Data.Linq.dll /r:System.dll /r:System.Core.dll /r:System.Xml.dll /r:System.Data.dll /r:System.Runtime.Serialization.dll /resource:./src/DbLinq/Schema/Dbml/DbmlSchema.xsd,DbLinq.Schema.Dbml.DbmlSchema.xsd /d:MONO_STRICT /d:MONO_DEPLOY -warn:1</flags>
       <output>System.Data.Linq_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System.Data.Linq_test_net_4_5.dll</library_output>
     <project dir="class/System.Web.DynamicData" library="System.Web.DynamicData-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Web.DynamicData.dll /r:System.dll /r:System.Core.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.dll /r:System.Data.Linq.dll /r:System.Drawing.dll /r:System.Web.dll /r:System.Web.Extensions.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll -r:System.Web.ApplicationServices.dll -r:System.ComponentModel.DataAnnotations.dll -r:System.Configuration.dll /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx.cs,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx.cs /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx.cs,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx.cs /resource:Test/WebPages/DynamicData/Content/Images/Back.gif,MonoTests.WebPages.DynamicData.Content.Images.Back.gif /resource:Test/WebPages/DynamicData/Content/Images/header_back.gif,MonoTests.WebPages.DynamicData.Content.Images.header_back.gif /resource:Test/WebPages/DynamicData/Content/Images/PgFirst.gif,MonoTests.WebPages.DynamicData.Content.Images.PgFirst.gif /resource:Test/WebPages/DynamicData/Content/Images/PgLast.gif,MonoTests.WebPages.DynamicData.Content.Images.PgLast.gif /resource:Test/WebPages/DynamicData/Content/Images/PgNext.gif,MonoTests.WebPages.DynamicData.Content.Images.PgNext.gif /resource:Test/WebPages/DynamicData/Content/Images/PgPrev.gif,MonoTests.WebPages.DynamicData.Content.Images.PgPrev.gif /resource:Test/WebPages/DynamicData/Content/Images/plus.gif,MonoTests.WebPages.DynamicData.Content.Images.plus.gif /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx.cs /resource:Test/WebPages/DynamicData/web.config,MonoTests.WebPages.DynamicData.web.config /resource:Test/WebPages/Global.asax,MonoTests.WebPages.Global.asax /resource:Test/WebPages/ListView_DynamicControl_01.aspx,MonoTests.WebPages.ListView_DynamicControl_01.aspx /resource:Test/WebPages/ListView_DynamicControl_01.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_01.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_02.aspx,MonoTests.WebPages.ListView_DynamicControl_02.aspx /resource:Test/WebPages/ListView_DynamicControl_02.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_02.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_03.aspx,MonoTests.WebPages.ListView_DynamicControl_03.aspx /resource:Test/WebPages/ListView_DynamicControl_03.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_03.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_04.aspx,MonoTests.WebPages.ListView_DynamicControl_04.aspx /resource:Test/WebPages/ListView_DynamicControl_04.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_04.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_05.aspx,MonoTests.WebPages.ListView_DynamicControl_05.aspx /resource:Test/WebPages/ListView_DynamicControl_05.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_05.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_06.aspx,MonoTests.WebPages.ListView_DynamicControl_06.aspx /resource:Test/WebPages/ListView_DynamicControl_06.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_06.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_07.aspx,MonoTests.WebPages.ListView_DynamicControl_07.aspx /resource:Test/WebPages/ListView_DynamicControl_07.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_07.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_08.aspx,MonoTests.WebPages.ListView_DynamicControl_08.aspx /resource:Test/WebPages/ListView_DynamicControl_08.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_08.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_09.aspx,MonoTests.WebPages.ListView_DynamicControl_09.aspx /resource:Test/WebPages/ListView_DynamicControl_09.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_09.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_10.aspx,MonoTests.WebPages.ListView_DynamicControl_10.aspx /resource:Test/WebPages/ListView_DynamicControl_10.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_10.aspx.cs /resource:Test/WebPages/DynamicValidator_01.aspx,MonoTests.WebPages.DynamicValidator_01.aspx /resource:Test/WebPages/DynamicValidator_01.aspx.cs,MonoTests.WebPages.DynamicValidator_01.aspx.cs /resource:Test/WebPages/DynamicValidator_02.aspx,MonoTests.WebPages.DynamicValidator_02.aspx /resource:Test/WebPages/DynamicValidator_02.aspx.cs,MonoTests.WebPages.DynamicValidator_02.aspx.cs /resource:Test/WebPages/Site.css,MonoTests.WebPages.Site.css /resource:Test/WebPages/Site.master,MonoTests.WebPages.Site.master /resource:Test/WebPages/Site.master.cs,MonoTests.WebPages.Site.master.cs /resource:Test/WebPages/web.config.2.0,MonoTests.WebPages.web.config.2.0 /resource:Test/WebPages/web.config.4.0,MonoTests.WebPages.web.config.4.0 -r:SystemWebTestShim.dll -r:System.Web.ApplicationServices.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Web.DynamicData.dll /r:System.dll /r:System.Core.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.dll /r:System.Data.Linq.dll /r:System.Drawing.dll /r:System.Web.dll /r:System.Web.Extensions.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll -r:System.Web.ApplicationServices.dll -r:System.ComponentModel.DataAnnotations.dll -r:System.Configuration.dll /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx /resource:Test/WebPages/DynamicData/Content/FilterUserControl.ascx.cs,MonoTests.WebPages.DynamicData.Content.FilterUserControl.ascx.cs /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx /resource:Test/WebPages/DynamicData/Content/GridViewPager.ascx.cs,MonoTests.WebPages.DynamicData.Content.GridViewPager.ascx.cs /resource:Test/WebPages/DynamicData/Content/Images/Back.gif,MonoTests.WebPages.DynamicData.Content.Images.Back.gif /resource:Test/WebPages/DynamicData/Content/Images/header_back.gif,MonoTests.WebPages.DynamicData.Content.Images.header_back.gif /resource:Test/WebPages/DynamicData/Content/Images/PgFirst.gif,MonoTests.WebPages.DynamicData.Content.Images.PgFirst.gif /resource:Test/WebPages/DynamicData/Content/Images/PgLast.gif,MonoTests.WebPages.DynamicData.Content.Images.PgLast.gif /resource:Test/WebPages/DynamicData/Content/Images/PgNext.gif,MonoTests.WebPages.DynamicData.Content.Images.PgNext.gif /resource:Test/WebPages/DynamicData/Content/Images/PgPrev.gif,MonoTests.WebPages.DynamicData.Content.Images.PgPrev.gif /resource:Test/WebPages/DynamicData/Content/Images/plus.gif,MonoTests.WebPages.DynamicData.Content.Images.plus.gif /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Boolean_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Boolean_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Children.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Children.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomColor.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomColor.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/CustomFieldTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.CustomFieldTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/DateTime_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.DateTime_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Decimal_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Decimal_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/ForeignKey_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.ForeignKey_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Integer_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Integer_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MultilineText_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MultilineText_Edit.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/MyCustomUIHintTemplate_Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.MyCustomUIHintTemplate_Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/MonoTests.Common.FooEmpty.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.MonoTests.Common.FooEmpty.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Boolean.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Boolean.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Byte[].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Byte[].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Char.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Char.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.Generic.List`1[System.String].ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.Generic.List`1[System.String].ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Collections.ICollection.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Collections.ICollection.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Int64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Int64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.Object.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.Object.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.SByte.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.SByte.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.String.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.String.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/System.UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.System.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt16.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt16.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt32.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt32.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx /resource:Test/WebPages/DynamicData/FieldTemplates_NonDefault/UInt64.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates_NonDefault.UInt64.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/PlainControlTemplate.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.PlainControlTemplate.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text.ascx.cs /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx /resource:Test/WebPages/DynamicData/FieldTemplates/Text_Edit.ascx.cs,MonoTests.WebPages.DynamicData.FieldTemplates.Text_Edit.ascx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Details.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Details.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Edit.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Edit.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx /resource:Test/WebPages/DynamicData/PageTemplates/Insert.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.Insert.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx /resource:Test/WebPages/DynamicData/PageTemplates/List.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.List.aspx.cs /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx /resource:Test/WebPages/DynamicData/PageTemplates/ListDetails.aspx.cs,MonoTests.WebPages.DynamicData.PageTemplates.ListDetails.aspx.cs /resource:Test/WebPages/DynamicData/web.config,MonoTests.WebPages.DynamicData.web.config /resource:Test/WebPages/Global.asax,MonoTests.WebPages.Global.asax /resource:Test/WebPages/ListView_DynamicControl_01.aspx,MonoTests.WebPages.ListView_DynamicControl_01.aspx /resource:Test/WebPages/ListView_DynamicControl_01.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_01.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_02.aspx,MonoTests.WebPages.ListView_DynamicControl_02.aspx /resource:Test/WebPages/ListView_DynamicControl_02.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_02.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_03.aspx,MonoTests.WebPages.ListView_DynamicControl_03.aspx /resource:Test/WebPages/ListView_DynamicControl_03.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_03.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_04.aspx,MonoTests.WebPages.ListView_DynamicControl_04.aspx /resource:Test/WebPages/ListView_DynamicControl_04.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_04.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_05.aspx,MonoTests.WebPages.ListView_DynamicControl_05.aspx /resource:Test/WebPages/ListView_DynamicControl_05.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_05.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_06.aspx,MonoTests.WebPages.ListView_DynamicControl_06.aspx /resource:Test/WebPages/ListView_DynamicControl_06.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_06.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_07.aspx,MonoTests.WebPages.ListView_DynamicControl_07.aspx /resource:Test/WebPages/ListView_DynamicControl_07.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_07.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_08.aspx,MonoTests.WebPages.ListView_DynamicControl_08.aspx /resource:Test/WebPages/ListView_DynamicControl_08.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_08.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_09.aspx,MonoTests.WebPages.ListView_DynamicControl_09.aspx /resource:Test/WebPages/ListView_DynamicControl_09.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_09.aspx.cs /resource:Test/WebPages/ListView_DynamicControl_10.aspx,MonoTests.WebPages.ListView_DynamicControl_10.aspx /resource:Test/WebPages/ListView_DynamicControl_10.aspx.cs,MonoTests.WebPages.ListView_DynamicControl_10.aspx.cs /resource:Test/WebPages/DynamicValidator_01.aspx,MonoTests.WebPages.DynamicValidator_01.aspx /resource:Test/WebPages/DynamicValidator_01.aspx.cs,MonoTests.WebPages.DynamicValidator_01.aspx.cs /resource:Test/WebPages/DynamicValidator_02.aspx,MonoTests.WebPages.DynamicValidator_02.aspx /resource:Test/WebPages/DynamicValidator_02.aspx.cs,MonoTests.WebPages.DynamicValidator_02.aspx.cs /resource:Test/WebPages/Site.css,MonoTests.WebPages.Site.css /resource:Test/WebPages/Site.master,MonoTests.WebPages.Site.master /resource:Test/WebPages/Site.master.cs,MonoTests.WebPages.Site.master.cs /resource:Test/WebPages/web.config.2.0,MonoTests.WebPages.web.config.2.0 /resource:Test/WebPages/web.config.4.0,MonoTests.WebPages.web.config.4.0 -r:SystemWebTestShim.dll -r:System.Xml.dll -r:System.Web.ApplicationServices.dll</flags>
       <output>System.Web.DynamicData_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System.Web.DynamicData_test_net_4_5.dll</library_output>
       <fx_version>4.5</fx_version>
       <response>./../../build/deps/System.ServiceModel.Web_test_net_4_5.dll.response</response>
     </project>
-    <project dir="class/System.Web.Mvc" library="System.Web.Mvc-net_4_5">
-      <boot>false</boot>
-      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll</flags>
-      <output>dummy-System.Web.Mvc.dll</output>
-      <built_sources></built_sources>
-      <library_output>./../../class/compat/net_4_5/tmp/dummy-System.Web.Mvc.dll</library_output>
-      <fx_version>4.5</fx_version>
-      <response>System.Web.Mvc.dll.sources</response>
-    </project>
     <project dir="class/System.Web.Mvc2" library="System.Web.Mvc2-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /warnaserror- /noconfig /keyfile:../winfx.pub /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.Linq.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /warn:1 /keyfile:../winfx.pub /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.Linq.dll</flags>
       <output>dummy-System.Web.Mvc.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/tmp/dummy-System.Web.Mvc.dll</library_output>
     <project dir="class/Mono.C5" library="Mono.C5-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:mscorlib.dll /r:System.dll -nowarn:169,219,414,1030,3001,3005,3006</flags>
       <output>Mono.C5.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/Mono.C5.dll</library_output>
     <project dir="class/Mono.C5" library="Mono.C5-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.C5.dll /r:mscorlib.dll /r:System.dll -nowarn:169 -nowarn:0618 -nowarn:219 -nowarn:169</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.C5.dll /r:mscorlib.dll /r:System.dll -nowarn:169,219,414,1030,3001,3005,3006 -nowarn:0618 -nowarn:219 -nowarn:169</flags>
       <output>Mono.C5_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.C5_test_net_4_5.dll</library_output>
     <project dir="class/Mono.Options" library="Mono.Options-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.Options.dll /r:Mono.Posix.dll /r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.Options.dll /r:Mono.Posix.dll /r:System.dll /r:System.Core.dll</flags>
       <output>Mono.Options_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.Options_test_net_4_5.dll</library_output>
     <project dir="class/System.Dynamic" library="System.Dynamic-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -unsafe -d:CODEPLEX_40 -r:System.Core.dll -r:System.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -unsafe -d:CODEPLEX_40 -r:System.Core.dll -r:System.dll -nowarn:414,169</flags>
       <output>System.Dynamic.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/System.Dynamic.dll</library_output>
     <project dir="class/Mono.CSharp" library="Mono.CSharp-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.Core.dll -r:System.Xml -r:System</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.Core.dll -r:System.Xml.dll -r:System.dll</flags>
       <output>Mono.CSharp.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/Mono.CSharp.dll</library_output>
     <project dir="class/Mono.CSharp" library="Mono.CSharp-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.CSharp.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.CSharp.dll -r:System.Core.dll</flags>
       <output>Mono.CSharp_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>Mono.CSharp_test_net_4_5.dll</library_output>
     <project dir="class/WindowsBase" library="WindowsBase-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -unsafe -r:System -r:System.Xml -r:System.Xaml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -unsafe -r:System.dll -r:System.Xml.dll -r:System.Xaml.dll</flags>
       <output>WindowsBase.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/WindowsBase.dll</library_output>
     <project dir="class/WindowsBase" library="WindowsBase-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/WindowsBase.dll -unsafe -r:WindowsBase.dll -r:System.Xaml.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/WindowsBase.dll -unsafe -r:WindowsBase.dll -r:System.dll -r:System.Xml.dll -r:System.Core.dll -r:System.Xaml.dll</flags>
       <output>WindowsBase_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>WindowsBase_test_net_4_5.dll</library_output>
       <fx_version>4.5</fx_version>
       <response>./../../build/deps/System.Runtime.DurableInstancing_test_net_4_5.dll.response</response>
     </project>
-    <project dir="class/Mono.CodeContracts" library="Mono.CodeContracts-net_4_5">
-      <boot>false</boot>
-      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System -r:System.Core -r:Mono.Cecil.dll -r:Mono.Cecil.Mdb.dll</flags>
-      <output>Mono.CodeContracts.dll</output>
-      <built_sources></built_sources>
-      <library_output>./../../class/lib/net_4_5/Mono.CodeContracts.dll</library_output>
-      <fx_version>4.5</fx_version>
-      <response>Mono.CodeContracts.dll.sources</response>
-    </project>
-    <project dir="class/Mono.CodeContracts" library="Mono.CodeContracts-tests-net_4_5">
-      <boot>false</boot>
-      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.CodeContracts.dll</flags>
-      <output>Mono.CodeContracts_test_net_4_5.dll</output>
-      <built_sources></built_sources>
-      <library_output>Mono.CodeContracts_test_net_4_5.dll</library_output>
-      <fx_version>4.5</fx_version>
-      <response>./../../build/deps/Mono.CodeContracts_test_net_4_5.dll.response</response>
-    </project>
     <project dir="class/Mono.Parallel" library="Mono.Parallel-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
     <project dir="class/System.Data.Services.Client" library="System.Data.Services.Client-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -d:NET_3_5 -r:System.dll -r:System.Core.dll -r:System.Xml.Linq.dll -r:System.Data.dll -r:System.Xml.dll -warn:2 -r:WindowsBase</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -d:NET_3_5 -r:System.dll -r:System.Core.dll -r:System.Xml.Linq.dll -r:System.Data.dll -r:System.Xml.dll -resource:Client/System.Data.Services.Client.resources -warn:2 -r:WindowsBase</flags>
       <output>System.Data.Services.Client.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/System.Data.Services.Client.dll</library_output>
     <project dir="class/System.Data.Services" library="System.Data.Services-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Data.Services.dll -r:System.ServiceModel</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Data.Services.dll -r:System.ServiceModel.dll -r:System.Core.dll</flags>
       <output>System.Data.Services_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System.Data.Services_test_net_4_5.dll</library_output>
     <project dir="class/System.Json" library="System.Json-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.ServiceModel.Web.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /d:ASPNETMVC -keyfile:../winfx.pub -delaysign /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.Runtime.Serialization.dll /r:System.ServiceModel.Web.dll /resource:System.Json.Properties.Resources.resources /r:Microsoft.CSharp.dll</flags>
       <output>System.Json.dll</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/System.Json.dll</library_output>
     <project dir="class/System.Json" library="System.Json-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Json.dll /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.ServiceModel.Web.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Json.dll /d:ASPNETMVC -keyfile:../winfx.pub -delaysign /r:System.dll /r:System.Xml.dll /r:System.Core.dll /r:System.Runtime.Serialization.dll /r:System.ServiceModel.Web.dll /resource:System.Json.Properties.Resources.resources /r:Microsoft.CSharp.dll</flags>
       <output>System.Json_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System.Json_test_net_4_5.dll</library_output>
     <project dir="class/System.Threading.Tasks.Dataflow" library="System.Threading.Tasks.Dataflow-tests-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Threading.Tasks.Dataflow.dll</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Threading.Tasks.Dataflow.dll -r:System.Core.dll</flags>
       <output>System.Threading.Tasks.Dataflow_test_net_4_5.dll</output>
       <built_sources></built_sources>
       <library_output>System.Threading.Tasks.Dataflow_test_net_4_5.dll</library_output>
       <fx_version>4.5</fx_version>
       <response>System.ComponentModel.Composition.dll.sources</response>
     </project>
+    <project dir="class/System.Net.Http" library="System.Net.Http-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.Core.dll -r:System.dll</flags>
+      <output>System.Net.Http.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/System.Net.Http.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>System.Net.Http.dll.sources</response>
+    </project>
+    <project dir="class/System.Net.Http" library="System.Net.Http-tests-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/System.Net.Http.dll -r:System.dll -r:System.Core.dll</flags>
+      <output>System.Net.Http_test_net_4_5.dll</output>
+      <built_sources></built_sources>
+      <library_output>System.Net.Http_test_net_4_5.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>./../../build/deps/System.Net.Http_test_net_4_5.dll.response</response>
+    </project>
+    <project dir="class/System.Web.Razor" library="System.Web.Razor-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /warn:1 /keyfile:../winfx.pub -delaysign /r:System.dll /r:System.Core.dll /d:ASPNETWEBPAGES /resource:System.Web.Razor.Resources.RazorResources.resources /resource:System.Web.Razor.Common.CommonResources.resources</flags>
+      <output>System.Web.Razor.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/System.Web.Razor.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>System.Web.Razor.dll.sources</response>
+    </project>
+    <project dir="class/System.Web.WebPages.Deployment" library="System.Web.WebPages.Deployment-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /warn:1 /keyfile:../winfx.pub -delaysign /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Web.dll /r:Microsoft.Web.Infrastructure.dll /d:ASPNETWEBPAGES /resource:System.Web.WebPages.Deployment.Common.CommonResources.resources /resource:System.Web.WebPages.Deployment.Resources.ConfigurationResources.resources</flags>
+      <output>System.Web.WebPages.Deployment.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/System.Web.WebPages.Deployment.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>System.Web.WebPages.Deployment.dll.sources</response>
+    </project>
+    <project dir="class/System.Web.WebPages" library="System.Web.WebPages-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /warn:1 /keyfile:../winfx.pub /delaysign /r:Microsoft.CSharp.dll /r:Microsoft.Web.Infrastructure.dll /r:System.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Configuration.dll /r:System.Core.dll /r:System.Data.Linq.dll /r:System.Web.dll /r:System.Web.WebPages.Deployment.dll /r:System.Web.Razor.dll /r:System.Xml.dll /r:System.Xml.Linq.dll /d:ASPNETWEBPAGES /resource:System.Web.WebPages.Resources.WebPageResources.resources /resource:System.Web.WebPages.Common.CommonResources.resources</flags>
+      <output>System.Web.WebPages.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/System.Web.WebPages.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>System.Web.WebPages.dll.sources</response>
+    </project>
+    <project dir="class/System.Web.WebPages.Razor" library="System.Web.WebPages.Razor-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /warn:1 /keyfile:../winfx.pub /delaysign /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Web.dll /r:System.Web.WebPages.dll /r:System.Web.Razor.dll /d:ASPNETWEBPAGES /resource:System.Web.WebPages.Razor.Resources.RazorWebResources.resources /resource:System.Web.WebPages.Razor.Common.CommonResources.resources</flags>
+      <output>System.Web.WebPages.Razor.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/System.Web.WebPages.Razor.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>System.Web.WebPages.Razor.dll.sources</response>
+    </project>
+    <project dir="class/System.Web.Mvc3" library="System.Web.Mvc3-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /warn:1 /keyfile:../winfx.pub /d:MONO /delaysign /r:Microsoft.Web.Infrastructure.dll /r:System.dll /r:System.Core.dll /r:System.Configuration.dll /r:System.Data.dll /r:System.Xml.dll /r:System.Web.dll /r:System.Web.Abstractions.dll /r:System.Web.Routing.dll /r:System.Web.Extensions.dll /r:System.ComponentModel.DataAnnotations.dll /r:System.Data.Linq.dll /r:System.Runtime.Caching.dll /r:System.Web.Razor.dll /r:System.Web.WebPages.Razor.dll /r:System.Web.WebPages.dll /resource:Mvc/Resources/MvcResources.resources,System.Web.Mvc.Resources.MvcResources.resources</flags>
+      <output>System.Web.Mvc.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/tmp/System.Web.Mvc.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>System.Web.Mvc3.dll.sources</response>
+    </project>
+    <project dir="class/System.Net.Http.Formatting" library="System.Net.Http.Formatting-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.Core.dll -r:System.dll -r:System.Net.Http.dll -r:System.Xml.dll -r:System.Runtime.Serialization.dll -r:System.Xml.Linq.dll -r:System.Data.dll -r:System.Configuration.dll -d:ASPNETMVC -keyfile:../winfx.pub -delaysign -resource:System.Net.Http.Properties.CommonWebApiResources.resources</flags>
+      <output>System.Net.Http.Formatting.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/System.Net.Http.Formatting.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>System.Net.Http.Formatting.dll.sources</response>
+    </project>
+    <project dir="class/System.Web.Http" library="System.Web.Http-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.Core.dll -r:System.dll -r:System.Xml.dll -r:System.Net.Http.dll -r:System.ComponentModel.DataAnnotations.dll -r:System.Net.Http.Formatting.dll -r:System.Runtime.Caching.dll -r:System.Runtime.Serialization.dll -r:System.Data.Linq.dll -d:ASPNETMVC -keyfile:../winfx.pub -delaysign</flags>
+      <output>System.Web.Http.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/System.Web.Http.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>System.Web.Http.dll.sources</response>
+    </project>
+    <project dir="class/Mono.CodeContracts" library="Mono.CodeContracts-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -r:System.dll -r:System.Core.dll -r:Mono.Cecil.dll -r:Mono.Cecil.Mdb.dll</flags>
+      <output>Mono.CodeContracts.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/Mono.CodeContracts.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>Mono.CodeContracts.dll.sources</response>
+    </project>
+    <project dir="class/Mono.CodeContracts" library="Mono.CodeContracts-tests-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug -r:./../../class/lib/net_4_5/Mono.CodeContracts.dll -r:System.Core.dll</flags>
+      <output>Mono.CodeContracts_test_net_4_5.dll</output>
+      <built_sources></built_sources>
+      <library_output>Mono.CodeContracts_test_net_4_5.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>./../../build/deps/Mono.CodeContracts_test_net_4_5.dll.response</response>
+    </project>
     <project dir="nunit24/NUnit.Framework/framework" library="NUnit.Framework-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig -debug /r:System.Xml.dll /r:System.dll /d:StronglyNamedAssembly</flags>
+      <flags>/codepage:65001 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /r:System.Xml.dll /r:System.dll /d:StronglyNamedAssembly -warn:1</flags>
       <output>nunit.framework.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_4_5/nunit.framework.dll</library_output>
     <project dir="nunit20/NUnitCore/core" library="nunit.core-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 -debug -r:nunit.framework.dll -r:nunit.core.interfaces.dll -r:System.dll /d:StronglyNamedAssembly -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 -r:nunit.framework.dll -r:nunit.core.interfaces.dll -r:System.dll /d:StronglyNamedAssembly -warn:1 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
       <output>nunit.core.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_4_5/nunit.core.dll</library_output>
     <project dir="nunit24/ClientUtilities/util" library="nunit.util-net_4_5">
       <boot>false</boot>
       <mcs>MONO_PATH=./../../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /resource:Transform.resources,NUnit.Util.Transform.resources -r:nunit.core.dll -r:nunit.core.interfaces.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Remoting.dll /d:MONO /d:StronglyNamedAssembly -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /resource:Transform.resources,NUnit.Util.Transform.resources -r:nunit.core.dll -r:nunit.core.interfaces.dll -r:System.dll -r:System.Xml.dll -r:System.Runtime.Remoting.dll /d:MONO /d:StronglyNamedAssembly -warn:1 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
       <output>nunit.util.dll</output>
       <built_sources></built_sources>
       <library_output>./../../../class/lib/net_4_5/nunit.util.dll</library_output>
       <fx_version>4.5</fx_version>
       <response>dtd2xsd.exe.sources</response>
     </project>
+    <project dir="tools/monodoc" library="monodoc-net_4_5">
+      <boot>false</boot>
+      <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
+      <flags>/codepage:65001 /nowarn:618,612,672,809 -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig /codepage:utf8 /nowarn:169,164,162,168,219,618,612 /r:Commons.Xml.Relaxng /resource:../../docs/monodoc.xml,monodoc.xml /resource:Resources/base.css,base.css /resource:Resources/ecmaspec-html-css.xsl,ecmaspec-html-css.xsl /resource:Resources/ecmaspec-html.xsl,ecmaspec-html.xsl /resource:Resources/ecmaspec.css,ecmaspec.css /resource:Resources/helper.js,helper.js /resource:Resources/home.html,home.html /resource:Resources/Lminus.gif,Lminus.gif /resource:Resources/Lplus.gif,Lplus.gif /resource:Resources/mdoc-html-format.xsl,mdoc-html-format.xsl /resource:Resources/mdoc-html-utils.xsl,mdoc-html-utils.xsl /resource:Resources/mdoc-sections-css.xsl,mdoc-sections-css.xsl /resource:Resources/mdoc-sections.xsl,mdoc-sections.xsl /resource:Resources/mono-ecma-css.xsl,mono-ecma-css.xsl /resource:Resources/mono-ecma-impl.xsl,mono-ecma-impl.xsl /resource:Resources/mono-ecma.css,mono-ecma.css /resource:Resources/mono-ecma.xsl,mono-ecma.xsl /resource:Resources/images/bc_bg.png,bc_bg.png /resource:Resources/images/bc_separator.png,bc_separator.png /resource:Resources/images/error.png,error.png /resource:Resources/images/hatch.png,hatch.png /resource:Resources/images/headerbg.png,headerbg.png /resource:Resources/images/help.png,help.png /resource:Resources/images/house.png,house.png /resource:Resources/images/members.png,members.png /resource:Resources/images/namespace.png,namespace.png /resource:Resources/images/privclass.png,privclass.png /resource:Resources/images/privdelegate.png,privdelegate.png /resource:Resources/images/privenumeration.png,privenumeration.png /resource:Resources/images/privevent.png,privevent.png /resource:Resources/images/privextension.png,privextension.png /resource:Resources/images/privfield.png,privfield.png /resource:Resources/images/privinterface.png,privinterface.png /resource:Resources/images/privmethod.png,privmethod.png /resource:Resources/images/privproperty.png,privproperty.png /resource:Resources/images/privstructure.png,privstructure.png /resource:Resources/images/protclass.png,protclass.png /resource:Resources/images/protdelegate.png,protdelegate.png /resource:Resources/images/protenumeration.png,protenumeration.png /resource:Resources/images/protevent.png,protevent.png /resource:Resources/images/protextension.png,protextension.png /resource:Resources/images/protfield.png,protfield.png /resource:Resources/images/protinterface.png,protinterface.png /resource:Resources/images/protmethod.png,protmethod.png /resource:Resources/images/protproperty.png,protproperty.png /resource:Resources/images/protstructure.png,protstructure.png /resource:Resources/images/pubclass.png,pubclass.png /resource:Resources/images/pubdelegate.png,pubdelegate.png /resource:Resources/images/pubenumeration.png,pubenumeration.png /resource:Resources/images/pubevent.png,pubevent.png /resource:Resources/images/pubextension.png,pubextension.png /resource:Resources/images/pubfield.png,pubfield.png /resource:Resources/images/pubinterface.png,pubinterface.png /resource:Resources/images/pubmethod.png,pubmethod.png /resource:Resources/images/pubproperty.png,pubproperty.png /resource:Resources/images/pubstructure.png,pubstructure.png /resource:Resources/images/reference.png,reference.png /resource:Resources/images/treebg.png,treebg.png /r:ICSharpCode.SharpZipLib /r:mscorlib.dll /r:System.dll /r:System.Core.dll /r:System.Web /r:System.Web.Services /r:System.Xml.dll /r:System.Configuration.dll</flags>
+      <output>monodoc.dll</output>
+      <built_sources></built_sources>
+      <library_output>./../../class/lib/net_4_5/monodoc.dll</library_output>
+      <fx_version>4.5</fx_version>
+      <response>monodoc.dll.sources</response>
+    </project>
     <project dir="tools/mdoc" library="mdoc-net_4_5">
       <boot></boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /resource:../monodoc/Resources/mdoc-html-format.xsl,mdoc-html-format.xsl /resource:../monodoc/Resources/mdoc-html-utils.xsl,mdoc-html-utils.xsl /resource:../monodoc/Resources/mdoc-sections-css.xsl,mdoc-sections-css.xsl /resource:../monodoc/Resources/mono-ecma-css.xsl,mono-ecma-css.xsl /resource:Resources/defaulttemplate.xsl,defaulttemplate.xsl /resource:Resources/monodoc-ecma.xsd,monodoc-ecma.xsd /resource:Resources/msitomsx.xsl,msitomsx.xsl /resource:Resources/overview.xsl,overview.xsl /resource:Resources/stylesheet.xsl,stylesheet.xsl /r:System.Web.dll /r:System.Xml.Linq.dll /r:ICSharpCode.SharpZipLib.dll /r:Mono.Cecil.dll /r:./../../class/lib/net_2_0/monodoc.dll -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /resource:../monodoc/Resources/mdoc-html-format.xsl,mdoc-html-format.xsl /resource:../monodoc/Resources/mdoc-html-utils.xsl,mdoc-html-utils.xsl /resource:../monodoc/Resources/mdoc-sections-css.xsl,mdoc-sections-css.xsl /resource:../monodoc/Resources/mono-ecma-css.xsl,mono-ecma-css.xsl /resource:Resources/defaulttemplate.xsl,defaulttemplate.xsl /resource:Resources/monodoc-ecma.xsd,monodoc-ecma.xsd /resource:Resources/msitomsx.xsl,msitomsx.xsl /resource:Resources/overview.xsl,overview.xsl /resource:Resources/stylesheet.xsl,stylesheet.xsl /r:System.Web.dll /r:System.Xml.Linq.dll /r:ICSharpCode.SharpZipLib.dll /r:Mono.Cecil.dll /r:monodoc.dll -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
       <output>mdoc.exe</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/mdoc.exe</library_output>
     <project dir="tools/mod" library="mod-net_4_5">
       <boot></boot>
       <mcs>MONO_PATH=./../../class/lib/build: /home/marek/git/mono/runtime/mono-wrapper ./../../class/lib/build/mcs.exe</mcs>
-      <flags>/codepage:65001 /r:./../../class/lib/net_2_0/monodoc.dll -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
+      <flags>/codepage:65001 /r:monodoc.dll -optimize -d:NET_1_1 -d:NET_2_0 -d:NET_3_0 -d:NET_3_5 -d:NET_4_0 -d:NET_4_5 -nowarn:1699 -nostdlib -lib:./../../class/lib/net_4_5 -r:mscorlib.dll -debug /noconfig</flags>
       <output>mod.exe</output>
       <built_sources></built_sources>
       <library_output>./../../class/lib/net_4_5/mod.exe</library_output>
index ff15ae536614511f17be5c1e295afd987196c875..a25b55e99813b0de771262f276765644d9d99f7e 100644 (file)
@@ -86,7 +86,7 @@
     </ProjectReference>\r
     <Link>\r
       <AdditionalDependencies>Ws2_32.lib;Psapi.lib;eglib.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
-      <AdditionalLibraryDirectories>$(Platform)_$(Configuration)/lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
+      <AdditionalLibraryDirectories>$(Platform)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
       <GenerateDebugInformation>true</GenerateDebugInformation>\r
       <OptimizeReferences>false</OptimizeReferences>\r
       <EnableCOMDATFolding>false</EnableCOMDATFolding>\r
     </ProjectReference>\r
     <Link>\r
       <AdditionalDependencies>Ws2_32.lib;Psapi.lib;eglib.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
-      <AdditionalLibraryDirectories>$(Platform)_$(Configuration)/lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
+      <AdditionalLibraryDirectories>$(Platform)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
       <RandomizedBaseAddress>false</RandomizedBaseAddress>\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
     </ProjectReference>\r
     <Link>\r
       <AdditionalDependencies>Ws2_32.lib;Psapi.lib;eglib.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
-      <AdditionalLibraryDirectories>$(Platform)_$(Configuration)/lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
+      <AdditionalLibraryDirectories>$(Platform)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
       <GenerateDebugInformation>true</GenerateDebugInformation>\r
       <OptimizeReferences>false</OptimizeReferences>\r
       <EnableCOMDATFolding>false</EnableCOMDATFolding>\r
     </ProjectReference>\r
     <Link>\r
       <AdditionalDependencies>Ws2_32.lib;Psapi.lib;eglib.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
-      <AdditionalLibraryDirectories>$(Platform)_$(Configuration)/lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
+      <AdditionalLibraryDirectories>$(Platform)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
       <TargetMachine>MachineX64</TargetMachine>\r
     </Link>\r
   </ItemDefinitionGroup>\r
index bf41c1cdf28881932840da84d76abe2bf004498d..caf902408dea106f53b331186c25aa71ac29974b 100644 (file)
@@ -148,6 +148,7 @@ EXTRA_DIST =                        \
        mono-find-provides.in   \
        mono-find-requires.in   \
        peverify.in                     \
+       update_submodules               \
        mcs.in                          \
        gmcs.in                         \
        dmcs.in                         \
index 241f9a6a0c4929802be5ffe629b642a4e0d9cbc6..8ab10a0b28f916d1572ebd16a4838b8e5a21edbe 100755 (executable)
@@ -25,16 +25,16 @@ if [ $? -ne 0 ] ; then
 fi
 
 # compile
-${SED} -e 's/^\t\(if \)\?$(COMPILE)/\t$(if $(V),,@echo -e "CC\\t$@";) \1$(COMPILE)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
-${SED} -e 's/^\t\(if \)\?$(LTCOMPILE)/\t$(if $(V),,@echo -e "CC\\t$@";) \1$(LTCOMPILE)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
-${SED} -e 's/^\t\(if \)\?$(LTCXXCOMPILE)/\t$(if $(V),,@echo -e "CC\\t$@";) \1$(LTCXXCOMPILE)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
-${SED} -e 's/^\t\(if \)\?$(LIBTOOL)/\t$(if $(V),,@echo -e "CC\\t$@";) \1$(LIBTOOL)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
+${SED} -e 's/^\t\(if \)\?$(COMPILE)/\t$(if $(V),,@echo "CC      $@";) \1$(COMPILE)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
+${SED} -e 's/^\t\(if \)\?$(LTCOMPILE)/\t$(if $(V),,@echo "CC      $@";) \1$(LTCOMPILE)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
+${SED} -e 's/^\t\(if \)\?$(LTCXXCOMPILE)/\t$(if $(V),,@echo "CC      $@";) \1$(LTCXXCOMPILE)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
+${SED} -e 's/^\t\(if \)\?$(LIBTOOL)/\t$(if $(V),,@echo "CC      $@";) \1$(LIBTOOL)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
 # link
 # automake defines multiple symbols ending with LINK
-${SED} -e 's/^\t$(\(.*LINK\))/\t$(if $(V),,@echo -e "LD\\t$@";) $(\1)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
-#sed -e 's/LINK = $(LIBTOOL)/LINK = $(if $(V),,@echo -e "LD\\t$@";) $(LIBTOOL)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
+${SED} -e 's/^\t$(\(.*LINK\))/\t$(if $(V),,@echo "LD      $@";) $(\1)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
+#sed -e 's/LINK = $(LIBTOOL)/LINK = $(if $(V),,@echo "LD      $@";) $(LIBTOOL)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
 # CC
-${SED} -e 's/^\t\(if \)\?$(CC)/\t$(if $(V),,@echo -e "CC\\t$@";) \1$(CC)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
+${SED} -e 's/^\t\(if \)\?$(CC)/\t$(if $(V),,@echo "CC      $@";) \1$(CC)/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
 # mv
 ${SED} -e 's/^\tmv -f/\t$(if $(V),,@)mv -f/g' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
 ${SED} -e 's/^am__mv = /&$(if $(V),,@)/' < $src > $src.tmp && cp $src.tmp $src && rm -f $src.tmp
diff --git a/scripts/update_submodules b/scripts/update_submodules
new file mode 100755 (executable)
index 0000000..22109b9
--- /dev/null
@@ -0,0 +1,9 @@
+SUBMODULE_ERROR='Could not recursively update all git submodules. You may experience compilation problems if some submodules are out of date'
+SUBMODULE_OK='Git submodules updated successfully'
+if test -d .git; then \
+          (git submodule update --init --recursive && echo $SUBMODULE_OK) \
+       || (git submodule init && git submodule update --recursive && echo $SUBMODULE_OK) \
+       || (git submodule init && git submodule update && echo $SUBMODULE_ERROR) \
+       || (echo 'Git submodules could not be updated. Compilation will fail') \
+fi
+
index 6dff0ce7cc998705f560470293e69c5fc852d0d0..0e271f649a15b1eeecffbd9e22e51bc158214701 100644 (file)
@@ -1,7 +1,6 @@
 /Makefile
 /Makefile.in
 /culture-info-tables.h
-/icu_locales.tar.gz
+/*.zip
 /locale-builder.exe
 /locale-builder.exe.mdb
-/icu_langs.tar.gz
diff --git a/tools/locale-builder/CLDR/.gitignore b/tools/locale-builder/CLDR/.gitignore
new file mode 100644 (file)
index 0000000..d66298e
--- /dev/null
@@ -0,0 +1 @@
+common
\ No newline at end of file
diff --git a/tools/locale-builder/CLDR/README.txt b/tools/locale-builder/CLDR/README.txt
new file mode 100644 (file)
index 0000000..89174bc
--- /dev/null
@@ -0,0 +1,5 @@
+CLDR - Unicode Common Locale Data Repository
+
+Downloaded from http://cldr.unicode.org/index/downloads
+
+The latest used version is: 21
\ No newline at end of file
diff --git a/tools/locale-builder/CalendarType.cs b/tools/locale-builder/CalendarType.cs
new file mode 100644 (file)
index 0000000..f7c0c78
--- /dev/null
@@ -0,0 +1,40 @@
+//
+// CalendarType.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+
+namespace Mono.Tools.LocaleBuilder
+{
+       public enum CalendarType
+       {
+               Gregorian = 1,
+               ThaiBuddhist = 2,
+               UmAlQuraCalendar = 3,
+               HijriCalendar = 4
+       }
+}
diff --git a/tools/locale-builder/Constants.cs b/tools/locale-builder/Constants.cs
new file mode 100644 (file)
index 0000000..b6cbd23
--- /dev/null
@@ -0,0 +1,48 @@
+//
+// Constants.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+
+namespace Mono.Tools.LocaleBuilder
+{
+       static class Constants
+       {
+               //
+               // All values must match defines from culture-info.h
+               // 
+               public const int NUM_DAYS = 7;
+               public const int NUM_MONTHS = 13;
+               public const int GROUP_SIZE = 2;
+               public const int NUM_CALENDARS = 4;
+
+               public const int NUM_SHORT_DATE_PATTERNS = 14;
+               public const int NUM_LONG_DATE_PATTERNS = 8;
+               public const int NUM_SHORT_TIME_PATTERNS = 12;
+               public const int NUM_LONG_TIME_PATTERNS = 9;
+       }
+}
index fb9f642e2420449bbb9f702b218fbecfc3a41649..4aefd7cc94365f129466085043ee72101054524f 100644 (file)
 
 using System;
 using System.Text;
+using System.Collections.Generic;
+using System.Globalization;
 
-namespace Mono.Tools.LocaleBuilder {
+namespace Mono.Tools.LocaleBuilder
+{
+       public class CultureInfoEntry : Entry
+       {
+               string language;
 
-        public class CultureInfoEntry : Entry {
+               public string Script;
+               public string Territory;
 
-               public static CultureInfoEntry ShallowCopy (CultureInfoEntry e)
+               public string EnglishName;
+               public string DisplayName;
+               public string NativeName;
+               public string ThreeLetterWindowsLanguageName;
+               public string TwoLetterISOLanguageName;
+               public string ThreeLetterISOLanguageName;
+               public string LCID;
+               public string ParentLcid;
+               public string SpecificLcid;
+               public RegionInfoEntry RegionInfoEntry;
+               public DateTimeFormatEntry DateTimeFormatEntry;
+               public NumberFormatEntry NumberFormatEntry;
+               public TextInfoEntry TextInfoEntry;
+               public int DateTimeIndex;
+               public int NumberIndex;
+               public string NativeCurrencyName;
+               public string NativeTerritoryName;
+               public string[] NativeCalendarNames = new string[Constants.NUM_CALENDARS];
+
+               public CalendarType CalendarType;
+               public GregorianCalendarTypes GregorianCalendarType;
+
+               public List<CultureInfoEntry> Children = new List<CultureInfoEntry> ();
+
+               public int Row;
+
+               public CultureInfoEntry ()
+               {
+                       DateTimeFormatEntry = new DateTimeFormatEntry ();
+                       NumberFormatEntry = new NumberFormatEntry ();
+               }
+
+               public string Language {
+                       get {
+                               return language;
+                       }
+                       set {
+                               language = value;
+                       }
+               }
+
+               public bool HasMissingLocale { get; set; }
+
+               public string OriginalName { get; set; }
+
+               public CultureInfoEntry Parent { get; set; }
+
+               public string Name {
+                       get {
+                               string s = language;
+                               if (Script != null)
+                                       s = s + "-" + Script;
+                               if (Territory != null)
+                                       s = s + "-" + Territory;
+
+                               return s;
+                       }
+               }
+
+               public string GetExportName ()
+               {
+                       return OriginalName.Replace ('_', '-');
+               }
+
+               public override string ToString ()
+               {
+                       StringBuilder builder = new StringBuilder ();
+                       AppendTableRow (builder);
+                       return builder.ToString ();
+               }
+
+               public void AppendTableRow (StringBuilder builder)
+               {
+                       builder.Append ("\t{");
+                       builder.Append (LCID).Append (", ");
+                       builder.Append (ParentLcid).Append (", ");
+
+                       int calendar_type = (int) CalendarType;
+                       calendar_type <<= 8;
+                       if (CalendarType == CalendarType.Gregorian)
+                               calendar_type |= (int) GregorianCalendarType;
+
+                       builder.Append (calendar_type).Append (", ");
+                       builder.Append (RegionInfoEntry == null ? -1 : RegionInfoEntry.Index).Append (", ");
+                       builder.Append (EncodeStringIdx (GetExportName ())).Append (", ");
+                       builder.Append (EncodeStringIdx (EnglishName)).Append (", ");
+                       builder.Append (EncodeStringIdx (NativeName)).Append (", ");
+                       builder.Append (EncodeStringIdx (ThreeLetterWindowsLanguageName)).Append (", ");
+                       builder.Append (EncodeStringIdx (ThreeLetterISOLanguageName)).Append (", ");
+                       builder.Append (EncodeStringIdx (TwoLetterISOLanguageName)).Append (", ");
+                       builder.Append (EncodeStringIdx (Territory)).Append (", ");
+                       AppendNames (builder, NativeCalendarNames).Append (", ");
+                       builder.Append (DateTimeFormatEntry.Row).Append (", ");
+                       builder.Append (NumberFormatEntry.Row).Append (", ");
+                       builder.Append (TextInfoEntry.ToString ());
+                       builder.Append ('}');
+               }
+
+               private string ValuesString (int[] values)
                {
-                       return (CultureInfoEntry) e.MemberwiseClone ();
+                       StringBuilder builder = new StringBuilder ();
+                       builder.Append ('{');
+                       for (int i = 0; i < values.Length; i++) {
+                               builder.Append (values[i].ToString ());
+                               if (i + 1 < values.Length)
+                                       builder.Append (", ");
+                       }
+                       builder.Append ("}");
+                       return builder.ToString ();
                }
+       }
 
-                string language;
-
-                public string Territory;
-                public string EnglishName;
-                public string DisplayName;
-                public string NativeName;
-                public string IcuName;
-                public string Win3Lang;
-                public string ISO2Lang;
-                public string ISO3Lang;
-                public string Lcid;
-                public string ParentLcid;
-                public string SpecificLcid;
-                public int RegionId = -1;
-                public DateTimeFormatEntry DateTimeFormatEntry;
-                public NumberFormatEntry NumberFormatEntry;
-                public TextInfoEntry TextInfoEntry;
-                public int [] CalendarData = new int [5];
-                public int DateTimeIndex;
-                public int NumberIndex;
-                
-                
-                public int Row;
-
-                public CultureInfoEntry ()
-                {
-                        DateTimeFormatEntry = new DateTimeFormatEntry ();
-                        NumberFormatEntry = new NumberFormatEntry ();
-                }
-
-                public string Language {
-                        get {
-                                return language;
-                        }
-                        set {
-                                language = (value == "zh") ? "zh-CHS" : value;
-                        }
-                }
-
-                public string Name {
-                        get {
-                                if (Territory == null)
-                                        return Language;
-                                return (Language.StartsWith ("zh") ? "zh" : Language) + "-" + Territory;
-                        }
-                }
-
-                public override string ToString ()
-                {
-                        StringBuilder builder = new StringBuilder ();
-                        AppendTableRow (builder);
-                        return builder.ToString ();
-                }
-
-                public void AppendTableRow (StringBuilder builder)
-                {
-                        builder.Append ("\t{");
-                        builder.AppendFormat ("{0}, {1}, {2}, {3}," +
-                                        "{4}, {5}, {6}, " +
-                                        "{7}, {8}, {9}, " +
-                                        "{10}, {11}, {12}, " +
-                                        "{13}, " +
-                                        "{14}, {15}, {16}",
-                                        Lcid, ParentLcid, SpecificLcid, RegionId,
-                                        EncodeStringIdx (Name), EncodeStringIdx (IcuName), EncodeStringIdx (EnglishName),
-                                        EncodeStringIdx (DisplayName), EncodeStringIdx (NativeName), EncodeStringIdx (Win3Lang),
-                                        EncodeStringIdx (ISO3Lang), EncodeStringIdx (ISO2Lang),
-                                        EncodeStringIdx (Territory),
-                                        ValuesString (CalendarData),
-                                        DateTimeFormatEntry == null ? -1 : DateTimeFormatEntry.Row,
-                                        NumberFormatEntry == null ? -1 : NumberFormatEntry.Row,
-                                       TextInfoEntry.ToString ());
-                        builder.Append ('}');
-                }
-
-                private string ValuesString (int [] values)
-                {
-                        StringBuilder builder = new StringBuilder ();
-                        builder.Append ('{');
-                        for (int i=0; i<values.Length; i++) {
-                                builder.Append (values [i].ToString ());
-                                if (i+1 < values.Length)
-                                        builder.Append (", ");
-                        }
-                        builder.Append ("}");
-                        return builder.ToString ();
-                }
-        }
-        
 }
 
index 0c8fbca34819b5ddf987dd5d7fc67ee004e861a1..3780835cbc825d6a095aa1b850fa2843e6d3bd6f 100644 (file)
 //
-// Mono.Tools.LocaleBuilder.DateTimeFormatEntry
+// DateTimeFormatEntry.cs
 //
-// Author(s):
+// Authors:
 //  Jackson Harper (jackson@ximian.com)
+//     Marek Safar  <marek.safar@gmail.com>
 //
 // (C) 2004, Novell, Inc (http://www.novell.com)
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
 
-using System;
 using System.Text;
-using System.Collections;
-
-namespace Mono.Tools.LocaleBuilder {
-
-        public class DateTimeFormatEntry : Entry {
-
-                public string CalendarType;
-                public ArrayList AbbreviatedDayNames = new ArrayList ();
-                public ArrayList AbbreviatedMonthNames = new ArrayList ();
-                public string AMDesignator;
-                public int CalendarWeekRule;
-                public string DateSeparator;
-                public ArrayList DayNames = new ArrayList ();
-                public int FirstDayOfWeek;
-                public string RawFullDateTimePattern;
-                public string LongDatePattern;
-                public string LongTimePattern;
-                public string MonthDayPattern;
-                public ArrayList MonthNames = new ArrayList ();
-                public string PMDesignator;
-                public string ShortDatePattern;
-                public string ShortTimePattern;
-                public string TimeSeparator;
-                public string YearMonthPattern;
-                public int [] OptionalCalendars = new int [5];
-                public ArrayList ShortDatePatterns = new ArrayList (14);
-                public ArrayList LongDatePatterns = new ArrayList (8);
-                public ArrayList ShortTimePatterns = new ArrayList (5);
-                public ArrayList LongTimePatterns = new ArrayList (6);
-
-                public string FullDateTimePattern {
-                        get { return String.Format (RawFullDateTimePattern, LongTimePattern, LongDatePattern); }
-                }
-
-                public int Row;
-
-                public void AppendTableRow (StringBuilder builder)
-                {
-                        builder.Append ("\t{");
-                        builder.Append (EncodeStringIdx (FullDateTimePattern) + ", ");
-                        builder.Append (EncodeStringIdx (LongDatePattern) + ", ");
-                        builder.Append (EncodeStringIdx (ShortDatePattern) + ", ");
-
-                        builder.Append (EncodeStringIdx (LongTimePattern) + ", ");
-                        builder.Append (EncodeStringIdx (ShortTimePattern) + ", ");
-
-                        builder.Append (EncodeStringIdx (YearMonthPattern) + ", ");
-                        builder.Append (EncodeStringIdx (MonthDayPattern) + ", ");
-
-                        builder.Append (EncodeStringIdx (AMDesignator) + ", ");
-                        builder.Append (EncodeStringIdx (PMDesignator) + ", ");
-
-                        AppendNames (builder, DayNames);
-                        builder.Append (", ");
-                        AppendNames (builder, AbbreviatedDayNames);
-                        builder.Append (", ");
-
-                        AppendNames (builder, MonthNames);
-                        builder.Append (", ");
-                        AppendNames (builder, AbbreviatedMonthNames);
-                        builder.Append (", ");
-
-                        builder.Append (CalendarWeekRule + ", ");
-                        builder.Append (FirstDayOfWeek + ", ");
-                        
-                        builder.Append (EncodeStringIdx (DateSeparator) + ", ");
-                        builder.Append (EncodeStringIdx (TimeSeparator) + ", ");
-
-                        AppendPatterns (builder, ShortDatePatterns);
-                        builder.Append (',');
-                        AppendPatterns (builder, LongDatePatterns);
-                        builder.Append (',');
-                        AppendPatterns (builder, ShortTimePatterns);
-                        builder.Append (',');
-                        AppendPatterns (builder, LongTimePatterns);
-
-                        builder.Append ('}');
-                }
-
-                private void AppendPatterns (StringBuilder builder, ArrayList al)
-                {
-                        string [] patterns = al.ToArray (typeof (string)) as string [];
-                        builder.Append ('{');
-                        for (int i = 0; i < patterns.Length; i++) {
-                                string s = EncodeStringIdx (patterns [i]);
-                                builder.Append (s);
-                                if (i + 1 < patterns.Length)
-                                        builder.Append (',');
-                        }
-                        if (patterns.Length == 0)
-                                builder.Append ('0');
-                        builder.Append ('}');
-                }
-
-                public override string ToString ()
-                {
-                        StringBuilder builder = new StringBuilder ();
-                        AppendTableRow (builder);
-                        return builder.ToString ();
-                }
-
-                private void AppendNames (StringBuilder builder, ArrayList names)
-                {
-                        builder.Append ('{');
-                        for (int i=0; i<names.Count; i++) {
-                                builder.Append (EncodeStringIdx (names [i].ToString ()));
-                                if (i+1 < names.Count)
-                                        builder.Append (", ");
-                        }
-                        builder.Append ("}");
-                }
-        }
+using System.Collections.Generic;
+
+namespace Mono.Tools.LocaleBuilder
+{
+       public class DateTimeFormatEntry : Entry
+       {
+               public string NativeCalendarName;
+               public string[] AbbreviatedDayNames = new string[Constants.NUM_DAYS];
+               // Input data are mostly missing for abbreviated month but datetime 'MMM' parse depends on them
+               // we pre-fill them the most common ones
+               public string[] AbbreviatedMonthGenitiveNames = new string[Constants.NUM_MONTHS] { "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", null };
+               public string[] AbbreviatedMonthNames = new string[Constants.NUM_MONTHS] { "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", null };
+               public string AMDesignator;
+               public int? CalendarWeekRule;
+               public string DateSeparator;
+               public string[] DayNames = new string[Constants.NUM_DAYS];
+               public int? FirstDayOfWeek;
+               public string RawFullDateTimePattern;
+               public string LongDatePattern;
+               public string LongTimePattern;
+               public string MonthDayPattern;
+               public string[] MonthGenitiveNames = new string[Constants.NUM_MONTHS];
+               public string[] MonthNames = new string[Constants.NUM_MONTHS];
+               public string PMDesignator;
+               public string ShortDatePattern;
+               public string ShortTimePattern;
+               public string TimeSeparator;
+               public string YearMonthPattern;
+               public string[] ShortDatePatterns = new string[Constants.NUM_SHORT_DATE_PATTERNS];
+               public string[] LongDatePatterns = new string[Constants.NUM_LONG_DATE_PATTERNS];
+               public string[] ShortTimePatterns = new string[Constants.NUM_SHORT_TIME_PATTERNS];
+               public string[] LongTimePatterns = new string[Constants.NUM_LONG_TIME_PATTERNS];
+               public string[] ShortestDayNames = new string[Constants.NUM_DAYS];
+
+               public int Row;
+
+               public void AppendTableRow (StringBuilder builder)
+               {
+                       builder.Append ("\t{");
+                       builder.Append (EncodeStringIdx (LongDatePattern) + ", ");
+                       builder.Append (EncodeStringIdx (ShortDatePattern) + ", ");
+
+                       builder.Append (EncodeStringIdx (LongTimePattern) + ", ");
+                       builder.Append (EncodeStringIdx (ShortTimePattern) + ", ");
+
+                       builder.Append (EncodeStringIdx (YearMonthPattern) + ", ");
+                       builder.Append (EncodeStringIdx (MonthDayPattern) + ", ");
+
+                       builder.Append (EncodeStringIdx (AMDesignator) + ", ");
+                       builder.Append (EncodeStringIdx (PMDesignator) + ", ");
+
+                       AppendNames (builder, DayNames).Append (", ");
+                       AppendNames (builder, AbbreviatedDayNames).Append (", ");
+                       AppendNames (builder, ShortestDayNames).Append (", ");
+
+                       AppendNames (builder, MonthNames).Append (", ");
+                       AppendNames (builder, MonthGenitiveNames).Append (", ");
+                       AppendNames (builder, AbbreviatedMonthNames).Append (", ");
+                       AppendNames (builder, AbbreviatedMonthGenitiveNames).Append (", ");
+
+                       // TODO:
+                       builder.Append ((CalendarWeekRule ?? 0) + ", ");
+                       builder.Append ((FirstDayOfWeek ?? 0) + ", ");
+
+                       builder.Append (EncodeStringIdx (DateSeparator) + ", ");
+                       builder.Append (EncodeStringIdx (TimeSeparator) + ", ");
+
+                       AppendPatterns (builder, ShortDatePatterns);
+                       builder.Append (',');
+                       AppendPatterns (builder, LongDatePatterns);
+                       builder.Append (',');
+                       AppendPatterns (builder, ShortTimePatterns);
+                       builder.Append (',');
+                       AppendPatterns (builder, LongTimePatterns);
+
+                       builder.Append ('}');
+               }
+
+               private void AppendPatterns (StringBuilder builder, IList<string> patterns)
+               {
+                       builder.Append ('{');
+                       for (int i = 0; i < patterns.Count; i++) {
+                               if (i > 0)
+                                       builder.Append (',');
+
+                               string s = EncodeStringIdx (patterns[i]);
+                               builder.Append (s);
+                       }
+                       if (patterns.Count == 0)
+                               builder.Append ('0');
+                       builder.Append ('}');
+               }
+
+               public override string ToString ()
+               {
+                       StringBuilder builder = new StringBuilder ();
+                       AppendTableRow (builder);
+                       return builder.ToString ();
+               }
+       }
 }
 
 
index 7bd2520421f0d294a0a8dc49a9311f1ab17e935e..43e5b418b68636435c6ab7909d77232e2218cc4a 100644 (file)
@@ -1,59 +1,82 @@
+//
+// Driver.cs
 //
-// Mono.Tools.LocalBuilder.Driver
-//
-// Author(s):
+// Authors:
 //  Jackson Harper (jackson@ximian.com)
 //  Atsushi Enomoto (atsushi@ximian.com)
+//     Marek Safar  <marek.safar@gmail.com>
 //
 // (C) 2004-2005 Novell, Inc (http://www.novell.com)
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
-
 
 using System;
 using System.IO;
 using System.Text;
 using System.Xml;
-using System.Xml.XPath;
-using System.Collections;
 using System.Globalization;
 using System.Text.RegularExpressions;
+using System.Collections.Generic;
+using System.Linq;
 
-namespace Mono.Tools.LocaleBuilder {
+namespace Mono.Tools.LocaleBuilder
+{
+       public class Driver
+       {
+               static readonly string data_root = Path.Combine ("CLDR", "common");
 
-       public class Driver {
-
-               public static void Main (string [] args)
+               public static void Main (string[] args)
                {
                        Driver d = new Driver ();
                        ParseArgs (args, d);
                        d.Run ();
                }
 
-               private static void ParseArgs (string [] args, Driver d)
+               private static void ParseArgs (string[] args, Driver d)
                {
                        for (int i = 0; i < args.Length; i++) {
-                               if (args [i] == "--lang" && i+1 < args.Length)
-                                       d.Lang = args [++i];
-                               else if (args [i] == "--locales" && i+1 < args.Length)
-                                       d.Locales = args [++i];
-                                else if (args [i] == "--header" && i + 1 < args.Length)
-                                        d.HeaderFileName = args [++i];
+                               if (args[i] == "--lang" && i + 1 < args.Length)
+                                       d.Lang = args[++i];
+                               else if (args[i] == "--locales" && i + 1 < args.Length)
+                                       d.Locales = args[++i];
+                               else if (args[i] == "--header" && i + 1 < args.Length)
+                                       d.HeaderFileName = args[++i];
+                               else if (args[i] == "--compare")
+                                       d.OutputCompare = true;
                        }
                }
 
                private string lang;
                private string locales;
-                private string header_name;
-                private ArrayList cultures;
-                private Hashtable langs;
-                private Hashtable currency_types;
-                private Hashtable regions;
-
-               private XPathDocument lcids_doc;
+               private string header_name;
+               List<CultureInfoEntry> cultures;
+               Dictionary<string, string> region_currency;
+               Dictionary<string, string> currency_fractions;
 
                // The lang is the language that display names will be displayed in
-               public string Lang {
-                       get {
+               public string Lang
+               {
+                       get
+                       {
                                if (lang == null)
                                        lang = "en";
                                return lang;
@@ -61,1184 +84,1088 @@ namespace Mono.Tools.LocaleBuilder {
                        set { lang = value; }
                }
 
-               public string Locales {
+               public string Locales
+               {
                        get { return locales; }
                        set { locales = value; }
                }
 
-                public string HeaderFileName {
-                        get {
-                                if (header_name == null)
-                                        return "culture-info-tables.h";
-                                return header_name;
-                        }
-                        set { header_name = value; }
-                }
-
-               public void Run ()
+               public string HeaderFileName
                {
-                       lcids_doc = GetXPathDocument ("lcids.xml");
-
-                       Regex locales_regex = null;
-                       if (Locales != null)
-                               locales_regex = new Regex (Locales);
-
-                        langs = new Hashtable ();
-                        cultures = new ArrayList ();
-                        regions = new Hashtable ();
-
-                       LookupRegions ();
-
-                        LookupCurrencyTypes ();
-
-                       foreach (string file in Directory.GetFiles ("locales", "*.xml")) {
-                               string fn = Path.GetFileNameWithoutExtension (file);
-                               if (fn == "hy_AM")
-                                       continue; // see bug #75499
-                               if (locales_regex == null || locales_regex.IsMatch (fn)) {
-                                       ParseLocale (fn);
-                                }
-                       }
-
-                       /* FIXME: This is hacky.
-                        * Since there is only langs/zh.xml while there are
-                        * two "zh" languages (CHS and CHT), there should be
-                        * different language profiles and we are not likely
-                        * to add lang/* files. So here I just clone zh-CHS
-                        * as zh-CHT
-                        */
-                        foreach (CultureInfoEntry e in cultures) {
-                               if (e.Name == "zh-CHS") {
-                                       CultureInfoEntry t =
-                                               CultureInfoEntry.ShallowCopy (e);
-                                       t.Language = "zh-CHT";
-                                       LookupLcids (t, true);
-                                       cultures.Add (t);
-                                       break;
-                               }
-                        }
-
-                       ArrayList regionList = new ArrayList (regions.Values);
-                       regionList.Sort (RegionComparer.Instance);
-                       int number = 0;
-                       foreach (RegionInfoEntry r in regionList)
-                               r.RegionId = number++;
-
-                       foreach (CultureInfoEntry e in cultures) {
-                               int lcid = int.Parse (e.Lcid.Substring (2),
-                                       NumberStyles.HexNumber);
-                               int idx;
-                               int start = e.Name.IndexOf ('-') + 1;
-                               if (start == 0)
-                                       continue;
-                               for (idx = start; idx < e.Name.Length; idx++)
-                                       if (!Char.IsLetter (e.Name [idx]))
-                                               break;
-                               if (start == idx) {
-                                       Console.Error.WriteLine ("Culture {0} {1} is not mappable to Region.", e.Lcid, e.Name);
-                                       continue;
-                               }
-                               string name = e.Name.Substring (start, idx - start);
-                               RegionInfoEntry rm = null;
-                               foreach (RegionInfoEntry r in regions.Values)
-                                       if (r.ISO2Name == name) {
-                                               rm = r;
-                                               break;
-                                       }
-                               if (rm == null) {
-                                       Console.Error.WriteLine ("No definition for region {0}", name);
-                                       continue;
-                               }
-                               e.RegionId = rm.RegionId;
+                       get
+                       {
+                               if (header_name == null)
+                                       return "culture-info-tables.h";
+                               return header_name;
                        }
+                       set { header_name = value; }
+               }
 
-                        /**
-                         * Dump each table individually. Using StringBuilders
-                         * because it is easier to debug, should switch to just
-                         * writing to streams eventually.
-                         */
-                        using (StreamWriter writer = new StreamWriter (HeaderFileName, false, new UTF8Encoding (false, true))) {
-                                writer.NewLine = "\n";
-                                writer.WriteLine ();
-                                writer.WriteLine ("/* This is a generated file. Do not edit. See tools/locale-builder. */");
-                                writer.WriteLine ("#ifndef MONO_METADATA_CULTURE_INFO_TABLES");
-                                writer.WriteLine ("#define MONO_METADATA_CULTURE_INFO_TABLES 1");
-                                writer.WriteLine ("\n");
-
-                                writer.WriteLine ("#define NUM_CULTURE_ENTRIES " + cultures.Count);
-                                writer.WriteLine ("#define NUM_REGION_ENTRIES " + regionList.Count);
-                                writer.WriteLine ("\n");
-
-                                // Sort the cultures by lcid
-                                cultures.Sort (new LcidComparer ());
-
-                                StringBuilder builder = new StringBuilder ();
-                                int row = 0;
-                                int count = cultures.Count;
-                                for (int i = 0; i < count; i++) {
-                                        CultureInfoEntry ci = (CultureInfoEntry) cultures [i];
-                                        if (ci.DateTimeFormatEntry == null)
-                                                continue;
-                                        ci.DateTimeFormatEntry.AppendTableRow (builder);
-                                        ci.DateTimeFormatEntry.Row = row++;
-                                        if (i + 1 < count)
-                                                builder.Append (',');
-                                        builder.Append ('\n');
-                                }
-
-                                writer.WriteLine ("static const DateTimeFormatEntry datetime_format_entries [] = {");
-                                writer.Write (builder);
-                                writer.WriteLine ("};\n\n");
-                                
-                                builder = new StringBuilder ();
-                                row = 0;
-                                for (int i=0; i < count; i++) {
-                                        CultureInfoEntry ci = (CultureInfoEntry) cultures [i];
-                                        if (ci.NumberFormatEntry == null)
-                                                continue;
-                                        ci.NumberFormatEntry.AppendTableRow (builder);
-                                        ci.NumberFormatEntry.Row = row++;
-                                        if (i + 1 < count)
-                                                builder.Append (',');
-                                        builder.Append ('\n');
-                                }
-
-                                writer.WriteLine ("static const NumberFormatEntry number_format_entries [] = {");
-                                writer.Write (builder);
-                                writer.WriteLine ("};\n\n");
-                                
-                                builder = new StringBuilder ();
-                                row = 0;
-                                for (int i = 0; i < count; i++) {
-                                        CultureInfoEntry ci = (CultureInfoEntry) cultures [i];
-                                        ci.AppendTableRow (builder);
-                                        ci.Row = row++;
-                                        if (i + 1 < count)
-                                                builder.Append (',');
-                                        builder.Append ('\n');
-                                }
-                                
-                                writer.WriteLine ("static const CultureInfoEntry culture_entries [] = {");
-                                writer.Write (builder);
-                                writer.WriteLine ("};\n\n");
-
-                                cultures.Sort (new NameComparer ()); // Sort based on name
-                                builder = new StringBuilder ();
-                                for (int i = 0; i < count; i++) {
-                                        CultureInfoEntry ci = (CultureInfoEntry) cultures [i];
-                                        builder.Append ("\t{" + Entry.EncodeStringIdx (ci.Name.ToLower ()) + ", ");
-                                        builder.Append (ci.Row + "}");
-                                        if (i + 1 < count)
-                                                builder.Append (',');
-                                        builder.Append ('\n');
-                                }
-
-                                writer.WriteLine ("static const CultureInfoNameEntry culture_name_entries [] = {");
-                                writer.Write (builder);
-                                writer.WriteLine ("};\n\n");
+               public bool OutputCompare { get; set; }
 
-                               builder = new StringBuilder ();
-                               int rcount = 0;
-                               foreach (RegionInfoEntry r in regionList) {
-                                       r.AppendTableRow (builder);
-                                       if (++rcount != regionList.Count)
-                                               builder.Append (',');
-                                       builder.Append ('\n');
+               void Print ()
+               {
+                       cultures.Sort ((a, b) => int.Parse (a.LCID.Substring (2), NumberStyles.HexNumber).CompareTo (int.Parse (b.LCID.Substring (2), NumberStyles.HexNumber)));
+
+                       var writer = Console.Out;
+
+                       foreach (var c in cultures) {
+                               writer.WriteLine ("Name: {0}, LCID {1}", c.OriginalName, c.LCID);
+
+                               writer.WriteLine ("{0}: {1}", "DisplayName", c.DisplayName);
+                               writer.WriteLine ("{0}: {1}", "EnglishName", c.EnglishName);
+                               writer.WriteLine ("{0}: {1}", "NativeName", c.NativeName);
+                               // writer.WriteLine ("{0}: {1}", "OptionalCalendars", c.OptionalCalendars);
+                               writer.WriteLine ("{0}: {1}", "ThreeLetterISOLanguageName", c.ThreeLetterISOLanguageName);
+                               writer.WriteLine ("{0}: {1}", "ThreeLetterWindowsLanguageName", c.ThreeLetterWindowsLanguageName);
+                               writer.WriteLine ("{0}: {1}", "TwoLetterISOLanguageName", c.TwoLetterISOLanguageName);
+                               writer.WriteLine ("{0}: {1}", "Calendar", GetCalendarType (c.CalendarType));
+
+                               var df = c.DateTimeFormatEntry;
+                               writer.WriteLine ("-- DateTimeFormat --");
+                               Dump (writer, df.AbbreviatedDayNames, "AbbreviatedDayNames");
+                               Dump (writer, df.AbbreviatedMonthGenitiveNames, "AbbreviatedMonthGenitiveNames");
+                               Dump (writer, df.AbbreviatedMonthNames, "AbbreviatedMonthNames");
+                               writer.WriteLine ("{0}: {1}", "AMDesignator", df.AMDesignator);
+                               writer.WriteLine ("{0}: {1}", "CalendarWeekRule", (CalendarWeekRule) df.CalendarWeekRule);
+                               writer.WriteLine ("{0}: {1}", "DateSeparator", df.DateSeparator);
+                               Dump (writer, df.DayNames, "DayNames");
+                               writer.WriteLine ("{0}: {1}", "FirstDayOfWeek", (DayOfWeek) df.FirstDayOfWeek);
+//                             Dump (writer, df.GetAllDateTimePatterns (), "GetAllDateTimePatterns");
+                               writer.WriteLine ("{0}: {1}", "LongDatePattern", df.LongDatePattern);
+                               writer.WriteLine ("{0}: {1}", "LongTimePattern", df.LongTimePattern);
+                               writer.WriteLine ("{0}: {1}", "MonthDayPattern", df.MonthDayPattern);
+                               Dump (writer, df.MonthGenitiveNames, "MonthGenitiveNames");
+                               Dump (writer, df.MonthNames, "MonthNames");
+                               writer.WriteLine ("{0}: {1}", "NativeCalendarName", df.NativeCalendarName);
+                               writer.WriteLine ("{0}: {1}", "PMDesignator", df.PMDesignator);
+                               writer.WriteLine ("{0}: {1}", "ShortDatePattern", df.ShortDatePattern);
+                               Dump (writer, df.ShortestDayNames, "ShortestDayNames");
+                               writer.WriteLine ("{0}: {1}", "ShortTimePattern", df.ShortTimePattern);
+                               writer.WriteLine ("{0}: {1}", "TimeSeparator", df.TimeSeparator);
+                               writer.WriteLine ("{0}: {1}", "YearMonthPattern", df.YearMonthPattern);
+
+                               var ti = c.TextInfoEntry;
+                               writer.WriteLine ("-- TextInfo --");
+                               writer.WriteLine ("{0}: {1}", "ANSICodePage", ti.ANSICodePage);
+                               writer.WriteLine ("{0}: {1}", "EBCDICCodePage", ti.EBCDICCodePage);
+                               writer.WriteLine ("{0}: {1}", "IsRightToLeft", ti.IsRightToLeft);
+                               writer.WriteLine ("{0}: {1}", "ListSeparator", ti.ListSeparator);
+                               writer.WriteLine ("{0}: {1}", "MacCodePage", ti.MacCodePage);
+                               writer.WriteLine ("{0}: {1}", "OEMCodePage", ti.OEMCodePage);
+
+                               var nf = c.NumberFormatEntry;
+                               writer.WriteLine ("-- NumberFormat --");
+                               writer.WriteLine ("{0}: {1}", "CurrencyDecimalDigits", nf.CurrencyDecimalDigits);
+                               writer.WriteLine ("{0}: {1}", "CurrencyDecimalSeparator", nf.CurrencyDecimalSeparator);
+                               writer.WriteLine ("{0}: {1}", "CurrencyGroupSeparator", nf.CurrencyGroupSeparator);
+                               Dump (writer, nf.CurrencyGroupSizes, "CurrencyGroupSizes", true);
+                               writer.WriteLine ("{0}: {1}", "CurrencyNegativePattern", nf.CurrencyNegativePattern);
+                               writer.WriteLine ("{0}: {1}", "CurrencyPositivePattern", nf.CurrencyPositivePattern);
+                               writer.WriteLine ("{0}: {1}", "CurrencySymbol", nf.CurrencySymbol);
+                               writer.WriteLine ("{0}: {1}", "DigitSubstitution", nf.DigitSubstitution);
+                               writer.WriteLine ("{0}: {1}", "NaNSymbol", nf.NaNSymbol);
+                               Dump (writer, nf.NativeDigits, "NativeDigits");
+                               writer.WriteLine ("{0}: {1}", "NegativeInfinitySymbol", nf.NegativeInfinitySymbol);
+                               writer.WriteLine ("{0}: {1}", "NegativeSign", nf.NegativeSign);
+                               writer.WriteLine ("{0}: {1}", "NumberDecimalDigits", nf.NumberDecimalDigits);
+                               writer.WriteLine ("{0}: {1}", "NumberDecimalSeparator", nf.NumberDecimalSeparator);
+                               writer.WriteLine ("{0}: {1}", "NumberGroupSeparator", nf.NumberGroupSeparator);
+                               Dump (writer, nf.NumberGroupSizes, "NumberGroupSizes", true);
+                               writer.WriteLine ("{0}: {1}", "NumberNegativePattern", nf.NumberNegativePattern);
+                               writer.WriteLine ("{0}: {1}", "PercentDecimalDigits", nf.PercentDecimalDigits);
+                               writer.WriteLine ("{0}: {1}", "PercentDecimalSeparator", nf.PercentDecimalSeparator);
+                               writer.WriteLine ("{0}: {1}", "PercentGroupSeparator", nf.PercentGroupSeparator);
+                               Dump (writer, nf.PercentGroupSizes, "PercentGroupSizes", true);
+                               writer.WriteLine ("{0}: {1}", "PercentNegativePattern", nf.PercentNegativePattern);
+                               writer.WriteLine ("{0}: {1}", "PercentPositivePattern", nf.PercentPositivePattern);
+                               writer.WriteLine ("{0}: {1}", "PercentSymbol", nf.PercentSymbol);
+                               writer.WriteLine ("{0}: {1}", "PerMilleSymbol", nf.PerMilleSymbol);
+                               writer.WriteLine ("{0}: {1}", "PositiveInfinitySymbol", nf.PositiveInfinitySymbol);
+                               writer.WriteLine ("{0}: {1}", "PositiveSign", nf.PositiveSign);
+
+                               if (c.RegionInfoEntry != null) {
+                                       var ri = c.RegionInfoEntry;
+                                       writer.WriteLine ("-- RegionInfo --");
+                                       writer.WriteLine ("{0}: {1}", "CurrencyEnglishName", ri.CurrencyEnglishName);
+                                       writer.WriteLine ("{0}: {1}", "CurrencyNativeName", ri.CurrencyNativeName);
+                                       writer.WriteLine ("{0}: {1}", "CurrencySymbol", ri.CurrencySymbol);
+                                       writer.WriteLine ("{0}: {1}", "DisplayName", ri.DisplayName);
+                                       writer.WriteLine ("{0}: {1}", "EnglishName", ri.EnglishName);
+                                       writer.WriteLine ("{0}: {1}", "GeoId", ri.GeoId);
+                                       writer.WriteLine ("{0}: {1}", "IsMetric", ri.IsMetric);
+                                       writer.WriteLine ("{0}: {1}", "ISOCurrencySymbol", ri.ISOCurrencySymbol);
+                                       writer.WriteLine ("{0}: {1}", "Name", ri.Name);
+                                       writer.WriteLine ("{0}: {1}", "NativeName", ri.NativeName);
+                                       writer.WriteLine ("{0}: {1}", "ThreeLetterISORegionName", ri.ThreeLetterISORegionName);
+                                       writer.WriteLine ("{0}: {1}", "ThreeLetterWindowsRegionName", ri.ThreeLetterWindowsRegionName);
+                                       writer.WriteLine ("{0}: {1}", "TwoLetterISORegionName", ri.TwoLetterISORegionName);
                                }
-                               writer.WriteLine ("static const RegionInfoEntry region_entries [] = {");
-                               writer.Write (builder);
-                               writer.WriteLine ("};\n\n");
 
-                                builder = new StringBuilder ();
-                               rcount = 0;
-                               foreach (RegionInfoEntry ri in regionList) {
-                                        builder.Append ("\t{" + Entry.EncodeStringIdx (ri.ISO2Name) + ", ");
-                                        builder.Append (ri.RegionId + "}");
-                                        if (++rcount < regionList.Count)
-                                                builder.Append (',');
-                                        builder.Append ('\n');
-                                }
-
-                                writer.WriteLine ("static const RegionInfoNameEntry region_name_entries [] = {");
-                                writer.Write (builder);
-                                writer.WriteLine ("};\n\n");
-
-                                writer.WriteLine ("static const char locale_strings [] = {");
-                                writer.Write (Entry.GetStrings ());
-                                writer.WriteLine ("};\n\n");
-
-                                writer.WriteLine ("#endif\n");
-                        }
+                               writer.WriteLine ();
+                       }
                }
 
-               private XPathDocument GetXPathDocument (string path)
+               static Type GetCalendarType (CalendarType ct)
                {
-                       XmlTextReader xtr = null;
-                       try {
-                               xtr = new XmlTextReader (path);
-                               xtr.XmlResolver = null;
-                               return new XPathDocument (xtr);
-                       } finally {
-                               if (xtr != null)
-                                       xtr.Close ();
+                       switch (ct) {
+                       case CalendarType.Gregorian:
+                               return typeof (GregorianCalendar);
+                       case CalendarType.HijriCalendar:
+                               return typeof (HijriCalendar);
+                       case CalendarType.ThaiBuddhist:
+                               return typeof (ThaiBuddhistCalendar);
+                       case CalendarType.UmAlQuraCalendar:
+                               return typeof (UmAlQuraCalendar);
+                       default:
+                               throw new NotImplementedException ();
                        }
                }
 
-               private string GetShortName (string lang)
+               static void Dump<T> (TextWriter tw, IList<T> values, string name, bool stopOnNull = false) where T : class
                {
-                       return lang == "zh-CHS" ? "zh" : lang;
-               }
+                       tw.Write (name);
+                       tw.Write (": ");
 
-                private bool ParseLang (string lang)
-               {
-                        XPathDocument doc = GetXPathDocument (Path.Combine ("langs", GetShortName (lang) + ".xml"));
-                       XPathNavigator nav = doc.CreateNavigator ();
-                        CultureInfoEntry ci = LookupCulture (GetShortName (lang), true);
-                        string lang_type, terr_type;
+                       for (int i = 0; i < values.Count; ++i) {
+                               var v = values[i];
 
-//                        ci.Name = lang; // TODO: might need to be mapped.
+                               if (stopOnNull && v == null)
+                                       break;
 
-                        lang_type = nav.Evaluate ("string (ldml/identity/language/@type)").ToString ();
-                       terr_type = nav.Evaluate ("string (ldml/identity/territory/@type)").ToString ();
+                               if (i > 0)
+                                       tw.Write (", ");
 
-                        ci.Language = (lang_type == String.Empty ? null : lang_type);
-                        ci.Territory = (terr_type == String.Empty ? null : terr_type);
+                               tw.Write (v);
+                       }
 
-                       if (!LookupLcids (ci, true))
-                                return false;
+                       tw.WriteLine ();
+               }
 
-                        doc = GetXPathDocument (Path.Combine ("langs", GetShortName (Lang) + ".xml"));
-                       nav = doc.CreateNavigator ();
-                       ci.DisplayName = LookupFullName (ci, nav);
-                        
-                       if (Lang == "en") {
-                               ci.EnglishName = ci.DisplayName;
-                       } else {
-                               doc = GetXPathDocument (Path.Combine ("langs", GetShortName (lang) + ".xml"));
-                               nav = doc.CreateNavigator ();
-                               ci.EnglishName = LookupFullName (ci, nav);
-                       }
+               void Run ()
+               {
+                       Regex locales_regex = null;
+                       if (Locales != null)
+                               locales_regex = new Regex (Locales);
 
-                       if (ci.Language == Lang) {
-                               ci.NativeName = ci.DisplayName;
-                       } else {
-                               doc = GetXPathDocument (Path.Combine ("langs", GetShortName (lang) + ".xml"));
-                               nav = doc.CreateNavigator ();
-                               ci.NativeName = LookupFullName (ci, nav);
-                       }
+                       cultures = new List<CultureInfoEntry> ();
+                       var regions = new List<RegionInfoEntry> ();
 
-                        langs [lang] = ci;
-                        cultures.Add (ci);
 
-                        return true;
-                }
+                       var supplemental = GetXmlDocument (Path.Combine (data_root, "supplemental", "supplementalData.xml"));
 
-                private void ParseLocale (string locale)
-                {
-                        CultureInfoEntry ci;
+                       // Read currencies info
+                       region_currency = new Dictionary<string, string> (StringComparer.OrdinalIgnoreCase);
+                       foreach (XmlNode entry in supplemental.SelectNodes ("supplementalData/currencyData/region")) {
+                               var child = entry.SelectSingleNode ("currency");
+                               region_currency.Add (entry.Attributes["iso3166"].Value, child.Attributes["iso4217"].Value);
+                       }
 
-                        ci = LookupCulture (locale);
+                       var lcdids = GetXmlDocument ("lcids.xml");
+                       foreach (XmlNode lcid in lcdids.SelectNodes ("lcids/lcid")) {
+                               var name = lcid.Attributes["name"].Value;
 
-                        if (ci == null)
-                                return;
+                               if (locales_regex != null && !locales_regex.IsMatch (name))
+                                       continue;
 
-                        if (langs [GetLanguageFixed (ci)] == null) {
-                                if (!ParseLang (GetLanguageFixed (ci))) // If we can't parse the lang we cant have the locale
-                                        return;
-                        }
+                               var ci = new CultureInfoEntry ();
+                               ci.LCID = lcid.Attributes["id"].Value;
+                               ci.ParentLcid = lcid.Attributes["parent"].Value;
+                               ci.TwoLetterISOLanguageName = lcid.Attributes["iso2"].Value;
+                               ci.ThreeLetterISOLanguageName = lcid.Attributes["iso3"].Value;
+                               ci.ThreeLetterWindowsLanguageName = lcid.Attributes["win"].Value;
+                               ci.OriginalName = name.Replace ('_', '-');
+                               ci.TextInfoEntry = new TextInfoEntry ();
+                               ci.NumberFormatEntry = new NumberFormatEntry ();
+
+                               if (!Import (ci, name))
+                                       continue;
 
-                        cultures.Add (ci);
-                }
+                               cultures.Add (ci);
+                       }
 
-               private CultureInfoEntry LookupCulture (string locale)
-               {
-                       return LookupCulture (locale, false);
-               }
-               private CultureInfoEntry LookupCulture (string locale, bool is_language)
-               {
-                       string path = Path.Combine (is_language ? "langs" : "locales", locale + ".xml");
-                       if (!File.Exists (path))
-                               return null;
-                        XPathDocument doc = GetXPathDocument (path);
-                        XPathNavigator nav = doc.CreateNavigator ();
-                       CultureInfoEntry ci = new CultureInfoEntry ();
-                       string supp;
-                       string loc;
+                       var doc_english = GetXmlDocument (Path.Combine (data_root, "main", "en.xml"));
+
+                       //
+                       // Fill all EnglishName values from en.xml language file
+                       //
+                       foreach (var ci in cultures) {
+                               var el = doc_english.SelectSingleNode (string.Format ("ldml/localeDisplayNames/languages/language[@type='{0}']", ci.Language));
+                               if (el != null)
+                                       ci.EnglishName = el.InnerText;
+
+                               string s = null;
+                               if (ci.Script != null) {
+                                       el = doc_english.SelectSingleNode (string.Format ("ldml/localeDisplayNames/scripts/script[@type='{0}']", ci.Script));
+                                       if (el != null)
+                                               s = el.InnerText;
+                               }
 
-//                        ci.Name = locale; // TODO: Some of these need to be mapped.
+                               if (ci.Territory != null) {
+                                       el = doc_english.SelectSingleNode (string.Format ("ldml/localeDisplayNames/territories/territory[@type='{0}']", ci.Territory));
+                                       if (el != null) {
+                                               if (s == null)
+                                                       s = el.InnerText;
+                                               else
+                                                       s = string.Join (", ", s, el.InnerText);
+                                       }
+                               }
 
-                       // First thing we do is get the lang-territory combo, lcid, and full names
-                       ci.Language = nav.Evaluate ("string (ldml/identity/language/@type)").ToString ();
-                       ci.Territory = nav.Evaluate ("string (ldml/identity/territory/@type)").ToString ();
+                               switch (ci.ThreeLetterWindowsLanguageName) {
+                               case "CHT":
+                                       s = "Traditional";
+                                       break;
+                               case "CHS":
+                                       s = "Simplified";
+                                       break;
+                               }
 
-                        if (!LookupLcids (ci, is_language))
-                                return null;
-                       LookupNames (ci);
+                               if (s != null)
+                                       ci.EnglishName = string.Format ("{0} ({1})", ci.EnglishName, s);
 
-                       /**
-                        * Locale generation is done in six steps, first we
-                         * read the root file which is the base invariant data
-                         * then the supplemental root data, 
-                        * then the language file, the supplemental languages
-                        * file then the locale file, then the supplemental
-                        * locale file. Values in each descending file can
-                        * overwrite previous values.
-                        */
-                        doc = GetXPathDocument (Path.Combine ("langs", "root.xml"));
-                        nav = doc.CreateNavigator ();
-                        Lookup (nav, ci);
-
-                        doc = GetXPathDocument (Path.Combine ("supp", "root.xml"));
-                        nav = doc.CreateNavigator ();
-                        Lookup (nav, ci);
-
-                       doc = GetXPathDocument (Path.Combine ("langs", GetShortName (GetLanguageFixed (ci)) + ".xml"));
-                       nav = doc.CreateNavigator ();
-                       Lookup (nav, ci);
-
-                       supp = Path.Combine ("supp", GetLanguageFixed (ci) + ".xml");
-                       if (File.Exists (supp)) {
-                               doc = GetXPathDocument (supp);
-                               nav = doc.CreateNavigator ();
-                               Lookup (nav, ci);
-                       }
-                       
-                       loc = Path.Combine ("locales", locale + ".xml");
-                       if (File.Exists (loc)) {
-                           doc = GetXPathDocument (loc);
-                           nav = doc.CreateNavigator ();
-                           Lookup (nav, ci);
+                               // Special case legacy chinese
+                               if (ci.OriginalName == "zh-CHS" || ci.OriginalName == "zh-CHT")
+                                       ci.EnglishName += " Legacy";
+
+                               // Mono is not localized and supports english only, hence the name will always be same
+                               ci.DisplayName = ci.EnglishName;
                        }
 
-                       supp = Path.Combine ("supp", locale + ".xml");
-                       if (File.Exists (supp)) {
-                               doc = GetXPathDocument (supp);
-                               nav = doc.CreateNavigator ();
-                               Lookup (nav, ci);
+                       //
+                       // Fill culture hierarchy for easier data manipulation
+                       //
+                       foreach (var ci in cultures) {
+                               foreach (var p in cultures.Where (l => ci.LCID == l.ParentLcid)) {
+                                       ci.Children.Add (p);
+                               }
                        }
 
-                        return ci;
-               }
+                       currency_fractions = new Dictionary<string, string> (StringComparer.OrdinalIgnoreCase);
+                       foreach (XmlNode entry in supplemental.SelectNodes ("supplementalData/currencyData/fractions/info")) {
+                               currency_fractions.Add (entry.Attributes["iso4217"].Value, entry.Attributes["digits"].Value);
+                       }
 
-               private void Lookup (XPathNavigator nav, CultureInfoEntry ci)
-               {
-                       LookupDateTimeInfo (nav, ci);
-                       LookupNumberInfo (nav, ci);
-               }
+                       var territory2dayofweek = new Dictionary<string, DayOfWeek> (StringComparer.OrdinalIgnoreCase);
+                       foreach (XmlNode entry in supplemental.SelectNodes ("supplementalData/weekData/firstDay")) {
+                               DayOfWeek dow;
 
-               private string GetLanguageFixed (CultureInfoEntry ci)
-               {
-                       // This is a hack, but without it nb-NO and nn-NO won't work.
-                       if (ci.Territory == "NO") {
-                               switch (ci.Language) {
-                               case "nb":
-                               case "nn":
-                                       return "no";
+                               switch (entry.Attributes["day"].Value) {
+                               case "mon":
+                                       dow = DayOfWeek.Monday;
+                                       break;
+                               case "fri":
+                                       dow = DayOfWeek.Friday;
+                                       break;
+                               case "sat":
+                                       dow = DayOfWeek.Saturday;
+                                       break;
+                               case "sun":
+                                       dow = DayOfWeek.Sunday;
+                                       break;
+                               default:
+                                       throw new NotImplementedException ();
                                }
+
+                               var territories = entry.Attributes["territories"].Value.Split ();
+                               foreach (var t in territories)
+                                       territory2dayofweek[t] = dow;
                        }
-                       return ci.Language;
-               }
 
-               private void LookupNames (CultureInfoEntry ci)
-               {
-                       XPathDocument doc = GetXPathDocument (Path.Combine ("langs", GetShortName (Lang) + ".xml"));
-                       XPathNavigator nav = doc.CreateNavigator ();
+                       var territory2wr = new Dictionary<string, CalendarWeekRule> (StringComparer.OrdinalIgnoreCase);
+                       foreach (XmlNode entry in supplemental.SelectNodes ("supplementalData/weekData/minDays")) {
+                               CalendarWeekRule rule;
 
-                       ci.DisplayName = LookupFullName (ci, nav);
-                       
-                       if (Lang == "en") {
-                               ci.EnglishName = ci.DisplayName;
-                       } else {
-                               doc = GetXPathDocument (Path.Combine ("langs", "en.xml"));
-                               nav = doc.CreateNavigator ();
-                               ci.EnglishName = LookupFullName (ci, nav);
+                               switch (entry.Attributes["count"].InnerText) {
+                               case "1":
+                                       rule = CalendarWeekRule.FirstDay;
+                                       break;
+                               case "4":
+                                       rule = CalendarWeekRule.FirstFourDayWeek;
+                                       break;
+                               default:
+                                       throw new NotImplementedException ();
+                               }
+
+                               var territories = entry.Attributes["territories"].InnerText.Split ();
+                               foreach (var t in territories)
+                                       territory2wr[t] = rule;
                        }
 
-                       if (ci.Language == Lang) {
-                               ci.NativeName = ci.DisplayName;
-                       } else {
-                               // FIXME: We use ci.Language here.
-                               // This is nothing more than hack for nb-NO and nn-NO
-                               // where Parent of them is nn (not nb or nn).
-                               string lang = ci.Language;
-                               doc = GetXPathDocument (Path.Combine ("langs", GetShortName (lang) + ".xml"));
-                               nav = doc.CreateNavigator ();
-                               ci.NativeName = LookupFullName (ci, nav);
+                       //
+                       // Fill all territory speficic data where territory is available
+                       //
+                       var non_metric = new HashSet<string> ();
+                       foreach (XmlNode entry in supplemental.SelectNodes ("supplementalData/measurementData/measurementSystem[@type='US']")) {
+                               var territories = entry.Attributes["territories"].InnerText.Split ();
+                               foreach (var t in territories)
+                                       non_metric.Add (t);
                        }
-               }
 
-               private void AddPattern (ArrayList al, string pattern)
-               {
-                       if (!al.Contains (pattern))
-                               al.Add (pattern);
-               }
+                       foreach (var ci in cultures) {
+                               if (ci.Territory == null)
+                                       continue;
 
-               private void LookupDateTimeInfo (XPathNavigator nav, CultureInfoEntry ci)
-               {
-                       /**
-                        * TODO: Does anyone have multiple calendars?
-                        */
-                       XPathNodeIterator ni =(XPathNodeIterator) nav.Evaluate ("ldml/dates/calendars/calendar");
-
-                       while (ni.MoveNext ()) {
-                               DateTimeFormatEntry df = ci.DateTimeFormatEntry;
-                               string cal_type = ni.Current.GetAttribute ("type", String.Empty);
-
-                               if (cal_type != String.Empty)
-                                       df.CalendarType = cal_type;
-
-                               XPathNodeIterator ni2 = (XPathNodeIterator) ni.Current.Evaluate ("optionalCalendars/calendar");
-                                int opt_cal_count = 0;
-                               while (ni2.MoveNext ()) {
-                                        int type;
-                                        string greg_type_str;
-                                        XPathNavigator df_nav = ni2.Current;
-                                        switch (df_nav.GetAttribute ("type", String.Empty)) {
-                                        case "Gregorian":
-                                                type = 0;
-                                                break;
-                                        case "Hijri":
-                                                type = 0x01;
-                                                break;
-                                        case "ThaiBuddhist":
-                                                type = 0x02;
-                                                break;
-                                        default:
-                                                Console.WriteLine ("unknown calendar type:  " +
-                                                                df_nav.GetAttribute ("type", String.Empty));
-                                                continue;
-                                        }
-                                        type <<= 24;
-                                        greg_type_str = df_nav.GetAttribute ("greg_type", String.Empty);
-                                        if (greg_type_str != null && greg_type_str != String.Empty) {
-                                                GregorianCalendarTypes greg_type = (GregorianCalendarTypes)
-                                                        Enum.Parse (typeof (GregorianCalendarTypes), greg_type_str);
-                                                int greg_type_int = (int) greg_type;
-                                                type |= greg_type_int;
-                                                
-                                        }
-                                        Console.WriteLine ("Setting cal type: {0:X}  for   {1}", type, ci.Name);
-                                       ci.CalendarData [opt_cal_count++] = type;
-                               }
-                                
-                               ni2 = (XPathNodeIterator) ni.Current.Evaluate ("monthNames/month");
-                               while (ni2.MoveNext ()) {
-                                       if (ni2.CurrentPosition == 1)
-                                               df.MonthNames.Clear ();
-                                       df.MonthNames.Add (ni2.Current.Value);
+                               DayOfWeek value;
+                               if (territory2dayofweek.TryGetValue (ci.Territory, out value)) {
+                                       ci.DateTimeFormatEntry.FirstDayOfWeek = (int) value;
                                }
-                               if (df.MonthNames.Count == 12)
-                                       df.MonthNames.Add (String.Empty);
-
-                               ni2 = (XPathNodeIterator) ni.Current.Evaluate ("dayNames/day");
-                               while (ni2.MoveNext ()) {
-                                       if (ni2.CurrentPosition == 1)
-                                               df.DayNames.Clear ();
-                                       df.DayNames.Add (ni2.Current.Value);
+
+                               CalendarWeekRule rule;
+                               if (territory2wr.TryGetValue (ci.Territory, out rule)) {
+                                       ci.DateTimeFormatEntry.CalendarWeekRule = (int) rule;
                                }
 
-                               ni2 = (XPathNodeIterator) ni.Current.Evaluate ("dayAbbr/day");
-                               while (ni2.MoveNext ()) {
-                                       if (ni2.CurrentPosition == 1)
-                                               df.AbbreviatedDayNames.Clear ();
-                                       df.AbbreviatedDayNames.Add (ni2.Current.Value);
+                               string fraction_value;
+                               if (currency_fractions.TryGetValue (ci.Territory, out fraction_value)) {
+                                       ci.NumberFormatEntry.CurrencyDecimalDigits = fraction_value;
                                }
 
-                               ni2 = (XPathNodeIterator) ni.Current.Evaluate ("monthAbbr/month");
-                               while (ni2.MoveNext ()) {
-                                       if (ni2.CurrentPosition == 1)
-                                               df.AbbreviatedMonthNames.Clear ();
-                                       df.AbbreviatedMonthNames.Add (ni2.Current.Value);
+                               RegionInfoEntry region = regions.Where (l => l.Name == ci.Territory).FirstOrDefault ();
+                               if (region == null) {
+                                       region = new RegionInfoEntry () {
+                                               CurrencySymbol = ci.NumberFormatEntry.CurrencySymbol,
+                                               EnglishName = ci.EnglishName,
+                                               NativeName = ci.NativeTerritoryName,
+                                               Name = ci.Territory,
+                                               TwoLetterISORegionName = ci.Territory,
+                                               CurrencyNativeName = ci.NativeCurrencyName
+                                       };
+
+                                       var tc = supplemental.SelectSingleNode (string.Format ("supplementalData/codeMappings/territoryCodes[@type='{0}']", ci.Territory));
+                                       region.ThreeLetterISORegionName = tc.Attributes["alpha3"].Value;
+                                       region.ThreeLetterWindowsRegionName = region.ThreeLetterISORegionName;
+
+                                       var el = doc_english.SelectSingleNode (string.Format ("ldml/localeDisplayNames/territories/territory[@type='{0}']", ci.Territory));
+                                       region.EnglishName = el.InnerText;
+                                       region.DisplayName = region.EnglishName;
+
+                                       region.ISOCurrencySymbol = region_currency[ci.Territory];
+
+                                       el = doc_english.SelectSingleNode (string.Format ("ldml/numbers/currencies/currency[@type='{0}']/displayName", region.ISOCurrencySymbol));
+                                       region.CurrencyEnglishName = el.InnerText;
+
+                                       if (non_metric.Contains (ci.Territory))
+                                               region.IsMetric = false;
+
+                                       var lcdid_value = int.Parse (ci.LCID.Substring (2), NumberStyles.HexNumber);
+                                       Patterns.FillValues (lcdid_value, region);
+                                       regions.Add (region);
                                }
-                               if (df.AbbreviatedMonthNames.Count == 12)
-                                       df.AbbreviatedMonthNames.Add (String.Empty);
-
-                               ni2 = (XPathNodeIterator) ni.Current.Evaluate ("dateFormats/dateFormatLength");
-                               while (ni2.MoveNext ()) {
-                                       XPathNavigator df_nav = ni2.Current;
-                                       XPathNodeIterator p = df_nav.Select ("dateFormat/pattern");
-                                       string value = null;
-                                       if (p.MoveNext ())
-                                               value = p.Current.Value;
-                                       XPathNodeIterator ext = null;
-                                       switch (df_nav.GetAttribute ("type", String.Empty)) {
-                                       case "full":
-                                               if (value != null)
-                                                       ParseFullDateFormat (df, value);
-                                               break;
-                                       case "long":
-                                               if (value != null)
-                                                       df.LongDatePattern = value;
-                                               ext = df_nav.Select ("extraPatterns/pattern");
-                                               if (ext.MoveNext ()) {
-                                                       df.LongDatePatterns.Clear ();
-                                                       AddPattern (df.LongDatePatterns, df.LongDatePattern);
-                                                       do {
-                                                               df.LongDatePatterns.Add (ext.Current.Value);
-                                                       } while (ext.MoveNext ());
-                                               }
-                                               else
-                                                       AddPattern (df.LongDatePatterns, df.LongDatePattern);
+
+                               ci.RegionInfoEntry = region;
+                       }
+
+                       //
+                       // Fill neutral cultures territory data
+                       //
+                       foreach (var ci in cultures) {
+                               var dtf = ci.DateTimeFormatEntry;
+                               if (dtf.FirstDayOfWeek == null) {
+                                       switch (ci.Name) {
+                                       case "ar":
+                                               dtf.FirstDayOfWeek = (int) DayOfWeek.Saturday;
                                                break;
-                                       case "short":
-                                               if (value != null)
-                                                       df.ShortDatePattern = value;
-                                               ext = df_nav.Select ("extraPatterns/pattern");
-                                               if (ext.MoveNext ()) {
-                                                       df.ShortDatePatterns.Clear ();
-                                                       AddPattern (df.ShortDatePatterns, df.ShortDatePattern);
-                                                       do {
-                                                               df.ShortDatePatterns.Add (ext.Current.Value);
-                                                       } while (ext.MoveNext ());
-                                               }
-                                               else
-                                                       AddPattern (df.ShortDatePatterns, df.ShortDatePattern);
+                                       case "en":
+                                       case "pt":
+                                       case "zh-Hans":
+                                               dtf.FirstDayOfWeek = (int) DayOfWeek.Sunday;
                                                break;
-                                       case "year_month":
-                                               if (value != null)
-                                                       df.YearMonthPattern = value;
+                                       case "es":
+                                       case "fr":
+                                       case "bn":
+                                       case "sr-Cyrl":
+                                       case "sr-Latn":
+                                               dtf.FirstDayOfWeek = (int) DayOfWeek.Monday;
                                                break;
-                                       case "month_day":
-                                               if (value != null)
-                                                       df.MonthDayPattern = value;
+                                       default:
+                                               List<int?> all_fdow = new List<int?> ();
+                                               GetAllChildrenValues (ci, all_fdow, l => l.DateTimeFormatEntry.FirstDayOfWeek);
+                                               var children = all_fdow.Where (l => l != null).Distinct ().ToList ();
+
+                                               if (children.Count == 1) {
+                                                       dtf.FirstDayOfWeek = children[0];
+                                               } else if (children.Count == 0) {
+                                                       if (!ci.HasMissingLocale)
+                                                               Console.WriteLine ("No week data for `{0}'", ci.Name);
+
+                                                       // Default to Sunday
+                                                       dtf.FirstDayOfWeek = (int) DayOfWeek.Sunday;
+                                               } else {
+                                                       // .NET has weird concept of territory data available for neutral cultures (e.g. en, es, pt)
+                                                       // We have to manually disambiguate the correct entry (which is artofficial anyway)
+                                                       throw new ApplicationException (string.Format ("Ambiguous week data for `{0}'", ci.Name));
+                                               }
+
                                                break;
                                        }
                                }
 
-                               ni2 = (XPathNodeIterator) ni.Current.Evaluate ("timeFormats/timeFormatLength");
-                               while (ni2.MoveNext ()) {
-                                       XPathNavigator df_nav = ni2.Current;
-                                       XPathNodeIterator p = df_nav.Select ("timeFormat/pattern");
-                                       string value = null;
-                                       if (p.MoveNext ())
-                                               value = p.Current.Value;
-                                       XPathNodeIterator ext = null;
-                                       switch (df_nav.GetAttribute ("type", String.Empty)) {
-                                       case "long":
-                                               if (value != null)
-                                                       df.LongTimePattern = value.Replace ('a', 't');
-                                               ext = df_nav.Select ("extraPatterns/pattern");
-                                               if (ext.MoveNext ()) {
-                                                       df.LongTimePatterns.Clear ();
-                                                       AddPattern (df.LongTimePatterns, df.LongTimePattern);
-                                                       do {
-                                                               df.LongTimePatterns.Add (ext.Current.Value);
-                                                       } while (ext.MoveNext ());
-                                               }
-                                               else
-                                                       AddPattern (df.LongTimePatterns, df.LongTimePattern);
+                               if (dtf.CalendarWeekRule == null) {
+                                       switch (ci.Name) {
+                                       case "ar":
+                                       case "en":
+                                       case "es":
+                                       case "zh-Hans":
+                                       case "pt":
+                                       case "fr":
+                                       case "bn":
+                                               dtf.CalendarWeekRule = (int) CalendarWeekRule.FirstDay;
                                                break;
-                                       case "short":
-                                               if (value != null)
-                                                       df.ShortTimePattern = value.Replace ('a', 't');
-                                               ext = df_nav.Select ("extraPatterns/pattern");
-                                               if (ext.MoveNext ()) {
-                                                       df.ShortTimePatterns.Clear ();
-                                                       AddPattern (df.ShortTimePatterns, df.ShortTimePattern);
-                                                       do {
-                                                               df.ShortTimePatterns.Add (ext.Current.Value);
-                                                       } while (ext.MoveNext ());
+                                       default:
+                                               List<int?> all_cwr = new List<int?> ();
+                                               GetAllChildrenValues (ci, all_cwr, l => l.DateTimeFormatEntry.CalendarWeekRule);
+                                               var children = all_cwr.Where (l => l != null).Distinct ().ToList ();
+
+                                               if (children.Count == 1) {
+                                                       dtf.CalendarWeekRule = children[0];
+                                               } else if (children.Count == 0) {
+                                                       if (!ci.HasMissingLocale)
+                                                               Console.WriteLine ("No calendar week data for `{0}'", ci.Name);
+
+
+                                                       // Default to FirstDay
+                                                       dtf.CalendarWeekRule = (int) CalendarWeekRule.FirstDay;
+                                               } else {
+                                                       // .NET has weird concept of territory data available for neutral cultures (e.g. en, es, pt)
+                                                       // We have to manually disambiguate the correct entry (which is artofficial anyway)
+                                                       throw new ApplicationException (string.Format ("Ambiguous calendar data for `{0}'", ci.Name));
                                                }
-                                               else
-                                                       AddPattern (df.ShortTimePatterns, df.ShortTimePattern);
+
                                                break;
                                        }
                                }
 
-                               ni2 = (XPathNodeIterator) ni.Current.Evaluate ("dateTimeFormats/dateTimeFormatLength/dateTimeFormat/pattern");
-                               if (ni2.MoveNext ())
-                                       df.RawFullDateTimePattern = ni2.Current.ToString ();/*String.Format (ni2.Current.ToString (),
-                                                       df.LongTimePattern, df.LongDatePattern);*/
-
-                               XPathNodeIterator am = ni.Current.SelectChildren ("am", "");
-                               if (am.MoveNext ())
-                                       df.AMDesignator = am.Current.Value;
-                               XPathNodeIterator pm = ni.Current.SelectChildren ("pm", "");
-                               if (pm.MoveNext ())
-                                       df.PMDesignator = pm.Current.Value;
-/*
-                                string am = (string) ni.Current.Evaluate ("string(am)");
-                                string pm = (string) ni.Current.Evaluate ("string(pm)");
-
-                                if (am != String.Empty)
-                                        df.AMDesignator = am;
-                                if (pm != String.Empty)
-                                        df.PMDesignator = pm;
-*/
-                               ni2 = (XPathNodeIterator) ni.Current.Evaluate
-("week/firstDay");
-                               if (ni2.MoveNext ()) {
-                                       XPathNavigator weekday_nav = ni2.Current;
-                                       switch (weekday_nav.GetAttribute ("day", String.Empty)) {
-                                       case "sun":
-                                               df.FirstDayOfWeek = 0;
+                               var nfe = ci.NumberFormatEntry;
+                               if (nfe.CurrencySymbol == null) {
+                                       switch (ci.Name) {
+                                       case "ar":
+                                               nfe.CurrencySymbol = "ر.س.‏";
+                                               break;
+                                       case "en":
+                                               nfe.CurrencySymbol = "$";
+                                               break;
+                                       case "es":
+                                       case "fr":
+                                               nfe.CurrencySymbol = "€";
+                                               break;
+                                       case "pt":
+                                               nfe.CurrencySymbol = "R$";
+                                               break;
+                                       case "sv":
+                                               nfe.CurrencySymbol = "kr";
                                                break;
-                                       case "mon":
-                                               df.FirstDayOfWeek = 1;
+                                       case "ms":
+                                               nfe.CurrencySymbol = "RM";
                                                break;
-                                       case "tue":
-                                               df.FirstDayOfWeek = 2;
+                                       case "bn":
+                                               nfe.CurrencySymbol = "টা";
                                                break;
-                                       case "wed":
-                                               df.FirstDayOfWeek = 3;
+                                       case "sr-Cyrl":
+                                               nfe.CurrencySymbol = "Дин.";
                                                break;
-                                       case "thu":
-                                               df.FirstDayOfWeek = 4;
+                                       case "sr-Latn":
+                                       case "sr":
+                                               nfe.CurrencySymbol = "Din.";
                                                break;
-                                       case "fri":
-                                               df.FirstDayOfWeek = 5;
+                                       case "zh":
+                                               nfe.CurrencySymbol = "¥";
                                                break;
-                                       case "sat":
-                                               df.FirstDayOfWeek = 6;
+                                       case "zh-Hant":
+                                               nfe.CurrencySymbol = "HK$";
+                                               break;
+                                               
+                                       default:
+                                               var all_currencies = new List<string> ();
+                                               GetAllChildrenValues (ci, all_currencies, l => l.NumberFormatEntry.CurrencySymbol);
+                                               var children = all_currencies.Where (l => l != null).Distinct ().ToList ();
+
+                                               if (children.Count == 1) {
+                                                       nfe.CurrencySymbol = children[0];
+                                               } else if (children.Count == 0) {
+                                                       if (!ci.HasMissingLocale)
+                                                               Console.WriteLine ("No currency data for `{0}'", ci.Name);
+
+
+                                               } else {
+                                                       // .NET has weird concept of territory data available for neutral cultures (e.g. en, es, pt)
+                                                       // We have to manually disambiguate the correct entry (which is artofficial anyway)
+                                                       throw new ApplicationException (string.Format ("Ambiguous currency data for `{0}'", ci.Name));
+                                               }
+
                                                break;
                                        }
                                }
+
+                               if (nfe.CurrencyDecimalDigits == null) {
+                                       var all_digits = new List<string> ();
+                                       GetAllChildrenValues (ci, all_digits, l => l.NumberFormatEntry.CurrencyDecimalDigits);
+                                       var children = all_digits.Where (l => l != null).Distinct ().ToList ();
+
+                                       if (children.Count == 1) {
+                                               nfe.CurrencyDecimalDigits = children[0];
+                                       } else if (children.Count == 0) {
+                                               if (!ci.HasMissingLocale)
+                                                       Console.WriteLine ("No currency decimal digits data for `{0}'", ci.Name);
+
+                                               nfe.CurrencyDecimalDigits = "2";
+                                       } else {
+                                               // .NET has weird concept of territory data available for neutral cultures (e.g. en, es, pt)
+                                               // We have to manually disambiguate the correct entry (which is artofficial anyway)
+                                               throw new ApplicationException (string.Format ("Ambiguous currency decimal digits data for `{0}'", ci.Name));
+                                       }
+                               }
                        }
 
-                        string date_sep = (string) nav.Evaluate ("string(ldml/dates/symbols/dateSeparator)");
-                        string time_sep = (string) nav.Evaluate ("string(ldml/dates/symbols/timeSeparator)");
+                       if (OutputCompare)
+                               Print ();
 
-                        if (date_sep != String.Empty)
-                                ci.DateTimeFormatEntry.DateSeparator = date_sep;
-                        if (time_sep != String.Empty)
-                                ci.DateTimeFormatEntry.TimeSeparator = time_sep;
-               }
+                       regions.Sort (new RegionComparer ());
+                       for (int i = 0; i < regions.Count; ++i)
+                               regions[i].Index = i;
 
-               private void LookupNumberInfo (XPathNavigator nav, CultureInfoEntry ci)
-               {
-                       XPathNodeIterator ni =(XPathNodeIterator) nav.Evaluate ("ldml/numbers");
-
-                       while (ni.MoveNext ()) {
-                                LookupNumberSymbols (ni.Current, ci);
-                               LookupDecimalFormat (ni.Current, ci);
-                               LookupPercentFormat (ni.Current, ci);
-                               LookupCurrencyFormat (ni.Current, ci);
-                                LookupCurrencySymbol (ni.Current, ci);
+                       /**
+                        * Dump each table individually. Using StringBuilders
+                        * because it is easier to debug, should switch to just
+                        * writing to streams eventually.
+                        */
+                       using (StreamWriter writer = new StreamWriter (HeaderFileName, false, new UTF8Encoding (false, true))) {
+                               writer.NewLine = "\n";
+                               writer.WriteLine ();
+                               writer.WriteLine ("/* This is a generated file. Do not edit. See tools/locale-builder. */");
+                               writer.WriteLine ("#ifndef MONO_METADATA_CULTURE_INFO_TABLES");
+                               writer.WriteLine ("#define MONO_METADATA_CULTURE_INFO_TABLES 1");
+                               writer.WriteLine ("\n");
+
+                               writer.WriteLine ("#define NUM_CULTURE_ENTRIES {0}", cultures.Count);
+                               writer.WriteLine ("#define NUM_REGION_ENTRIES {0}", regions.Count);
+
+                               writer.WriteLine ("\n");
+
+                               // Sort the cultures by lcid
+                               cultures.Sort (new LcidComparer ());
+
+                               StringBuilder builder = new StringBuilder ();
+                               int row = 0;
+                               int count = cultures.Count;
+                               for (int i = 0; i < count; i++) {
+                                       CultureInfoEntry ci = cultures[i];
+                                       if (ci.DateTimeFormatEntry == null)
+                                               continue;
+                                       ci.DateTimeFormatEntry.AppendTableRow (builder);
+                                       ci.DateTimeFormatEntry.Row = row++;
+                                       if (i + 1 < count)
+                                               builder.Append (',');
+                                       builder.Append ('\n');
+                               }
+
+                               writer.WriteLine ("static const DateTimeFormatEntry datetime_format_entries [] = {");
+                               writer.Write (builder);
+                               writer.WriteLine ("};\n\n");
+
+                               builder = new StringBuilder ();
+                               row = 0;
+                               for (int i = 0; i < count; i++) {
+                                       CultureInfoEntry ci = cultures[i];
+                                       if (ci.NumberFormatEntry == null)
+                                               continue;
+                                       ci.NumberFormatEntry.AppendTableRow (builder);
+                                       ci.NumberFormatEntry.Row = row++;
+                                       if (i + 1 < count)
+                                               builder.Append (',');
+                                       builder.Append ('\n');
+                               }
+
+                               writer.WriteLine ("static const NumberFormatEntry number_format_entries [] = {");
+                               writer.Write (builder);
+                               writer.WriteLine ("};\n\n");
+
+                               builder = new StringBuilder ();
+                               row = 0;
+                               for (int i = 0; i < count; i++) {
+                                       CultureInfoEntry ci = cultures[i];
+                                       ci.AppendTableRow (builder);
+                                       ci.Row = row++;
+                                       if (i + 1 < count)
+                                               builder.Append (',');
+                                       builder.Append ('\n');
+                               }
+
+                               writer.WriteLine ("static const CultureInfoEntry culture_entries [] = {");
+                               writer.Write (builder);
+                               writer.WriteLine ("};\n\n");
+
+                               cultures.Sort (new ExportNameComparer ()); // Sort based on name
+                               builder = new StringBuilder ();
+                               for (int i = 0; i < count; i++) {
+                                       CultureInfoEntry ci = cultures[i];
+                                       var name = ci.GetExportName ().ToLowerInvariant ();
+                                       builder.Append ("\t{" + Entry.EncodeStringIdx (name) + ", ");
+                                       builder.Append (ci.Row + "}");
+                                       if (i + 1 < count)
+                                               builder.Append (',');
+
+                                       builder.AppendFormat ("\t /* {0} */", name);
+                                       builder.Append ('\n');
+                               }
+
+                               writer.WriteLine ("static const CultureInfoNameEntry culture_name_entries [] = {");
+                               writer.Write (builder);
+                               writer.WriteLine ("};\n\n");
+
+                               builder = new StringBuilder ();
+                               int rcount = 0;
+                               foreach (RegionInfoEntry r in regions) {
+                                       r.AppendTableRow (builder);
+                                       if (++rcount != regions.Count)
+                                               builder.Append (',');
+
+                                       builder.Append ('\n');
+                               }
+                               writer.WriteLine ("static const RegionInfoEntry region_entries [] = {");
+                               writer.Write (builder);
+                               writer.WriteLine ("};\n\n");
+
+                               builder = new StringBuilder ();
+                               rcount = 0;
+                               foreach (RegionInfoEntry ri in regions) {
+                                       builder.Append ("\t{" + Entry.EncodeStringIdx (ri.TwoLetterISORegionName) + ", ");
+                                       builder.Append (ri.Index + "}");
+                                       if (++rcount != regions.Count)
+                                               builder.Append (',');
+                                       
+                                       builder.AppendFormat ("\t /* {0} */", ri.TwoLetterISORegionName);
+                                       builder.Append ('\n');
+                               }
+
+                               writer.WriteLine ("static const RegionInfoNameEntry region_name_entries [] = {");
+                               writer.Write (builder);
+                               writer.WriteLine ("};\n\n");
+
+                               writer.WriteLine ("static const char locale_strings [] = {");
+                               writer.Write (Entry.GetStrings ());
+                               writer.WriteLine ("};\n\n");
+
+                               writer.WriteLine ("#endif\n");
                        }
                }
 
-               private void LookupDecimalFormat (XPathNavigator nav, CultureInfoEntry ci)
+               static void GetAllChildrenValues<T> (CultureInfoEntry entry, List<T> values, Func<CultureInfoEntry, T> selector)
                {
-                       string format = (string) nav.Evaluate ("string(decimalFormats/" +
-                                       "decimalFormatLength/decimalFormat/pattern)");
-
-                       if (format == String.Empty)
-                               return;
-
-                       string [] part_one, part_two;
-                       string [] pos_neg = format.Split (new char [1] {';'}, 2);
-
-                       // Most of the patterns are common in positive and negative
-                       if (pos_neg.Length == 1)
-                               pos_neg = new string [] {pos_neg [0], pos_neg [0]};
-
-                       if (pos_neg.Length == 2) {
-                               
-                               part_one = pos_neg [0].Split (new char [1] {'.'}, 2);
-                               if (part_one.Length == 1)
-                                       part_one = new string [] {part_one [0], String.Empty};
-
-                               if (part_one.Length == 2) {
-                                       // assumed same for both positive and negative
-                                       // decimal digit side
-                                       ci.NumberFormatEntry.NumberDecimalDigits = 0;                                   
-                                       for (int i = 0; i < part_one [1].Length; i++) {
-                                               if (part_one [1][i] == '#') {
-                                                       ci.NumberFormatEntry.NumberDecimalDigits ++;
-                                               } else
-                                                       break;                                                          }
-                                       // FIXME: This should be actually done by modifying culture xml files, but too many files to be modified.
-                                       if (ci.NumberFormatEntry.NumberDecimalDigits > 0)
-                                               ci.NumberFormatEntry.NumberDecimalDigits --;
-
-                                       // decimal grouping side
-                                       part_two = part_one [0].Split (',');
-                                       if (part_two.Length > 1) {
-                                               int len = part_two.Length - 1;
-                                               ci.NumberFormatEntry.NumberGroupSizes = new int [len];
-                                               for (int i = 0; i < len; i++) {
-                                                       string pat = part_two [i + 1];
-                                                       ci.NumberFormatEntry.NumberGroupSizes [i] = pat.Length;
-                                               }
-                                       } else {
-                                               ci.NumberFormatEntry.NumberGroupSizes = new int [1] { 3 };
-                                       }
+                       foreach (var e in entry.Children) {
+                               if (e == entry)
+                                       continue;
 
-                                       if (pos_neg [1].StartsWith ("(") && pos_neg [1].EndsWith (")")) {
-                                               ci.NumberFormatEntry.NumberNegativePattern = 0;
-                                       } else if (pos_neg [1].StartsWith ("- ")) {
-                                               ci.NumberFormatEntry.NumberNegativePattern = 2;
-                                       } else if (pos_neg [1].StartsWith ("-")) {
-                                               ci.NumberFormatEntry.NumberNegativePattern = 1;
-                                       } else if (pos_neg [1].EndsWith (" -")) {
-                                               ci.NumberFormatEntry.NumberNegativePattern = 4;
-                                       } else if (pos_neg [1].EndsWith ("-")) {
-                                               ci.NumberFormatEntry.NumberNegativePattern = 3;
-                                       } else {
-                                               ci.NumberFormatEntry.NumberNegativePattern = 1;
-                                       }
+                               values.Add (selector (e));
+
+                               foreach (var e2 in e.Children) {
+                                       GetAllChildrenValues (e2, values, selector);
                                }
                        }
                }
 
-               private void LookupPercentFormat (XPathNavigator nav, CultureInfoEntry ci)
+               static XmlDocument GetXmlDocument (string path)
                {
-                       string format = (string) nav.Evaluate ("string(percentFormats/" +
-                                       "percentFormatLength/percentFormat/pattern)");
-
-                       if (format == String.Empty)
-                               return;
-
-                       string [] part_one, part_two;
-
-                       // we don't have percentNegativePattern in CLDR so 
-                       // the percentNegativePattern are just guesses
-                       if (format.StartsWith ("%")) {
-                               ci.NumberFormatEntry.PercentPositivePattern = 2;
-                               ci.NumberFormatEntry.PercentNegativePattern = 2;
-                               format = format.Substring (1);
-                       } else if (format.EndsWith (" %")) {
-                               ci.NumberFormatEntry.PercentPositivePattern = 0;
-                               ci.NumberFormatEntry.PercentNegativePattern = 0;
-                               format = format.Substring (0, format.Length - 2);
-                       } else if (format.EndsWith ("%")) {
-                               ci.NumberFormatEntry.PercentPositivePattern = 1;
-                               ci.NumberFormatEntry.PercentNegativePattern = 1;
-                               format = format.Substring (0, format.Length - 1);
-                       } else {
-                               ci.NumberFormatEntry.PercentPositivePattern = 0;
-                               ci.NumberFormatEntry.PercentNegativePattern = 0;
-                       }
+                       var doc = new XmlDocument ();
+                       doc.Load (new XmlTextReader (path) { /*DtdProcessing = DtdProcessing.Ignore*/ } );
+                       return doc;
+               }
 
-                       part_one = format.Split (new char [1] {'.'}, 2);
-                       if (part_one.Length == 2) {
-                               // assumed same for both positive and negative
-                               // decimal digit side
-                               ci.NumberFormatEntry.PercentDecimalDigits = 0;
-                               for (int i = 0; i < part_one [1].Length; i++) {
-                                       if (part_one [1][i] == '#')
-                                               ci.NumberFormatEntry.PercentDecimalDigits++;
-                                       else
-                                               break;
+               bool Import (CultureInfoEntry data, string locale)
+               {
+                       string fname = null;
+                       var sep = locale.Split ('_');
+                       data.Language = sep[0];
+
+                       // CLDR strictly follow ISO names, .NET does not
+                       // Replace names where non-iso2 is used, e.g. Norway
+                       if (data.Language != data.TwoLetterISOLanguageName) {
+                               locale = data.TwoLetterISOLanguageName;
+                               if (sep.Length > 1) {
+                                       locale += string.Join ("_", sep.Skip (1));
                                }
                        }
 
-                       if (part_one.Length > 0) {
-                               // percent grouping side
-                               part_two = part_one [0].Split (',');
-                               if (part_two.Length > 1) {
-                                       int len = part_two.Length - 1;
-                                       ci.NumberFormatEntry.PercentGroupSizes = new int [len];
-                                       for (int i = 0; i < len; i++) {
-                                               string pat = part_two [i + 1];
-                                               if (pat [pat.Length -1] == '0')
-                                                       ci.NumberFormatEntry.PercentDecimalDigits = pat.Length - 1;
-                                               ci.NumberFormatEntry.PercentGroupSizes [i] = pat.Length;
-                                       }
-                               } else {
-                                       ci.NumberFormatEntry.PercentGroupSizes = new int [1] { 3 };
-                                       ci.NumberFormatEntry.PercentDecimalDigits = 2;
-                               }
+                       // Convert broken Chinese names to correct one
+                       switch (locale) {
+                       case "zh_CHS":
+                               locale = "zh_Hans";
+                               break;
+                       case "zh_CHT":
+                               locale = "zh_Hant";
+                               break;
+                       case "zh_CN":
+                               locale = "zh_Hans_CN";
+                               break;
+                       case "zh_HK":
+                               locale = "zh_Hant_HK";
+                               break;
+                       case "zh_SG":
+                               locale = "zh_Hans_SG";
+                               break;
+                       case "zh_TW":
+                               locale = "zh_Hant_TW";
+                               break;
+                       case "zh_MO":
+                               locale = "zh_Hant_MO";
+                               break;
                        }
-               }
 
-               private void LookupCurrencyFormat (XPathNavigator nav, CultureInfoEntry ci)
-               {
-                       string format = (string) nav.Evaluate ("string(currencyFormats/" +
-                                       "currencyFormatLength/currencyFormat/pattern)");
-
-                       if (format == String.Empty)
-                               return;
-
-                       string [] part_one, part_two;
-                       string [] pos_neg = format.Split (new char [1] {';'}, 2);
-       
-                       // Most of the patterns are common in positive and negative
-                       if (pos_neg.Length == 1)
-                               pos_neg = new string [] {pos_neg [0], pos_neg [0]};
-
-                       if (pos_neg.Length == 2) {
-                               part_one = pos_neg [0].Split (new char [1] {'.'}, 2);
-                               if (part_one.Length == 1)
-                                       part_one = new string [] {part_one [0], String.Empty};
-                               if (part_one.Length == 2) {
-                                       // assumed same for both positive and negative
-                                       // decimal digit side
-                                       ci.NumberFormatEntry.CurrencyDecimalDigits = 0;
-                                       for (int i = 0; i < part_one [1].Length; i++) {
-                                               if (part_one [1][i] == '0')
-                                                       ci.NumberFormatEntry.CurrencyDecimalDigits++;
-                                               else
-                                                       break;
-                                       }
+                       sep = locale.Split ('_');
 
-                                       // decimal grouping side
-                                       part_two = part_one [0].Split (',');
-                                       if (part_two.Length > 1) {
-                                               int len = part_two.Length - 1;
-                                               ci.NumberFormatEntry.CurrencyGroupSizes = new int [len];
-                                               for (int i = 0; i < len; i++) {
-                                                       string pat = part_two [i + 1];
-                                                       ci.NumberFormatEntry.CurrencyGroupSizes [i] = pat.Length;
-                                               }
-                                       } else {
-                                               ci.NumberFormatEntry.CurrencyGroupSizes = new int [1] { 3 };
-                                       }
+                       string full_name = Path.Combine (data_root, "main", locale + ".xml");
+                       if (!File.Exists (full_name)) {
+                               Console.WriteLine ("Missing locale file for `{0}'", locale);
 
-                                       if (pos_neg [1].StartsWith ("(\u00a4 ") && pos_neg [1].EndsWith (")")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 14;
-                                       } else if (pos_neg [1].StartsWith ("(\u00a4") && pos_neg [1].EndsWith (")")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 0;
-                                       } else if (pos_neg [1].StartsWith ("\u00a4 ") && pos_neg [1].EndsWith ("-")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 11;
-                                       } else if (pos_neg [1].StartsWith ("\u00a4") && pos_neg [1].EndsWith ("-")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 3;
-                                       } else if (pos_neg [1].StartsWith ("(") && pos_neg [1].EndsWith (" \u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 15;
-                                       } else if (pos_neg [1].StartsWith ("(") && pos_neg [1].EndsWith ("\u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 4;
-                                       } else if (pos_neg [1].StartsWith ("-") && pos_neg [1].EndsWith (" \u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 8;
-                                       } else if (pos_neg [1].StartsWith ("-") && pos_neg [1].EndsWith ("\u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 5;
-                                       } else if (pos_neg [1].StartsWith ("-\u00a4 ")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 9;
-                                       } else if (pos_neg [1].StartsWith ("-\u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 1;
-                                       } else if (pos_neg [1].StartsWith ("\u00a4 -")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 12;
-                                       } else if (pos_neg [1].StartsWith ("\u00a4-")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 2;
-                                       } else if (pos_neg [1].EndsWith (" \u00a4-")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 10;
-                                       } else if (pos_neg [1].EndsWith ("\u00a4-")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 7;
-                                       } else if (pos_neg [1].EndsWith ("- \u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 13;
-                                       } else if (pos_neg [1].EndsWith ("-\u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 6;
-                                       } else {
-                                               ci.NumberFormatEntry.CurrencyNegativePattern = 0;
+                               // We could fill default values but that's not as simple as it seems. For instance for non-neutral
+                               // cultures the next part could be territory or not.
+                               return false;
+                       } else {
+                               XmlDocument doc = null;
+
+                               /*
+                                * Locale generation is done in several steps, first we
+                                * read the root file which is the base invariant data
+                                * then the supplemental root data, 
+                                * then the language file, the supplemental languages
+                                * file then the locale file, then the supplemental
+                                * locale file. Values in each descending file can
+                                * overwrite previous values.
+                                */
+                               foreach (var part in sep) {
+                                       if (fname != null)
+                                               fname += "_";
+
+                                       fname += part;
+
+                                       var xml = GetXmlDocument (Path.Combine (data_root, "main", fname + ".xml"));
+                                       if (doc == null)
+                                               doc = xml;
+
+                                       Import (xml, data);
+                               }
+
+                               //
+                               // Extract localized locale name from language xml file. Have to do it after both language and territory are read
+                               //
+                               var el = doc.SelectSingleNode (string.Format ("ldml/localeDisplayNames/languages/language[@type='{0}']", data.Language));
+                               if (el != null)
+                                       data.NativeName = el.InnerText;
+
+                               if (data.Territory != null) {
+                                       el = doc.SelectSingleNode (string.Format ("ldml/localeDisplayNames/territories/territory[@type='{0}']", data.Territory));
+                                       if (el != null) {
+                                               // TODO: Should read <localePattern>
+                                               data.NativeName = string.Format ("{0} ({1})", data.NativeName, el.InnerText);
+                                               data.NativeTerritoryName = el.InnerText;
                                        }
-                                       
-                                       if (pos_neg [0].StartsWith ("\u00a4 ")) {
-                                               ci.NumberFormatEntry.CurrencyPositivePattern = 2;
-                                       } else if (pos_neg [0].StartsWith ("\u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyPositivePattern = 0;
-                                       } else if (pos_neg [0].EndsWith (" \u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyPositivePattern = 3;
-                                       } else if (pos_neg [0].EndsWith ("\u00a4")) {
-                                               ci.NumberFormatEntry.CurrencyPositivePattern = 1; 
-                                       } else {
-                                               ci.NumberFormatEntry.CurrencyPositivePattern = 0;
+
+                                       string currency;
+                                       // We have territory now we have to run the process again to extract currency symbol
+                                       if (region_currency.TryGetValue (data.Territory, out currency)) {
+                                               fname = null;
+
+                                               var xml = GetXmlDocument (Path.Combine (data_root, "main", "root.xml"));
+                                               el = xml.SelectSingleNode (string.Format ("ldml/numbers/currencies/currency[@type='{0}']/symbol", currency));
+                                               if (el != null)
+                                                       data.NumberFormatEntry.CurrencySymbol = el.InnerText;
+
+                                               foreach (var part in sep) {
+                                                       if (fname != null)
+                                                               fname += "_";
+
+                                                       fname += part;
+
+                                                       xml = GetXmlDocument (Path.Combine (data_root, "main", fname + ".xml"));
+                                                       el = xml.SelectSingleNode (string.Format ("ldml/numbers/currencies/currency[@type='{0}']/symbol", currency));
+                                                       if (el != null)
+                                                               data.NumberFormatEntry.CurrencySymbol = el.InnerText;
+
+                                                       el = xml.SelectSingleNode (string.Format ("ldml/numbers/currencies/currency[@type='{0}']/displayName", currency));
+                                                       if (el != null)
+                                                               data.NativeCurrencyName = el.InnerText;
+                                               }
                                        }
                                }
-                       }
-               }
 
-                private void LookupNumberSymbols (XPathNavigator nav, CultureInfoEntry ci)
-                {
-                        string dec = (string) nav.Evaluate ("string(symbols/decimal)");
-                        string group = (string) nav.Evaluate ("string(symbols/group)");
-                        string percent = (string) nav.Evaluate ("string(symbols/percentSign)");
-                        string positive = (string) nav.Evaluate ("string(symbols/plusSign)");
-                        string negative = (string) nav.Evaluate ("string(symbols/minusSign)");
-                        string per_mille = (string) nav.Evaluate ("string(symbols/perMille)");
-                        string infinity = (string) nav.Evaluate ("string(symbols/infinity)");
-                        string nan = (string) nav.Evaluate ("string(symbols/nan)");
-
-                        if (dec != String.Empty) {
-                                ci.NumberFormatEntry.NumberDecimalSeparator = dec;
-                                ci.NumberFormatEntry.PercentDecimalSeparator = dec;
-                                ci.NumberFormatEntry.CurrencyDecimalSeparator = dec;
-                        }
-
-                        if (group != String.Empty) {
-                                ci.NumberFormatEntry.NumberGroupSeparator = group;
-                                ci.NumberFormatEntry.PercentGroupSeparator = group;
-                                ci.NumberFormatEntry.CurrencyGroupSeparator = group;
-                        }
-
-                        if (percent != String.Empty)
-                                ci.NumberFormatEntry.PercentSymbol = percent;
-                        if (positive != String.Empty)
-                                ci.NumberFormatEntry.PositiveSign = positive;
-                        if (negative != String.Empty)
-                                ci.NumberFormatEntry.NegativeSign = negative;
-                        if (per_mille != String.Empty)
-                                ci.NumberFormatEntry.PerMilleSymbol = per_mille;
-                        if (infinity != String.Empty)
-                                ci.NumberFormatEntry.PositiveInfinitySymbol = infinity;
-                        if (nan != String.Empty)
-                                ci.NumberFormatEntry.NaNSymbol = nan;
-                }
-
-                private void LookupCurrencySymbol (XPathNavigator nav, CultureInfoEntry ci)
-                {
-                        string type = currency_types [ci.Territory] as string;
-
-                        if (type == null) {
-                                Console.WriteLine ("no currency type for:  " + ci.Territory);
-                                return;
-                        }
-                        
-                        string cur = (string) nav.Evaluate ("string(currencies/currency [@type='" +
-                                        type + "']/symbol)");
-
-                        if (cur != String.Empty)
-                                ci.NumberFormatEntry.CurrencySymbol = cur;
-                }
-
-               private bool LookupLcids (CultureInfoEntry ci, bool lang)
-               {
-                       XPathNavigator nav = lcids_doc.CreateNavigator ();
-                       string name = ci.Name;
-                       // Language name does not always consist of locale name.
-                       // (for zh-* it must be either zh-CHS or zh-CHT)
-                       string langName = GetLanguageFixed (ci);
-
-//                        if (ci.Territory != null)
-//                                name += "-" + ci.Territory;
-
-                       XPathNodeIterator ni =(XPathNodeIterator) nav.Evaluate ("lcids/lcid[@name='"
-                                       + (lang ? langName : name) + "']");
-                       if (!ni.MoveNext ()) {
-                               Console.WriteLine ("no lcid found for: {0} ({1}/{2})", name, ci.Language, ci.Territory);
-                                string file;
-
-                                if (ci.Territory != null) {
-                                        file = Path.Combine ("locales", ci.Language + "_" + ci.Territory + ".xml");
-                                        Console.WriteLine ("deleting file:  " + file);
-                                        File.Delete (file);
-                                }
+                               if (data.DateTimeFormatEntry.MonthGenitiveNames[0] == null)
+                                       data.DateTimeFormatEntry.MonthGenitiveNames = data.DateTimeFormatEntry.MonthNames;
+
+                               if (data.DateTimeFormatEntry.AbbreviatedMonthGenitiveNames[0] == null)
+                                       data.DateTimeFormatEntry.AbbreviatedMonthGenitiveNames = data.DateTimeFormatEntry.AbbreviatedMonthNames;
+
 
-                               return false;
                        }
 
-                       string id = ni.Current.GetAttribute ("id", String.Empty);
-                       string parent = ni.Current.GetAttribute ("parent", String.Empty);
-                        string specific = ni.Current.GetAttribute ("specific", String.Empty);
-                        string iso2 = ni.Current.GetAttribute ("iso2", String.Empty);
-                        string iso3 = ni.Current.GetAttribute ("iso3", String.Empty);
-                        string win = ni.Current.GetAttribute ("win", String.Empty);
-                        string icu = ni.Current.GetAttribute ("icu_name", String.Empty);
-
-                       // lcids are in 0x<hex> format
-                       ci.Lcid = id;
-                       ci.ParentLcid = parent;
-                        ci.SpecificLcid = specific;
-                        ci.ISO2Lang = iso2;
-                        ci.ISO3Lang = iso3;
-                        ci.Win3Lang = win;
-                        ci.IcuName = icu;
-                       
-                       ci.TextInfoEntry = new TextInfoEntry (int.Parse (id.Substring (2), NumberStyles.HexNumber), GetXPathDocument ("textinfo.xml"));
-
-                        return true;
-               }
-               
-               private string LookupFullName (CultureInfoEntry ci, XPathNavigator nav)
-               {
-                       string pre = "ldml/localeDisplayNames/";
-                       string ret;
+                       // It looks like it never changes
+                       data.DateTimeFormatEntry.TimeSeparator = ":";
+
+                       // TODO: Don't have input data available but most values are 2 with few exceptions for 1 and 3
+                       // We don't add 3 as it's for some arabic states only
+                       switch (data.ThreeLetterISOLanguageName) {
+                       case "amh":
+                               data.NumberFormatEntry.NumberDecimalDigits =
+                               data.NumberFormatEntry.PercentDecimalDigits = 1;
+                               break;
+                       default:
+                               data.NumberFormatEntry.NumberDecimalDigits =
+                               data.NumberFormatEntry.PercentDecimalDigits = 2;
+                               break;
+                       }
 
-                       // FIXME: We use ci.Language here.
-                       // This is nothing more than hack for nb-NO or nn-NO
-                       // where Parent of them is nn (not nb or nn).
-                       ret = (string) nav.Evaluate ("string("+
-                                       pre + "languages/language[@type='" + GetShortName (ci.Language) + "'])");
+                       // TODO: For now we capture only native name for default calendar
+                       data.NativeCalendarNames[((int) data.CalendarType & 0xFF) - 1] = data.DateTimeFormatEntry.NativeCalendarName;
 
-                       if (ci.Territory == null)
-                               return ret;
-                       ret += " (" + (string) nav.Evaluate ("string("+
-                                       pre + "territories/territory[@type='" + ci.Territory + "'])") + ")";
+                       var lcdid_value = int.Parse (data.LCID.Substring (2), NumberStyles.HexNumber);
+                       Patterns.FillValues (lcdid_value, data);
 
-                       return ret;
+                       return true;
                }
 
-               private void LookupRegions ()
+               void Import (XmlDocument doc, CultureInfoEntry ci)
                {
-                        XPathDocument doc = GetXPathDocument ("supplementalData.xml");
-                       XPathNavigator nav = doc.CreateNavigator ();
-                       XPathNodeIterator ni = nav.Select ("supplementalData/currencyData/region");
-                       while (ni.MoveNext ()) {
-                               string territory = (string) ni.Current.GetAttribute ("iso3166", String.Empty);
-                                string currency = (string) ni.Current.Evaluate ("string(currency/@iso4217)");
-                               RegionInfoEntry region = new RegionInfoEntry ();
-                               region.ISO2Name = territory.ToUpper ();
-                               region.ISOCurrencySymbol = currency;
-                               regions [territory] = region;
+                       XmlNodeList nodes;
+                       XmlNode el;
+
+                       //
+                       // Extract script & teritory
+                       //
+                       el = doc.SelectSingleNode ("ldml/identity/script");
+                       if (el != null)
+                               ci.Script = el.Attributes["type"].Value;
+
+                       el = doc.SelectSingleNode ("ldml/identity/territory");
+                       if (el != null)
+                               ci.Territory = el.Attributes["type"].Value;
+
+                       var df = ci.DateTimeFormatEntry;
+
+                       string calendar;
+                       // Default calendar is for now always "gregorian"
+                       switch (ci.Name) {
+                       case "th": case "th-TH":
+                               calendar = "buddhist";
+                               ci.CalendarType = CalendarType.ThaiBuddhist; // typeof (ThaiBuddhistCalendar);
+                               break;
+                       case "ar": case "ar-SA":
+                               calendar = "islamic";
+                               ci.CalendarType = CalendarType.UmAlQuraCalendar; // typeof (UmAlQuraCalendar);
+                               break;
+                       case "ps": case "ps-AF": case "prs": case "prs-AF": case "dv": case "dv-MV":
+                               calendar = "persian";
+                               ci.CalendarType = CalendarType.HijriCalendar; // typeof (HijriCalendar);
+                               break;
+                       default:
+                               calendar = "gregorian";
+                               ci.CalendarType = CalendarType.Gregorian; // typeof (GregorianCalendar);
+                               ci.GregorianCalendarType = GregorianCalendarTypes.Localized;
+                               break;
                        }
 
-                        doc = GetXPathDocument ("langs/en.xml");
-                       nav = doc.CreateNavigator ();
-                       ni = nav.Select ("/ldml/localeDisplayNames/territories/territory");
-                       while (ni.MoveNext ()) {
-                               RegionInfoEntry r = (RegionInfoEntry)
-                                       regions [ni.Current.GetAttribute ("type", "")];
-                               if (r == null)
-                                       continue;
-                               r.EnglishName = ni.Current.Value;
+                       var node = doc.SelectSingleNode (string.Format ("ldml/dates/calendars/calendar[@type='{0}']", calendar));
+                       if (node != null) {
+                               el = doc.SelectSingleNode (string.Format ("ldml/localeDisplayNames/types/type[@type='{0}']", calendar));
+                               if (el != null)
+                                       df.NativeCalendarName = el.InnerText;
+
+
+                               // Apply global rule first <alias source="locale" path="../../monthContext[@type='format']/monthWidth[@type='wide']"/>
+                               nodes = node.SelectNodes ("months/monthContext[@type='format']/monthWidth[@type='wide']/month");
+                               ProcessAllNodes (nodes, df.MonthNames, AddOrReplaceValue);
+                               nodes = node.SelectNodes ("months/monthContext[@type='stand-alone']/monthWidth[@type='wide']/month");
+                               ProcessAllNodes (nodes, df.MonthNames, AddOrReplaceValue);
+
+                               // Apply global rule first <alias source="locale" path="../../monthContext[@type='format']/monthWidth[@type='abbreviated']"/>
+                               nodes = node.SelectNodes ("months/monthContext[@type='format']/monthWidth[@type='abbreviated']/month");
+                               ProcessAllNodes (nodes, df.AbbreviatedMonthNames, AddOrReplaceValue);
+                               nodes = node.SelectNodes ("months/monthContext[@type='stand-alone']/monthWidth[@type='abbreviated']/month");
+                               ProcessAllNodes (nodes, df.AbbreviatedMonthNames, AddOrReplaceValue);
+
+                               nodes = node.SelectNodes ("months/monthContext[@type='format']/monthWidth[@type='wide']/month");
+                               if (nodes != null)
+                                       ProcessAllNodes (nodes, df.MonthGenitiveNames, AddOrReplaceValue);
+
+                               nodes = node.SelectNodes ("days/dayContext[@type='format']/dayWidth[@type='wide']/day");
+                               ProcessAllNodes (nodes, df.DayNames, AddOrReplaceDayValue);
+
+                               // Apply global rule first <alias source="locale" path="../../dayContext[@type='format']/dayWidth[@type='abbreviated']"/>
+                               nodes = node.SelectNodes ("days/dayContext[@type='format']/dayWidth[@type='abbreviated']/day");
+                               ProcessAllNodes (nodes, df.AbbreviatedDayNames, AddOrReplaceDayValue);
+                               nodes = node.SelectNodes ("days/dayContext[@type='stand-alone']/dayWidth[@type='abbreviated']/day");
+                               ProcessAllNodes (nodes, df.AbbreviatedDayNames, AddOrReplaceDayValue);
+
+                               // TODO: This is not really ShortestDayNames as .NET uses it
+                               // Apply global rules first <alias source="locale" path="../../dayContext[@type='stand-alone']/dayWidth[@type='narrow']"/>
+                               nodes = node.SelectNodes ("days/dayContext[@type='format']/dayWidth[@type='narrow']/day");
+                               ProcessAllNodes (nodes, df.ShortestDayNames, AddOrReplaceDayValue);
+                               nodes = node.SelectNodes ("days/dayContext[@type='stand-alone']/dayWidth[@type='narrow']/day");
+                               ProcessAllNodes (nodes, df.ShortestDayNames, AddOrReplaceDayValue);
+/*
+                               Cannot really be used it's too different to .NET and most app rely on it
+                               el = node.SelectSingleNode ("dateFormats/dateFormatLength[@type='full']/dateFormat/pattern");
+                               if (el != null)
+                                       df.LongDatePattern = ConvertDatePatternFormat (el.InnerText);
+
+                               // Medium is our short
+                               el = node.SelectSingleNode ("dateFormats/dateFormatLength[@type='medium']/dateFormat/pattern");
+                               if (el != null)
+                                       df.ShortDatePattern = ConvertDatePatternFormat (el.InnerText);
+
+                               // Medium is our Long
+                               el = node.SelectSingleNode ("timeFormats/timeFormatLength[@type='medium']/timeFormat/pattern");
+                               if (el != null)
+                                       df.LongTimePattern = ConvertTimePatternFormat (el.InnerText);
+
+                               el = node.SelectSingleNode ("timeFormats/timeFormatLength[@type='short']/timeFormat/pattern");
+                               if (el != null)
+                                       df.ShortTimePattern = ConvertTimePatternFormat (el.InnerText);
+
+                               el = node.SelectSingleNode ("dateTimeFormats/availableFormats/dateFormatItem[@id='yyyyMMMM']");
+                               if (el != null)
+                                       df.YearMonthPattern = ConvertDatePatternFormat (el.InnerText);
+
+                               el = node.SelectSingleNode ("dateTimeFormats/availableFormats/dateFormatItem[@id='MMMMdd']");
+                               if (el != null)
+                                       df.MonthDayPattern = ConvertDatePatternFormat (el.InnerText);
+*/
+                               el = node.SelectSingleNode ("dayPeriods/dayPeriodContext/dayPeriodWidth[@type='abbreviated']/dayPeriod[@type='am']");
+                               if (el == null)
+                                       // Apply global rule first <alias source="locale" path="../dayPeriodWidth[@type='wide']"/>
+                                       el = node.SelectSingleNode ("dayPeriods/dayPeriodContext/dayPeriodWidth[@type='wide']/dayPeriod[@type='am']");
+
+                               if (el != null)
+                                       df.AMDesignator = el.InnerText;
+
+                               el = node.SelectSingleNode ("dayPeriods/dayPeriodContext/dayPeriodWidth[@type='abbreviated']/dayPeriod[@type='pm']");
+                               if (el == null)
+                                       // Apply global rule first <alias source="locale" path="../dayPeriodWidth[@type='wide']"/>
+                                       el = node.SelectSingleNode ("dayPeriods/dayPeriodContext/dayPeriodWidth[@type='wide']/dayPeriod[@type='pm']");
+
+                               // No data
+                               if (el != null)
+                                       df.PMDesignator = el.InnerText;
                        }
 
-                       Hashtable curNames = new Hashtable ();
-                       ni = nav.Select ("/ldml/numbers/currencies/currency");
-                       while (ni.MoveNext ())
-                               curNames [ni.Current.GetAttribute ("type", "")] =
-                                       ni.Current.Evaluate ("string (displayName)");
+                       var ni = ci.NumberFormatEntry;
 
-                       foreach (RegionInfoEntry r in regions.Values)
-                               r.CurrencyEnglishName =
-                                       (string) curNames [r.ISOCurrencySymbol];
-               }
+                       node = doc.SelectSingleNode ("ldml/numbers/symbols");
+                       if (node != null) {
+                               el = node.SelectSingleNode ("decimal");
+                               if (el != null) {
+                                       ni.NumberDecimalSeparator =
+                                       ni.PercentDecimalSeparator =
+                                       ni.CurrencyDecimalSeparator = el.InnerText;
+                               }
+
+                               el = node.SelectSingleNode ("plusSign");
+                               if (el != null)
+                                       ni.PositiveSign = el.InnerText;
+
+                               el = node.SelectSingleNode ("minusSign");
+                               if (el != null)
+                                       ni.NegativeSign = el.InnerText;
+
+                               el = node.SelectSingleNode ("infinity");
+                               if (el != null) {
+                                       ni.InfinitySymbol = el.InnerText;
+                               }
 
-                private void LookupCurrencyTypes ()
-                {
-                        XPathDocument doc = GetXPathDocument ("supplementalData.xml");
-                       XPathNavigator nav = doc.CreateNavigator ();
+                               el = node.SelectSingleNode ("perMille");
+                               if (el != null)
+                                       ni.PerMilleSymbol = el.InnerText;
 
-                        currency_types = new Hashtable ();
+                               el = node.SelectSingleNode ("nan");
+                               if (el != null)
+                                       ni.NaNSymbol = el.InnerText;
 
-                       XPathNodeIterator ni =(XPathNodeIterator) nav.Evaluate ("supplementalData/currencyData/region");
-                       while (ni.MoveNext ()) {
-                               string territory = (string) ni.Current.GetAttribute ("iso3166", String.Empty);
-                                string currency = (string) ni.Current.Evaluate ("string(currency/@iso4217)");
-                                currency_types [territory] = currency;
+                               el = node.SelectSingleNode ("percentSign");
+                               if (el != null)
+                                       ni.PercentSymbol = el.InnerText;
+
+                               el = node.SelectSingleNode ("group");
+                               if (el != null) {
+                                       ni.NumberGroupSeparator =
+                                       ni.PercentGroupSeparator =
+                                       ni.CurrencyGroupSeparator = el.InnerText;
+                               }
                        }
-                }
-
-                static string control_chars = "eghmsftz";
-
-                // HACK: We are trying to build year_month and month_day patterns from the full pattern.
-                private void ParseFullDateFormat (DateTimeFormatEntry df, string full)
-                {
-                        
-                        string month_day = String.Empty;
-                        string year_month = String.Empty;
-                        bool in_month_data = false;
-                        bool in_year_data = false;
-                       int day_start = 0, day_end = 0;
-                        int month_start = 0, month_end = 0;
-                        int year_start = 0, year_end = 0;
-                       bool inquote = false;
-                        
-                        for (int i = 0; i < full.Length; i++) {
-                                char c = full [i];
-                               if (!inquote && c == 'M') {
-                                        month_day += c;
-                                        year_month += c;
-                                        in_year_data = true;
-                                        in_month_data = true;
-                                       if (month_start == 0)
-                                               month_start = i;
-                                        month_end = i;
-                                        year_end = year_month.Length;
-                                } else if (!inquote && Char.ToLower (c) == 'd') {
-                                        month_day += c;
-                                        in_month_data = true;
-                                        in_year_data = false;
-                                       if (day_start == 0)
-                                               day_start = i;
-                                        day_end = i;
-                                } else if (!inquote && Char.ToLower (c) == 'y') {
-                                        year_month += c;
-                                        in_year_data = true;
-                                        in_month_data = false;
-                                       if (year_start == 0)
-                                               year_start = i;
-                                        year_end = i;
-                                } else if (!inquote && control_chars.IndexOf (Char.ToLower (c)) >= 0) {
-                                        in_year_data = false;
-                                        in_month_data = false;
-                                } else if (in_year_data || in_month_data) {
-                                        if (in_month_data)
-                                                month_day += c;
-                                        if (in_year_data)
-                                                year_month += c;
-                                }
-
-                               if (c == '\'') {
-                                       inquote = !inquote;
-                                }
-                        }
-
-                        if (month_day != String.Empty) {
-                                //month_day = month_day.Substring (0, month_end);
-                                df.MonthDayPattern = TrimPattern (month_day);
-                        }
-                        if (year_month != String.Empty) {
-                                //year_month = year_month.Substring (0, year_end);
-                                df.YearMonthPattern = TrimPattern (year_month);
-                        }
-                }
-
-               string TrimPattern (string p)
+               }
+
+               static string ConvertDatePatternFormat (string format)
+               {
+                       //
+                       // LDMR uses different characters for some fields
+                       // http://unicode.org/reports/tr35/#Date_Format_Patterns
+                       //
+                       format = format.Replace ("EEEE", "dddd"); // The full name of the day of the week
+                       format = format.Replace ("LLLL", "MMMM"); // The full month name
+
+                       if (format.EndsWith (" y", StringComparison.Ordinal))
+                               format += "yyy";
+
+                       return format;
+               }
+
+               static string ConvertTimePatternFormat (string format)
                {
-                       int idx = 0;
-                       p = p.Trim ().TrimEnd (',');
-                       idx = p.LastIndexOf ("' de '"); // spanish dates
-                       if (idx > 0)
-                               p = p.Substring (0, idx);
-                       idx = p.LastIndexOf ("' ta '"); // finnish
-                       if (idx > 0)
-                               p = p.Substring (0, idx);
-                       idx = p.LastIndexOf ("'ren'"); // euskara
-                       if (idx > 0)
-                               p = p.Replace ("'ren'", "").Trim ();
-                       idx = p.LastIndexOf ("'a'"); // estonian
-                       if (idx > 0)
-                               p = p.Substring (0, idx);
-
-                       return p.Replace ("'ta '", "'ta'"); // finnish
+                       format = format.Replace ("a", "tt"); // AM or PM
+                       return format;
                }
 
-                private class LcidComparer : IComparer {
+               static void ProcessAllNodes (XmlNodeList list, IList<string> values, Action<IList<string>, string, string> convertor)
+               {
+                       foreach (XmlNode entry in list) {
+                               var index = entry.Attributes["type"].Value;
+                               var value = entry.InnerText;
+                               convertor (values, index, value);
+                       }
+               }
 
-                        public int Compare (object a, object b)
-                        {
-                                CultureInfoEntry aa = (CultureInfoEntry) a;
-                                CultureInfoEntry bb = (CultureInfoEntry) b;
-                        
-                                return aa.Lcid.CompareTo (bb.Lcid);
-                        }                
-                }
+               // All text indexes are 1-based
+               static void AddOrReplaceValue (IList<string> list, string oneBasedIndex, string value)
+               {
+                       int index = int.Parse (oneBasedIndex);
+                       AddOrReplaceValue (list, index - 1, value);
+               }
 
-                private class NameComparer : IComparer {
+               static readonly string[] day_types = new string[] { "sun", "mon", "tue", "wed", "thu", "fri", "sat" };
 
-                        public int Compare (object a, object b)
-                        {
-                                CultureInfoEntry aa = (CultureInfoEntry) a;
-                                CultureInfoEntry bb = (CultureInfoEntry) b;
+               static void AddOrReplaceDayValue (IList<string> list, string dayType, string value)
+               {
+                       int index = Array.IndexOf (day_types, dayType);
+                       AddOrReplaceValue (list, index, value);
+               }
 
-                                return String.CompareOrdinal(aa.Name.ToLower (), bb.Name.ToLower ());
-                        }
-                }
+               static void AddOrReplaceValue (IList<string> list, int index, string value)
+               {
+                       if (list.Count <= index)
+                               ((List<string>) list).AddRange (new string[index - list.Count + 1]);
 
-               class RegionComparer : IComparer
+                       list[index] = value;
+               }
+
+               sealed class LcidComparer : IComparer<CultureInfoEntry>
                {
-                       public static RegionComparer Instance = new RegionComparer ();
-                       
-                       public int Compare (object o1, object o2)
+                       public int Compare (CultureInfoEntry x, CultureInfoEntry y)
                        {
-                               RegionInfoEntry r1 = (RegionInfoEntry) o1;
-                               RegionInfoEntry r2 = (RegionInfoEntry) o2;
-                               return String.CompareOrdinal (
-                                       r1.ISO2Name, r2.ISO2Name);
+                               return x.LCID.CompareTo (y.LCID);
                        }
                }
 
-               class RegionLCIDMap
+               sealed class ExportNameComparer : IComparer<CultureInfoEntry>
                {
-                       public RegionLCIDMap (int lcid, int regionId)
+                       public int Compare (CultureInfoEntry x, CultureInfoEntry y)
                        {
-                               LCID = lcid;
-                               RegionId = regionId;
+                               return String.Compare (x.GetExportName (), y.GetExportName (), StringComparison.OrdinalIgnoreCase);
                        }
+               }
 
-                       public int LCID;
-                       public int RegionId;
+               class RegionComparer : IComparer<RegionInfoEntry>
+               {
+                       public int Compare (RegionInfoEntry x, RegionInfoEntry y)
+                       {
+                               return x.TwoLetterISORegionName.CompareTo (y.TwoLetterISORegionName);
+                       }
                }
-        }
+       }
 }
-
-
index a26f64c33387a99996cd667701b8cc122a1f5cc8..2e7b7be34d5c0458acf95c43f339892e657aac97 100644 (file)
@@ -1,23 +1,48 @@
 //
+// Entry.cs
 //
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
 using System;
 using System.Text;
-using System.Collections;
-
-namespace Mono.Tools.LocaleBuilder {
-
-        public class Entry {
+using System.Collections.Generic;
 
+namespace Mono.Tools.LocaleBuilder
+{
+       public class Entry
+       {
                // maps strings to indexes
-               static Hashtable hash;
-               static ArrayList string_order;
+               static Dictionary<string, int> hash = new Dictionary<string, int> ();
+               static List<string> string_order = new List<string> ();
                // idx 0 is reserved to indicate null
                static int curpos = 1;
 
                // serialize the strings in Hashtable.
-               public static string GetStrings () {
+               public static string GetStrings ()
+               {
                        Console.WriteLine ("Total string data size: {0}", curpos);
                        if (curpos > UInt16.MaxValue)
                                throw new Exception ("need to increase idx size in culture-info.h");
@@ -31,54 +56,61 @@ namespace Mono.Tools.LocaleBuilder {
                        }
                        return ret.ToString ();
                }
-               static Entry () {
-                       hash = new Hashtable ();
-                       string_order = new ArrayList ();
-               }
-               static int AddString (string s, int size) {
-                       object o = hash [s];
-                       if (o == null) {
+
+               static int AddString (string s, int size)
+               {
+                       if (!hash.ContainsKey (s)) {
                                int ret;
                                string_order.Add (s);
                                ret = curpos;
-                               hash [s] = curpos;
+                               hash.Add (s, curpos);
                                curpos += size + 1; // null terminator
                                return ret;
-                       } else {
-                               return (int)o;
                        }
+
+                       return hash[s];
                }
 
-                internal static String EncodeStringIdx (string str)
-                {
-                        if (str == null)
-                                return "0";
+               protected static StringBuilder AppendNames (StringBuilder builder, IList<string> names)
+               {
+                       builder.Append ('{');
+                       for (int i = 0; i < names.Count; i++) {
+                               if (i > 0)
+                                       builder.Append (", ");
 
-                        StringBuilder ret = new StringBuilder ();
-                        byte [] ba = new UTF8Encoding ().GetBytes (str);
-                        bool in_hex = false;
-                        foreach (byte b in ba) {
-                                if (b > 127 || (in_hex && is_hex (b))) {
-                                        ret.AppendFormat ("\\x{0:x}", b);
-                                        in_hex = true;
-                                } else {
-                                        if (b == '\\')
-                                                ret.Append ('\\');
-                                        ret.Append ((char) b);
-                                        in_hex = false;
-                                }
-                        }
+                               builder.Append (EncodeStringIdx (names[i]));
+                       }
+                       builder.Append ("}");
+
+                       return builder;
+               }
+
+               internal static String EncodeStringIdx (string str)
+               {
+                       if (str == null)
+                               return "0";
+
+                       StringBuilder ret = new StringBuilder ();
+                       byte[] ba = new UTF8Encoding ().GetBytes (str);
+                       bool in_hex = false;
+                       foreach (byte b in ba) {
+                               if (b > 127 || (in_hex && is_hex (b))) {
+                                       ret.AppendFormat ("\\x{0:x}", b);
+                                       in_hex = true;
+                               } else {
+                                       if (b == '\\')
+                                               ret.Append ('\\');
+                                       ret.Append ((char) b);
+                                       in_hex = false;
+                               }
+                       }
                        int res = AddString (ret.ToString (), ba.Length);
-                        return res.ToString ();
-                }
+                       return res.ToString ();
+               }
 
-                private static bool is_hex (int e)
+               private static bool is_hex (int e)
                {
                        return (e >= '0' && e <= '9') || (e >= 'A' && e <= 'F') || (e >= 'a' && e <= 'f');
                }
-        }
+       }
 }
-
-
-
-
index c87dc6bec756d5488192bc7f2e8799d27bc789a6..c30980292626d72826c9d9f4d17a9685694373f7 100644 (file)
@@ -8,7 +8,7 @@ MCSFLAGS = -debug+
 #      make minimal MINIMAL_LOCALES=en_US
 # MINIMAL_LOCALES is a regular expression over the filenames in locales.
 # make minimal saves about 60 KB of the mono binary size.
-# To create the tables fro all the supported locales, use:
+# To create the tables for all the supported locales, use:
 #      make culture-table
 # After make minimal or make culture-table, you need to run:
 #      make install-culture-table
@@ -19,6 +19,9 @@ MINIMAL_LOCALES=en
 CLEANFILES = locale-builder.exe culture-info-tables.h
 
 locale_builder_sources = Driver.cs             \
+                       CalendarType.cs \
+                       Constants.cs \
+                       Patterns.cs \
                         CultureInfoEntry.cs    \
                         DateTimeFormatEntry.cs \
                         NumberFormatEntry.cs   \
@@ -26,140 +29,21 @@ locale_builder_sources = Driver.cs         \
                         TextInfoEntry.cs       \
                         Entry.cs
 
-supp_data_files =      \
-       supp/af_ZA.xml  \
-       supp/ar_AE.xml  \
-       supp/ar_BH.xml  \
-       supp/ar_DZ.xml  \
-       supp/ar_EG.xml  \
-       supp/ar_IQ.xml  \
-       supp/ar_JO.xml  \
-       supp/ar_KW.xml  \
-       supp/ar_LB.xml  \
-       supp/ar_LY.xml  \
-       supp/ar_MA.xml  \
-       supp/ar_OM.xml  \
-       supp/ar_QA.xml  \
-       supp/ar_SA.xml  \
-       supp/ar_SY.xml  \
-       supp/ar_TN.xml  \
-       supp/ar.xml     \
-       supp/ar_YE.xml  \
-       supp/be_BY.xml  \
-       supp/bg.xml     \
-       supp/ca_ES.xml  \
-       supp/ChangeLog  \
-       supp/cs_CZ.xml  \
-       supp/da.xml     \
-       supp/de_AT.xml  \
-       supp/de.xml     \
-       supp/el.xml     \
-       supp/en_AU.xml  \
-       supp/en_CA.xml  \
-       supp/en_GB.xml  \
-       supp/en_IE.xml  \
-       supp/en_NZ.xml  \
-       supp/en_PH.xml  \
-       supp/en_TT.xml  \
-       supp/en_US.xml  \
-       supp/en.xml     \
-       supp/en_ZA.xml  \
-       supp/en_ZW.xml  \
-       supp/es_AR.xml  \
-       supp/es_BO.xml  \
-       supp/es_CL.xml  \
-       supp/es_CO.xml  \
-       supp/es_CR.xml  \
-       supp/es_DO.xml  \
-       supp/es_EC.xml  \
-       supp/es_ES.xml  \
-       supp/es_GT.xml  \
-       supp/es_HN.xml  \
-       supp/es_MX.xml  \
-       supp/es_NI.xml  \
-       supp/es_PA.xml  \
-       supp/es_PE.xml  \
-       supp/es_PR.xml  \
-       supp/es_PY.xml  \
-       supp/es_SV.xml  \
-       supp/es_UY.xml  \
-       supp/es_VE.xml  \
-       supp/es.xml     \
-       supp/et.xml     \
-       supp/eu_ES.xml  \
-       supp/fa.xml     \
-       supp/fi.xml     \
-       supp/fo_FO.xml  \
-       supp/fr_BE.xml  \
-       supp/fr_CA.xml  \
-       supp/fr_CH.xml  \
-       supp/fr_FR.xml  \
-       supp/fr_LU.xml  \
-       supp/fr.xml     \
-       supp/he.xml     \
-       supp/hi_IN.xml  \
-       supp/hr.xml     \
-       supp/hu.xml     \
-       supp/hy.xml     \
-       supp/id_ID.xml  \
-       supp/is.xml     \
-       supp/it_CH.xml  \
-       supp/it_IT.xml  \
-       supp/ja.xml     \
-       supp/ka_GE.xml  \
-       supp/ko_KR.xml  \
-       supp/lt_LT.xml  \
-       supp/lv.xml     \
-       supp/mk.xml     \
-       supp/nl_BE.xml  \
-       supp/nl_NL.xml  \
-       supp/pl.xml     \
-       supp/pt_BR.xml  \
-       supp/pt_PT.xml  \
-       supp/pt.xml     \
-       supp/root.xml   \
-       supp/ro.xml     \
-       supp/ru.xml     \
-       supp/sk.xml     \
-       supp/sl.xml     \
-       supp/sq.xml     \
-       supp/sv_FI.xml  \
-       supp/sv_SE.xml  \
-       supp/sw_KE.xml  \
-       supp/th.xml     \
-       supp/tr.xml     \
-       supp/uk.xml     \
-       supp/vi.xml
-
-extra_langs = \
-       langs/ka.xml    
-
-extra_locales = \
-       locales/ka_GE.xml
-
-EXTRA_DIST = $(locale_builder_sources) $(supp_data_files) lcids.xml supplementalData.xml textinfo.xml \
-       $(extra_langs) $(extra_locales)
-
+EXTRA_DIST = $(locale_builder_sources) lcids.xml
 
 locale-builder.exe: $(locale_builder_sources)
        $(MCS) $(MCSFLAGS) /out:$@ $^
 
-culture-table: locale-builder.exe lang-data locale-data
+culture-table: locale-builder.exe locale-data
        $(RUNTIME) locale-builder.exe
 
-minimal: locale-builder.exe lang-data locale-data
+minimal: locale-builder.exe locale-data
        $(RUNTIME) locale-builder.exe --locales '$(MINIMAL_LOCALES)'
 
-lang-data:
-       if ! test -f langs/en.xml ; then \
-               wget http://go-mono.com/icu/icu_langs.tar.gz ; \
-               tar xzvf icu_langs.tar.gz ; \
-       fi
-
 locale-data:
-       if ! test -f locales/en_US.xml ; then \
-               wget http://go-mono.com/icu/icu_locales.tar.gz ; \
-               tar xzvf icu_locales.tar.gz ; \
+       if ! test -d CLDR/common ; then \
+               wget http://www.unicode.org/Public/cldr/21/core.zip ; \
+               unzip core.zip -d CLDR ; \
        fi
 
 install-culture-table: culture-info-tables.h
index 5c74fcfcd5ac5e64d7c9eaf9a61c3bae779073a1..f90e58c24b732f21c7e471b4b6225d6f57437080 100644 (file)
+//
+// DateTimeFormatEntry.cs
 //
-// Mono.Tools.LocaleBuilder.NumberFormatEntry
-//
-// Author(s):
+// Authors:
 //  Jackson Harper (jackson@ximian.com)
+//     Marek Safar  <marek.safar@gmail.com>
 //
-// (C) 2004 Novell, Inc (http://www.novell.com)
+// (C) 2004, Novell, Inc (http://www.novell.com)
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-
-using System;
 using System.Text;
-
-namespace Mono.Tools.LocaleBuilder {
-
-        public class NumberFormatEntry : Entry {
-
-                public static readonly int MaxGroupSize = 5;
-
-                public int CurrencyDecimalDigits;
-                public string CurrencyDecimalSeparator;
-                public string CurrencyGroupSeparator;
-                public int [] CurrencyGroupSizes;
-                public int CurrencyNegativePattern;
-                public int CurrencyPositivePattern;
-                public string CurrencySymbol;
-                public string NaNSymbol;
-                public string NegativeSign;
-                public int NumberDecimalDigits;
-                public string NumberDecimalSeparator;
-                public string NumberGroupSeparator;
-                public int [] NumberGroupSizes;
-                public int NumberNegativePattern;
-                public int PercentDecimalDigits;
-                public string PercentDecimalSeparator;
-                public string PercentGroupSeparator;
-                public int [] PercentGroupSizes;
-                public int PercentNegativePattern;
-                public int PercentPositivePattern;
-                public string PercentSymbol;
-                public string PerMilleSymbol;
-                public string PositiveInfinitySymbol;
-                public string PositiveSign;
-
-                public int Row;
-
-                public string NegativeInfinitySymbol {
-                        get {
-                                return NegativeSign + PositiveInfinitySymbol;
-                        }
-                }
-                
-                public void AppendTableRow (StringBuilder builder)
-                {
-                        builder.Append ("\t{");
-
-                        builder.Append (EncodeStringIdx (CurrencyDecimalSeparator) + ", ");
-                        builder.Append (EncodeStringIdx (CurrencyGroupSeparator) + ", ");
-                        builder.Append (EncodeStringIdx (PercentDecimalSeparator) + ", ");
-                        builder.Append (EncodeStringIdx (PercentGroupSeparator) + ", ");
-                        builder.Append (EncodeStringIdx (NumberDecimalSeparator) + ", ");
-                        builder.Append (EncodeStringIdx (NumberGroupSeparator) + ", ");
-
-                        builder.Append (EncodeStringIdx (CurrencySymbol) + ", ");
-                        builder.Append (EncodeStringIdx (PercentSymbol) + ", ");
-                        builder.Append (EncodeStringIdx (NaNSymbol) + ", ");
-                        builder.Append (EncodeStringIdx (PerMilleSymbol) + ", ");
-                        builder.Append (EncodeStringIdx (NegativeInfinitySymbol) + ", ");
-                        builder.Append (EncodeStringIdx (PositiveInfinitySymbol) + ", ");
-
-                        builder.Append (EncodeStringIdx (NegativeSign) + ", ");
-                        builder.Append (EncodeStringIdx (PositiveSign) + ", ");
-
-                        builder.Append (CurrencyNegativePattern + ", ");
-                        builder.Append (CurrencyPositivePattern + ", ");
-                        builder.Append (PercentNegativePattern + ", ");
-                        builder.Append (PercentPositivePattern + ", ");
-                        builder.Append (NumberNegativePattern + ", ");
-
-                        builder.Append (CurrencyDecimalDigits + ", ");
-                        builder.Append (PercentDecimalDigits + ", ");
-                        builder.Append (NumberDecimalDigits + ", ");
-
-                        AppendGroupSizes (builder, CurrencyGroupSizes);
-                        builder.Append (", ");
-                        AppendGroupSizes (builder, PercentGroupSizes);
-                        builder.Append (", ");
-                        AppendGroupSizes (builder, NumberGroupSizes);
-                        
-                        builder.Append ('}');
-                }
-
-                private void AppendGroupSizes (StringBuilder builder, int [] gs)
-                {
-                        int len = (gs == null ? 0 : gs.Length);
-
-                        builder.Append ('{');
-                        for (int i = 0; i < MaxGroupSize; i++) {
-                                if (i < len)
-                                        builder.Append (gs [0]);
-                                else
-                                        builder.Append (-1);
-                                if (i+1 < MaxGroupSize)
-                                        builder.Append (", ");
-                        }
-                        builder.Append ('}');
-                }
-
-                public override string ToString ()
-                {
-                        StringBuilder builder = new StringBuilder ();
-                        AppendTableRow (builder);
-                        return builder.ToString ();
-                }
-        }
+using System.Globalization;
+
+namespace Mono.Tools.LocaleBuilder
+{
+       public class NumberFormatEntry : Entry
+       {
+               public string CurrencyDecimalDigits;
+               public string CurrencyDecimalSeparator = ",";
+               public string CurrencyGroupSeparator = ",";
+               public string[] CurrencyGroupSizes = new string[Constants.GROUP_SIZE];
+               public string CurrencyNegativePattern;
+               public string CurrencyPositivePattern;
+               public string CurrencySymbol;
+               public string NaNSymbol;
+               public string NegativeSign = "-";
+               public int NumberDecimalDigits;
+               public string NumberDecimalSeparator = ",";
+               public string NumberGroupSeparator = ",";
+               public string[] NumberGroupSizes = new string[Constants.GROUP_SIZE];
+               public string NumberNegativePattern;
+               public int PercentDecimalDigits;
+               public string PercentDecimalSeparator = ",";
+               public string PercentGroupSeparator = ",";
+               public string[] PercentGroupSizes = new string[Constants.GROUP_SIZE];
+               public string PercentNegativePattern;
+               public string PercentPositivePattern;
+               public string PercentSymbol = "%";
+               public string PerMilleSymbol = "‰";
+               public string InfinitySymbol = "∞";
+               public string PositiveSign = "+";
+               public DigitShapes DigitSubstitution = DigitShapes.None;
+               public string[] NativeDigits = new string[10] { "0", "1", "2", "3", "4", "5", "6", "7", "8", "9" };
+
+               public int Row;
+
+               public string NegativeInfinitySymbol
+               {
+                       get
+                       {
+                               return NegativeSign + InfinitySymbol;
+                       }
+               }
+
+               public string PositiveInfinitySymbol
+               {
+                       get
+                       {
+                               return PositiveSign + InfinitySymbol;
+                       }
+               }
+
+               public void AppendTableRow (StringBuilder builder)
+               {
+                       builder.Append ("\t{");
+
+                       builder.Append (EncodeStringIdx (CurrencyDecimalSeparator) + ", ");
+                       builder.Append (EncodeStringIdx (CurrencyGroupSeparator) + ", ");
+                       builder.Append (EncodeStringIdx (PercentDecimalSeparator) + ", ");
+                       builder.Append (EncodeStringIdx (PercentGroupSeparator) + ", ");
+                       builder.Append (EncodeStringIdx (NumberDecimalSeparator) + ", ");
+                       builder.Append (EncodeStringIdx (NumberGroupSeparator) + ", ");
+
+                       builder.Append (EncodeStringIdx (CurrencySymbol) + ", ");
+                       builder.Append (EncodeStringIdx (PercentSymbol) + ", ");
+                       builder.Append (EncodeStringIdx (NaNSymbol) + ", ");
+                       builder.Append (EncodeStringIdx (PerMilleSymbol) + ", ");
+                       builder.Append (EncodeStringIdx (NegativeInfinitySymbol) + ", ");
+                       builder.Append (EncodeStringIdx (PositiveInfinitySymbol) + ", ");
+
+                       builder.Append (EncodeStringIdx (NegativeSign) + ", ");
+                       builder.Append (EncodeStringIdx (PositiveSign) + ", ");
+
+                       builder.Append (CurrencyNegativePattern + ", ");
+                       builder.Append (CurrencyPositivePattern + ", ");
+                       builder.Append (PercentNegativePattern + ", ");
+                       builder.Append (PercentPositivePattern + ", ");
+                       builder.Append (NumberNegativePattern + ", ");
+
+                       builder.Append (CurrencyDecimalDigits + ", ");
+                       builder.Append (PercentDecimalDigits + ", ");
+                       builder.Append (NumberDecimalDigits + ", ");
+
+                       AppendGroupSizes (builder, CurrencyGroupSizes);
+                       builder.Append (", ");
+                       AppendGroupSizes (builder, PercentGroupSizes);
+                       builder.Append (", ");
+                       AppendGroupSizes (builder, NumberGroupSizes);
+
+                       builder.Append ('}');
+               }
+
+               static void AppendGroupSizes (StringBuilder builder, string[] gs)
+               {
+                       builder.Append ('{');
+                       for (int i = 0; i < gs.Length; i++) {
+                               if (i > 0)
+                                       builder.Append (", ");
+
+                               if (gs[i] == null)
+                                       builder.Append (-1);
+                               else
+                                       builder.Append (gs[i]);
+                       }
+
+                       builder.Append ('}');
+               }
+
+               public override string ToString ()
+               {
+                       StringBuilder builder = new StringBuilder ();
+                       AppendTableRow (builder);
+                       return builder.ToString ();
+               }
+       }
 }
 
diff --git a/tools/locale-builder/Patterns.cs b/tools/locale-builder/Patterns.cs
new file mode 100644 (file)
index 0000000..b36a586
--- /dev/null
@@ -0,0 +1,1781 @@
+//
+// Patterns.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.Collections.Generic;
+
+namespace Mono.Tools.LocaleBuilder
+{
+       static class Patterns
+       {
+               static readonly Dictionary<int, string[]> DateTime = new Dictionary<int, string[]> {
+                       { 0x0001, new [] { "/", "dd/MMMM/yyyy", "hh:mm:ss tt", "dd/MM/yy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0002, new [] { ".", "dd MMMM yyyy 'г.'", "HH:mm:ss 'ч.'", "d.M.yyyy 'г.'", "HH:mm 'ч.'", "dd MMMM", "MMMM yyyy 'г.'" } },
+                       { 0x0003, new [] { "/", "dddd, d' / 'MMMM' / 'yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM' / 'yyyy" } },
+                       { 0x0004, new [] { "/", "yyyy'年'M'月'd'日'", "H:mm:ss", "yyyy/M/d", "H:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x0005, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0006, new [] { "-", "d. MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0007, new [] { ".", "dddd, d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0008, new [] { "/", "dddd, d MMMM yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0009, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x000a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x000b, new [] { ".", "d. MMMM'ta 'yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM'ta'", "MMMM yyyy" } },
+                       { 0x000c, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x000d, new [] { "/", "dddd dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x000e, new [] { ".", "yyyy. MMMM d.", "H:mm:ss", "yyyy.MM.dd.", "H:mm", "MMMM d.", "yyyy. MMMM" } },
+                       { 0x000f, new [] { ".", "d. MMMM yyyy", "HH:mm:ss", "d.M.yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0010, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0011, new [] { "/", "yyyy'年'M'月'd'日'", "H:mm:ss", "yyyy/MM/dd", "H:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x0012, new [] { "-", "yyyy'년' M'월' d'일' dddd", "tt h:mm:ss", "yyyy-MM-dd", "tt h:mm", "M'월' d'일'", "yyyy'년' M'월'" } },
+                       { 0x0013, new [] { "-", "dddd d MMMM yyyy", "H:mm:ss", "d-M-yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0014, new [] { ".", "d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0015, new [] { "-", "d MMMM yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0016, new [] { "/", "dddd, d' de 'MMMM' de 'yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd' de 'MMMM", "MMMM' de 'yyyy" } },
+                       { 0x0017, new [] { "/", "dddd, d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0018, new [] { ".", "d MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0019, new [] { ".", "d MMMM yyyy 'г.'", "H:mm:ss", "dd.MM.yyyy", "H:mm", "MMMM dd", "MMMM yyyy" } },
+                       { 0x001a, new [] { ".", "d. MMMM yyyy.", "H:mm:ss", "d.M.yyyy.", "H:mm", "d. MMMM", "MMMM, yyyy" } },
+                       { 0x001b, new [] { ". ", "d. MMMM yyyy", "H:mm:ss", "d. M. yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x001c, new [] { "-", "yyyy-MM-dd", "h:mm:ss.tt", "yyyy-MM-dd", "h:mm.tt", "MMMM dd", "yyyy-MM" } },
+                       { 0x001d, new [] { "-", "'den 'd MMMM yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "'den 'd MMMM", "MMMM yyyy" } },
+                       { 0x001e, new [] { "/", "d MMMM yyyy", "H:mm:ss", "d/M/yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x001f, new [] { ".", "dd MMMM yyyy dddd", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0020, new [] { "/", "dd MMMM, yyyy", "h:mm:ss tt", "dd/MM/yyyy", "h:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0021, new [] { "/", "dd MMMM yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0022, new [] { ".", "d MMMM yyyy' р.'", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy' р.'" } },
+                       { 0x0023, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0024, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0025, new [] { ".", "d. MMMM yyyy'. a.'", "H:mm:ss", "d.MM.yyyy", "H:mm", "d. MMMM", "MMMM yyyy'. a.'" } },
+                       { 0x0026, new [] { ".", "dddd, yyyy'. gada 'd. MMMM", "H:mm:ss", "yyyy.MM.dd.", "H:mm", "d. MMMM", "yyyy. MMMM" } },
+                       { 0x0027, new [] { ".", "yyyy 'm.' MMMM d 'd.'", "HH:mm:ss", "yyyy.MM.dd", "HH:mm", "MMMM d 'd.'", "yyyy 'm.' MMMM" } },
+                       { 0x0028, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yy", "H:mm", "MMMM dd", "MMMM yyyy" } },
+                       { 0x0029, new [] { "/", "dddd, MMMM dd, yyyy", "hh:mm:ss tt", "MM/dd/yyyy", "hh:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x002a, new [] { "/", "dd MMMM yyyy", "h:mm:ss tt", "dd/MM/yyyy", "h:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x002b, new [] { ".", "d MMMM, yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM, yyyy" } },
+                       { 0x002c, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x002d, new [] { "/", "dddd, yyyy.'eko' MMMM'k 'd", "H:mm:ss", "yyyy/MM/dd", "HH:mm", "MMMM dd", "yyyy.'eko' MMMM" } },
+                       { 0x002e, new [] { ". ", "dddd, 'dnja' d. MMMM yyyy", "H:mm:ss", "d. M. yyyy", "H.mm 'hodź.'", "d. MMMM", "MMMM yyyy" } },
+                       { 0x002f, new [] { ".", "dddd, dd MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0032, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0034, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0035, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0036, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0037, new [] { ".", "yyyy 'წლის' dd MM, dddd", "H:mm:ss", "dd.MM.yyyy", "H:mm", "dd MM", "MMMM yyyy" } },
+                       { 0x0038, new [] { "-", "d. MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0039, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x003a, new [] { "/", "dddd, d' ta\' 'MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d' ta\' 'MMMM", "MMMM yyyy" } },
+                       { 0x003b, new [] { ".", "MMMM d'. b. 'yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x003c, new [] { "/", "d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x003e, new [] { "/", "dd MMMM yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x003f, new [] { ".", "d MMMM yyyy 'ж.'", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0040, new [] { ".", "d'-'MMMM yyyy'-ж.'", "H:mm:ss", "dd.MM.yy", "H:mm", "d MMMM", "MMMM yyyy'-ж.'" } },
+                       { 0x0041, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x0042, new [] { ".", "yyyy 'ý.' MMMM d", "H:mm:ss", "dd.MM.yy", "H:mm", "MMMM dd", "yyyy 'ý.' MMMM" } },
+                       { 0x0043, new [] { "/", "yyyy 'yil' d-MMMM", "HH:mm:ss", "dd/MM yyyy", "HH:mm", "d-MMMM", "MMMM yyyy" } },
+                       { 0x0044, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0045, new [] { "-", "dd MMMM yyyy", "HH.mm.ss", "dd-MM-yy", "HH.mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0046, new [] { "-", "dd MMMM yyyy dddd", "tt hh:mm:ss", "dd-MM-yy", "tt hh:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0047, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0048, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0049, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x004a, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x004b, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x004c, new [] { "-", "dd MMMM yyyy", "HH.mm.ss", "dd-MM-yy", "HH.mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x004d, new [] { "-", "yyyy,MMMM dd, dddd", "tt h:mm:ss", "dd-MM-yyyy", "tt h:mm", "dd MMMM", "MMMM,yy" } },
+                       { 0x004e, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x004f, new [] { "-", "dd MMMM yyyy dddd", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0050, new [] { ".", "yyyy 'оны' MMMM d", "H:mm:ss", "yy.MM.dd", "H:mm", "d MMMM", "yyyy 'он' MMMM" } },
+                       { 0x0051, new [] { "/", "yyyy'ལོའི་ཟླ' M'ཚེས' d", "HH:mm:ss", "yyyy/M/d", "HH:mm", "'ཟླ་' M'ཚེས'd", "yyyy.M" } },
+                       { 0x0052, new [] { "/", "dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0053, new [] { "-", "d MMMM yyyy", "HH:mm:ss", "yyyy-MM-dd", "H:mm tt", "'ថ្ងៃទី' dd 'ខែ' MM", "'ខែ' MM 'ឆ្នាំ' yyyy" } },
+                       { 0x0054, new [] { "/", "dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "H:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0056, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x0057, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x005a, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x005b, new [] { "-", "yyyy MMMM' මස 'dd' වැනිදා 'dddd", "h:mm:ss tt", "yyyy-MM-dd", "h:mm tt", "MMMM dd", "yyyy MMMM" } },
+                       { 0x005d, new [] { "/", "ddd, MMMM dd,yyyy", "h:mm:ss tt", "d/MM/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x005e, new [] { "/", "dddd '፣' MMMM d 'ቀን' yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM d ቀን", "MMMM yyyy" } },
+                       { 0x005f, new [] { "-", "dd MMMM, yyyy", "H:mm:ss", "dd-MM-yyyy", "H:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0061, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM,yyyy" } },
+                       { 0x0062, new [] { "-", "dddd d MMMM yyyy", "H:mm:ss", "d-M-yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0063, new [] { "/", "dd/MM/yyyy", "h:mm:ss tt", "dd/MM/yy", "h:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0064, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x0065, new [] { "/", "dd/MM/yyyy", "HH:mm:ss", "dd/MM/yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0068, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x006a, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x006b, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "MMMM dd", "MMMM' de 'yyyy" } },
+                       { 0x006c, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x006d, new [] { ".", "d MMMM yyyy 'й'", "H:mm:ss", "dd.MM.yy", "H:mm", "MMMM dd", "MMMM yyyy" } },
+                       { 0x006e, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x006f, new [] { "-", "d. MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0070, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x0078, new [] { "/", "yyyy'ꈎ' M'ꆪ' d'ꑍ'", "H:mm:ss", "yyyy/M/d", "tt h:mm", "M'ꆪ' d'ꑍ'", "yyyy'ꈎ' M'ꆪ'" } },
+                       { 0x007a, new [] { "-", "dddd, dd' de 'MMMM' de 'yyyy", "H:mm:ss", "dd-MM-yyyy", "H:mm", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x007c, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x007e, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x007f, new [] { "/", "dddd, dd MMMM yyyy", "HH:mm:ss", "MM/dd/yyyy", "HH:mm", "MMMM dd", "yyyy MMMM" } },
+                       { 0x0080, new [] { "-", "yyyy-'يىلى' MMMM d-'كۈنى،'", "H:mm:ss", "yyyy-M-d", "H:mm", "MMMM d'-كۈنى'", "yyyy-'يىلى' MMMM" } },
+                       { 0x0081, new [] { "/", "dddd, dd MMMM, yyyy", "h:mm:ss tt", "dd/MM/yyyy", "h:mm tt", "dd MMMM", "MMMM, yy" } },
+                       { 0x0082, new [] { "/", "dddd,' lo 'd MMMM' de 'yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0083, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0084, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0085, new [] { ".", "MMMM d yyyy 'с.'", "H:mm:ss", "MM.dd.yyyy", "H:mm", "MMMM dd", "MMMM yyyy 'с.'" } },
+                       { 0x0086, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x0087, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x0088, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x008c, new [] { "/", "dd/MM/yyyy", "h:mm:ss tt", "dd/MM/yy", "h:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0091, new [] { "/", "dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0401, new [] { "/", "dd/MMMM/yyyy", "hh:mm:ss tt", "dd/MM/yy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0402, new [] { ".", "dd MMMM yyyy 'г.'", "HH:mm:ss 'ч.'", "d.M.yyyy 'г.'", "HH:mm 'ч.'", "dd MMMM", "MMMM yyyy 'г.'" } },
+                       { 0x0403, new [] { "/", "dddd, d' / 'MMMM' / 'yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM' / 'yyyy" } },
+                       { 0x0404, new [] { "/", "yyyy'年'M'月'd'日'", "tt hh:mm:ss", "yyyy/M/d", "tt hh:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x0405, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0406, new [] { "-", "d. MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0407, new [] { ".", "dddd, d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0408, new [] { "/", "dddd, d MMMM yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0409, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x040b, new [] { ".", "d. MMMM'ta 'yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM'ta'", "MMMM yyyy" } },
+                       { 0x040c, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x040d, new [] { "/", "dddd dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x040e, new [] { ".", "yyyy. MMMM d.", "H:mm:ss", "yyyy.MM.dd.", "H:mm", "MMMM d.", "yyyy. MMMM" } },
+                       { 0x040f, new [] { ".", "d. MMMM yyyy", "HH:mm:ss", "d.M.yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0410, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0411, new [] { "/", "yyyy'年'M'月'd'日'", "H:mm:ss", "yyyy/MM/dd", "H:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x0412, new [] { "-", "yyyy'년' M'월' d'일' dddd", "tt h:mm:ss", "yyyy-MM-dd", "tt h:mm", "M'월' d'일'", "yyyy'년' M'월'" } },
+                       { 0x0413, new [] { "-", "dddd d MMMM yyyy", "H:mm:ss", "d-M-yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0414, new [] { ".", "d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0415, new [] { "-", "d MMMM yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0416, new [] { "/", "dddd, d' de 'MMMM' de 'yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd' de 'MMMM", "MMMM' de 'yyyy" } },
+                       { 0x0417, new [] { "/", "dddd, d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0418, new [] { ".", "d MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0419, new [] { ".", "d MMMM yyyy 'г.'", "H:mm:ss", "dd.MM.yyyy", "H:mm", "MMMM dd", "MMMM yyyy" } },
+                       { 0x041a, new [] { ".", "d. MMMM yyyy.", "H:mm:ss", "d.M.yyyy.", "H:mm", "d. MMMM", "MMMM, yyyy" } },
+                       { 0x041b, new [] { ". ", "d. MMMM yyyy", "H:mm:ss", "d. M. yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x041c, new [] { "-", "yyyy-MM-dd", "h:mm:ss.tt", "yyyy-MM-dd", "h:mm.tt", "MMMM dd", "yyyy-MM" } },
+                       { 0x041d, new [] { "-", "'den 'd MMMM yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "'den 'd MMMM", "MMMM yyyy" } },
+                       { 0x041e, new [] { "/", "d MMMM yyyy", "H:mm:ss", "d/M/yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x041f, new [] { ".", "dd MMMM yyyy dddd", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0420, new [] { "/", "dd MMMM, yyyy", "h:mm:ss tt", "dd/MM/yyyy", "h:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0421, new [] { "/", "dd MMMM yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0422, new [] { ".", "d MMMM yyyy' р.'", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy' р.'" } },
+                       { 0x0423, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0424, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0425, new [] { ".", "d. MMMM yyyy'. a.'", "H:mm:ss", "d.MM.yyyy", "H:mm", "d. MMMM", "MMMM yyyy'. a.'" } },
+                       { 0x0426, new [] { ".", "dddd, yyyy'. gada 'd. MMMM", "H:mm:ss", "yyyy.MM.dd.", "H:mm", "d. MMMM", "yyyy. MMMM" } },
+                       { 0x0427, new [] { ".", "yyyy 'm.' MMMM d 'd.'", "HH:mm:ss", "yyyy.MM.dd", "HH:mm", "MMMM d 'd.'", "yyyy 'm.' MMMM" } },
+                       { 0x0428, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yy", "H:mm", "MMMM dd", "MMMM yyyy" } },
+                       { 0x0429, new [] { "/", "dddd, MMMM dd, yyyy", "hh:mm:ss tt", "MM/dd/yyyy", "hh:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x042a, new [] { "/", "dd MMMM yyyy", "h:mm:ss tt", "dd/MM/yyyy", "h:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x042b, new [] { ".", "d MMMM, yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM, yyyy" } },
+                       { 0x042c, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x042d, new [] { "/", "dddd, yyyy.'eko' MMMM'k 'd", "H:mm:ss", "yyyy/MM/dd", "HH:mm", "MMMM dd", "yyyy.'eko' MMMM" } },
+                       { 0x042e, new [] { ". ", "dddd, 'dnja' d. MMMM yyyy", "H:mm:ss", "d. M. yyyy", "H.mm 'hodź.'", "d. MMMM", "MMMM yyyy" } },
+                       { 0x042f, new [] { ".", "dddd, dd MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0432, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0434, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0435, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0436, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0437, new [] { ".", "yyyy 'წლის' dd MM, dddd", "H:mm:ss", "dd.MM.yyyy", "H:mm", "dd MM", "MMMM yyyy" } },
+                       { 0x0438, new [] { "-", "d. MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0439, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x043a, new [] { "/", "dddd, d' ta\' 'MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d' ta\' 'MMMM", "MMMM yyyy" } },
+                       { 0x043b, new [] { ".", "MMMM d'. b. 'yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x043e, new [] { "/", "dd MMMM yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x043f, new [] { ".", "d MMMM yyyy 'ж.'", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0440, new [] { ".", "d'-'MMMM yyyy'-ж.'", "H:mm:ss", "dd.MM.yy", "H:mm", "d MMMM", "MMMM yyyy'-ж.'" } },
+                       { 0x0441, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x0442, new [] { ".", "yyyy 'ý.' MMMM d", "H:mm:ss", "dd.MM.yy", "H:mm", "MMMM dd", "yyyy 'ý.' MMMM" } },
+                       { 0x0443, new [] { "/", "yyyy 'yil' d-MMMM", "HH:mm:ss", "dd/MM yyyy", "HH:mm", "d-MMMM", "MMMM yyyy" } },
+                       { 0x0444, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0445, new [] { "-", "dd MMMM yyyy", "HH.mm.ss", "dd-MM-yy", "HH.mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0446, new [] { "-", "dd MMMM yyyy dddd", "tt hh:mm:ss", "dd-MM-yy", "tt hh:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0447, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0448, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0449, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x044a, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x044b, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x044c, new [] { "-", "dd MMMM yyyy", "HH.mm.ss", "dd-MM-yy", "HH.mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x044d, new [] { "-", "yyyy,MMMM dd, dddd", "tt h:mm:ss", "dd-MM-yyyy", "tt h:mm", "dd MMMM", "MMMM,yy" } },
+                       { 0x044e, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x044f, new [] { "-", "dd MMMM yyyy dddd", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0450, new [] { ".", "yyyy 'оны' MMMM d", "H:mm:ss", "yy.MM.dd", "H:mm", "d MMMM", "yyyy 'он' MMMM" } },
+                       { 0x0451, new [] { "/", "yyyy'ལོའི་ཟླ' M'ཚེས' d", "HH:mm:ss", "yyyy/M/d", "HH:mm", "'ཟླ་' M'ཚེས'd", "yyyy.M" } },
+                       { 0x0452, new [] { "/", "dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0453, new [] { "-", "d MMMM yyyy", "HH:mm:ss", "yyyy-MM-dd", "H:mm tt", "'ថ្ងៃទី' dd 'ខែ' MM", "'ខែ' MM 'ឆ្នាំ' yyyy" } },
+                       { 0x0454, new [] { "/", "dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "H:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0456, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x0457, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x045a, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x045b, new [] { "-", "yyyy MMMM' මස 'dd' වැනිදා 'dddd", "h:mm:ss tt", "yyyy-MM-dd", "h:mm tt", "MMMM dd", "yyyy MMMM" } },
+                       { 0x045d, new [] { "/", "dddd,MMMM dd,yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM dd", "MMMM,yyyy" } },
+                       { 0x045e, new [] { "/", "dddd '፣' MMMM d 'ቀን' yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM d ቀን", "MMMM yyyy" } },
+                       { 0x0461, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM,yyyy" } },
+                       { 0x0462, new [] { "-", "dddd d MMMM yyyy", "H:mm:ss", "d-M-yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0463, new [] { "/", "dd/MM/yyyy", "h:mm:ss tt", "dd/MM/yy", "h:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0464, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x0465, new [] { "/", "dd/MM/yyyy", "HH:mm:ss", "dd/MM/yy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0468, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x046a, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x046b, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "MMMM dd", "MMMM' de 'yyyy" } },
+                       { 0x046c, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x046d, new [] { ".", "d MMMM yyyy 'й'", "H:mm:ss", "dd.MM.yy", "H:mm", "MMMM dd", "MMMM yyyy" } },
+                       { 0x046e, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x046f, new [] { "-", "d. MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0470, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x0478, new [] { "/", "yyyy'ꈎ' M'ꆪ' d'ꑍ'", "H:mm:ss", "yyyy/M/d", "tt h:mm", "M'ꆪ' d'ꑍ'", "yyyy'ꈎ' M'ꆪ'" } },
+                       { 0x047a, new [] { "-", "dddd, dd' de 'MMMM' de 'yyyy", "H:mm:ss", "dd-MM-yyyy", "H:mm", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x047c, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x047e, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0480, new [] { "-", "yyyy-'يىلى' MMMM d-'كۈنى،'", "H:mm:ss", "yyyy-M-d", "H:mm", "MMMM d'-كۈنى'", "yyyy-'يىلى' MMMM" } },
+                       { 0x0481, new [] { "/", "dddd, dd MMMM, yyyy", "h:mm:ss tt", "dd/MM/yyyy", "h:mm tt", "dd MMMM", "MMMM, yy" } },
+                       { 0x0482, new [] { "/", "dddd,' lo 'd MMMM' de 'yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0483, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0484, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0485, new [] { ".", "MMMM d yyyy 'с.'", "H:mm:ss", "MM.dd.yyyy", "H:mm", "MMMM dd", "MMMM yyyy 'с.'" } },
+                       { 0x0486, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x0487, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x0488, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x048c, new [] { "/", "dd/MM/yyyy", "h:mm:ss tt", "dd/MM/yy", "h:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0491, new [] { "/", "dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0801, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0804, new [] { "/", "yyyy'年'M'月'd'日'", "H:mm:ss", "yyyy/M/d", "H:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x0807, new [] { ".", "dddd, d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0809, new [] { "/", "dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x080a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x080c, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "d/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x0810, new [] { ".", "dddd, d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0813, new [] { "/", "dddd d MMMM yyyy", "H:mm:ss", "d/MM/yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0814, new [] { ".", "d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0816, new [] { "-", "dddd, d' de 'MMMM' de 'yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "d/M", "MMMM' de 'yyyy" } },
+                       { 0x081a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x081d, new [] { ".", "'den 'd MMMM yyyy", "HH:mm:ss", "d.M.yyyy", "HH:mm", "'den 'd MMMM", "MMMM yyyy" } },
+                       { 0x082c, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x082e, new [] { ". ", "dddd, 'dnja' d. MMMM yyyy", "H:mm:ss", "d. M. yyyy", "H.mm 'goź.'", "d. MMMM", "MMMM yyyy" } },
+                       { 0x083b, new [] { "-", "MMMM d'. b. 'yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x083c, new [] { "/", "d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x083e, new [] { "/", "dd MMMM yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0843, new [] { ".", "yyyy 'йил' d-MMMM", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d-MMMM", "MMMM yyyy" } },
+                       { 0x0845, new [] { "-", "dd MMMM yyyy", "HH.mm.ss", "dd-MM-yy", "HH.mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0850, new [] { "/", "yyyy'ᠣᠨ ᠤ᠋' M'ᠰᠠᠷ᠎ᠠ  ᠢᠢᠨ 'd' ᠤ᠋ ᠡᠳᠦᠷ'", "H:mm:ss", "yyyy/M/d", "H:mm", "M'ᠰᠠᠷ᠎ᠠ' d'ᠡᠳᠦᠷ'", "yyyy'ᠣᠨ' M'ᠰᠠᠷ᠎ᠠ'" } },
+                       { 0x085d, new [] { "/", "ddd, MMMM dd,yyyy", "h:mm:ss tt", "d/MM/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x085f, new [] { "-", "dd MMMM, yyyy", "H:mm:ss", "dd-MM-yyyy", "H:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x086b, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "MMMM dd", "MMMM' de 'yyyy" } },
+                       { 0x0c01, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x0c04, new [] { "/", "yyyy'年'M'月'd'日'", "H:mm:ss", "d/M/yyyy", "H:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x0c07, new [] { ".", "dddd, dd. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0c09, new [] { "/", "dddd, d MMMM yyyy", "h:mm:ss tt", "d/MM/yyyy", "h:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x0c0a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x0c0c, new [] { "-", "d MMMM yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "d MMMM", "MMMM, yyyy" } },
+                       { 0x0c1a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x0c3b, new [] { ".", "MMMM d'. b. 'yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x0c6b, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "MMMM dd", "MMMM' de 'yyyy" } },
+                       { 0x1001, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x1004, new [] { "/", "yyyy'年'M'月'd'日'", "tt h:mm:ss", "d/M/yyyy", "tt h:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x1007, new [] { ".", "dddd, d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x1009, new [] { "/", "MMMM-dd-yy", "h:mm:ss tt", "dd/MM/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x100a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x100c, new [] { ".", "dddd d MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x101a, new [] { ".", "d. MMMM yyyy.", "H:mm:ss", "d.M.yyyy.", "H:mm", "d. MMMM", "MMMM, yyyy" } },
+                       { 0x103b, new [] { ".", "MMMM d'. b. 'yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x1401, new [] { "-", "dd MMMM, yyyy", "H:mm:ss", "dd-MM-yyyy", "H:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x1404, new [] { "/", "yyyy'年'M'月'd'日'", "H:mm:ss", "d/M/yyyy", "H:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x1407, new [] { ".", "dddd, d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x1409, new [] { "/", "dddd, d MMMM yyyy", "h:mm:ss tt", "d/MM/yyyy", "h:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x140a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x140c, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x141a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x143b, new [] { "-", "MMMM d'. b. 'yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x1801, new [] { "-", "dd MMMM, yyyy", "H:mm:ss", "dd-MM-yyyy", "H:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x1809, new [] { "/", "dd MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "dd MMMM", "MMMM yyyy" } },
+                       { 0x180a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "MM/dd/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x180c, new [] { "/", "dddd d MMMM yyyy", "HH:mm:ss", "dd/MM/yyyy", "HH:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x181a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x183b, new [] { ".", "MMMM d'. b. 'yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x1c01, new [] { "-", "dd MMMM, yyyy", "H:mm:ss", "dd-MM-yyyy", "H:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x1c09, new [] { "/", "dd MMMM yyyy", "hh:mm:ss tt", "yyyy/MM/dd", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x1c0a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x1c1a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM, yyyy" } },
+                       { 0x1c3b, new [] { "-", "MMMM d'. b. 'yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x2001, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x2009, new [] { "/", "dddd, MMMM dd, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x200a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x201a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM, yyyy" } },
+                       { 0x203b, new [] { ".", "MMMM d'. p. 'yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "MMMM d'. p. '", "MMMM yyyy" } },
+                       { 0x2401, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x2409, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "MM/dd/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x240a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x241a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x243b, new [] { ".", "MMMM d'. p. 'yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "MMMM d'. p. '", "MMMM yyyy" } },
+                       { 0x2801, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x2809, new [] { "/", "dddd, dd MMMM yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x280a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x281a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x2c01, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x2c09, new [] { "/", "dddd, dd MMMM yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM yyyy" } },
+                       { 0x2c0a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x2c1a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x3001, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x3009, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x300a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "H:mm:ss", "dd/MM/yyyy", "H:mm", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x301a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x3401, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x3409, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x340a, new [] { "-", "dddd, dd' de 'MMMM' de 'yyyy", "H:mm:ss", "dd-MM-yyyy", "H:mm", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x3801, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x380a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x3c01, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x3c0a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x4001, new [] { "/", "dd MMMM, yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x4009, new [] { "-", "dd MMMM yyyy", "HH:mm:ss", "dd-MM-yyyy", "HH:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x400a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x4409, new [] { "/", "dddd, d MMMM, yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "d MMMM", "MMMM, yyyy" } },
+                       { 0x440a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x4809, new [] { "/", "dddd, d MMMM, yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "d MMMM", "MMMM, yyyy" } },
+                       { 0x480a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x4c0a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x500a, new [] { "/", "dddd, dd' de 'MMMM' de 'yyyy", "hh:mm:ss tt", "dd/MM/yyyy", "hh:mm tt", "dd MMMM", "MMMM' de 'yyyy" } },
+                       { 0x540a, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "M/d/yyyy", "h:mm tt", "dd' de 'MMMM", "MMMM' de 'yyyy" } },
+                       { 0x641a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM, yyyy" } },
+                       { 0x681a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x6c1a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x701a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x703b, new [] { ".", "MMMM d'. p. 'yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "MMMM d'. p. '", "MMMM yyyy" } },
+                       { 0x742c, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x743b, new [] { ".", "MMMM d'. p. 'yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "MMMM d'. p. '", "MMMM yyyy" } },
+                       { 0x7804, new [] { "/", "yyyy'年'M'月'd'日'", "H:mm:ss", "yyyy/M/d", "H:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x7814, new [] { ".", "d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x781a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x782c, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yyyy", "H:mm", "d MMMM", "MMMM yyyy" } },
+                       { 0x783b, new [] { "-", "MMMM d'. b. 'yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x7843, new [] { ".", "yyyy 'йил' d-MMMM", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d-MMMM", "MMMM yyyy" } },
+                       { 0x7850, new [] { ".", "yyyy 'оны' MMMM d", "H:mm:ss", "yy.MM.dd", "H:mm", "d MMMM", "yyyy 'он' MMMM" } },
+                       { 0x785d, new [] { "/", "dddd,MMMM dd,yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM dd", "MMMM,yyyy" } },
+                       { 0x7c04, new [] { "/", "yyyy'年'M'月'd'日'", "H:mm:ss", "d/M/yyyy", "H:mm", "M'月'd'日'", "yyyy'年'M'月'" } },
+                       { 0x7c14, new [] { ".", "d. MMMM yyyy", "HH:mm:ss", "dd.MM.yyyy", "HH:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x7c1a, new [] { ".", "d. MMMM yyyy", "H:mm:ss", "d.M.yyyy", "H:mm", "d. MMMM", "MMMM yyyy" } },
+                       { 0x7c28, new [] { ".", "d MMMM yyyy", "H:mm:ss", "dd.MM.yy", "H:mm", "MMMM dd", "MMMM yyyy" } },
+                       { 0x7c2e, new [] { ". ", "dddd, 'dnja' d. MMMM yyyy", "H:mm:ss", "d. M. yyyy", "H.mm 'goź.'", "d. MMMM", "MMMM yyyy" } },
+                       { 0x7c3b, new [] { "-", "MMMM d'. b. 'yyyy", "HH:mm:ss", "yyyy-MM-dd", "HH:mm", "MMMM d'. b. '", "MMMM yyyy" } },
+                       { 0x7c43, new [] { "/", "yyyy 'yil' d-MMMM", "HH:mm:ss", "dd/MM yyyy", "HH:mm", "d-MMMM", "MMMM yyyy" } },
+                       { 0x7c50, new [] { "/", "yyyy'ᠣᠨ ᠤ᠋' M'ᠰᠠᠷ᠎ᠠ  ᠢᠢᠨ 'd' ᠤ᠋ ᠡᠳᠦᠷ'", "H:mm:ss", "yyyy/M/d", "H:mm", "M'ᠰᠠᠷ᠎ᠠ' d'ᠡᠳᠦᠷ'", "yyyy'ᠣᠨ' M'ᠰᠠᠷ᠎ᠠ'" } },
+                       { 0x7c5d, new [] { "/", "ddd, MMMM dd,yyyy", "h:mm:ss tt", "d/MM/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } },
+                       { 0x7c5f, new [] { "-", "dd MMMM, yyyy", "H:mm:ss", "dd-MM-yyyy", "H:mm", "dd MMMM", "MMMM, yyyy" } },
+                       { 0x7c68, new [] { "/", "dddd, MMMM dd, yyyy", "h:mm:ss tt", "d/M/yyyy", "h:mm tt", "MMMM dd", "MMMM, yyyy" } }
+               };
+
+               static readonly Dictionary<int, string[][]> DateTime2 = new Dictionary<int, string[][]> {
+                       { 0x0001, new[] { new[] { "dd/MM/yy", "dd/MM/yyyy" }, new[] { "dd/MMMM/yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0002, new[] { new[] { "d.M.yyyy 'г.'", "dd.M.yyyy 'г.'", "d.MM.yyyy 'г.'", "dd.MM.yyyy 'г.'" }, new[] { "dd MMMM yyyy 'г.'", "d MMMM yyyy 'г.'", "dddd, dd MMMM yyyy 'г.'", "dddd, d MMMM yyyy 'г.'" }, new[] { "HH:mm 'ч.'", "H:mm 'ч.'" }, new[] { "HH:mm:ss 'ч.'", "H:mm:ss 'ч.'" } } },
+                       { 0x0003, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd", "d/MM/yy", "d/M/yy", "dd-MM-yy", "dd.MM.yy" }, new[] { "dddd, d' / 'MMMM' / 'yyyy", "d'/'MMMM'/'yyyy", "d' 'MMMM' 'yyyy" }, new[] { "HH:mm", "H:mm", "HH'H'mm'\''" }, new[] { "HH:mm:ss", "H:mm:ss", "HH'H'mm'\''ss'\'\''" } } },
+                       { 0x0004, new[] { new[] { "yyyy/M/d", "yyyy-M-d", "yyyy.M.d", "yyyy-MM-dd", "yyyy/MM/dd", "yyyy.MM.dd", "yy-M-d", "yy/M/d", "yy.M.d", "yy/MM/dd" }, new[] { "yyyy'年'M'月'd'日'", "yyyy'年'M'月'd'日',dddd", "dddd,yyyy'年'M'月'd'日'" }, new[] { "H:mm", "HH:mm", "tt h:mm", "tt hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss", "tt h:mm:ss", "tt hh:mm:ss" } } },
+                       { 0x0005, new[] { new[] { "d.M.yyyy", "d-M-yy", "yyyy-MM-dd", "yyyy-M-d", "yy-M-d" }, new[] { "d. MMMM yyyy" }, new[] { "H:mm", "HH:mm", "h.mm tt", "H.mm" }, new[] { "H:mm:ss", "HH:mm:ss", "h.mm.ss tt", "H.mm.ss" } } },
+                       { 0x0006, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd", "yyyy MM dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0007, new[] { new[] { "dd.MM.yyyy", "dd.MMM.yyyy", "dd.MM.yy", "d.MM.yy", "d.M.yy", "d.M.yyyy", "yyyy-MM-dd" }, new[] { "dddd, d. MMMM yyyy", "d. MMMM yyyy", "d. MMM yyyy" }, new[] { "HH:mm", "H:mm", "H.mm", "H.mm' Uhr'" }, new[] { "HH:mm:ss", "H:mm:ss' Uhr'", "HH:mm:ss' Uhr'", "HHmmss" } } },
+                       { 0x0008, new[] { new[] { "d/M/yyyy", "dd/MM/yyyy", "d/M/yy", "dd/MM/yy", "dd/MMM/yyyy", "yyyy-MM-dd" }, new[] { "dddd, d MMMM yyyy", "d MMMM yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0009, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x000a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yy", "d/M/yy", "dd-MM-yy", "dd.MM.yy", "yyyy-MM-dd", "dd.MMM.yyyy" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "H:mm", "HH:mm", "HH'H'mm'\''" }, new[] { "H:mm:ss", "HH:mm:ss", "HH'H'mm'\''ss'\'\''" } } },
+                       { 0x000b, new[] { new[] { "d.M.yyyy", "dd.MM.yyyy", "d.M.yy", "yyyy-MM-dd" }, new[] { "d. MMMM'ta 'yyyy", "dd. MMMM'ta 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x000c, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x000d, new[] { new[] { "dd/MM/yyyy", "dd MMMM yyyy", "dd/MM/yy", "dd/MMMM/yyyy", "dd-MM-yy", "dd-MM-yyyy", "dd-MMMM-yyyy", "yyyy-MM-dd", "dd 'ב'MMMM yyyy", "dd MMM yy" }, new[] { "dddd dd MMMM yyyy", "dd MMMM yyyy", "dddd dd 'ב'MMMM yyyy", "ddd dd 'ב'MMMM yyyy", "dd 'ב'MMMM yyyy" }, new[] { "HH:mm", "hh:mm tt" }, new[] { "HH:mm:ss", "hh:mm:ss tt" } } },
+                       { 0x000e, new[] { new[] { "yyyy.MM.dd.", "yyyy. MM. dd.", "yyyy-MM-dd", "yy-MM-dd" }, new[] { "yyyy. MMMM d." }, new[] { "H:mm", "HH:mm", "h:mm tt" }, new[] { "H:mm:ss", "HH:mm:ss", "h:mm:ss tt" } } },
+                       { 0x000f, new[] { new[] { "d.M.yyyy", "dd.MM.yy", "d. M. yyyy.", "d. M. '\''yy.", "yyyy-MM-dd", "yy MM dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0010, new[] { new[] { "dd/MM/yyyy", "dd/MMM/yyyy", "dd/MM/yy", "dd.M.yy", "d/M/yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d-MMM-yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "H.mm", "HH.mm" }, new[] { "HH:mm:ss", "H.mm.ss", "HH.mm.ss" } } },
+                       { 0x0011, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yy/M/d", "yyyy/M/d", "yy/MM/dd' ('ddd')'", "yy/M/d' ('ddd')'", "yyyy/MM/dd' ('ddd')'", "yyyy-MM-dd" }, new[] { "yyyy'年'M'月'd'日'", "yyyy'年'MM'月'dd'日'", "yyyy'年'M'月'd'日' dddd", "yyyy'年'MM'月'dd'日' dddd" }, new[] { "H:mm", "HH:mm", "tt h:mm", "tt hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss", "tt h:mm:ss", "tt hh:mm:ss" } } },
+                       { 0x0012, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd", "yy-M-d", "yyyy-M-d" }, new[] { "yyyy'년' M'월' d'일' dddd", "yyyy'년' M'월' d'일'", "yy'년' M'월' d'일' dddd", "yy'년' M'월' d'일'", "yyyy'년' MM'월' dd'일' dddd", "yyyy'년' MM'월' dd'일'" }, new[] { "tt h:mm", "tt hh:mm", "H:mm", "HH:mm" }, new[] { "tt h:mm:ss", "tt hh:mm:ss", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0013, new[] { new[] { "d-M-yyyy", "d-M-yy", "dd-MM-yy", "dd/MM/yy", "dd.MM.yy", "dd.MMM.yyyy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d-MMM-yy", "d MMMM yyyy", "d MMM yy" }, new[] { "H:mm", "HH:mm", "H.mm", "HH.mm' uur'", "HH:mm' uur'" }, new[] { "H:mm:ss", "HH:mm:ss", "HH.mm.ss' uur'", "HH:mm:ss' uur'" } } },
+                       { 0x0014, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "yyyy-MM-dd", "dd.MMM.yyyy" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm", "'kl 'HH.mm", "HH.mm" }, new[] { "HH:mm:ss", "H:mm:ss", "'kl 'HH.mm.ss", "HH.mm.ss" } } },
+                       { 0x0015, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0016, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yyyy", "d/M/yy", "dd-MM-yy", "dd-MM-yyyy", "d-M-yy", "d-M-yyyy", "dd.MM.yy", "dd.MM.yyyy", "dd.MMM.yyyy", "d.M.yy", "d.M.yyyy", "yyyy-MM-dd" }, new[] { "dddd, d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0017, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yy", "dd/M/yy", "d/M/yy", "dd/MM/yyyy", "yyyy-MM-dd" }, new[] { "dddd, d MMMM yyyy", "d MMMM yyyy", "d MMM yy" }, new[] { "HH:mm", "H:mm", "HH:mm' Ura'", "H:mm' Ura'", "H' Ura'", "HH.mm' h'", "H.mm' h'", "H' h'", "H.mm' Uhr'", "H' Uhr'", "HHmm", "HH" }, new[] { "HH:mm:ss", "H:mm:ss", "HH:mm:ss' Ura'", "H:mm:ss' Ura'", "HH:mm:ss' Uhr'", "H:mm:ss' Uhr'", "HH:mm:ss' h'", "H:mm:ss' h'", "HHmmss" } } },
+                       { 0x0018, new[] { new[] { "dd.MM.yyyy", "d.M.yyyy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0019, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy 'г.'", "dd MMMM yyyy 'г.'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x001a, new[] { new[] { "d.M.yyyy.", "d.M.yy.", "d. M. yyyy.", "dd.MM.yyyy.", "d. M. yy.", "dd.MM.yy.", "dd. MM. yy.", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy.", "dd. MMMM yyyy.", "dddd, d. MMMM yyyy." }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x001b, new[] { new[] { "d. M. yyyy", "d.M.yyyy", "d. M. yy", "d.M.yy", "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "H:mm", "HH:mm", "H.mm" }, new[] { "H:mm:ss", "HH:mm:ss", "H.mm.ss" } } },
+                       { 0x001c, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "yyyy-MM-dd" }, new[] { "h:mm.tt", "HH:mm" }, new[] { "h:mm:ss.tt", "HH:mm:ss" } } },
+                       { 0x001d, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "'den 'd MMMM yyyy", "dddd' den 'd MMMM yyyy" }, new[] { "HH:mm", "H:mm", "'kl 'H:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "'kl 'H:mm:ss" } } },
+                       { 0x001e, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "dd/MM/yyyy", "d MMM yyyy", "dd MMM yyyy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "ddd d MMMM yyyy", "'วัน'dddd'ที่' d MMMM gg yyyy" }, new[] { "H:mm", "HH:mm", "h:mm tt", "hh:mm tt" }, new[] { "H:mm:ss", "HH:mm:ss", "h:mm:ss tt", "hh:mm:ss tt" } } },
+                       { 0x001f, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy dddd", "dd MMMM yyyy" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0020, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0021, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0022, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy' р.'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0023, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0024, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0025, new[] { new[] { "d.MM.yyyy", "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy'. a.'", "dd. MMMM yyyy'. a.'", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0026, new[] { new[] { "yyyy.MM.dd.", "yy.MM.dd.", "yyyy-MM-dd" }, new[] { "dddd, yyyy'. gada 'd. MMMM" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0027, new[] { new[] { "yyyy.MM.dd", "yyyy-MM-dd" }, new[] { "yyyy 'm.' MMMM d 'd.'" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0028, new[] { new[] { "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x0029, new[] { new[] { "MM/dd/yyyy", "MM/dd/yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x002a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd-MM-yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x002b, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d/MM/yyyy", "dd/MM/yyyy", "d/MMM/yyyy", "dd/MMM/yyyy", "yyyy-MM-dd" }, new[] { "d MMMM, yyyy", "dddd, d MMMM yyyy", "dddd, dd MMMM yyyy", "dd MMMM yyyy", "d-MMM-yyyy", "dd-MMM-yyyy", "ddd, d-MMMM-yyyy", "ddd, dd-MMMM-yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x002c, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x002d, new[] { new[] { "yyyy/MM/dd", "yyyy-MM-dd" }, new[] { "dddd, yyyy.'eko' MMMM'k 'd" }, new[] { "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss", "HH'H'mm'\''ss'\'\''" } } },
+                       { 0x002e, new[] { new[] { "d. M. yyyy", "d. M. yy", "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, 'dnja' d. MMMM yyyy", "dddd, d. MMMM yyyy", "d. MMMM yyyy", "d. M. yyyy" }, new[] { "H.mm 'hodź.'", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x002f, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, dd MMMM yyyy" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0032, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0034, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0035, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0036, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd", "yyyy/MMM/dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0037, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "yyyy 'წლის' dd MM, dddd" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0038, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy" }, new[] { "HH:mm", "HH.mm" }, new[] { "HH:mm:ss", "HH.mm.ss" } } },
+                       { 0x0039, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x003a, new[] { new[] { "dd/MM/yyyy", "yyyy-MM-dd", "ddMMyyyy", "d-M-yyyy", "d/M/yyyy" }, new[] { "dddd, d' ta\' 'MMMM yyyy", "d' ta\' 'MMMM yyyy", "dd MMM yyyy" }, new[] { "HH:mm", "h:mm tt", "H:mm", "hh:mm tt" }, new[] { "HH:mm:ss", "h:mm:ss tt", "H:mm:ss", "hh:mm:ss tt" } } },
+                       { 0x003b, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm" }, new[] { "HH:mm:ss", "H:mm:ss", "HH.mm.ss" } } },
+                       { 0x003c, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy", "dd MMM yyyy", "d MMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x003e, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x003f, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy 'ж.'", "dd MMMM yyyy 'ж.'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0040, new[] { new[] { "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d'-'MMMM yyyy'-ж.'" }, new[] { "H:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x0041, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0042, new[] { new[] { "dd.MM.yy", "yyyy-MM-dd" }, new[] { "yyyy 'ý.' MMMM d", "yyyy 'ý.' MMMM dd" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0043, new[] { new[] { "dd/MM yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "yyyy 'yil' d-MMMM", "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0044, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0045, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH.mm", "H.mm", "tt hh.mm", "tt h.mm" }, new[] { "HH.mm.ss", "H.mm.ss", "tt hh.mm.ss", "tt h.mm.ss" } } },
+                       { 0x0046, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy dddd", "d MMMM yyyy" }, new[] { "tt hh:mm", "tt h:mm", "H:mm", "HH:mm" }, new[] { "tt hh:mm:ss", "tt h:mm:ss", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0047, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x0048, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x0049, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x004a, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x004b, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x004c, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH.mm", "H.mm", "tt hh.mm", "tt h.mm" }, new[] { "HH.mm.ss", "H.mm.ss", "tt hh.mm.ss", "tt h.mm.ss" } } },
+                       { 0x004d, new[] { new[] { "dd-MM-yyyy" }, new[] { "yyyy,MMMM dd, dddd" }, new[] { "tt h:mm", "tt hh:mm" }, new[] { "tt h:mm:ss", "tt hh:mm:ss" } } },
+                       { 0x004e, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x004f, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy dddd", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x0050, new[] { new[] { "yy.MM.dd", "yyyy-MM-dd" }, new[] { "yyyy 'оны' MMMM d" }, new[] { "H:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x0051, new[] { new[] { "yyyy/M/d", "yyyy-M-d", "yyyy.M.d", "yyyy.MM.dd", "yyyy-MM-dd", "yyyy/MM/dd", "yy-M-d", "yy/M/d", "yy.M.d" }, new[] { "yyyy'ལོའི་ཟླ' M'ཚེས' d", "yyyy'ལོའི་ཟླ' M'ཚེས' d dddd" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0052, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "hh:mm tt", "h:mm tt" }, new[] { "HH:mm:ss", "H:mm:ss", "hh:mm:ss tt", "h:mm:ss tt" } } },
+                       { 0x0053, new[] { new[] { "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "ddd d MMMM yyyy" }, new[] { "H:mm tt" }, new[] { "HH:mm:ss" } } },
+                       { 0x0054, new[] { new[] { "dd/MM/yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "H:mm tt" }, new[] { "HH:mm:ss" } } },
+                       { 0x0056, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yy", "d/M/yy", "dd-MM-yy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "H:mm", "HH:mm", "hh:mm tt", "HH'H'mm'\''" }, new[] { "H:mm:ss", "HH:mm:ss", "hh:mm:ss tt", "HH'H'mm'\''ss'\'\''" } } },
+                       { 0x0057, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x005a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x005b, new[] { new[] { "yyyy-MM-dd", "yyyy/MM/dd", "yy/MM/dd", "dd/MM/yyyy", "dd/MM/yy" }, new[] { "yyyy MMMM' මස 'dd' වැනිදා 'dddd" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x005d, new[] { new[] { "d/MM/yyyy", "d/M/yy", "yy-MM-dd", "dd/MM/yyyy", "yy-MM-dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "ddd, MMMM dd,yyyy", "MMMM dd,yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "HH:mm", "H:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x005e, new[] { new[] { "d/M/yyyy", "yyyy-MM-dd" }, new[] { "dddd '፣' MMMM d 'ቀን' yyyy" }, new[] { "h:mm tt" }, new[] { "h:mm:ss tt" } } },
+                       { 0x005f, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "H:mm", "HH:mm", "hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0061, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0062, new[] { new[] { "d-M-yyyy", "d-M-yy", "dd-MM-yy", "dd/MM/yy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d-MMM-yy", "d MMMM yyyy", "d MMM yy" }, new[] { "H:mm", "HH:mm", "H:mm", "H.mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0063, new[] { new[] { "dd/MM/yy", "dd/MM/yyyy" }, new[] { "dd/MM/yyyy", "dd/MMMM/yyyy", "dddd, dd MMMM, yyyy", "dd/MM/yyyy 'هـ'" }, new[] { "h:mm tt", "H:mm" }, new[] { "h:mm:ss tt", "H:mm:ss" } } },
+                       { 0x0064, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0065, new[] { new[] { "dd/MM/yy", "dd/MM/yyyy" }, new[] { "dd/MM/yyyy", "dd/MMMM/yyyy", "dddd, dd MMMM, yyyy", "dd/MM/yyyy 'هـ'" }, new[] { "HH:mm", "hh:mm tt" }, new[] { "HH:mm:ss", "hh:mm:ss tt" } } },
+                       { 0x0068, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "dd/MM/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x006a, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "dd/MM/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x006b, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x006c, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x006d, new[] { new[] { "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy 'й'" }, new[] { "H:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x006e, new[] { new[] { "dd/MM/yyyy", " dd/MM/yy", "dd.MM.yy", "dd/MM/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "H.mm", "H.mm' Auer'" }, new[] { "HH:mm:ss", "H:mm:ss' Auer'", "HH:mm:ss' Auer'", "HHmmss" } } },
+                       { 0x006f, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd", "yyyy MM dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0070, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "dd/MM/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0078, new[] { new[] { "yyyy/M/d", "yyyy-M-d", "yyyy.M.d", "yyyy.MM.dd", "yyyy-MM-dd", "yyyy/MM/dd" }, new[] { "yyyy'ꈎ' M'ꆪ' d'ꑍ'", "dddd, yyyy'ꈎ' M'ꆪ' d'ꑍ'", "yyyy'ꈎ' M'ꆪ' d'ꑍ', dddd" }, new[] { "tt h:mm", "H:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x007a, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "dd/MM/yy", "d/M/yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x007c, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "HH:mm", "H:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x007e, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0080, new[] { new[] { "yyyy-M-d", "yyyy.M.d", "yyyy-MM-dd", "yyyy.MM.dd" }, new[] { "yyyy-'يىلى' MMMM d-'كۈنى،'", "yyyy-'يىلى' MMMM d-'كۈنى،' dddd" }, new[] { "H:mm", "HH:mm", "tt h:mm", "tt hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss", "tt h:mm:ss", "tt hh:mm:ss" } } },
+                       { 0x0081, new[] { new[] { "dd/MM/yyyy", "d/MM/yy", "dd/MM/yy", "d.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, dd MMMM, yyyy", "d MMMM yyyy" }, new[] { "h:mm tt", "hh:mm tt", "HH:mm", "H:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0082, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd,' lo 'd MMMM' de 'yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0083, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0084, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0085, new[] { new[] { "MM.dd.yyyy", "MM.dd.yy", "d.M.yy", "MM/dd/yy", "MM-dd-yyyy" }, new[] { "MMMM d yyyy 'с.'", "MMMM dd yyyy 'с.'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0086, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yyyy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0087, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0088, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x008c, new[] { new[] { "dd/MM/yy", "dd/MM/yyyy" }, new[] { "dd/MM/yyyy", "dd/MMMM/yyyy", "dddd, dd MMMM, yyyy", "dd/MM/yyyy 'هـ'" }, new[] { "h:mm tt", "H:mm" }, new[] { "h:mm:ss tt", "H:mm:ss" } } },
+                       { 0x0091, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "hh:mm tt", "h:mm tt" }, new[] { "HH:mm:ss", "H:mm:ss", "hh:mm:ss tt", "h:mm:ss tt" } } },
+                       { 0x0401, new[] { new[] { "dd/MM/yy", "dd/MM/yyyy" }, new[] { "dd/MMMM/yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0402, new[] { new[] { "d.M.yyyy 'г.'", "dd.M.yyyy 'г.'", "d.MM.yyyy 'г.'", "dd.MM.yyyy 'г.'" }, new[] { "dd MMMM yyyy 'г.'", "d MMMM yyyy 'г.'", "dddd, dd MMMM yyyy 'г.'", "dddd, d MMMM yyyy 'г.'" }, new[] { "HH:mm 'ч.'", "H:mm 'ч.'" }, new[] { "HH:mm:ss 'ч.'", "H:mm:ss 'ч.'" } } },
+                       { 0x0403, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd", "d/MM/yy", "d/M/yy", "dd-MM-yy", "dd.MM.yy" }, new[] { "dddd, d' / 'MMMM' / 'yyyy", "d'/'MMMM'/'yyyy", "d' 'MMMM' 'yyyy" }, new[] { "HH:mm", "H:mm", "HH'H'mm'\''" }, new[] { "HH:mm:ss", "H:mm:ss", "HH'H'mm'\''ss'\'\''" } } },
+                       { 0x0404, new[] { new[] { "yyyy/M/d", "yyyy/MM/dd", "yyyy-MM-dd" }, new[] { "yyyy'年'M'月'd'日'", "yyyy'年'MM'月'dd'日'" }, new[] { "tt hh:mm", "tt h:mm", "HH:mm", "H:mm" }, new[] { "tt hh:mm:ss", "tt h:mm:ss", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0405, new[] { new[] { "d.M.yyyy", "d-M-yy", "yyyy-MM-dd", "yyyy-M-d", "yy-M-d" }, new[] { "d. MMMM yyyy" }, new[] { "H:mm", "HH:mm", "h.mm tt", "H.mm" }, new[] { "H:mm:ss", "HH:mm:ss", "h.mm.ss tt", "H.mm.ss" } } },
+                       { 0x0406, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd", "yyyy MM dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0407, new[] { new[] { "dd.MM.yyyy", "dd.MMM.yyyy", "dd.MM.yy", "d.MM.yy", "d.M.yy", "d.M.yyyy", "yyyy-MM-dd" }, new[] { "dddd, d. MMMM yyyy", "d. MMMM yyyy", "d. MMM yyyy" }, new[] { "HH:mm", "H:mm", "H.mm", "H.mm' Uhr'" }, new[] { "HH:mm:ss", "H:mm:ss' Uhr'", "HH:mm:ss' Uhr'", "HHmmss" } } },
+                       { 0x0408, new[] { new[] { "d/M/yyyy", "dd/MM/yyyy", "d/M/yy", "dd/MM/yy", "dd/MMM/yyyy", "yyyy-MM-dd" }, new[] { "dddd, d MMMM yyyy", "d MMMM yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0409, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x040b, new[] { new[] { "d.M.yyyy", "dd.MM.yyyy", "d.M.yy", "yyyy-MM-dd" }, new[] { "d. MMMM'ta 'yyyy", "dd. MMMM'ta 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x040c, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x040d, new[] { new[] { "dd/MM/yyyy", "dd MMMM yyyy", "dd/MM/yy", "dd/MMMM/yyyy", "dd-MM-yy", "dd-MM-yyyy", "dd-MMMM-yyyy", "yyyy-MM-dd", "dd 'ב'MMMM yyyy", "dd MMM yy" }, new[] { "dddd dd MMMM yyyy", "dd MMMM yyyy", "dddd dd 'ב'MMMM yyyy", "ddd dd 'ב'MMMM yyyy", "dd 'ב'MMMM yyyy" }, new[] { "HH:mm", "hh:mm tt" }, new[] { "HH:mm:ss", "hh:mm:ss tt" } } },
+                       { 0x040e, new[] { new[] { "yyyy.MM.dd.", "yyyy. MM. dd.", "yyyy-MM-dd", "yy-MM-dd" }, new[] { "yyyy. MMMM d." }, new[] { "H:mm", "HH:mm", "h:mm tt" }, new[] { "H:mm:ss", "HH:mm:ss", "h:mm:ss tt" } } },
+                       { 0x040f, new[] { new[] { "d.M.yyyy", "dd.MM.yy", "d. M. yyyy.", "d. M. '\''yy.", "yyyy-MM-dd", "yy MM dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0410, new[] { new[] { "dd/MM/yyyy", "dd/MMM/yyyy", "dd/MM/yy", "dd.M.yy", "d/M/yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d-MMM-yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "H.mm", "HH.mm" }, new[] { "HH:mm:ss", "H.mm.ss", "HH.mm.ss" } } },
+                       { 0x0411, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yy/M/d", "yyyy/M/d", "yy/MM/dd' ('ddd')'", "yy/M/d' ('ddd')'", "yyyy/MM/dd' ('ddd')'", "yyyy-MM-dd" }, new[] { "yyyy'年'M'月'd'日'", "yyyy'年'MM'月'dd'日'", "yyyy'年'M'月'd'日' dddd", "yyyy'年'MM'月'dd'日' dddd" }, new[] { "H:mm", "HH:mm", "tt h:mm", "tt hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss", "tt h:mm:ss", "tt hh:mm:ss" } } },
+                       { 0x0412, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd", "yy-M-d", "yyyy-M-d" }, new[] { "yyyy'년' M'월' d'일' dddd", "yyyy'년' M'월' d'일'", "yy'년' M'월' d'일' dddd", "yy'년' M'월' d'일'", "yyyy'년' MM'월' dd'일' dddd", "yyyy'년' MM'월' dd'일'" }, new[] { "tt h:mm", "tt hh:mm", "H:mm", "HH:mm" }, new[] { "tt h:mm:ss", "tt hh:mm:ss", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0413, new[] { new[] { "d-M-yyyy", "d-M-yy", "dd-MM-yy", "dd/MM/yy", "dd.MM.yy", "dd.MMM.yyyy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d-MMM-yy", "d MMMM yyyy", "d MMM yy" }, new[] { "H:mm", "HH:mm", "H.mm", "HH.mm' uur'", "HH:mm' uur'" }, new[] { "H:mm:ss", "HH:mm:ss", "HH.mm.ss' uur'", "HH:mm:ss' uur'" } } },
+                       { 0x0414, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "yyyy-MM-dd", "dd.MMM.yyyy" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm", "'kl 'HH.mm", "HH.mm" }, new[] { "HH:mm:ss", "H:mm:ss", "'kl 'HH.mm.ss", "HH.mm.ss" } } },
+                       { 0x0415, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0416, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yyyy", "d/M/yy", "dd-MM-yy", "dd-MM-yyyy", "d-M-yy", "d-M-yyyy", "dd.MM.yy", "dd.MM.yyyy", "dd.MMM.yyyy", "d.M.yy", "d.M.yyyy", "yyyy-MM-dd" }, new[] { "dddd, d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0417, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yy", "dd/M/yy", "d/M/yy", "dd/MM/yyyy", "yyyy-MM-dd" }, new[] { "dddd, d MMMM yyyy", "d MMMM yyyy", "d MMM yy" }, new[] { "HH:mm", "H:mm", "HH:mm' Ura'", "H:mm' Ura'", "H' Ura'", "HH.mm' h'", "H.mm' h'", "H' h'", "H.mm' Uhr'", "H' Uhr'", "HHmm", "HH" }, new[] { "HH:mm:ss", "H:mm:ss", "HH:mm:ss' Ura'", "H:mm:ss' Ura'", "HH:mm:ss' Uhr'", "H:mm:ss' Uhr'", "HH:mm:ss' h'", "H:mm:ss' h'", "HHmmss" } } },
+                       { 0x0418, new[] { new[] { "dd.MM.yyyy", "d.M.yyyy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0419, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy 'г.'", "dd MMMM yyyy 'г.'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x041a, new[] { new[] { "d.M.yyyy.", "d.M.yy.", "d. M. yyyy.", "dd.MM.yyyy.", "d. M. yy.", "dd.MM.yy.", "dd. MM. yy.", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy.", "dd. MMMM yyyy.", "dddd, d. MMMM yyyy." }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x041b, new[] { new[] { "d. M. yyyy", "d.M.yyyy", "d. M. yy", "d.M.yy", "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "H:mm", "HH:mm", "H.mm" }, new[] { "H:mm:ss", "HH:mm:ss", "H.mm.ss" } } },
+                       { 0x041c, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "yyyy-MM-dd" }, new[] { "h:mm.tt", "HH:mm" }, new[] { "h:mm:ss.tt", "HH:mm:ss" } } },
+                       { 0x041d, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "'den 'd MMMM yyyy", "dddd' den 'd MMMM yyyy" }, new[] { "HH:mm", "H:mm", "'kl 'H:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "'kl 'H:mm:ss" } } },
+                       { 0x041e, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "dd/MM/yyyy", "d MMM yyyy", "dd MMM yyyy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "ddd d MMMM yyyy", "'วัน'dddd'ที่' d MMMM gg yyyy" }, new[] { "H:mm", "HH:mm", "h:mm tt", "hh:mm tt" }, new[] { "H:mm:ss", "HH:mm:ss", "h:mm:ss tt", "hh:mm:ss tt" } } },
+                       { 0x041f, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy dddd", "dd MMMM yyyy" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0420, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0421, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0422, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy' р.'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0423, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0424, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0425, new[] { new[] { "d.MM.yyyy", "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy'. a.'", "dd. MMMM yyyy'. a.'", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0426, new[] { new[] { "yyyy.MM.dd.", "yy.MM.dd.", "yyyy-MM-dd" }, new[] { "dddd, yyyy'. gada 'd. MMMM" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0427, new[] { new[] { "yyyy.MM.dd", "yyyy-MM-dd" }, new[] { "yyyy 'm.' MMMM d 'd.'" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0428, new[] { new[] { "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x0429, new[] { new[] { "MM/dd/yyyy", "MM/dd/yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x042a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd-MM-yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x042b, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d/MM/yyyy", "dd/MM/yyyy", "d/MMM/yyyy", "dd/MMM/yyyy", "yyyy-MM-dd" }, new[] { "d MMMM, yyyy", "dddd, d MMMM yyyy", "dddd, dd MMMM yyyy", "dd MMMM yyyy", "d-MMM-yyyy", "dd-MMM-yyyy", "ddd, d-MMMM-yyyy", "ddd, dd-MMMM-yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x042c, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x042d, new[] { new[] { "yyyy/MM/dd", "yyyy-MM-dd" }, new[] { "dddd, yyyy.'eko' MMMM'k 'd" }, new[] { "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss", "HH'H'mm'\''ss'\'\''" } } },
+                       { 0x042e, new[] { new[] { "d. M. yyyy", "d. M. yy", "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, 'dnja' d. MMMM yyyy", "dddd, d. MMMM yyyy", "d. MMMM yyyy", "d. M. yyyy" }, new[] { "H.mm 'hodź.'", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x042f, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, dd MMMM yyyy" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0432, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0434, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0435, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0436, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd", "yyyy/MMM/dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0437, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "yyyy 'წლის' dd MM, dddd" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0438, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy" }, new[] { "HH:mm", "HH.mm" }, new[] { "HH:mm:ss", "HH.mm.ss" } } },
+                       { 0x0439, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x043a, new[] { new[] { "dd/MM/yyyy", "yyyy-MM-dd", "ddMMyyyy", "d-M-yyyy", "d/M/yyyy" }, new[] { "dddd, d' ta\' 'MMMM yyyy", "d' ta\' 'MMMM yyyy", "dd MMM yyyy" }, new[] { "HH:mm", "h:mm tt", "H:mm", "hh:mm tt" }, new[] { "HH:mm:ss", "h:mm:ss tt", "H:mm:ss", "hh:mm:ss tt" } } },
+                       { 0x043b, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm" }, new[] { "HH:mm:ss", "H:mm:ss", "HH.mm.ss" } } },
+                       { 0x043e, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x043f, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy 'ж.'", "dd MMMM yyyy 'ж.'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0440, new[] { new[] { "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d'-'MMMM yyyy'-ж.'" }, new[] { "H:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x0441, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0442, new[] { new[] { "dd.MM.yy", "yyyy-MM-dd" }, new[] { "yyyy 'ý.' MMMM d", "yyyy 'ý.' MMMM dd" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0443, new[] { new[] { "dd/MM yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "yyyy 'yil' d-MMMM", "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0444, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0445, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH.mm", "H.mm", "tt hh.mm", "tt h.mm" }, new[] { "HH.mm.ss", "H.mm.ss", "tt hh.mm.ss", "tt h.mm.ss" } } },
+                       { 0x0446, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy dddd", "d MMMM yyyy" }, new[] { "tt hh:mm", "tt h:mm", "H:mm", "HH:mm" }, new[] { "tt hh:mm:ss", "tt h:mm:ss", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0447, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x0448, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x0449, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x044a, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x044b, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x044c, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH.mm", "H.mm", "tt hh.mm", "tt h.mm" }, new[] { "HH.mm.ss", "H.mm.ss", "tt hh.mm.ss", "tt h.mm.ss" } } },
+                       { 0x044d, new[] { new[] { "dd-MM-yyyy" }, new[] { "yyyy,MMMM dd, dddd" }, new[] { "tt h:mm", "tt hh:mm" }, new[] { "tt h:mm:ss", "tt hh:mm:ss" } } },
+                       { 0x044e, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x044f, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy dddd", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x0450, new[] { new[] { "yy.MM.dd", "yyyy-MM-dd" }, new[] { "yyyy 'оны' MMMM d" }, new[] { "H:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x0451, new[] { new[] { "yyyy/M/d", "yyyy-M-d", "yyyy.M.d", "yyyy.MM.dd", "yyyy-MM-dd", "yyyy/MM/dd", "yy-M-d", "yy/M/d", "yy.M.d" }, new[] { "yyyy'ལོའི་ཟླ' M'ཚེས' d", "yyyy'ལོའི་ཟླ' M'ཚེས' d dddd" }, new[] { "HH:mm" }, new[] { "HH:mm:ss" } } },
+                       { 0x0452, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "hh:mm tt", "h:mm tt" }, new[] { "HH:mm:ss", "H:mm:ss", "hh:mm:ss tt", "h:mm:ss tt" } } },
+                       { 0x0453, new[] { new[] { "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "ddd d MMMM yyyy" }, new[] { "H:mm tt" }, new[] { "HH:mm:ss" } } },
+                       { 0x0454, new[] { new[] { "dd/MM/yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "H:mm tt" }, new[] { "HH:mm:ss" } } },
+                       { 0x0456, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yy", "d/M/yy", "dd-MM-yy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "H:mm", "HH:mm", "hh:mm tt", "HH'H'mm'\''" }, new[] { "H:mm:ss", "HH:mm:ss", "hh:mm:ss tt", "HH'H'mm'\''ss'\'\''" } } },
+                       { 0x0457, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm", "tt h:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x045a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x045b, new[] { new[] { "yyyy-MM-dd", "yyyy/MM/dd", "yy/MM/dd", "dd/MM/yyyy", "dd/MM/yy" }, new[] { "yyyy MMMM' මස 'dd' වැනිදා 'dddd" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x045d, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd,MMMM dd,yyyy", "MMMM dd,yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x045e, new[] { new[] { "d/M/yyyy", "yyyy-MM-dd" }, new[] { "dddd '፣' MMMM d 'ቀን' yyyy" }, new[] { "h:mm tt" }, new[] { "h:mm:ss tt" } } },
+                       { 0x0461, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0462, new[] { new[] { "d-M-yyyy", "d-M-yy", "dd-MM-yy", "dd/MM/yy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d-MMM-yy", "d MMMM yyyy", "d MMM yy" }, new[] { "H:mm", "HH:mm", "H:mm", "H.mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0463, new[] { new[] { "dd/MM/yy", "dd/MM/yyyy" }, new[] { "dd/MM/yyyy", "dd/MMMM/yyyy", "dddd, dd MMMM, yyyy", "dd/MM/yyyy 'هـ'" }, new[] { "h:mm tt", "H:mm" }, new[] { "h:mm:ss tt", "H:mm:ss" } } },
+                       { 0x0464, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0465, new[] { new[] { "dd/MM/yy", "dd/MM/yyyy" }, new[] { "dd/MM/yyyy", "dd/MMMM/yyyy", "dddd, dd MMMM, yyyy", "dd/MM/yyyy 'هـ'" }, new[] { "HH:mm", "hh:mm tt" }, new[] { "HH:mm:ss", "hh:mm:ss tt" } } },
+                       { 0x0468, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "dd/MM/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x046a, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "dd/MM/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x046b, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x046c, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x046d, new[] { new[] { "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy 'й'" }, new[] { "H:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x046e, new[] { new[] { "dd/MM/yyyy", " dd/MM/yy", "dd.MM.yy", "dd/MM/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "H.mm", "H.mm' Auer'" }, new[] { "HH:mm:ss", "H:mm:ss' Auer'", "HH:mm:ss' Auer'", "HHmmss" } } },
+                       { 0x046f, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd", "yyyy MM dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0470, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "dd/MM/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0478, new[] { new[] { "yyyy/M/d", "yyyy-M-d", "yyyy.M.d", "yyyy.MM.dd", "yyyy-MM-dd", "yyyy/MM/dd" }, new[] { "yyyy'ꈎ' M'ꆪ' d'ꑍ'", "dddd, yyyy'ꈎ' M'ꆪ' d'ꑍ'", "yyyy'ꈎ' M'ꆪ' d'ꑍ', dddd" }, new[] { "tt h:mm", "H:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x047a, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "dd/MM/yy", "d/M/yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x047c, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "HH:mm", "H:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x047e, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0480, new[] { new[] { "yyyy-M-d", "yyyy.M.d", "yyyy-MM-dd", "yyyy.MM.dd" }, new[] { "yyyy-'يىلى' MMMM d-'كۈنى،'", "yyyy-'يىلى' MMMM d-'كۈنى،' dddd" }, new[] { "H:mm", "HH:mm", "tt h:mm", "tt hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss", "tt h:mm:ss", "tt hh:mm:ss" } } },
+                       { 0x0481, new[] { new[] { "dd/MM/yyyy", "d/MM/yy", "dd/MM/yy", "d.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, dd MMMM, yyyy", "d MMMM yyyy" }, new[] { "h:mm tt", "hh:mm tt", "HH:mm", "H:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0482, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd,' lo 'd MMMM' de 'yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0483, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0484, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0485, new[] { new[] { "MM.dd.yyyy", "MM.dd.yy", "d.M.yy", "MM/dd/yy", "MM-dd-yyyy" }, new[] { "MMMM d yyyy 'с.'", "MMMM dd yyyy 'с.'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0486, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yyyy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0487, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0488, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x048c, new[] { new[] { "dd/MM/yy", "dd/MM/yyyy" }, new[] { "dd/MM/yyyy", "dd/MMMM/yyyy", "dddd, dd MMMM, yyyy", "dd/MM/yyyy 'هـ'" }, new[] { "h:mm tt", "H:mm" }, new[] { "h:mm:ss tt", "H:mm:ss" } } },
+                       { 0x0491, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "hh:mm tt", "h:mm tt" }, new[] { "HH:mm:ss", "H:mm:ss", "hh:mm:ss tt", "h:mm:ss tt" } } },
+                       { 0x0801, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0804, new[] { new[] { "yyyy/M/d", "yyyy-M-d", "yyyy.M.d", "yyyy-MM-dd", "yyyy/MM/dd", "yyyy.MM.dd", "yy-M-d", "yy/M/d", "yy.M.d", "yy/MM/dd" }, new[] { "yyyy'年'M'月'd'日'", "yyyy'年'M'月'd'日',dddd", "dddd,yyyy'年'M'月'd'日'" }, new[] { "H:mm", "HH:mm", "tt h:mm", "tt hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss", "tt h:mm:ss", "tt hh:mm:ss" } } },
+                       { 0x0807, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.MM.yy", "dd. M. yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dddd, d. MMMM yyyy", "d. MMMM yyyy", "d. MMM yy" }, new[] { "HH:mm", "H:mm", "H.mm' h'", "HH.mm' h'", "H.mm' Uhr'", "HHmm", "HH", "H' h'", "H' Uhr'" }, new[] { "HH:mm:ss", "H:mm:ss", "HH:mm:ss' h'", "H:mm:ss' h'", "HH:mm:ss' Uhr'", "H:mm:ss' Uhr'", "HHmmss" } } },
+                       { 0x0809, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "hh:mm tt", "h:mm tt" }, new[] { "HH:mm:ss", "H:mm:ss", "hh:mm:ss tt", "h:mm:ss tt" } } },
+                       { 0x080a, new[] { new[] { "dd/MM/yyyy", "dd/MMM/yyyy", "dd/MM/yy", "d/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x080c, new[] { new[] { "d/MM/yyyy", "d/MM/yy", "dd.MM.yy", "yy/MM/dd", "dd-MM-yy", "dd/MM/yyyy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMMM yyyy", "dd-MMM-yy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0810, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "dd. MM. yy", "d/M/yy", "dd.M.yy", "yyyy-MM-dd" }, new[] { "dddd, d. MMMM yyyy", "d-MMM-yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "H.mm' h'" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0813, new[] { new[] { "d/MM/yyyy", "d/MM/yy", "dd-MM-yy", "dd.MM.yy", "dd.MMM.yyyy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "dd-MMM-yy", "d MMMM yyyy", "dd MMM yy" }, new[] { "H:mm", "HH:mm", "H.mm' u.'" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0814, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "yyyy-MM-dd", "dd.MMM.yyyy" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm", "'kl 'HH.mm", "HH.mm" }, new[] { "HH:mm:ss", "H:mm:ss", "'kl 'HH.mm.ss", "HH.mm.ss" } } },
+                       { 0x0816, new[] { new[] { "dd-MM-yyyy", "dd-MMM-yyyy", "yy.MM.dd", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dddd, d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy", "d/MMM/yy", "d.MMM.yy" }, new[] { "HH:mm", "HH'H'mm'm'" }, new[] { "HH:mm:ss" } } },
+                       { 0x081a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x081d, new[] { new[] { "d.M.yyyy", "dd.MM.yyyy", "d.M.yy", "yyyy-MM-dd" }, new[] { "'den 'd MMMM yyyy", "dddd' den 'd MMMM yyyy" }, new[] { "HH:mm", "H:mm", "'kl 'H:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "'kl 'H:mm:ss" } } },
+                       { 0x082c, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x082e, new[] { new[] { "d. M. yyyy", "d. M. yy", "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, 'dnja' d. MMMM yyyy", "dddd, d. MMMM yyyy", "d. MMMM yyyy", "d. M. yyyy" }, new[] { "H.mm 'goź.'", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x083b, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x083c, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy", "dd MMM yyyy", "d MMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x083e, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0843, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "dd/MM yyyy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "yyyy 'йил' d-MMMM", "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0845, new[] { new[] { "dd-MM-yy", "d-M-yy", "d.M.yy", "dd-MM-yyyy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH.mm", "H.mm", "tt hh.mm", "tt h.mm" }, new[] { "HH.mm.ss", "H.mm.ss", "tt hh.mm.ss", "tt h.mm.ss" } } },
+                       { 0x0850, new[] { new[] { "yyyy/M/d", "yyyy-M-d", "yyyy.M.d", "yyyy.MM.dd", "yyyy-MM-dd", "yyyy/MM/dd", "yy-M-d", "yy/M/d", "yy.M.d", "yy/MM/dd" }, new[] { "yyyy'ᠣᠨ ᠤ᠋' M'ᠰᠠᠷ᠎ᠠ  ᠢᠢᠨ 'd' ᠤ᠋ ᠡᠳᠦᠷ'", "yyyy'ᠣᠨ ᠤ᠋' M'ᠰᠠᠷ᠎ᠠ  ᠢᠢᠨ 'd' ᠤ᠋ ᠡᠳᠦᠷ᠂' dddd" }, new[] { "H:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x085d, new[] { new[] { "d/MM/yyyy", "d/M/yy", "yy-MM-dd", "dd/MM/yyyy", "yy-MM-dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "ddd, MMMM dd,yyyy", "MMMM dd,yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "HH:mm", "H:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x085f, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "H:mm", "HH:mm", "hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x086b, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0c01, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x0c04, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "yy/M/d", "yy/MM/dd", "yyyy/M/d", "yyyy/MM/dd", "yyyy-MM-dd" }, new[] { "yyyy'年'M'月'd'日'", "yyyy'年'MM'月'dd'日'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0c07, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "dd.M.yyyy", "yyyy-MM-dd" }, new[] { "dddd, dd. MMMM yyyy", "d.MMMM yyyy", "d.MMMyyyy", "d MMM yyyy" }, new[] { "HH:mm", "H:mm", "HH:mm' Uhr'", "H:mm' Uhr'", "HHmm", "HH", "H' Uhr'" }, new[] { "HH:mm:ss", "H:mm:ss", "HH:mm:ss' Uhr'", "H:mm:ss' Uhr'", "HHmmss" } } },
+                       { 0x0c09, new[] { new[] { "d/MM/yyyy", "d/MM/yy", "d/M/yy", "d/M/yyyy", "dd/MM/yy", "dd/MM/yyyy", "dd-MMM-yy", "dd-MMMM-yyyy", "yyyy-MM-dd", "yy/MM/dd", "yyyy/MM/dd" }, new[] { "dddd, d MMMM yyyy", "d MMMM yyyy" }, new[] { "h:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0c0a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yy", "d/M/yy", "dd-MM-yy", "dd.MM.yy", "yyyy-MM-dd", "dd.MMM.yyyy" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "H:mm", "HH:mm", "HH'H'mm'\''" }, new[] { "H:mm:ss", "HH:mm:ss", "HH'H'mm'\''ss'\'\''" } } },
+                       { 0x0c0c, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd", "dd-MM-yy", "yy MM dd", "dd/MM/yy", "dd/MMM/yyyy" }, new[] { "d MMMM yyyy", "d MMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x0c1a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0c3b, new[] { new[] { "d.M.yyyy", "dd.MM.yyyy", "d.M.yy", "yyyy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x0c6b, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x1001, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x1004, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "yy/M/d", "yy/MM/dd", "yyyy/M/d", "yyyy/MM/dd", "yyyy-MM-dd" }, new[] { "yyyy'年'M'月'd'日'", "yyyy'年'MM'月'dd'日'" }, new[] { "tt h:mm", "tt hh:mm", "H:mm", "HH:mm" }, new[] { "tt h:mm:ss", "tt hh:mm:ss", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x1007, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.MM.yy", "d.M.yy", "d.M.yyyy", "yyyy-MM-dd" }, new[] { "dddd, d. MMMM yyyy", "d. MMMM yyyy", "d. MMM yyyy" }, new[] { "HH:mm", "H:mm", "H.mm", "H.mm' Uhr'" }, new[] { "HH:mm:ss", "H:mm:ss' Uhr'", "HH:mm:ss' Uhr'", "HHmmss" } } },
+                       { 0x1009, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "yyyy-MM-dd", "yy-MM-dd", "M/dd/yy", "dd-MMM-yy", "dd-MMM-yyyy" }, new[] { "MMMM-dd-yy", "MMMM d, yyyy", "d-MMM-yy", "dddd, MMMM dd, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "HH:mm", "H:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x100a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yyyy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x100c, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "dd. M. yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMMM yyyy", "d MMM yy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x101a, new[] { new[] { "d.M.yyyy.", "d.M.yy.", "d. M. yyyy.", "dd.MM.yyyy.", "d. M. yy.", "dd.MM.yy.", "dd. MM. yy.", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy.", "dd. MMMM yyyy.", "dddd, d. MMMM yyyy." }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x103b, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm" }, new[] { "HH:mm:ss", "H:mm:ss", "HH.mm.ss" } } },
+                       { 0x1401, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "H:mm", "HH:mm", "hh:mm tt" }, new[] { "H:mm:ss", "HH:mm:ss", "hh:mm:ss tt" } } },
+                       { 0x1404, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "yy/M/d", "yy/MM/dd", "yyyy/M/d", "yyyy/MM/dd", "yyyy-MM-dd" }, new[] { "yyyy'年'M'月'd'日'", "dddd yyyy'年'M'月'd'日'", "dddd yyyy MM dd", "yyyy MM dd" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x1407, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.MM.yy", "dd. M. yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dddd, d. MMMM yyyy", "d. MMMM yyyy", "d. MMM yy" }, new[] { "HH:mm", "H:mm", "H.mm' h'", "HH.mm' h'", "H.mm' Uhr'", "HHmm", "HH", "H' h'", "H' Uhr'" }, new[] { "HH:mm:ss", "H:mm:ss", "HH:mm:ss' h'", "H:mm:ss' h'", "HH:mm:ss' Uhr'", "H:mm:ss' Uhr'", "HHmmss" } } },
+                       { 0x1409, new[] { new[] { "d/MM/yyyy", "d/MM/yy", "dd/MM/yy", "d.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, d MMMM yyyy", "d MMMM yyyy" }, new[] { "h:mm tt", "hh:mm tt", "HH:mm", "H:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x140a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x140c, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x141a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x143b, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x1801, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "H:mm", "HH:mm", "hh:mm tt" }, new[] { "H:mm:ss", "HH:mm:ss", "hh:mm:ss tt" } } },
+                       { 0x1809, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x180a, new[] { new[] { "MM/dd/yyyy", "MM/dd/yy", "d/M/yy", "dd/MM/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x180c, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "dd.MM.yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd d MMMM yyyy", "d MMM yy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "HH.mm", "HH' h 'mm", "HH'h'mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x181a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x183b, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x1c01, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "H:mm", "HH:mm", "hh:mm tt" }, new[] { "H:mm:ss", "HH:mm:ss", "hh:mm:ss tt" } } },
+                       { 0x1c09, new[] { new[] { "yyyy/MM/dd", "yy/MM/dd", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x1c0a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "MM/dd/yyyy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x1c1a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x1c3b, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x2001, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x2009, new[] { new[] { "dd/MM/yyyy", "yyyy-MM-dd" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x200a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x201a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x203b, new[] { new[] { "d.M.yyyy", "dd.MM.yyyy", "d.M.yy", "yyyy-MM-dd" }, new[] { "MMMM d'. p. 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x2401, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x2409, new[] { new[] { "MM/dd/yyyy", "MM/dd/yy", "yyyy-MM-dd" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x240a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/MM/yyyy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x241a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x243b, new[] { new[] { "d.M.yyyy", "dd.MM.yyyy", "d.M.yy", "yyyy-MM-dd" }, new[] { "MMMM d'. p. 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x2801, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x2809, new[] { new[] { "dd/MM/yyyy", "yyyy-MM-dd" }, new[] { "dddd, dd MMMM yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x280a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x281a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x2c01, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x2c09, new[] { new[] { "dd/MM/yyyy", "yyyy-MM-dd" }, new[] { "dddd, dd MMMM yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x2c0a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x2c1a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x3001, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x3009, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yyyy-MM-dd", "yy/MM/dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x300a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x301a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x3401, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x3409, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yyyy-MM-dd", "yy/MM/dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x340a, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "dd/MM/yy", "d/M/yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x3801, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x380a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x3c01, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x3c0a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x4001, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "hh:mm tt", "HH:mm", "H:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x4009, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "d-M-yy", "d.M.yy", "yyyy-MM-dd" }, new[] { "dd MMMM yyyy", "d MMMM yyyy" }, new[] { "HH:mm", "H:mm", "tt hh:mm" }, new[] { "HH:mm:ss", "H:mm:ss", "tt hh:mm:ss", "tt h:mm:ss" } } },
+                       { 0x400a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "d/M/yy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy", "dddd d' de 'MMMM' de 'yyyy", "d' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "h:mm tt", "H:mm", "HH:mm" }, new[] { "hh:mm:ss tt", "h:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x4409, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dddd, d MMMM, yyyy", "d MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x440a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "MM-dd-yyyy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x4809, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "dddd, d MMMM, yyyy", "d MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x480a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "MM-dd-yyyy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x4c0a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "MM-dd-yyyy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x500a, new[] { new[] { "dd/MM/yyyy", "dd/MM/yy", "MM-dd-yyyy", "yyyy-MM-dd" }, new[] { "dddd, dd' de 'MMMM' de 'yyyy" }, new[] { "hh:mm tt", "HH:mm" }, new[] { "hh:mm:ss tt", "HH:mm:ss" } } },
+                       { 0x540a, new[] { new[] { "M/d/yyyy", "M/d/yy", "MM/dd/yy", "MM/dd/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x641a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x681a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x6c1a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x701a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x703b, new[] { new[] { "d.M.yyyy", "dd.MM.yyyy", "d.M.yy", "yyyy-MM-dd" }, new[] { "MMMM d'. p. 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x742c, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x743b, new[] { new[] { "d.M.yyyy", "dd.MM.yyyy", "d.M.yy", "yyyy-MM-dd" }, new[] { "MMMM d'. p. 'yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x7804, new[] { new[] { "yyyy/M/d", "yyyy-M-d", "yyyy.M.d", "yyyy-MM-dd", "yyyy/MM/dd", "yyyy.MM.dd", "yy-M-d", "yy/M/d", "yy.M.d", "yy/MM/dd" }, new[] { "yyyy'年'M'月'd'日'", "yyyy'年'M'月'd'日',dddd", "dddd,yyyy'年'M'月'd'日'" }, new[] { "H:mm", "HH:mm", "tt h:mm", "tt hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss", "tt h:mm:ss", "tt hh:mm:ss" } } },
+                       { 0x7814, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "yyyy-MM-dd", "dd.MMM.yyyy" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm", "'kl 'HH.mm", "HH.mm" }, new[] { "HH:mm:ss", "H:mm:ss", "'kl 'HH.mm.ss", "HH.mm.ss" } } },
+                       { 0x781a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x782c, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x783b, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x7843, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "dd/MM yyyy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "yyyy 'йил' d-MMMM", "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x7850, new[] { new[] { "yy.MM.dd", "yyyy-MM-dd" }, new[] { "yyyy 'оны' MMMM d" }, new[] { "H:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x785d, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd,MMMM dd,yyyy", "MMMM dd,yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x7c04, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "yy/M/d", "yy/MM/dd", "yyyy/M/d", "yyyy/MM/dd", "yyyy-MM-dd" }, new[] { "yyyy'年'M'月'd'日'", "yyyy'年'MM'月'dd'日'" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x7c14, new[] { new[] { "dd.MM.yyyy", "dd.MM.yy", "d.M.yy", "yyyy-MM-dd", "dd.MMM.yyyy" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy" }, new[] { "HH:mm", "H:mm", "'kl 'HH.mm", "HH.mm" }, new[] { "HH:mm:ss", "H:mm:ss", "'kl 'HH.mm.ss", "HH.mm.ss" } } },
+                       { 0x7c1a, new[] { new[] { "d.M.yyyy", "d.M.yy", "d. M. yyyy", "dd.MM.yyyy", "d. M. yy", "dd.MM.yy", "dd. MM. yy", "yyyy-MM-dd" }, new[] { "d. MMMM yyyy", "dd. MMMM yyyy", "dddd, d. MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x7c28, new[] { new[] { "dd.MM.yy", "yyyy-MM-dd" }, new[] { "d MMMM yyyy" }, new[] { "H:mm", "HH:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x7c2e, new[] { new[] { "d. M. yyyy", "d. M. yy", "dd.MM.yyyy", "dd.MM.yy", "yyyy-MM-dd" }, new[] { "dddd, 'dnja' d. MMMM yyyy", "dddd, d. MMMM yyyy", "d. MMMM yyyy", "d. M. yyyy" }, new[] { "H.mm 'goź.'", "HH:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x7c3b, new[] { new[] { "yyyy-MM-dd", "yy-MM-dd" }, new[] { "MMMM d'. b. 'yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x7c43, new[] { new[] { "dd/MM yyyy", "dd.MM.yy", "d.M.yy", "dd/MM/yy", "yyyy-MM-dd" }, new[] { "yyyy 'yil' d-MMMM", "d MMMM yyyy", "dd MMMM yyyy" }, new[] { "HH:mm", "H:mm" }, new[] { "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x7c50, new[] { new[] { "yyyy/M/d", "yyyy-M-d", "yyyy.M.d", "yyyy.MM.dd", "yyyy-MM-dd", "yyyy/MM/dd", "yy-M-d", "yy/M/d", "yy.M.d", "yy/MM/dd" }, new[] { "yyyy'ᠣᠨ ᠤ᠋' M'ᠰᠠᠷ᠎ᠠ  ᠢᠢᠨ 'd' ᠤ᠋ ᠡᠳᠦᠷ'", "yyyy'ᠣᠨ ᠤ᠋' M'ᠰᠠᠷ᠎ᠠ  ᠢᠢᠨ 'd' ᠤ᠋ ᠡᠳᠦᠷ᠂' dddd" }, new[] { "H:mm" }, new[] { "H:mm:ss" } } },
+                       { 0x7c5d, new[] { new[] { "d/MM/yyyy", "d/M/yy", "yy-MM-dd", "dd/MM/yyyy", "yy-MM-dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "ddd, MMMM dd,yyyy", "MMMM dd,yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "HH:mm", "H:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "HH:mm:ss", "H:mm:ss" } } },
+                       { 0x7c5f, new[] { new[] { "dd-MM-yyyy", "dd-MM-yy", "yyyy-MM-dd" }, new[] { "dd MMMM, yyyy", "dddd, dd MMMM, yyyy" }, new[] { "H:mm", "HH:mm", "hh:mm" }, new[] { "H:mm:ss", "HH:mm:ss" } } },
+                       { 0x7c68, new[] { new[] { "d/M/yyyy", "d/M/yy", "dd/MM/yy", "dd/MM/yyyy", "yy/MM/dd", "yyyy-MM-dd", "dd-MMM-yy" }, new[] { "dddd, MMMM dd, yyyy", "MMMM dd, yyyy", "dddd, dd MMMM, yyyy", "dd MMMM, yyyy" }, new[] { "h:mm tt", "hh:mm tt", "H:mm", "HH:mm" }, new[] { "h:mm:ss tt", "hh:mm:ss tt", "H:mm:ss", "HH:mm:ss" } } },
+               };
+
+               static readonly Dictionary<int, string[][]> GroupSizes = new Dictionary<int, string[][]> {
+                       { 0x0028, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0039, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0045, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0046, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0047, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0048, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0049, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x004a, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x004b, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x004c, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x004d, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x004e, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x004f, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0051, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0053, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0054, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0057, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x005b, new [] { new [] { "3" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x005d, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x005e, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0061, new [] { new [] { "3" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x006d, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x006f, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0078, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x007c, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0428, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0439, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0445, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0446, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0447, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0448, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0449, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x044a, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x044b, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x044c, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x044d, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x044e, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x044f, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0451, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0453, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0454, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0457, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x045b, new [] { new [] { "3" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x045d, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x045e, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0461, new [] { new [] { "3" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x046d, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x046f, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0478, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x047c, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x0845, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x0850, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x085d, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x4009, new [] { new [] { "3", "2" }, new [] { "3", "2" }, new [] { "3", "2" } } },
+                       { 0x540a, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x785d, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x7c28, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x7c50, new [] { new [] { "3", "0" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+                       { 0x7c5d, new [] { new [] { "3" }, new [] { "3", "0" }, new [] { "3", "0" } } },
+               };
+
+               static readonly Dictionary<int, string[]> Text = new Dictionary<int, string[]> {
+                       { 0x0001, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x0002, new [] { "1251", "21025", "0", ";", "10007", "866" } },
+                       { 0x0003, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0004, new [] { "936", "500", "0", ",", "10008", "936" } },
+                       { 0x0005, new [] { "1250", "500", "0", ";", "10029", "852" } },
+                       { 0x0006, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x0007, new [] { "1252", "20273", "0", ";", "10000", "850" } },
+                       { 0x0008, new [] { "1253", "20273", "0", ";", "10006", "737" } },
+                       { 0x0009, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x000a, new [] { "1252", "20284", "0", ";", "10000", "850" } },
+                       { 0x000b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x000c, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x000d, new [] { "1255", "500", "1", ",", "10005", "862" } },
+                       { 0x000e, new [] { "1250", "500", "0", ";", "10029", "852" } },
+                       { 0x000f, new [] { "1252", "20871", "0", ";", "10079", "850" } },
+                       { 0x0010, new [] { "1252", "20280", "0", ";", "10000", "850" } },
+                       { 0x0011, new [] { "932", "20290", "0", ",", "10001", "932" } },
+                       { 0x0012, new [] { "949", "20833", "0", ",", "10003", "949" } },
+                       { 0x0013, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0014, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x0015, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x0016, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0017, new [] { "1252", "20273", "0", ";", "10000", "850" } },
+                       { 0x0018, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x0019, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x001a, new [] { "1250", "500", "0", ";", "10082", "852" } },
+                       { 0x001b, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x001c, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x001d, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x001e, new [] { "874", "20838", "0", ",", "10021", "874" } },
+                       { 0x001f, new [] { "1254", "20905", "0", ";", "10081", "857" } },
+                       { 0x0020, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x0021, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0022, new [] { "1251", "500", "0", ";", "10017", "866" } },
+                       { 0x0023, new [] { "1251", "500", "0", ";", "10007", "866" } },
+                       { 0x0024, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x0025, new [] { "1257", "500", "0", ";", "10029", "775" } },
+                       { 0x0026, new [] { "1257", "500", "0", ";", "10029", "775" } },
+                       { 0x0027, new [] { "1257", "500", "0", ";", "10029", "775" } },
+                       { 0x0028, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0029, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x002a, new [] { "1258", "500", "0", ",", "10000", "1258" } },
+                       { 0x002b, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x002c, new [] { "1254", "20905", "0", ";", "10081", "857" } },
+                       { 0x002d, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x002e, new [] { "1252", "870", "0", ";", "10000", "850" } },
+                       { 0x002f, new [] { "1251", "500", "0", ";", "10007", "866" } },
+                       { 0x0032, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x0034, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x0035, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x0036, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x0037, new [] { "0", "500", "0", ";", "2", "1" } },
+                       { 0x0038, new [] { "1252", "20277", "0", ";", "10079", "850" } },
+                       { 0x0039, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x003a, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x003b, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x003c, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x003e, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x003f, new [] { "0", "500", "0", ";", "2", "1" } },
+                       { 0x0040, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0041, new [] { "1252", "500", "0", ",", "10000", "437" } },
+                       { 0x0042, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x0043, new [] { "1254", "500", "0", ";", "10029", "857" } },
+                       { 0x0044, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0045, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0046, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0047, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0048, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0049, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x004a, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x004b, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x004c, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x004d, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x004e, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x004f, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0050, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0051, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0052, new [] { "1252", "20285", "0", ",", "10000", "850" } },
+                       { 0x0053, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0054, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0056, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0057, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x005a, new [] { "0", "500", "1", ",", "2", "1" } },
+                       { 0x005b, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x005d, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x005e, new [] { "0", "500", "0", "á\8d£", "2", "1" } },
+                       { 0x005f, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0061, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0062, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0063, new [] { "0", "500", "1", ";", "2", "1" } },
+                       { 0x0064, new [] { "1252", "500", "0", ",", "10000", "437" } },
+                       { 0x0065, new [] { "0", "500", "1", "ØŒ", "2", "1" } },
+                       { 0x0068, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x006a, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x006b, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x006c, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x006d, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x006e, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x006f, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x0070, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x0078, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x007a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x007c, new [] { "1252", "37", "0", ",", "10000", "850" } },
+                       { 0x007e, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x007f, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x0080, new [] { "1256", "20420", "1", ",", "10004", "720" } },
+                       { 0x0081, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0082, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0083, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0084, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0085, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0086, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x0087, new [] { "1252", "37", "0", ";", "10000", "437" } },
+                       { 0x0088, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x008c, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x0091, new [] { "1252", "20285", "0", ",", "10000", "850" } },
+                       { 0x0401, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x0402, new [] { "1251", "21025", "0", ";", "10007", "866" } },
+                       { 0x0403, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0404, new [] { "950", "500", "0", ",", "10002", "950" } },
+                       { 0x0405, new [] { "1250", "500", "0", ";", "10029", "852" } },
+                       { 0x0406, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x0407, new [] { "1252", "20273", "0", ";", "10000", "850" } },
+                       { 0x0408, new [] { "1253", "20273", "0", ";", "10006", "737" } },
+                       { 0x0409, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x040b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x040c, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x040d, new [] { "1255", "500", "1", ",", "10005", "862" } },
+                       { 0x040e, new [] { "1250", "500", "0", ";", "10029", "852" } },
+                       { 0x040f, new [] { "1252", "20871", "0", ";", "10079", "850" } },
+                       { 0x0410, new [] { "1252", "20280", "0", ";", "10000", "850" } },
+                       { 0x0411, new [] { "932", "20290", "0", ",", "10001", "932" } },
+                       { 0x0412, new [] { "949", "20833", "0", ",", "10003", "949" } },
+                       { 0x0413, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0414, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x0415, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x0416, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0417, new [] { "1252", "20273", "0", ";", "10000", "850" } },
+                       { 0x0418, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x0419, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x041a, new [] { "1250", "500", "0", ";", "10082", "852" } },
+                       { 0x041b, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x041c, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x041d, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x041e, new [] { "874", "20838", "0", ",", "10021", "874" } },
+                       { 0x041f, new [] { "1254", "20905", "0", ";", "10081", "857" } },
+                       { 0x0420, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x0421, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0422, new [] { "1251", "500", "0", ";", "10017", "866" } },
+                       { 0x0423, new [] { "1251", "500", "0", ";", "10007", "866" } },
+                       { 0x0424, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x0425, new [] { "1257", "500", "0", ";", "10029", "775" } },
+                       { 0x0426, new [] { "1257", "500", "0", ";", "10029", "775" } },
+                       { 0x0427, new [] { "1257", "500", "0", ";", "10029", "775" } },
+                       { 0x0428, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0429, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x042a, new [] { "1258", "500", "0", ",", "10000", "1258" } },
+                       { 0x042b, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x042c, new [] { "1254", "20905", "0", ";", "10081", "857" } },
+                       { 0x042d, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x042e, new [] { "1252", "870", "0", ";", "10000", "850" } },
+                       { 0x042f, new [] { "1251", "500", "0", ";", "10007", "866" } },
+                       { 0x0432, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x0434, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x0435, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x0436, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x0437, new [] { "0", "500", "0", ";", "2", "1" } },
+                       { 0x0438, new [] { "1252", "20277", "0", ";", "10079", "850" } },
+                       { 0x0439, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x043a, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x043b, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x043e, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x043f, new [] { "0", "500", "0", ";", "2", "1" } },
+                       { 0x0440, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0441, new [] { "1252", "500", "0", ",", "10000", "437" } },
+                       { 0x0442, new [] { "1250", "20880", "0", ";", "10029", "852" } },
+                       { 0x0443, new [] { "1254", "500", "0", ";", "10029", "857" } },
+                       { 0x0444, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0445, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0446, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0447, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0448, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0449, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x044a, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x044b, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x044c, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x044d, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x044e, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x044f, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0450, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0451, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0452, new [] { "1252", "20285", "0", ",", "10000", "850" } },
+                       { 0x0453, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0454, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0456, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0457, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x045a, new [] { "0", "500", "1", ",", "2", "1" } },
+                       { 0x045b, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x045d, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x045e, new [] { "0", "500", "0", "á\8d£", "2", "1" } },
+                       { 0x0461, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0462, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0463, new [] { "0", "500", "1", ";", "2", "1" } },
+                       { 0x0464, new [] { "1252", "500", "0", ",", "10000", "437" } },
+                       { 0x0465, new [] { "0", "500", "1", "ØŒ", "2", "1" } },
+                       { 0x0468, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x046a, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x046b, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x046c, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x046d, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x046e, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x046f, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x0470, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x0478, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x047a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x047c, new [] { "1252", "37", "0", ",", "10000", "850" } },
+                       { 0x047e, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0480, new [] { "1256", "20420", "1", ",", "10004", "720" } },
+                       { 0x0481, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0482, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0483, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0484, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0485, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0486, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x0487, new [] { "1252", "37", "0", ";", "10000", "437" } },
+                       { 0x0488, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x048c, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x0491, new [] { "1252", "20285", "0", ",", "10000", "850" } },
+                       { 0x0801, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x0804, new [] { "936", "500", "0", ",", "10008", "936" } },
+                       { 0x0807, new [] { "1252", "20273", "0", ";", "10000", "850" } },
+                       { 0x0809, new [] { "1252", "20285", "0", ",", "10000", "850" } },
+                       { 0x080a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x080c, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0810, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0813, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0814, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x0816, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x081a, new [] { "1250", "500", "0", ";", "10029", "852" } },
+                       { 0x081d, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x082c, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x082e, new [] { "1252", "870", "0", ";", "10000", "850" } },
+                       { 0x083b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x083c, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x083e, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x0843, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x0845, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x0850, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x085d, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x085f, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x086b, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x0c01, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x0c04, new [] { "950", "500", "0", ",", "10002", "950" } },
+                       { 0x0c07, new [] { "1252", "20273", "0", ";", "10000", "850" } },
+                       { 0x0c09, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x0c0a, new [] { "1252", "20284", "0", ";", "10000", "850" } },
+                       { 0x0c0c, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x0c1a, new [] { "1251", "21025", "0", ";", "10007", "855" } },
+                       { 0x0c3b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x0c6b, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x1001, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x1004, new [] { "936", "500", "0", ",", "10008", "936" } },
+                       { 0x1007, new [] { "1252", "20273", "0", ";", "10000", "850" } },
+                       { 0x1009, new [] { "1252", "37", "0", ",", "10000", "850" } },
+                       { 0x100a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x100c, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x101a, new [] { "1250", "870", "0", ";", "10082", "852" } },
+                       { 0x103b, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x1401, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x1404, new [] { "950", "500", "0", ",", "10002", "950" } },
+                       { 0x1407, new [] { "1252", "20273", "0", ";", "10000", "850" } },
+                       { 0x1409, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x140a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x140c, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x141a, new [] { "1250", "870", "0", ";", "10082", "852" } },
+                       { 0x143b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x1801, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x1809, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x180a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x180c, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x181a, new [] { "1250", "870", "0", ";", "10082", "852" } },
+                       { 0x183b, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x1c01, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x1c09, new [] { "1252", "500", "0", ",", "10000", "437" } },
+                       { 0x1c0a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x1c1a, new [] { "1251", "21025", "0", ";", "10007", "855" } },
+                       { 0x1c3b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x2001, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x2009, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x200a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x201a, new [] { "1251", "870", "0", ";", "10082", "855" } },
+                       { 0x203b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x2401, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x2409, new [] { "1252", "500", "0", ",", "10000", "850" } },
+                       { 0x240a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x241a, new [] { "1250", "500", "0", ";", "10029", "852" } },
+                       { 0x243b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x2801, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x2809, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x280a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x281a, new [] { "1251", "21025", "0", ";", "10007", "855" } },
+                       { 0x2c01, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x2c09, new [] { "1252", "500", "0", ";", "10000", "850" } },
+                       { 0x2c0a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x2c1a, new [] { "1250", "500", "0", ";", "10029", "852" } },
+                       { 0x3001, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x3009, new [] { "1252", "500", "0", ",", "10000", "437" } },
+                       { 0x300a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x301a, new [] { "1251", "21025", "0", ";", "10007", "855" } },
+                       { 0x3401, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x3409, new [] { "1252", "500", "0", ",", "10000", "437" } },
+                       { 0x340a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x3801, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x380a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x3c01, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x3c0a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x4001, new [] { "1256", "20420", "1", ";", "10004", "720" } },
+                       { 0x4009, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x400a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x4409, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x440a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x4809, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x480a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x4c0a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x500a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x540a, new [] { "1252", "20284", "0", ",", "10000", "850" } },
+                       { 0x641a, new [] { "1251", "870", "0", ";", "10082", "855" } },
+                       { 0x681a, new [] { "1250", "870", "0", ";", "10082", "852" } },
+                       { 0x6c1a, new [] { "1251", "21025", "0", ";", "10007", "855" } },
+                       { 0x701a, new [] { "1250", "500", "0", ";", "10029", "852" } },
+                       { 0x703b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x742c, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x743b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x7804, new [] { "936", "500", "0", ",", "10008", "936" } },
+                       { 0x7814, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x781a, new [] { "1250", "870", "0", ";", "10082", "852" } },
+                       { 0x782c, new [] { "1254", "20905", "0", ";", "10081", "857" } },
+                       { 0x783b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x7843, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x7850, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x785d, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x7c04, new [] { "950", "500", "0", ",", "10002", "950" } },
+                       { 0x7c14, new [] { "1252", "20277", "0", ";", "10000", "850" } },
+                       { 0x7c1a, new [] { "1250", "500", "0", ";", "10029", "852" } },
+                       { 0x7c28, new [] { "1251", "20880", "0", ";", "10007", "866" } },
+                       { 0x7c2e, new [] { "1252", "870", "0", ";", "10000", "850" } },
+                       { 0x7c3b, new [] { "1252", "20278", "0", ";", "10000", "850" } },
+                       { 0x7c43, new [] { "1254", "500", "0", ";", "10029", "857" } },
+                       { 0x7c50, new [] { "0", "500", "0", ",", "2", "1" } },
+                       { 0x7c5d, new [] { "1252", "37", "0", ",", "10000", "437" } },
+                       { 0x7c5f, new [] { "1252", "20297", "0", ";", "10000", "850" } },
+                       { 0x7c68, new [] { "1252", "37", "0", ",", "10000", "437" } },
+               };
+
+               static readonly Dictionary<int, string[]> Numbers = new Dictionary<int, string[]> {
+                       { 0x0001, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x0002, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0003, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0004, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x0005, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0006, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0007, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0008, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0009, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x000a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x000b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x000c, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x000d, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x000e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x000f, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0010, new [] { "9", "2", "1", "1", "1" } },
+                       { 0x0011, new [] { "1", "0", "1", "1", "1" } },
+                       { 0x0012, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x0013, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0014, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0015, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0016, new [] { "9", "2", "1", "1", "1" } },
+                       { 0x0017, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x0018, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0019, new [] { "5", "1", "1", "1", "1" } },
+                       { 0x001a, new [] { "8", "3", "2", "1", "1" } },
+                       { 0x001b, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x001c, new [] { "5", "1", "1", "0", "0" } },
+                       { 0x001d, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x001e, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x001f, new [] { "8", "3", "1", "2", "2" } },
+                       { 0x0020, new [] { "3", "0", "1", "0", "0" } },
+                       { 0x0021, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0022, new [] { "5", "1", "1", "1", "1" } },
+                       { 0x0023, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0024, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0025, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0026, new [] { "9", "2", "1", "1", "1" } },
+                       { 0x0027, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0028, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0029, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x002a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x002b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x002c, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x002d, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x002e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x002f, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0032, new [] { "2", "2", "1", "2", "2" } },
+                       { 0x0034, new [] { "2", "2", "1", "2", "2" } },
+                       { 0x0035, new [] { "2", "2", "1", "2", "2" } },
+                       { 0x0036, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x0037, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0038, new [] { "12", "2", "1", "1", "1" } },
+                       { 0x0039, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x003a, new [] { "1", "0", "1", "2", "2" } },
+                       { 0x003b, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x003c, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x003e, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x003f, new [] { "1", "0", "1", "1", "1" } },
+                       { 0x0040, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0041, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0042, new [] { "5", "1", "1", "1", "1" } },
+                       { 0x0043, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0044, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0045, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x0046, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0047, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0048, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0049, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x004a, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x004b, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x004c, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x004d, new [] { "12", "1", "1", "1", "1" } },
+                       { 0x004e, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x004f, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0050, new [] { "5", "1", "1", "0", "0" } },
+                       { 0x0051, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x0052, new [] { "1", "0", "1", "2", "2" } },
+                       { 0x0053, new [] { "5", "1", "2", "1", "1" } },
+                       { 0x0054, new [] { "4", "1", "0", "0", "0" } },
+                       { 0x0056, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0057, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x005a, new [] { "3", "2", "1", "0", "0" } },
+                       { 0x005b, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x005d, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x005e, new [] { "1", "0", "1", "1", "1" } },
+                       { 0x005f, new [] { "8", "3", "3", "0", "0" } },
+                       { 0x0061, new [] { "1", "0", "1", "1", "1" } },
+                       { 0x0062, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0063, new [] { "3", "0", "3", "4", "2" } },
+                       { 0x0064, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0065, new [] { "10", "3", "1", "0", "0" } },
+                       { 0x0068, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x006a, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x006b, new [] { "14", "2", "1", "2", "2" } },
+                       { 0x006c, new [] { "2", "2", "1", "2", "2" } },
+                       { 0x006d, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x006e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x006f, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0070, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x0078, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x007a, new [] { "9", "2", "1", "0", "0" } },
+                       { 0x007c, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x007e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x007f, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0080, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x0081, new [] { "1", "0", "1", "2", "2" } },
+                       { 0x0082, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0083, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0084, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0085, new [] { "5", "1", "1", "1", "1" } },
+                       { 0x0086, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0087, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x0088, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x008c, new [] { "3", "0", "3", "4", "2" } },
+                       { 0x0091, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x0401, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x0402, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0403, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0404, new [] { "1", "0", "1", "1", "1" } },
+                       { 0x0405, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0406, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0407, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0408, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0409, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x040b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x040c, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x040d, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x040e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x040f, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0410, new [] { "9", "2", "1", "1", "1" } },
+                       { 0x0411, new [] { "1", "0", "1", "1", "1" } },
+                       { 0x0412, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x0413, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0414, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0415, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0416, new [] { "9", "2", "1", "1", "1" } },
+                       { 0x0417, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x0418, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0419, new [] { "5", "1", "1", "1", "1" } },
+                       { 0x041a, new [] { "8", "3", "2", "1", "1" } },
+                       { 0x041b, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x041c, new [] { "5", "1", "1", "0", "0" } },
+                       { 0x041d, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x041e, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x041f, new [] { "8", "3", "1", "2", "2" } },
+                       { 0x0420, new [] { "3", "0", "1", "0", "0" } },
+                       { 0x0421, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0422, new [] { "5", "1", "1", "1", "1" } },
+                       { 0x0423, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0424, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0425, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0426, new [] { "9", "2", "1", "1", "1" } },
+                       { 0x0427, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0428, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0429, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x042a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x042b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x042c, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x042d, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x042e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x042f, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0432, new [] { "2", "2", "1", "2", "2" } },
+                       { 0x0434, new [] { "2", "2", "1", "2", "2" } },
+                       { 0x0435, new [] { "2", "2", "1", "2", "2" } },
+                       { 0x0436, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x0437, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0438, new [] { "12", "2", "1", "1", "1" } },
+                       { 0x0439, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x043a, new [] { "1", "0", "1", "2", "2" } },
+                       { 0x043b, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x043e, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x043f, new [] { "1", "0", "1", "1", "1" } },
+                       { 0x0440, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0441, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0442, new [] { "5", "1", "1", "1", "1" } },
+                       { 0x0443, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0444, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0445, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x0446, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0447, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0448, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0449, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x044a, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x044b, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x044c, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x044d, new [] { "12", "1", "1", "1", "1" } },
+                       { 0x044e, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x044f, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0450, new [] { "5", "1", "1", "0", "0" } },
+                       { 0x0451, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x0452, new [] { "1", "0", "1", "2", "2" } },
+                       { 0x0453, new [] { "5", "1", "2", "1", "1" } },
+                       { 0x0454, new [] { "4", "1", "0", "0", "0" } },
+                       { 0x0456, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0457, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x045a, new [] { "3", "2", "1", "0", "0" } },
+                       { 0x045b, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x045d, new [] { "0", "0", "1", "1", "1" } },
+                       { 0x045e, new [] { "1", "0", "1", "1", "1" } },
+                       { 0x0461, new [] { "1", "0", "1", "1", "1" } },
+                       { 0x0462, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0463, new [] { "3", "0", "3", "4", "2" } },
+                       { 0x0464, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0465, new [] { "10", "3", "1", "0", "0" } },
+                       { 0x0468, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x046a, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x046b, new [] { "14", "2", "1", "2", "2" } },
+                       { 0x046c, new [] { "2", "2", "1", "2", "2" } },
+                       { 0x046d, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x046e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x046f, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0470, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x0478, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x047a, new [] { "9", "2", "1", "0", "0" } },
+                       { 0x047c, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x047e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0480, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x0481, new [] { "1", "0", "1", "2", "2" } },
+                       { 0x0482, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0483, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0484, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0485, new [] { "5", "1", "1", "1", "1" } },
+                       { 0x0486, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0487, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x0488, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x048c, new [] { "3", "0", "3", "4", "2" } },
+                       { 0x0491, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x0801, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x0804, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x0807, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x0809, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x080a, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x080c, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0810, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x0813, new [] { "12", "2", "1", "1", "1" } },
+                       { 0x0814, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x0816, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x081a, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x081d, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x082c, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x082e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x083b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x083c, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x083e, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x0843, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0845, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x0850, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x085d, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x085f, new [] { "8", "3", "3", "0", "0" } },
+                       { 0x086b, new [] { "14", "2", "1", "2", "2" } },
+                       { 0x0c01, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x0c04, new [] { "0", "0", "1", "1", "1" } },
+                       { 0x0c07, new [] { "9", "2", "1", "1", "1" } },
+                       { 0x0c09, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x0c0a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0c0c, new [] { "15", "3", "1", "0", "0" } },
+                       { 0x0c1a, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x0c3b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x0c6b, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x1001, new [] { "3", "0", "3", "0", "0" } },
+                       { 0x1004, new [] { "0", "0", "1", "1", "1" } },
+                       { 0x1007, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x1009, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x100a, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x100c, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x101a, new [] { "8", "3", "2", "0", "0" } },
+                       { 0x103b, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x1401, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x1404, new [] { "0", "0", "1", "1", "1" } },
+                       { 0x1407, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x1409, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x140a, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x140c, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x141a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x143b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x1801, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x1809, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x180a, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x180c, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x181a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x183b, new [] { "12", "2", "1", "2", "2" } },
+                       { 0x1c01, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x1c09, new [] { "2", "2", "1", "1", "1" } },
+                       { 0x1c0a, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x1c1a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x1c3b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x2001, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x2009, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x200a, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x201a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x203b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x2401, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x2409, new [] { "1", "0", "1", "0", "0" } },
+                       { 0x240a, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x241a, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x243b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x2801, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x2809, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x280a, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x281a, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x2c01, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x2c09, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x2c0a, new [] { "2", "2", "1", "0", "0" } },
+                       { 0x2c1a, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x3001, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x3009, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x300a, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x301a, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x3401, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x3409, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x340a, new [] { "9", "2", "1", "0", "0" } },
+                       { 0x3801, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x380a, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x3c01, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x3c0a, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x4001, new [] { "3", "2", "3", "0", "0" } },
+                       { 0x4009, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x400a, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x4409, new [] { "0", "0", "1", "1", "1" } },
+                       { 0x440a, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x4809, new [] { "0", "0", "1", "1", "1" } },
+                       { 0x480a, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x4c0a, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x500a, new [] { "14", "2", "1", "0", "0" } },
+                       { 0x540a, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x641a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x681a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x6c1a, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x701a, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x703b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x742c, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x743b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x7804, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x7814, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x781a, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x782c, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x783b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x7843, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x7850, new [] { "5", "1", "1", "0", "0" } },
+                       { 0x785d, new [] { "0", "0", "1", "1", "1" } },
+                       { 0x7c04, new [] { "0", "0", "1", "1", "1" } },
+                       { 0x7c14, new [] { "12", "2", "1", "0", "0" } },
+                       { 0x7c1a, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x7c28, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x7c2e, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x7c3b, new [] { "8", "3", "1", "0", "0" } },
+                       { 0x7c43, new [] { "8", "3", "1", "1", "1" } },
+                       { 0x7c50, new [] { "2", "0", "1", "1", "1" } },
+                       { 0x7c5d, new [] { "0", "0", "1", "0", "0" } },
+                       { 0x7c5f, new [] { "8", "3", "3", "0", "0" } },
+                       { 0x7c68, new [] { "2", "2", "1", "0", "0" } },
+               };
+
+               static readonly Dictionary<int, string> Geo = new Dictionary<int, string> {
+                       { 0x0401, "205" },
+                       { 0x0402, "35" },
+                       { 0x0403, "217" },
+                       { 0x0404, "237" },
+                       { 0x0405, "75" },
+                       { 0x0406, "61" },
+                       { 0x0407, "94" },
+                       { 0x0408, "98" },
+                       { 0x0409, "244" },
+                       { 0x040b, "77" },
+                       { 0x040c, "84" },
+                       { 0x040d, "117" },
+                       { 0x040e, "109" },
+                       { 0x040f, "110" },
+                       { 0x0410, "118" },
+                       { 0x0411, "122" },
+                       { 0x0412, "134" },
+                       { 0x0413, "176" },
+                       { 0x0414, "177" },
+                       { 0x0415, "191" },
+                       { 0x0416, "32" },
+                       { 0x0417, "223" },
+                       { 0x0418, "200" },
+                       { 0x0419, "203" },
+                       { 0x041a, "108" },
+                       { 0x041b, "143" },
+                       { 0x041c, "6" },
+                       { 0x041d, "221" },
+                       { 0x041e, "227" },
+                       { 0x041f, "235" },
+                       { 0x0420, "190" },
+                       { 0x0421, "111" },
+                       { 0x0422, "241" },
+                       { 0x0423, "29" },
+                       { 0x0424, "212" },
+                       { 0x0425, "70" },
+                       { 0x0426, "140" },
+                       { 0x0427, "141" },
+                       { 0x0428, "228" },
+                       { 0x0429, "116" },
+                       { 0x042a, "251" },
+                       { 0x042b, "7" },
+                       { 0x042c, "5" },
+                       { 0x042d, "217" },
+                       { 0x042e, "94" },
+                       { 0x042f, "19618" },
+                       { 0x0432, "209" },
+                       { 0x0434, "209" },
+                       { 0x0435, "209" },
+                       { 0x0436, "209" },
+                       { 0x0437, "88" },
+                       { 0x0438, "81" },
+                       { 0x0439, "113" },
+                       { 0x043a, "163" },
+                       { 0x043b, "177" },
+                       { 0x043e, "167" },
+                       { 0x043f, "137" },
+                       { 0x0440, "130" },
+                       { 0x0441, "129" },
+                       { 0x0442, "238" },
+                       { 0x0443, "247" },
+                       { 0x0444, "203" },
+                       { 0x0445, "113" },
+                       { 0x0446, "113" },
+                       { 0x0447, "113" },
+                       { 0x0448, "113" },
+                       { 0x0449, "113" },
+                       { 0x044a, "113" },
+                       { 0x044b, "113" },
+                       { 0x044c, "113" },
+                       { 0x044d, "113" },
+                       { 0x044e, "113" },
+                       { 0x044f, "113" },
+                       { 0x0450, "154" },
+                       { 0x0451, "45" },
+                       { 0x0452, "242" },
+                       { 0x0453, "40" },
+                       { 0x0454, "138" },
+                       { 0x0456, "217" },
+                       { 0x0457, "113" },
+                       { 0x045a, "222" },
+                       { 0x045b, "42" },
+                       { 0x045d, "39" },
+                       { 0x045e, "73" },
+                       { 0x0461, "178" },
+                       { 0x0462, "176" },
+                       { 0x0463, "3" },
+                       { 0x0464, "201" },
+                       { 0x0465, "165" },
+                       { 0x0468, "175" },
+                       { 0x046a, "175" },
+                       { 0x046b, "26" },
+                       { 0x046c, "209" },
+                       { 0x046d, "203" },
+                       { 0x046e, "147" },
+                       { 0x046f, "93" },
+                       { 0x0470, "175" },
+                       { 0x0478, "45" },
+                       { 0x047a, "46" },
+                       { 0x047c, "39" },
+                       { 0x047e, "84" },
+                       { 0x0480, "45" },
+                       { 0x0481, "183" },
+                       { 0x0482, "84" },
+                       { 0x0483, "84" },
+                       { 0x0484, "84" },
+                       { 0x0485, "203" },
+                       { 0x0486, "99" },
+                       { 0x0487, "204" },
+                       { 0x0488, "210" },
+                       { 0x048c, "3" },
+                       { 0x0491, "242" },
+                       { 0x0801, "121" },
+                       { 0x0804, "45" },
+                       { 0x0807, "223" },
+                       { 0x0809, "242" },
+                       { 0x080a, "166" },
+                       { 0x080c, "21" },
+                       { 0x0810, "223" },
+                       { 0x0813, "21" },
+                       { 0x0814, "177" },
+                       { 0x0816, "193" },
+                       { 0x081a, "269" },
+                       { 0x081d, "77" },
+                       { 0x082c, "5" },
+                       { 0x082e, "94" },
+                       { 0x083b, "221" },
+                       { 0x083c, "68" },
+                       { 0x083e, "37" },
+                       { 0x0843, "247" },
+                       { 0x0845, "23" },
+                       { 0x0850, "154" },
+                       { 0x085d, "39" },
+                       { 0x085f, "4" },
+                       { 0x086b, "66" },
+                       { 0x0c01, "67" },
+                       { 0x0c04, "104" },
+                       { 0x0c07, "14" },
+                       { 0x0c09, "12" },
+                       { 0x0c0a, "217" },
+                       { 0x0c0c, "39" },
+                       { 0x0c1a, "269" },
+                       { 0x0c3b, "77" },
+                       { 0x0c6b, "187" },
+                       { 0x1001, "148" },
+                       { 0x1004, "215" },
+                       { 0x1007, "147" },
+                       { 0x1009, "39" },
+                       { 0x100a, "99" },
+                       { 0x100c, "223" },
+                       { 0x101a, "25" },
+                       { 0x103b, "177" },
+                       { 0x1401, "4" },
+                       { 0x1404, "151" },
+                       { 0x1407, "145" },
+                       { 0x1409, "183" },
+                       { 0x140a, "54" },
+                       { 0x140c, "147" },
+                       { 0x141a, "25" },
+                       { 0x143b, "221" },
+                       { 0x1801, "159" },
+                       { 0x1809, "68" },
+                       { 0x180a, "192" },
+                       { 0x180c, "158" },
+                       { 0x181a, "25" },
+                       { 0x183b, "177" },
+                       { 0x1c01, "234" },
+                       { 0x1c09, "209" },
+                       { 0x1c0a, "65" },
+                       { 0x1c1a, "25" },
+                       { 0x1c3b, "221" },
+                       { 0x2001, "164" },
+                       { 0x2009, "124" },
+                       { 0x200a, "249" },
+                       { 0x201a, "25" },
+                       { 0x203b, "77" },
+                       { 0x2401, "261" },
+                       { 0x2409, "124" },
+                       { 0x240a, "51" },
+                       { 0x241a, "271" },
+                       { 0x243b, "77" },
+                       { 0x2801, "222" },
+                       { 0x2809, "24" },
+                       { 0x280a, "187" },
+                       { 0x281a, "271" },
+                       { 0x2c01, "126" },
+                       { 0x2c09, "225" },
+                       { 0x2c0a, "11" },
+                       { 0x2c1a, "270" },
+                       { 0x3001, "139" },
+                       { 0x3009, "264" },
+                       { 0x300a, "66" },
+                       { 0x301a, "270" },
+                       { 0x3401, "136" },
+                       { 0x3409, "201" },
+                       { 0x340a, "46" },
+                       { 0x3801, "224" },
+                       { 0x380a, "246" },
+                       { 0x3c01, "17" },
+                       { 0x3c0a, "185" },
+                       { 0x4001, "197" },
+                       { 0x4009, "113" },
+                       { 0x400a, "26" },
+                       { 0x4409, "167" },
+                       { 0x440a, "72" },
+                       { 0x4809, "215" },
+                       { 0x480a, "106" },
+                       { 0x4c0a, "182" },
+                       { 0x500a, "202" },
+                       { 0x540a, "244" },
+                       };
+
+
+               public static void FillValues (int lcid, CultureInfoEntry ci)
+               {
+                       var entry = DateTime[lcid];
+                       var dfe = ci.DateTimeFormatEntry;
+                       dfe.DateSeparator = entry[0];
+                       dfe.LongDatePattern = entry[1];
+                       dfe.LongTimePattern = entry[2];
+                       dfe.ShortDatePattern = entry[3];
+                       dfe.ShortTimePattern = entry[4];
+                       dfe.MonthDayPattern = entry[5];
+                       dfe.YearMonthPattern = entry[6];
+
+                       var entry_dt = DateTime2[lcid];
+                       entry_dt[0].CopyTo (dfe.ShortDatePatterns, 0);
+                       entry_dt[1].CopyTo (dfe.LongDatePatterns, 0);
+                       entry_dt[2].CopyTo (dfe.ShortTimePatterns, 0);
+                       entry_dt[3].CopyTo (dfe.LongTimePatterns, 0);
+
+                       var entry_te = Text[lcid];
+                       var te = ci.TextInfoEntry;
+                       te.ANSICodePage = entry_te[0];
+                       te.EBCDICCodePage = entry_te[1];
+                       te.IsRightToLeft = entry_te[2] == "1" ? true : false;
+                       te.ListSeparator = entry_te[3];
+                       te.MacCodePage = entry_te[4];
+                       te.OEMCodePage = entry_te[5];
+
+                       var entry_nf = Numbers[lcid];
+                       var nf = ci.NumberFormatEntry;
+                       nf.CurrencyNegativePattern = entry_nf[0];
+                       nf.CurrencyPositivePattern = entry_nf[1];
+                       nf.NumberNegativePattern = entry_nf[2];
+                       nf.PercentNegativePattern = entry_nf[3];
+                       nf.PercentPositivePattern = entry_nf[4];
+
+                       string[][] gsizes;
+                       if (!GroupSizes.TryGetValue (lcid, out gsizes)) {
+                               gsizes = new[] { new[] { "3" }, new[] { "3" }, new[] { "3" } };
+                       }
+
+                       gsizes[0].CopyTo (nf.CurrencyGroupSizes, 0);
+                       gsizes[1].CopyTo (nf.NumberGroupSizes, 0);
+                       gsizes[2].CopyTo (nf.PercentGroupSizes, 0);
+               }
+
+               public static void FillValues (int lcid, RegionInfoEntry ri)
+               {
+                       var entry = Geo[lcid];
+                       ri.GeoId = entry;
+               }
+       }
+}
index cad06784fdbf7c15d6d157fc51bfc34f32487c6a..df8f310c0c0f421abd89c272c2c9548e56d2c322 100644 (file)
@@ -5,14 +5,14 @@
 
 * input resources
 
-       There is only an external resource: unicode CLDR. I used version 1.7, the latest one as of
-       May, 2009:
-       http://unicode.org/Public/cldr/1.7.0/core.zip
+       There is only an external resource: unicode CLDR. It can be downloaded from
+       http://www.unicode.org/Public/cldr/
 
-       There is a couple of extra mono resources included in this directory:
-       - lcids.xml for LCIDs.
-       - textinfos.xml for TextInfo.
-       - supplementalData.xml and supp/*.xml for .NET(Windows)-ism fixup.
+       CLDR specificatin can be found at http://www.unicode.org/reports/tr35/
+
+       All content has to me extracted into CLDR folder. The latest version used is 21.
+
+       There is an extra mono resource included in this directory lcids.xml for LCIDs.
 
 * generated file
 
 
 * updating the data
 
-       Currently, when we need to fix or update data, we need to modify or
-       add the proper file in the supp directory (if it's a new file it must be added
-       in Makefile.am as well to supp_data_files).
+       Update Makefile.am to get the latest CLDR data. However, CLDR is not complete and
+       it's missing data for many rarely used cultures. In such cases we provide empty value
+       but when someone has the knowleadge what the values should be it's recommended to
+       use online CLDR tool to fill the data gap.
+
        To create the files used by the runtime after an update, run:
                make culture-table
                make install-culture-table
+
        At the start of Makefile.am there are additional instructions for specific builds.
 
index b0fd61014129405c85c808bba6bdd50168f6965a..8cfdde5ecb6321122db43249c34876c9974eaeb9 100644 (file)
@@ -16,38 +16,35 @@ namespace Mono.Tools.LocaleBuilder
 {
        public class RegionInfoEntry : Entry
        {
-               public int RegionId; // it is GeoId in 2.0.
-               // public byte MeasurementSystem;
-               public string ISO2Name = String.Empty; // supplementalData.xml
-               public string ISO3Name = String.Empty;
-               public string Win3Name = String.Empty;
-               public string EnglishName = String.Empty; // langs/en.xml
-               public string CurrencySymbol = String.Empty;
-               public string ISOCurrencySymbol = String.Empty; // supplementalData.xml
-               public string CurrencyEnglishName = String.Empty; // langs/en.xml
-
-               // NativeName and CurrencyNativeName are language dependent.
+               public int Index; // Used to link region from culture, it must be 0-based index from region_name_entries
+
+               public string GeoId;
+               public string TwoLetterISORegionName;
+               public string ThreeLetterISORegionName;
+               public string ThreeLetterWindowsRegionName;
+               public string EnglishName;
+               public string CurrencySymbol;
+               public string ISOCurrencySymbol;
+               public string CurrencyEnglishName;
+               public string Name;
+               public string DisplayName;
+               public string NativeName;
+               public string CurrencyNativeName;
+               public bool IsMetric = true;
 
                public void AppendTableRow (StringBuilder builder)
                {
-                       builder.Append ("\t{ 0, "); // 0 is a slot for LCID (stored at managed code)
-                       builder.Append (RegionId);
-                       builder.Append (',');
-                       // builder.Append (MeasurementSystem);
-                       // builder.Append (',');
-                       builder.Append (EncodeStringIdx (ISO2Name));
-                       builder.Append (',');
-                       builder.Append (EncodeStringIdx (ISO3Name));
-                       builder.Append (',');
-                       builder.Append (EncodeStringIdx (Win3Name));
-                       builder.Append (',');
-                       builder.Append (EncodeStringIdx (EnglishName));
-                       builder.Append (',');
-                       builder.Append (EncodeStringIdx (CurrencySymbol));
-                       builder.Append (',');
-                       builder.Append (EncodeStringIdx (ISOCurrencySymbol));
-                       builder.Append (',');
-                       builder.Append (EncodeStringIdx (CurrencyEnglishName));
+                       builder.Append ("\t{ ");
+                       builder.Append (GeoId).Append (',');
+                       builder.Append (EncodeStringIdx (TwoLetterISORegionName)).Append (',');
+                       builder.Append (EncodeStringIdx (ThreeLetterISORegionName)).Append (',');
+                       builder.Append (EncodeStringIdx (ThreeLetterWindowsRegionName)).Append (',');
+                       builder.Append (EncodeStringIdx (EnglishName)).Append (',');
+                       builder.Append (EncodeStringIdx (NativeName)).Append (',');
+                       builder.Append (EncodeStringIdx (CurrencySymbol)).Append (',');
+                       builder.Append (EncodeStringIdx (ISOCurrencySymbol)).Append (',');
+                       builder.Append (EncodeStringIdx (CurrencyEnglishName)).Append (',');
+                       builder.Append (EncodeStringIdx (CurrencyNativeName));
                        builder.Append ('}');
                }
 
index f7a04b5613ca010e40d83a92efeaaf13b85f9b8d..01fd9ccdd55ce5d96333b26fd9295bceda981956 100644 (file)
@@ -1,49 +1,62 @@
-using System;
-using System.Text;
-using System.Collections;
-using System.Xml;
-using System.Xml.XPath;
+//
+// TextInfoEntry.cs
+//
+// Authors:
+//     Marek Safar  <marek.safar@gmail.com>
+//
+// Copyright (C) 2012 Xamarin Inc (http://www.xamarin.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
 
-namespace Mono.Tools.LocaleBuilder {
+using System.Text;
 
-        public class TextInfoEntry : Entry {
-               
-               string ansi = "0";
-               string ebcdic = "0";
-               string mac = "0";
-               string oem = "0";
-               string listsep = ",";
+namespace Mono.Tools.LocaleBuilder
+{
+       public class TextInfoEntry : Entry
+       {
+               public string ANSICodePage;
+               public string EBCDICCodePage;
+               public string MacCodePage;
+               public string OEMCodePage;
+               public string ListSeparator;
+               public bool IsRightToLeft;
 
-               public TextInfoEntry (int lcid, XPathDocument d)
+               public override string ToString ()
                {
-                       string q = "/textinfos/textinfo [@lcid=" + lcid + "]";
-                       XPathNodeIterator ni = (XPathNodeIterator) d.CreateNavigator ().Evaluate (q);
-                       // no info, move along
-                       if (! ni.MoveNext ())
-                               throw new Exception ();         
-                       
-                       ansi = ni.Current.GetAttribute ("ansi", String.Empty);
-                       ebcdic = ni.Current.GetAttribute ("ebcdic", String.Empty);
-                       mac = ni.Current.GetAttribute ("mac", String.Empty);
-                       oem = ni.Current.GetAttribute ("oem", String.Empty);
-                       listsep = ni.Current.GetAttribute ("listsep", String.Empty);
-               }
-               
-                public override string ToString ()
-                {
                        StringBuilder b = new StringBuilder ();
                        b.Append ("{ ");
-                       b.Append (ansi);
-                       b.Append (", ");
-                       b.Append (ebcdic);
-                       b.Append (", ");
-                       b.Append (mac );
-                       b.Append (", ");
-                       b.Append (oem);
-                       b.Append (", '");
-                       b.Append (listsep);
+                       b.Append (ANSICodePage).Append (", ");
+                       b.Append (EBCDICCodePage).Append (", ");
+                       b.Append (MacCodePage).Append (", ");
+                       b.Append (OEMCodePage).Append (", ");
+                       b.Append (IsRightToLeft ? "1" : "0").Append (", '");
+
+                       // TODO: It's more than 1 char for some cultures
+                       if (ListSeparator.Length <= 1)
+                               b.Append (ListSeparator);
+                       else
+                               b.Append (";");
+
                        b.Append ("' }");
-                       
+
                        return b.ToString ();
                }
        }
diff --git a/tools/locale-builder/langs/.gitattributes b/tools/locale-builder/langs/.gitattributes
deleted file mode 100644 (file)
index 2d2377b..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-/nb.xml -crlf
-/nn.xml -crlf
diff --git a/tools/locale-builder/langs/.gitignore b/tools/locale-builder/langs/.gitignore
deleted file mode 100644 (file)
index b878e88..0000000
+++ /dev/null
@@ -1 +0,0 @@
-/*.xml
diff --git a/tools/locale-builder/langs/ka.xml b/tools/locale-builder/langs/ka.xml
deleted file mode 100644 (file)
index 4656cee..0000000
+++ /dev/null
@@ -1,2159 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "../../common/dtd/ldml.dtd">
-<ldml>
-       <identity>
-               <version number="$Revision: 1.66 $"/>
-               <generation date="$Date: 2009/05/05 23:06:37 $"/>
-               <language type="ka"/>
-       </identity>
-       <localeDisplayNames>
-               <localeDisplayPattern>
-                       <localePattern draft="contributed">{0} ({1})</localePattern>
-                       <localeSeparator draft="contributed">, </localeSeparator>
-               </localeDisplayPattern>
-               <languages>
-                       <language type="ab">აფხაზური</language>
-                       <language type="ady">ადიღეური</language>
-                       <language type="ae" draft="contributed">ავესტა</language>
-                       <language type="af">აფრიკული</language>
-                       <language type="ain" draft="contributed">აინუ</language>
-                       <language type="ale" draft="contributed">ალეუტური</language>
-                       <language type="ang">ძველი ინგლისური</language>
-                       <language type="ar">არაბული</language>
-                       <language type="arc">არამეული</language>
-                       <language type="art" draft="contributed">ხელოვნური სხვა</language>
-                       <language type="as" draft="contributed">ასამური</language>
-                       <language type="ast">ავსტრიული</language>
-                       <language type="az">აზერბაიჯანული</language>
-                       <language type="be" draft="contributed">ბელორუსული</language>
-                       <language type="bg">ბულგარული</language>
-                       <language type="bh" draft="contributed">ბიჰარი</language>
-                       <language type="bo">ტიბეტური</language>
-                       <language type="br" draft="contributed">ბრეტონული</language>
-                       <language type="bs">ბოსნიური</language>
-                       <language type="bua" draft="contributed">ბურიატული</language>
-                       <language type="ca" draft="contributed">კატალანური</language>
-                       <language type="cau" draft="contributed">კავკასიური სხვა</language>
-                       <language type="ce">ჩეჩნური</language>
-                       <language type="cel" draft="contributed">კელტური სხვა</language>
-                       <language type="cs">ჩეხური</language>
-                       <language type="cu">საეკლესიო სლავური</language>
-                       <language type="cy" draft="contributed">უელსური</language>
-                       <language type="da">დანიური</language>
-                       <language type="de">გერმანული</language>
-                       <language type="de_AT">ავსტრიული გერმანული</language>
-                       <language type="de_CH" draft="contributed">შვეიცარიული მაღალი გერმანული</language>
-                       <language type="egy" draft="contributed">ეგვიპტური</language>
-                       <language type="el">ბერძნული</language>
-                       <language type="en">ინგლისური</language>
-                       <language type="en_AU">ავსტრალიური ინგლისური</language>
-                       <language type="en_CA">კანადური ინგლისური</language>
-                       <language type="en_GB">ბრიტანული ინგლისური</language>
-                       <language type="en_US">ამერიკული ინგლისური</language>
-                       <language type="eo">ესპერანტო</language>
-                       <language type="es">ესპანური</language>
-                       <language type="es_419" draft="contributed">ლათინურ ამერიკული ესპანური</language>
-                       <language type="es_ES" draft="contributed">იბერიული ესპანური</language>
-                       <language type="et">ესტონური</language>
-                       <language type="eu">ბასკური</language>
-                       <language type="fa">სპარსული</language>
-                       <language type="fi">ფინური</language>
-                       <language type="fil">ფილიპინური</language>
-                       <language type="fr">ფრანგული</language>
-                       <language type="fr_CA">კანადური ფრანგული</language>
-                       <language type="fr_CH">შვეიცარიული ფრანგული</language>
-                       <language type="fro">ძველი ფრანგული</language>
-                       <language type="ga">ირლანდიური</language>
-                       <language type="gd">შოტლანდიურ-გალური</language>
-                       <language type="gl">გალური</language>
-                       <language type="gn" draft="contributed">გუარანი</language>
-                       <language type="goh">ძველი გერმანული</language>
-                       <language type="grc">ძველი ბერძნული</language>
-                       <language type="gsw">შვეიცარიული გერმანული</language>
-                       <language type="gu" draft="contributed">გუჯარათი</language>
-                       <language type="he">ებრაული</language>
-                       <language type="hi" draft="contributed">ჰინდი</language>
-                       <language type="hr">ხორვატიული</language>
-                       <language type="hu">უნგრული</language>
-                       <language type="hy">სომხური</language>
-                       <language type="ia" draft="contributed">ინტერლინგუალური</language>
-                       <language type="id">ინდონეზიური</language>
-                       <language type="ie" draft="contributed">ინტერლინგი</language>
-                       <language type="ine" draft="contributed">ინდო-ევროპული სხვა</language>
-                       <language type="is">ისლანდიური</language>
-                       <language type="it">იტალიური</language>
-                       <language type="ja">იაპონური</language>
-                       <language type="jv" draft="contributed">იავანური</language>
-                       <language type="ka">ქართული</language>
-                       <language type="kg" draft="contributed">კონგო</language>
-                       <language type="kk" draft="contributed">ყაზახური</language>
-                       <language type="km">კამბოჯიური</language>
-                       <language type="ko">კორეული</language>
-                       <language type="ku" draft="contributed">ქურთული</language>
-                       <language type="ky">ყირგიზული</language>
-                       <language type="la">ლათინური</language>
-                       <language type="lb">ლუქსემბურგული</language>
-                       <language type="ln" draft="contributed">ლინგალა</language>
-                       <language type="lo">ლაოსური</language>
-                       <language type="lt">ლიტვური</language>
-                       <language type="lv">ლატვიური</language>
-                       <language type="mk">მაკედონიური</language>
-                       <language type="mn" draft="contributed">მონღოლური</language>
-                       <language type="mo" draft="contributed">მოლდოვური</language>
-                       <language type="ms">მალაიზიური</language>
-                       <language type="myn" draft="contributed">მაიას ენები</language>
-                       <language type="nap" draft="contributed">ნეაპოლიტანური</language>
-                       <language type="ne">ნეპალური</language>
-                       <language type="nl">ჰოლანდიური</language>
-                       <language type="nl_BE" draft="contributed">ფლომანდიური</language>
-                       <language type="nn">ნორვეგიული ნინორსკი</language>
-                       <language type="no">ნორვეგიული</language>
-                       <language type="nv">ნავახო</language>
-                       <language type="oc" draft="contributed">ოციტანური</language>
-                       <language type="or" draft="contributed">ორიული</language>
-                       <language type="os">ოსური</language>
-                       <language type="peo">ძველი სპარსული</language>
-                       <language type="pl">პოლონური</language>
-                       <language type="pra" draft="contributed">პრაკრიტის ენები</language>
-                       <language type="ps" draft="contributed">პუშტუ</language>
-                       <language type="pt">პორტუგალიური</language>
-                       <language type="pt_BR" draft="contributed">ბრაზილიური პორტუგალიური</language>
-                       <language type="pt_PT">იბერიულ-პორტუგალიური</language>
-                       <language type="ro">რუმინული</language>
-                       <language type="ru">რუსული</language>
-                       <language type="sa" draft="contributed">სანსკრიტი</language>
-                       <language type="sc">სარდინიული</language>
-                       <language type="scn">სიცილიური</language>
-                       <language type="sd" draft="contributed">სინდური</language>
-                       <language type="sga">ძველი ირლანდიური</language>
-                       <language type="sh" draft="contributed">სერბულ-ხორვატული</language>
-                       <language type="si" draft="contributed">სინჰალური</language>
-                       <language type="sk">სლოვაკური</language>
-                       <language type="sl">სლოვენური</language>
-                       <language type="sla" draft="contributed">სლავური სხვა</language>
-                       <language type="so">სომალიური</language>
-                       <language type="sq">ალბანური</language>
-                       <language type="sr" draft="contributed">სერბული</language>
-                       <language type="st" draft="contributed">სამხრეთ სოთოს ენა</language>
-                       <language type="sux">შუმერული</language>
-                       <language type="sv">შვედური</language>
-                       <language type="sw" draft="contributed">სუაჰილი</language>
-                       <language type="tg">ტაჯიკური</language>
-                       <language type="th">ტაილანდური</language>
-                       <language type="tk">თურქმენული</language>
-                       <language type="tlh" draft="contributed">კლინგონი</language>
-                       <language type="tn" draft="contributed">ტსვანა</language>
-                       <language type="tr">თურქული</language>
-                       <language type="tw" draft="contributed">თუი</language>
-                       <language type="udm" draft="contributed">უდმურტიული</language>
-                       <language type="ug" draft="contributed">უიგურული</language>
-                       <language type="uk">უკრაინული</language>
-                       <language type="und">უცნობი ან არასწორი ენა</language>
-                       <language type="ur" draft="contributed">ურდუ</language>
-                       <language type="uz">უზბეკური</language>
-                       <language type="vi">ვიეტნამური</language>
-                       <language type="xh" draft="contributed">ქსოზა</language>
-                       <language type="yi" draft="contributed">იდიში</language>
-                       <language type="zh">ჩინური</language>
-                       <language type="zh_Hans" draft="contributed">გამარტივებული ჩინური</language>
-                       <language type="zh_Hant" draft="contributed">ტრადიციული ჩინური</language>
-                       <language type="zu" draft="contributed">ზულუ</language>
-               </languages>
-               <scripts>
-                       <script type="Arab">არაბული</script>
-                       <script type="Armn">სომხური</script>
-                       <script type="Bali" draft="contributed">ბალი</script>
-                       <script type="Batk" draft="contributed">ბატაკი</script>
-                       <script type="Beng">ბენგალური</script>
-                       <script type="Brai">ბრაილი</script>
-                       <script type="Copt" draft="contributed">კოპტური</script>
-                       <script type="Cprt" draft="contributed">კვიპროსული</script>
-                       <script type="Cyrl">კირილიცა</script>
-                       <script type="Cyrs">ძველი საეკლესიო კირილიცა</script>
-                       <script type="Deva" draft="contributed">დევანაგარი</script>
-                       <script type="Egyd" draft="contributed">ეგვიპტური დემოტიკური</script>
-                       <script type="Egyh" draft="contributed">ეგვიპტური ჰიერატიკული</script>
-                       <script type="Egyp" draft="contributed">ეგვიპტური იეროგლიფური</script>
-                       <script type="Ethi">ეთიოპური</script>
-                       <script type="Geok">ხუცური</script>
-                       <script type="Geor">ქართული</script>
-                       <script type="Glag" draft="contributed">გლაგოლიცა</script>
-                       <script type="Goth">გოთური</script>
-                       <script type="Grek">ბერძნული</script>
-                       <script type="Gujr" draft="contributed">გუჯარათული</script>
-                       <script type="Guru" draft="contributed">გურმუხული</script>
-                       <script type="Hani" draft="contributed">ჰანი</script>
-                       <script type="Hans" draft="contributed">გამარტივებული ჰანი</script>
-                       <script type="Hant">ტრადიციული ჰანი</script>
-                       <script type="Hebr">ებრაული</script>
-                       <script type="Hira">ჰირაგანა</script>
-                       <script type="Hrkt">კატაკანა ან ჰირაგანა</script>
-                       <script type="Hung">ძველი უნგრული</script>
-                       <script type="Jpan">იაპონური</script>
-                       <script type="Kana">კატაკანა</script>
-                       <script type="Khmr" draft="contributed">ქჰმერული</script>
-                       <script type="Laoo" draft="contributed">ლაოსური</script>
-                       <script type="Latn">ლათინური</script>
-                       <script type="Lina" draft="contributed">წრფივი A</script>
-                       <script type="Linb" draft="contributed">წრფივი B</script>
-                       <script type="Maya">მაიას იეროგლიფები</script>
-                       <script type="Mong">მონღოლური</script>
-                       <script type="Phnx" draft="contributed">ფინიკიური</script>
-                       <script type="Runr" draft="contributed">რუნული</script>
-                       <script type="Syrc">სირიული</script>
-                       <script type="Syre" draft="contributed">ესტრანჯელოსეული სირიული</script>
-                       <script type="Syrj" draft="contributed">დასავლეთი სირიული</script>
-                       <script type="Syrn" draft="contributed">აღმოსავლეთი სირიული</script>
-                       <script type="Taml">ტამილური</script>
-                       <script type="Thai">ტაილანდური</script>
-                       <script type="Tibt">ტიბეტური</script>
-                       <script type="Xpeo">ძველი სპარსული</script>
-                       <script type="Xsux" draft="contributed">შუმერულ-აქადური ლურსმნული</script>
-                       <script type="Zxxx">დაუწერელი</script>
-                       <script type="Zzzz">უცნობი ან არასწორი დამწერლობა</script>
-               </scripts>
-               <territories>
-                       <territory type="001">მსოფლიო</territory>
-                       <territory type="002">აფრიკა</territory>
-                       <territory type="003">ჩრდილოეთ ამერიკა</territory>
-                       <territory type="005">სამხრეთი ამერიკა</territory>
-                       <territory type="009" draft="contributed">ოკეანეთი</territory>
-                       <territory type="011">დასავლეთი აფრიკა</territory>
-                       <territory type="013">ცენტრალური ამერიკა</territory>
-                       <territory type="014">აღმოსავლეთი აფრიკა</territory>
-                       <territory type="015">ჩრდილოეთი აფრიკა</territory>
-                       <territory type="017">შუა აფრიკა</territory>
-                       <territory type="018">სამხრეთი აფრიკა</territory>
-                       <territory type="019">ამერიკები</territory>
-                       <territory type="021">ჩრდილოეთი ამერიკა</territory>
-                       <territory type="029" draft="contributed">კარიბი</territory>
-                       <territory type="030">აღმოსავლეთი აზია</territory>
-                       <territory type="034">სამხრეთი აზია</territory>
-                       <territory type="035">სამხრეთ-აღმოსავლეთი აზია</territory>
-                       <territory type="039">სამხრეთი ევროპა</territory>
-                       <territory type="053">ავსტრალია და ახალი ზელანდია</territory>
-                       <territory type="054" draft="contributed">მელანეზია</territory>
-                       <territory type="057" draft="contributed">მირონეზია</territory>
-                       <territory type="061">პოლინეზია</territory>
-                       <territory type="062">სამხრეთ-ცენტრალური აზია</territory>
-                       <territory type="142">აზია</territory>
-                       <territory type="143">ცენტრალური აზია</territory>
-                       <territory type="145">დასავლეთი აზია</territory>
-                       <territory type="150">ევროპა</territory>
-                       <territory type="151">აღმოსავლეთი ევროპა</territory>
-                       <territory type="154">ჩრდილოეთი ევროპა</territory>
-                       <territory type="155">დასავლეთი ევროპა</territory>
-                       <territory type="172">დამოუკიდებელ სახელმწიფოთა თანამეგობრობა</territory>
-                       <territory type="419" draft="contributed">ლათინური ამერიკა და კარიბი</territory>
-                       <territory type="AD">ანდორა</territory>
-                       <territory type="AE">არაბეთის გაერთიანებული ემირატები</territory>
-                       <territory type="AF">ავღანეთი</territory>
-                       <territory type="AG">ანტიგუა და ბარბუდა</territory>
-                       <territory type="AI">ანგვილა</territory>
-                       <territory type="AL">ალბანეთი</territory>
-                       <territory type="AM">სომხეთი</territory>
-                       <territory type="AN" draft="contributed">ნიდერლანდების ანტილები</territory>
-                       <territory type="AO">ანგოლა</territory>
-                       <territory type="AQ">ანტარქტიკა</territory>
-                       <territory type="AR">არგენტინა</territory>
-                       <territory type="AS">ამერიკული სამოა</territory>
-                       <territory type="AT">ავსტრია</territory>
-                       <territory type="AU">ავსტრალია</territory>
-                       <territory type="AW">არუბა</territory>
-                       <territory type="AX">ალანდის კუნძულები</territory>
-                       <territory type="AZ">აზერბაიჯანი</territory>
-                       <territory type="BA">ბოსნია და ჰერცეგოვინა</territory>
-                       <territory type="BB">ბარბადოსი</territory>
-                       <territory type="BD">ბანგლადეში</territory>
-                       <territory type="BE">ბელგია</territory>
-                       <territory type="BF">ბურკინა-ფასო</territory>
-                       <territory type="BG">ბულგარეთი</territory>
-                       <territory type="BH">ბაჰრეინი</territory>
-                       <territory type="BI">ბურუნდი</territory>
-                       <territory type="BJ">ბენინი</territory>
-                       <territory type="BM">ბერმუდა</territory>
-                       <territory type="BN">ბრუნეი</territory>
-                       <territory type="BO">ბოლივია</territory>
-                       <territory type="BR">ბრაზილია</territory>
-                       <territory type="BS">ბაჰამის კუნძულები</territory>
-                       <territory type="BT">ბუტანი</territory>
-                       <territory type="BV" draft="contributed">ბუვეს კუნძული</territory>
-                       <territory type="BW">ბოტსვანა</territory>
-                       <territory type="BY">ბელორუსია</territory>
-                       <territory type="BZ">ბელიზი</territory>
-                       <territory type="CA">კანადა</territory>
-                       <territory type="CD" draft="contributed">კონგო - კინშასა</territory>
-                       <territory type="CF">ცენტრალური აფრიკის რესპუბლიკა</territory>
-                       <territory type="CG">კონგო</territory>
-                       <territory type="CH">შვეიცარია</territory>
-                       <territory type="CI">სპილოს ძვლის სანაპირო</territory>
-                       <territory type="CK">კუკის კუნძულები</territory>
-                       <territory type="CL">ჩილე</territory>
-                       <territory type="CM">კამერუნი</territory>
-                       <territory type="CN">ჩინეთი</territory>
-                       <territory type="CO">კოლუმბია</territory>
-                       <territory type="CR">კოსტა-რიკა</territory>
-                       <territory type="CS">სერბია და მონტენეგრო</territory>
-                       <territory type="CU">კუბა</territory>
-                       <territory type="CV">კაბო-ვერდე</territory>
-                       <territory type="CX">შობის კუნძული</territory>
-                       <territory type="CY">კვიპროსი</territory>
-                       <territory type="CZ">ჩეხეთის რესპუბლიკა</territory>
-                       <territory type="DE">გერმანია</territory>
-                       <territory type="DJ">ჯიბუტი</territory>
-                       <territory type="DK">დანია</territory>
-                       <territory type="DM">დომინიკა</territory>
-                       <territory type="DO">დომინიკანის რესპუბლიკა</territory>
-                       <territory type="DZ">ალჟირი</territory>
-                       <territory type="EC">ეკვადორი</territory>
-                       <territory type="EE">ესტონეთი</territory>
-                       <territory type="EG">ეგვიპტე</territory>
-                       <territory type="EH">დასავლეთი საჰარა</territory>
-                       <territory type="ER">ერიტრეა</territory>
-                       <territory type="ES">ესპანეთი</territory>
-                       <territory type="ET">ეთიოპია</territory>
-                       <territory type="FI">ფინეთი</territory>
-                       <territory type="FJ">ფიჯი</territory>
-                       <territory type="FK">ფალკლენდის კუნძულები</territory>
-                       <territory type="FM">მიკრონეზია</territory>
-                       <territory type="FO">ფაროს კუნძულები</territory>
-                       <territory type="FR">საფრანგეთი</territory>
-                       <territory type="GA">გაბონი</territory>
-                       <territory type="GB">დიდი ბრიტანეთი</territory>
-                       <territory type="GD">გრენადა</territory>
-                       <territory type="GE">საქართველო</territory>
-                       <territory type="GH">განა</territory>
-                       <territory type="GI">გიბრალტარი</territory>
-                       <territory type="GL">გრენლანდია</territory>
-                       <territory type="GM">გამბია</territory>
-                       <territory type="GN">გვინეა</territory>
-                       <territory type="GP" draft="contributed">გვადელუპე</territory>
-                       <territory type="GQ">ეკვატორული გვინეა</territory>
-                       <territory type="GR">საბერძნეთი</territory>
-                       <territory type="GS" draft="contributed">სამხრეთი ჯორჯია და სამხრეთ სენდვიჩის კუნძულები</territory>
-                       <territory type="GT">გვატემალა</territory>
-                       <territory type="GU" draft="contributed">გუამი</territory>
-                       <territory type="GW">გვინეა-ბისაუ</territory>
-                       <territory type="GY">გაიანა</territory>
-                       <territory type="HK" draft="contributed">ჰონგ კონგი</territory>
-                       <territory type="HK" alt="short">ჰონგ კონგი</territory>
-                       <territory type="HM" draft="contributed">ჰერდის კუნძული და მაკდონალდის კუნძულები</territory>
-                       <territory type="HN">ჰონდურასი</territory>
-                       <territory type="HR">ჰორვატია</territory>
-                       <territory type="HT">ჰაიტი</territory>
-                       <territory type="HU">უნგრეთი</territory>
-                       <territory type="ID">ინდონეზია</territory>
-                       <territory type="IE">ირლანდია</territory>
-                       <territory type="IL">ისრაელი</territory>
-                       <territory type="IM" draft="contributed">მანის კუნძული</territory>
-                       <territory type="IN">ინდოეთი</territory>
-                       <territory type="IO">ბრიტანული ტერიტორია ინდოეთის ოკეანეში</territory>
-                       <territory type="IQ">ერაყი</territory>
-                       <territory type="IR">ირანი</territory>
-                       <territory type="IS">ისლანდია</territory>
-                       <territory type="IT">იტალია</territory>
-                       <territory type="JE" draft="contributed">ჯერსი</territory>
-                       <territory type="JM">იამაიკა</territory>
-                       <territory type="JO">იორდანია</territory>
-                       <territory type="JP">იაპონია</territory>
-                       <territory type="KE">კენია</territory>
-                       <territory type="KG">ყირგიზეთი</territory>
-                       <territory type="KH">კამბოჯა</territory>
-                       <territory type="KI">კირიბატი</territory>
-                       <territory type="KM">კომორის კუნძულები</territory>
-                       <territory type="KN">სენტ-კიტსი და ნევისი</territory>
-                       <territory type="KP">ჩრდილოეთი კორეა</territory>
-                       <territory type="KR">სამხრეთი კორეა</territory>
-                       <territory type="KW">კუვეიტი</territory>
-                       <territory type="KY">კაიმანის კუნძულები</territory>
-                       <territory type="KZ">ყაზახეთი</territory>
-                       <territory type="LA">ლაოსი</territory>
-                       <territory type="LB">ლიბანი</territory>
-                       <territory type="LC">სენტ-ლუსია</territory>
-                       <territory type="LI">ლიხტენშტაინი</territory>
-                       <territory type="LK">შრი-ლანკა</territory>
-                       <territory type="LR">ლიბერია</territory>
-                       <territory type="LS" draft="contributed">ლესოთო</territory>
-                       <territory type="LT">ლიტვა</territory>
-                       <territory type="LU">ლუქსემბურგი</territory>
-                       <territory type="LV">ლატვია</territory>
-                       <territory type="LY">ლიბია</territory>
-                       <territory type="MA">მაროკო</territory>
-                       <territory type="MC">მონაკო</territory>
-                       <territory type="MD">მოლდოვა</territory>
-                       <territory type="ME">მონტენეგრო</territory>
-                       <territory type="MG">მადაგასკარი</territory>
-                       <territory type="MH">მარშალის კუნძულები</territory>
-                       <territory type="MK">მაკედონია</territory>
-                       <territory type="ML">მალი</territory>
-                       <territory type="MM">მიანმარი</territory>
-                       <territory type="MN">მონღოლეთი</territory>
-                       <territory type="MO" draft="contributed">მაკაო</territory>
-                       <territory type="MO" alt="short">მაკაო</territory>
-                       <territory type="MQ" draft="contributed">მარტინიკი</territory>
-                       <territory type="MR">მავრიტანია</territory>
-                       <territory type="MS">მონსერატი</territory>
-                       <territory type="MT">მალტა</territory>
-                       <territory type="MU">მავრიკია</territory>
-                       <territory type="MV">მალდივის კუნძულები</territory>
-                       <territory type="MW">მალავი</territory>
-                       <territory type="MX">მექსიკა</territory>
-                       <territory type="MY">მალაიზია</territory>
-                       <territory type="MZ">მოზამბიკი</territory>
-                       <territory type="NA">ნამიბია</territory>
-                       <territory type="NC" draft="contributed">ახალი კალედონია</territory>
-                       <territory type="NE">ნიგერი</territory>
-                       <territory type="NF">ნორფოლკის კუნძული</territory>
-                       <territory type="NG">ნიგერია</territory>
-                       <territory type="NI">ნიკარაგუა</territory>
-                       <territory type="NL">ნიდერლანდები</territory>
-                       <territory type="NO">ნორვეგია</territory>
-                       <territory type="NP">ნეპალი</territory>
-                       <territory type="NR">ნაურუ</territory>
-                       <territory type="NZ">ახალი ზელანდია</territory>
-                       <territory type="OM">ომანი</territory>
-                       <territory type="PA">პანამა</territory>
-                       <territory type="PE">პერუ</territory>
-                       <territory type="PF" draft="contributed">ფრანგული პოლინეზია</territory>
-                       <territory type="PG">პაპუა-ახალი გვინეა</territory>
-                       <territory type="PH">ფილიპინები</territory>
-                       <territory type="PK">პაკისტანი</territory>
-                       <territory type="PL">პოლონეთი</territory>
-                       <territory type="PM" draft="contributed">სენტ-პიერი და მიქელონი</territory>
-                       <territory type="PR">პუერტო რიკო</territory>
-                       <territory type="PS">პალესტინის ტერიტორია</territory>
-                       <territory type="PT">პორტუგალია</territory>
-                       <territory type="PW">პალაუ</territory>
-                       <territory type="PY">პარაგვაი</territory>
-                       <territory type="QA">კატარი</territory>
-                       <territory type="QO" draft="contributed">დაშორებული ოკეანია</territory>
-                       <territory type="QU">ევროკავშირი</territory>
-                       <territory type="RE" draft="contributed">რეიუნიონი</territory>
-                       <territory type="RO">რუმინეთი</territory>
-                       <territory type="RS">სერბია</territory>
-                       <territory type="RU">რუსეთი</territory>
-                       <territory type="RW">რუანდა</territory>
-                       <territory type="SA">საუდის არაბეთი</territory>
-                       <territory type="SB">სოლომონის კუნძულები</territory>
-                       <territory type="SC">სეიშელის კუნძულები</territory>
-                       <territory type="SD">სუდანი</territory>
-                       <territory type="SE">შვეცია</territory>
-                       <territory type="SG">სინგაპური</territory>
-                       <territory type="SH" draft="contributed">წმინდა ელენეს კუნძული</territory>
-                       <territory type="SI">სლოვენია</territory>
-                       <territory type="SK">სლოვაკეთი</territory>
-                       <territory type="SL">სიერა-ლეონე</territory>
-                       <territory type="SM">სან-მარინო</territory>
-                       <territory type="SN">სენეგალი</territory>
-                       <territory type="SO">სომალი</territory>
-                       <territory type="SR">სურინამი</territory>
-                       <territory type="ST">საო-ტომე და პრინსიპი</territory>
-                       <territory type="SV">სალვადორი</territory>
-                       <territory type="SY">სირია</territory>
-                       <territory type="SZ">სვაზილენდი</territory>
-                       <territory type="TD">ჩადი</territory>
-                       <territory type="TF" draft="contributed">ფრანგული სამხრეთის ტერიტორიები</territory>
-                       <territory type="TG">ტოგო</territory>
-                       <territory type="TH">ტაილანდი</territory>
-                       <territory type="TJ">ტაჯიკეთი</territory>
-                       <territory type="TL">აღმოსავლეთი ტიმორი</territory>
-                       <territory type="TM">თურქმენეთი</territory>
-                       <territory type="TN">ტუნისი</territory>
-                       <territory type="TO">ტონგა</territory>
-                       <territory type="TR">თურქეთი</territory>
-                       <territory type="TT">ტრინიდადი და ტობაგო</territory>
-                       <territory type="TV">ტუვალუ</territory>
-                       <territory type="TW">ტაივანი</territory>
-                       <territory type="TZ">ტანზანია</territory>
-                       <territory type="UA">უკრაინა</territory>
-                       <territory type="UG">უგანდა</territory>
-                       <territory type="UM">შეერთებული შტატების მცირე დაშორებული კუნძულები</territory>
-                       <territory type="US">ამერიკის შეერთებული შტატები</territory>
-                       <territory type="UY">ურუგვაი</territory>
-                       <territory type="UZ">უზბეკეთი</territory>
-                       <territory type="VA">ვატიკანი</territory>
-                       <territory type="VC">სენტ-ვინსენტი და გრენადინები</territory>
-                       <territory type="VE">ვენესუელა</territory>
-                       <territory type="VN">ვიეტნამი</territory>
-                       <territory type="VU">ვანუატუ</territory>
-                       <territory type="WF" draft="contributed">ვალისი და ფუტუნა</territory>
-                       <territory type="WS">სამოა</territory>
-                       <territory type="YE">იემენი</territory>
-                       <territory type="ZA">სამხრეთ აფრიკა</territory>
-                       <territory type="ZM">ზამბია</territory>
-                       <territory type="ZW">ზიმბაბვე</territory>
-                       <territory type="ZZ">უცნობი ან არასწორი რეგიონი</territory>
-               </territories>
-               <keys>
-                       <key type="calendar">კალენდარი</key>
-                       <key type="collation">მიმდევრობა</key>
-                       <key type="currency">ვალუტა</key>
-               </keys>
-               <types>
-                       <type type="big5han" key="collation">ტრადიციული ჩინური</type>
-                       <type type="buddhist" key="calendar">ბუდისტური კალენდარი</type>
-                       <type type="chinese" key="calendar">ჩინური კალენდარი</type>
-                       <type type="direct" key="collation">პირდაპირი მიმდევრობა</type>
-                       <type type="gb2312han" key="collation">გამარტივებული ჩინური</type>
-                       <type type="gregorian" key="calendar">გრიგორიანული კალენდარი</type>
-                       <type type="hebrew" key="calendar">ებრაული კალენდარი</type>
-                       <type type="indian" key="calendar" draft="contributed">ინდური ეროვნული კალენდარი</type>
-                       <type type="islamic" key="calendar">ისლამური კალენდარი</type>
-                       <type type="islamic-civil" key="calendar">ისლამური სამოქალაქო კალენდარი</type>
-                       <type type="japanese" key="calendar">იაპონური კალენდარი</type>
-                       <type type="roc" key="calendar" draft="contributed">ჩინეთის რესპუბლიკის კალენდარი</type>
-                       <type type="traditional" key="collation">ტრადიციული</type>
-               </types>
-               <measurementSystemNames>
-                       <measurementSystemName type="US" draft="contributed">US</measurementSystemName>
-                       <measurementSystemName type="metric" draft="contributed">Metric</measurementSystemName>
-               </measurementSystemNames>
-       </localeDisplayNames>
-       <characters>
-               <exemplarCharacters>[ა ⴀ ბ ⴁ გ ⴂ დ ⴃ ე ⴄ ვ ⴅ ზ ⴆ ჱ ⴡ თ ⴇ ი ⴈ კ ⴉ ლ ⴊ მ ⴋ ნ ⴌ ჲ ⴢ ო ⴍ პ ⴎ ჟ ⴏ რ ⴐ ს ⴑ ტ ⴒ ჳ ⴣ უ ⴓ ფ ⴔ ქ ⴕ ღ ⴖ ყ ⴗ შ ⴘ ჩ ⴙ ც ⴚ ძ ⴛ წ ⴜ ჭ ⴝ ხ ⴞ ჴ ⴤ ჯ ⴟ ჰ ⴠ ჵ ⴥ ჶ-ჺ]</exemplarCharacters>
-       </characters>
-       <delimiters>
-               <quotationStart draft="contributed">“</quotationStart>
-               <quotationEnd draft="contributed">”</quotationEnd>
-               <alternateQuotationStart draft="contributed">‘</alternateQuotationStart>
-               <alternateQuotationEnd draft="contributed">’</alternateQuotationEnd>
-       </delimiters>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <months>
-                                       <monthContext type="format">
-                                               <monthWidth type="abbreviated">
-                                                       <month type="1" draft="provisional">იან</month>
-                                                       <month type="2" draft="provisional">თებ</month>
-                                                       <month type="3" draft="provisional">მარ</month>
-                                                       <month type="4" draft="provisional">აპრ</month>
-                                                       <month type="5" draft="provisional">მაი</month>
-                                                       <month type="6" draft="provisional">ივნ</month>
-                                                       <month type="7" draft="provisional">ივლ</month>
-                                                       <month type="8" draft="provisional">აგვ</month>
-                                                       <month type="9" draft="provisional">სექ</month>
-                                                       <month type="10" draft="provisional">ოქტ</month>
-                                                       <month type="11" draft="provisional">ნოე</month>
-                                                       <month type="12" draft="provisional">დეკ</month>
-                                               </monthWidth>
-                                               <monthWidth type="wide">
-                                                       <month type="1" draft="provisional">იანვარი</month>
-                                                       <month type="2" draft="provisional">თებერვალი</month>
-                                                       <month type="3" draft="provisional">მარტი</month>
-                                                       <month type="4" draft="provisional">აპრილი</month>
-                                                       <month type="5" draft="provisional">მაისი</month>
-                                                       <month type="6" draft="provisional">ივნისი</month>
-                                                       <month type="7" draft="provisional">ივლისი</month>
-                                                       <month type="8" draft="provisional">აგვისტო</month>
-                                                       <month type="9" draft="provisional">სექტემბერი</month>
-                                                       <month type="10" draft="provisional">ოქტომბერი</month>
-                                                       <month type="11" draft="provisional">ნოემბერი</month>
-                                                       <month type="12" draft="provisional">დეკემბერი</month>
-                                               </monthWidth>
-                                       </monthContext>
-                                       <monthContext type="stand-alone">
-                                               <monthWidth type="narrow">
-                                                       <month type="1" draft="provisional">ი</month>
-                                                       <month type="2" draft="provisional">თ</month>
-                                                       <month type="3" draft="provisional">მ</month>
-                                                       <month type="4" draft="provisional">ა</month>
-                                                       <month type="5" draft="provisional">მ</month>
-                                                       <month type="6" draft="provisional">ი</month>
-                                                       <month type="7" draft="provisional">ი</month>
-                                                       <month type="8" draft="provisional">ა</month>
-                                                       <month type="9" draft="provisional">ს</month>
-                                                       <month type="10" draft="provisional">ო</month>
-                                                       <month type="11" draft="provisional">ნ</month>
-                                                       <month type="12" draft="provisional">დ</month>
-                                               </monthWidth>
-                                       </monthContext>
-                               </months>
-                               <days>
-                                       <dayContext type="format">
-                                               <dayWidth type="abbreviated">
-                                                       <day type="sun" draft="provisional">კვი</day>
-                                                       <day type="mon" draft="provisional">ორშ</day>
-                                                       <day type="tue" draft="provisional">სამ</day>
-                                                       <day type="wed" draft="provisional">ოთხ</day>
-                                                       <day type="thu" draft="provisional">ხუთ</day>
-                                                       <day type="fri" draft="provisional">პარ</day>
-                                                       <day type="sat" draft="provisional">შაბ</day>
-                                               </dayWidth>
-                                               <dayWidth type="wide">
-                                                       <day type="sun" draft="provisional">კვირა</day>
-                                                       <day type="mon" draft="provisional">ორშაბათი</day>
-                                                       <day type="tue" draft="provisional">სამშაბათი</day>
-                                                       <day type="wed" draft="provisional">ოთხშაბათი</day>
-                                                       <day type="thu" draft="provisional">ხუთშაბათი</day>
-                                                       <day type="fri" draft="provisional">პარასკევი</day>
-                                                       <day type="sat" draft="provisional">შაბათი</day>
-                                               </dayWidth>
-                                       </dayContext>
-                                       <dayContext type="stand-alone">
-                                               <dayWidth type="narrow">
-                                                       <day type="sun" draft="provisional">კ</day>
-                                                       <day type="mon" draft="provisional">ო</day>
-                                                       <day type="tue" draft="provisional">ს</day>
-                                                       <day type="wed" draft="provisional">ო</day>
-                                                       <day type="thu" draft="provisional">ხ</day>
-                                                       <day type="fri" draft="provisional">პ</day>
-                                                       <day type="sat" draft="provisional">შ</day>
-                                               </dayWidth>
-                                       </dayContext>
-                               </days>
-                               <quarters>
-                                       <quarterContext type="format">
-                                               <quarterWidth type="abbreviated">
-                                                       <quarter type="1">I კვ.</quarter>
-                                                       <quarter type="2">II კვ.</quarter>
-                                                       <quarter type="3">III კვ.</quarter>
-                                                       <quarter type="4">IV კვ.</quarter>
-                                               </quarterWidth>
-                                               <quarterWidth type="wide">
-                                                       <quarter type="1">1-ლი კვარტალი</quarter>
-                                                       <quarter type="2">მე-2 კვარტალი</quarter>
-                                                       <quarter type="3">მე-3 კვარტალი</quarter>
-                                                       <quarter type="4">მე-4 კვარტალი</quarter>
-                                               </quarterWidth>
-                                       </quarterContext>
-                                       <quarterContext type="stand-alone">
-                                               <quarterWidth type="wide">
-                                                       <quarter type="1" draft="provisional">I კვარტალი</quarter>
-                                                       <quarter type="2" draft="provisional">II კვარტალი</quarter>
-                                                       <quarter type="3" draft="provisional">III კვარტალი</quarter>
-                                                       <quarter type="4" draft="provisional">IV კვარტალი</quarter>
-                                               </quarterWidth>
-                                       </quarterContext>
-                               </quarters>
-                               <am draft="provisional">დილის</am>
-                               <pm draft="provisional">საღამოს</pm>
-                               <eras>
-                                       <eraNames>
-                                               <era type="0" draft="provisional">ჩვენს წელთაღრიცხვამდე</era>
-                                               <era type="1" draft="provisional">ჩვენი წელთაღრიცხვით</era>
-                                       </eraNames>
-                                       <eraAbbr>
-                                               <era type="0" draft="provisional">ჩვენს წელთაღრიცხვამდე</era>
-                                               <era type="1" draft="provisional">ჩვენი წელთაღრიცხვით</era>
-                                       </eraAbbr>
-                                       <eraNarrow>
-                                               <era type="0" draft="provisional">ჩვენს წელთაღრიცხვამდე</era>
-                                               <era type="1" draft="provisional">ჩვენი წელთაღრიცხვით</era>
-                                       </eraNarrow>
-                               </eras>
-                               <dateFormats>
-                                       <dateFormatLength type="full">
-                                               <dateFormat>
-                                                       <pattern draft="unconfirmed">EEEE, y MMMM dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-                                       <dateFormatLength type="long">
-                                               <dateFormat>
-                                                       <pattern draft="unconfirmed">y MMMM d</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-                                       <dateFormatLength type="medium">
-                                               <dateFormat>
-                                                       <pattern draft="unconfirmed">y MMM d</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-                                       <dateFormatLength type="short">
-                                               <dateFormat>
-                                                       <pattern draft="unconfirmed">yy/MM/dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="full">
-                                               <timeFormat>
-                                                       <pattern draft="provisional">HH:mm:ss zzzz</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength>
-                                       <timeFormatLength type="long">
-                                               <timeFormat>
-                                                       <pattern draft="provisional">HH:mm:ss z</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength>
-                                       <timeFormatLength type="medium">
-                                               <timeFormat>
-                                                       <pattern draft="provisional">HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength>
-                                       <timeFormatLength type="short">
-                                               <timeFormat>
-                                                       <pattern draft="provisional">HH:mm</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength>
-                               </timeFormats>
-                               <dateTimeFormats>
-                                       <availableFormats>
-                                               <dateFormatItem id="HHmm" draft="unconfirmed">HH:mm</dateFormatItem>
-                                               <dateFormatItem id="HHmmss" draft="unconfirmed">HH:mm:ss</dateFormatItem>
-                                               <dateFormatItem id="MMMdd" draft="unconfirmed">dd MMM</dateFormatItem>
-                                               <dateFormatItem id="MMdd" draft="contributed">dd/MM</dateFormatItem>
-                                               <dateFormatItem id="hhmm" draft="unconfirmed">hh:mm a</dateFormatItem>
-                                               <dateFormatItem id="hhmmss" draft="unconfirmed">hh:mm:ss a</dateFormatItem>
-                                               <dateFormatItem id="yyMM" draft="unconfirmed">MM/yy</dateFormatItem>
-                                               <dateFormatItem id="yyMMMEEEd" draft="unconfirmed">EEE, d MMM, yy</dateFormatItem>
-                                               <dateFormatItem id="yyMMMd" draft="unconfirmed">d MMM, yy</dateFormatItem>
-                                               <dateFormatItem id="yyMMdd" draft="unconfirmed">dd/MM/yy</dateFormatItem>
-                                               <dateFormatItem id="yyQ" draft="unconfirmed">Q yy</dateFormatItem>
-                                               <dateFormatItem id="yyQQQQ" draft="unconfirmed">QQQQ yy</dateFormatItem>
-                                       </availableFormats>
-                               </dateTimeFormats>
-                               <fields>
-                                       <field type="era">
-                                               <displayName draft="provisional">ხანა</displayName>
-                                       </field>
-                                       <field type="year">
-                                               <displayName draft="provisional">წელი</displayName>
-                                       </field>
-                                       <field type="month">
-                                               <displayName draft="provisional">თვე</displayName>
-                                       </field>
-                                       <field type="week">
-                                               <displayName draft="provisional">კვირა</displayName>
-                                       </field>
-                                       <field type="day">
-                                               <displayName draft="provisional">დღე</displayName>
-                                               <relative type="-3" draft="provisional">სამი დღის წინ</relative>
-                                               <relative type="-2" draft="provisional">გუშინწინ</relative>
-                                               <relative type="-1" draft="provisional">გუშინ</relative>
-                                               <relative type="0" draft="provisional">დღეს</relative>
-                                               <relative type="1" draft="provisional">ხვალ</relative>
-                                               <relative type="2" draft="provisional">ზეგ</relative>
-                                               <relative type="3" draft="provisional">სამი დღის შემდეგ</relative>
-                                       </field>
-                                       <field type="weekday">
-                                               <displayName draft="provisional">კვირის დღე</displayName>
-                                       </field>
-                                       <field type="dayperiod">
-                                               <displayName draft="provisional">დღის პერიოდი</displayName>
-                                       </field>
-                                       <field type="hour">
-                                               <displayName draft="provisional">საათი</displayName>
-                                       </field>
-                                       <field type="minute">
-                                               <displayName draft="provisional">წუთი</displayName>
-                                       </field>
-                                       <field type="second">
-                                               <displayName draft="provisional">წამი</displayName>
-                                       </field>
-                                       <field type="zone">
-                                               <displayName draft="provisional">ზონა</displayName>
-                                       </field>
-                               </fields>
-                       </calendar>
-               </calendars>
-               <timeZoneNames>
-                       <hourFormat draft="contributed">+HH:mm;-HH:mm</hourFormat>
-                       <gmtFormat draft="unconfirmed">GMT{0}</gmtFormat>
-                       <regionFormat draft="contributed">{0}</regionFormat>
-                       <fallbackFormat draft="contributed">{1} ({0})</fallbackFormat>
-                       <zone type="Etc/Unknown">
-                               <exemplarCity draft="contributed">უცნობი</exemplarCity>
-                       </zone>
-                       <zone type="America/Antigua">
-                               <exemplarCity draft="provisional">ბარბუდა</exemplarCity>
-                       </zone>
-                       <zone type="America/Anguilla">
-                               <exemplarCity draft="provisional">ანგილა</exemplarCity>
-                       </zone>
-                       <zone type="America/Curacao">
-                               <exemplarCity draft="provisional">ნიდერლანდის</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Luanda">
-                               <exemplarCity draft="provisional">ანგოლა</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/Rothera">
-                               <exemplarCity draft="contributed">როთერა</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/Palmer">
-                               <exemplarCity draft="contributed">პალმერი</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/South_Pole">
-                               <exemplarCity draft="contributed">სამხრეთი პოლუსი</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/Syowa">
-                               <exemplarCity draft="contributed">სიოუა</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/Mawson">
-                               <exemplarCity draft="contributed">მოუსონი</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/Davis">
-                               <exemplarCity draft="contributed">დევისი</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/Vostok">
-                               <exemplarCity draft="contributed">ვოსტოკი</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/Casey">
-                               <exemplarCity draft="contributed">კეისი</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/DumontDUrville">
-                               <exemplarCity draft="contributed">დიუმონ დ'ურვილი</exemplarCity>
-                       </zone>
-                       <zone type="Antarctica/McMurdo">
-                               <exemplarCity draft="contributed">მაკმურდო</exemplarCity>
-                       </zone>
-                       <zone type="America/Argentina/Rio_Gallegos">
-                               <exemplarCity draft="contributed">რიო გალეგოსი</exemplarCity>
-                       </zone>
-                       <zone type="America/Mendoza">
-                               <exemplarCity draft="contributed">მენდოზა</exemplarCity>
-                       </zone>
-                       <zone type="America/Argentina/San_Juan">
-                               <exemplarCity draft="contributed">სან ხუანი</exemplarCity>
-                       </zone>
-                       <zone type="America/Argentina/Ushuaia">
-                               <exemplarCity draft="contributed">უშუაია</exemplarCity>
-                       </zone>
-                       <zone type="America/Argentina/La_Rioja">
-                               <exemplarCity draft="contributed">ლა რიოხა</exemplarCity>
-                       </zone>
-                       <zone type="America/Argentina/San_Luis">
-                               <exemplarCity draft="contributed">სან ლუისი</exemplarCity>
-                       </zone>
-                       <zone type="America/Catamarca">
-                               <exemplarCity draft="contributed">კატამარკა</exemplarCity>
-                       </zone>
-                       <zone type="America/Jujuy">
-                               <exemplarCity draft="contributed">ჯუჯუი</exemplarCity>
-                       </zone>
-                       <zone type="America/Argentina/Tucuman">
-                               <exemplarCity draft="contributed">ტუკუმანი</exemplarCity>
-                       </zone>
-                       <zone type="America/Cordoba">
-                               <exemplarCity draft="contributed">კორდობა</exemplarCity>
-                       </zone>
-                       <zone type="America/Buenos_Aires">
-                               <exemplarCity draft="contributed">ბუენოს აირესი</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Perth">
-                               <exemplarCity draft="contributed">პერთი</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Eucla">
-                               <exemplarCity draft="contributed">ეუკლა</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Darwin">
-                               <exemplarCity draft="contributed">დარვინი</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Adelaide">
-                               <exemplarCity draft="contributed">ადელაიდა</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Broken_Hill">
-                               <exemplarCity draft="contributed">ბროუკენ ჰილი</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Currie">
-                               <exemplarCity draft="contributed">ქური</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Melbourne">
-                               <exemplarCity draft="contributed">მელბურნი</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Hobart">
-                               <exemplarCity draft="contributed">ჰობარტი</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Lindeman">
-                               <exemplarCity draft="contributed">ლინდმანი</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Sydney">
-                               <exemplarCity draft="contributed">სიდნეი</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Brisbane">
-                               <exemplarCity draft="contributed">ბრისბეინი</exemplarCity>
-                       </zone>
-                       <zone type="Australia/Lord_Howe">
-                               <exemplarCity draft="contributed">ლორდ ჰოუი</exemplarCity>
-                       </zone>
-                       <zone type="America/Aruba">
-                               <exemplarCity draft="provisional">არუბა</exemplarCity>
-                       </zone>
-                       <zone type="America/Barbados">
-                               <exemplarCity draft="provisional">ბარბადოსი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Ouagadougou">
-                               <exemplarCity draft="provisional">ბურკინა ფასო</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Bujumbura">
-                               <exemplarCity draft="provisional">ბურუნდი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Porto-Novo">
-                               <exemplarCity draft="provisional">ბენინი</exemplarCity>
-                       </zone>
-                       <zone type="America/La_Paz">
-                               <exemplarCity draft="provisional">ბოლივია</exemplarCity>
-                       </zone>
-                       <zone type="America/Eirunepe">
-                               <exemplarCity draft="contributed">ეირუნეპე</exemplarCity>
-                       </zone>
-                       <zone type="America/Rio_Branco">
-                               <exemplarCity draft="contributed">რიო ბრანკო</exemplarCity>
-                       </zone>
-                       <zone type="America/Porto_Velho">
-                               <exemplarCity draft="contributed">პორტო ველჰო</exemplarCity>
-                       </zone>
-                       <zone type="America/Boa_Vista">
-                               <exemplarCity draft="contributed">ბოა ვისტა</exemplarCity>
-                       </zone>
-                       <zone type="America/Manaus">
-                               <exemplarCity draft="contributed">მანაუსი</exemplarCity>
-                       </zone>
-                       <zone type="America/Cuiaba">
-                               <exemplarCity draft="contributed">კუიაბა</exemplarCity>
-                       </zone>
-                       <zone type="America/Campo_Grande">
-                               <exemplarCity draft="contributed">კამპო გრანდე</exemplarCity>
-                       </zone>
-                       <zone type="America/Belem">
-                               <exemplarCity draft="contributed">ბელემი</exemplarCity>
-                       </zone>
-                       <zone type="America/Araguaina">
-                               <exemplarCity draft="contributed">არაგუაინა</exemplarCity>
-                       </zone>
-                       <zone type="America/Sao_Paulo">
-                               <exemplarCity draft="contributed">საო პაულო</exemplarCity>
-                       </zone>
-                       <zone type="America/Bahia">
-                               <exemplarCity draft="contributed">ბაია</exemplarCity>
-                       </zone>
-                       <zone type="America/Fortaleza">
-                               <exemplarCity draft="contributed">ფორტალეზა</exemplarCity>
-                       </zone>
-                       <zone type="America/Maceio">
-                               <exemplarCity draft="contributed">მასეიო</exemplarCity>
-                       </zone>
-                       <zone type="America/Recife">
-                               <exemplarCity draft="contributed">რეციფე</exemplarCity>
-                       </zone>
-                       <zone type="America/Noronha">
-                               <exemplarCity draft="contributed">ნორონია</exemplarCity>
-                       </zone>
-                       <zone type="America/Nassau">
-                               <exemplarCity draft="provisional">ბაჰამის კუნძულები</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Gaborone">
-                               <exemplarCity draft="provisional">ბოტსვანა</exemplarCity>
-                       </zone>
-                       <zone type="America/Belize">
-                               <exemplarCity draft="provisional">ბელიზი</exemplarCity>
-                       </zone>
-                       <zone type="America/Dawson">
-                               <exemplarCity draft="contributed">დოუსონი</exemplarCity>
-                       </zone>
-                       <zone type="America/Whitehorse">
-                               <exemplarCity draft="contributed">უაითჰორსი</exemplarCity>
-                       </zone>
-                       <zone type="America/Inuvik">
-                               <exemplarCity draft="contributed">ინუვიკი</exemplarCity>
-                       </zone>
-                       <zone type="America/Vancouver">
-                               <exemplarCity draft="contributed">ვანკუვერი</exemplarCity>
-                       </zone>
-                       <zone type="America/Dawson_Creek">
-                               <exemplarCity draft="contributed">დოუსონ ქრიკი</exemplarCity>
-                       </zone>
-                       <zone type="America/Yellowknife">
-                               <exemplarCity draft="contributed">იელოუნაიფი</exemplarCity>
-                       </zone>
-                       <zone type="America/Edmonton">
-                               <exemplarCity draft="contributed">ედმონტონი</exemplarCity>
-                       </zone>
-                       <zone type="America/Swift_Current">
-                               <exemplarCity draft="contributed">სვიფტ კარენტი</exemplarCity>
-                       </zone>
-                       <zone type="America/Cambridge_Bay">
-                               <exemplarCity draft="contributed">კემბრიჯ ბეი</exemplarCity>
-                       </zone>
-                       <zone type="America/Regina">
-                               <exemplarCity draft="contributed">რეჯინა</exemplarCity>
-                       </zone>
-                       <zone type="America/Winnipeg">
-                               <exemplarCity draft="contributed">უინიპეგი</exemplarCity>
-                       </zone>
-                       <zone type="America/Resolute">
-                               <exemplarCity draft="contributed">რეზოლუტე</exemplarCity>
-                       </zone>
-                       <zone type="America/Rainy_River">
-                               <exemplarCity draft="contributed">რეინი რივერი</exemplarCity>
-                       </zone>
-                       <zone type="America/Rankin_Inlet">
-                               <exemplarCity draft="contributed">რენკინ ინლეტი</exemplarCity>
-                       </zone>
-                       <zone type="America/Coral_Harbour">
-                               <exemplarCity draft="contributed">ქორალ ჰარბორი</exemplarCity>
-                       </zone>
-                       <zone type="America/Thunder_Bay">
-                               <exemplarCity draft="contributed">თანდერ ბეი</exemplarCity>
-                       </zone>
-                       <zone type="America/Nipigon">
-                               <exemplarCity draft="contributed">ნიპიგონი</exemplarCity>
-                       </zone>
-                       <zone type="America/Toronto">
-                               <exemplarCity draft="contributed">ტორონტო</exemplarCity>
-                       </zone>
-                       <zone type="America/Montreal">
-                               <exemplarCity draft="contributed">მონრეალი</exemplarCity>
-                       </zone>
-                       <zone type="America/Iqaluit">
-                               <exemplarCity draft="contributed">იქალუიტი</exemplarCity>
-                       </zone>
-                       <zone type="America/Pangnirtung">
-                               <exemplarCity draft="contributed">პანგნირტუნგი</exemplarCity>
-                       </zone>
-                       <zone type="America/Moncton">
-                               <exemplarCity draft="contributed">მონქტონი</exemplarCity>
-                       </zone>
-                       <zone type="America/Halifax">
-                               <exemplarCity draft="contributed">ჰალიფაქსი</exemplarCity>
-                       </zone>
-                       <zone type="America/Goose_Bay">
-                               <exemplarCity draft="contributed">გუზ ბეი</exemplarCity>
-                       </zone>
-                       <zone type="America/Glace_Bay">
-                               <exemplarCity draft="contributed">გლეის ბეი</exemplarCity>
-                       </zone>
-                       <zone type="America/Blanc-Sablon">
-                               <exemplarCity draft="contributed">ბლან-საბლონი</exemplarCity>
-                       </zone>
-                       <zone type="America/St_Johns">
-                               <exemplarCity draft="contributed">სენტ ჯონსი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Kinshasa">
-                               <exemplarCity draft="contributed">კინშასა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Lubumbashi">
-                               <exemplarCity draft="contributed">ლუბუმბაში</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Bangui">
-                               <exemplarCity draft="provisional">ცენტრალური აფრიკის რესპუბლიკა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Brazzaville">
-                               <exemplarCity draft="provisional">კონგო - ბრაზავილი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Abidjan">
-                               <exemplarCity draft="provisional">სპილოს ძვლის სანაპირო</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Easter">
-                               <exemplarCity draft="contributed">ისთერი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Douala">
-                               <exemplarCity draft="provisional">კამერუნი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Kashgar">
-                               <exemplarCity draft="contributed">კაშგარი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Urumqi">
-                               <exemplarCity draft="contributed">ურუმქი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Chongqing">
-                               <exemplarCity draft="contributed">ჩონგქინგი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Harbin">
-                               <exemplarCity draft="contributed">ჰარბინი</exemplarCity>
-                       </zone>
-                       <zone type="America/Bogota">
-                               <exemplarCity draft="provisional">კოლუმბია</exemplarCity>
-                       </zone>
-                       <zone type="America/Costa_Rica">
-                               <exemplarCity draft="provisional">კოსტა რიკა</exemplarCity>
-                       </zone>
-                       <zone type="America/Havana">
-                               <exemplarCity draft="provisional">კუბა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Djibouti">
-                               <exemplarCity draft="provisional">ჯიბუტი</exemplarCity>
-                       </zone>
-                       <zone type="America/Dominica">
-                               <exemplarCity draft="provisional">დომინიკა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Algiers">
-                               <exemplarCity draft="provisional">ალჟირი</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Galapagos">
-                               <exemplarCity draft="contributed">გალაპაგოსი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Cairo">
-                               <exemplarCity draft="provisional">ეგვიპტე</exemplarCity>
-                       </zone>
-                       <zone type="Africa/El_Aaiun">
-                               <exemplarCity draft="provisional">დასავლეთი საჰარა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Asmera">
-                               <exemplarCity draft="provisional">ერითრეა</exemplarCity>
-                       </zone>
-                       <zone type="Atlantic/Canary">
-                               <exemplarCity draft="contributed">კანარი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Ceuta">
-                               <exemplarCity draft="contributed">სეუტა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Addis_Ababa">
-                               <exemplarCity draft="provisional">ეთიოპია</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Truk">
-                               <exemplarCity draft="contributed">ტრუკი</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Ponape">
-                               <exemplarCity draft="contributed">პონაპე</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Kosrae">
-                               <exemplarCity draft="contributed">კოსრაე</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Libreville">
-                               <exemplarCity draft="provisional">გაბონი</exemplarCity>
-                       </zone>
-                       <zone type="America/Grenada">
-                               <exemplarCity draft="provisional">გრენადა</exemplarCity>
-                       </zone>
-                       <zone type="America/Cayenne">
-                               <exemplarCity draft="provisional">გუიანა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Accra">
-                               <exemplarCity draft="provisional">განა</exemplarCity>
-                       </zone>
-                       <zone type="America/Thule">
-                               <exemplarCity draft="contributed">თულე</exemplarCity>
-                       </zone>
-                       <zone type="America/Scoresbysund">
-                               <exemplarCity draft="contributed">სკორსბისუნდი</exemplarCity>
-                       </zone>
-                       <zone type="America/Danmarkshavn">
-                               <exemplarCity draft="contributed">დენმარკშავნი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Banjul">
-                               <exemplarCity draft="provisional">გამბია</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Conakry">
-                               <exemplarCity draft="provisional">გინეა</exemplarCity>
-                       </zone>
-                       <zone type="America/Guadeloupe">
-                               <exemplarCity draft="provisional">გუადელუპე</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Malabo">
-                               <exemplarCity draft="provisional">ეკვატორული გვინეა</exemplarCity>
-                       </zone>
-                       <zone type="America/Guatemala">
-                               <exemplarCity draft="provisional">გუატემალა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Bissau">
-                               <exemplarCity draft="provisional">გინეა-ბისაუ</exemplarCity>
-                       </zone>
-                       <zone type="America/Guyana">
-                               <exemplarCity draft="provisional">გუიანა</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Jakarta">
-                               <exemplarCity draft="contributed">ჯაკარტა</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Pontianak">
-                               <exemplarCity draft="contributed">პონტიანაკი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Makassar">
-                               <exemplarCity draft="contributed">მაკასარი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Jayapura">
-                               <exemplarCity draft="contributed">ჯაიაპურა</exemplarCity>
-                       </zone>
-                       <zone type="America/Jamaica">
-                               <exemplarCity draft="provisional">იამაიკა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Nairobi">
-                               <exemplarCity draft="provisional">კენია</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Enderbury">
-                               <exemplarCity draft="contributed">ენდერბური</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Kiritimati">
-                               <exemplarCity draft="contributed">კირიტიმატი</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Tarawa">
-                               <exemplarCity draft="contributed">ტარაუა</exemplarCity>
-                       </zone>
-                       <zone type="America/Cayman">
-                               <exemplarCity draft="provisional">კაიმანის</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Aqtau">
-                               <exemplarCity draft="contributed">აქტაუ</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Oral">
-                               <exemplarCity draft="contributed">ორალი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Aqtobe">
-                               <exemplarCity draft="contributed">აქტობე</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Qyzylorda">
-                               <exemplarCity draft="contributed">ყიზილორდა</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Almaty">
-                               <exemplarCity draft="contributed">ალმატი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Monrovia">
-                               <exemplarCity draft="provisional">ლიბერია</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Maseru">
-                               <exemplarCity draft="provisional">ლესოთო</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Tripoli">
-                               <exemplarCity draft="provisional">ლიბია</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Casablanca">
-                               <exemplarCity draft="provisional">მაროკო</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Kwajalein">
-                               <exemplarCity draft="contributed">კვაჯალეინი</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Majuro">
-                               <exemplarCity draft="contributed">მახურო</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Bamako">
-                               <exemplarCity draft="provisional">მალი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Hovd">
-                               <exemplarCity draft="contributed">ჰოვდი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Ulaanbaatar">
-                               <exemplarCity draft="contributed">ულანბატარი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Choibalsan">
-                               <exemplarCity draft="contributed">ჩოიბალსანი</exemplarCity>
-                       </zone>
-                       <zone type="America/Martinique">
-                               <exemplarCity draft="provisional">მარტინიკი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Nouakchott">
-                               <exemplarCity draft="provisional">მავრიტანია</exemplarCity>
-                       </zone>
-                       <zone type="America/Montserrat">
-                               <exemplarCity draft="provisional">მონსერატი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Blantyre">
-                               <exemplarCity draft="provisional">მალავი</exemplarCity>
-                       </zone>
-                       <zone type="America/Tijuana">
-                               <exemplarCity draft="contributed">ტიხუანა</exemplarCity>
-                       </zone>
-                       <zone type="America/Hermosillo">
-                               <exemplarCity draft="contributed">ჰერმოსიო</exemplarCity>
-                       </zone>
-                       <zone type="America/Mazatlan">
-                               <exemplarCity draft="contributed">მაზატლანი</exemplarCity>
-                       </zone>
-                       <zone type="America/Chihuahua">
-                               <exemplarCity draft="contributed">ჩიჰუაჰუა</exemplarCity>
-                       </zone>
-                       <zone type="America/Monterrey">
-                               <exemplarCity draft="contributed">მონტერეი</exemplarCity>
-                       </zone>
-                       <zone type="America/Mexico_City">
-                               <exemplarCity draft="contributed">მექსიკო სითი</exemplarCity>
-                       </zone>
-                       <zone type="America/Merida">
-                               <exemplarCity draft="contributed">მერიდა</exemplarCity>
-                       </zone>
-                       <zone type="America/Cancun">
-                               <exemplarCity draft="contributed">კანკუნი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Kuching">
-                               <exemplarCity draft="contributed">კუჩინგი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Maputo">
-                               <exemplarCity draft="provisional">მოზამბიკი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Windhoek">
-                               <exemplarCity draft="provisional">ნამიბია</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Niamey">
-                               <exemplarCity draft="provisional">ნიგერი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Lagos">
-                               <exemplarCity draft="provisional">ნიგერია</exemplarCity>
-                       </zone>
-                       <zone type="America/Managua">
-                               <exemplarCity draft="provisional">ნიკარაგუა</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Chatham">
-                               <exemplarCity draft="contributed">ჩათამი</exemplarCity>
-                       </zone>
-                       <zone type="America/Lima">
-                               <exemplarCity draft="provisional">პერუ</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Marquesas">
-                               <exemplarCity draft="contributed">მარკეზასი</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Gambier">
-                               <exemplarCity draft="contributed">გამბიერი</exemplarCity>
-                       </zone>
-                       <zone type="America/Miquelon">
-                               <exemplarCity draft="provisional">სენტ პიერი და მიკელონი</exemplarCity>
-                       </zone>
-                       <zone type="Atlantic/Azores">
-                               <exemplarCity draft="contributed">აზორეს</exemplarCity>
-                       </zone>
-                       <zone type="Atlantic/Madeira">
-                               <exemplarCity draft="contributed">მადეირა</exemplarCity>
-                       </zone>
-                       <zone type="America/Asuncion">
-                               <exemplarCity draft="provisional">პარაგვაი</exemplarCity>
-                       </zone>
-                       <zone type="Europe/Kaliningrad">
-                               <exemplarCity draft="contributed">კალინინგრადი</exemplarCity>
-                       </zone>
-                       <zone type="Europe/Moscow">
-                               <exemplarCity draft="contributed">მოსკოვი</exemplarCity>
-                       </zone>
-                       <zone type="Europe/Volgograd">
-                               <exemplarCity draft="contributed">ვოლგოგრადი</exemplarCity>
-                       </zone>
-                       <zone type="Europe/Samara">
-                               <exemplarCity draft="contributed">სამარა</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Yekaterinburg">
-                               <exemplarCity draft="contributed">ეკატერინბურგი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Omsk">
-                               <exemplarCity draft="contributed">ომსკი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Novosibirsk">
-                               <exemplarCity draft="contributed">ნოვოსიბირსკი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Krasnoyarsk">
-                               <exemplarCity draft="contributed">კრასნოიარსკი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Irkutsk">
-                               <exemplarCity draft="contributed">ირკუტსკი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Yakutsk">
-                               <exemplarCity draft="contributed">იაკუტსკი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Vladivostok">
-                               <exemplarCity draft="contributed">ვლადივოსტოკი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Sakhalin">
-                               <exemplarCity draft="contributed">სახალინი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Magadan">
-                               <exemplarCity draft="contributed">მაგადანი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Kamchatka">
-                               <exemplarCity draft="contributed">კამჩატკა</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Anadyr">
-                               <exemplarCity draft="contributed">ანადირი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Kigali">
-                               <exemplarCity draft="provisional">რუანდა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Khartoum">
-                               <exemplarCity draft="provisional">სუდანი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Freetown">
-                               <exemplarCity draft="provisional">სიერა ლეონე</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Dakar">
-                               <exemplarCity draft="provisional">სენეგალი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Mogadishu">
-                               <exemplarCity draft="provisional">სომალია</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Sao_Tome">
-                               <exemplarCity draft="provisional">საო ტომე და პრინსიპე</exemplarCity>
-                       </zone>
-                       <zone type="America/El_Salvador">
-                               <exemplarCity draft="provisional">ელ სალვადორი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Mbabane">
-                               <exemplarCity draft="provisional">სვაზილენდი</exemplarCity>
-                       </zone>
-                       <zone type="America/Grand_Turk">
-                               <exemplarCity draft="provisional">ტერკის და კაიკოს</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Ndjamena">
-                               <exemplarCity draft="provisional">ჩადი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Lome">
-                               <exemplarCity draft="provisional">ტოგო</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Tunis">
-                               <exemplarCity draft="provisional">ტუნისი</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Dar_es_Salaam">
-                               <exemplarCity draft="provisional">ტანზანია</exemplarCity>
-                       </zone>
-                       <zone type="Europe/Uzhgorod">
-                               <exemplarCity draft="contributed">უჟგოროდი</exemplarCity>
-                       </zone>
-                       <zone type="Europe/Kiev">
-                               <exemplarCity draft="contributed">კიევი</exemplarCity>
-                       </zone>
-                       <zone type="Europe/Simferopol">
-                               <exemplarCity draft="contributed">სიმფეროპოლი</exemplarCity>
-                       </zone>
-                       <zone type="Europe/Zaporozhye">
-                               <exemplarCity draft="contributed">ზაპოროჟიე</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Kampala">
-                               <exemplarCity draft="provisional">უგანდა</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Midway">
-                               <exemplarCity draft="contributed">მიდუეი</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Johnston">
-                               <exemplarCity draft="contributed">ჯონსტონი</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Wake">
-                               <exemplarCity draft="contributed">უეიკი</exemplarCity>
-                       </zone>
-                       <zone type="America/Adak">
-                               <exemplarCity draft="contributed">ადაკი</exemplarCity>
-                       </zone>
-                       <zone type="America/Nome">
-                               <exemplarCity draft="contributed">ნომი</exemplarCity>
-                       </zone>
-                       <zone type="Pacific/Honolulu">
-                               <exemplarCity draft="contributed">ჰონოლულუ</exemplarCity>
-                       </zone>
-                       <zone type="America/Anchorage">
-                               <exemplarCity draft="contributed">ენქორაჯი</exemplarCity>
-                       </zone>
-                       <zone type="America/Yakutat">
-                               <exemplarCity draft="contributed">იაკუტატი</exemplarCity>
-                       </zone>
-                       <zone type="America/Juneau">
-                               <exemplarCity draft="contributed">ჯუნო</exemplarCity>
-                       </zone>
-                       <zone type="America/Los_Angeles">
-                               <exemplarCity draft="contributed">ლოს ანჯელესი</exemplarCity>
-                       </zone>
-                       <zone type="America/Boise">
-                               <exemplarCity draft="contributed">ბუასი</exemplarCity>
-                       </zone>
-                       <zone type="America/Phoenix">
-                               <exemplarCity draft="contributed">ფენიქსი</exemplarCity>
-                       </zone>
-                       <zone type="America/Shiprock">
-                               <exemplarCity draft="contributed">შიპროკი</exemplarCity>
-                       </zone>
-                       <zone type="America/Denver">
-                               <exemplarCity draft="contributed">დენვერი</exemplarCity>
-                       </zone>
-                       <zone type="America/North_Dakota/New_Salem">
-                               <exemplarCity draft="contributed">ნიუ სალემი, ჩრდილოეთი დაკოტა</exemplarCity>
-                       </zone>
-                       <zone type="America/North_Dakota/Center">
-                               <exemplarCity draft="contributed">ცენტრი, ჩრდილოეთი დაკოტა</exemplarCity>
-                       </zone>
-                       <zone type="America/Chicago">
-                               <exemplarCity draft="contributed">ჩიკაგო</exemplarCity>
-                       </zone>
-                       <zone type="America/Menominee">
-                               <exemplarCity draft="contributed">მენომინი</exemplarCity>
-                       </zone>
-                       <zone type="America/Indiana/Vincennes">
-                               <exemplarCity draft="contributed">ვინსენი, ინდიანა</exemplarCity>
-                       </zone>
-                       <zone type="America/Indiana/Petersburg">
-                               <exemplarCity draft="contributed">პიტერსბურგი</exemplarCity>
-                       </zone>
-                       <zone type="America/Indiana/Tell_City">
-                               <exemplarCity draft="contributed">თელ სითი, ინდიანა</exemplarCity>
-                       </zone>
-                       <zone type="America/Indiana/Knox">
-                               <exemplarCity draft="contributed">ნოქსი, ინდიანა</exemplarCity>
-                       </zone>
-                       <zone type="America/Indiana/Winamac">
-                               <exemplarCity draft="contributed">უინემაკი, ინდიანა</exemplarCity>
-                       </zone>
-                       <zone type="America/Indiana/Marengo">
-                               <exemplarCity draft="contributed">მარენგო</exemplarCity>
-                       </zone>
-                       <zone type="America/Indianapolis">
-                               <exemplarCity draft="contributed">ინდიანაპოლისი</exemplarCity>
-                       </zone>
-                       <zone type="America/Louisville">
-                               <exemplarCity draft="contributed">ლუისვილი</exemplarCity>
-                       </zone>
-                       <zone type="America/Indiana/Vevay">
-                               <exemplarCity draft="contributed">ვივეი, ინდიანა</exemplarCity>
-                       </zone>
-                       <zone type="America/Kentucky/Monticello">
-                               <exemplarCity draft="contributed">მონტიჩელო</exemplarCity>
-                       </zone>
-                       <zone type="America/Detroit">
-                               <exemplarCity draft="contributed">დეტროიტი</exemplarCity>
-                       </zone>
-                       <zone type="America/New_York">
-                               <exemplarCity draft="contributed">ნიუ იორკი</exemplarCity>
-                       </zone>
-                       <zone type="America/Montevideo">
-                               <exemplarCity draft="provisional">ურუგვაი</exemplarCity>
-                       </zone>
-                       <zone type="Asia/Samarkand">
-                               <exemplarCity draft="contributed">სამარყანდი</exemplarCity>
-                       </zone>
-                       <zone type="America/Caracas">
-                               <exemplarCity draft="provisional">ვენესუელა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Johannesburg">
-                               <exemplarCity draft="provisional">სამხრეთი აფრიკა</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Lusaka">
-                               <exemplarCity draft="provisional">ზამბია</exemplarCity>
-                       </zone>
-                       <zone type="Africa/Harare">
-                               <exemplarCity draft="provisional">ზიმბაბვე</exemplarCity>
-                       </zone>
-               </timeZoneNames>
-       </dates>
-       <numbers>
-               <symbols>
-                       <decimal draft="contributed">,</decimal>
-                       <group draft="contributed">.</group>
-                       <list draft="contributed">;</list>
-                       <percentSign draft="contributed">%</percentSign>
-                       <nativeZeroDigit draft="contributed">0</nativeZeroDigit>
-                       <plusSign draft="contributed">+</plusSign>
-                       <minusSign draft="contributed">-</minusSign>
-                       <exponential draft="contributed">E</exponential>
-                       <perMille draft="contributed">‰</perMille>
-                       <infinity draft="contributed">∞</infinity>
-                       <nan draft="contributed">NaN</nan>
-               </symbols>
-               <decimalFormats>
-                       <decimalFormatLength>
-                               <decimalFormat>
-                                       <pattern draft="provisional">#,##0.###</pattern>
-                               </decimalFormat>
-                       </decimalFormatLength>
-               </decimalFormats>
-               <percentFormats>
-                       <percentFormatLength>
-                               <percentFormat>
-                                       <pattern draft="provisional">#,##0%</pattern>
-                               </percentFormat>
-                       </percentFormatLength>
-               </percentFormats>
-               <currencyFormats>
-                       <currencyFormatLength>
-                               <currencyFormat>
-                                       <pattern draft="provisional">¤ #,##0.00</pattern>
-                               </currencyFormat>
-                       </currencyFormatLength>
-                       <unitPattern count="other" draft="contributed">{0} {1}</unitPattern>
-               </currencyFormats>
-               <currencies>
-                       <currency type="ADP">
-                               <displayName draft="contributed">ანდორული პესეტა</displayName>
-                       </currency>
-                       <currency type="AED">
-                               <displayName draft="contributed">გაერთიანებული არაბული საემიროების დირჰემი</displayName>
-                       </currency>
-                       <currency type="AFA">
-                               <displayName draft="contributed">ავღანი (1927-2002)</displayName>
-                       </currency>
-                       <currency type="AFN">
-                               <displayName draft="contributed">ავღანი</displayName>
-                       </currency>
-                       <currency type="ALL">
-                               <displayName draft="contributed">ალბანური ლეკი</displayName>
-                       </currency>
-                       <currency type="AMD">
-                               <displayName draft="contributed">სომხური დრამი</displayName>
-                       </currency>
-                       <currency type="ANG">
-                               <displayName draft="contributed">ნიდრელანდების ანტილიის გულდენი</displayName>
-                       </currency>
-                       <currency type="AOA">
-                               <displayName draft="contributed">ანგოლური კვანზა</displayName>
-                       </currency>
-                       <currency type="AOK">
-                               <displayName draft="contributed">ანგოლური კვანზა (1977-1990)</displayName>
-                       </currency>
-                       <currency type="AON">
-                               <displayName draft="contributed">ანგოლური ახალი კვანზა (1990-2000)</displayName>
-                       </currency>
-                       <currency type="AOR">
-                               <displayName draft="contributed">ანგოლური მიტოლებული კვანზა (1995-1999)</displayName>
-                       </currency>
-                       <currency type="ARA">
-                               <displayName draft="contributed">არგენტინული აუსტრალი</displayName>
-                       </currency>
-                       <currency type="ARP">
-                               <displayName draft="contributed">არგენტინული პესო (1983-1985)</displayName>
-                       </currency>
-                       <currency type="ARS">
-                               <displayName draft="contributed">არგენტინული პესო</displayName>
-                       </currency>
-                       <currency type="ATS">
-                               <displayName draft="contributed">ავსტრიული შილინგი</displayName>
-                       </currency>
-                       <currency type="AUD">
-                               <displayName draft="contributed">ავსტრალიური დოლარი</displayName>
-                       </currency>
-                       <currency type="AWG">
-                               <displayName draft="contributed">არუბანული გულდენი</displayName>
-                       </currency>
-                       <currency type="AZM">
-                               <displayName draft="contributed">აზერბაიჯანული მანათი (1993-2006)</displayName>
-                       </currency>
-                       <currency type="AZN">
-                               <displayName draft="contributed">აზერბაიჯანული მანათი</displayName>
-                       </currency>
-                       <currency type="BAD">
-                               <displayName draft="contributed">ბოსნია-ჰერცოგოვინას დინარი</displayName>
-                       </currency>
-                       <currency type="BAM">
-                               <displayName draft="contributed">ბოსნია-ჰერცოგოვინას კონვერტირებადი მარკა</displayName>
-                       </currency>
-                       <currency type="BBD">
-                               <displayName draft="contributed">ბარბადოსული დოლარი</displayName>
-                       </currency>
-                       <currency type="BDT">
-                               <displayName draft="contributed">ბანგლადეშური ტაკა</displayName>
-                       </currency>
-                       <currency type="BEC">
-                               <displayName draft="contributed">ბელგიური ფრანკი (კოვერტირებადი)</displayName>
-                       </currency>
-                       <currency type="BEF">
-                               <displayName draft="contributed">ბელგიური ფრანკი</displayName>
-                       </currency>
-                       <currency type="BEL">
-                               <displayName draft="contributed">ბელგიური ფრანკი (ფინანსური)</displayName>
-                       </currency>
-                       <currency type="BGL">
-                               <displayName draft="contributed">ბულგარული მყარი ლევი</displayName>
-                       </currency>
-                       <currency type="BGN">
-                               <displayName draft="contributed">ბულგარული ახალი ლევი</displayName>
-                       </currency>
-                       <currency type="BHD">
-                               <displayName draft="contributed">ბაჰრეინული დინარი</displayName>
-                       </currency>
-                       <currency type="BIF">
-                               <displayName draft="contributed">ბურუნდიული ფრანკი</displayName>
-                       </currency>
-                       <currency type="BMD">
-                               <displayName draft="contributed">ბერმუდული დინარი</displayName>
-                       </currency>
-                       <currency type="BND">
-                               <displayName draft="contributed">ბრუნეული დოლარი</displayName>
-                       </currency>
-                       <currency type="BOB">
-                               <displayName draft="contributed">ბოლივიანო</displayName>
-                       </currency>
-                       <currency type="BOP">
-                               <displayName draft="contributed">ბოლივიური პესო</displayName>
-                       </currency>
-                       <currency type="BRB">
-                               <displayName draft="contributed">ბრაზილიური კრუზეირო ნოვო (1967-1986)</displayName>
-                       </currency>
-                       <currency type="BRC">
-                               <displayName draft="contributed">ბრაზილიური კრუზადო</displayName>
-                       </currency>
-                       <currency type="BRE">
-                               <displayName draft="contributed">ბრაზილიური კრუზეირო (1990-1993)</displayName>
-                       </currency>
-                       <currency type="BRL">
-                               <displayName draft="contributed">ბრაზილიური რეალი</displayName>
-                       </currency>
-                       <currency type="BRN">
-                               <displayName draft="contributed">ბრაზილიური კრუზადო ნოვო</displayName>
-                       </currency>
-                       <currency type="BRR">
-                               <displayName draft="contributed">ბრაზილიური კრუზეირო</displayName>
-                       </currency>
-                       <currency type="BSD">
-                               <displayName draft="contributed">ბაჰამური დოლარი</displayName>
-                       </currency>
-                       <currency type="BWP">
-                               <displayName draft="contributed">ბოტსვანიური პულა</displayName>
-                       </currency>
-                       <currency type="BYB">
-                               <displayName draft="contributed">ახალი ბელარუსიული რუბლი (1994-1999)</displayName>
-                       </currency>
-                       <currency type="BYR">
-                               <displayName draft="contributed">ბელარუსიული რუბლი</displayName>
-                       </currency>
-                       <currency type="CAD">
-                               <displayName draft="contributed">კანადური დოლარი</displayName>
-                       </currency>
-                       <currency type="CHF">
-                               <displayName draft="contributed">შვეიცარიული ფრანკი</displayName>
-                       </currency>
-                       <currency type="CNY">
-                               <displayName draft="contributed">ჩინური უანი</displayName>
-                       </currency>
-                       <currency type="CRC">
-                               <displayName draft="contributed">კოსტა რიკული კოლონი</displayName>
-                       </currency>
-                       <currency type="CSD">
-                               <displayName draft="contributed">ძველი სერბიული დინარი</displayName>
-                       </currency>
-                       <currency type="CSK">
-                               <displayName draft="contributed">ჩეხოსლოვაკიის მყარი კრონა</displayName>
-                       </currency>
-                       <currency type="CUP">
-                               <displayName draft="contributed">კუბური პესო</displayName>
-                       </currency>
-                       <currency type="CVE">
-                               <displayName draft="contributed">კაბო ვერდეს ესკუდო</displayName>
-                       </currency>
-                       <currency type="CYP">
-                               <displayName draft="contributed">კვიპროსის გირვანქა</displayName>
-                       </currency>
-                       <currency type="CZK">
-                               <displayName draft="contributed">ჩეხური კრონა</displayName>
-                       </currency>
-                       <currency type="DDM">
-                               <displayName draft="contributed">აღმოსავლეთ გერმანული მარკა</displayName>
-                       </currency>
-                       <currency type="DEM">
-                               <displayName draft="contributed">გერმანული მარკა</displayName>
-                       </currency>
-                       <currency type="DJF">
-                               <displayName draft="contributed">ჯიბუტის ფრანკი</displayName>
-                       </currency>
-                       <currency type="DKK">
-                               <displayName draft="contributed">დანიური კრონა</displayName>
-                       </currency>
-                       <currency type="DOP">
-                               <displayName draft="contributed">დომინიკური პესო</displayName>
-                       </currency>
-                       <currency type="DZD">
-                               <displayName draft="contributed">ალჟირიული დინარი</displayName>
-                       </currency>
-                       <currency type="EEK">
-                               <displayName draft="contributed">ესტონური კრუნა</displayName>
-                       </currency>
-                       <currency type="EGP">
-                               <displayName draft="contributed">ეგვიპტური გირვანქა</displayName>
-                       </currency>
-                       <currency type="ESP">
-                               <displayName draft="contributed">ესპანური პესეტა</displayName>
-                       </currency>
-                       <currency type="EUR">
-                               <displayName draft="contributed">ევრო</displayName>
-                       </currency>
-                       <currency type="FIM">
-                               <displayName draft="contributed">ფინური მარკა</displayName>
-                       </currency>
-                       <currency type="FJD">
-                               <displayName draft="contributed">ფიჯი დოლარი</displayName>
-                       </currency>
-                       <currency type="FRF">
-                               <displayName draft="contributed">ფრანგული ფრანკი</displayName>
-                       </currency>
-                       <currency type="GBP">
-                               <displayName draft="contributed">ინგლისური გირვანქა სტერლინგი</displayName>
-                       </currency>
-                       <currency type="GEK">
-                               <displayName draft="contributed">ქართული კუპონი ლარით</displayName>
-                       </currency>
-                       <currency type="GEL">
-                               <displayName draft="contributed">ქართული ლარი</displayName>
-                       </currency>
-                       <currency type="GRD">
-                               <displayName draft="contributed">ბერძნული დრაჰმა</displayName>
-                       </currency>
-                       <currency type="GWE">
-                               <displayName draft="contributed">პორტუგალიური გინეა ესკუდო</displayName>
-                       </currency>
-                       <currency type="HKD">
-                               <displayName draft="contributed">ჰონგ კონგის დოლარი</displayName>
-                       </currency>
-                       <currency type="HNL">
-                               <displayName draft="contributed">ჰონდურასის ლემპირა</displayName>
-                       </currency>
-                       <currency type="HRD">
-                               <displayName draft="contributed">ხორვატიული დინარი</displayName>
-                       </currency>
-                       <currency type="HRK">
-                               <displayName draft="contributed">ხორვატიული კუნა</displayName>
-                       </currency>
-                       <currency type="HUF">
-                               <displayName draft="contributed">უნგრული ფორინტი</displayName>
-                       </currency>
-                       <currency type="IDR">
-                               <displayName draft="contributed">ინდონეზიური რუპია</displayName>
-                       </currency>
-                       <currency type="IEP">
-                               <displayName draft="contributed">ირლანდიური გირვანქა</displayName>
-                       </currency>
-                       <currency type="INR">
-                               <displayName draft="contributed">ინდური რუპია</displayName>
-                       </currency>
-                       <currency type="ISK">
-                               <displayName draft="contributed">ისლანდიური კრონა</displayName>
-                       </currency>
-                       <currency type="ITL">
-                               <displayName draft="contributed">იტალიური ლირა</displayName>
-                       </currency>
-                       <currency type="JMD">
-                               <displayName draft="contributed">იამაიკური დოლარი</displayName>
-                       </currency>
-                       <currency type="JOD">
-                               <displayName draft="contributed">იორდანიული დოლარი</displayName>
-                       </currency>
-                       <currency type="JPY">
-                               <displayName draft="contributed">იაპონური იენი</displayName>
-                       </currency>
-                       <currency type="KES">
-                               <displayName draft="contributed">კენიური შილინგი</displayName>
-                       </currency>
-                       <currency type="KGS">
-                               <displayName draft="contributed">ყირღიზული სომი</displayName>
-                       </currency>
-                       <currency type="KPW">
-                               <displayName draft="contributed">ჩრდილოეთ კორეული ვონი</displayName>
-                       </currency>
-                       <currency type="KRW">
-                               <displayName draft="contributed">სამხრეთ კორეული ვონი</displayName>
-                       </currency>
-                       <currency type="KWD">
-                               <displayName draft="contributed">კუვეიტური დინარი</displayName>
-                       </currency>
-                       <currency type="KYD">
-                               <displayName draft="contributed">კაიმანის კუნძულების დოლარი</displayName>
-                       </currency>
-                       <currency type="KZT">
-                               <displayName draft="contributed">ყაზახური ტენგე</displayName>
-                       </currency>
-                       <currency type="LKR">
-                               <displayName draft="contributed">შრი ლანკის რუპია</displayName>
-                       </currency>
-                       <currency type="LRD">
-                               <displayName draft="contributed">ლიბერიული დოლარი</displayName>
-                       </currency>
-                       <currency type="LTL">
-                               <displayName draft="contributed">ლიტვური ლიტა</displayName>
-                       </currency>
-                       <currency type="LTT">
-                               <displayName draft="contributed">ლიტვური ტალონი</displayName>
-                       </currency>
-                       <currency type="LUC">
-                               <displayName draft="contributed">ლუქსემბურგის კონვერტირებადი ფრანკი</displayName>
-                       </currency>
-                       <currency type="LUF">
-                               <displayName draft="contributed">ლუქსემბურგის ფრანკი</displayName>
-                       </currency>
-                       <currency type="LUL">
-                               <displayName draft="contributed">ლუქსემბურგის ფინანსური ფრანკი</displayName>
-                       </currency>
-                       <currency type="LVL">
-                               <displayName draft="contributed">ლატვიური ლატი</displayName>
-                       </currency>
-                       <currency type="LVR">
-                               <displayName draft="contributed">ლატვიური რუბლი</displayName>
-                       </currency>
-                       <currency type="LYD">
-                               <displayName draft="contributed">ლიბიური დინარი</displayName>
-                       </currency>
-                       <currency type="MAD">
-                               <displayName draft="contributed">მაროკოს დირჰამი</displayName>
-                       </currency>
-                       <currency type="MAF">
-                               <displayName draft="contributed">მაროკოს ფრანკი</displayName>
-                       </currency>
-                       <currency type="MDL">
-                               <displayName draft="contributed">მოლდოვური ლეუ</displayName>
-                       </currency>
-                       <currency type="MGA">
-                               <displayName draft="contributed">მადაგასკარის არიარი</displayName>
-                       </currency>
-                       <currency type="MGF">
-                               <displayName draft="contributed">მადაგასკარის ფრანკი</displayName>
-                       </currency>
-                       <currency type="MKD">
-                               <displayName draft="contributed">მაკედონიური დენარი</displayName>
-                       </currency>
-                       <currency type="MLF">
-                               <displayName draft="contributed">მალის ფრანკი</displayName>
-                       </currency>
-                       <currency type="MMK">
-                               <displayName draft="contributed">მიანმარის კიატი</displayName>
-                       </currency>
-                       <currency type="MNT">
-                               <displayName draft="contributed">მონღოლური ტუგრიკი</displayName>
-                       </currency>
-                       <currency type="MTL">
-                               <displayName draft="contributed">მალტის ლირა</displayName>
-                       </currency>
-                       <currency type="MTP">
-                               <displayName draft="contributed">მალტის გირვანქა</displayName>
-                       </currency>
-                       <currency type="MUR">
-                               <displayName draft="contributed">მავრიტანული რუპია</displayName>
-                       </currency>
-                       <currency type="MVR">
-                               <displayName draft="contributed">მალდივური რუფია</displayName>
-                       </currency>
-                       <currency type="MWK">
-                               <displayName draft="contributed">მალავის კვანჩა</displayName>
-                       </currency>
-                       <currency type="MXN">
-                               <displayName draft="contributed">მექსიკური პესო</displayName>
-                       </currency>
-                       <currency type="MXP">
-                               <displayName draft="contributed">მექსიკური ვერცხლის პესო (1861-1992)</displayName>
-                       </currency>
-                       <currency type="MYR">
-                               <displayName draft="contributed">მალაიზიური რინგიტი</displayName>
-                       </currency>
-                       <currency type="MZE">
-                               <displayName draft="contributed">მოზამბიკური ესკუდო</displayName>
-                       </currency>
-                       <currency type="MZM">
-                               <displayName draft="contributed">ძველი მოზამბიკური მეტიკალი</displayName>
-                       </currency>
-                       <currency type="MZN">
-                               <displayName draft="contributed">მოზამბიკური მეტიკალი</displayName>
-                       </currency>
-                       <currency type="NAD">
-                               <displayName draft="contributed">ნამიბიური დოლარი</displayName>
-                       </currency>
-                       <currency type="NGN">
-                               <displayName draft="contributed">ნიგერიული ნაირა</displayName>
-                       </currency>
-                       <currency type="NIC">
-                               <displayName draft="contributed">ნიკარაგუას კორდობა</displayName>
-                       </currency>
-                       <currency type="NIO">
-                               <displayName draft="contributed">ნიკარაგუას ოქროს კორდობა</displayName>
-                       </currency>
-                       <currency type="NLG">
-                               <displayName draft="contributed">ჰოლანდიური გულდენი</displayName>
-                       </currency>
-                       <currency type="NOK">
-                               <displayName draft="contributed">ნორვეგიული კრონა</displayName>
-                       </currency>
-                       <currency type="NPR">
-                               <displayName draft="contributed">ნეპალური რუპია</displayName>
-                       </currency>
-                       <currency type="NZD">
-                               <displayName draft="contributed">ახალი ზელანდიის დოლარი</displayName>
-                       </currency>
-                       <currency type="OMR">
-                               <displayName draft="contributed">ომანის რეალი</displayName>
-                       </currency>
-                       <currency type="PEI">
-                               <displayName draft="contributed">პერუს ინტი</displayName>
-                       </currency>
-                       <currency type="PEN">
-                               <displayName draft="contributed">პერუს ახალი სოლი</displayName>
-                       </currency>
-                       <currency type="PES">
-                               <displayName draft="contributed">პერუს სოლი</displayName>
-                       </currency>
-                       <currency type="PHP">
-                               <displayName draft="contributed">ფილიპინური პესო</displayName>
-                       </currency>
-                       <currency type="PKR">
-                               <displayName draft="contributed">პაკისტანური რუპია</displayName>
-                       </currency>
-                       <currency type="PLN">
-                               <displayName draft="contributed">პოლონური ზლოტი</displayName>
-                       </currency>
-                       <currency type="PLZ">
-                               <displayName draft="contributed">პოლონური ზლოტი (1950-1995)</displayName>
-                       </currency>
-                       <currency type="PTE">
-                               <displayName draft="contributed">პორტუგალიური ესკუდო</displayName>
-                       </currency>
-                       <currency type="QAR">
-                               <displayName draft="contributed">კატარის რიალი</displayName>
-                       </currency>
-                       <currency type="RHD">
-                               <displayName draft="contributed">როდეზიული დოლარი</displayName>
-                       </currency>
-                       <currency type="ROL">
-                               <displayName draft="contributed">ძველი რუმინული ლეუ</displayName>
-                       </currency>
-                       <currency type="RON">
-                               <displayName draft="contributed">რუმინული ლეუ</displayName>
-                       </currency>
-                       <currency type="RUB">
-                               <displayName draft="contributed">რუსული რუბლი</displayName>
-                       </currency>
-                       <currency type="RUR">
-                               <displayName draft="contributed">რუსული რუბლი (1991-1998)</displayName>
-                       </currency>
-                       <currency type="RWF">
-                               <displayName draft="contributed">რუანდული ფრანკი</displayName>
-                       </currency>
-                       <currency type="SCR">
-                               <displayName draft="contributed">სეიშელის რუპია</displayName>
-                       </currency>
-                       <currency type="SDD">
-                               <displayName draft="contributed">სუდანის დინარი</displayName>
-                       </currency>
-                       <currency type="SDP">
-                               <displayName draft="contributed">სუდანის გირვანქა</displayName>
-                       </currency>
-                       <currency type="SEK">
-                               <displayName draft="contributed">შვედური კრონა</displayName>
-                       </currency>
-                       <currency type="SGD">
-                               <displayName draft="contributed">სინგაპურის დოლარი</displayName>
-                       </currency>
-                       <currency type="SLL">
-                               <displayName draft="contributed">სიერა ლეონეს ლეონე</displayName>
-                       </currency>
-                       <currency type="SRD">
-                               <displayName draft="contributed">სურინამის დოლარი</displayName>
-                       </currency>
-                       <currency type="SRG">
-                               <displayName draft="contributed">სურინამის გულდენი</displayName>
-                       </currency>
-                       <currency type="SUR">
-                               <displayName draft="contributed">საბჭოთა რუბლი</displayName>
-                       </currency>
-                       <currency type="SYP">
-                               <displayName draft="contributed">სირიული გირვანქა</displayName>
-                       </currency>
-                       <currency type="TJR">
-                               <displayName draft="contributed">ტაჯიკური რუბლი</displayName>
-                       </currency>
-                       <currency type="TJS">
-                               <displayName draft="contributed">ტაჯიკური სომონი</displayName>
-                       </currency>
-                       <currency type="TMM">
-                               <displayName draft="contributed">თურქმენული მანათი</displayName>
-                       </currency>
-                       <currency type="TND">
-                               <displayName draft="contributed">ტუნისიური დინარი</displayName>
-                       </currency>
-                       <currency type="TRL">
-                               <displayName draft="contributed">თურქული ლირა</displayName>
-                       </currency>
-                       <currency type="TRY">
-                               <displayName draft="contributed">ახალი თურქული ლირა</displayName>
-                       </currency>
-                       <currency type="TTD">
-                               <displayName draft="contributed">ტრინიდად და ტობაგოს დოლარი</displayName>
-                       </currency>
-                       <currency type="TWD">
-                               <displayName draft="contributed">ტაივანური ახალი დოლარი</displayName>
-                       </currency>
-                       <currency type="TZS">
-                               <displayName draft="contributed">ტანზანიური შილინგი</displayName>
-                       </currency>
-                       <currency type="UAH">
-                               <displayName draft="contributed">უკრაინული გრივნა</displayName>
-                       </currency>
-                       <currency type="UAK">
-                               <displayName draft="contributed">უკრაინული კარბოვანეცი</displayName>
-                       </currency>
-                       <currency type="UGS">
-                               <displayName draft="contributed">უგანდური შილინგი (1966-1987)</displayName>
-                       </currency>
-                       <currency type="UGX">
-                               <displayName draft="contributed">უგანდური შილინგი</displayName>
-                       </currency>
-                       <currency type="USD">
-                               <displayName draft="contributed">აშშ დოლარი</displayName>
-                       </currency>
-                       <currency type="USN">
-                               <displayName draft="contributed">აშშ დოლარი (შემდეგი დღე)</displayName>
-                       </currency>
-                       <currency type="USS">
-                               <displayName draft="contributed">აშშ დოლარი (იგივე დღე)</displayName>
-                       </currency>
-                       <currency type="UYP">
-                               <displayName draft="contributed">ურუგვაის პესო (1975-1993)</displayName>
-                       </currency>
-                       <currency type="UYU">
-                               <displayName draft="contributed">ურუგვაის პესო ურუგვაიო</displayName>
-                       </currency>
-                       <currency type="UZS">
-                               <displayName draft="contributed">უზბეკური სუმი</displayName>
-                       </currency>
-                       <currency type="VEB">
-                               <displayName draft="contributed">ვენესუელის ბოლივარი</displayName>
-                       </currency>
-                       <currency type="VND">
-                               <displayName draft="contributed">ვიეტნამური დონგი</displayName>
-                       </currency>
-                       <currency type="VUV">
-                               <displayName draft="contributed">ვანატუს ვატუ</displayName>
-                       </currency>
-                       <currency type="WST">
-                               <displayName draft="contributed">დასავლეთ სამოას ტალა</displayName>
-                       </currency>
-                       <currency type="XAG">
-                               <displayName draft="contributed">ვერცხლი</displayName>
-                       </currency>
-                       <currency type="XBA">
-                               <displayName draft="contributed">ევროპული კომპპოზიტური ერთეული</displayName>
-                       </currency>
-                       <currency type="XBB">
-                               <displayName draft="contributed">ევროპული ფულადი ერთეული</displayName>
-                       </currency>
-                       <currency type="XCD">
-                               <displayName draft="contributed">აღმოსავლეთ კარიბიული დოლარი</displayName>
-                       </currency>
-                       <currency type="XEU">
-                               <displayName draft="contributed">ევროპული სავალუტო ერთეული</displayName>
-                       </currency>
-                       <currency type="XFO">
-                               <displayName draft="contributed">ფრანგული ოქროს ფრანკი</displayName>
-                       </currency>
-                       <currency type="XXX">
-                               <displayName draft="contributed">უცნობი ან არასწორი ვალუტა</displayName>
-                       </currency>
-                       <currency type="YDD">
-                               <displayName draft="contributed">იემენის დინარი</displayName>
-                       </currency>
-                       <currency type="YER">
-                               <displayName draft="contributed">იემენის რეალი</displayName>
-                       </currency>
-                       <currency type="YUD">
-                               <displayName draft="contributed">იუგოსლავიური მყარი დინარი</displayName>
-                       </currency>
-                       <currency type="YUM">
-                               <displayName draft="contributed">იუგოსლავიური ახალი დინარი</displayName>
-                       </currency>
-                       <currency type="YUN">
-                               <displayName draft="contributed">იუგოსლავიური კონვერტირებადი დინარი</displayName>
-                       </currency>
-                       <currency type="ZMK">
-                               <displayName draft="contributed">ზამბიური კვანჩა</displayName>
-                       </currency>
-                       <currency type="ZRN">
-                               <displayName draft="contributed">ზაირის ახალი ზაირი</displayName>
-                       </currency>
-                       <currency type="ZRZ">
-                               <displayName draft="contributed">ზაირის ზაირი</displayName>
-                       </currency>
-                       <currency type="ZWD">
-                               <displayName draft="contributed">ზიმბაბვეს დოლარი</displayName>
-                       </currency>
-               </currencies>
-       </numbers>
-       <units>
-               <unit type="day">
-                       <unitPattern count="other" draft="contributed">{0} დღე</unitPattern>
-               </unit>
-               <unit type="hour">
-                       <unitPattern count="other" draft="contributed">{0} საათი</unitPattern>
-               </unit>
-               <unit type="minute">
-                       <unitPattern count="other" draft="contributed">{0} წუთი</unitPattern>
-               </unit>
-               <unit type="month">
-                       <unitPattern count="other" draft="contributed">{0} თვე</unitPattern>
-               </unit>
-               <unit type="second">
-                       <unitPattern count="other" draft="contributed">{0} წამი</unitPattern>
-               </unit>
-               <unit type="week">
-                       <unitPattern count="other" draft="contributed">{0} კვირა</unitPattern>
-               </unit>
-               <unit type="year">
-                       <unitPattern count="other" draft="contributed">{0} წელი</unitPattern>
-               </unit>
-       </units>
-       <posix>
-               <messages>
-                       <yesstr draft="contributed">დიახ</yesstr>
-                       <nostr draft="contributed">არა</nostr>
-               </messages>
-       </posix>
-</ldml>
diff --git a/tools/locale-builder/langs/nb.xml b/tools/locale-builder/langs/nb.xml
deleted file mode 100644 (file)
index 7773462..0000000
+++ /dev/null
@@ -1,1893 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>\r
-<!DOCTYPE ldml SYSTEM "http://www.unicode.org/cldr/dtd/1.3/ldml.dtd">\r
-<ldml>\r
-       <identity>\r
-               <version number="$Revision: 1.50 $"/>\r
-               <generation date="$Date: 2005/05/24 21:21:38 $"/>\r
-               <language type="nb"/>\r
-       </identity>\r
-       <localeDisplayNames>\r
-               <languages>\r
-                       <language type="aa">afar</language>\r
-                       <language type="ab">abkhasisk</language>\r
-                       <language type="ace">achinesisk</language>\r
-                       <language type="ach">acoli</language>\r
-                       <language type="ada">adangme</language>\r
-                       <language type="ady">adyghe</language>\r
-                       <language type="ae">avestisk</language>\r
-                       <language type="af">afrikaans</language>\r
-                       <language type="afa">afroasiatisk (annet)</language>\r
-                       <language type="afh">afrihili</language>\r
-                       <language type="ak">akan</language>\r
-                       <language type="akk">akkadisk</language>\r
-                       <language type="ale">aleutisk</language>\r
-                       <language type="alg">algonkinsk språk</language>\r
-                       <language type="am">amharisk</language>\r
-                       <language type="an">aragonsk</language>\r
-                       <language type="ang">gammelengelsk (ca. 450-1100)</language>\r
-                       <language type="apa">apache-språk</language>\r
-                       <language type="ar">arabisk</language>\r
-                       <language type="arc">arameisk</language>\r
-                       <language type="arn">araukansk</language>\r
-                       <language type="arp">arapaho</language>\r
-                       <language type="art">kunstig (annet)</language>\r
-                       <language type="arw">arawak</language>\r
-                       <language type="as">assamisk</language>\r
-                       <language type="ast">asturisk</language>\r
-                       <language type="ath">athapaskansk språk</language>\r
-                       <language type="aus">australsk språk</language>\r
-                       <language type="av">avarisk</language>\r
-                       <language type="awa">awadhi</language>\r
-                       <language type="ay">aymara</language>\r
-                       <language type="az">aserbajdsjansk</language>\r
-                       <language type="ba">basjkirsk</language>\r
-                       <language type="bad">banda</language>\r
-                       <language type="bai">bamilekisk språk</language>\r
-                       <language type="bal">baluchi</language>\r
-                       <language type="ban">balinesisk</language>\r
-                       <language type="bas">basa</language>\r
-                       <language type="bat">baltisk (annet)</language>\r
-                       <language type="be">hviterussisk</language>\r
-                       <language type="bej">beja</language>\r
-                       <language type="bem">bemba</language>\r
-                       <language type="ber">berbisk (annet)</language>\r
-                       <language type="bg">bulgarsk</language>\r
-                       <language type="bh">bihari</language>\r
-                       <language type="bho">bhojpuri</language>\r
-                       <language type="bi">bislama</language>\r
-                       <language type="bik">bikol</language>\r
-                       <language type="bin">bini</language>\r
-                       <language type="bla">siksika</language>\r
-                       <language type="bm">bambara</language>\r
-                       <language type="bn">bengali</language>\r
-                       <language type="bnt">bantu</language>\r
-                       <language type="bo">tibetansk</language>\r
-                       <language type="br">bretonsk</language>\r
-                       <language type="bra">braj</language>\r
-                       <language type="bs">bosnisk</language>\r
-                       <language type="btk">batak (Indonesia)</language>\r
-                       <language type="bua">buriat</language>\r
-                       <language type="bug">buginesisk</language>\r
-                       <language type="byn">blin</language>\r
-                       <language type="ca">katalansk</language>\r
-                       <language type="cad">caddo</language>\r
-                       <language type="cai">sentralamerikansk indiansk (annet)</language>\r
-                       <language type="car">karibisk</language>\r
-                       <language type="cau">kaukasisk (annet)</language>\r
-                       <language type="ce">tsjetsjensk</language>\r
-                       <language type="ceb">cebuansk</language>\r
-                       <language type="cel">keltisk (annet)</language>\r
-                       <language type="ch">chamorro</language>\r
-                       <language type="chb">chibcha</language>\r
-                       <language type="chg">chagatai</language>\r
-                       <language type="chk">chuukesisk</language>\r
-                       <language type="chm">mari</language>\r
-                       <language type="chn">chinook</language>\r
-                       <language type="cho">choctaw</language>\r
-                       <language type="chp">chipewiansk</language>\r
-                       <language type="chr">cherokee</language>\r
-                       <language type="chy">cheyenne</language>\r
-                       <language type="cmc">kamisk språk</language>\r
-                       <language type="co">korsikansk</language>\r
-                       <language type="cop">koptisk</language>\r
-                       <language type="cpe">kreolsk og pidgin, engelskbasert (annet)</language>\r
-                       <language type="cpf">kreolsk og pidgin, franskbasert (annet)</language>\r
-                       <language type="cpp">kreolsk og pidgin, portugisiskbasert (annet)</language>\r
-                       <language type="cr">cree</language>\r
-                       <language type="crh">krimtatarisk</language>\r
-                       <language type="crp">kreolsk og pidgin (annet)</language>\r
-                       <language type="cs">tsjekkisk</language>\r
-                       <language type="csb">kasjubisk</language>\r
-                       <language type="cu">kirkeslavisk</language>\r
-                       <language type="cus">kusjitisk (annet)</language>\r
-                       <language type="cv">tsjuvansk</language>\r
-                       <language type="cy">walisisk</language>\r
-                       <language type="da">dansk</language>\r
-                       <language type="dak">dakota</language>\r
-                       <language type="dar">dargwa</language>\r
-                       <language type="day">dayak</language>\r
-                       <language type="de">tysk</language>\r
-                       <language type="del">delaware</language>\r
-                       <language type="den">slavisk (athapaskansk)</language>\r
-                       <language type="dgr">dogrib</language>\r
-                       <language type="din">dinka</language>\r
-                       <language type="doi">dogri</language>\r
-                       <language type="dra">dravidisk (annet)</language>\r
-                       <language type="dsb">lavsorbisk</language>\r
-                       <language type="dua">duala</language>\r
-                       <language type="dum">mellomnederlandsk (ca. 1050-1350)</language>\r
-                       <language type="dv">divehi</language>\r
-                       <language type="dyu">dyula</language>\r
-                       <language type="dz">dzongkha</language>\r
-                       <language type="ee">ewe</language>\r
-                       <language type="efi">efik</language>\r
-                       <language type="egy">egyptisk (historisk)</language>\r
-                       <language type="eka">ekajuk</language>\r
-                       <language type="el">gresk</language>\r
-                       <language type="elx">elamittisk</language>\r
-                       <language type="en">engelsk</language>\r
-                       <language type="enm">mellomengelsk (1100-1500)</language>\r
-                       <language type="eo">esperanto</language>\r
-                       <language type="es">spansk</language>\r
-                       <language type="et">estisk</language>\r
-                       <language type="eu">baskisk</language>\r
-                       <language type="ewo">ewondo</language>\r
-                       <language type="fa">persisk</language>\r
-                       <language type="fan">fang</language>\r
-                       <language type="fat">fanti</language>\r
-                       <language type="ff">fulani</language>\r
-                       <language type="fi">finsk</language>\r
-                       <language type="fiu">finsk-ugrisk (annet)</language>\r
-                       <language type="fj">fijiansk</language>\r
-                       <language type="fo">færøysk</language>\r
-                       <language type="fr">fransk</language>\r
-                       <language type="frm">mellomfransk (ca.1400-1600)</language>\r
-                       <language type="fro">gammelfransk (842 til ca.1400)</language>\r
-                       <language type="fur">friuliansk</language>\r
-                       <language type="fy">frisisk</language>\r
-                       <language type="ga">irsk</language>\r
-                       <language type="gaa">ga</language>\r
-                       <language type="gay">gayo</language>\r
-                       <language type="gba">gbaya</language>\r
-                       <language type="gd">skotsk gælisk</language>\r
-                       <language type="gem">germansk (annet)</language>\r
-                       <language type="gez">ges</language>\r
-                       <language type="gil">kiribatisk; gilbertesisk</language>\r
-                       <language type="gl">galicisk</language>\r
-                       <language type="gmh">mellomhøytysk (ca.1050-1500)</language>\r
-                       <language type="gn">guarani</language>\r
-                       <language type="goh">gammelhøytysk (ca.750-1050)</language>\r
-                       <language type="gon">gondi</language>\r
-                       <language type="gor">gorontalo</language>\r
-                       <language type="got">gotisk</language>\r
-                       <language type="grb">grebo</language>\r
-                       <language type="grc">gammelgresk (til 1453)</language>\r
-                       <language type="gu">gujarati</language>\r
-                       <language type="gv">manx</language>\r
-                       <language type="gwi">gwichʼin</language>\r
-                       <language type="hai">haida</language>\r
-                       <language type="haw">hawaiisk</language>\r
-                       <language type="he">hebraisk</language>\r
-                       <language type="hi">hindi</language>\r
-                       <language type="hil">hiligaynon</language>\r
-                       <language type="him">himachali</language>\r
-                       <language type="hit">hettittisk</language>\r
-                       <language type="hmn">hmong</language>\r
-                       <language type="ho">hiri motu</language>\r
-                       <language type="hr">kroatisk</language>\r
-                       <language type="hsb">høysorbisk</language>\r
-                       <language type="ht">haitisk</language>\r
-                       <language type="hu">ungarsk</language>\r
-                       <language type="hup">hupa</language>\r
-                       <language type="hy">armensk</language>\r
-                       <language type="hz">herero</language>\r
-                       <language type="ia">interlingua</language>\r
-                       <language type="iba">iban</language>\r
-                       <language type="id">indonesisk</language>\r
-                       <language type="ie">interlingue</language>\r
-                       <language type="ig">ibo</language>\r
-                       <language type="ii">sichuan-yi</language>\r
-                       <language type="ik">unupiak</language>\r
-                       <language type="ilo">iloko</language>\r
-                       <language type="inc">indisk (annet)</language>\r
-                       <language type="ine">indoeuropeisk (annet)</language>\r
-                       <language type="inh">ingusjisk</language>\r
-                       <language type="io">ido</language>\r
-                       <language type="ira">iransk</language>\r
-                       <language type="iro">irokansk språk</language>\r
-                       <language type="is">islandsk</language>\r
-                       <language type="it">italiensk</language>\r
-                       <language type="iu">inuktitut</language>\r
-                       <language type="ja">japansk</language>\r
-                       <language type="jbo">lojban</language>\r
-                       <language type="jpr">jødepersisk</language>\r
-                       <language type="jrb">jødearabisk</language>\r
-                       <language type="jv">javanesisk</language>\r
-                       <language type="ka">georgisk</language>\r
-                       <language type="kaa">karakalpakisk</language>\r
-                       <language type="kab">kabylsk</language>\r
-                       <language type="kac">kachin</language>\r
-                       <language type="kam">kamba</language>\r
-                       <language type="kar">karensk</language>\r
-                       <language type="kaw">kawi</language>\r
-                       <language type="kbd">kabardisk</language>\r
-                       <language type="kg">kikongo</language>\r
-                       <language type="kha">khasi</language>\r
-                       <language type="khi">khoisan (annet)</language>\r
-                       <language type="kho">khotanesisk</language>\r
-                       <language type="ki">kikuyu</language>\r
-                       <language type="kj">kuanyama</language>\r
-                       <language type="kk">kasakhisk</language>\r
-                       <language type="kl">kalaallisut</language>\r
-                       <language type="km">khmer</language>\r
-                       <language type="kmb">kimbundu</language>\r
-                       <language type="kn">kannada</language>\r
-                       <language type="ko">koreansk</language>\r
-                       <language type="kok">konkani</language>\r
-                       <language type="kos">kosraeansk</language>\r
-                       <language type="kpe">kpelle</language>\r
-                       <language type="kr">kanuri</language>\r
-                       <language type="krc">karachay-balkar</language>\r
-                       <language type="kro">kru</language>\r
-                       <language type="kru">kurukh</language>\r
-                       <language type="ks">kasjmiri</language>\r
-                       <language type="ku">kurdisk</language>\r
-                       <language type="kum">kumyk</language>\r
-                       <language type="kut">kutenai</language>\r
-                       <language type="kv">komi</language>\r
-                       <language type="kw">kornisk</language>\r
-                       <language type="ky">kirgisisk</language>\r
-                       <language type="la">latin</language>\r
-                       <language type="lad">ladinsk</language>\r
-                       <language type="lah">lahnda</language>\r
-                       <language type="lam">lamba</language>\r
-                       <language type="lb">luxemburgsk</language>\r
-                       <language type="lez">lezghian</language>\r
-                       <language type="lg">ganda</language>\r
-                       <language type="li">limburgisk</language>\r
-                       <language type="ln">lingala</language>\r
-                       <language type="lo">laotisk</language>\r
-                       <language type="lol">mongo</language>\r
-                       <language type="loz">lozi</language>\r
-                       <language type="lt">litauisk</language>\r
-                       <language type="lu">luba-katanga</language>\r
-                       <language type="lua">luba-lulua</language>\r
-                       <language type="lui">luiseno</language>\r
-                       <language type="lun">lunda</language>\r
-                       <language type="lus">lushai</language>\r
-                       <language type="lv">latvisk</language>\r
-                       <language type="mad">maduresisk</language>\r
-                       <language type="mag">magahi</language>\r
-                       <language type="mai">maithili</language>\r
-                       <language type="mak">makasar</language>\r
-                       <language type="man">mandingo</language>\r
-                       <language type="map">austronesisk</language>\r
-                       <language type="mas">masai</language>\r
-                       <language type="mdf">moksha</language>\r
-                       <language type="mdr">mandar</language>\r
-                       <language type="men">mende</language>\r
-                       <language type="mg">madagassisk</language>\r
-                       <language type="mga">mellomirsk (900-1200)</language>\r
-                       <language type="mh">marshallesisk</language>\r
-                       <language type="mi">maori</language>\r
-                       <language type="mic">micmac</language>\r
-                       <language type="min">minangkabau</language>\r
-                       <language type="mis">ulike språk</language>\r
-                       <language type="mk">makedonsk</language>\r
-                       <language type="mkh">mon-khmer (Other)</language>\r
-                       <language type="ml">malayalam</language>\r
-                       <language type="mn">mongolsk</language>\r
-                       <language type="mnc">mandsju</language>\r
-                       <language type="mni">manipuri</language>\r
-                       <language type="mno">manobo-språk</language>\r
-                       <language type="mo">moldavisk</language>\r
-                       <language type="moh">mohawk</language>\r
-                       <language type="mos">mossi</language>\r
-                       <language type="mr">marathi</language>\r
-                       <language type="ms">malayisk</language>\r
-                       <language type="mt">maltesisk</language>\r
-                       <language type="mul">flere språk</language>\r
-                       <language type="mun">munda-språk</language>\r
-                       <language type="mus">creek</language>\r
-                       <language type="mwr">marwari</language>\r
-                       <language type="my">burmesisk</language>\r
-                       <language type="myn">maya</language>\r
-                       <language type="myv">erzya</language>\r
-                       <language type="na">nauru</language>\r
-                       <language type="nah">nahuatl</language>\r
-                       <language type="nai">nordamerikansk indiansk</language>\r
-                       <language type="nap">napolitansk</language>\r
-                       <language type="nb">norsk bokmål</language>\r
-                       <language type="nd">ndebele (nord)</language>\r
-                       <language type="nds">lavtysk; lavsaksisk</language>\r
-                       <language type="ne">nepalsk</language>\r
-                       <language type="new">newari</language>\r
-                       <language type="ng">ndonga</language>\r
-                       <language type="nia">nias</language>\r
-                       <language type="nic">niger - kordofaniansk (annet)</language>\r
-                       <language type="niu">niueansk</language>\r
-                       <language type="nl">nederlandsk</language>\r
-                       <language type="nn">norsk nynorsk</language>\r
-                       <language type="no">norsk</language>\r
-                       <language type="nog">nogai</language>\r
-                       <language type="non">gammelnorsk</language>\r
-                       <language type="nr">ndebele, sør</language>\r
-                       <language type="nso">sotho, nord</language>\r
-                       <language type="nub">nubisk språk</language>\r
-                       <language type="nv">navajo</language>\r
-                       <language type="ny">nyanja</language>\r
-                       <language type="nym">nyamwezi</language>\r
-                       <language type="nyn">nyankole</language>\r
-                       <language type="nyo">nyoro</language>\r
-                       <language type="nzi">nzima</language>\r
-                       <language type="oc">oksitansk (etter 1500)</language>\r
-                       <language type="oj">ojibwa</language>\r
-                       <language type="om">oromo</language>\r
-                       <language type="or">oriya</language>\r
-                       <language type="os">ossetisk</language>\r
-                       <language type="osa">osage</language>\r
-                       <language type="ota">tyrkisk, ottomansk (1500-1928)</language>\r
-                       <language type="oto">otomisk språk</language>\r
-                       <language type="pa">panjabi</language>\r
-                       <language type="paa">papuisk (annet)</language>\r
-                       <language type="pag">pangasinan</language>\r
-                       <language type="pal">pahlavi</language>\r
-                       <language type="pam">pampanga</language>\r
-                       <language type="pap">papiamento</language>\r
-                       <language type="pau">palauisk</language>\r
-                       <language type="peo">gammelpersisk (ca. 600-400 f. kr.)</language>\r
-                       <language type="phi">filippinsk (annet)</language>\r
-                       <language type="phn">fønikisk</language>\r
-                       <language type="pi">pali</language>\r
-                       <language type="pl">polsk</language>\r
-                       <language type="pon">ponapisk</language>\r
-                       <language type="pra">prakrit-språk</language>\r
-                       <language type="pro">gammelprovençalsk (til 1500)</language>\r
-                       <language type="ps">pashto</language>\r
-                       <language type="pt">portugisisk</language>\r
-                       <language type="qu">quechua</language>\r
-                       <language type="raj">rajasthani</language>\r
-                       <language type="rap">rapanui</language>\r
-                       <language type="rar">rarotongansk</language>\r
-                       <language type="rm">retoromansk</language>\r
-                       <language type="rn">rundi</language>\r
-                       <language type="ro">rumensk</language>\r
-                       <language type="roa">romansk (annet)</language>\r
-                       <language type="rom">romani</language>\r
-                       <language type="ru">russisk</language>\r
-                       <language type="rw">kinjarwanda</language>\r
-                       <language type="sa">sanskrit</language>\r
-                       <language type="sad">sandawe</language>\r
-                       <language type="sah">jakutsk</language>\r
-                       <language type="sai">søramerikansk indiansk (annet)</language>\r
-                       <language type="sal">salishansk språk</language>\r
-                       <language type="sam">samaritansk arameisk</language>\r
-                       <language type="sas">sasak</language>\r
-                       <language type="sat">santali</language>\r
-                       <language type="sc">sardinsk</language>\r
-                       <language type="sco">skotsk</language>\r
-                       <language type="sd">sindhi</language>\r
-                       <language type="se">nordsamisk</language>\r
-                       <language type="sel">selkupisk</language>\r
-                       <language type="sem">semittisk (annet)</language>\r
-                       <language type="sg">sango</language>\r
-                       <language type="sga">gammelirsk (til 900)</language>\r
-                       <language type="sgn">tegnspråk</language>\r
-                       <language type="sh">serbokroatisk</language>\r
-                       <language type="shn">shan</language>\r
-                       <language type="si">singalesisk</language>\r
-                       <language type="sid">sidamo</language>\r
-                       <language type="sio">sioux-språk</language>\r
-                       <language type="sit">sino-tibetansk (annet)</language>\r
-                       <language type="sk">slovakisk</language>\r
-                       <language type="sl">slovensk</language>\r
-                       <language type="sla">slavisk (annet)</language>\r
-                       <language type="sm">samoansk</language>\r
-                       <language type="sma">sørsamisk</language>\r
-                       <language type="smi">samisk språk (annet)</language>\r
-                       <language type="smj">lulesamisk</language>\r
-                       <language type="smn">enaresamisk</language>\r
-                       <language type="sms">skoltesamisk</language>\r
-                       <language type="sn">shona</language>\r
-                       <language type="snk">soninke</language>\r
-                       <language type="so">somalisk</language>\r
-                       <language type="sog">sogdisk</language>\r
-                       <language type="son">songhai</language>\r
-                       <language type="sq">albansk</language>\r
-                       <language type="sr">serbisk</language>\r
-                       <language type="srr">serer</language>\r
-                       <language type="ss">swati</language>\r
-                       <language type="ssa">nilo-saharam (annet)</language>\r
-                       <language type="st">sotho (sørlig)</language>\r
-                       <language type="su">sundanesisk</language>\r
-                       <language type="suk">sukuma</language>\r
-                       <language type="sus">susu</language>\r
-                       <language type="sux">sumerisk</language>\r
-                       <language type="sv">svensk</language>\r
-                       <language type="sw">swahili</language>\r
-                       <language type="syr">syrisk</language>\r
-                       <language type="ta">tamil</language>\r
-                       <language type="tai">tai (annet)</language>\r
-                       <language type="te">telugu</language>\r
-                       <language type="tem">temne</language>\r
-                       <language type="ter">tereno</language>\r
-                       <language type="tet">tetum</language>\r
-                       <language type="tg">tatsjikisk</language>\r
-                       <language type="th">thai</language>\r
-                       <language type="ti">tigrinja</language>\r
-                       <language type="tig">tigré</language>\r
-                       <language type="tk">turkmensk</language>\r
-                       <language type="tkl">tokelau</language>\r
-                       <language type="tl">tagalog</language>\r
-                       <language type="tli" draft="true">tlingit</language>\r
-                       <language type="tmh">tamasjek</language>\r
-                       <language type="tn">tswana</language>\r
-                       <language type="to">tonga (Tonga-øyene)</language>\r
-                       <language type="tog">tonga (Nyasa)</language>\r
-                       <language type="tpi">tok pisin</language>\r
-                       <language type="tr">tyrkisk</language>\r
-                       <language type="ts">tsonga</language>\r
-                       <language type="tsi">tsimshian</language>\r
-                       <language type="tt">tatarisk</language>\r
-                       <language type="tum">tumbuka</language>\r
-                       <language type="tup">tupi-språk</language>\r
-                       <language type="tut">altaisk (annet)</language>\r
-                       <language type="tvl">tuvalu</language>\r
-                       <language type="tw">twi</language>\r
-                       <language type="ty">tahitisk</language>\r
-                       <language type="tyv">tuvinisk</language>\r
-                       <language type="udm">udmurt</language>\r
-                       <language type="ug">uigurisk</language>\r
-                       <language type="uga">ugaritisk</language>\r
-                       <language type="uk">ukrainsk</language>\r
-                       <language type="umb">umbundu</language>\r
-                       <language type="und">ikke angitt</language>\r
-                       <language type="ur">urdu</language>\r
-                       <language type="uz">usbekisk</language>\r
-                       <language type="ve">venda</language>\r
-                       <language type="vi">vietnamesisk</language>\r
-                       <language type="vo">volapyk</language>\r
-                       <language type="vot">votisk</language>\r
-                       <language type="wa">vallonsk</language>\r
-                       <language type="wak">wakasjansk språk</language>\r
-                       <language type="wal">walamo</language>\r
-                       <language type="war">waray</language>\r
-                       <language type="was">washo</language>\r
-                       <language type="wen">sorbisk språk</language>\r
-                       <language type="wo">wolof</language>\r
-                       <language type="xal">kalmyk</language>\r
-                       <language type="xh">xhosa</language>\r
-                       <language type="yap">yapesisk</language>\r
-                       <language type="yi">jiddisk</language>\r
-                       <language type="yo">joruba</language>\r
-                       <language type="ypk">jupisk språk</language>\r
-                       <language type="za">zhuang</language>\r
-                       <language type="zap">zapotec</language>\r
-                       <language type="zen">zenaga</language>\r
-                       <language type="zh">kinesisk</language>\r
-                       <language type="znd">zande</language>\r
-                       <language type="zu">zulu</language>\r
-                       <language type="zun">zuni</language>\r
-               </languages>\r
-               <scripts>\r
-                       <script type="Arab">arabisk</script>\r
-                       <script type="Armn">armensk</script>\r
-                       <script type="Beng">bengalsk</script>\r
-                       <script type="Bopo">bopomofo</script>\r
-                       <script type="Brai">braille</script>\r
-                       <script type="Buhd">buhid</script>\r
-                       <script type="Cans">Unified Canadian Aboriginal Symbols</script>\r
-                       <script type="Cher">cherokee</script>\r
-                       <script type="Copt">koptisk</script>\r
-                       <script type="Cprt">kypriotisk</script>\r
-                       <script type="Cyrl">kyrillisk</script>\r
-                       <script type="Deva">devanagari</script>\r
-                       <script type="Dsrt">deseret</script>\r
-                       <script type="Ethi">etiopisk</script>\r
-                       <script type="Geor">georgisk</script>\r
-                       <script type="Goth">gotisk</script>\r
-                       <script type="Grek">gresk</script>\r
-                       <script type="Gujr">gujarati</script>\r
-                       <script type="Guru">gurmukhi</script>\r
-                       <script type="Hang">hangul</script>\r
-                       <script type="Hani">han</script>\r
-                       <script type="Hano">hanunoo</script>\r
-                       <script type="Hans">forenklet han</script>\r
-                       <script type="Hant">tradisjonell han</script>\r
-                       <script type="Hebr">hebraisk</script>\r
-                       <script type="Hira">hiragana</script>\r
-                       <script type="Ital">gammelitalisk</script>\r
-                       <script type="Kana">katakana</script>\r
-                       <script type="Khmr">khmer</script>\r
-                       <script type="Knda">kannada</script>\r
-                       <script type="Laoo">laotisk</script>\r
-                       <script type="Latn">latin</script>\r
-                       <script type="Limb">limbu</script>\r
-                       <script type="Linb">lineær B</script>\r
-                       <script type="Mlym">malayalam</script>\r
-                       <script type="Mong">mongolsk</script>\r
-                       <script type="Mymr">myanmar</script>\r
-                       <script type="Ogam">ogham</script>\r
-                       <script type="Orya">oriya</script>\r
-                       <script type="Osma">osmanya</script>\r
-                       <script type="Qaai">nedarvet</script>\r
-                       <script type="Runr">runisk</script>\r
-                       <script type="Shaw">shavisk</script>\r
-                       <script type="Sinh">sinhala</script>\r
-                       <script type="Syrc">syrisk</script>\r
-                       <script type="Tagb">tagbanwa</script>\r
-                       <script type="Tale">tai le</script>\r
-                       <script type="Taml">tamil</script>\r
-                       <script type="Telu">telugu</script>\r
-                       <script type="Tglg">tagalog</script>\r
-                       <script type="Thaa">thaana</script>\r
-                       <script type="Thai">thai</script>\r
-                       <script type="Tibt">tibetansk</script>\r
-                       <script type="Ugar">ugaritisk</script>\r
-                       <script type="Yiii">yi</script>\r
-                       <script type="Zyyy">generelt</script>\r
-               </scripts>\r
-               <territories>\r
-                       <territory type="AD">Andorra</territory>\r
-                       <territory type="AE">De forente arabiske emiratene</territory>\r
-                       <territory type="AF">Afghanistan</territory>\r
-                       <territory type="AG">Antigua og Barbuda</territory>\r
-                       <territory type="AI">Anguilla</territory>\r
-                       <territory type="AL">Albania</territory>\r
-                       <territory type="AM">Armenia</territory>\r
-                       <territory type="AN">De nederlandske antiller</territory>\r
-                       <territory type="AO">Angola</territory>\r
-                       <territory type="AQ">Antarktis</territory>\r
-                       <territory type="AR">Argentina</territory>\r
-                       <territory type="AS">Amerikansk Samoa</territory>\r
-                       <territory type="AT">Østerrike</territory>\r
-                       <territory type="AU">Australia</territory>\r
-                       <territory type="AW">Aruba</territory>\r
-                       <territory type="AZ">Aserbajdsjan</territory>\r
-                       <territory type="BA">Bosnia og Hercegovina</territory>\r
-                       <territory type="BB">Barbados</territory>\r
-                       <territory type="BD">Bangladesh</territory>\r
-                       <territory type="BE">Belgia</territory>\r
-                       <territory type="BF">Burkina Faso</territory>\r
-                       <territory type="BG">Bulgaria</territory>\r
-                       <territory type="BH">Bahrain</territory>\r
-                       <territory type="BI">Burundi</territory>\r
-                       <territory type="BJ">Benin</territory>\r
-                       <territory type="BM">Bermuda</territory>\r
-                       <territory type="BN">Brunei Darussalam</territory>\r
-                       <territory type="BO">Bolivia</territory>\r
-                       <territory type="BR">Brasil</territory>\r
-                       <territory type="BS">Bahamas</territory>\r
-                       <territory type="BT">Bhutan</territory>\r
-                       <territory type="BV">Bouvetøya</territory>\r
-                       <territory type="BW">Botswana</territory>\r
-                       <territory type="BY">Hviterussland</territory>\r
-                       <territory type="BZ">Belize</territory>\r
-                       <territory type="CA">Canada</territory>\r
-                       <territory type="CC">Kokosøyene (Keelingøyene)</territory>\r
-                       <territory type="CD">Kongo, Den demokratiske republikken</territory>\r
-                       <territory type="CF">Den sentralafrikanske republikk</territory>\r
-                       <territory type="CG">Kongo</territory>\r
-                       <territory type="CH">Sveits</territory>\r
-                       <territory type="CI">Elfenbenskysten</territory>\r
-                       <territory type="CK">Cookøyene</territory>\r
-                       <territory type="CL">Chile</territory>\r
-                       <territory type="CM">Kamerun</territory>\r
-                       <territory type="CN">Kina</territory>\r
-                       <territory type="CO">Colombia</territory>\r
-                       <territory type="CR">Costa Rica</territory>\r
-                       <territory type="CS">Serbia og Montenegro</territory>\r
-                       <territory type="CU">Cuba</territory>\r
-                       <territory type="CV">Kapp Verde</territory>\r
-                       <territory type="CX">Christmasøya</territory>\r
-                       <territory type="CY">Kypros</territory>\r
-                       <territory type="CZ">Tsjekkia</territory>\r
-                       <territory type="DE">Tyskland</territory>\r
-                       <territory type="DJ">Djibouti</territory>\r
-                       <territory type="DK">Danmark</territory>\r
-                       <territory type="DM">Dominica</territory>\r
-                       <territory type="DO">Den dominikanske republikk</territory>\r
-                       <territory type="DZ">Algerie</territory>\r
-                       <territory type="EC">Ecuador</territory>\r
-                       <territory type="EE">Estland</territory>\r
-                       <territory type="EG">Egypt</territory>\r
-                       <territory type="EH">Vest-Sahara</territory>\r
-                       <territory type="ER">Eritrea</territory>\r
-                       <territory type="ES">Spania</territory>\r
-                       <territory type="ET">Etiopia</territory>\r
-                       <territory type="FI">Finland</territory>\r
-                       <territory type="FJ">Fiji</territory>\r
-                       <territory type="FK">Falklandsøyene (Malvinas)</territory>\r
-                       <territory type="FM">Mikronesiaføderasjonen</territory>\r
-                       <territory type="FO">Færøyene</territory>\r
-                       <territory type="FR">Frankrike</territory>\r
-                       <territory type="GA">Gabon</territory>\r
-                       <territory type="GB">Storbritannia</territory>\r
-                       <territory type="GD">Grenada</territory>\r
-                       <territory type="GE">Georgia</territory>\r
-                       <territory type="GF">Fransk Guyana</territory>\r
-                       <territory type="GH">Ghana</territory>\r
-                       <territory type="GI">Gibraltar</territory>\r
-                       <territory type="GL">Grønland</territory>\r
-                       <territory type="GM">Gambia</territory>\r
-                       <territory type="GN">Guinea</territory>\r
-                       <territory type="GP">Guadeloupe</territory>\r
-                       <territory type="GQ">Ekvatorial-Guinea</territory>\r
-                       <territory type="GR">Hellas</territory>\r
-                       <territory type="GS">Sør-Georgia og Sør-Sandwich-øyene</territory>\r
-                       <territory type="GT">Guatemala</territory>\r
-                       <territory type="GU">Guam</territory>\r
-                       <territory type="GW">Guinea-Bissau</territory>\r
-                       <territory type="GY">Guyana</territory>\r
-                       <territory type="HK">Hong Kong S.A.R. (Kina)</territory>\r
-                       <territory type="HM">Heard- og McDonaldsøyene</territory>\r
-                       <territory type="HN">Honduras</territory>\r
-                       <territory type="HR">Kroatia</territory>\r
-                       <territory type="HT">Haiti</territory>\r
-                       <territory type="HU">Ungarn</territory>\r
-                       <territory type="ID">Indonesia</territory>\r
-                       <territory type="IE">Irland</territory>\r
-                       <territory type="IL">Israel</territory>\r
-                       <territory type="IN">India</territory>\r
-                       <territory type="IO">Britiske områder i det indiske hav</territory>\r
-                       <territory type="IQ">Irak</territory>\r
-                       <territory type="IR">Iran</territory>\r
-                       <territory type="IS">Island</territory>\r
-                       <territory type="IT">Italia</territory>\r
-                       <territory type="JM">Jamaica</territory>\r
-                       <territory type="JO">Jordan</territory>\r
-                       <territory type="JP">Japan</territory>\r
-                       <territory type="KE">Kenya</territory>\r
-                       <territory type="KG">Kirgisistan</territory>\r
-                       <territory type="KH">Kambodsja</territory>\r
-                       <territory type="KI">Kiribati</territory>\r
-                       <territory type="KM">Komorene</territory>\r
-                       <territory type="KN">St. Christopher og Nevis</territory>\r
-                       <territory type="KP">Nord-Korea</territory>\r
-                       <territory type="KR">Sør-Korea</territory>\r
-                       <territory type="KW">Kuwait</territory>\r
-                       <territory type="KY">Caymanøyene</territory>\r
-                       <territory type="KZ">Kasakhstan</territory>\r
-                       <territory type="LA">Laos, Den folkedemokratiske republikken</territory>\r
-                       <territory type="LB">Libanon</territory>\r
-                       <territory type="LC">St. Lucia</territory>\r
-                       <territory type="LI">Liechtenstein</territory>\r
-                       <territory type="LK">Sri Lanka</territory>\r
-                       <territory type="LR">Liberia</territory>\r
-                       <territory type="LS">Lesotho</territory>\r
-                       <territory type="LT">Litauen</territory>\r
-                       <territory type="LU">Luxembourg</territory>\r
-                       <territory type="LV">Latvia</territory>\r
-                       <territory type="LY">Libya</territory>\r
-                       <territory type="MA">Marokko</territory>\r
-                       <territory type="MC">Monaco</territory>\r
-                       <territory type="MD">Moldova</territory>\r
-                       <territory type="MG">Madagaskar</territory>\r
-                       <territory type="MH">Marshalløyene</territory>\r
-                       <territory type="MK">Makedonia, Republikken</territory>\r
-                       <territory type="ML">Mali</territory>\r
-                       <territory type="MM">Myanmar</territory>\r
-                       <territory type="MN">Mongolia</territory>\r
-                       <territory type="MO">Macao S.A.R. (Kina)</territory>\r
-                       <territory type="MP">Nord-Marianene</territory>\r
-                       <territory type="MQ">Martinique</territory>\r
-                       <territory type="MR">Mauritania</territory>\r
-                       <territory type="MS">Montserrat</territory>\r
-                       <territory type="MT">Malta</territory>\r
-                       <territory type="MU">Mauritius</territory>\r
-                       <territory type="MV">Maldivene</territory>\r
-                       <territory type="MW">Malawi</territory>\r
-                       <territory type="MX">Mexico</territory>\r
-                       <territory type="MY">Malaysia</territory>\r
-                       <territory type="MZ">Mosambik</territory>\r
-                       <territory type="NA">Namibia</territory>\r
-                       <territory type="NC">Ny-Caledonia</territory>\r
-                       <territory type="NE">Niger</territory>\r
-                       <territory type="NF">Norfolkøyene</territory>\r
-                       <territory type="NG">Nigeria</territory>\r
-                       <territory type="NI">Nicaragua</territory>\r
-                       <territory type="NL">Nederland</territory>\r
-                       <territory type="NO">Norge</territory>\r
-                       <territory type="NP">Nepal</territory>\r
-                       <territory type="NR">Nauru</territory>\r
-                       <territory type="NU">Niue</territory>\r
-                       <territory type="NZ">New Zealand</territory>\r
-                       <territory type="OM">Oman</territory>\r
-                       <territory type="PA">Panama</territory>\r
-                       <territory type="PE">Peru</territory>\r
-                       <territory type="PF">Fransk Polynesia</territory>\r
-                       <territory type="PG">Papua Ny-Guinea</territory>\r
-                       <territory type="PH">Filippinene</territory>\r
-                       <territory type="PK">Pakistan</territory>\r
-                       <territory type="PL">Polen</territory>\r
-                       <territory type="PM">St. Pierre og Miquelon</territory>\r
-                       <territory type="PN">Pitcairn</territory>\r
-                       <territory type="PR">Puerto Rico</territory>\r
-                       <territory type="PS">Palestinsk territorium</territory>\r
-                       <territory type="PT">Portugal</territory>\r
-                       <territory type="PW">Palau</territory>\r
-                       <territory type="PY">Paraguay</territory>\r
-                       <territory type="QA">Qatar</territory>\r
-                       <territory type="RE">Reunion</territory>\r
-                       <territory type="RO">Romania</territory>\r
-                       <territory type="RU">Den russiske føderasjon</territory>\r
-                       <territory type="RW">Rwanda</territory>\r
-                       <territory type="SA">Saudi Arabia</territory>\r
-                       <territory type="SB">Salomonøyene</territory>\r
-                       <territory type="SC">Seychellene</territory>\r
-                       <territory type="SD">Sudan</territory>\r
-                       <territory type="SE">Sverige</territory>\r
-                       <territory type="SG">Singapore</territory>\r
-                       <territory type="SH">Saint Helena</territory>\r
-                       <territory type="SI">Slovenia</territory>\r
-                       <territory type="SJ">Svalbard og Jan Mayen</territory>\r
-                       <territory type="SK">Slovakia</territory>\r
-                       <territory type="SL">Sierra Leone</territory>\r
-                       <territory type="SM">San Marino</territory>\r
-                       <territory type="SN">Senegal</territory>\r
-                       <territory type="SO">Somalia</territory>\r
-                       <territory type="SR">Surinam</territory>\r
-                       <territory type="ST">Sao Tome og Principe</territory>\r
-                       <territory type="SV">El Salvador</territory>\r
-                       <territory type="SY">Syria</territory>\r
-                       <territory type="SZ">Swaziland</territory>\r
-                       <territory type="TC">Turks- og Caicosøyene</territory>\r
-                       <territory type="TD">Tchad</territory>\r
-                       <territory type="TF">Franske sørområder</territory>\r
-                       <territory type="TG">Togo</territory>\r
-                       <territory type="TH">Thailand</territory>\r
-                       <territory type="TJ">Tadsjikistan</territory>\r
-                       <territory type="TK">Tokelau</territory>\r
-                       <territory type="TL">Øst-Timor</territory>\r
-                       <territory type="TM">Turkmenistan</territory>\r
-                       <territory type="TN">Tunisia</territory>\r
-                       <territory type="TO">Tonga</territory>\r
-                       <territory type="TR">Tyrkia</territory>\r
-                       <territory type="TT">Trinidad og Tobago</territory>\r
-                       <territory type="TV">Tuvalu</territory>\r
-                       <territory type="TW">Taiwan</territory>\r
-                       <territory type="TZ">Tanzania</territory>\r
-                       <territory type="UA">Ukraina</territory>\r
-                       <territory type="UG">Uganda</territory>\r
-                       <territory type="UM">USAs mindre øyer</territory>\r
-                       <territory type="US">USA</territory>\r
-                       <territory type="UY">Uruguay</territory>\r
-                       <territory type="UZ">Usbekistan</territory>\r
-                       <territory type="VA">Vatikanstaten</territory>\r
-                       <territory type="VC">St. Vincent og Grenadinene</territory>\r
-                       <territory type="VE">Venezuela</territory>\r
-                       <territory type="VG">Jomfruøyene (britisk)</territory>\r
-                       <territory type="VI">Jomfruøyene (USA)</territory>\r
-                       <territory type="VN">Vietnam</territory>\r
-                       <territory type="VU">Vanuatu</territory>\r
-                       <territory type="WF">Wallis og Futuna</territory>\r
-                       <territory type="WS">Samoa</territory>\r
-                       <territory type="YE">Yemen</territory>\r
-                       <territory type="YT">Mayotte</territory>\r
-                       <territory type="ZA">Sør-Afrika</territory>\r
-                       <territory type="ZM">Zambia</territory>\r
-                       <territory type="ZW">Zimbabwe</territory>\r
-               </territories>\r
-               <variants>\r
-                       <variant type="REVISED">Revidert</variant>\r
-               </variants>\r
-               <keys>\r
-                       <key type="calendar">Kalendar</key>\r
-                       <key type="collation">Kollasjon</key>\r
-                       <key type="currency">Valuta</key>\r
-               </keys>\r
-               <types>\r
-                       <type type="buddhist" key="calendar">Buddhistisk kalender</type>\r
-                       <type type="chinese" key="calendar">Kinesisk kalender</type>\r
-                       <type type="direct" key="collation">Direkte rekkefølge</type>\r
-                       <type type="gregorian" key="calendar">Gregoriansk kalender</type>\r
-                       <type type="hebrew" key="calendar">Hebraisk kalender</type>\r
-                       <type type="islamic" key="calendar">Islamsk kalender</type>\r
-                       <type type="islamic-civil" key="calendar">Islamsk sivil kalender</type>\r
-                       <type type="japanese" key="calendar">Japansk kalender</type>\r
-                       <type type="phonebook" key="collation">Telefonkatalogrekkefølge</type>\r
-                       <type type="pinyin" key="collation">Pinyin-rekkefølge</type>\r
-                       <type type="stroke" key="collation">Strekrekkefølge</type>\r
-                       <type type="traditional" key="collation">Tradisjonell rekkefølge</type>\r
-               </types>\r
-       </localeDisplayNames>\r
-       <characters>\r
-               <exemplarCharacters>[a-zæåøéóôàüǎ]</exemplarCharacters>\r
-       </characters>\r
-       <dates>\r
-               <calendars>\r
-                       <calendar type="gregorian">\r
-                               <months>\r
-                                       <monthContext type="format">\r
-                                               <monthWidth type="abbreviated">\r
-                                                       <month type="1">jan.</month>\r
-                                                       <month type="1" alt="proposed" references="R1" draft="true">jan.</month>\r
-                                                       <month type="2">feb.</month>\r
-                                                       <month type="2" alt="proposed" references="R1" draft="true">feb.</month>\r
-                                                       <month type="3">mars</month>\r
-                                                       <month type="3" alt="proposed" references="R1" draft="true">mars</month>\r
-                                                       <month type="4">april</month>\r
-                                                       <month type="4" alt="proposed" references="R1" draft="true">april</month>\r
-                                                       <month type="5" references="R1">mai</month>\r
-                                                       <month type="6">juni</month>\r
-                                                       <month type="6" alt="proposed" references="R1" draft="true">juni</month>\r
-                                                       <month type="7">juli</month>\r
-                                                       <month type="7" alt="proposed" references="R1" draft="true">juli</month>\r
-                                                       <month type="8">aug.</month>\r
-                                                       <month type="8" alt="proposed" references="R1" draft="true">aug.</month>\r
-                                                       <month type="9">sep.</month>\r
-                                                       <month type="9" alt="proposed" references="R1" draft="true">sep.</month>\r
-                                                       <month type="10">okt.</month>\r
-                                                       <month type="10" alt="proposed" references="R1" draft="true">okt.</month>\r
-                                                       <month type="11">nov.</month>\r
-                                                       <month type="11" alt="proposed" references="R1" draft="true">nov.</month>\r
-                                                       <month type="12">des.</month>\r
-                                                       <month type="12" alt="proposed" references="R1" draft="true">des.</month>\r
-                                               </monthWidth>\r
-                                               <monthWidth type="wide">\r
-                                                       <month type="1">januar</month>\r
-                                                       <month type="2">februar</month>\r
-                                                       <month type="3">mars</month>\r
-                                                       <month type="4">april</month>\r
-                                                       <month type="5">mai</month>\r
-                                                       <month type="6">juni</month>\r
-                                                       <month type="7">juli</month>\r
-                                                       <month type="8">august</month>\r
-                                                       <month type="9">september</month>\r
-                                                       <month type="10">oktober</month>\r
-                                                       <month type="11">november</month>\r
-                                                       <month type="12">desember</month>\r
-                                               </monthWidth>\r
-                                       </monthContext>\r
-                                       <monthContext type="stand-alone">\r
-                                               <monthWidth type="narrow">\r
-                                                       <month type="1">J</month>\r
-                                                       <month type="2">F</month>\r
-                                                       <month type="3">M</month>\r
-                                                       <month type="4">A</month>\r
-                                                       <month type="5">M</month>\r
-                                                       <month type="6">J</month>\r
-                                                       <month type="7">J</month>\r
-                                                       <month type="8">A</month>\r
-                                                       <month type="9">S</month>\r
-                                                       <month type="10">O</month>\r
-                                                       <month type="11">N</month>\r
-                                                       <month type="12">D</month>\r
-                                               </monthWidth>\r
-                                       </monthContext>\r
-                               </months>\r
-                               <days>\r
-                                       <dayContext type="format">\r
-                                               <dayWidth type="abbreviated">\r
-                                                       <day type="sun">sø.</day>\r
-                                                       <day type="sun" alt="proposed" references="R1" draft="true">sø.</day>\r
-                                                       <day type="mon">ma.</day>\r
-                                                       <day type="mon" alt="proposed" references="R1" draft="true">ma.</day>\r
-                                                       <day type="tue">ti.</day>\r
-                                                       <day type="tue" alt="proposed" references="R1" draft="true">ti.</day>\r
-                                                       <day type="wed">on.</day>\r
-                                                       <day type="wed" alt="proposed" references="R1" draft="true">on.</day>\r
-                                                       <day type="thu">to.</day>\r
-                                                       <day type="thu" alt="proposed" references="R1" draft="true">to.</day>\r
-                                                       <day type="fri">fr.</day>\r
-                                                       <day type="fri" alt="proposed" references="R1" draft="true">fr.</day>\r
-                                                       <day type="sat">lø.</day>\r
-                                                       <day type="sat" alt="proposed" references="R1" draft="true">lø.</day>\r
-                                               </dayWidth>\r
-                                               <dayWidth type="wide">\r
-                                                       <day type="sun">søndag</day>\r
-                                                       <day type="mon">mandag</day>\r
-                                                       <day type="tue">tirsdag</day>\r
-                                                       <day type="wed">onsdag</day>\r
-                                                       <day type="thu">torsdag</day>\r
-                                                       <day type="fri">fredag</day>\r
-                                                       <day type="sat">lørdag</day>\r
-                                               </dayWidth>\r
-                                       </dayContext>\r
-                                       <dayContext type="stand-alone">\r
-                                               <dayWidth type="narrow">\r
-                                                       <day type="sun">S</day>\r
-                                                       <day type="mon">M</day>\r
-                                                       <day type="tue">T</day>\r
-                                                       <day type="wed">O</day>\r
-                                                       <day type="thu">T</day>\r
-                                                       <day type="fri">F</day>\r
-                                                       <day type="sat">L</day>\r
-                                               </dayWidth>\r
-                                       </dayContext>\r
-                               </days>\r
-                               <week>\r
-                                       <minDays count="4"/>\r
-                                       <firstDay day="mon"/>\r
-                               </week>\r
-                               <am>a.m.</am>\r
-                               <pm>p.m.</pm>\r
-                               <eras>\r
-                                       <eraAbbr>\r
-                                               <era type="0">f.Kr.</era>\r
-                                               <era type="1">e.Kr.</era>\r
-                                       </eraAbbr>\r
-                               </eras>\r
-                               <dateFormats>\r
-                                       <dateFormatLength type="full">\r
-                                               <dateFormat>\r
-                                                       <pattern>EEEE d. MMMM yyyy</pattern>\r
-                                               </dateFormat>\r
-                                       </dateFormatLength>\r
-                                       <dateFormatLength type="long">\r
-                                               <dateFormat>\r
-                                                       <pattern>d. MMMM yyyy</pattern>\r
-                                               </dateFormat>\r
-                                       </dateFormatLength>\r
-                                       <dateFormatLength type="medium">\r
-                                               <dateFormat>\r
-                                                       <pattern>d. MMM. yyyy</pattern>\r
-                                               </dateFormat>\r
-                                       </dateFormatLength>\r
-                                       <dateFormatLength type="short">\r
-                                               <dateFormat>\r
-                                                       <pattern>dd.MM.yy</pattern>\r
-                                               </dateFormat>\r
-                                       </dateFormatLength>\r
-                               </dateFormats>\r
-                               <timeFormats>\r
-                                       <timeFormatLength type="full">\r
-                                               <timeFormat>\r
-                                                       <pattern>'kl. 'HH.mm.ss z</pattern>\r
-                                               </timeFormat>\r
-                                       </timeFormatLength>\r
-                                       <timeFormatLength type="long">\r
-                                               <timeFormat>\r
-                                                       <pattern>HH.mm.ss z</pattern>\r
-                                               </timeFormat>\r
-                                       </timeFormatLength>\r
-                                       <timeFormatLength type="medium">\r
-                                               <timeFormat>\r
-                                                       <pattern>HH.mm.ss</pattern>\r
-                                               </timeFormat>\r
-                                       </timeFormatLength>\r
-                                       <timeFormatLength type="short">\r
-                                               <timeFormat>\r
-                                                       <pattern>HH.mm</pattern>\r
-                                               </timeFormat>\r
-                                       </timeFormatLength>\r
-                               </timeFormats>\r
-                       </calendar>\r
-               </calendars>\r
-               <timeZoneNames>\r
-                       <zone type="Antarctica/South_Pole">\r
-                               <exemplarCity>Sydpolen</exemplarCity>\r
-                       </zone>\r
-                       <zone type="America/St_Johns">\r
-                               <exemplarCity>St. John's</exemplarCity>\r
-                       </zone>\r
-                       <zone type="America/Godthab">\r
-                               <exemplarCity>Godthåb</exemplarCity>\r
-                       </zone>\r
-                       <!-- Portugal -->\r
-                       <zone type="Atlantic/Azores">\r
-                               <exemplarCity>Azorene</exemplarCity>\r
-                       </zone>\r
-                       <zone type="Europe/Lisbon">\r
-                               <exemplarCity>Lisboa</exemplarCity>\r
-                       </zone>\r
-                       <zone type="Europe/Bucharest">\r
-                               <long>\r
-                                       <standard>Eastern European Standard Time</standard>\r
-                                       <daylight>Eastern European Daylight Time</daylight>\r
-                               </long>\r
-                               <short>\r
-                                       <standard>EET</standard>\r
-                                       <daylight>EEST</daylight>\r
-                               </short>\r
-                               <exemplarCity>Bucuresti</exemplarCity>\r
-                       </zone>\r
-                       <zone type="Europe/Moscow">\r
-                               <exemplarCity>Moskva</exemplarCity>\r
-                       </zone>\r
-               </timeZoneNames>\r
-       </dates>\r
-       <numbers>\r
-               <symbols>\r
-                       <decimal>,</decimal>\r
-                       <group> </group>\r
-               </symbols>\r
-               <percentFormats>\r
-                       <percentFormatLength>\r
-                               <percentFormat>\r
-                                       <pattern draft="true">#,##0 %</pattern>\r
-                               </percentFormat>\r
-                       </percentFormatLength>\r
-               </percentFormats>\r
-               <currencies>\r
-                       <currency type="ADP">\r
-                               <displayName>Andorranske pesetas</displayName>\r
-                       </currency>\r
-                       <currency type="AED">\r
-                               <displayName>UAE dirham</displayName>\r
-                       </currency>\r
-                       <currency type="AFA">\r
-                               <displayName>Afghani (1927-2002)</displayName>\r
-                       </currency>\r
-                       <currency type="AFN">\r
-                               <displayName>Afghani</displayName>\r
-                               <symbol>Af</symbol>\r
-                       </currency>\r
-                       <currency type="ALL">\r
-                               <displayName>Albanske lek</displayName>\r
-                               <symbol>lek</symbol>\r
-                       </currency>\r
-                       <currency type="AMD">\r
-                               <displayName>Armenske dram</displayName>\r
-                               <symbol>dram</symbol>\r
-                       </currency>\r
-                       <currency type="ANG">\r
-                               <displayName>Nederlandske antillegylden</displayName>\r
-                               <symbol>NA f.</symbol>\r
-                       </currency>\r
-                       <currency type="AOA">\r
-                               <displayName>Angolanske kwanza</displayName>\r
-                       </currency>\r
-                       <currency type="AOK">\r
-                               <displayName>Angolanske kwanza (1977-1990)</displayName>\r
-                       </currency>\r
-                       <currency type="AON">\r
-                               <displayName>Angolanske ny kwanza (1990-2000)</displayName>\r
-                       </currency>\r
-                       <currency type="AOR">\r
-                               <displayName>Angolan Kwanza Reajustado (1995-1999)</displayName>\r
-                       </currency>\r
-                       <currency type="ARA">\r
-                               <displayName>Argentinske australer</displayName>\r
-                       </currency>\r
-                       <currency type="ARP">\r
-                               <displayName>Argentinske pesos (1983-1985)</displayName>\r
-                       </currency>\r
-                       <currency type="ARS">\r
-                               <displayName>Argentinske pesos</displayName>\r
-                               <symbol>Arg$</symbol>\r
-                       </currency>\r
-                       <currency type="ATS">\r
-                               <displayName>Østerrikske shilling</displayName>\r
-                       </currency>\r
-                       <currency type="AUD">\r
-                               <displayName>Australske dollar</displayName>\r
-                               <symbol>$A</symbol>\r
-                       </currency>\r
-                       <currency type="AWG">\r
-                               <displayName>Arubiske gylden</displayName>\r
-                       </currency>\r
-                       <currency type="AZM">\r
-                               <displayName>Aserbajdsjanske Manat</displayName>\r
-                       </currency>\r
-                       <currency type="BAD">\r
-                               <displayName>Bosnia-Hercegovina dinarer</displayName>\r
-                       </currency>\r
-                       <currency type="BAM">\r
-                               <displayName>Bosnia-Hercegovina mark (konvertible)</displayName>\r
-                               <symbol>KM</symbol>\r
-                       </currency>\r
-                       <currency type="BBD">\r
-                               <displayName>Barbadisk dollar</displayName>\r
-                               <symbol>BDS$</symbol>\r
-                       </currency>\r
-                       <currency type="BDT">\r
-                               <displayName>Bangladeshiske taka</displayName>\r
-                               <symbol>Tk</symbol>\r
-                       </currency>\r
-                       <currency type="BEC">\r
-                               <displayName>Belgiske franc (konvertible)</displayName>\r
-                       </currency>\r
-                       <currency type="BEF">\r
-                               <displayName>Belgiske franc</displayName>\r
-                               <symbol>BF</symbol>\r
-                       </currency>\r
-                       <currency type="BEL">\r
-                               <displayName>Belgiske franc (økonomiske)</displayName>\r
-                       </currency>\r
-                       <currency type="BGL">\r
-                               <displayName>Bulgarske lev (hard)</displayName>\r
-                               <symbol>lev</symbol>\r
-                       </currency>\r
-                       <currency type="BGN">\r
-                               <displayName>Bulgarske lev</displayName>\r
-                       </currency>\r
-                       <currency type="BHD">\r
-                               <displayName>Bahrainske dinarer</displayName>\r
-                               <symbol>BD</symbol>\r
-                       </currency>\r
-                       <currency type="BIF">\r
-                               <displayName>Burundiske franc</displayName>\r
-                               <symbol>Fbu</symbol>\r
-                       </currency>\r
-                       <currency type="BMD">\r
-                               <displayName>Bermudiske dollar</displayName>\r
-                               <symbol>Ber$</symbol>\r
-                       </currency>\r
-                       <currency type="BND">\r
-                               <displayName>Bruneiske dollar</displayName>\r
-                       </currency>\r
-                       <currency type="BOB">\r
-                               <displayName>Boliviano</displayName>\r
-                               <symbol>Bs</symbol>\r
-                       </currency>\r
-                       <currency type="BOP">\r
-                               <displayName>Boliviansk pesos</displayName>\r
-                       </currency>\r
-                       <currency type="BOV">\r
-                               <displayName>Boliviansk mvdol</displayName>\r
-                       </currency>\r
-                       <currency type="BRB">\r
-                               <displayName>Brasiliansk cruzeiro novo (1967-1986)</displayName>\r
-                       </currency>\r
-                       <currency type="BRC">\r
-                               <displayName>Brasilianske cruzado</displayName>\r
-                       </currency>\r
-                       <currency type="BRE">\r
-                               <displayName>Brasilianske cruzeiro (1990-1993)</displayName>\r
-                       </currency>\r
-                       <currency type="BRL">\r
-                               <displayName>Brasilianske realer</displayName>\r
-                               <symbol>R$</symbol>\r
-                       </currency>\r
-                       <currency type="BRN">\r
-                               <displayName>Brasilianske cruzado novo</displayName>\r
-                       </currency>\r
-                       <currency type="BRR">\r
-                               <displayName>Brasilianske cruzeiro</displayName>\r
-                       </currency>\r
-                       <currency type="BSD">\r
-                               <displayName>Bahamske dollar</displayName>\r
-                       </currency>\r
-                       <currency type="BTN">\r
-                               <displayName>Bhutanske ngultrum</displayName>\r
-                               <symbol>Nu</symbol>\r
-                       </currency>\r
-                       <currency type="BUK">\r
-                               <displayName>Burmesiske kyat</displayName>\r
-                       </currency>\r
-                       <currency type="BWP">\r
-                               <displayName>Botswanske pula</displayName>\r
-                       </currency>\r
-                       <currency type="BYB">\r
-                               <displayName>Hviterussiske nye rubler (1994-1999)</displayName>\r
-                       </currency>\r
-                       <currency type="BYR">\r
-                               <displayName>Hviterussiske rubler</displayName>\r
-                               <symbol>Rbl</symbol>\r
-                       </currency>\r
-                       <currency type="BZD">\r
-                               <displayName>Beliziske dollar</displayName>\r
-                               <symbol>BZ$</symbol>\r
-                       </currency>\r
-                       <currency type="CAD">\r
-                               <displayName>Kanadiske dollar</displayName>\r
-                               <symbol>Can$</symbol>\r
-                       </currency>\r
-                       <currency type="CDF">\r
-                               <displayName>Kongolesiske franc (congolais)</displayName>\r
-                       </currency>\r
-                       <currency type="CHF">\r
-                               <displayName>Sveitsiske franc</displayName>\r
-                               <symbol>SwF</symbol>\r
-                       </currency>\r
-                       <currency type="CLF">\r
-                               <displayName>Chilenske Unidades de Fomento</displayName>\r
-                       </currency>\r
-                       <currency type="CLP">\r
-                               <displayName>Chilenske pesos</displayName>\r
-                               <symbol>Ch$</symbol>\r
-                       </currency>\r
-                       <currency type="CNY">\r
-                               <displayName>Kinesiske Yuan Renminbi</displayName>\r
-                               <symbol>Y</symbol>\r
-                       </currency>\r
-                       <currency type="COP">\r
-                               <displayName>Colombianske pesos</displayName>\r
-                               <symbol>Col$</symbol>\r
-                       </currency>\r
-                       <currency type="CRC">\r
-                               <displayName>Costaricanske colon</displayName>\r
-                               <symbol>C</symbol>\r
-                       </currency>\r
-                       <currency type="CSK">\r
-                               <displayName>Tsjekkoslovakiske koruna (hard)</displayName>\r
-                       </currency>\r
-                       <currency type="CUP">\r
-                               <displayName>Kubanske pesos</displayName>\r
-                       </currency>\r
-                       <currency type="CVE">\r
-                               <displayName>Kappverdiske escudo</displayName>\r
-                               <symbol>CVEsc</symbol>\r
-                       </currency>\r
-                       <currency type="CYP">\r
-                               <displayName>Kypriotiske pund</displayName>\r
-                               <symbol>£C</symbol>\r
-                       </currency>\r
-                       <currency type="CZK">\r
-                               <displayName>Tsjekkiske koruna</displayName>\r
-                       </currency>\r
-                       <currency type="DDM">\r
-                               <displayName>Østtyske ostmark</displayName>\r
-                       </currency>\r
-                       <currency type="DEM">\r
-                               <displayName>Tyske mark</displayName>\r
-                       </currency>\r
-                       <currency type="DJF">\r
-                               <displayName>Djiboutiske franc</displayName>\r
-                               <symbol>DF</symbol>\r
-                       </currency>\r
-                       <currency type="DKK">\r
-                               <displayName>Danske kroner</displayName>\r
-                               <symbol>DKr</symbol>\r
-                       </currency>\r
-                       <currency type="DOP">\r
-                               <displayName>Dominikanske pesos</displayName>\r
-                               <symbol>RD$</symbol>\r
-                       </currency>\r
-                       <currency type="DZD">\r
-                               <displayName>Algeriske dinarer</displayName>\r
-                               <symbol>DA</symbol>\r
-                       </currency>\r
-                       <currency type="ECS">\r
-                               <displayName>Ecuadorianske sucre</displayName>\r
-                       </currency>\r
-                       <currency type="ECV">\r
-                               <displayName>Ecuadorianske Unidad de Valor Constante (UVC)</displayName>\r
-                       </currency>\r
-                       <currency type="EEK">\r
-                               <displayName>Estiske kroon</displayName>\r
-                       </currency>\r
-                       <currency type="EGP">\r
-                               <displayName>Egyptiske pund</displayName>\r
-                       </currency>\r
-                       <currency type="ERN">\r
-                               <displayName>Eritreiske nakfa</displayName>\r
-                       </currency>\r
-                       <currency type="ESP">\r
-                               <displayName>Spanske peseta</displayName>\r
-                       </currency>\r
-                       <currency type="ETB">\r
-                               <displayName>Etiopiske birr</displayName>\r
-                               <symbol>Br</symbol>\r
-                       </currency>\r
-                       <currency type="EUR">\r
-                               <displayName>Euro</displayName>\r
-                       </currency>\r
-                       <currency type="FIM">\r
-                               <displayName>Finske mark</displayName>\r
-                       </currency>\r
-                       <currency type="FJD">\r
-                               <displayName>Fijianske dollar</displayName>\r
-                               <symbol>F$</symbol>\r
-                       </currency>\r
-                       <currency type="FKP">\r
-                               <displayName>Falklandsøyene-pund</displayName>\r
-                       </currency>\r
-                       <currency type="FRF">\r
-                               <displayName>Franske franc</displayName>\r
-                       </currency>\r
-                       <currency type="GBP">\r
-                               <displayName>Britiske pund sterling</displayName>\r
-                       </currency>\r
-                       <currency type="GEK">\r
-                               <displayName>Georgiske kupon larit</displayName>\r
-                       </currency>\r
-                       <currency type="GEL">\r
-                               <displayName>Georgiske lari</displayName>\r
-                               <symbol>lari</symbol>\r
-                       </currency>\r
-                       <currency type="GHC">\r
-                               <displayName>Ghanesiske cedi</displayName>\r
-                       </currency>\r
-                       <currency type="GIP">\r
-                               <displayName>Gibraltarske pund</displayName>\r
-                       </currency>\r
-                       <currency type="GMD">\r
-                               <displayName>Gambiske dalasi</displayName>\r
-                       </currency>\r
-                       <currency type="GNF">\r
-                               <displayName>Guineanske franc</displayName>\r
-                               <symbol>GF</symbol>\r
-                       </currency>\r
-                       <currency type="GNS">\r
-                               <displayName>Guineanske syli</displayName>\r
-                       </currency>\r
-                       <currency type="GQE">\r
-                               <displayName>Ekvatorialguineanske ekwele guineana</displayName>\r
-                       </currency>\r
-                       <currency type="GRD">\r
-                               <displayName>Greske drakmer</displayName>\r
-                       </currency>\r
-                       <currency type="GTQ">\r
-                               <displayName>Guatemalanske quetzal</displayName>\r
-                               <symbol>Q</symbol>\r
-                       </currency>\r
-                       <currency type="GWE">\r
-                               <displayName>Portugisiske guinea escudo</displayName>\r
-                       </currency>\r
-                       <currency type="GWP">\r
-                               <displayName>Guinea-Bissau-pesos</displayName>\r
-                       </currency>\r
-                       <currency type="GYD">\r
-                               <displayName>Guyanske dollar</displayName>\r
-                               <symbol>G$</symbol>\r
-                       </currency>\r
-                       <currency type="HKD">\r
-                               <displayName>Hongkong-dollar</displayName>\r
-                               <symbol>HK$</symbol>\r
-                       </currency>\r
-                       <currency type="HNL">\r
-                               <displayName>Hoduras Lempira</displayName>\r
-                               <symbol>L</symbol>\r
-                       </currency>\r
-                       <currency type="HRD">\r
-                               <displayName>Kroatiske dinarer</displayName>\r
-                       </currency>\r
-                       <currency type="HRK">\r
-                               <displayName>Kroatiske kuna</displayName>\r
-                       </currency>\r
-                       <currency type="HTG">\r
-                               <displayName>Haitiske gourde</displayName>\r
-                       </currency>\r
-                       <currency type="HUF">\r
-                               <displayName>Ungarske forinter</displayName>\r
-                               <symbol>Ft</symbol>\r
-                       </currency>\r
-                       <currency type="IDR">\r
-                               <displayName>Indonesiske rupier</displayName>\r
-                               <symbol>Rp</symbol>\r
-                       </currency>\r
-                       <currency type="IEP">\r
-                               <displayName>Irske pund</displayName>\r
-                               <symbol>IR£</symbol>\r
-                       </currency>\r
-                       <currency type="ILP">\r
-                               <displayName>Israelske pund</displayName>\r
-                       </currency>\r
-                       <currency type="ILS">\r
-                               <displayName>Israelske nye shekler</displayName>\r
-                       </currency>\r
-                       <currency type="INR">\r
-                               <displayName>Indiske rupier</displayName>\r
-                       </currency>\r
-                       <currency type="IQD">\r
-                               <displayName>Irakske dinarer</displayName>\r
-                               <symbol>ID</symbol>\r
-                       </currency>\r
-                       <currency type="IRR">\r
-                               <displayName>Iranske rialer</displayName>\r
-                               <symbol>RI</symbol>\r
-                       </currency>\r
-                       <currency type="ISK">\r
-                               <displayName>Islandske kronar</displayName>\r
-                       </currency>\r
-                       <currency type="ITL">\r
-                               <displayName>Italienske lire</displayName>\r
-                       </currency>\r
-                       <currency type="JMD">\r
-                               <displayName>Jamaikanske dollar</displayName>\r
-                               <symbol>J$</symbol>\r
-                       </currency>\r
-                       <currency type="JOD">\r
-                               <displayName>Jordanske dinarer</displayName>\r
-                               <symbol>JD</symbol>\r
-                       </currency>\r
-                       <currency type="JPY">\r
-                               <displayName>Japanske yen</displayName>\r
-                       </currency>\r
-                       <currency type="KES">\r
-                               <displayName>Kenyanske shilling</displayName>\r
-                               <symbol>K Sh</symbol>\r
-                       </currency>\r
-                       <currency type="KGS">\r
-                               <displayName>Kirgisiske som</displayName>\r
-                               <symbol>som</symbol>\r
-                       </currency>\r
-                       <currency type="KHR">\r
-                               <displayName>Kambodsjanske riel</displayName>\r
-                               <symbol>CR</symbol>\r
-                       </currency>\r
-                       <currency type="KMF">\r
-                               <displayName>Komoriske franc</displayName>\r
-                               <symbol>CF</symbol>\r
-                       </currency>\r
-                       <currency type="KPW">\r
-                               <displayName>Nordkoreanske won</displayName>\r
-                       </currency>\r
-                       <currency type="KRW">\r
-                               <displayName>Sørkoreanske won</displayName>\r
-                       </currency>\r
-                       <currency type="KWD">\r
-                               <displayName>Kuwaitiske dinarer</displayName>\r
-                               <symbol>KD</symbol>\r
-                       </currency>\r
-                       <currency type="KYD">\r
-                               <displayName>Caymanske dollar</displayName>\r
-                       </currency>\r
-                       <currency type="KZT">\r
-                               <displayName>Kasakhstanske tenge</displayName>\r
-                               <symbol>T</symbol>\r
-                       </currency>\r
-                       <currency type="LAK">\r
-                               <displayName>Laotiske kip</displayName>\r
-                       </currency>\r
-                       <currency type="LBP">\r
-                               <displayName>Libanesiske pund</displayName>\r
-                               <symbol>LL</symbol>\r
-                       </currency>\r
-                       <currency type="LKR">\r
-                               <displayName>Srilankiske rupier</displayName>\r
-                               <symbol>SL Re</symbol>\r
-                       </currency>\r
-                       <currency type="LRD">\r
-                               <displayName>Liberiske dollar</displayName>\r
-                       </currency>\r
-                       <currency type="LSL">\r
-                               <displayName>Lesothiske loti</displayName>\r
-                               <symbol>M</symbol>\r
-                       </currency>\r
-                       <currency type="LTL">\r
-                               <displayName>Litauiske lita</displayName>\r
-                       </currency>\r
-                       <currency type="LTT">\r
-                               <displayName>Litauiske talonas</displayName>\r
-                       </currency>\r
-                       <currency type="LUF">\r
-                               <displayName>Luxemburgske franc</displayName>\r
-                       </currency>\r
-                       <currency type="LVL">\r
-                               <displayName>Latviske lats</displayName>\r
-                       </currency>\r
-                       <currency type="LVR">\r
-                               <displayName>Latviske rubler</displayName>\r
-                       </currency>\r
-                       <currency type="LYD">\r
-                               <displayName>Libyske dinarer</displayName>\r
-                               <symbol>LD</symbol>\r
-                       </currency>\r
-                       <currency type="MAD">\r
-                               <displayName>Marokkanske dirham</displayName>\r
-                       </currency>\r
-                       <currency type="MAF">\r
-                               <displayName>Marokkanske franc</displayName>\r
-                       </currency>\r
-                       <currency type="MDL">\r
-                               <displayName>Moldovske leu</displayName>\r
-                       </currency>\r
-                       <currency type="MGA">\r
-                               <displayName>Madagassiske ariary</displayName>\r
-                       </currency>\r
-                       <currency type="MGF">\r
-                               <displayName>Madagassiske franc</displayName>\r
-                       </currency>\r
-                       <currency type="MKD">\r
-                               <displayName>Makedonske denarer</displayName>\r
-                               <symbol>MDen</symbol>\r
-                       </currency>\r
-                       <currency type="MLF">\r
-                               <displayName>Maliske franc</displayName>\r
-                       </currency>\r
-                       <currency type="MMK">\r
-                               <displayName>Myanmarske kyat</displayName>\r
-                       </currency>\r
-                       <currency type="MNT">\r
-                               <displayName>Mongolske tugrik</displayName>\r
-                               <symbol>Tug</symbol>\r
-                       </currency>\r
-                       <currency type="MOP">\r
-                               <displayName>Makaoske pataca</displayName>\r
-                       </currency>\r
-                       <currency type="MRO">\r
-                               <displayName>Mauritanske ouguiya</displayName>\r
-                               <symbol>UM</symbol>\r
-                       </currency>\r
-                       <currency type="MTL">\r
-                               <displayName>Maltesiske lira</displayName>\r
-                               <symbol>Lm</symbol>\r
-                       </currency>\r
-                       <currency type="MTP">\r
-                               <displayName>Maltesiske pund</displayName>\r
-                       </currency>\r
-                       <currency type="MUR">\r
-                               <displayName>Mauritiske rupier</displayName>\r
-                       </currency>\r
-                       <currency type="MVR">\r
-                               <displayName>Maldiviske rufiyaa</displayName>\r
-                       </currency>\r
-                       <currency type="MWK">\r
-                               <displayName>Malawisle kwacha</displayName>\r
-                               <symbol>MK</symbol>\r
-                       </currency>\r
-                       <currency type="MXN">\r
-                               <displayName>Meksikanske pesos</displayName>\r
-                               <symbol>MEX$</symbol>\r
-                       </currency>\r
-                       <currency type="MXP">\r
-                               <displayName>Meksikanske sølvpesos (1861-1992)</displayName>\r
-                       </currency>\r
-                       <currency type="MXV">\r
-                               <displayName>Meksikanske Unidad de Inversion (UDI)</displayName>\r
-                       </currency>\r
-                       <currency type="MYR">\r
-                               <displayName>Malaysiske ringgit</displayName>\r
-                               <symbol>RM</symbol>\r
-                       </currency>\r
-                       <currency type="MZE">\r
-                               <displayName>Mosambikiske escudo</displayName>\r
-                       </currency>\r
-                       <currency type="MZM">\r
-                               <displayName>Mosambikiske metical</displayName>\r
-                               <symbol>Mt</symbol>\r
-                       </currency>\r
-                       <currency type="NAD">\r
-                               <displayName>Namibiske dollar</displayName>\r
-                               <symbol>N$</symbol>\r
-                       </currency>\r
-                       <currency type="NGN">\r
-                               <displayName>Nigerianske naira</displayName>\r
-                       </currency>\r
-                       <currency type="NIC">\r
-                               <displayName>Nicaraguanske cordoba</displayName>\r
-                       </currency>\r
-                       <currency type="NIO">\r
-                               <displayName>Nicaraguanske cordoba oro</displayName>\r
-                       </currency>\r
-                       <currency type="NLG">\r
-                               <displayName>Nederlandske gylden</displayName>\r
-                       </currency>\r
-                       <currency type="NOK">\r
-                               <displayName>Norske kroner</displayName>\r
-                               <symbol>kr</symbol>\r
-                       </currency>\r
-                       <currency type="NPR">\r
-                               <displayName>Nepalesiske rupier</displayName>\r
-                               <symbol>Nrs</symbol>\r
-                       </currency>\r
-                       <currency type="NZD">\r
-                               <displayName>Nyzealandske dollar</displayName>\r
-                               <symbol>$NZ</symbol>\r
-                       </currency>\r
-                       <currency type="OMR">\r
-                               <displayName>Omanske rialer</displayName>\r
-                               <symbol>RO</symbol>\r
-                       </currency>\r
-                       <currency type="PAB">\r
-                               <displayName>Panamanske balboa</displayName>\r
-                       </currency>\r
-                       <currency type="PEI">\r
-                               <displayName>Peruvianske inti</displayName>\r
-                       </currency>\r
-                       <currency type="PEN">\r
-                               <displayName>Peruvianske sol nuevo</displayName>\r
-                       </currency>\r
-                       <currency type="PES">\r
-                               <displayName>Peruvianske sol</displayName>\r
-                       </currency>\r
-                       <currency type="PGK">\r
-                               <displayName>Papuanske kina</displayName>\r
-                       </currency>\r
-                       <currency type="PHP">\r
-                               <displayName>Filippinske pesos</displayName>\r
-                       </currency>\r
-                       <currency type="PKR">\r
-                               <displayName>Pakistanske rupier</displayName>\r
-                               <symbol>Pra</symbol>\r
-                       </currency>\r
-                       <currency type="PLN">\r
-                               <displayName>Polske zloty</displayName>\r
-                               <symbol>Zl</symbol>\r
-                       </currency>\r
-                       <currency type="PLZ">\r
-                               <displayName>Polske zloty (1950-1995)</displayName>\r
-                       </currency>\r
-                       <currency type="PTE">\r
-                               <displayName>Portugisiske escudo</displayName>\r
-                       </currency>\r
-                       <currency type="PYG">\r
-                               <displayName>Paraguayanske guarani</displayName>\r
-                       </currency>\r
-                       <currency type="QAR">\r
-                               <displayName>Qatarske riyaler</displayName>\r
-                               <symbol>QR</symbol>\r
-                       </currency>\r
-                       <currency type="ROL">\r
-                               <displayName>Rumenske leu</displayName>\r
-                               <symbol>leu</symbol>\r
-                       </currency>\r
-                       <currency type="RUB">\r
-                               <displayName>Russiske rubler</displayName>\r
-                       </currency>\r
-                       <currency type="RUR">\r
-                               <displayName>Russiske rubler (1991-1998)</displayName>\r
-                       </currency>\r
-                       <currency type="RWF">\r
-                               <displayName>Rwandiske franc</displayName>\r
-                       </currency>\r
-                       <currency type="SAR">\r
-                               <displayName>Saudiarabiske riyaler</displayName>\r
-                               <symbol>SRl</symbol>\r
-                       </currency>\r
-                       <currency type="SBD">\r
-                               <displayName>Salomonske dollar</displayName>\r
-                               <symbol>SI$</symbol>\r
-                       </currency>\r
-                       <currency type="SCR">\r
-                               <displayName>Seychelliske rupier</displayName>\r
-                               <symbol>SR</symbol>\r
-                       </currency>\r
-                       <currency type="SDD">\r
-                               <displayName>Sudanesiske dinarer</displayName>\r
-                       </currency>\r
-                       <currency type="SDP">\r
-                               <displayName>Sudanesiske pund</displayName>\r
-                       </currency>\r
-                       <currency type="SEK">\r
-                               <displayName>Svenske kroner</displayName>\r
-                               <symbol>SKr</symbol>\r
-                       </currency>\r
-                       <currency type="SGD">\r
-                               <displayName>Singaporske dollar</displayName>\r
-                               <symbol>S$</symbol>\r
-                       </currency>\r
-                       <currency type="SHP">\r
-                               <displayName>Sankthelenske pund</displayName>\r
-                       </currency>\r
-                       <currency type="SIT">\r
-                               <displayName>Slovenske tolar</displayName>\r
-                       </currency>\r
-                       <currency type="SKK">\r
-                               <displayName>Slovakiske koruna</displayName>\r
-                               <symbol>Sk</symbol>\r
-                       </currency>\r
-                       <currency type="SLL">\r
-                               <displayName>Sierraleonske leone</displayName>\r
-                       </currency>\r
-                       <currency type="SOS">\r
-                               <displayName>Somaliske shilling</displayName>\r
-                               <symbol>So. Sh.</symbol>\r
-                       </currency>\r
-                       <currency type="SRG">\r
-                               <displayName>Surinamske gylden</displayName>\r
-                               <symbol>Sf</symbol>\r
-                       </currency>\r
-                       <currency type="STD">\r
-                               <displayName>Sao Tome og Principe-dobra</displayName>\r
-                               <symbol>Db</symbol>\r
-                       </currency>\r
-                       <currency type="SUR">\r
-                               <displayName>Sovjetiske rubler</displayName>\r
-                       </currency>\r
-                       <currency type="SVC">\r
-                               <displayName>Salvadoranske colon</displayName>\r
-                       </currency>\r
-                       <currency type="SYP">\r
-                               <displayName>Syriske pund</displayName>\r
-                               <symbol>LS</symbol>\r
-                       </currency>\r
-                       <currency type="SZL">\r
-                               <displayName>Swazilandske lilangeni</displayName>\r
-                               <symbol>E</symbol>\r
-                       </currency>\r
-                       <currency type="THB">\r
-                               <displayName>Thailandske baht</displayName>\r
-                       </currency>\r
-                       <currency type="TJR">\r
-                               <displayName>Tadsjikiske rubler</displayName>\r
-                       </currency>\r
-                       <currency type="TJS">\r
-                               <displayName>Tadsjikiske somoni</displayName>\r
-                       </currency>\r
-                       <currency type="TMM">\r
-                               <displayName>Turkmenske manat</displayName>\r
-                       </currency>\r
-                       <currency type="TND">\r
-                               <displayName>Tunisiske dinarer</displayName>\r
-                       </currency>\r
-                       <currency type="TOP">\r
-                               <displayName>Tonganske paʻanga</displayName>\r
-                               <symbol>T$</symbol>\r
-                       </currency>\r
-                       <currency type="TPE">\r
-                               <displayName>Timoresiske escudo</displayName>\r
-                       </currency>\r
-                       <currency type="TRL">\r
-                               <displayName>Tyrkiske lira</displayName>\r
-                               <symbol>TL</symbol>\r
-                       </currency>\r
-                       <currency type="TRY">\r
-                               <displayName>Ny tyrkisk lire</displayName>\r
-                       </currency>\r
-                       <currency type="TTD">\r
-                               <displayName>Trinidadiske dollar</displayName>\r
-                               <symbol>TT$</symbol>\r
-                       </currency>\r
-                       <currency type="TWD">\r
-                               <displayName>Taiwanske nye dollar</displayName>\r
-                               <symbol>NT$</symbol>\r
-                       </currency>\r
-                       <currency type="TZS">\r
-                               <displayName>Tanzanianske shilling</displayName>\r
-                               <symbol>T Sh</symbol>\r
-                       </currency>\r
-                       <currency type="UAH">\r
-                               <displayName>Ukrainsle hryvnia</displayName>\r
-                       </currency>\r
-                       <currency type="UAK">\r
-                               <displayName>Ukrainske karbovanetz</displayName>\r
-                       </currency>\r
-                       <currency type="UGS">\r
-                               <displayName>Ugandiske shilling (1966-1987)</displayName>\r
-                       </currency>\r
-                       <currency type="UGX">\r
-                               <displayName>Ugandiske shilling</displayName>\r
-                               <symbol>U Sh</symbol>\r
-                       </currency>\r
-                       <currency type="USD">\r
-                               <displayName>Amerikanske dollar</displayName>\r
-                               <symbol>US$</symbol>\r
-                       </currency>\r
-                       <currency type="USN">\r
-                               <displayName>Amerikanske dollar (neste dag)</displayName>\r
-                       </currency>\r
-                       <currency type="USS">\r
-                               <displayName>Amerikanske dollar (samme dag)</displayName>\r
-                       </currency>\r
-                       <currency type="UYP">\r
-                               <displayName>Uruguayanske pesos (1975-1993)</displayName>\r
-                       </currency>\r
-                       <currency type="UYU">\r
-                               <displayName>Uruguayanske peso uruguayo</displayName>\r
-                               <symbol>Ur$</symbol>\r
-                       </currency>\r
-                       <currency type="UZS">\r
-                               <displayName>Usbekiske sum</displayName>\r
-                       </currency>\r
-                       <currency type="VEB">\r
-                               <displayName>Venezuelanske bolivar</displayName>\r
-                               <symbol>Be</symbol>\r
-                       </currency>\r
-                       <currency type="VND">\r
-                               <displayName>Vietnamesiske dong</displayName>\r
-                       </currency>\r
-                       <currency type="VUV">\r
-                               <displayName>Vanuatisk vatu</displayName>\r
-                               <symbol>VT</symbol>\r
-                       </currency>\r
-                       <currency type="WST">\r
-                               <displayName>Vestsamoisk tala</displayName>\r
-                       </currency>\r
-                       <currency type="XAF">\r
-                               <displayName>CFA Franc BEAC</displayName>\r
-                       </currency>\r
-                       <currency type="XAU">\r
-                               <displayName>Gull</displayName>\r
-                       </currency>\r
-                       <currency type="XBA">\r
-                               <displayName>European Composite Unit</displayName>\r
-                       </currency>\r
-                       <currency type="XBB">\r
-                               <displayName>European Monetary Unit</displayName>\r
-                       </currency>\r
-                       <currency type="XBC">\r
-                               <displayName>European Unit of Account (XBC)</displayName>\r
-                       </currency>\r
-                       <currency type="XBD">\r
-                               <displayName>European Unit of Account (XBD)</displayName>\r
-                       </currency>\r
-                       <currency type="XCD">\r
-                               <displayName>Østkaribiske dollar</displayName>\r
-                               <symbol>EC$</symbol>\r
-                       </currency>\r
-                       <currency type="XDR">\r
-                               <displayName>Special Drawing Rights</displayName>\r
-                       </currency>\r
-                       <currency type="XEU">\r
-                               <displayName>European Currency Unit</displayName>\r
-                       </currency>\r
-                       <currency type="XFO">\r
-                               <displayName>French Gold Franc</displayName>\r
-                       </currency>\r
-                       <currency type="XFU">\r
-                               <displayName>French UIC-Franc</displayName>\r
-                       </currency>\r
-                       <currency type="XOF">\r
-                               <displayName>CFA Franc BCEAO</displayName>\r
-                       </currency>\r
-                       <currency type="XPF">\r
-                               <displayName>CFP Franc</displayName>\r
-                               <symbol>CFPF</symbol>\r
-                       </currency>\r
-                       <currency type="YDD">\r
-                               <displayName>Jemenittiske dinarer</displayName>\r
-                       </currency>\r
-                       <currency type="YER">\r
-                               <displayName>Jemenittiske rialer</displayName>\r
-                               <symbol>YRl</symbol>\r
-                       </currency>\r
-                       <currency type="YUD">\r
-                               <displayName>Jugoslaviske dinarer (hard)</displayName>\r
-                       </currency>\r
-                       <currency type="YUM">\r
-                               <displayName>Jugoslaviske noviy-dinarer</displayName>\r
-                       </currency>\r
-                       <currency type="YUN">\r
-                               <displayName>Jugoslaviske konvertible dinarer</displayName>\r
-                       </currency>\r
-                       <currency type="ZAL">\r
-                               <displayName>Sørafrikanske rand (økonomisk)</displayName>\r
-                       </currency>\r
-                       <currency type="ZAR">\r
-                               <displayName>Sørafrikanske rand</displayName>\r
-                               <symbol>R</symbol>\r
-                       </currency>\r
-                       <currency type="ZMK">\r
-                               <displayName>Zambiske kwacha</displayName>\r
-                       </currency>\r
-                       <currency type="ZRN">\r
-                               <displayName>Zairiske nye zaire</displayName>\r
-                       </currency>\r
-                       <currency type="ZRZ">\r
-                               <displayName>Zairiske zaire</displayName>\r
-                       </currency>\r
-                       <currency type="ZWD">\r
-                               <displayName>Zimbabwiske dollar</displayName>\r
-                               <symbol>Z$</symbol>\r
-                       </currency>\r
-               </currencies>\r
-       </numbers>\r
-       <references>\r
-               <reference type="R1" uri="URN:ISBN:82-03-32936-5">Vinje, Finn-Erik, Skriveregler (1994)</reference>\r
-       </references>\r
-</ldml>\r
-<!-- Old Comments. See root.xml for more info.\r
-URL: http://oss.software.ibm.com/cvs/icu/icu/source/data/locales/nb.txt?only_with_tag=final-update-LDML\r
-\r
-        FK { "Falklands\u00F8yene (Malvinas)" }    // alternate name { "Falklands\u00F8yene" }\r
-        KP { "Nord-Korea" }    // alternate name { "Korea, Den demokratiske republikken" }\r
-        KR { "S\u00f8r-Korea" }    // alternate name { "Korea, Republikken" }\r
-LY { "Libya, Den arabiske republikken" }\r
-SH { "St. Helena" }\r
-SY { "Syria" }    // alternate name { "Syria, Den arabiske republikken" }\r
-zh_cn { "kinesisk (forenklet)" }\r
-zh_tw { "kinesisk (tradisjonell)" }\r
-        Hans { "forenklet han" } // Not a formal part of ISO-15924 yet\r
-        Hant { "tradisjonell han" } // Not a formal part of ISO-15924 yet\r
-        Qaai { "nedarvet" } // PUA\r
-        Zyyy { "generelt" } // This may need to become "undetermined script"\r
-EURO    { "Europeisk" }\r
-PREEURO { "F\u00f8r-eruropeisk" }\r
-\r
-Comments without bases\r
-\r
- Spain          - was on: /ldml/dates/timeZoneNames/zone[@type="Atlantic/Canary"]\r
- Kiribati       - was on: /ldml/dates/timeZoneNames/zone[@type="Pacific/Enderbury"]\r
- Marshall Islands       - was on: /ldml/dates/timeZoneNames/zone[@type="Pacific/Kwajalein"]\r
- Mali   - was on: /ldml/dates/timeZoneNames/zone[@type="Africa/Bamako"]\r
- Ecuador        - was on: /ldml/dates/timeZoneNames/zone[@type="Pacific/Galapagos"]\r
- Indonesia      - was on: /ldml/dates/timeZoneNames/zone[@type="Asia/Jakarta"]\r
- Russia         - was on: /ldml/dates/timeZoneNames/zone[@type="Europe/Kaliningrad"]\r
- United States          - was on: /ldml/dates/timeZoneNames/zone[@type="America/Adak"]\r
- Kazakhstan     - was on: /ldml/dates/timeZoneNames/zone[@type="Asia/Aqtau"]\r
- Ukraine        - was on: /ldml/dates/timeZoneNames/zone[@type="Europe/Uzhgorod"]\r
- Brazil         - was on: /ldml/dates/timeZoneNames/zone[@type="America/Eirunepe"]\r
- Antarctica     - was on: /ldml/dates/timeZoneNames/zone[@type="Antarctica/Rothera"]\r
- Malaysia       - was on: /ldml/dates/timeZoneNames/zone[@type="Asia/Kuala_Lumpur"]\r
- Canada         - was on: /ldml/dates/timeZoneNames/zone[@type="America/Dawson"]\r
- Micronesia     - was on: /ldml/dates/timeZoneNames/zone[@type="Pacific/Yap"]\r
- Argentina      - was on: /ldml/dates/timeZoneNames/zone[@type="America/Argentina/Rio_Gallegos"]\r
- United States Minor Outlying Islands   - was on: /ldml/dates/timeZoneNames/zone[@type="Pacific/Midway"]\r
- Mexico         - was on: /ldml/dates/timeZoneNames/zone[@type="America/Tijuana"]\r
- Democratic Republic of the Congo       - was on: /ldml/dates/timeZoneNames/zone[@type="Africa/Kinshasa"]\r
- United Kingdom         - was on: /ldml/dates/timeZoneNames/zone[@type="Europe/Belfast"]\r
- French Polynesia       - was on: /ldml/dates/timeZoneNames/zone[@type="Pacific/Tahiti"]\r
- Chile          - was on: /ldml/dates/timeZoneNames/zone[@type="Pacific/Easter"]\r
- New Zealand    - was on: /ldml/dates/timeZoneNames/zone[@type="Pacific/Chatham"]\r
- Greenland      - was on: /ldml/dates/timeZoneNames/zone[@type="America/Thule"]\r
- Mongolia       - was on: /ldml/dates/timeZoneNames/zone[@type="Asia/Hovd"]\r
- Uzbekistan     - was on: /ldml/dates/timeZoneNames/zone[@type="Asia/Samarkand"]\r
- Svalbard and Jan Mayen         - was on: /ldml/dates/timeZoneNames/zone[@type="Atlantic/Jan_Mayen"]\r
- Australia      - was on: /ldml/dates/timeZoneNames/zone[@type="Australia/Perth"]\r
- China          - was on: /ldml/dates/timeZoneNames/zone[@type="Asia/Kashgar"]\r
--->\r
-\r
diff --git a/tools/locale-builder/langs/nn.xml b/tools/locale-builder/langs/nn.xml
deleted file mode 100644 (file)
index 658af6e..0000000
+++ /dev/null
@@ -1,560 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>\r
-<!DOCTYPE ldml SYSTEM "http://www.unicode.org/cldr/dtd/1.3/ldml.dtd">\r
-<ldml>\r
-       <identity>\r
-               <version number="$Revision: 1.41 $"/>\r
-               <generation date="$Date: 2005/05/03 16:03:26 $"/>\r
-               <language type="nn"/>\r
-       </identity>\r
-       <localeDisplayNames>\r
-               <languages>\r
-                       <language type="ar" draft="true">Arabisk</language>\r
-                       <language type="de" draft="true">Tysk</language>\r
-                       <language type="en" draft="true">Engelsk</language>\r
-                       <language type="es" draft="true">Spansk</language>\r
-                       <language type="fr" draft="true">Fransk</language>\r
-                       <language type="it" draft="true">Italiensk</language>\r
-                       <language type="ja" draft="true">Japansk</language>\r
-                       <language type="nb">norsk bokmål</language>\r
-                       <language type="nn">norsk nynorsk</language>\r
-                       <language type="no">norsk</language>\r
-                       <language type="pt" draft="true">Portugisisk</language>\r
-                       <language type="ru" draft="true">Russisk</language>\r
-                       <language type="zh" draft="true">Kinesisk</language>\r
-               </languages>\r
-               <scripts>\r
-                       <script type="Latn" draft="true">Latinsk</script>\r
-               </scripts>\r
-               <territories>\r
-                       <territory type="001" draft="true">Verden</territory>\r
-                       <territory type="002" draft="true">Afrika</territory>\r
-                       <territory type="005" draft="true">Sør-Amerika</territory>\r
-                       <territory type="009" draft="true">Oseania</territory>\r
-                       <territory type="011" draft="true">Vest-Afrika</territory>\r
-                       <territory type="013" draft="true">Sentral-Amerika</territory>\r
-                       <territory type="014" draft="true">Aust-Afrika</territory>\r
-                       <territory type="015" draft="true">Nord-Afrika</territory>\r
-                       <territory type="017" draft="true">Sentral-Afrika</territory>\r
-                       <territory type="018" draft="true">Sørlege Afrika</territory>\r
-                       <territory type="019" draft="true">Amerika</territory>\r
-                       <territory type="021" draft="true">Nord-Amerika</territory>\r
-                       <territory type="029" draft="true">Karibiske hav</territory>\r
-                       <territory type="030" draft="true">Aust-Asia</territory>\r
-                       <territory type="035" draft="true">Søraust-Asia</territory>\r
-                       <territory type="039" draft="true">Sør-Europa</territory>\r
-                       <territory type="053" draft="true">Australia og New Zealand</territory>\r
-                       <territory type="054" draft="true">Melanesia</territory>\r
-                       <territory type="057" draft="true">Mikronesia</territory>\r
-                       <territory type="061" draft="true">Polynesia</territory>\r
-                       <territory type="062" draft="true">Sørlege Sentral-Asia</territory>\r
-                       <territory type="142" draft="true">Asia</territory>\r
-                       <territory type="145" draft="true">Vest-Asia</territory>\r
-                       <territory type="150" draft="true">Europa</territory>\r
-                       <territory type="151" draft="true">Aust-Europa</territory>\r
-                       <territory type="154" draft="true">Nord-Europa</territory>\r
-                       <territory type="155" draft="true">Vest-Europa</territory>\r
-                       <territory type="830" draft="true">Kanaløyene</territory>\r
-                       <territory type="833" draft="true">Man</territory>\r
-                       <territory type="AD">Andorra</territory>\r
-                       <territory type="AE">De forente arabiske emiratene</territory>\r
-                       <territory type="AF">Afghanistan</territory>\r
-                       <territory type="AG">Antigua og Barbuda</territory>\r
-                       <territory type="AI">Anguilla</territory>\r
-                       <territory type="AL">Albania</territory>\r
-                       <territory type="AM">Armenia</territory>\r
-                       <territory type="AN">De nederlandske antiller</territory>\r
-                       <territory type="AO">Angola</territory>\r
-                       <territory type="AQ">Antarktis</territory>\r
-                       <territory type="AR">Argentina</territory>\r
-                       <territory type="AS">Amerikansk Samoa</territory>\r
-                       <territory type="AT">Østerrike</territory>\r
-                       <territory type="AU">Australia</territory>\r
-                       <territory type="AW">Aruba</territory>\r
-                       <territory type="AX" draft="true">Åland</territory>\r
-                       <territory type="AZ">Aserbajdsjan</territory>\r
-                       <territory type="BA">Bosnia og Hercegovina</territory>\r
-                       <territory type="BB">Barbados</territory>\r
-                       <territory type="BD">Bangladesh</territory>\r
-                       <territory type="BE">Belgia</territory>\r
-                       <territory type="BF">Burkina Faso</territory>\r
-                       <territory type="BG">Bulgaria</territory>\r
-                       <territory type="BH">Bahrain</territory>\r
-                       <territory type="BI">Burundi</territory>\r
-                       <territory type="BJ">Benin</territory>\r
-                       <territory type="BM">Bermuda</territory>\r
-                       <territory type="BN">Brunei Darussalam</territory>\r
-                       <territory type="BO">Bolivia</territory>\r
-                       <territory type="BR">Brasil</territory>\r
-                       <territory type="BS">Bahamas</territory>\r
-                       <territory type="BT">Bhutan</territory>\r
-                       <territory type="BV">Bouvetøya</territory>\r
-                       <territory type="BW">Botswana</territory>\r
-                       <territory type="BY">Hviterussland</territory>\r
-                       <territory type="BZ">Belize</territory>\r
-                       <territory type="CA">Canada</territory>\r
-                       <territory type="CC">Kokosøyene (Keelingøyene)</territory>\r
-                       <territory type="CD">Kongo, Den demokratiske republikken</territory>\r
-                       <territory type="CF">Den sentralafrikanske republikk</territory>\r
-                       <territory type="CG">Kongo</territory>\r
-                       <territory type="CH">Sveits</territory>\r
-                       <territory type="CI">Elfenbenskysten</territory>\r
-                       <territory type="CK">Cookøyene</territory>\r
-                       <territory type="CL">Chile</territory>\r
-                       <territory type="CM">Kamerun</territory>\r
-                       <territory type="CN">Kina</territory>\r
-                       <territory type="CO">Colombia</territory>\r
-                       <territory type="CR">Costa Rica</territory>\r
-                       <territory type="CS" draft="true">Serbia Montenegro</territory>\r
-                       <territory type="CU">Cuba</territory>\r
-                       <territory type="CV">Kapp Verde</territory>\r
-                       <territory type="CX">Christmasøya</territory>\r
-                       <territory type="CY">Kypros</territory>\r
-                       <territory type="CZ">Tsjekkia</territory>\r
-                       <territory type="DE">Tyskland</territory>\r
-                       <territory type="DJ">Djibouti</territory>\r
-                       <territory type="DK">Danmark</territory>\r
-                       <territory type="DM">Dominica</territory>\r
-                       <territory type="DO">Den dominikanske republikk</territory>\r
-                       <territory type="DZ">Algerie</territory>\r
-                       <territory type="EC">Ecuador</territory>\r
-                       <territory type="EE">Estland</territory>\r
-                       <territory type="EG">Egypt</territory>\r
-                       <territory type="EH">Vest-Sahara</territory>\r
-                       <territory type="ER">Eritrea</territory>\r
-                       <territory type="ES">Spania</territory>\r
-                       <territory type="ET">Etiopia</territory>\r
-                       <territory type="FI">Finland</territory>\r
-                       <territory type="FJ">Fiji</territory>\r
-                       <territory type="FK">Falklandsøyene (Malvinas)</territory>\r
-                       <territory type="FM">Mikronesiaføderasjonen</territory>\r
-                       <territory type="FO">Færøyene</territory>\r
-                       <territory type="FR">Frankrike</territory>\r
-                       <territory type="GA">Gabon</territory>\r
-                       <territory type="GB">Storbritannia</territory>\r
-                       <territory type="GD">Grenada</territory>\r
-                       <territory type="GE">Georgia</territory>\r
-                       <territory type="GF">Fransk Guyana</territory>\r
-                       <territory type="GH">Ghana</territory>\r
-                       <territory type="GI">Gibraltar</territory>\r
-                       <territory type="GL">Grønland</territory>\r
-                       <territory type="GM">Gambia</territory>\r
-                       <territory type="GN">Guinea</territory>\r
-                       <territory type="GP">Guadeloupe</territory>\r
-                       <territory type="GQ">Ekvatorial-Guinea</territory>\r
-                       <territory type="GR">Hellas</territory>\r
-                       <territory type="GS">Sør-Georgia og Sør-Sandwich-øyene</territory>\r
-                       <territory type="GT">Guatemala</territory>\r
-                       <territory type="GU">Guam</territory>\r
-                       <territory type="GW">Guinea-Bissau</territory>\r
-                       <territory type="GY">Guyana</territory>\r
-                       <territory type="HK">Hong Kong S.A.R. (Kina)</territory>\r
-                       <territory type="HM">Heard- og McDonaldsøyene</territory>\r
-                       <territory type="HN">Honduras</territory>\r
-                       <territory type="HR">Kroatia</territory>\r
-                       <territory type="HT">Haiti</territory>\r
-                       <territory type="HU">Ungarn</territory>\r
-                       <territory type="ID">Indonesia</territory>\r
-                       <territory type="IE">Irland</territory>\r
-                       <territory type="IL">Israel</territory>\r
-                       <territory type="IN">India</territory>\r
-                       <territory type="IO">Britiske områder i det indiske hav</territory>\r
-                       <territory type="IQ">Irak</territory>\r
-                       <territory type="IR">Iran</territory>\r
-                       <territory type="IS">Island</territory>\r
-                       <territory type="IT">Italia</territory>\r
-                       <territory type="JM">Jamaica</territory>\r
-                       <territory type="JO">Jordan</territory>\r
-                       <territory type="JP">Japan</territory>\r
-                       <territory type="KE">Kenya</territory>\r
-                       <territory type="KG">Kirgisistan</territory>\r
-                       <territory type="KH">Kambodsja</territory>\r
-                       <territory type="KI">Kiribati</territory>\r
-                       <territory type="KM">Komorene</territory>\r
-                       <territory type="KN">St. Christopher og Nevis</territory>\r
-                       <territory type="KP">Nord-Korea</territory>\r
-                       <territory type="KR">Sør-Korea</territory>\r
-                       <territory type="KW">Kuwait</territory>\r
-                       <territory type="KY">Caymanøyene</territory>\r
-                       <territory type="KZ">Kasakhstan</territory>\r
-                       <territory type="LA">Laos, Den folkedemokratiske republikken</territory>\r
-                       <territory type="LB">Libanon</territory>\r
-                       <territory type="LC">St. Lucia</territory>\r
-                       <territory type="LI">Liechtenstein</territory>\r
-                       <territory type="LK">Sri Lanka</territory>\r
-                       <territory type="LR">Liberia</territory>\r
-                       <territory type="LS">Lesotho</territory>\r
-                       <territory type="LT">Litauen</territory>\r
-                       <territory type="LU">Luxembourg</territory>\r
-                       <territory type="LV">Latvia</territory>\r
-                       <territory type="LY">Libya</territory>\r
-                       <territory type="MA">Marokko</territory>\r
-                       <territory type="MC">Monaco</territory>\r
-                       <territory type="MD">Moldova</territory>\r
-                       <territory type="MG">Madagaskar</territory>\r
-                       <territory type="MH">Marshalløyene</territory>\r
-                       <territory type="MK">Makedonia, Republikken</territory>\r
-                       <territory type="ML">Mali</territory>\r
-                       <territory type="MM">Myanmar</territory>\r
-                       <territory type="MN">Mongolia</territory>\r
-                       <territory type="MO">Macao S.A.R. (Kina)</territory>\r
-                       <territory type="MP">Nord-Marianene</territory>\r
-                       <territory type="MQ">Martinique</territory>\r
-                       <territory type="MR">Mauritania</territory>\r
-                       <territory type="MS">Montserrat</territory>\r
-                       <territory type="MT">Malta</territory>\r
-                       <territory type="MU">Mauritius</territory>\r
-                       <territory type="MV">Maldivene</territory>\r
-                       <territory type="MW">Malawi</territory>\r
-                       <territory type="MX">Mexico</territory>\r
-                       <territory type="MY">Malaysia</territory>\r
-                       <territory type="MZ">Mosambik</territory>\r
-                       <territory type="NA">Namibia</territory>\r
-                       <territory type="NC">Ny-Caledonia</territory>\r
-                       <territory type="NE">Niger</territory>\r
-                       <territory type="NF">Norfolkøyene</territory>\r
-                       <territory type="NG">Nigeria</territory>\r
-                       <territory type="NI">Nicaragua</territory>\r
-                       <territory type="NL">Nederland</territory>\r
-                       <territory type="NO">Noreg</territory>\r
-                       <territory type="NP">Nepal</territory>\r
-                       <territory type="NR">Nauru</territory>\r
-                       <territory type="NU">Niue</territory>\r
-                       <territory type="NZ">New Zealand</territory>\r
-                       <territory type="OM">Oman</territory>\r
-                       <territory type="PA">Panama</territory>\r
-                       <territory type="PE">Peru</territory>\r
-                       <territory type="PF">Fransk Polynesia</territory>\r
-                       <territory type="PG">Papua Ny-Guinea</territory>\r
-                       <territory type="PH">Filippinene</territory>\r
-                       <territory type="PK">Pakistan</territory>\r
-                       <territory type="PL">Polen</territory>\r
-                       <territory type="PM">St. Pierre og Miquelon</territory>\r
-                       <territory type="PN">Pitcairn</territory>\r
-                       <territory type="PR">Puerto Rico</territory>\r
-                       <territory type="PS">Palestinsk territorium</territory>\r
-                       <territory type="PT">Portugal</territory>\r
-                       <territory type="PW">Palau</territory>\r
-                       <territory type="PY">Paraguay</territory>\r
-                       <territory type="QA">Qatar</territory>\r
-                       <territory type="QO" draft="true">Ytre Oseania</territory>\r
-                       <territory type="RE">Reunion</territory>\r
-                       <territory type="RO">Romania</territory>\r
-                       <territory type="RU">Den russiske føderasjon</territory>\r
-                       <territory type="RW">Rwanda</territory>\r
-                       <territory type="SA">Saudi Arabia</territory>\r
-                       <territory type="SB">Salomonøyene</territory>\r
-                       <territory type="SC">Seychellene</territory>\r
-                       <territory type="SD">Sudan</territory>\r
-                       <territory type="SE">Sverige</territory>\r
-                       <territory type="SG">Singapore</territory>\r
-                       <territory type="SH">Saint Helena</territory>\r
-                       <territory type="SI">Slovenia</territory>\r
-                       <territory type="SJ">Svalbard og Jan Mayen</territory>\r
-                       <territory type="SK">Slovakia</territory>\r
-                       <territory type="SL">Sierra Leone</territory>\r
-                       <territory type="SM">San Marino</territory>\r
-                       <territory type="SN">Senegal</territory>\r
-                       <territory type="SO">Somalia</territory>\r
-                       <territory type="SR">Surinam</territory>\r
-                       <territory type="ST">Sao Tome og Principe</territory>\r
-                       <territory type="SV">El Salvador</territory>\r
-                       <territory type="SY">Syria</territory>\r
-                       <territory type="SZ">Swaziland</territory>\r
-                       <territory type="TC">Turks- og Caicosøyene</territory>\r
-                       <territory type="TD">Tchad</territory>\r
-                       <territory type="TF">Franske sørområder</territory>\r
-                       <territory type="TG">Togo</territory>\r
-                       <territory type="TH">Thailand</territory>\r
-                       <territory type="TJ">Tadsjikistan</territory>\r
-                       <territory type="TK">Tokelau</territory>\r
-                       <territory type="TL">Øst-Timor</territory>\r
-                       <territory type="TM">Turkmenistan</territory>\r
-                       <territory type="TN">Tunisia</territory>\r
-                       <territory type="TO">Tonga</territory>\r
-                       <territory type="TR">Tyrkia</territory>\r
-                       <territory type="TT">Trinidad og Tobago</territory>\r
-                       <territory type="TV">Tuvalu</territory>\r
-                       <territory type="TW">Taiwan</territory>\r
-                       <territory type="TZ">Tanzania</territory>\r
-                       <territory type="UA">Ukraina</territory>\r
-                       <territory type="UG">Uganda</territory>\r
-                       <territory type="UM">USAs mindre øyer</territory>\r
-                       <territory type="US">USA</territory>\r
-                       <territory type="UY">Uruguay</territory>\r
-                       <territory type="UZ">Usbekistan</territory>\r
-                       <territory type="VA">Vatikanstaten</territory>\r
-                       <territory type="VC">St. Vincent og Grenadinene</territory>\r
-                       <territory type="VE">Venezuela</territory>\r
-                       <territory type="VG">Jomfruøyene (britisk)</territory>\r
-                       <territory type="VI">Jomfruøyene (USA)</territory>\r
-                       <territory type="VN">Vietnam</territory>\r
-                       <territory type="VU">Vanuatu</territory>\r
-                       <territory type="WF">Wallis og Futuna</territory>\r
-                       <territory type="WS">Samoa</territory>\r
-                       <territory type="YE">Yemen</territory>\r
-                       <territory type="YT">Mayotte</territory>\r
-                       <territory type="ZA">Sør-Afrika</territory>\r
-                       <territory type="ZM">Zambia</territory>\r
-                       <territory type="ZW">Zimbabwe</territory>\r
-               </territories>\r
-       </localeDisplayNames>\r
-       <characters>\r
-               <exemplarCharacters>[a-zæåøéóôàüǎ]</exemplarCharacters>\r
-       </characters>\r
-       <dates>\r
-               <calendars>\r
-                       <calendar type="gregorian">\r
-                               <months>\r
-                                       <monthContext type="format">\r
-                                               <monthWidth type="abbreviated">\r
-                                                       <month type="1">jan</month>\r
-                                                       <month type="1" alt="proposed" references="R1" draft="true">jan.</month>\r
-                                                       <month type="2">feb</month>\r
-                                                       <month type="2" alt="proposed" references="R1" draft="true">feb.</month>\r
-                                                       <month type="3">mar</month>\r
-                                                       <month type="3" alt="proposed" references="R1" draft="true">mars</month>\r
-                                                       <month type="4">apr</month>\r
-                                                       <month type="4" alt="proposed" references="R1" draft="true">april</month>\r
-                                                       <month type="5" references="R1">mai</month>\r
-                                                       <month type="6">jun</month>\r
-                                                       <month type="6" alt="proposed" references="R1" draft="true">juni</month>\r
-                                                       <month type="7">jul</month>\r
-                                                       <month type="7" alt="proposed" references="R1" draft="true">juli</month>\r
-                                                       <month type="8">aug</month>\r
-                                                       <month type="8" alt="proposed" references="R1" draft="true">aug.</month>\r
-                                                       <month type="9">sep</month>\r
-                                                       <month type="9" alt="proposed" references="R1" draft="true">sep.</month>\r
-                                                       <month type="10">okt</month>\r
-                                                       <month type="10" alt="proposed" references="R1" draft="true">okt.</month>\r
-                                                       <month type="11">nov</month>\r
-                                                       <month type="11" alt="proposed" references="R1" draft="true">nov.</month>\r
-                                                       <month type="12">des</month>\r
-                                                       <month type="12" alt="proposed" references="R1" draft="true">des.</month>\r
-                                               </monthWidth>\r
-                                               <monthWidth type="wide">\r
-                                                       <month type="1">januar</month>\r
-                                                       <month type="2">februar</month>\r
-                                                       <month type="3">mars</month>\r
-                                                       <month type="4">april</month>\r
-                                                       <month type="5">mai</month>\r
-                                                       <month type="6">juni</month>\r
-                                                       <month type="7">juli</month>\r
-                                                       <month type="8">august</month>\r
-                                                       <month type="9">september</month>\r
-                                                       <month type="10">oktober</month>\r
-                                                       <month type="11">november</month>\r
-                                                       <month type="12">desember</month>\r
-                                               </monthWidth>\r
-                                       </monthContext>\r
-                               </months>\r
-                               <days>\r
-                                       <dayContext type="format">\r
-                                               <dayWidth type="abbreviated">\r
-                                                       <day type="sun">su</day>\r
-                                                       <day type="sun" alt="proposed" references="R1" draft="true">su.</day>\r
-                                                       <day type="mon">må</day>\r
-                                                       <day type="mon" alt="proposed" references="R1" draft="true">må.</day>\r
-                                                       <day type="tue">ty</day>\r
-                                                       <day type="tue" alt="proposed" references="R1" draft="true">ty.</day>\r
-                                                       <day type="wed">on</day>\r
-                                                       <day type="wed" alt="proposed" references="R1" draft="true">on.</day>\r
-                                                       <day type="thu">to</day>\r
-                                                       <day type="thu" alt="proposed" references="R1" draft="true">to.</day>\r
-                                                       <day type="fri">fr</day>\r
-                                                       <day type="fri" alt="proposed" references="R1" draft="true">fr.</day>\r
-                                                       <day type="sat">la</day>\r
-                                                       <day type="sat" alt="proposed" references="R1" draft="true">la.</day>\r
-                                               </dayWidth>\r
-                                               <dayWidth type="wide">\r
-                                                       <day type="sun">sundag</day>\r
-                                                       <day type="mon">måndag</day>\r
-                                                       <day type="tue">tysdag</day>\r
-                                                       <day type="wed">onsdag</day>\r
-                                                       <day type="thu">torsdag</day>\r
-                                                       <day type="fri">fredag</day>\r
-                                                       <day type="sat">laurdag</day>\r
-                                               </dayWidth>\r
-                                       </dayContext>\r
-                                       <dayContext type="stand-alone">\r
-                                               <dayWidth type="narrow">\r
-                                                       <day type="sun" draft="true">S</day>\r
-                                                       <day type="mon" draft="true">M</day>\r
-                                                       <day type="tue" draft="true">T</day>\r
-                                                       <day type="wed" draft="true">O</day>\r
-                                                       <day type="thu" draft="true">T</day>\r
-                                                       <day type="fri" draft="true">F</day>\r
-                                                       <day type="sat" draft="true">L</day>\r
-                                               </dayWidth>\r
-                                       </dayContext>\r
-                               </days>\r
-                               <week>\r
-                                       <minDays count="4"/>\r
-                                       <firstDay day="mon"/>\r
-                               </week>\r
-                               <am draft="true">a.m.</am>\r
-                               <pm draft="true">p.m.</pm>\r
-                               <eras>\r
-                                       <eraAbbr>\r
-                                               <era type="0">f.Kr.</era>\r
-                                               <era type="1">e.Kr.</era>\r
-                                       </eraAbbr>\r
-                               </eras>\r
-                               <dateFormats>\r
-                                       <dateFormatLength type="full">\r
-                                               <dateFormat>\r
-                                                       <pattern>EEEE d. MMMM yyyy</pattern>\r
-                                               </dateFormat>\r
-                                       </dateFormatLength>\r
-                                       <dateFormatLength type="long">\r
-                                               <dateFormat>\r
-                                                       <pattern>d. MMMM yyyy</pattern>\r
-                                               </dateFormat>\r
-                                       </dateFormatLength>\r
-                                       <dateFormatLength type="medium">\r
-                                               <dateFormat>\r
-                                                       <pattern>d. MMM. yyyy</pattern>\r
-                                               </dateFormat>\r
-                                       </dateFormatLength>\r
-                                       <dateFormatLength type="short">\r
-                                               <dateFormat>\r
-                                                       <pattern>dd.MM.yy</pattern>\r
-                                               </dateFormat>\r
-                                       </dateFormatLength>\r
-                               </dateFormats>\r
-                               <timeFormats>\r
-                                       <timeFormatLength type="full">\r
-                                               <timeFormat>\r
-                                                       <pattern>'kl. 'HH.mm.ss z</pattern>\r
-                                               </timeFormat>\r
-                                       </timeFormatLength>\r
-                                       <timeFormatLength type="long">\r
-                                               <timeFormat>\r
-                                                       <pattern>HH.mm.ss z</pattern>\r
-                                               </timeFormat>\r
-                                       </timeFormatLength>\r
-                                       <timeFormatLength type="medium">\r
-                                               <timeFormat>\r
-                                                       <pattern>HH.mm.ss</pattern>\r
-                                               </timeFormat>\r
-                                       </timeFormatLength>\r
-                                       <timeFormatLength type="short">\r
-                                               <timeFormat>\r
-                                                       <pattern>HH.mm</pattern>\r
-                                               </timeFormat>\r
-                                       </timeFormatLength>\r
-                               </timeFormats>\r
-                       </calendar>\r
-               </calendars>\r
-               <timeZoneNames>\r
-                       <hourFormat>+HH.mm;-HH.mm</hourFormat>\r
-                       <!-- Antarktis -->\r
-                       <zone type="Antarctica/South_Pole">\r
-                               <exemplarCity draft="true">Sørpolen</exemplarCity>\r
-                       </zone>\r
-                       <!-- Argentina\r
-                                Australia\r
-                                Brazil\r
-                                Canada\r
-                                Kongo, Den demokratiske republikken\r
-                                Chile\r
-                       -->\r
-                       <zone type="Pacific/Easter">\r
-                               <exemplarCity draft="true">Påskeøya</exemplarCity>\r
-                       </zone>\r
-                       <!-- China\r
-                                Ecuador\r
-                                Spain\r
-                       -->\r
-                       <zone type="Atlantic/Canary">\r
-                               <exemplarCity draft="true">Kanariøyene</exemplarCity>\r
-                       </zone>\r
-                       <!-- Micronesia\r
-                                United Kingdom\r
-                                Greenland\r
-                       -->\r
-                       <zone type="America/Godthab">\r
-                               <exemplarCity draft="true">Godthåb</exemplarCity>\r
-                       </zone>\r
-                       <!-- Indonesia\r
-                                Kiribati\r
-                                Kasakhstan\r
-                                Marshall Islands\r
-                                Mali\r
-                                Mongolia\r
-                       -->\r
-                       <zone type="Asia/Ulaanbaatar">\r
-                               <exemplarCity draft="true">Ulan Bator</exemplarCity>\r
-                       </zone>\r
-                       <!-- Mexico -->\r
-                       <zone type="America/Mexico_City">\r
-                               <exemplarCity draft="true">Mexico by</exemplarCity>\r
-                       </zone>\r
-                       <!-- Malaysia\r
-                                New Zealand\r
-                                French Polynesia\r
-                                Portugal\r
-                       -->\r
-                       <zone type="Atlantic/Azores">\r
-                               <exemplarCity draft="true">Azorene</exemplarCity>\r
-                       </zone>\r
-                       <zone type="Europe/Lisbon">\r
-                               <exemplarCity draft="true">Lisboa</exemplarCity>\r
-                       </zone>\r
-                       <!-- Russia -->\r
-                       <zone type="Europe/Moscow">\r
-                               <exemplarCity draft="true">Moskva</exemplarCity>\r
-                       </zone>\r
-                       <!-- Svalbard and Jan Mayen\r
-                                Ukraine\r
-                                United States Minor Outlying Islands\r
-                                United States\r
-                                Usbekistan\r
-                       -->\r
-                       <zone type="Asia/Tashkent">\r
-                               <exemplarCity draft="true">Tasjkent</exemplarCity>\r
-                       </zone>\r
-               </timeZoneNames>\r
-       </dates>\r
-       <numbers>\r
-               <symbols>\r
-                       <decimal>,</decimal>\r
-                       <group> </group>\r
-               </symbols>\r
-               <currencies>\r
-                       <currency type="BRL">\r
-                               <displayName draft="true">Brasilianske real</displayName>\r
-                       </currency>\r
-                       <currency type="CNY">\r
-                               <displayName draft="true">Kinesiske yuan renminbi</displayName>\r
-                       </currency>\r
-                       <currency type="GBP">\r
-                               <displayName draft="true">Britiske pund</displayName>\r
-                       </currency>\r
-                       <currency type="INR">\r
-                               <displayName draft="true">Indiske rupi</displayName>\r
-                       </currency>\r
-                       <currency type="NOK">\r
-                               <symbol>kr</symbol>\r
-                       </currency>\r
-                       <currency type="NOK" alt="proposed">\r
-                               <displayName draft="true">Norske kroner</displayName>\r
-                       </currency>\r
-                       <currency type="RUB">\r
-                               <displayName draft="true">Russiske rubler</displayName>\r
-                       </currency>\r
-                       <currency type="USD">\r
-                               <displayName draft="true">Amerikanske dollar</displayName>\r
-                       </currency>\r
-               </currencies>\r
-       </numbers>\r
-       <references>\r
-               <reference type="R1" uri="URN:ISBN:82-03-32936-5">Vinje, Finn-Erik, Skriveregler (1994)</reference>\r
-       </references>\r
-</ldml>\r
-<!-- Old Comments. See root.xml for more info.\r
-URL: http://oss.software.ibm.com/cvs/icu/icu/source/data/locales/nn.txt?only_with_tag=final-update-LDML\r
-\r
-Currency display names\r
-        "Latn",  // ISO 15924 Name\r
--->\r
-\r
old mode 100755 (executable)
new mode 100644 (file)
index eddbe6f..6f22bab
 <lcids>\r
-  <lcid name="ar" id="0x0001" parent="0x007F" specific="0x0401" iso2="ar" iso3="ara" win="ARA" icu_name="Arabic" />\r
-  <lcid name="bg" id="0x0002" parent="0x007F" specific="0x0402" iso2="bg" iso3="bul" win="BGR" icu_name="Bulgarian" />\r
-  <lcid name="ca" id="0x0003" parent="0x007F" specific="0x0403" iso2="ca" iso3="cat" win="CAT" icu_name="Catalan" />\r
-  <lcid name="zh-CHS" id="0x0004" parent="0x007F" specific="0x0000" iso2="zh" iso3="zho" win="CHS" icu_name="Chinese" />\r
-  <lcid name="cs" id="0x0005" parent="0x007F" specific="0x0405" iso2="cs" iso3="ces" win="CSY" icu_name="Czech" />\r
-  <lcid name="da" id="0x0006" parent="0x007F" specific="0x0406" iso2="da" iso3="dan" win="DAN" icu_name="Danish" />\r
-  <lcid name="de" id="0x0007" parent="0x007F" specific="0x0407" iso2="de" iso3="deu" win="DEU" icu_name="German" />\r
-  <lcid name="el" id="0x0008" parent="0x007F" specific="0x0408" iso2="el" iso3="ell" win="ELL" icu_name="Greek" />\r
-  <lcid name="en" id="0x0009" parent="0x007F" specific="0x0409" iso2="en" iso3="eng" win="ENU" icu_name="English" />\r
-  <lcid name="ar-KW" id="0x3401" parent="0x0001" specific="0x3401" iso2="ar" iso3="ara" win="ARK" icu_name="Arabic (Kuwait)" />\r
-  <lcid name="fi" id="0x000B" parent="0x007F" specific="0x040B" iso2="fi" iso3="fin" win="FIN" icu_name="Finnish" />\r
-  <lcid name="fr" id="0x000C" parent="0x007F" specific="0x040C" iso2="fr" iso3="fra" win="FRA" icu_name="French" />\r
-  <lcid name="he" id="0x000D" parent="0x007F" specific="0x040D" iso2="he" iso3="heb" win="HEB" icu_name="Hebrew" />\r
-  <lcid name="hu" id="0x000E" parent="0x007F" specific="0x040E" iso2="hu" iso3="hun" win="HUN" icu_name="Hungarian" />\r
-  <lcid name="is" id="0x000F" parent="0x007F" specific="0x040F" iso2="is" iso3="isl" win="ISL" icu_name="Icelandic" />\r
-  <lcid name="it" id="0x0010" parent="0x007F" specific="0x0410" iso2="it" iso3="ita" win="ITA" icu_name="Italian" />\r
-  <lcid name="ja" id="0x0011" parent="0x007F" specific="0x0411" iso2="ja" iso3="jpn" win="JPN" icu_name="Japanese" />\r
-  <lcid name="en-PH" id="0x3409" parent="0x0009" specific="0x3409" iso2="en" iso3="eng" win="ENP" icu_name="English (Philippines)" />\r
-  <lcid name="nl" id="0x0013" parent="0x007F" specific="0x0413" iso2="nl" iso3="nld" win="NLD" icu_name="Dutch" />\r
-  <lcid name="ka" id="0x0037" parent="0x007F" specific="0x0437" iso2="ka" iso3="kat" win="KAT" icu_name="Georgian" />\r
-  <lcid name="ko" id="0x0012" parent="0x007F" specific="0x0412" iso2="ko" iso3="kor" win="KOR" icu_name="Korean" />\r
-  <lcid name="ar-SA" id="0x0401" parent="0x0001" specific="0x0401" iso2="ar" iso3="ara" win="ARA" icu_name="Arabic (Saudi Arabia)" />\r
-  <lcid name="bg-BG" id="0x0402" parent="0x0002" specific="0x0402" iso2="bg" iso3="bul" win="BGR" icu_name="Bulgarian (Bulgaria)" />\r
-  <lcid name="ca-ES" id="0x0403" parent="0x0003" specific="0x0403" iso2="ca" iso3="cat" win="CAT" icu_name="Catalan (Spain)" />\r
-  <lcid name="zh-TW" id="0x0404" parent="0x7C04" specific="0x0404" iso2="zh" iso3="zho" win="CHT" icu_name="Chinese (Taiwan)" />\r
-  <lcid name="cs-CZ" id="0x0405" parent="0x0005" specific="0x0405" iso2="cs" iso3="ces" win="CSY" icu_name="Czech (Czech Republic)" />\r
-  <lcid name="hr" id="0x001A" parent="0x007F" specific="0x041A" iso2="hr" iso3="hrv" win="HRV" icu_name="Croatian" />\r
-  <lcid name="de-DE" id="0x0407" parent="0x0007" specific="0x0407" iso2="de" iso3="deu" win="DEU" icu_name="German (Germany)" />\r
-  <lcid name="sq" id="0x001C" parent="0x007F" specific="0x041C" iso2="sq" iso3="sqi" win="SQI" icu_name="Albanian" />\r
-  <lcid name="en-US" id="0x0409" parent="0x0009" specific="0x0409" iso2="en" iso3="eng" win="ENU" icu_name="English (United States)" />\r
-  <lcid name="ar-AE" id="0x3801" parent="0x0001" specific="0x3801" iso2="ar" iso3="ara" win="ARU" icu_name="Arabic (United Arab Emirates)" />\r
-  <lcid name="fi-FI" id="0x040B" parent="0x000B" specific="0x040B" iso2="fi" iso3="fin" win="FIN" icu_name="Finnish (Finland)" />\r
-  <lcid name="fr-FR" id="0x040C" parent="0x000C" specific="0x040C" iso2="fr" iso3="fra" win="FRA" icu_name="French (France)" />\r
-  <lcid name="he-IL" id="0x040D" parent="0x000D" specific="0x040D" iso2="he" iso3="heb" win="HEB" icu_name="Hebrew (Israel)" />\r
-  <lcid name="hu-HU" id="0x040E" parent="0x000E" specific="0x040E" iso2="hu" iso3="hun" win="HUN" icu_name="Hungarian (Hungary)" />\r
-  <lcid name="be" id="0x0023" parent="0x007F" specific="0x0423" iso2="be" iso3="bel" win="BEL" icu_name="Belarusian" />\r
-  <lcid name="id" id="0x0021" parent="0x007F" specific="0x0421" iso2="id" iso3="ind" win="IND" icu_name="Indonesian" />\r
-  <lcid name="et" id="0x0025" parent="0x007F" specific="0x0425" iso2="et" iso3="est" win="ETI" icu_name="Estonian" />\r
-  <lcid name="ka-GE" id="0x0437" parent="0x0037" specific="0x0437" iso2="ka" iso3="kat" win="KAT" icu_name="Georgian (Georgia)" />\r
-  <lcid name="ko-KR" id="0x0412" parent="0x0012" specific="0x0412" iso2="ko" iso3="kor" win="KOR" icu_name="Korean (South Korea)" />\r
-  <lcid name="nl-NL" id="0x0413" parent="0x0013" specific="0x0413" iso2="nl" iso3="nld" win="NLD" icu_name="Dutch (Netherlands)" />\r
-  <lcid name="no" id="0x0014" parent="0x007F" specific="0x0414" iso2="no" iso3="nor" win="NOR" icu_name="Norwegian" />\r
-  <lcid name="fa" id="0x0029" parent="0x007F" specific="0x0429" iso2="fa" iso3="fas" win="FAR" icu_name="Persian" />\r
-  <lcid name="lt" id="0x0027" parent="0x007F" specific="0x0427" iso2="lt" iso3="lit" win="LTH" icu_name="Lithuanian" />\r
-  <lcid name="hy" id="0x002B" parent="0x007F" specific="0x042B" iso2="hy" iso3="hye" win="HYE" icu_name="Armenian" />\r
-  <lcid name="zh-CN" id="0x0804" parent="0x0004" specific="0x0804" iso2="zh" iso3="zho" win="CHS" icu_name="Chinese (China)" />\r
-  <lcid name="eu" id="0x002D" parent="0x007F" specific="0x042D" iso2="eu" iso3="eus" win="EUQ" icu_name="Basque" />\r
-  <lcid name="hr-HR" id="0x041A" parent="0x001A" specific="0x041A" iso2="hr" iso3="hrv" win="HRV" icu_name="Croatian (Croatia)" />\r
-  <lcid name="de-CH" id="0x0807" parent="0x0007" specific="0x0807" iso2="de" iso3="deu" win="DES" icu_name="German (Switzerland)" />\r
-  <lcid name="sq-AL" id="0x041C" parent="0x001C" specific="0x041C" iso2="sq" iso3="sqi" win="SQI" icu_name="Albanian (Albania)" />\r
-  <lcid name="en-GB" id="0x0809" parent="0x0009" specific="0x0809" iso2="en" iso3="eng" win="ENG" icu_name="English (United Kingdom)" />\r
-  <lcid name="ar-BH" id="0x3C01" parent="0x0001" specific="0x3C01" iso2="ar" iso3="ara" win="ARH" icu_name="Arabic (Bahrain)" />\r
-  <lcid name="pl" id="0x0015" parent="0x007F" specific="0x0415" iso2="pl" iso3="pol" win="PLK" icu_name="Polish" />\r
-  <lcid name="fr-BE" id="0x080C" parent="0x000C" specific="0x080C" iso2="fr" iso3="fra" win="FRB" icu_name="French (Belgium)" />\r
-  <lcid name="id-ID" id="0x0421" parent="0x0021" specific="0x0421" iso2="id" iso3="ind" win="IND" icu_name="Indonesian (Indonesia)" />\r
-  <lcid name="af" id="0x0036" parent="0x007F" specific="0x0436" iso2="af" iso3="afr" win="AFK" icu_name="Afrikaans" />\r
-  <lcid name="be-BY" id="0x0423" parent="0x0023" specific="0x0423" iso2="be" iso3="bel" win="BEL" icu_name="Belarusian (Belarus)" />\r
-  <lcid name="fo" id="0x0038" parent="0x007F" specific="0x0438" iso2="fo" iso3="fao" win="FOS" icu_name="Faroese" />\r
-  <lcid name="et-EE" id="0x0425" parent="0x0025" specific="0x0425" iso2="et" iso3="est" win="ETI" icu_name="Estonian (Estonia)" />\r
-  <lcid name="lv-LV" id="0x0426" parent="0x0026" specific="0x0426" iso2="lv" iso3="lav" win="LVI" icu_name="Latvian (Latvia)" />\r
-  <lcid name="nl-BE" id="0x0813" parent="0x0013" specific="0x0813" iso2="nl" iso3="nld" win="NLB" icu_name="Dutch (Belgium)" />\r
-  <lcid name="da-DK" id="0x0406" parent="0x0006" specific="0x0406" iso2="da" iso3="dan" win="DAN" icu_name="Danish (Denmark)" />\r
-  <lcid name="fa-IR" id="0x0429" parent="0x0029" specific="0x0429" iso2="fa" iso3="fas" win="FAR" icu_name="Persian (Iran)" />\r
-  <lcid name="el-GR" id="0x0408" parent="0x0008" specific="0x0408" iso2="el" iso3="ell" win="ELL" icu_name="Greek (Greece)" />\r
-  <lcid name="hy-AM" id="0x042B" parent="0x002B" specific="0x042B" iso2="hy" iso3="hye" win="HYE" icu_name="Armenian (Armenia)" />\r
-  <lcid name="zh-HK" id="0x0C04" parent="0x7C04" specific="0x0C04" iso2="zh" iso3="zho" win="ZHH" icu_name="Chinese (Hong Kong S.A.R., China)" />\r
-  <lcid name="eu-ES" id="0x042D" parent="0x002D" specific="0x042D" iso2="eu" iso3="eus" win="EUQ" icu_name="Basque (Spain)" />\r
-  <lcid name="hi" id="0x0039" parent="0x007F" specific="0x0439" iso2="hi" iso3="hin" win="HIN" icu_name="Hindi" />\r
-  <lcid name="de-AT" id="0x0C07" parent="0x0007" specific="0x0C07" iso2="de" iso3="deu" win="DEA" icu_name="German (Austria)" />\r
-  <lcid name="lv" id="0x0026" parent="0x007F" specific="0x0426" iso2="lv" iso3="lav" win="LVI" icu_name="Latvian" />\r
-  <lcid name="en-AU" id="0x0C09" parent="0x0009" specific="0x0C09" iso2="en" iso3="eng" win="ENA" icu_name="English (Australia)" />\r
-  <lcid name="ar-QA" id="0x4001" parent="0x0001" specific="0x4001" iso2="ar" iso3="ara" win="ARQ" icu_name="Arabic (Qatar)" />\r
-  <lcid name="gu" id="0x0047" parent="0x007F" specific="0x0447" iso2="gu" iso3="guj" win="GUJ" icu_name="Gujarati" />\r
-  <lcid name="fr-CA" id="0x0C0C" parent="0x000C" specific="0x0C0C" iso2="fr" iso3="fra" win="FRC" icu_name="French (Canada)" />\r
-  <lcid name="ru" id="0x0019" parent="0x007F" specific="0x0419" iso2="ru" iso3="rus" win="RUS" icu_name="Russian" />\r
-  <lcid name="af-ZA" id="0x0436" parent="0x0036" specific="0x0436" iso2="af" iso3="afr" win="AFK" icu_name="Afrikaans (South Africa)" />\r
-  <lcid name="kn" id="0x004B" parent="0x007F" specific="0x044B" iso2="kn" iso3="kan" win="KAN" icu_name="Kannada" />\r
-  <lcid name="fo-FO" id="0x0438" parent="0x0038" specific="0x0438" iso2="fo" iso3="fao" win="FOS" icu_name="Faroese (Faroe Islands)" />\r
-  <lcid name="hi-IN" id="0x0439" parent="0x0039" specific="0x0439" iso2="hi" iso3="hin" win="HIN" icu_name="Hindi (India)" />\r
-  <lcid name="mr" id="0x004E" parent="0x007F" specific="0x044E" iso2="mr" iso3="mar" win="MAR" icu_name="Marathi" />\r
-  <lcid name="ru-RU" id="0x0419" parent="0x0019" specific="0x0419" iso2="ru" iso3="rus" win="RUS" icu_name="Russian (Russia)" />\r
-  <lcid name="mk" id="0x002F" parent="0x007F" specific="0x042F" iso2="mk" iso3="mkd" win="MKI" icu_name="Macedonian" />\r
-  <lcid name="ar-LY" id="0x1001" parent="0x0001" specific="0x1001" iso2="ar" iso3="ara" win="ARL" icu_name="Arabic (Libya)" />\r
-  <lcid name="pt" id="0x0016" parent="0x007F" specific="0x0416" iso2="pt" iso3="por" win="PTB" icu_name="Portuguese" />\r
-  <lcid name="sk" id="0x001B" parent="0x007F" specific="0x041B" iso2="sk" iso3="slk" win="SKY" icu_name="Slovak" />\r
-  <lcid name="zh-SG" id="0x1004" parent="0x0004" specific="0x1004" iso2="zh" iso3="zho" win="ZHI" icu_name="Chinese (Singapore)" />\r
-  <lcid name="sw" id="0x0041" parent="0x007F" specific="0x0441" iso2="sw" iso3="swa" win="SWK" icu_name="Swahili" />\r
-  <lcid name="gl" id="0x0056" parent="0x007F" specific="0x0456" iso2="gl" iso3="glg" win="GLC" icu_name="Gallegan" />\r
-  <lcid name="de-LU" id="0x1007" parent="0x0007" specific="0x1007" iso2="de" iso3="deu" win="DEL" icu_name="German (Luxembourg)" />\r
-  <lcid name="ro" id="0x0018" parent="0x007F" specific="0x0418" iso2="ro" iso3="ron" win="ROM" icu_name="Romanian" />\r
-  <lcid name="en-CA" id="0x1009" parent="0x0009" specific="0x1009" iso2="en" iso3="eng" win="ENC" icu_name="English (Canada)" />\r
-  <lcid name="sl" id="0x0024" parent="0x007F" specific="0x0424" iso2="sl" iso3="slv" win="SLV" icu_name="Slovenian" />\r
-  <lcid name="gu-IN" id="0x0447" parent="0x0047" specific="0x0447" iso2="gu" iso3="guj" win="GUJ" icu_name="Gujarati (India)" />\r
-  <lcid name="fr-CH" id="0x100C" parent="0x000C" specific="0x100C" iso2="fr" iso3="fra" win="FRS" icu_name="French (Switzerland)" />\r
-  <lcid name="es-BO" id="0x400A" parent="0x000A" specific="0x400A" iso2="es" iso3="spa" win="ESB" icu_name="Spanish (Bolivia)" />\r
-  <lcid name="lt-LT" id="0x0427" parent="0x0027" specific="0x0427" iso2="lt" iso3="lit" win="LTH" icu_name="Lithuanian (Lithuania)" />\r
-  <lcid name="kn-IN" id="0x044B" parent="0x004B" specific="0x044B" iso2="kn" iso3="kan" win="KAN" icu_name="Kannada (India)" />\r
-  <lcid name="es" id="0x000A" parent="0x007F" specific="0x0C0A" iso2="es" iso3="spa" win="ESP" icu_name="Spanish" />\r
-  <lcid name="sv" id="0x001D" parent="0x007F" specific="0x041D" iso2="sv" iso3="swe" win="SVE" icu_name="Swedish" />\r
-  <lcid name="mr-IN" id="0x044E" parent="0x004E" specific="0x044E" iso2="mr" iso3="mar" win="MAR" icu_name="Marathi (India)" />\r
-  <lcid name="kok" id="0x0057" parent="0x007F" specific="0x0457" iso2="hi" iso3="kok" win="KNK" icu_name="Konkani" />\r
-  <lcid name="th" id="0x001E" parent="0x007F" specific="0x041E" iso2="th" iso3="tha" win="THA" icu_name="Thai" />\r
-  <lcid name="ar-DZ" id="0x1401" parent="0x0001" specific="0x1401" iso2="ar" iso3="ara" win="ARG" icu_name="Arabic (Algeria)" />\r
-  <lcid name="mk-MK" id="0x042F" parent="0x002F" specific="0x042F" iso2="mk" iso3="mkd" win="MKI" icu_name="Macedonian (Macedonia)" />\r
-  <lcid name="is-IS" id="0x040F" parent="0x000F" specific="0x040F" iso2="is" iso3="isl" win="ISL" icu_name="Icelandic (Iceland)" />\r
-  <lcid name="zh-MO" id="0x1404" parent="0x0004" specific="0x1404" iso2="zh" iso3="zho" win="ZHM" icu_name="Chinese (Macao S.A.R. China)" />\r
-  <lcid name="ja-JP" id="0x0411" parent="0x0011" specific="0x0411" iso2="ja" iso3="jpn" win="JPN" icu_name="Japanese (Japan)" />\r
-  <lcid name="gl-ES" id="0x0456" parent="0x0056" specific="0x0456" iso2="gl" iso3="glg" win="GLC" icu_name="Gallegan (Spain)" />\r
-  <lcid name="ar-IQ" id="0x0801" parent="0x0001" specific="0x0801" iso2="ar" iso3="ara" win="ARI" icu_name="Arabic (Iraq)" />\r
-  <lcid name="nb-NO" id="0x0414" parent="0x0014" specific="0x0414" iso2="nb" iso3="nob" win="NOR" icu_name="Norwegian Bokm?l (Norway)" />\r
-  <lcid name="en-NZ" id="0x1409" parent="0x0009" specific="0x1409" iso2="en" iso3="eng" win="ENZ" icu_name="English (New Zealand)" />\r
-  <lcid name="pt-BR" id="0x0416" parent="0x0016" specific="0x0416" iso2="pt" iso3="por" win="PTB" icu_name="Portuguese (Brazil)" />\r
-  <lcid name="tr" id="0x001F" parent="0x007F" specific="0x041F" iso2="tr" iso3="tur" win="TRK" icu_name="Turkish" />\r
-  <lcid name="fr-LU" id="0x140C" parent="0x000C" specific="0x140C" iso2="fr" iso3="fra" win="FRL" icu_name="French (Luxembourg)" />\r
-  <lcid name="ta" id="0x0049" parent="0x007F" specific="0x0449" iso2="ta" iso3="tam" win="TAM" icu_name="Tamil" />\r
-  <lcid name="te" id="0x004A" parent="0x007F" specific="0x044A" iso2="te" iso3="tel" win="TEL" icu_name="Telugu" />\r
-  <lcid name="sk-SK" id="0x041B" parent="0x001B" specific="0x041B" iso2="sk" iso3="slk" win="SKY" icu_name="Slovak (Slovakia)" />\r
-  <lcid name="es-MX" id="0x080A" parent="0x000A" specific="0x080A" iso2="es" iso3="spa" win="ESM" icu_name="Spanish (Mexico)" />\r
-  <lcid name="sv-SE" id="0x041D" parent="0x001D" specific="0x041D" iso2="sv" iso3="swe" win="SVE" icu_name="Swedish (Sweden)" />\r
-  <lcid name="th-TH" id="0x041E" parent="0x001E" specific="0x041E" iso2="th" iso3="tha" win="THA" icu_name="Thai (Thailand)" />\r
-  <lcid name="es-HN" id="0x480A" parent="0x000A" specific="0x480A" iso2="es" iso3="spa" win="ESH" icu_name="Spanish (Honduras)" />\r
-  <lcid name="vi" id="0x002A" parent="0x007F" specific="0x042A" iso2="vi" iso3="vie" win="VIT" icu_name="Vietnamese" />\r
-  <lcid name="ar-MA" id="0x1801" parent="0x0001" specific="0x1801" iso2="ar" iso3="ara" win="ARM" icu_name="Arabic (Morocco)" />\r
-  <lcid name="zh-CHT" id="0x7C04" parent="0x007F" specific="0x0000" iso2="zh" iso3="zho" win="CHT" icu_name="Chinese (Taiwan)" />\r
-  <lcid name="uk" id="0x0022" parent="0x007F" specific="0x0422" iso2="uk" iso3="ukr" win="UKR" icu_name="Ukrainian" />\r
-  <lcid name="nn-NO" id="0x0814" parent="0x0014" specific="0x0814" iso2="nn" iso3="nno" win="NON" icu_name="Norwegian Nynorsk (Norway)" />\r
-  <lcid name="pt-PT" id="0x0816" parent="0x0016" specific="0x0816" iso2="pt" iso3="por" win="PTG" icu_name="Portuguese (Portugal)" />\r
-  <lcid name="en-IE" id="0x1809" parent="0x0009" specific="0x1809" iso2="en" iso3="eng" win="ENI" icu_name="English (Ireland)" />\r
-  <lcid name="es-PA" id="0x180A" parent="0x000A" specific="0x180A" iso2="es" iso3="spa" win="ESA" icu_name="Spanish (Panama)" />\r
-  <lcid name="fr-MC" id="0x180C" parent="0x000C" specific="0x180C" iso2="fr" iso3="fra" win="FRM" icu_name="French (Monaco)" />\r
-  <lcid name="sv-FI" id="0x081D" parent="0x001D" specific="0x081D" iso2="sv" iso3="swe" win="SVF" icu_name="Swedish (Finland)" />\r
-  <lcid name="it-IT" id="0x0410" parent="0x0010" specific="0x0410" iso2="it" iso3="ita" win="ITA" icu_name="Italian (Italy)" />\r
-  <lcid name="es-NI" id="0x4C0A" parent="0x000A" specific="0x4C0A" iso2="es" iso3="spa" win="ESI" icu_name="Spanish (Nicaragua)" />\r
-  <lcid name="ar-TN" id="0x1C01" parent="0x0001" specific="0x1C01" iso2="ar" iso3="ara" win="ART" icu_name="Arabic (Tunisia)" />\r
-  <lcid name="kok-IN" id="0x0457" parent="0x0057" specific="0x0457" iso2="kok" iso3="kok" win="KNK" icu_name="Konkani (India)" />\r
-  <lcid name="es-SV" id="0x440A" parent="0x000A" specific="0x440A" iso2="es" iso3="spa" win="ESE" icu_name="Spanish (El Salvador)" />\r
-  <lcid name="ro-RO" id="0x0418" parent="0x0018" specific="0x0418" iso2="ro" iso3="ron" win="ROM" icu_name="Romanian (Romania)" />\r
-  <lcid name="en-ZA" id="0x1C09" parent="0x0009" specific="0x1C09" iso2="en" iso3="eng" win="ENS" icu_name="English (South Africa)" />\r
-  <lcid name="es-DO" id="0x1C0A" parent="0x000A" specific="0x1C0A" iso2="es" iso3="spa" win="ESD" icu_name="Spanish (Dominican Republic)" />\r
-  <lcid name="tr-TR" id="0x041F" parent="0x001F" specific="0x041F" iso2="tr" iso3="tur" win="TRK" icu_name="Turkish (Turkey)" />\r
-  <lcid name="sw-KE" id="0x0441" parent="0x0041" specific="0x0441" iso2="sw" iso3="swa" win="SWK" icu_name="Swahili (Kenya)" />\r
-  <lcid name="ar-EG" id="0x0C01" parent="0x0001" specific="0x0C01" iso2="ar" iso3="ara" win="ARE" icu_name="Arabic (Egypt)" />\r
-  <lcid name="ar-OM" id="0x2001" parent="0x0001" specific="0x2001" iso2="ar" iso3="ara" win="ARO" icu_name="Arabic (Oman)" />\r
-  <lcid name="ta-IN" id="0x0449" parent="0x0049" specific="0x0449" iso2="ta" iso3="tam" win="TAM" icu_name="Tamil (India)" />\r
-  <lcid name="te-IN" id="0x044A" parent="0x004A" specific="0x044A" iso2="te" iso3="tel" win="TEL" icu_name="Telugu (India)" />\r
-  <lcid name="vi-VN" id="0x042A" parent="0x002A" specific="0x042A" iso2="vi" iso3="vie" win="VIT" icu_name="Vietnamese (Vietnam)" />\r
-  <lcid name="es-ES" id="0x0C0A" parent="0x000A" specific="0x0C0A" iso2="es" iso3="spa" win="ESN" icu_name="Spanish (Spain)" />\r
-  <lcid name="en-JM" id="0x2009" parent="0x0009" specific="0x2009" iso2="en" iso3="eng" win="ENJ" icu_name="English (Jamaica)" />\r
-  <lcid name="es-VE" id="0x200A" parent="0x000A" specific="0x200A" iso2="es" iso3="spa" win="ESV" icu_name="Spanish (Venezuela)" />\r
-  <lcid name="pl-PL" id="0x0415" parent="0x0015" specific="0x0415" iso2="pl" iso3="pol" win="PLK" icu_name="Polish (Poland)" />\r
-  <lcid name="de-LI" id="0x1407" parent="0x0007" specific="0x1407" iso2="de" iso3="deu" win="DEC" icu_name="German (Liechtenstein)" />\r
-  <lcid name="ar-YE" id="0x2401" parent="0x0001" specific="0x2401" iso2="ar" iso3="ara" win="ARY" icu_name="Arabic (Yemen)" />\r
-  <lcid name="es-CR" id="0x140A" parent="0x000A" specific="0x140A" iso2="es" iso3="spa" win="ESC" icu_name="Spanish (Costa Rica)" />\r
-  <lcid name="Cy-sr-SP" id="0x0C1A" parent="0x001A" specific="0x0C1A" iso2="sr" iso3="srp" win="SRB" icu_name="Serbian" />\r
-  <lcid name="es-CL" id="0x340A" parent="0x000A" specific="0x340A" iso2="es" iso3="spa" win="ESL" icu_name="Spanish (Chile)" />\r
-  <lcid name="it-CH" id="0x0810" parent="0x0010" specific="0x0810" iso2="it" iso3="ita" win="ITS" icu_name="Italian (Switzerland)" />\r
-  <lcid name="en-CB" id="0x2409" parent="0x0009" specific="0x2409" iso2="en" iso3="eng" win="ENB" icu_name="English (U.S. Virgin Islands)" />\r
-  <lcid name="es-CO" id="0x240A" parent="0x000A" specific="0x240A" iso2="es" iso3="spa" win="ESO" icu_name="Spanish (Colombia)" />\r
-  <lcid name="es-PR" id="0x500A" parent="0x000A" specific="0x500A" iso2="es" iso3="spa" win="ESU" icu_name="Spanish (Puerto Rico)" />\r
-  <lcid name="uk-UA" id="0x0422" parent="0x0022" specific="0x0422" iso2="uk" iso3="ukr" win="UKR" icu_name="Ukrainian (Ukraine)" />\r
-  <lcid name="sl-SI" id="0x0424" parent="0x0024" specific="0x0424" iso2="sl" iso3="slv" win="SLV" icu_name="Slovenian (Slovenia)" />\r
-  <lcid name="Lt-sr-SP" id="0x081A" parent="0x001A" specific="0x081A" iso2="sr" iso3="srp" win="SRL" icu_name="Serbo-Croatian" />\r
-  <lcid name="ar-SY" id="0x2801" parent="0x0001" specific="0x2801" iso2="ar" iso3="ara" win="ARS" icu_name="Arabic (Syria)" />\r
-  <lcid name="en-BZ" id="0x2809" parent="0x0009" specific="0x2809" iso2="en" iso3="eng" win="ENL" icu_name="English (Belize)" />\r
-  <lcid name="es-PE" id="0x280A" parent="0x000A" specific="0x280A" iso2="es" iso3="spa" win="ESR" icu_name="Spanish (Peru)" />\r
-  <lcid name="es-GT" id="0x100A" parent="0x000A" specific="0x100A" iso2="es" iso3="spa" win="ESG" icu_name="Spanish (Guatemala)" />\r
-  <lcid name="ar-JO" id="0x2C01" parent="0x0001" specific="0x2C01" iso2="ar" iso3="ara" win="ARJ" icu_name="Arabic (Jordan)" />\r
-  <lcid name="en-TT" id="0x2C09" parent="0x0009" specific="0x2C09" iso2="en" iso3="eng" win="ENT" icu_name="English (Trinidad and Tobago)" />\r
-  <lcid name="es-AR" id="0x2C0A" parent="0x000A" specific="0x2C0A" iso2="es" iso3="spa" win="ESS" icu_name="Spanish (Argentina)" />\r
-  <lcid name="es-PY" id="0x3C0A" parent="0x000A" specific="0x3C0A" iso2="es" iso3="spa" win="ESZ" icu_name="Spanish (Paraguay)" />\r
-  <lcid name="es-UY" id="0x380A" parent="0x000A" specific="0x380A" iso2="es" iso3="spa" win="ESY" icu_name="Spanish (Uruguay)" />\r
-  <lcid name="ar-LB" id="0x3001" parent="0x0001" specific="0x3001" iso2="ar" iso3="ara" win="ARB" icu_name="Arabic (Lebanon)" />\r
-  <lcid name="en-ZW" id="0x3009" parent="0x0009" specific="0x3009" iso2="en" iso3="eng" win="ENW" icu_name="English (Zimbabwe)" />\r
-  <lcid name="es-EC" id="0x300A" parent="0x000A" specific="0x300A" iso2="es" iso3="spa" win="ESF" icu_name="Spanish (Ecuador)" />\r
+  <lcid name="ar" id="0x0001" parent="0x007F" iso2="ar" iso3="ara" win="ARA" />\r
+  <lcid name="bg" id="0x0002" parent="0x007F" iso2="bg" iso3="bul" win="BGR" />\r
+  <lcid name="ca" id="0x0003" parent="0x007F" iso2="ca" iso3="cat" win="CAT" />\r
+  <lcid name="zh_Hans" id="0x0004" parent="0x7804" iso2="zh" iso3="zho" win="CHS" />\r
+  <lcid name="zh_CHS" id="0x0004" parent="0x0004" iso2="zh" iso3="zho" win="CHS" />\r
+  <lcid name="cs" id="0x0005" parent="0x007F" iso2="cs" iso3="ces" win="CSY" />\r
+  <lcid name="da" id="0x0006" parent="0x007F" iso2="da" iso3="dan" win="DAN" />\r
+  <lcid name="de" id="0x0007" parent="0x007F" iso2="de" iso3="deu" win="DEU" />\r
+  <lcid name="el" id="0x0008" parent="0x007F" iso2="el" iso3="ell" win="ELL" />\r
+  <lcid name="en" id="0x0009" parent="0x007F" iso2="en" iso3="eng" win="ENU" />\r
+  <lcid name="es" id="0x000A" parent="0x007F" iso2="es" iso3="spa" win="ESP" />\r
+  <lcid name="fi" id="0x000B" parent="0x007F" iso2="fi" iso3="fin" win="FIN" />\r
+  <lcid name="fr" id="0x000C" parent="0x007F" iso2="fr" iso3="fra" win="FRA" />\r
+  <lcid name="he" id="0x000D" parent="0x007F" iso2="he" iso3="heb" win="HEB" />\r
+  <lcid name="hu" id="0x000E" parent="0x007F" iso2="hu" iso3="hun" win="HUN" />\r
+  <lcid name="is" id="0x000F" parent="0x007F" iso2="is" iso3="isl" win="ISL" />\r
+  <lcid name="it" id="0x0010" parent="0x007F" iso2="it" iso3="ita" win="ITA" />\r
+  <lcid name="ja" id="0x0011" parent="0x007F" iso2="ja" iso3="jpn" win="JPN" />\r
+  <lcid name="ko" id="0x0012" parent="0x007F" iso2="ko" iso3="kor" win="KOR" />\r
+  <lcid name="nl" id="0x0013" parent="0x007F" iso2="nl" iso3="nld" win="NLD" />\r
+  <lcid name="no" id="0x0014" parent="0x007F" iso2="nb" iso3="nob" win="NOR" />\r
+  <lcid name="pl" id="0x0015" parent="0x007F" iso2="pl" iso3="pol" win="PLK" />\r
+  <lcid name="pt" id="0x0016" parent="0x007F" iso2="pt" iso3="por" win="PTB" />\r
+  <lcid name="rm" id="0x0017" parent="0x007F" iso2="rm" iso3="roh" win="RMC" />\r
+  <lcid name="ro" id="0x0018" parent="0x007F" iso2="ro" iso3="ron" win="ROM" />\r
+  <lcid name="ru" id="0x0019" parent="0x007F" iso2="ru" iso3="rus" win="RUS" />\r
+  <lcid name="hr" id="0x001A" parent="0x007F" iso2="hr" iso3="hrv" win="HRV" />\r
+  <lcid name="sk" id="0x001B" parent="0x007F" iso2="sk" iso3="slk" win="SKY" />\r
+  <lcid name="sq" id="0x001C" parent="0x007F" iso2="sq" iso3="sqi" win="SQI" />\r
+  <lcid name="sv" id="0x001D" parent="0x007F" iso2="sv" iso3="swe" win="SVE" />\r
+  <lcid name="th" id="0x001E" parent="0x007F" iso2="th" iso3="tha" win="THA" />\r
+  <lcid name="tr" id="0x001F" parent="0x007F" iso2="tr" iso3="tur" win="TRK" />\r
+  <lcid name="ur" id="0x0020" parent="0x007F" iso2="ur" iso3="urd" win="URD" />\r
+  <lcid name="id" id="0x0021" parent="0x007F" iso2="id" iso3="ind" win="IND" />\r
+  <lcid name="uk" id="0x0022" parent="0x007F" iso2="uk" iso3="ukr" win="UKR" />\r
+  <lcid name="be" id="0x0023" parent="0x007F" iso2="be" iso3="bel" win="BEL" />\r
+  <lcid name="sl" id="0x0024" parent="0x007F" iso2="sl" iso3="slv" win="SLV" />\r
+  <lcid name="et" id="0x0025" parent="0x007F" iso2="et" iso3="est" win="ETI" />\r
+  <lcid name="lv" id="0x0026" parent="0x007F" iso2="lv" iso3="lav" win="LVI" />\r
+  <lcid name="lt" id="0x0027" parent="0x007F" iso2="lt" iso3="lit" win="LTH" />\r
+  <lcid name="tg" id="0x0028" parent="0x007F" iso2="tg" iso3="tgk" win="TAJ" />\r
+  <lcid name="fa" id="0x0029" parent="0x007F" iso2="fa" iso3="fas" win="FAR" />\r
+  <lcid name="vi" id="0x002A" parent="0x007F" iso2="vi" iso3="vie" win="VIT" />\r
+  <lcid name="hy" id="0x002B" parent="0x007F" iso2="hy" iso3="hye" win="HYE" />\r
+  <lcid name="az" id="0x002C" parent="0x007F" iso2="az" iso3="aze" win="AZE" />\r
+  <lcid name="eu" id="0x002D" parent="0x007F" iso2="eu" iso3="eus" win="EUQ" />\r
+  <lcid name="hsb" id="0x002E" parent="0x007F" iso2="hsb" iso3="hsb" win="HSB" />\r
+  <lcid name="mk" id="0x002F" parent="0x007F" iso2="mk" iso3="mkd" win="MKI" />\r
+  <lcid name="tn" id="0x0032" parent="0x007F" iso2="tn" iso3="tsn" win="TSN" />\r
+  <lcid name="xh" id="0x0034" parent="0x007F" iso2="xh" iso3="xho" win="XHO" />\r
+  <lcid name="zu" id="0x0035" parent="0x007F" iso2="zu" iso3="zul" win="ZUL" />\r
+  <lcid name="af" id="0x0036" parent="0x007F" iso2="af" iso3="afr" win="AFK" />\r
+  <lcid name="ka" id="0x0037" parent="0x007F" iso2="ka" iso3="kat" win="KAT" />\r
+  <lcid name="fo" id="0x0038" parent="0x007F" iso2="fo" iso3="fao" win="FOS" />\r
+  <lcid name="hi" id="0x0039" parent="0x007F" iso2="hi" iso3="hin" win="HIN" />\r
+  <lcid name="mt" id="0x003A" parent="0x007F" iso2="mt" iso3="mlt" win="MLT" />\r
+  <lcid name="se" id="0x003B" parent="0x007F" iso2="se" iso3="sme" win="SME" />\r
+  <lcid name="ga" id="0x003C" parent="0x007F" iso2="ga" iso3="gle" win="IRE" />\r
+  <lcid name="ms" id="0x003E" parent="0x007F" iso2="ms" iso3="msa" win="MSL" />\r
+  <lcid name="kk" id="0x003F" parent="0x007F" iso2="kk" iso3="kaz" win="KKZ" />\r
+  <lcid name="ky" id="0x0040" parent="0x007F" iso2="ky" iso3="kir" win="KYR" />\r
+  <lcid name="sw" id="0x0041" parent="0x007F" iso2="sw" iso3="swa" win="SWK" />\r
+  <lcid name="tk" id="0x0042" parent="0x007F" iso2="tk" iso3="tuk" win="TUK" />\r
+  <lcid name="uz" id="0x0043" parent="0x007F" iso2="uz" iso3="uzb" win="UZB" />\r
+  <lcid name="tt" id="0x0044" parent="0x007F" iso2="tt" iso3="tat" win="TTT" />\r
+  <lcid name="bn" id="0x0045" parent="0x007F" iso2="bn" iso3="bng" win="BNG" />\r
+  <lcid name="pa" id="0x0046" parent="0x007F" iso2="pa" iso3="pan" win="PAN" />\r
+  <lcid name="gu" id="0x0047" parent="0x007F" iso2="gu" iso3="guj" win="GUJ" />\r
+  <lcid name="or" id="0x0048" parent="0x007F" iso2="or" iso3="ori" win="ORI" />\r
+  <lcid name="ta" id="0x0049" parent="0x007F" iso2="ta" iso3="tam" win="TAM" />\r
+  <lcid name="te" id="0x004A" parent="0x007F" iso2="te" iso3="tel" win="TEL" />\r
+  <lcid name="kn" id="0x004B" parent="0x007F" iso2="kn" iso3="kan" win="KDI" />\r
+  <lcid name="ml" id="0x004C" parent="0x007F" iso2="ml" iso3="mym" win="MYM" />\r
+  <lcid name="as" id="0x004D" parent="0x007F" iso2="as" iso3="asm" win="ASM" />\r
+  <lcid name="mr" id="0x004E" parent="0x007F" iso2="mr" iso3="mar" win="MAR" />\r
+  <lcid name="sa" id="0x004F" parent="0x007F" iso2="sa" iso3="san" win="SAN" />\r
+  <lcid name="mn" id="0x0050" parent="0x007F" iso2="mn" iso3="mon" win="MON" />\r
+  <lcid name="bo" id="0x0051" parent="0x007F" iso2="bo" iso3="bod" win="BOB" />\r
+  <lcid name="cy" id="0x0052" parent="0x007F" iso2="cy" iso3="cym" win="CYM" />\r
+  <lcid name="km" id="0x0053" parent="0x007F" iso2="km" iso3="khm" win="KHM" />\r
+  <lcid name="lo" id="0x0054" parent="0x007F" iso2="lo" iso3="lao" win="LAO" />\r
+  <lcid name="gl" id="0x0056" parent="0x007F" iso2="gl" iso3="glg" win="GLC" />\r
+  <lcid name="kok" id="0x0057" parent="0x007F" iso2="kok" iso3="kok" win="KNK" />\r
+  <lcid name="syr" id="0x005A" parent="0x007F" iso2="syr" iso3="syr" win="SYR" />\r
+  <lcid name="si" id="0x005B" parent="0x007F" iso2="si" iso3="sin" win="SIN" />\r
+  <lcid name="iu" id="0x005D" parent="0x007F" iso2="iu" iso3="iku" win="IUK" />\r
+  <lcid name="am" id="0x005E" parent="0x007F" iso2="am" iso3="amh" win="AMH" />\r
+  <lcid name="tzm" id="0x005F" parent="0x007F" iso2="tzm" iso3="tzm" win="TZM" />\r
+  <lcid name="ne" id="0x0061" parent="0x007F" iso2="ne" iso3="nep" win="NEP" />\r
+  <lcid name="fy" id="0x0062" parent="0x007F" iso2="fy" iso3="fry" win="FYN" />\r
+  <lcid name="ps" id="0x0063" parent="0x007F" iso2="ps" iso3="pus" win="PAS" />\r
+  <lcid name="fil" id="0x0064" parent="0x007F" iso2="fil" iso3="fil" win="FPO" />\r
+  <lcid name="dv" id="0x0065" parent="0x007F" iso2="dv" iso3="div" win="DIV" />\r
+  <lcid name="ha" id="0x0068" parent="0x007F" iso2="ha" iso3="hau" win="HAU" />\r
+  <lcid name="yo" id="0x006A" parent="0x007F" iso2="yo" iso3="yor" win="YOR" />\r
+  <lcid name="quz" id="0x006B" parent="0x007F" iso2="quz" iso3="qub" win="QUB" />\r
+  <lcid name="nso" id="0x006C" parent="0x007F" iso2="nso" iso3="nso" win="NSO" />\r
+  <lcid name="ba" id="0x006D" parent="0x007F" iso2="ba" iso3="bak" win="BAS" />\r
+  <lcid name="lb" id="0x006E" parent="0x007F" iso2="lb" iso3="ltz" win="LBX" />\r
+  <lcid name="kl" id="0x006F" parent="0x007F" iso2="kl" iso3="kal" win="KAL" />\r
+  <lcid name="ig" id="0x0070" parent="0x007F" iso2="ig" iso3="ibo" win="IBO" />\r
+  <lcid name="ii" id="0x0078" parent="0x007F" iso2="ii" iso3="iii" win="III" />\r
+  <lcid name="arn" id="0x007A" parent="0x007F" iso2="arn" iso3="arn" win="MPD" />\r
+  <lcid name="moh" id="0x007C" parent="0x007F" iso2="moh" iso3="moh" win="MWK" />\r
+  <lcid name="br" id="0x007E" parent="0x007F" iso2="br" iso3="bre" win="BRE" />\r
+  <lcid name="ug" id="0x0080" parent="0x007F" iso2="ug" iso3="uig" win="UIG" />\r
+  <lcid name="mi" id="0x0081" parent="0x007F" iso2="mi" iso3="mri" win="MRI" />\r
+  <lcid name="oc" id="0x0082" parent="0x007F" iso2="oc" iso3="oci" win="OCI" />\r
+  <lcid name="co" id="0x0083" parent="0x007F" iso2="co" iso3="cos" win="COS" />\r
+  <lcid name="gsw" id="0x0084" parent="0x007F" iso2="gsw" iso3="gsw" win="GSW" />\r
+  <lcid name="sah" id="0x0085" parent="0x007F" iso2="sah" iso3="sah" win="SAH" />\r
+  <lcid name="qut" id="0x0086" parent="0x007F" iso2="qut" iso3="qut" win="QUT" />\r
+  <lcid name="rw" id="0x0087" parent="0x007F" iso2="rw" iso3="kin" win="KIN" />\r
+  <lcid name="wo" id="0x0088" parent="0x007F" iso2="wo" iso3="wol" win="WOL" />\r
+  <lcid name="prs" id="0x008C" parent="0x007F" iso2="prs" iso3="prs" win="PRS" />\r
+  <lcid name="gd" id="0x0091" parent="0x007F" iso2="gd" iso3="gla" win="GLA" />\r
+  <lcid name="ar_SA" id="0x0401" parent="0x0001" iso2="ar" iso3="ara" win="ARA" />\r
+  <lcid name="bg_BG" id="0x0402" parent="0x0002" iso2="bg" iso3="bul" win="BGR" />\r
+  <lcid name="ca_ES" id="0x0403" parent="0x0003" iso2="ca" iso3="cat" win="CAT" />\r
+  <lcid name="zh_TW" id="0x0404" parent="0x7C04" iso2="zh" iso3="zho" win="CHT" />\r
+  <lcid name="cs_CZ" id="0x0405" parent="0x0005" iso2="cs" iso3="ces" win="CSY" />\r
+  <lcid name="da_DK" id="0x0406" parent="0x0006" iso2="da" iso3="dan" win="DAN" />\r
+  <lcid name="de_DE" id="0x0407" parent="0x0007" iso2="de" iso3="deu" win="DEU" />\r
+  <lcid name="el_GR" id="0x0408" parent="0x0008" iso2="el" iso3="ell" win="ELL" />\r
+  <lcid name="en_US" id="0x0409" parent="0x0009" iso2="en" iso3="eng" win="ENU" />\r
+  <lcid name="fi_FI" id="0x040B" parent="0x000B" iso2="fi" iso3="fin" win="FIN" />\r
+  <lcid name="fr_FR" id="0x040C" parent="0x000C" iso2="fr" iso3="fra" win="FRA" />\r
+  <lcid name="he_IL" id="0x040D" parent="0x000D" iso2="he" iso3="heb" win="HEB" />\r
+  <lcid name="hu_HU" id="0x040E" parent="0x000E" iso2="hu" iso3="hun" win="HUN" />\r
+  <lcid name="is_IS" id="0x040F" parent="0x000F" iso2="is" iso3="isl" win="ISL" />\r
+  <lcid name="it_IT" id="0x0410" parent="0x0010" iso2="it" iso3="ita" win="ITA" />\r
+  <lcid name="ja_JP" id="0x0411" parent="0x0011" iso2="ja" iso3="jpn" win="JPN" />\r
+  <lcid name="ko_KR" id="0x0412" parent="0x0012" iso2="ko" iso3="kor" win="KOR" />\r
+  <lcid name="nl_NL" id="0x0413" parent="0x0013" iso2="nl" iso3="nld" win="NLD" />\r
+  <lcid name="nb_NO" id="0x0414" parent="0x7C14" iso2="nb" iso3="nob" win="NOR" />\r
+  <lcid name="pl_PL" id="0x0415" parent="0x0015" iso2="pl" iso3="pol" win="PLK" />\r
+  <lcid name="pt_BR" id="0x0416" parent="0x0016" iso2="pt" iso3="por" win="PTB" />\r
+  <lcid name="rm_CH" id="0x0417" parent="0x0017" iso2="rm" iso3="roh" win="RMC" />\r
+  <lcid name="ro_RO" id="0x0418" parent="0x0018" iso2="ro" iso3="ron" win="ROM" />\r
+  <lcid name="ru_RU" id="0x0419" parent="0x0019" iso2="ru" iso3="rus" win="RUS" />\r
+  <lcid name="hr_HR" id="0x041A" parent="0x001A" iso2="hr" iso3="hrv" win="HRV" />\r
+  <lcid name="sk_SK" id="0x041B" parent="0x001B" iso2="sk" iso3="slk" win="SKY" />\r
+  <lcid name="sq_AL" id="0x041C" parent="0x001C" iso2="sq" iso3="sqi" win="SQI" />\r
+  <lcid name="sv_SE" id="0x041D" parent="0x001D" iso2="sv" iso3="swe" win="SVE" />\r
+  <lcid name="th_TH" id="0x041E" parent="0x001E" iso2="th" iso3="tha" win="THA" />\r
+  <lcid name="tr_TR" id="0x041F" parent="0x001F" iso2="tr" iso3="tur" win="TRK" />\r
+  <lcid name="ur_PK" id="0x0420" parent="0x0020" iso2="ur" iso3="urd" win="URD" />\r
+  <lcid name="id_ID" id="0x0421" parent="0x0021" iso2="id" iso3="ind" win="IND" />\r
+  <lcid name="uk_UA" id="0x0422" parent="0x0022" iso2="uk" iso3="ukr" win="UKR" />\r
+  <lcid name="be_BY" id="0x0423" parent="0x0023" iso2="be" iso3="bel" win="BEL" />\r
+  <lcid name="sl_SI" id="0x0424" parent="0x0024" iso2="sl" iso3="slv" win="SLV" />\r
+  <lcid name="et_EE" id="0x0425" parent="0x0025" iso2="et" iso3="est" win="ETI" />\r
+  <lcid name="lv_LV" id="0x0426" parent="0x0026" iso2="lv" iso3="lav" win="LVI" />\r
+  <lcid name="lt_LT" id="0x0427" parent="0x0027" iso2="lt" iso3="lit" win="LTH" />\r
+  <lcid name="tg_Cyrl_TJ" id="0x0428" parent="0x7C28" iso2="tg" iso3="tgk" win="TAJ" />\r
+  <lcid name="fa_IR" id="0x0429" parent="0x0029" iso2="fa" iso3="fas" win="FAR" />\r
+  <lcid name="vi_VN" id="0x042A" parent="0x002A" iso2="vi" iso3="vie" win="VIT" />\r
+  <lcid name="hy_AM" id="0x042B" parent="0x002B" iso2="hy" iso3="hye" win="HYE" />\r
+  <lcid name="az_Latn_AZ" id="0x042C" parent="0x782C" iso2="az" iso3="aze" win="AZE" />\r
+  <lcid name="eu_ES" id="0x042D" parent="0x002D" iso2="eu" iso3="eus" win="EUQ" />\r
+  <lcid name="hsb_DE" id="0x042E" parent="0x002E" iso2="hsb" iso3="hsb" win="HSB" />\r
+  <lcid name="mk_MK" id="0x042F" parent="0x002F" iso2="mk" iso3="mkd" win="MKI" />\r
+  <lcid name="tn_ZA" id="0x0432" parent="0x0032" iso2="tn" iso3="tsn" win="TSN" />\r
+  <lcid name="xh_ZA" id="0x0434" parent="0x0034" iso2="xh" iso3="xho" win="XHO" />\r
+  <lcid name="zu_ZA" id="0x0435" parent="0x0035" iso2="zu" iso3="zul" win="ZUL" />\r
+  <lcid name="af_ZA" id="0x0436" parent="0x0036" iso2="af" iso3="afr" win="AFK" />\r
+  <lcid name="ka_GE" id="0x0437" parent="0x0037" iso2="ka" iso3="kat" win="KAT" />\r
+  <lcid name="fo_FO" id="0x0438" parent="0x0038" iso2="fo" iso3="fao" win="FOS" />\r
+  <lcid name="hi_IN" id="0x0439" parent="0x0039" iso2="hi" iso3="hin" win="HIN" />\r
+  <lcid name="mt_MT" id="0x043A" parent="0x003A" iso2="mt" iso3="mlt" win="MLT" />\r
+  <lcid name="se_NO" id="0x043B" parent="0x003B" iso2="se" iso3="sme" win="SME" />\r
+  <lcid name="ms_MY" id="0x043E" parent="0x003E" iso2="ms" iso3="msa" win="MSL" />\r
+  <lcid name="kk_KZ" id="0x043F" parent="0x003F" iso2="kk" iso3="kaz" win="KKZ" />\r
+  <lcid name="ky_KG" id="0x0440" parent="0x0040" iso2="ky" iso3="kir" win="KYR" />\r
+  <lcid name="sw_KE" id="0x0441" parent="0x0041" iso2="sw" iso3="swa" win="SWK" />\r
+  <lcid name="tk_TM" id="0x0442" parent="0x0042" iso2="tk" iso3="tuk" win="TUK" />\r
+  <lcid name="uz_Latn_UZ" id="0x0443" parent="0x7C43" iso2="uz" iso3="uzb" win="UZB" />\r
+  <lcid name="tt_RU" id="0x0444" parent="0x0044" iso2="tt" iso3="tat" win="TTT" />\r
+  <lcid name="bn_IN" id="0x0445" parent="0x0045" iso2="bn" iso3="bng" win="BNG" />\r
+  <lcid name="pa_IN" id="0x0446" parent="0x0046" iso2="pa" iso3="pan" win="PAN" />\r
+  <lcid name="gu_IN" id="0x0447" parent="0x0047" iso2="gu" iso3="guj" win="GUJ" />\r
+  <lcid name="or_IN" id="0x0448" parent="0x0048" iso2="or" iso3="ori" win="ORI" />\r
+  <lcid name="ta_IN" id="0x0449" parent="0x0049" iso2="ta" iso3="tam" win="TAM" />\r
+  <lcid name="te_IN" id="0x044A" parent="0x004A" iso2="te" iso3="tel" win="TEL" />\r
+  <lcid name="kn_IN" id="0x044B" parent="0x004B" iso2="kn" iso3="kan" win="KDI" />\r
+  <lcid name="ml_IN" id="0x044C" parent="0x004C" iso2="ml" iso3="mym" win="MYM" />\r
+  <lcid name="as_IN" id="0x044D" parent="0x004D" iso2="as" iso3="asm" win="ASM" />\r
+  <lcid name="mr_IN" id="0x044E" parent="0x004E" iso2="mr" iso3="mar" win="MAR" />\r
+  <lcid name="sa_IN" id="0x044F" parent="0x004F" iso2="sa" iso3="san" win="SAN" />\r
+  <lcid name="mn_MN" id="0x0450" parent="0x7850" iso2="mn" iso3="mon" win="MNN" />\r
+  <lcid name="bo_CN" id="0x0451" parent="0x0051" iso2="bo" iso3="bod" win="BOB" />\r
+  <lcid name="cy_GB" id="0x0452" parent="0x0052" iso2="cy" iso3="cym" win="CYM" />\r
+  <lcid name="km_KH" id="0x0453" parent="0x0053" iso2="km" iso3="khm" win="KHM" />\r
+  <lcid name="lo_LA" id="0x0454" parent="0x0054" iso2="lo" iso3="lao" win="LAO" />\r
+  <lcid name="gl_ES" id="0x0456" parent="0x0056" iso2="gl" iso3="glg" win="GLC" />\r
+  <lcid name="kok_IN" id="0x0457" parent="0x0057" iso2="kok" iso3="kok" win="KNK" />\r
+  <lcid name="syr_SY" id="0x045A" parent="0x005A" iso2="syr" iso3="syr" win="SYR" />\r
+  <lcid name="si_LK" id="0x045B" parent="0x005B" iso2="si" iso3="sin" win="SIN" />\r
+  <lcid name="iu_Cans_CA" id="0x045D" parent="0x785D" iso2="iu" iso3="iku" win="IUS" />\r
+  <lcid name="am_ET" id="0x045E" parent="0x005E" iso2="am" iso3="amh" win="AMH" />\r
+  <lcid name="ne_NP" id="0x0461" parent="0x0061" iso2="ne" iso3="nep" win="NEP" />\r
+  <lcid name="fy_NL" id="0x0462" parent="0x0062" iso2="fy" iso3="fry" win="FYN" />\r
+  <lcid name="ps_AF" id="0x0463" parent="0x0063" iso2="ps" iso3="pus" win="PAS" />\r
+  <lcid name="fil_PH" id="0x0464" parent="0x0064" iso2="fil" iso3="fil" win="FPO" />\r
+  <lcid name="dv_MV" id="0x0465" parent="0x0065" iso2="dv" iso3="div" win="DIV" />\r
+  <lcid name="ha_Latn_NG" id="0x0468" parent="0x7C68" iso2="ha" iso3="hau" win="HAU" />\r
+  <lcid name="yo_NG" id="0x046A" parent="0x006A" iso2="yo" iso3="yor" win="YOR" />\r
+  <lcid name="quz_BO" id="0x046B" parent="0x006B" iso2="quz" iso3="qub" win="QUB" />\r
+  <lcid name="nso_ZA" id="0x046C" parent="0x006C" iso2="nso" iso3="nso" win="NSO" />\r
+  <lcid name="ba_RU" id="0x046D" parent="0x006D" iso2="ba" iso3="bak" win="BAS" />\r
+  <lcid name="lb_LU" id="0x046E" parent="0x006E" iso2="lb" iso3="ltz" win="LBX" />\r
+  <lcid name="kl_GL" id="0x046F" parent="0x006F" iso2="kl" iso3="kal" win="KAL" />\r
+  <lcid name="ig_NG" id="0x0470" parent="0x0070" iso2="ig" iso3="ibo" win="IBO" />\r
+  <lcid name="ii_CN" id="0x0478" parent="0x0078" iso2="ii" iso3="iii" win="III" />\r
+  <lcid name="arn_CL" id="0x047A" parent="0x007A" iso2="arn" iso3="arn" win="MPD" />\r
+  <lcid name="moh_CA" id="0x047C" parent="0x007C" iso2="moh" iso3="moh" win="MWK" />\r
+  <lcid name="br_FR" id="0x047E" parent="0x007E" iso2="br" iso3="bre" win="BRE" />\r
+  <lcid name="ug_CN" id="0x0480" parent="0x0080" iso2="ug" iso3="uig" win="UIG" />\r
+  <lcid name="mi_NZ" id="0x0481" parent="0x0081" iso2="mi" iso3="mri" win="MRI" />\r
+  <lcid name="oc_FR" id="0x0482" parent="0x0082" iso2="oc" iso3="oci" win="OCI" />\r
+  <lcid name="co_FR" id="0x0483" parent="0x0083" iso2="co" iso3="cos" win="COS" />\r
+  <lcid name="gsw_FR" id="0x0484" parent="0x0084" iso2="gsw" iso3="gsw" win="GSW" />\r
+  <lcid name="sah_RU" id="0x0485" parent="0x0085" iso2="sah" iso3="sah" win="SAH" />\r
+  <lcid name="qut_GT" id="0x0486" parent="0x0086" iso2="qut" iso3="qut" win="QUT" />\r
+  <lcid name="rw_RW" id="0x0487" parent="0x0087" iso2="rw" iso3="kin" win="KIN" />\r
+  <lcid name="wo_SN" id="0x0488" parent="0x0088" iso2="wo" iso3="wol" win="WOL" />\r
+  <lcid name="prs_AF" id="0x048C" parent="0x008C" iso2="prs" iso3="prs" win="PRS" />\r
+  <lcid name="gd_GB" id="0x0491" parent="0x0091" iso2="gd" iso3="gla" win="GLA" />\r
+  <lcid name="ar_IQ" id="0x0801" parent="0x0001" iso2="ar" iso3="ara" win="ARI" />\r
+  <lcid name="zh_CN" id="0x0804" parent="0x0004" iso2="zh" iso3="zho" win="CHS" />\r
+  <lcid name="de_CH" id="0x0807" parent="0x0007" iso2="de" iso3="deu" win="DES" />\r
+  <lcid name="en_GB" id="0x0809" parent="0x0009" iso2="en" iso3="eng" win="ENG" />\r
+  <lcid name="es_MX" id="0x080A" parent="0x000A" iso2="es" iso3="spa" win="ESM" />\r
+  <lcid name="fr_BE" id="0x080C" parent="0x000C" iso2="fr" iso3="fra" win="FRB" />\r
+  <lcid name="it_CH" id="0x0810" parent="0x0010" iso2="it" iso3="ita" win="ITS" />\r
+  <lcid name="nl_BE" id="0x0813" parent="0x0013" iso2="nl" iso3="nld" win="NLB" />\r
+  <lcid name="nn_NO" id="0x0814" parent="0x7814" iso2="nn" iso3="nno" win="NON" />\r
+  <lcid name="pt_PT" id="0x0816" parent="0x0016" iso2="pt" iso3="por" win="PTG" />\r
+  <lcid name="sr_Latn_CS" id="0x081A" parent="0x701A" iso2="sr" iso3="srp" win="SRL" />\r
+  <lcid name="sv_FI" id="0x081D" parent="0x001D" iso2="sv" iso3="swe" win="SVF" />\r
+  <lcid name="az_Cyrl_AZ" id="0x082C" parent="0x742C" iso2="az" iso3="aze" win="AZC" />\r
+  <lcid name="dsb_DE" id="0x082E" parent="0x7C2E" iso2="dsb" iso3="dsb" win="DSB" />\r
+  <lcid name="se_SE" id="0x083B" parent="0x003B" iso2="se" iso3="smf" win="SMF" />\r
+  <lcid name="ga_IE" id="0x083C" parent="0x003C" iso2="ga" iso3="gle" win="IRE" />\r
+  <lcid name="ms_BN" id="0x083E" parent="0x003E" iso2="ms" iso3="msa" win="MSB" />\r
+  <lcid name="uz_Cyrl_UZ" id="0x0843" parent="0x7843" iso2="uz" iso3="uzb" win="UZB" />\r
+  <lcid name="bn_BD" id="0x0845" parent="0x0045" iso2="bn" iso3="bng" win="BNB" />\r
+  <lcid name="mn_Mong_CN" id="0x0850" parent="0x7C50" iso2="mn" iso3="mon" win="MNG" />\r
+  <lcid name="iu_Latn_CA" id="0x085D" parent="0x7C5D" iso2="iu" iso3="iku" win="IUK" />\r
+  <lcid name="tzm_Latn_DZ" id="0x085F" parent="0x7C5F" iso2="tzm" iso3="tzm" win="TZM" />\r
+  <lcid name="quz_EC" id="0x086B" parent="0x006B" iso2="quz" iso3="que" win="QUE" />\r
+  <lcid name="ar_EG" id="0x0C01" parent="0x0001" iso2="ar" iso3="ara" win="ARE" />\r
+  <lcid name="zh_HK" id="0x0C04" parent="0x7C04" iso2="zh" iso3="zho" win="ZHH" />\r
+  <lcid name="de_AT" id="0x0C07" parent="0x0007" iso2="de" iso3="deu" win="DEA" />\r
+  <lcid name="en_AU" id="0x0C09" parent="0x0009" iso2="en" iso3="eng" win="ENA" />\r
+  <lcid name="es_ES" id="0x0C0A" parent="0x000A" iso2="es" iso3="spa" win="ESN" />\r
+  <lcid name="fr_CA" id="0x0C0C" parent="0x000C" iso2="fr" iso3="fra" win="FRC" />\r
+  <lcid name="sr_Cyrl_CS" id="0x0C1A" parent="0x6C1A" iso2="sr" iso3="srp" win="SRB" />\r
+  <lcid name="se_FI" id="0x0C3B" parent="0x003B" iso2="se" iso3="smg" win="SMG" />\r
+  <lcid name="quz_PE" id="0x0C6B" parent="0x006B" iso2="quz" iso3="qup" win="QUP" />\r
+  <lcid name="ar_LY" id="0x1001" parent="0x0001" iso2="ar" iso3="ara" win="ARL" />\r
+  <lcid name="zh_SG" id="0x1004" parent="0x0004" iso2="zh" iso3="zho" win="ZHI" />\r
+  <lcid name="de_LU" id="0x1007" parent="0x0007" iso2="de" iso3="deu" win="DEL" />\r
+  <lcid name="en_CA" id="0x1009" parent="0x0009" iso2="en" iso3="eng" win="ENC" />\r
+  <lcid name="es_GT" id="0x100A" parent="0x000A" iso2="es" iso3="spa" win="ESG" />\r
+  <lcid name="fr_CH" id="0x100C" parent="0x000C" iso2="fr" iso3="fra" win="FRS" />\r
+  <lcid name="hr_BA" id="0x101A" parent="0x001A" iso2="hr" iso3="hrb" win="HRB" />\r
+  <lcid name="smj_NO" id="0x103B" parent="0x7C3B" iso2="smj" iso3="smj" win="SMJ" />\r
+  <lcid name="ar_DZ" id="0x1401" parent="0x0001" iso2="ar" iso3="ara" win="ARG" />\r
+  <lcid name="zh_MO" id="0x1404" parent="0x7C04" iso2="zh" iso3="zho" win="ZHM" />\r
+  <lcid name="de_LI" id="0x1407" parent="0x0007" iso2="de" iso3="deu" win="DEC" />\r
+  <lcid name="en_NZ" id="0x1409" parent="0x0009" iso2="en" iso3="eng" win="ENZ" />\r
+  <lcid name="es_CR" id="0x140A" parent="0x000A" iso2="es" iso3="spa" win="ESC" />\r
+  <lcid name="fr_LU" id="0x140C" parent="0x000C" iso2="fr" iso3="fra" win="FRL" />\r
+  <lcid name="bs_Latn_BA" id="0x141A" parent="0x681A" iso2="bs" iso3="bsb" win="BSB" />\r
+  <lcid name="smj_SE" id="0x143B" parent="0x7C3B" iso2="smj" iso3="smk" win="SMK" />\r
+  <lcid name="ar_MA" id="0x1801" parent="0x0001" iso2="ar" iso3="ara" win="ARM" />\r
+  <lcid name="en_IE" id="0x1809" parent="0x0009" iso2="en" iso3="eng" win="ENI" />\r
+  <lcid name="es_PA" id="0x180A" parent="0x000A" iso2="es" iso3="spa" win="ESA" />\r
+  <lcid name="fr_MC" id="0x180C" parent="0x000C" iso2="fr" iso3="fra" win="FRM" />\r
+  <lcid name="sr_Latn_BA" id="0x181A" parent="0x701A" iso2="sr" iso3="srs" win="SRS" />\r
+  <lcid name="sma_NO" id="0x183B" parent="0x783B" iso2="sma" iso3="sma" win="SMA" />\r
+  <lcid name="ar_TN" id="0x1C01" parent="0x0001" iso2="ar" iso3="ara" win="ART" />\r
+  <lcid name="en_ZA" id="0x1C09" parent="0x0009" iso2="en" iso3="eng" win="ENS" />\r
+  <lcid name="es_DO" id="0x1C0A" parent="0x000A" iso2="es" iso3="spa" win="ESD" />\r
+  <lcid name="sr_Cyrl_BA" id="0x1C1A" parent="0x6C1A" iso2="sr" iso3="srn" win="SRN" />\r
+  <lcid name="sma_SE" id="0x1C3B" parent="0x783B" iso2="sma" iso3="smb" win="SMB" />\r
+  <lcid name="ar_OM" id="0x2001" parent="0x0001" iso2="ar" iso3="ara" win="ARO" />\r
+  <lcid name="en_JM" id="0x2009" parent="0x0009" iso2="en" iso3="eng" win="ENJ" />\r
+  <lcid name="es_VE" id="0x200A" parent="0x000A" iso2="es" iso3="spa" win="ESV" />\r
+  <lcid name="bs_Cyrl_BA" id="0x201A" parent="0x641A" iso2="bs" iso3="bsc" win="BSC" />\r
+  <lcid name="sms_FI" id="0x203B" parent="0x743B" iso2="sms" iso3="sms" win="SMS" />\r
+  <lcid name="ar_YE" id="0x2401" parent="0x0001" iso2="ar" iso3="ara" win="ARY" />\r
+  <lcid name="en_029" id="0x2409" parent="0x0009" iso2="en" iso3="eng" win="ENB" />\r
+  <lcid name="es_CO" id="0x240A" parent="0x000A" iso2="es" iso3="spa" win="ESO" />\r
+  <lcid name="sr_Latn_RS" id="0x241A" parent="0x701A" iso2="sr" iso3="srp" win="SRM" />\r
+  <lcid name="smn_FI" id="0x243B" parent="0x703B" iso2="smn" iso3="smn" win="SMN" />\r
+  <lcid name="ar_SY" id="0x2801" parent="0x0001" iso2="ar" iso3="ara" win="ARS" />\r
+  <lcid name="en_BZ" id="0x2809" parent="0x0009" iso2="en" iso3="eng" win="ENL" />\r
+  <lcid name="es_PE" id="0x280A" parent="0x000A" iso2="es" iso3="spa" win="ESR" />\r
+  <lcid name="sr_Cyrl_RS" id="0x281A" parent="0x6C1A" iso2="sr" iso3="srp" win="SRO" />\r
+  <lcid name="ar_JO" id="0x2C01" parent="0x0001" iso2="ar" iso3="ara" win="ARJ" />\r
+  <lcid name="en_TT" id="0x2C09" parent="0x0009" iso2="en" iso3="eng" win="ENT" />\r
+  <lcid name="es_AR" id="0x2C0A" parent="0x000A" iso2="es" iso3="spa" win="ESS"  />\r
+  <lcid name="sr_Latn_ME" id="0x2C1A" parent="0x701A" iso2="sr" iso3="srp" win="SRP" />\r
+  <lcid name="ar_LB" id="0x3001" parent="0x0001" iso2="ar" iso3="ara" win="ARB" />\r
+  <lcid name="en_ZW" id="0x3009" parent="0x0009" iso2="en" iso3="eng" win="ENW" />\r
+  <lcid name="es_EC" id="0x300A" parent="0x000A" iso2="es" iso3="spa" win="ESF" />\r
+  <lcid name="sr_Cyrl_ME" id="0x301A" parent="0x6C1A" iso2="sr" iso3="srp" win="SRQ" />\r
+  <lcid name="ar_KW" id="0x3401" parent="0x0001" iso2="ar" iso3="ara" win="ARK" />\r
+  <lcid name="en_PH" id="0x3409" parent="0x0009" iso2="en" iso3="eng" win="ENP" />\r
+  <lcid name="es_CL" id="0x340A" parent="0x000A" iso2="es" iso3="spa" win="ESL" />\r
+  <lcid name="ar_AE" id="0x3801" parent="0x0001" iso2="ar" iso3="ara" win="ARU" />\r
+  <lcid name="es_UY" id="0x380A" parent="0x000A" iso2="es" iso3="spa" win="ESY" />\r
+  <lcid name="ar_BH" id="0x3C01" parent="0x0001" iso2="ar" iso3="ara" win="ARH" />\r
+  <lcid name="es_PY" id="0x3C0A" parent="0x000A" iso2="es" iso3="spa" win="ESZ" />\r
+  <lcid name="ar_QA" id="0x4001" parent="0x0001" iso2="ar" iso3="ara" win="ARQ" />\r
+  <lcid name="en_IN" id="0x4009" parent="0x0009" iso2="en" iso3="eng" win="ENN" />\r
+  <lcid name="es_BO" id="0x400A" parent="0x000A" iso2="es" iso3="spa" win="ESB" />\r
+  <lcid name="en_MY" id="0x4409" parent="0x0009" iso2="en" iso3="eng" win="ENM" />\r
+  <lcid name="es_SV" id="0x440A" parent="0x000A" iso2="es" iso3="spa" win="ESE" />\r
+  <lcid name="en_SG" id="0x4809" parent="0x0009" iso2="en" iso3="eng" win="ENE" />\r
+  <lcid name="es_HN" id="0x480A" parent="0x000A" iso2="es" iso3="spa" win="ESH" />\r
+  <lcid name="es_NI" id="0x4C0A" parent="0x000A" iso2="es" iso3="spa" win="ESI" />\r
+  <lcid name="es_PR" id="0x500A" parent="0x000A" iso2="es" iso3="spa" win="ESU" />\r
+  <lcid name="es_US" id="0x540A" parent="0x000A" iso2="es" iso3="spa" win="EST" />\r
+  <lcid name="bs_Cyrl" id="0x641A" parent="0x781A" iso2="bs" iso3="bsc" win="BSC" />\r
+  <lcid name="bs_Latn" id="0x681A" parent="0x781A" iso2="bs" iso3="bsb" win="BSB" />\r
+  <lcid name="sr_Cyrl" id="0x6C1A" parent="0x7C1A" iso2="sr" iso3="srp" win="SRO" />\r
+  <lcid name="sr_Latn" id="0x701A" parent="0x7C1A" iso2="sr" iso3="srp" win="SRM" />\r
+  <lcid name="smn" id="0x703B" parent="0x003B" iso2="smn" iso3="smn" win="SMN"  />\r
+  <lcid name="az_Cyrl" id="0x742C" parent="0x002C" iso2="az" iso3="aze" win="AZC" />\r
+  <lcid name="sms" id="0x743B" parent="0x003B" iso2="sms" iso3="sms" win="SMS" />\r
+  <lcid name="zh" id="0x7804" parent="0x007F" iso2="zh" iso3="zho" win="CHS" />\r
+  <lcid name="nn" id="0x7814" parent="0x0014" iso2="nn" iso3="nno" win="NON" />\r
+  <lcid name="bs" id="0x781A" parent="0x007F" iso2="bs" iso3="bsb" win="BSB" />\r
+  <lcid name="az_Latn" id="0x782C" parent="0x002C" iso2="az" iso3="aze" win="AZE" />\r
+  <lcid name="sma" id="0x783B" parent="0x003B" iso2="sma" iso3="smb" win="SMB" />\r
+  <lcid name="uz_Cyrl" id="0x7843" parent="0x0043" iso2="uz" iso3="uzb" win="UZB" />\r
+  <lcid name="mn_Cyrl" id="0x7850" parent="0x0050" iso2="mn" iso3="mon" win="MNN" />\r
+  <lcid name="iu_Cans" id="0x785D" parent="0x005D" iso2="iu" iso3="iku" win="IUS" />\r
+  <lcid name="zh_Hant" id="0x7C04" parent="0x7804" iso2="zh" iso3="zho" win="CHT" />\r
+  <lcid name="zh_CHT" id="0x7C04" parent="0x7C04" iso2="zh" iso3="zho" win="CHT" />\r
+  <lcid name="nb" id="0x7C14" parent="0x0014" iso2="nb" iso3="nob" win="NOR" />\r
+  <lcid name="sr" id="0x7C1A" parent="0x007F" iso2="sr" iso3="srp" win="SRB" />\r
+  <lcid name="tg_Cyrl" id="0x7C28" parent="0x0028" iso2="tg" iso3="tgk" win="TAJ" />\r
+  <lcid name="dsb" id="0x7C2E" parent="0x002E" iso2="dsb" iso3="dsb" win="DSB" />\r
+  <lcid name="smj" id="0x7C3B" parent="0x003B" iso2="smj" iso3="smk" win="SMK" />\r
+  <lcid name="uz_Latn" id="0x7C43" parent="0x0043" iso2="uz" iso3="uzb" win="UZB" />\r
+  <lcid name="mn_Mong" id="0x7C50" parent="0x0050" iso2="mn" iso3="mon" win="MNG" />\r
+  <lcid name="iu_Latn" id="0x7C5D" parent="0x005D" iso2="iu" iso3="iku" win="IUK" />\r
+  <lcid name="tzm_Latn" id="0x7C5F" parent="0x005F" iso2="tzm" iso3="tzm" win="TZM" />\r
+  <lcid name="ha_Latn" id="0x7C68" parent="0x0068" iso2="ha" iso3="hau" win="HAU" />\r
 </lcids>
\ No newline at end of file
diff --git a/tools/locale-builder/locale-builder.csproj b/tools/locale-builder/locale-builder.csproj
new file mode 100644 (file)
index 0000000..b032eba
--- /dev/null
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="utf-8"?>\r
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup>\r
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>\r
+    <Platform Condition=" '$(Platform)' == '' ">x86</Platform>\r
+    <ProjectGuid>{A57C517C-9795-471D-B510-DD9659096CAB}</ProjectGuid>\r
+    <OutputType>Exe</OutputType>\r
+    <NoStandardLibraries>false</NoStandardLibraries>\r
+    <AssemblyName>ConsoleApplication</AssemblyName>\r
+    <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>\r
+    <TargetFrameworkProfile>\r
+    </TargetFrameworkProfile>\r
+    <FileAlignment>512</FileAlignment>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">\r
+    <DebugSymbols>true</DebugSymbols>\r
+    <DebugType>full</DebugType>\r
+    <Optimize>false</Optimize>\r
+    <OutputPath>bin\Debug\</OutputPath>\r
+    <DefineConstants>DEBUG;TRACE</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <PlatformTarget>x86</PlatformTarget>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">\r
+    <DebugType>pdbonly</DebugType>\r
+    <Optimize>true</Optimize>\r
+    <OutputPath>bin\Release\</OutputPath>\r
+    <DefineConstants>TRACE</DefineConstants>\r
+    <ErrorReport>prompt</ErrorReport>\r
+    <WarningLevel>4</WarningLevel>\r
+    <PlatformTarget>x86</PlatformTarget>\r
+  </PropertyGroup>\r
+  <PropertyGroup>\r
+    <RootNamespace>Mono.Tools.LocaleBuilder</RootNamespace>\r
+  </PropertyGroup>\r
+  <ItemGroup>\r
+    <Reference Include="Microsoft.CSharp" />\r
+    <Reference Include="System" />\r
+    <Reference Include="System.Core" />\r
+    <Reference Include="System.Data" />\r
+    <Reference Include="System.Data.DataSetExtensions" />\r
+    <Reference Include="System.Xml" />\r
+    <Reference Include="System.Xml.Linq" />\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <None Include="app.config" />\r
+    <None Include="README" />\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <Compile Include="CalendarType.cs" />\r
+    <Compile Include="Constants.cs" />\r
+    <Compile Include="CultureInfoEntry.cs" />\r
+    <Compile Include="DateTimeFormatEntry.cs" />\r
+    <Compile Include="Driver.cs" />\r
+    <Compile Include="Entry.cs" />\r
+    <Compile Include="NumberFormatEntry.cs" />\r
+    <Compile Include="Patterns.cs" />\r
+    <Compile Include="RegionInfoEntry.cs" />\r
+    <Compile Include="TextInfoEntry.cs" />\r
+  </ItemGroup>\r
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSHARP.Targets" />\r
+  <ProjectExtensions>\r
+    <VisualStudio AllowExistingFolder="true" />\r
+  </ProjectExtensions>\r
+</Project>
\ No newline at end of file
diff --git a/tools/locale-builder/locales/.gitattributes b/tools/locale-builder/locales/.gitattributes
deleted file mode 100644 (file)
index 46581df..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-/nb_NO.xml -crlf
-/nn_NO.xml -crlf
diff --git a/tools/locale-builder/locales/.gitignore b/tools/locale-builder/locales/.gitignore
deleted file mode 100644 (file)
index b878e88..0000000
+++ /dev/null
@@ -1 +0,0 @@
-/*.xml
diff --git a/tools/locale-builder/locales/ka_GE.xml b/tools/locale-builder/locales/ka_GE.xml
deleted file mode 100644 (file)
index e2009e9..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "../../common/dtd/ldml.dtd">
-<ldml>
-       <identity>
-               <version number="$Revision: 1.37 $"/>
-               <generation date="$Date: 2009/05/05 23:06:37 $"/>
-               <language type="ka"/>
-               <territory type="GE"/>
-       </identity>
-</ldml>
diff --git a/tools/locale-builder/locales/nb_NO.xml b/tools/locale-builder/locales/nb_NO.xml
deleted file mode 100644 (file)
index 8e330ab..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>\r
-<!DOCTYPE ldml SYSTEM "http://www.unicode.org/cldr/dtd/1.3/ldml.dtd">\r
-<ldml>\r
-       <identity>\r
-               <version number="$Revision: 1.27 $"/>\r
-               <generation date="$Date: 2005/05/18 16:40:56 $"/>\r
-               <language type="nb"/>\r
-               <territory type="NO"/>\r
-       </identity>\r
-       <delimiters>\r
-               <quotationStart draft="true">’</quotationStart>\r
-               <quotationEnd draft="true">’</quotationEnd>\r
-               <alternateQuotationStart draft="true">«</alternateQuotationStart>\r
-               <alternateQuotationEnd draft="true">»</alternateQuotationEnd>\r
-       </delimiters>\r
-       <numbers>\r
-               <currencyFormats>\r
-                       <currencyFormatLength>\r
-                               <currencyFormat>\r
-                                       <pattern>#,##0.00 ¤</pattern>\r
-                               </currencyFormat>\r
-                       </currencyFormatLength>\r
-               </currencyFormats>\r
-       </numbers>\r
-</ldml>\r
-\r
diff --git a/tools/locale-builder/locales/nn_NO.xml b/tools/locale-builder/locales/nn_NO.xml
deleted file mode 100644 (file)
index 598d599..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>\r
-<!DOCTYPE ldml SYSTEM "http://www.unicode.org/cldr/dtd/1.3/ldml.dtd">\r
-<ldml>\r
-       <identity>\r
-               <version number="$Revision: 1.27 $"/>\r
-               <generation date="$Date: 2005/04/29 18:42:04 $"/>\r
-               <language type="nn"/>\r
-               <territory type="NO"/>\r
-       </identity>\r
-       <delimiters>\r
-               <quotationStart draft="true">’</quotationStart>\r
-               <quotationEnd draft="true">’</quotationEnd>\r
-               <alternateQuotationStart draft="true">«</alternateQuotationStart>\r
-               <alternateQuotationEnd draft="true">»</alternateQuotationEnd>\r
-       </delimiters>\r
-       <numbers>\r
-               <currencyFormats>\r
-                       <currencyFormatLength>\r
-                               <currencyFormat>\r
-                                       <pattern>#,##0.00 ¤</pattern>\r
-                               </currencyFormat>\r
-                       </currencyFormatLength>\r
-               </currencyFormats>\r
-       </numbers>\r
-</ldml>\r
-\r
diff --git a/tools/locale-builder/supp/ChangeLog b/tools/locale-builder/supp/ChangeLog
deleted file mode 100644 (file)
index 28a3ef1..0000000
+++ /dev/null
@@ -1,114 +0,0 @@
-2010-03-23  Geoff Norton  <gnorton@novell.com>
-
-       * da_DK.xml: The short format is day. month, not 
-       day month.  Fixes #588165
-
-2008-09-18  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * sv_SE.xml : fix bug #426942 (sv-SE time format was old).
-
-2007-10-30  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * es_ES.xml : couple of format string fixes for bug #335298.
-
-2007-05-31  Rolf Bjarne Kvinge  <RKvinge@novell.com>
-
-       * en-US.xml: Add a few date/time patterns.
-
-2006-06-08  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * en.xml, en-US.xml : move US-only date patterns from en.xml to
-         en-US.xml. Fixed bug #78569.
-
-2005-08-17  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * fr.xml : fixed long date pattern and dateTimeFormats.
-       * ja.xml : fixed long time pattern and dateTimeFormats.
-
-2005-05-25  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * fr.xml : more date pattern.
-
-2005-05-25  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * fr.xml : new file.
-
-2005-04-23  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * ko_KR.xml : fixed time format.
-         Fixed bug #74701. Patch by Hye-Shik Chang.
-
-2005-02-17  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * en.xml : fixed currency format.
-
-2004-10-06  Jackson Harper  <jackson@ximian.com>
-
-       * pt.xml: We need a space after R$. Is there a better way to do
-       this? I should know...
-       * pt_BR.xml: Fix currency format.
-
-2004-06-08  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * ja.xml : added extra datetime patterns.
-       * renamed ca.xml to added ca_ES.xml.
-       * ca_ES.xml, ko_KR.xml, pt_BR.xml : fixed percent patterns.
-
-2004-06-08  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * en.xml : added "all datetime" pattern strings.
-       * ca.xml, da.xml, el.xml, fi.xml, fr_FR.xml, he.xml, hu.xml,
-         nl_NL.xml : fixed percent patterns.
-
-2004-06-05  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * en_US.xml : fixed percent pattern.
-       * en_ZA.xml : fixed NumberDecimalDigits.
-       * id_ID.xml : fixed CurrencyDecimalDigits.
-       * ja_JP.xml : added currencySymbol (MS assigns 0x5c).
-
-2004-06-05  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * fr_CH.xml : missing updates.
-       * Renamed cs.xml as cs_CZ.xml and added number format.
-         Also renamed lt.xml as lt_LT.xml. They are files' precedence matter.
-       * es_NI.xml : added.
-       * en.xml, en_CA.xml, en_IE.xml, en_PH.xml, en_US.xml, en_ZW.xml :
-         Change with related to the change of NumberDecimalDigits handling.
-       * es_PR.xml, ja.xml, ko_KR.xml :
-         Added number format.
-
-2004-05-27  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * en_PH.xml, en_ZW.xml, fr_CA.xml, fr_CH.xml, fr_FR.xml, fr_LU.xml :
-         fixed incorrect markup.
-
-2004-05-26  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * Added ChangeLog also here (and moved the last msg from ..).
-
-       * af_ZA.xml, ar_SA.xml, be_BY.xml, de_AT.xml, en_AU.xml, en_GB.xml,
-         en_NZ.xml, es_AR.xml, es_BO.xml, es_CL.xml, es_CO.xml, es_CR.xml,
-         es_DO.xml, es_EC.xml, es_ES.xml, es_GT.xml, es_HN.xml, es_MX.xml,
-         es_PA.xml, es_PE.xml, es_PR.xml, es_PY.xml, es_SV.xml, es_UY.xml,
-         es_VE.xml, eu_ES.xml,
-         fo_FO.xml, fr_BE.xml, fr_CA.xml, fr_FR.xml, fr_CH.xml, fr_FR.xml,
-         fr_LU.xml, hi_IN.xml, id_ID.xml, it_CH.xml, it_IT.xml, ko_KR.xml,
-         nl_BE.xml, nl_NL.xml, pt_BR.xml, pt_PT.xml, sv_FI.xml, sv_SE.xml,
-         sw_KE.xml, bg.xml, ca.xml, cs.xml, da.xml, de.xml, el.xml, es.xml,
-         et.xml, fa.xml, fi.xml, he.xml, hr.xml, hu.xml, hy.xml, is.xml,
-         lt.xml, lv.xml, mk.xml, ro.xml, ru.xml, sk.xml, sl.xml, sq.xml,
-         tr.xml, uk.xml, vi.xml :
-         Added shortdate/longtime/am/pm etc. for DateTime.ToString().
-       * ar_AE.xml, ar_BH.xml, ar_DZ.xml, ar_EG.xml, ar_JO.xml, ar_KW.xml,
-         ar_LB.xml, ar_LY.xml, ar_MA.xml, ar_OM.xml, ar_QA.xml, ar_SY.xml,
-         ar_TN.xml, ar_YE.xml, en_CA.xml, en_IE.xml, en_PH.xml, en_ZA.xml,
-         en_ZW.xml :
-         Added shortdate/longtime.
-       * th.xml : ditto.
-       * ja.xml : I incorrectly modified long time format. Reverting.
-
-2004-05-26  Atsushi Enomoto  <atsushi@ximian.com>
-
-       * pl.xml,
-         ja.xml : Added overriding formats. pl.xml fixes bug #58186.
diff --git a/tools/locale-builder/supp/af_ZA.xml b/tools/locale-builder/supp/af_ZA.xml
deleted file mode 100755 (executable)
index 1d1b18a..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <!-- hmm, LongTimePattern contains "tt", but neither "VM" nor "NM" is not in output. -->
-                               <am></am>
-                               <pm></pm>
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy/MM/dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/ar.xml b/tools/locale-builder/supp/ar.xml
deleted file mode 100644 (file)
index 3f0e3f0..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-          <calendars>
-            <calendar>
-               <optionalCalendars>
-                  <calendar type="Hijri" />
-                </optionalCalendars>
-            </calendar>
-          </calendars>
-        </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_AE.xml b/tools/locale-builder/supp/ar_AE.xml
deleted file mode 100644 (file)
index 8c6d684..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_BH.xml b/tools/locale-builder/supp/ar_BH.xml
deleted file mode 100644 (file)
index 8c6d684..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_DZ.xml b/tools/locale-builder/supp/ar_DZ.xml
deleted file mode 100644 (file)
index bbb9e19..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd-MM-yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
-
-
diff --git a/tools/locale-builder/supp/ar_EG.xml b/tools/locale-builder/supp/ar_EG.xml
deleted file mode 100644 (file)
index 2a0f8bb..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-               </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_IQ.xml b/tools/locale-builder/supp/ar_IQ.xml
deleted file mode 100644 (file)
index e348fc6..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-          <calendars>
-            <calendar>
-               <optionalCalendars>
-                  <calendar type="Gregorian" greg_type="USEnglish" />
-                  <calendar type="Gregorian" greg_type="Localized" />
-                </optionalCalendars>
-            </calendar>
-          </calendars>
-        </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_JO.xml b/tools/locale-builder/supp/ar_JO.xml
deleted file mode 100644 (file)
index 952f841..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
-
diff --git a/tools/locale-builder/supp/ar_KW.xml b/tools/locale-builder/supp/ar_KW.xml
deleted file mode 100644 (file)
index 8c6d684..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_LB.xml b/tools/locale-builder/supp/ar_LB.xml
deleted file mode 100644 (file)
index 8c6d684..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_LY.xml b/tools/locale-builder/supp/ar_LY.xml
deleted file mode 100644 (file)
index 8c6d684..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_MA.xml b/tools/locale-builder/supp/ar_MA.xml
deleted file mode 100644 (file)
index 0404544..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd-MM-yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_OM.xml b/tools/locale-builder/supp/ar_OM.xml
deleted file mode 100644 (file)
index 8c6d684..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_QA.xml b/tools/locale-builder/supp/ar_QA.xml
deleted file mode 100644 (file)
index 8c6d684..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_SA.xml b/tools/locale-builder/supp/ar_SA.xml
deleted file mode 100755 (executable)
index 76a8d61..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                  <calendar_type type="GregorianCalendar" />
-                </calendars>
-        </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_SY.xml b/tools/locale-builder/supp/ar_SY.xml
deleted file mode 100644 (file)
index 8c6d684..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ar_TN.xml b/tools/locale-builder/supp/ar_TN.xml
deleted file mode 100644 (file)
index bbb9e19..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd-MM-yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
-
-
diff --git a/tools/locale-builder/supp/ar_YE.xml b/tools/locale-builder/supp/ar_YE.xml
deleted file mode 100644 (file)
index 8c6d684..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="GregorianCalendar" />
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/be_BY.xml b/tools/locale-builder/supp/be_BY.xml
deleted file mode 100755 (executable)
index c907904..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/bg.xml b/tools/locale-builder/supp/bg.xml
deleted file mode 100755 (executable)
index 86ae563..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <default type="medium"/>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.M.yyyy 'г.'</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/ca_ES.xml b/tools/locale-builder/supp/ca_ES.xml
deleted file mode 100755 (executable)
index ba2db28..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>#,##0 %</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-       </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/cs_CZ.xml b/tools/locale-builder/supp/cs_CZ.xml
deleted file mode 100755 (executable)
index 275da59..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <decimalFormats>
-                       <decimalFormatLength >
-                               <decimalFormat >
-                                       <pattern>#,##0.###;-#,##0.###</pattern>
-                               </decimalFormat>
-                       </decimalFormatLength >
-               </decimalFormats>
-       </numbers>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d.M.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/da.xml b/tools/locale-builder/supp/da.xml
deleted file mode 100755 (executable)
index f79e328..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>#,##0 %</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-       </numbers>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd-MM-yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                                        <dateFormatLength type="month_day">
-                                                <dateFormat>
-                                                        <pattern>dd. MMMM</pattern>
-                                                </dateFormat>
-                                        </dateFormatLength>
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
diff --git a/tools/locale-builder/supp/de.xml b/tools/locale-builder/supp/de.xml
deleted file mode 100755 (executable)
index 4a7f338..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/de_AT.xml b/tools/locale-builder/supp/de_AT.xml
deleted file mode 100755 (executable)
index 4a7f338..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/el.xml b/tools/locale-builder/supp/el.xml
deleted file mode 100755 (executable)
index 8324717..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>#,##0 %</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-       </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d/M/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/en.xml b/tools/locale-builder/supp/en.xml
deleted file mode 100644 (file)
index a29945a..0000000
+++ /dev/null
@@ -1,89 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <numbers>
-               <decimalFormats>
-                       <decimalFormatLength >
-                               <decimalFormat >
-                                       <pattern>#,##0.###;-#,##0.###</pattern>
-                               </decimalFormat>
-                       </decimalFormatLength >
-               </decimalFormats>
-               <scientificFormats>
-                       <scientificFormatLength >
-                               <scientificFormat >
-                                       <pattern>#E0</pattern>
-                               </scientificFormat>
-                       </scientificFormatLength >
-               </scientificFormats>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>#,###.##0%</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-               <currencyFormats>
-                       <currencyFormatLength >
-                               <currencyFormat >
-                                       <pattern>¤#,##0.00;-¤#,##0.00</pattern>
-                               </currencyFormat>
-                       </currencyFormatLength >
-               </currencyFormats>
-       </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <default type="medium"/>
-                                       <dateFormatLength type="long">
-                                               <dateFormat >
-                                                       <pattern>dddd, MMMM dd, yyyy</pattern>
-                                               </dateFormat>
-                                               <extraPatterns>
-                                                       <pattern>dddd, MMMM dd, yyyy</pattern>
-                                                       <pattern>MMMM dd, yyyy</pattern>
-                                                       <pattern>dddd, dd MMMM, yyyy</pattern>
-                                                       <pattern>dd, MMMM, yyyy</pattern>
-                                               </extraPatterns>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <default type="medium"/>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss tt</pattern>
-                                               </timeFormat>
-                                               <extraPatterns>
-                                                       <pattern>h:mm:ss tt</pattern>
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                                       <pattern>H:mm:ss</pattern>
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </extraPatterns>
-                                       </timeFormatLength >
-                                       <timeFormatLength type="medium">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss a</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                                       <timeFormatLength type="short">
-                                               <timeFormat >
-                                                       <pattern>h:mm tt</pattern>
-                                               </timeFormat>
-                                               <extraPatterns>
-                                                       <pattern>h:mm tt</pattern>
-                                                       <pattern>hh:mm tt</pattern>
-                                                       <pattern>H:mm</pattern>
-                                                       <pattern>HH:mm</pattern>
-                                               </extraPatterns>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
diff --git a/tools/locale-builder/supp/en_AU.xml b/tools/locale-builder/supp/en_AU.xml
deleted file mode 100755 (executable)
index e4fa640..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/en_CA.xml b/tools/locale-builder/supp/en_CA.xml
deleted file mode 100644 (file)
index ee3149a..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-  <numbers>
-    <decimalFormats>
-      <decimalFormatLength >
-        <decimalFormat >
-          <pattern>#,##0.###;-#,##0.###</pattern>
-        </decimalFormat>
-      </decimalFormatLength >
-    </decimalFormats>
-  </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/en_GB.xml b/tools/locale-builder/supp/en_GB.xml
deleted file mode 100755 (executable)
index 3f097c8..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/en_IE.xml b/tools/locale-builder/supp/en_IE.xml
deleted file mode 100644 (file)
index 2b6f375..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-  <numbers>
-    <decimalFormats>
-      <decimalFormatLength >
-        <decimalFormat >
-          <pattern>#,##0.###;-#,##0.###</pattern>
-        </decimalFormat>
-      </decimalFormatLength >
-    </decimalFormats>
-  </numbers>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/en_NZ.xml b/tools/locale-builder/supp/en_NZ.xml
deleted file mode 100755 (executable)
index b36c1b4..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <am>a.m.</am>
-                               <pm>p.m.</pm>
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/en_PH.xml b/tools/locale-builder/supp/en_PH.xml
deleted file mode 100644 (file)
index 99096d9..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <am>AM</am>
-                               <pm>PM</pm>
-                               <dateFormats>
-                                       <default type="medium"/>
-                                       <dateFormatLength type="medium">
-                                               <dateFormat >
-                                                       <pattern>MM d, yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>M/d/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat>
-                                                       <pattern>h:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength>
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-  <numbers>
-    <decimalFormats>
-      <decimalFormatLength >
-        <decimalFormat >
-          <pattern>#,##0.###;-#,##0.###</pattern>
-        </decimalFormat>
-      </decimalFormatLength >
-    </decimalFormats>
-  </numbers>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/en_TT.xml b/tools/locale-builder/supp/en_TT.xml
deleted file mode 100644 (file)
index e7711ee..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <am>AM</am>
-                               <pm>PM</pm>
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                               <extraPatterns>
-                                                 <pattern>yyyy-MM-dd</pattern>
-                                               </extraPatterns>
-                                       </dateFormatLength >
-                                       <dateFormatLength type="long">
-                                         <dateFormat>
-                                           <pattern>dddd, dd MMMM yyyy</pattern>
-                                         </dateFormat>
-                                       </dateFormatLength>
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                               <extraPatterns>
-                                                 <pattern>HH:mm:ss</pattern>
-                                               </extraPatterns>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-  <numbers>
-    <decimalFormats>
-      <decimalFormatLength >
-        <decimalFormat >
-          <pattern>#,##0.###;-#,##0.###</pattern>
-        </decimalFormat>
-      </decimalFormatLength >
-    </decimalFormats>
-  </numbers>
-</ldml>
diff --git a/tools/locale-builder/supp/en_US.xml b/tools/locale-builder/supp/en_US.xml
deleted file mode 100644 (file)
index b6169a3..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-  <numbers>
-    <decimalFormats>
-      <decimalFormatLength >
-        <decimalFormat >
-          <pattern>#,##0.###;-#,##0.###</pattern>
-        </decimalFormat>
-      </decimalFormatLength >
-    </decimalFormats>
-    <percentFormats>
-      <percentFormatLength >
-        <percentFormat >
-          <pattern>#,##0 %</pattern>
-        </percentFormat>
-      </percentFormatLength >
-    </percentFormats>
-  </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>M/d/yyyy</pattern>
-                                               </dateFormat>
-                                               <extraPatterns>
-                                                       <pattern>M/d/yyyy</pattern>
-                                                       <pattern>M/d/yy</pattern>
-                                                       <pattern>M/d/yy</pattern>
-                                                       <pattern>MM/dd/yy</pattern>
-                                                       <pattern>MM/dd/yyyy</pattern>
-                                                       <pattern>yy/MM/dd</pattern>
-                                                       <pattern>yyyy-MM-dd</pattern>
-                                                       <pattern>dd-MMM-yy</pattern>
-                                               </extraPatterns>
-                                       </dateFormatLength >
-                                       <dateFormatLength type="long">
-                                               <dateFormat >
-                                                       <pattern>dddd, MMMM dd, yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                                       <dateFormatLength type="year_month">
-                                               <dateFormat >
-                                                       <pattern>MMMM, yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                               <dateTimeFormats>
-                                       <dateTimeFormatLength >
-                                               <dateTimeFormat>
-                                                       <pattern>{1} {0}</pattern>
-                                               </dateTimeFormat>
-                                       </dateTimeFormatLength >
-                               </dateTimeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/en_ZA.xml b/tools/locale-builder/supp/en_ZA.xml
deleted file mode 100644 (file)
index 8d3234e..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy/MM/dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-  <numbers>
-    <decimalFormats>
-      <decimalFormatLength >
-        <decimalFormat >
-          <pattern>#,##0.###;-#,##0.###</pattern>
-        </decimalFormat>
-      </decimalFormatLength >
-    </decimalFormats>
-  </numbers>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/en_ZW.xml b/tools/locale-builder/supp/en_ZW.xml
deleted file mode 100644 (file)
index 496808e..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <am>AM</am>
-                               <pm>PM</pm>
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>M/d/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-  <numbers>
-    <decimalFormats>
-      <decimalFormatLength >
-        <decimalFormat >
-          <pattern>#,##0.###;-#,##0.###</pattern>
-        </decimalFormat>
-      </decimalFormatLength >
-    </decimalFormats>
-  </numbers>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es.xml b/tools/locale-builder/supp/es.xml
deleted file mode 100755 (executable)
index 973908f..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <am>a.m.</am>
-                               <pm>p.m.</pm>
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>MM/dd/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_AR.xml b/tools/locale-builder/supp/es_AR.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_BO.xml b/tools/locale-builder/supp/es_BO.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_CL.xml b/tools/locale-builder/supp/es_CL.xml
deleted file mode 100755 (executable)
index 555b1ba..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd-MM-yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_CO.xml b/tools/locale-builder/supp/es_CO.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_CR.xml b/tools/locale-builder/supp/es_CR.xml
deleted file mode 100755 (executable)
index eccff24..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_DO.xml b/tools/locale-builder/supp/es_DO.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_EC.xml b/tools/locale-builder/supp/es_EC.xml
deleted file mode 100755 (executable)
index 8b62186..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_ES.xml b/tools/locale-builder/supp/es_ES.xml
deleted file mode 100755 (executable)
index 6ca89a7..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-                                       <dateFormatLength type="long">
-                                               <dateFormat>
-                                                       <pattern>dddd, dd' de 'MMMM' de 'yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-                                       <dateFormatLength type="full">
-                                               <dateFormat>
-                                                       <pattern>dddd, dd' de 'MMMM' de 'yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-                                       <dateFormatLength type="year_month">
-                                               <dateFormat>
-                                                       <pattern>MMMM' de 'yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-                                       <dateFormatLength type="month_day">
-                                               <dateFormat>
-                                                       <pattern>dd MMMM</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="full">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_GT.xml b/tools/locale-builder/supp/es_GT.xml
deleted file mode 100755 (executable)
index eccff24..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_HN.xml b/tools/locale-builder/supp/es_HN.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_MX.xml b/tools/locale-builder/supp/es_MX.xml
deleted file mode 100755 (executable)
index eccff24..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_NI.xml b/tools/locale-builder/supp/es_NI.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_PA.xml b/tools/locale-builder/supp/es_PA.xml
deleted file mode 100755 (executable)
index 5308262..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>MM/dd/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_PE.xml b/tools/locale-builder/supp/es_PE.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_PR.xml b/tools/locale-builder/supp/es_PR.xml
deleted file mode 100755 (executable)
index a7fb435..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-  <numbers>
-    <decimalFormats>
-      <decimalFormatLength >
-        <decimalFormat >
-          <pattern>#,##0.###;-#,##0.###</pattern>
-        </decimalFormat>
-      </decimalFormatLength >
-    </decimalFormats>
-  </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_PY.xml b/tools/locale-builder/supp/es_PY.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_SV.xml b/tools/locale-builder/supp/es_SV.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_UY.xml b/tools/locale-builder/supp/es_UY.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/es_VE.xml b/tools/locale-builder/supp/es_VE.xml
deleted file mode 100755 (executable)
index 49a89c2..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/et.xml b/tools/locale-builder/supp/et.xml
deleted file mode 100755 (executable)
index 1d8ef50..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/eu_ES.xml b/tools/locale-builder/supp/eu_ES.xml
deleted file mode 100755 (executable)
index 5a3dada..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy/MM/dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/fa.xml b/tools/locale-builder/supp/fa.xml
deleted file mode 100755 (executable)
index 8a232e6..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>M/d/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>hh:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/fi.xml b/tools/locale-builder/supp/fi.xml
deleted file mode 100755 (executable)
index 6d4f681..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>#,##0 %</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-       </numbers>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d.M.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/fo_FO.xml b/tools/locale-builder/supp/fo_FO.xml
deleted file mode 100755 (executable)
index 88fddca..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd-MM-yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH.mm.ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/fr.xml b/tools/locale-builder/supp/fr.xml
deleted file mode 100644 (file)
index 6dc13a6..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="long">
-                                               <dateFormat >
-                                                       <pattern>dddd d MMMM yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                                       <dateFormatLength type="short">
-                                               <extraPatterns>
-                                                       <pattern>d/MM/yyyy</pattern>
-                                                       <pattern>d/MM/yy</pattern>
-                                               </extraPatterns>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                               <dateTimeFormats>
-                                       <dateTimeFormatLength >
-                                               <dateTimeFormat>
-                                                       <pattern>{1} {0}</pattern>
-                                               </dateTimeFormat>
-                                       </dateTimeFormatLength >
-                               </dateTimeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/fr_BE.xml b/tools/locale-builder/supp/fr_BE.xml
deleted file mode 100755 (executable)
index 91cc07b..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/fr_CA.xml b/tools/locale-builder/supp/fr_CA.xml
deleted file mode 100755 (executable)
index f8a3cc8..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy-MM-dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/fr_CH.xml b/tools/locale-builder/supp/fr_CH.xml
deleted file mode 100755 (executable)
index f2de8b0..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/fr_FR.xml b/tools/locale-builder/supp/fr_FR.xml
deleted file mode 100755 (executable)
index ff3cd20..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>#,##0 %</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-       </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/fr_LU.xml b/tools/locale-builder/supp/fr_LU.xml
deleted file mode 100755 (executable)
index 88a4f57..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/he.xml b/tools/locale-builder/supp/he.xml
deleted file mode 100755 (executable)
index c95fbfd..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>%#,##0</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-       </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/hi_IN.xml b/tools/locale-builder/supp/hi_IN.xml
deleted file mode 100755 (executable)
index e13d460..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd-MM-yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/hr.xml b/tools/locale-builder/supp/hr.xml
deleted file mode 100755 (executable)
index 66e3996..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d.M.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/hu.xml b/tools/locale-builder/supp/hu.xml
deleted file mode 100755 (executable)
index ba3b66a..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>#,##0 %</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-       </numbers>
-       <dates>
-               <symbols>
-                       <dateSeparator>. </dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy. MM. dd.</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/hy.xml b/tools/locale-builder/supp/hy.xml
deleted file mode 100755 (executable)
index c907904..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/id_ID.xml b/tools/locale-builder/supp/id_ID.xml
deleted file mode 100755 (executable)
index 03a91e0..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <currencyFormats>
-                       <currencyFormatLength >
-                               <currencyFormat >
-                                       <pattern>#,##0;-#,##0</pattern>
-                               </currencyFormat>
-                       </currencyFormatLength >
-               </currencyFormats>
-       </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <default type="medium"/>
-                                       <dateFormatLength type="medium">
-                                               <dateFormat >
-                                                       <pattern>dd MMM yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/is.xml b/tools/locale-builder/supp/is.xml
deleted file mode 100755 (executable)
index 23f637e..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d.M.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/it_CH.xml b/tools/locale-builder/supp/it_CH.xml
deleted file mode 100755 (executable)
index 4a7f338..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/it_IT.xml b/tools/locale-builder/supp/it_IT.xml
deleted file mode 100755 (executable)
index 4dc3b55..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H.mm.ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/ja.xml b/tools/locale-builder/supp/ja.xml
deleted file mode 100755 (executable)
index 893830b..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <numbers>
-               <currencies>
-                       <currency type="JPY">
-                               <symbol>\</symbol>
-                       </currency>
-               </currencies>
-               <currencyFormats>
-                       <currencyFormatLength >
-                               <currencyFormat >
-                                       <pattern>#,##0;-#,##0</pattern>
-                               </currencyFormat>
-                       </currencyFormatLength >
-               </currencyFormats>
-       </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy/MM/dd</pattern>
-                                               </dateFormat>
-                                               <extraPatterns>
-                                                       <pattern>yyyy/MM/dd</pattern>
-                                                       <pattern>yy/MM/dd</pattern>
-                                                       <pattern>yy/M/d</pattern>
-                                                       <pattern>yyyy/M/d</pattern>
-                                                       <pattern>yy/MM/dd' ('ddd')'</pattern>
-                                                       <pattern>yy/M/d' ('ddd')'</pattern>
-                                                       <pattern>yyyy/M/d' ('ddd')'</pattern>
-                                                       <!-- we should not need yyyy-MM-dd that should be covered by yyyy/MM/dd -->
-                                               </extraPatterns>
-                                       </dateFormatLength >
-                                       <dateFormatLength type="long">
-                                               <extraPatterns>
-                                                       <pattern>yyyy'年'M'月'd'日'</pattern>
-                                                       <pattern>yyyy'年'MM'月'dd'日'</pattern>
-                                                       <pattern>yyyy'年'M'月'd'日' dddd</pattern>
-                                                       <pattern>yyyy'年'MM'月'dd'日' dddd</pattern>
-                                               </extraPatterns>
-                                       </dateFormatLength>
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat>
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                               <extraPatterns>
-                                                       <pattern>HH:mm:ss</pattern>
-                                                       <pattern>tt h:mm:ss</pattern>
-                                                       <pattern>tt hh:mm:ss</pattern>
-                                               </extraPatterns>
-                                       </timeFormatLength>
-                                       <timeFormatLength type="short">
-                                               <extraPatterns>
-                                                       <pattern>H:mm</pattern>
-                                                       <pattern>HH:mm</pattern>
-                                                       <pattern>tt h:mm</pattern>
-                                                       <pattern>tt hh:mm</pattern>
-                                               </extraPatterns>
-                                       </timeFormatLength>
-                               </timeFormats>
-                               <dateTimeFormats>
-                                       <dateTimeFormatLength >
-                                               <dateTimeFormat>
-                                                       <pattern>{1} {0}</pattern>
-                                               </dateTimeFormat>
-                                       </dateTimeFormatLength >
-                               </dateTimeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
diff --git a/tools/locale-builder/supp/ka_GE.xml b/tools/locale-builder/supp/ka_GE.xml
deleted file mode 100644 (file)
index 185bafd..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat>
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength>
-          <dateFormatLength type="long">
-            <dateFormat>
-              <pattern>yyyy 'წლის' dd MM, dddd</pattern>
-            </dateFormat>
-          </dateFormatLength>
-                               </dateFormats>
-                               <timeFormats>
-          <timeFormatLength type="short">
-            <timeFormat>
-              <pattern>H:mm</pattern>
-            </timeFormat>
-          </timeFormatLength >
-                                       <timeFormatLength type="long">
-                                               <timeFormat>
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
diff --git a/tools/locale-builder/supp/ko_KR.xml b/tools/locale-builder/supp/ko_KR.xml
deleted file mode 100755 (executable)
index 6c511c2..0000000
+++ /dev/null
@@ -1,87 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <currencyFormats>
-                       <currencyFormatLength >
-                               <currencyFormat >
-                                       <pattern>#,##0;-#,##0</pattern>
-                               </currencyFormat>
-                       </currencyFormatLength >
-               </currencyFormats>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>#,##0 %</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-       </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy/MM/dd</pattern>
-                                               </dateFormat>
-                                               <extraPatterns>
-                                                       <pattern>yyyy/MM/dd</pattern>
-                                                       <pattern>yy/MM/dd</pattern>
-                                                       <pattern>yy/M/d</pattern>
-                                                       <pattern>yyyy/M/d</pattern>
-                                                       <pattern>yyyy. MM. dd</pattern>
-                                                       <pattern>yy. MM. dd</pattern>
-                                                       <!-- we should not need yyyy-MM-dd that should be covered by yyyy/MM/dd -->
-                                               </extraPatterns>
-                                       </dateFormatLength >
-                                       <dateFormatLength type="long">
-                                               <dateFormat >
-                                                       <pattern>yyyy'년' M'월' d'일'</pattern>
-                                               </dateFormat>
-                                               <extraPatterns>
-                                                       <pattern>yyyy'년' M'월' d'일'</pattern>
-                                                       <pattern>yyyy'년' MM'월' dd'일'</pattern>
-                                                       <pattern>yy'년' M'월' d'일'</pattern>
-                                                       <pattern>yy'년' MM'월' dd'일'</pattern>
-                                               </extraPatterns>
-                                       </dateFormatLength>
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>tt h'시' mm'분' ss'초'</pattern>
-                                               </timeFormat>
-                                               <extraPatterns>
-                                                       <pattern>tt h'시' mm'분' ss'초'</pattern>
-                                                       <pattern>H'시' m'분' ss'초'</pattern>
-                                                       <pattern>HH'시' mm'분' ss'초'</pattern>
-                                                       <pattern>H:mm:ss</pattern>
-                                                       <pattern>HH:mm:ss</pattern>
-                                                       <pattern>tt h'시' m'분' ss'초'</pattern>
-                                                       <pattern>tt hh'시' mm'분' ss'초'</pattern>
-                                                       <pattern>tt h:mm:ss</pattern>
-                                                       <pattern>tt hh:mm:ss</pattern>
-                                               </extraPatterns>
-                                       </timeFormatLength>
-                                       <timeFormatLength type="short">
-                                               <timeFormat >
-                                                       <pattern>tt h:mm</pattern>
-                                               </timeFormat>
-                                               <extraPatterns>
-                                                       <pattern>H:mm</pattern>
-                                                       <pattern>HH:mm</pattern>
-                                                       <pattern>H'시' m'분'</pattern>
-                                                       <pattern>H'시' mm'분'</pattern>
-                                                       <pattern>HH'시' mm'분'</pattern>
-                                                       <pattern>tt h:mm</pattern>
-                                                       <pattern>tt hh:mm</pattern>
-                                                       <pattern>tt h'시' m'분'</pattern>
-                                                       <pattern>tt h'시' mm'분'</pattern>
-                                                       <pattern>tt hh'시' mm'분'</pattern>
-                                               </extraPatterns>
-                                       </timeFormatLength>
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
diff --git a/tools/locale-builder/supp/lt_LT.xml b/tools/locale-builder/supp/lt_LT.xml
deleted file mode 100755 (executable)
index fe44ebf..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <decimalFormats>
-                       <decimalFormatLength >
-                               <decimalFormat >
-                                       <pattern>#,##0.###;-#,##0.###</pattern>
-                               </decimalFormat>
-                       </decimalFormatLength >
-               </decimalFormats>
-       </numbers>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy.MM.dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/lv.xml b/tools/locale-builder/supp/lv.xml
deleted file mode 100755 (executable)
index 48fd017..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy.MM.dd.</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/mk.xml b/tools/locale-builder/supp/mk.xml
deleted file mode 100755 (executable)
index 4a7f338..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/nl_BE.xml b/tools/locale-builder/supp/nl_BE.xml
deleted file mode 100755 (executable)
index aba4a99..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-       <numbers>
-               <currencyFormats>
-                       <currencyFormatLength >
-                               <currencyFormat >
-                                       <pattern>¤ #,##0.00;¤ -#,##0.00</pattern>
-                               </currencyFormat>
-                       </currencyFormatLength >
-               </currencyFormats>
-       </numbers>
-</ldml>
diff --git a/tools/locale-builder/supp/nl_NL.xml b/tools/locale-builder/supp/nl_NL.xml
deleted file mode 100755 (executable)
index 66bb661..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <percentFormats>
-                       <percentFormatLength >
-                               <percentFormat >
-                                       <pattern>#,##0 %</pattern>
-                               </percentFormat>
-                       </percentFormatLength >
-               </percentFormats>
-       </numbers>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d-M-yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/pl.xml b/tools/locale-builder/supp/pl.xml
deleted file mode 100755 (executable)
index 65e7964..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <identity>
-               <version number="2.0"/>
-               <generation date="2003-12-19" />
-               <language type="pl" /> 
-       </identity>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy-MM-dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
diff --git a/tools/locale-builder/supp/pt.xml b/tools/locale-builder/supp/pt.xml
deleted file mode 100755 (executable)
index c424d37..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-  <numbers>
-    <currencies>
-      <currency type="BRL">
-        <displayName>Real Brasileiro</displayName>
-        <symbol>R$ </symbol>
-      </currency>
-    </currencies>
-  </numbers>
-</ldml>
-
diff --git a/tools/locale-builder/supp/pt_BR.xml b/tools/locale-builder/supp/pt_BR.xml
deleted file mode 100755 (executable)
index f064212..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <numbers>
-               <currencyFormats>
-                       <currencyFormatLength >
-                               <currencyFormat >
-                                       <pattern>#,##0.00;(#,##0.00)</pattern>
-                               </currencyFormat>
-                       </currencyFormatLength >
-               </currencyFormats>
-       </numbers>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d/M/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/pt_PT.xml b/tools/locale-builder/supp/pt_PT.xml
deleted file mode 100755 (executable)
index 7f111e7..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd-MM-yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/ro.xml b/tools/locale-builder/supp/ro.xml
deleted file mode 100755 (executable)
index 4a7f338..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/root.xml b/tools/locale-builder/supp/root.xml
deleted file mode 100644 (file)
index 664e75f..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-
-<ldml>
-  <dates>
-    <symbols>
-      <dateSeparator>/</dateSeparator>
-      <timeSeparator>:</timeSeparator>
-    </symbols>
-  </dates>
-  <numbers>
-    <symbols>
-      <nan>NaN</nan>
-      <infinity>Infinity</infinity>
-    </symbols>
-  </numbers>
-</ldml>
-
diff --git a/tools/locale-builder/supp/ru.xml b/tools/locale-builder/supp/ru.xml
deleted file mode 100755 (executable)
index c907904..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/sk.xml b/tools/locale-builder/supp/sk.xml
deleted file mode 100755 (executable)
index 6709138..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>. </dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d. M. yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/sl.xml b/tools/locale-builder/supp/sl.xml
deleted file mode 100755 (executable)
index 66e3996..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d.M.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/sq.xml b/tools/locale-builder/supp/sq.xml
deleted file mode 100755 (executable)
index f1cdca8..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy-MM-dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss.tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/sv_FI.xml b/tools/locale-builder/supp/sv_FI.xml
deleted file mode 100755 (executable)
index 23f637e..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d.M.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/sv_SE.xml b/tools/locale-builder/supp/sv_SE.xml
deleted file mode 100755 (executable)
index 9db987e..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>-</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>yyyy-MM-dd</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                                       <timeFormatLength type="medium">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                                       <timeFormatLength type="short">
-                                               <timeFormat >
-                                                       <pattern>HH:mm</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/sw_KE.xml b/tools/locale-builder/supp/sw_KE.xml
deleted file mode 100755 (executable)
index f1937e1..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>M/d/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h.mm.ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/th.xml b/tools/locale-builder/supp/th.xml
deleted file mode 100644 (file)
index c8a5cf9..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE ldml SYSTEM "        http://www.openi18n.org/spec/ldml/1.0/ldml.dtd" 
-[
-      <!ENTITY % icu SYSTEM "  http://www.openi18n.org/spec/ldml/1.0/ldmlICU.dtd"> 
-%icu;
-]
->
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar_type type="ThaiBuddhistCalendar" />
-                       <calendar type="ThaiBuddhistCalendar">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>d/M/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
-
diff --git a/tools/locale-builder/supp/tr.xml b/tools/locale-builder/supp/tr.xml
deleted file mode 100755 (executable)
index 4a7f338..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>HH:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/uk.xml b/tools/locale-builder/supp/uk.xml
deleted file mode 100755 (executable)
index c907904..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <symbols>
-                       <dateSeparator>.</dateSeparator>
-               </symbols>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd.MM.yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>H:mm:ss</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supp/vi.xml b/tools/locale-builder/supp/vi.xml
deleted file mode 100755 (executable)
index 5f96b53..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<ldml>
-       <dates>
-               <calendars>
-                       <calendar type="gregorian">
-                               <dateFormats>
-                                       <dateFormatLength type="short">
-                                               <dateFormat >
-                                                       <pattern>dd/MM/yyyy</pattern>
-                                               </dateFormat>
-                                       </dateFormatLength >
-                               </dateFormats>
-                               <timeFormats>
-                                       <timeFormatLength type="long">
-                                               <timeFormat >
-                                                       <pattern>h:mm:ss tt</pattern>
-                                               </timeFormat>
-                                       </timeFormatLength >
-                               </timeFormats>
-                       </calendar>
-               </calendars>
-       </dates>
-</ldml>
\ No newline at end of file
diff --git a/tools/locale-builder/supplementalData.xml b/tools/locale-builder/supplementalData.xml
deleted file mode 100644 (file)
index ca46207..0000000
+++ /dev/null
@@ -1,968 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE supplementalData SYSTEM "http://www.openi18n.org/spec/ldml/1.0/ldmlSupplemental.dtd" >
-<supplementalData>
-    <currencyData>
-        <fractions>
-            <info iso4217="ADP" digits="0"  />
-            <info iso4217="BHD" digits="3"  />
-            <info iso4217="BIF" digits="0"  />
-            <info iso4217="BYR" digits="0"  />
-            <info iso4217="CHF" digits="2" rounding="5" />
-            <info iso4217="CLF" digits="0"  />
-            <info iso4217="CLP" digits="0"  />
-            <info iso4217="DEFAULT" digits="2"  />
-            <info iso4217="DJF" digits="0"  />
-            <info iso4217="GNF" digits="0"  />
-            <info iso4217="IQD" digits="3"  />
-            <info iso4217="JOD" digits="3"  />
-            <info iso4217="JPY" digits="0"  />
-            <info iso4217="KMF" digits="0"  />
-            <info iso4217="KRW" digits="0"  />
-            <info iso4217="KWD" digits="3"  />
-            <info iso4217="LYD" digits="3"  />
-            <info iso4217="MGF" digits="0"  />
-            <info iso4217="OMR" digits="3"  />
-            <info iso4217="PYG" digits="0"  />
-            <info iso4217="RWF" digits="0"  />
-            <info iso4217="TND" digits="3"  />
-            <info iso4217="TRL" digits="0"  />
-            <info iso4217="TTD" digits="0"  />
-            <info iso4217="VUV" digits="0"  />
-            <info iso4217="XAF" digits="0"  />
-            <info iso4217="XOF" digits="0"  />
-            <info iso4217="XPF" digits="0"  />
-        </fractions>
-        <region iso3166="AE">
-            <currency iso4217="AED" >
-            </currency>
-        </region>
-        <region iso3166="AF">
-            <currency iso4217="AFN" >
-            </currency>
-        </region>
-        <region iso3166="AG">
-            <currency iso4217="XCD" >
-            </currency>
-        </region>
-        <region iso3166="AI">
-            <currency iso4217="XCD" >
-            </currency>
-        </region>
-        <region iso3166="AL">
-            <currency iso4217="ALL" >
-            </currency>
-        </region>
-        <region iso3166="AM">
-            <currency iso4217="AMD" >
-            </currency>
-        </region>
-        <region iso3166="AN">
-            <currency iso4217="ANG" >
-            </currency>
-        </region>
-        <region iso3166="AO">
-            <currency iso4217="AOA" >
-            </currency>
-        </region>
-        <region iso3166="AR">
-            <currency iso4217="ARS" >
-            </currency>
-        </region>
-        <region iso3166="AS">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="AT">
-            <currency iso4217="EUR" >
-                <alternate iso4217="ATS"/>
-            </currency>
-        </region>
-        <region iso3166="AU">
-            <currency iso4217="AUD" >
-            </currency>
-        </region>
-        <region iso3166="AW">
-            <currency iso4217="AWG" >
-            </currency>
-        </region>
-        <region iso3166="AZ">
-            <currency iso4217="AZM" >
-            </currency>
-        </region>
-        <region iso3166="BA">
-            <currency iso4217="BAM" >
-            </currency>
-        </region>
-        <region iso3166="BB">
-            <currency iso4217="BBD" >
-            </currency>
-        </region>
-        <region iso3166="BD">
-            <currency iso4217="BDT" >
-            </currency>
-        </region>
-        <region iso3166="BE">
-            <currency iso4217="EUR" >
-                <alternate iso4217="BEF"/>
-            </currency>
-        </region>
-        <region iso3166="BF">
-            <currency iso4217="XOF" >
-            </currency>
-        </region>
-        <region iso3166="BG">
-            <currency iso4217="BGN" >
-            </currency>
-        </region>
-        <region iso3166="BH">
-            <currency iso4217="BHD" >
-            </currency>
-        </region>
-        <region iso3166="BI">
-            <currency iso4217="BIF" >
-            </currency>
-        </region>
-        <region iso3166="BJ">
-            <currency iso4217="XOF" >
-            </currency>
-        </region>
-        <region iso3166="BM">
-            <currency iso4217="BMD" >
-            </currency>
-        </region>
-        <region iso3166="BN">
-            <currency iso4217="BND" >
-            </currency>
-        </region>
-        <region iso3166="BO">
-            <currency iso4217="BOB" >
-            </currency>
-        </region>
-        <region iso3166="BR">
-            <currency iso4217="BRL" >
-            </currency>
-        </region>
-        <region iso3166="BS">
-            <currency iso4217="BSD" >
-            </currency>
-        </region>
-        <region iso3166="BV">
-            <currency iso4217="NOK" >
-            </currency>
-        </region>
-        <region iso3166="BW">
-            <currency iso4217="BWP" >
-            </currency>
-        </region>
-        <region iso3166="BY">
-            <currency iso4217="BYR" >
-            </currency>
-        </region>
-        <region iso3166="BZ">
-            <currency iso4217="BZD" >
-            </currency>
-        </region>
-        <region iso3166="CA">
-            <currency iso4217="CAD" >
-            </currency>
-        </region>
-        <region iso3166="CC">
-            <currency iso4217="AUD" >
-            </currency>
-        </region>
-        <region iso3166="CD">
-            <currency iso4217="CDF" >
-            </currency>
-        </region>
-        <region iso3166="CF">
-            <currency iso4217="XAF" >
-            </currency>
-        </region>
-        <region iso3166="CG">
-            <currency iso4217="XAF" >
-            </currency>
-        </region>
-        <region iso3166="CH">
-            <currency iso4217="CHF" >
-            </currency>
-        </region>
-        <region iso3166="CI">
-            <currency iso4217="XOF" >
-            </currency>
-        </region>
-        <region iso3166="CK">
-            <currency iso4217="NZD" >
-            </currency>
-        </region>
-        <region iso3166="CL">
-            <currency iso4217="CLP" >
-            </currency>
-        </region>
-        <region iso3166="CM">
-            <currency iso4217="XAF" >
-            </currency>
-        </region>
-        <region iso3166="CN">
-            <currency iso4217="CNY" >
-            </currency>
-        </region>
-        <region iso3166="CO">
-            <currency iso4217="COP" >
-            </currency>
-        </region>
-        <region iso3166="CR">
-            <currency iso4217="CRC" >
-            </currency>
-        </region>
-        <region iso3166="CU">
-            <currency iso4217="CUP" >
-            </currency>
-        </region>
-        <region iso3166="CV">
-            <currency iso4217="CVE" >
-            </currency>
-        </region>
-        <region iso3166="CX">
-            <currency iso4217="AUD" >
-            </currency>
-        </region>
-        <region iso3166="CY">
-            <currency iso4217="CYP" >
-            </currency>
-        </region>
-        <region iso3166="CZ">
-            <currency iso4217="CZK" >
-            </currency>
-        </region>
-        <region iso3166="DE">
-            <currency iso4217="EUR" >
-                <alternate iso4217="DEM"/>
-            </currency>
-        </region>
-        <region iso3166="DJ">
-            <currency iso4217="DJF" >
-            </currency>
-        </region>
-        <region iso3166="DK">
-            <currency iso4217="DKK" >
-            </currency>
-        </region>
-        <region iso3166="DM">
-            <currency iso4217="XCD" >
-            </currency>
-        </region>
-        <region iso3166="DO">
-            <currency iso4217="DOP" >
-            </currency>
-        </region>
-        <region iso3166="DZ">
-            <currency iso4217="DZD" >
-            </currency>
-        </region>
-        <region iso3166="EC">
-            <currency iso4217="ECS" >
-            </currency>
-        </region>
-        <region iso3166="EE">
-            <currency iso4217="EEK" >
-            </currency>
-        </region>
-        <region iso3166="EG">
-            <currency iso4217="EGP" >
-            </currency>
-        </region>
-        <region iso3166="EH">
-            <currency iso4217="MAD" >
-            </currency>
-        </region>
-        <region iso3166="ER">
-            <currency iso4217="ERN" >
-            </currency>
-        </region>
-        <region iso3166="ES">
-            <currency iso4217="EUR" >
-                <alternate iso4217="ESP"/>
-            </currency>
-        </region>
-        <region iso3166="ET">
-            <currency iso4217="ETB" >
-            </currency>
-        </region>
-        <region iso3166="FI">
-            <currency iso4217="EUR" >
-                <alternate iso4217="FIM"/>
-            </currency>
-        </region>
-        <region iso3166="FJ">
-            <currency iso4217="FJD" >
-            </currency>
-        </region>
-        <region iso3166="FK">
-            <currency iso4217="FKP" >
-            </currency>
-        </region>
-        <region iso3166="FM">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="FO">
-            <currency iso4217="DKK" >
-            </currency>
-        </region>
-        <region iso3166="FR">
-            <currency iso4217="EUR" >
-                <alternate iso4217="FRF"/>
-            </currency>
-        </region>
-        <region iso3166="GA">
-            <currency iso4217="XAF" >
-            </currency>
-        </region>
-        <region iso3166="GB">
-            <currency iso4217="GBP" >
-            </currency>
-        </region>
-        <region iso3166="GD">
-            <currency iso4217="XCD" >
-            </currency>
-        </region>
-        <region iso3166="GE">
-            <currency iso4217="GEL" >
-            </currency>
-        </region>
-        <region iso3166="GF">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="GH">
-            <currency iso4217="GHC" >
-            </currency>
-        </region>
-        <region iso3166="GI">
-            <currency iso4217="GIP" >
-            </currency>
-        </region>
-        <region iso3166="GL">
-            <currency iso4217="DKK" >
-            </currency>
-        </region>
-        <region iso3166="GM">
-            <currency iso4217="GMD" >
-            </currency>
-        </region>
-        <region iso3166="GN">
-            <currency iso4217="GNF" >
-            </currency>
-        </region>
-        <region iso3166="GP">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="GQ">
-            <currency iso4217="XAF" >
-            </currency>
-        </region>
-        <region iso3166="GR">
-            <currency iso4217="EUR" >
-                <alternate iso4217="GRD"/>
-            </currency>
-        </region>
-        <region iso3166="GT">
-            <currency iso4217="GTQ" >
-            </currency>
-        </region>
-        <region iso3166="GU">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="GY">
-            <currency iso4217="GYD" >
-            </currency>
-        </region>
-        <region iso3166="HK">
-            <currency iso4217="HKD" >
-            </currency>
-        </region>
-        <region iso3166="HM">
-            <currency iso4217="AUD" >
-            </currency>
-        </region>
-        <region iso3166="HN">
-            <currency iso4217="HNL" >
-            </currency>
-        </region>
-        <region iso3166="HR">
-            <currency iso4217="HRK" >
-            </currency>
-        </region>
-        <region iso3166="HU">
-            <currency iso4217="HUF" >
-            </currency>
-        </region>
-        <region iso3166="ID">
-            <currency iso4217="IDR" >
-            </currency>
-        </region>
-        <region iso3166="IE">
-            <currency iso4217="EUR" >
-                <alternate iso4217="IEP"/>
-            </currency>
-        </region>
-        <region iso3166="IL">
-            <currency iso4217="ILS" >
-            </currency>
-        </region>
-        <region iso3166="IN">
-            <currency iso4217="INR" >
-            </currency>
-        </region>
-        <region iso3166="IO">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="IQ">
-            <currency iso4217="IQD" >
-            </currency>
-        </region>
-        <region iso3166="IR">
-            <currency iso4217="IRR" >
-            </currency>
-        </region>
-        <region iso3166="IS">
-            <currency iso4217="ISK" >
-            </currency>
-        </region>
-        <region iso3166="IT">
-            <currency iso4217="EUR" >
-                <alternate iso4217="ITL"/>
-            </currency>
-        </region>
-        <region iso3166="JM">
-            <currency iso4217="JMD" >
-            </currency>
-        </region>
-        <region iso3166="JO">
-            <currency iso4217="JOD" >
-            </currency>
-        </region>
-        <region iso3166="JP">
-            <currency iso4217="JPY" >
-            </currency>
-        </region>
-        <region iso3166="KE">
-            <currency iso4217="KES" >
-            </currency>
-        </region>
-        <region iso3166="KG">
-            <currency iso4217="KGS" >
-            </currency>
-        </region>
-        <region iso3166="KH">
-            <currency iso4217="KHR" >
-            </currency>
-        </region>
-        <region iso3166="KI">
-            <currency iso4217="AUD" >
-            </currency>
-        </region>
-        <region iso3166="KM">
-            <currency iso4217="KMF" >
-            </currency>
-        </region>
-        <region iso3166="KN">
-            <currency iso4217="XCD" >
-            </currency>
-        </region>
-        <region iso3166="KP">
-            <currency iso4217="KPW" >
-            </currency>
-        </region>
-        <region iso3166="KR">
-            <currency iso4217="KRW" >
-            </currency>
-        </region>
-        <region iso3166="KW">
-            <currency iso4217="KWD" >
-            </currency>
-        </region>
-        <region iso3166="KY">
-            <currency iso4217="KYD" >
-            </currency>
-        </region>
-        <region iso3166="KZ">
-            <currency iso4217="KZT" >
-            </currency>
-        </region>
-        <region iso3166="LA">
-            <currency iso4217="LAK" >
-            </currency>
-        </region>
-        <region iso3166="LB">
-            <currency iso4217="LBP" >
-            </currency>
-        </region>
-        <region iso3166="LC">
-            <currency iso4217="XCD" >
-            </currency>
-        </region>
-        <region iso3166="LI">
-            <currency iso4217="CHF" >
-            </currency>
-        </region>
-        <region iso3166="LK">
-            <currency iso4217="LKR" >
-            </currency>
-        </region>
-        <region iso3166="LR">
-            <currency iso4217="LRD" >
-            </currency>
-        </region>
-        <region iso3166="LT">
-            <currency iso4217="LTL" >
-            </currency>
-        </region>
-        <region iso3166="LU">
-            <currency iso4217="EUR" >
-                <alternate iso4217="LUF"/>
-            </currency>
-        </region>
-        <region iso3166="LV">
-            <currency iso4217="LVL" >
-            </currency>
-        </region>
-        <region iso3166="LY">
-            <currency iso4217="LYD" >
-            </currency>
-        </region>
-        <region iso3166="MA">
-            <currency iso4217="MAD" >
-            </currency>
-        </region>
-        <region iso3166="MC">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="MD">
-            <currency iso4217="MDL" >
-            </currency>
-        </region>
-        <region iso3166="MG">
-            <currency iso4217="MGF" >
-            </currency>
-        </region>
-        <region iso3166="MH">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="MK">
-            <currency iso4217="MKD" >
-            </currency>
-        </region>
-        <region iso3166="ML">
-            <currency iso4217="XOF" >
-            </currency>
-        </region>
-        <region iso3166="MM">
-            <currency iso4217="MMK" >
-            </currency>
-        </region>
-        <region iso3166="MN">
-            <currency iso4217="MNT" >
-            </currency>
-        </region>
-        <region iso3166="MO">
-            <currency iso4217="MOP" >
-            </currency>
-        </region>
-        <region iso3166="MP">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="MQ">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="MR">
-            <currency iso4217="MRO" >
-            </currency>
-        </region>
-        <region iso3166="MS">
-            <currency iso4217="XCD" >
-            </currency>
-        </region>
-        <region iso3166="MT">
-            <currency iso4217="MTL" >
-            </currency>
-        </region>
-        <region iso3166="MU">
-            <currency iso4217="MUR" >
-            </currency>
-        </region>
-        <region iso3166="MV">
-            <currency iso4217="MVR" >
-            </currency>
-        </region>
-        <region iso3166="MW">
-            <currency iso4217="MWK" >
-            </currency>
-        </region>
-        <region iso3166="MX">
-            <currency iso4217="MXN" >
-            </currency>
-        </region>
-        <region iso3166="MY">
-            <currency iso4217="MYR" >
-            </currency>
-        </region>
-        <region iso3166="MZ">
-            <currency iso4217="MZM" >
-            </currency>
-        </region>
-        <region iso3166="NC">
-            <currency iso4217="XPF" >
-            </currency>
-        </region>
-        <region iso3166="NE">
-            <currency iso4217="XOF" >
-            </currency>
-        </region>
-        <region iso3166="NF">
-            <currency iso4217="AUD" >
-            </currency>
-        </region>
-        <region iso3166="NG">
-            <currency iso4217="NGN" >
-            </currency>
-        </region>
-        <region iso3166="NI">
-            <currency iso4217="NIO" >
-            </currency>
-        </region>
-        <region iso3166="NL">
-            <currency iso4217="EUR" >
-                <alternate iso4217="NLG"/>
-            </currency>
-        </region>
-        <region iso3166="NO">
-            <currency iso4217="NOK" >
-            </currency>
-        </region>
-        <region iso3166="NP">
-            <currency iso4217="NPR" >
-            </currency>
-        </region>
-        <region iso3166="NR">
-            <currency iso4217="AUD" >
-            </currency>
-        </region>
-        <region iso3166="NU">
-            <currency iso4217="NZD" >
-            </currency>
-        </region>
-        <region iso3166="NZ">
-            <currency iso4217="NZD" >
-            </currency>
-        </region>
-        <region iso3166="OM">
-            <currency iso4217="OMR" >
-            </currency>
-        </region>
-        <region iso3166="PA">
-            <currency iso4217="PAB" >
-            </currency>
-        </region>
-        <region iso3166="PE">
-            <currency iso4217="PEN" >
-            </currency>
-        </region>
-        <region iso3166="PF">
-            <currency iso4217="XPF" >
-            </currency>
-        </region>
-        <region iso3166="PG">
-            <currency iso4217="PGK" >
-            </currency>
-        </region>
-        <region iso3166="PH">
-            <currency iso4217="PHP" >
-            </currency>
-        </region>
-        <region iso3166="PK">
-            <currency iso4217="PKR" >
-            </currency>
-        </region>
-        <region iso3166="PL">
-            <currency iso4217="PLN" >
-            </currency>
-        </region>
-        <region iso3166="PM">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="PN">
-            <currency iso4217="NZD" >
-            </currency>
-        </region>
-        <region iso3166="PR">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="PT">
-            <currency iso4217="EUR" >
-                <alternate iso4217="PTE"/>
-            </currency>
-        </region>
-        <region iso3166="PW">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="PY">
-            <currency iso4217="PYG" >
-            </currency>
-        </region>
-        <region iso3166="QA">
-            <currency iso4217="QAR" >
-            </currency>
-        </region>
-        <region iso3166="RE">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="RO">
-            <currency iso4217="ROL" >
-            </currency>
-        </region>
-        <region iso3166="RU">
-            <currency iso4217="RUR" >
-            </currency>
-        </region>
-        <region iso3166="RW">
-            <currency iso4217="RWF" >
-            </currency>
-        </region>
-        <region iso3166="SA">
-            <currency iso4217="SAR" >
-            </currency>
-        </region>
-        <region iso3166="SB">
-            <currency iso4217="SBD" >
-            </currency>
-        </region>
-        <region iso3166="SC">
-            <currency iso4217="SCR" >
-            </currency>
-        </region>
-        <region iso3166="SD">
-            <currency iso4217="SDD" >
-            </currency>
-        </region>
-        <region iso3166="SE">
-            <currency iso4217="SEK" >
-            </currency>
-        </region>
-        <region iso3166="SG">
-            <currency iso4217="SGD" >
-            </currency>
-        </region>
-        <region iso3166="SH">
-            <currency iso4217="SHP" >
-            </currency>
-        </region>
-        <region iso3166="SI">
-            <currency iso4217="SIT" >
-            </currency>
-        </region>
-        <region iso3166="SJ">
-            <currency iso4217="NOK" >
-            </currency>
-        </region>
-        <region iso3166="SK">
-            <currency iso4217="SKK" >
-            </currency>
-        </region>
-        <region iso3166="SL">
-            <currency iso4217="SLL" >
-            </currency>
-        </region>
-        <region iso3166="SM">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="SN">
-            <currency iso4217="XOF" >
-            </currency>
-        </region>
-        <region iso3166="SO">
-            <currency iso4217="SOS" >
-            </currency>
-        </region>
-        <region iso3166="SR">
-            <currency iso4217="SRG" >
-            </currency>
-        </region>
-        <region iso3166="ST">
-            <currency iso4217="STD" >
-            </currency>
-        </region>
-        <region iso3166="SV">
-            <currency iso4217="SVC" >
-            </currency>
-        </region>
-        <region iso3166="SY">
-            <currency iso4217="SYP" >
-            </currency>
-        </region>
-        <region iso3166="SZ">
-            <currency iso4217="SZL" >
-            </currency>
-        </region>
-        <region iso3166="TC">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="TD">
-            <currency iso4217="XAF" >
-            </currency>
-        </region>
-        <region iso3166="TF">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="TG">
-            <currency iso4217="XOF" >
-            </currency>
-        </region>
-        <region iso3166="TH">
-            <currency iso4217="THB" >
-            </currency>
-        </region>
-        <region iso3166="TJ">
-            <currency iso4217="TJS" >
-            </currency>
-        </region>
-        <region iso3166="TK">
-            <currency iso4217="NZD" >
-            </currency>
-        </region>
-        <region iso3166="TL">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="TM">
-            <currency iso4217="TMM" >
-            </currency>
-        </region>
-        <region iso3166="TN">
-            <currency iso4217="TND" >
-            </currency>
-        </region>
-        <region iso3166="TO">
-            <currency iso4217="TOP" >
-            </currency>
-        </region>
-        <region iso3166="TR">
-            <currency iso4217="TRL" >
-            </currency>
-        </region>
-        <region iso3166="TT">
-            <currency iso4217="TTD" >
-            </currency>
-        </region>
-        <region iso3166="TV">
-            <currency iso4217="AUD" >
-            </currency>
-        </region>
-        <region iso3166="TW">
-            <currency iso4217="TWD" >
-            </currency>
-        </region>
-        <region iso3166="TZ">
-            <currency iso4217="TZS" >
-            </currency>
-        </region>
-        <region iso3166="UA">
-            <currency iso4217="UAH" >
-            </currency>
-        </region>
-        <region iso3166="UG">
-            <currency iso4217="UGX" >
-            </currency>
-        </region>
-        <region iso3166="UM">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="US">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="UY">
-            <currency iso4217="UYU" >
-            </currency>
-        </region>
-        <region iso3166="UZ">
-            <currency iso4217="UZS" >
-            </currency>
-        </region>
-        <region iso3166="VA">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="VC">
-            <currency iso4217="XCD" >
-            </currency>
-        </region>
-        <region iso3166="VE">
-            <currency iso4217="VEB" >
-            </currency>
-        </region>
-        <region iso3166="VG">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="VI">
-            <currency iso4217="USD" >
-            </currency>
-        </region>
-        <region iso3166="VN">
-            <currency iso4217="VND" >
-            </currency>
-        </region>
-        <region iso3166="VU">
-            <currency iso4217="VUV" >
-            </currency>
-        </region>
-        <region iso3166="WF">
-            <currency iso4217="XPF" >
-            </currency>
-        </region>
-        <region iso3166="WS">
-            <currency iso4217="WST" >
-            </currency>
-        </region>
-        <region iso3166="YE">
-            <currency iso4217="YER" >
-            </currency>
-        </region>
-        <region iso3166="YT">
-            <currency iso4217="EUR" >
-            </currency>
-        </region>
-        <region iso3166="YU">
-            <currency iso4217="YUM" >
-            </currency>
-        </region>
-        <region iso3166="ZA">
-            <currency iso4217="ZAR" >
-            </currency>
-        </region>
-        <region iso3166="ZM">
-            <currency iso4217="ZMK" >
-            </currency>
-        </region>
-        <region iso3166="ZW">
-            <currency iso4217="ZWD" >
-            </currency>
-        </region>
-    </currencyData>
-</supplementalData>
diff --git a/tools/locale-builder/tests/test-culture.cs b/tools/locale-builder/tests/test-culture.cs
new file mode 100644 (file)
index 0000000..7979095
--- /dev/null
@@ -0,0 +1,139 @@
+using System;
+using System.IO;
+using System.Linq;
+using System.Globalization;
+using System.Text;
+using System.Collections.Generic;
+
+class TestCulture
+{
+       public static void Main ()
+       {
+               var all = CultureInfo.GetCultures (CultureTypes.SpecificCultures | CultureTypes.NeutralCultures).OrderBy (l => l.LCID);
+
+               Console.OutputEncoding = Encoding.UTF8;
+               var writer = Console.Out;
+       
+               foreach (var c in all) {
+                       if (c.LCID == CultureInfo.InvariantCulture.LCID)
+                               continue;
+
+                       writer.WriteLine ("Name: {0}, LCID 0x{1}", c.Name , c.LCID.ToString ("X4"));
+
+                       writer.WriteLine ("{0}: {1}", "DisplayName", c.DisplayName);
+                       writer.WriteLine ("{0}: {1}", "EnglishName", c.EnglishName);
+                       writer.WriteLine ("{0}: {1}", "NativeName", c.NativeName);
+                       // writer.WriteLine ("{0}: {1}", "OptionalCalendars", c.OptionalCalendars);
+                       writer.WriteLine ("{0}: {1}", "ThreeLetterISOLanguageName", c.ThreeLetterISOLanguageName);
+                       writer.WriteLine ("{0}: {1}", "ThreeLetterWindowsLanguageName", c.ThreeLetterWindowsLanguageName);
+                       writer.WriteLine ("{0}: {1}", "TwoLetterISOLanguageName", c.TwoLetterISOLanguageName);
+                       writer.WriteLine ("{0}: {1}", "Calendar", c.Calendar.GetType ());
+
+                       var df = c.DateTimeFormat;
+                       writer.WriteLine ("-- DateTimeFormat --");
+                       Dump (writer, df.AbbreviatedDayNames, "AbbreviatedDayNames");
+                       Dump (writer, df.AbbreviatedMonthGenitiveNames, "AbbreviatedMonthGenitiveNames");
+                       Dump (writer, df.AbbreviatedMonthNames, "AbbreviatedMonthNames");
+                       writer.WriteLine ("{0}: {1}", "AMDesignator", df.AMDesignator);
+                       writer.WriteLine ("{0}: {1}", "CalendarWeekRule", df.CalendarWeekRule);
+                       writer.WriteLine ("{0}: {1}", "DateSeparator", df.DateSeparator);
+                       Dump (writer, df.DayNames, "DayNames");
+                       writer.WriteLine ("{0}: {1}", "FirstDayOfWeek", df.FirstDayOfWeek);
+                       Dump (writer, df.GetAllDateTimePatterns (), "GetAllDateTimePatterns");
+                       // df.GetAbbreviatedEraName
+                       // df.GetEra
+                       // df.GetEraName
+                       writer.WriteLine ("{0}: {1}", "LongDatePattern", df.LongDatePattern);
+                       writer.WriteLine ("{0}: {1}", "LongTimePattern", df.LongTimePattern);
+                       writer.WriteLine ("{0}: {1}", "MonthDayPattern", df.MonthDayPattern);
+                       Dump (writer, df.MonthGenitiveNames, "MonthGenitiveNames");
+                       Dump (writer, df.MonthNames, "MonthNames");
+                       writer.WriteLine ("{0}: {1}", "NativeCalendarName", df.NativeCalendarName);
+                       writer.WriteLine ("{0}: {1}", "PMDesignator", df.PMDesignator);
+                       writer.WriteLine ("{0}: {1}", "ShortDatePattern", df.ShortDatePattern);
+                       Dump (writer, df.ShortestDayNames, "ShortestDayNames");
+                       writer.WriteLine ("{0}: {1}", "ShortTimePattern", df.ShortTimePattern);
+                       writer.WriteLine ("{0}: {1}", "TimeSeparator", df.TimeSeparator);
+                       writer.WriteLine ("{0}: {1}", "YearMonthPattern", df.YearMonthPattern);
+
+                       var ti = c.TextInfo;
+                       writer.WriteLine ("-- TextInfo --");
+                       writer.WriteLine ("{0}: {1}", "ANSICodePage", ti.ANSICodePage);
+                       writer.WriteLine ("{0}: {1}", "EBCDICCodePage", ti.EBCDICCodePage);
+                       writer.WriteLine ("{0}: {1}", "IsRightToLeft", ti.IsRightToLeft);
+                       writer.WriteLine ("{0}: {1}", "ListSeparator", ti.ListSeparator);
+                       writer.WriteLine ("{0}: {1}", "MacCodePage", ti.MacCodePage);
+                       writer.WriteLine ("{0}: {1}", "OEMCodePage", ti.OEMCodePage);
+
+                       var nf = c.NumberFormat;
+                       writer.WriteLine ("-- NumberFormat --");
+                       writer.WriteLine ("{0}: {1}", "CurrencyDecimalDigits", nf.CurrencyDecimalDigits);
+                       writer.WriteLine ("{0}: {1}", "CurrencyDecimalSeparator", nf.CurrencyDecimalSeparator);
+                       writer.WriteLine ("{0}: {1}", "CurrencyGroupSeparator", nf.CurrencyGroupSeparator);
+                       Dump (writer, nf.CurrencyGroupSizes, "CurrencyGroupSizes");
+                       writer.WriteLine ("{0}: {1}", "CurrencyNegativePattern", nf.CurrencyNegativePattern);
+                       writer.WriteLine ("{0}: {1}", "CurrencyPositivePattern", nf.CurrencyPositivePattern);
+                       writer.WriteLine ("{0}: {1}", "CurrencySymbol", nf.CurrencySymbol);
+                       writer.WriteLine ("{0}: {1}", "DigitSubstitution", nf.DigitSubstitution);
+                       writer.WriteLine ("{0}: {1}", "NaNSymbol", nf.NaNSymbol);
+                       Dump (writer, nf.NativeDigits, "NativeDigits");
+                       writer.WriteLine ("{0}: {1}", "NegativeInfinitySymbol", nf.NegativeInfinitySymbol);
+                       writer.WriteLine ("{0}: {1}", "NegativeSign", nf.NegativeSign);
+                       writer.WriteLine ("{0}: {1}", "NumberDecimalDigits", nf.NumberDecimalDigits);
+                       writer.WriteLine ("{0}: {1}", "NumberDecimalSeparator", nf.NumberDecimalSeparator);
+                       writer.WriteLine ("{0}: {1}", "NumberGroupSeparator", nf.NumberGroupSeparator);
+                       Dump (writer, nf.NumberGroupSizes, "NumberGroupSizes");
+                       writer.WriteLine ("{0}: {1}", "NumberNegativePattern", nf.NumberNegativePattern);
+                       writer.WriteLine ("{0}: {1}", "PercentDecimalDigits", nf.PercentDecimalDigits);
+                       writer.WriteLine ("{0}: {1}", "PercentDecimalSeparator", nf.PercentDecimalSeparator);
+                       writer.WriteLine ("{0}: {1}", "PercentGroupSeparator", nf.PercentGroupSeparator);
+                       Dump (writer, nf.PercentGroupSizes, "PercentGroupSizes");
+                       writer.WriteLine ("{0}: {1}", "PercentNegativePattern", nf.PercentNegativePattern);
+                       writer.WriteLine ("{0}: {1}", "PercentPositivePattern", nf.PercentPositivePattern);
+                       writer.WriteLine ("{0}: {1}", "PercentSymbol", nf.PercentSymbol);
+                       writer.WriteLine ("{0}: {1}", "PerMilleSymbol", nf.PerMilleSymbol);
+                       writer.WriteLine ("{0}: {1}", "PositiveInfinitySymbol", nf.PositiveInfinitySymbol);
+                       writer.WriteLine ("{0}: {1}", "PositiveSign", nf.PositiveSign);
+
+                       if (!c.IsNeutralCulture) {
+                               var ri = new RegionInfo (c.LCID);
+                               writer.WriteLine ("-- RegionInfo --");
+                               writer.WriteLine ("{0}: {1}", "CurrencyEnglishName", ri.CurrencyEnglishName);
+                               writer.WriteLine ("{0}: {1}", "CurrencyNativeName", ri.CurrencyNativeName);
+                               writer.WriteLine ("{0}: {1}", "CurrencySymbol", ri.CurrencySymbol);
+                               writer.WriteLine ("{0}: {1}", "DisplayName", ri.DisplayName);
+                               writer.WriteLine ("{0}: {1}", "EnglishName", ri.EnglishName);
+                               writer.WriteLine ("{0}: {1}", "GeoId", ri.GeoId);
+                               writer.WriteLine ("{0}: {1}", "IsMetric", ri.IsMetric);
+                               writer.WriteLine ("{0}: {1}", "ISOCurrencySymbol", ri.ISOCurrencySymbol);
+                               writer.WriteLine ("{0}: {1}", "Name", ri.Name);
+                               writer.WriteLine ("{0}: {1}", "NativeName", ri.NativeName);
+                               writer.WriteLine ("{0}: {1}", "ThreeLetterISORegionName", ri.ThreeLetterISORegionName);
+                               writer.WriteLine ("{0}: {1}", "ThreeLetterWindowsRegionName", ri.ThreeLetterWindowsRegionName);
+                               writer.WriteLine ("{0}: {1}", "TwoLetterISORegionName", ri.TwoLetterISORegionName);
+                       }
+
+                       CompareInfo ci = CompareInfo.GetCompareInfo (c.LCID);
+                       writer.WriteLine ("-- CompareInfo --");
+                       writer.WriteLine ("{0}: {1}", "Name", ci.Name);
+                       //writer.WriteLine ("{0}: {1}", "Version", ci.Version);
+
+                       writer.WriteLine ();
+               }
+       }
+
+       static void Dump<T> (TextWriter tw, T[] values, string name)
+       {
+               tw.Write (name);
+               tw.Write (": ");
+
+               for (int i = 0; i < values.Length; ++i) {
+                       if (i > 0)
+                               tw.Write (", ");
+
+                       tw.Write (values[i]);
+               }
+
+               tw.WriteLine ();
+       }
+}
diff --git a/tools/locale-builder/textinfo.xml b/tools/locale-builder/textinfo.xml
deleted file mode 100644 (file)
index e4333bb..0000000
+++ /dev/null
@@ -1,205 +0,0 @@
-<textinfos>
-       <textinfo lcid='1' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='1025' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='2049' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='3073' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='4097' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='5121' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='6145' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='7169' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='8193' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='9217' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='10241' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='11265' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='12289' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='13313' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='14337' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='15361' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='16385' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='2' ansi='1251' ebcdic='20420' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='1026' ansi='1251' ebcdic='20420' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='3' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1027' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='4' ansi='936' ebcdic='500' mac='10008' oem='936' listsep=',' />
-       <textinfo lcid='1028' ansi='950' ebcdic='500' mac='10002' oem='950' listsep=',' />
-       <textinfo lcid='2052' ansi='936' ebcdic='500' mac='10008' oem='936' listsep=',' />
-       <textinfo lcid='3076' ansi='950' ebcdic='500' mac='10002' oem='950' listsep=',' />
-       <textinfo lcid='4100' ansi='936' ebcdic='500' mac='10008' oem='936' listsep=',' />
-       <textinfo lcid='5124' ansi='950' ebcdic='500' mac='10002' oem='950' listsep=',' />
-       <textinfo lcid='31748' ansi='950' ebcdic='500' mac='10002' oem='950' listsep=',' />
-       <textinfo lcid='5' ansi='1250' ebcdic='500' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='1029' ansi='1250' ebcdic='500' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='6' ansi='1252' ebcdic='20277' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1030' ansi='1252' ebcdic='20277' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='7' ansi='1252' ebcdic='20273' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1031' ansi='1252' ebcdic='20273' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='2055' ansi='1252' ebcdic='20273' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='3079' ansi='1252' ebcdic='20273' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='4103' ansi='1252' ebcdic='20273' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='5127' ansi='1252' ebcdic='20273' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='8' ansi='1253' ebcdic='20273' mac='10006' oem='737' listsep=';' />
-       <textinfo lcid='1032' ansi='1253' ebcdic='20273' mac='10006' oem='737' listsep=';' />
-       <textinfo lcid='9' ansi='1252' ebcdic='37' mac='10000' oem='437' listsep=',' />
-       <textinfo lcid='1033' ansi='1252' ebcdic='37' mac='10000' oem='437' listsep=',' />
-       <textinfo lcid='2057' ansi='1252' ebcdic='20285' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='3081' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='4105' ansi='1252' ebcdic='37' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='5129' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='6153' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='7177' ansi='1252' ebcdic='500' mac='10000' oem='437' listsep=',' />
-       <textinfo lcid='8201' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='9225' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='10249' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='11273' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='12297' ansi='1252' ebcdic='500' mac='10000' oem='437' listsep=',' />
-       <textinfo lcid='13321' ansi='1252' ebcdic='500' mac='10000' oem='437' listsep=',' />
-       <textinfo lcid='10' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='2058' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='3082' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='4106' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='5130' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='6154' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='7178' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='8202' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='9226' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='10250' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='11274' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='12298' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='13322' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='14346' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='15370' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='16394' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='17418' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='18442' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='19466' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='20490' ansi='1252' ebcdic='20284' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='11' ansi='1252' ebcdic='20278' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1035' ansi='1252' ebcdic='20278' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='12' ansi='1252' ebcdic='20297' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1036' ansi='1252' ebcdic='20297' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='2060' ansi='1252' ebcdic='20297' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='3084' ansi='1252' ebcdic='20297' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='4108' ansi='1252' ebcdic='20297' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='5132' ansi='1252' ebcdic='20297' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='6156' ansi='1252' ebcdic='20297' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='13' ansi='1255' ebcdic='500' mac='10005' oem='862' listsep=',' />
-       <textinfo lcid='1037' ansi='1255' ebcdic='500' mac='10005' oem='862' listsep=',' />
-       <textinfo lcid='14' ansi='1250' ebcdic='500' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='1038' ansi='1250' ebcdic='500' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='15' ansi='1252' ebcdic='20871' mac='10079' oem='850' listsep=';' />
-       <textinfo lcid='1039' ansi='1252' ebcdic='20871' mac='10079' oem='850' listsep=';' />
-       <textinfo lcid='16' ansi='1252' ebcdic='20280' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1040' ansi='1252' ebcdic='20280' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='2064' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='17' ansi='932' ebcdic='20290' mac='10001' oem='932' listsep=',' />
-       <textinfo lcid='1041' ansi='932' ebcdic='20290' mac='10001' oem='932' listsep=',' />
-       <textinfo lcid='18' ansi='949' ebcdic='20833' mac='10003' oem='949' listsep=',' />
-       <textinfo lcid='1042' ansi='949' ebcdic='20833' mac='10003' oem='949' listsep=',' />
-       <textinfo lcid='19' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1043' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='2067' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='20' ansi='1252' ebcdic='20277' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1044' ansi='1252' ebcdic='20277' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='2068' ansi='1252' ebcdic='20277' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='21' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='1045' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='22' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1046' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='2070' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='24' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='1048' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='25' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='1049' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='26' ansi='1250' ebcdic='500' mac='10082' oem='852' listsep=';' />
-       <textinfo lcid='1050' ansi='1250' ebcdic='500' mac='10082' oem='852' listsep=';' />
-       <textinfo lcid='2074' ansi='1250' ebcdic='500' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='3098' ansi='1251' ebcdic='21025' mac='10007' oem='855' listsep=';' />
-       <textinfo lcid='27' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='1051' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='28' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='1052' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='29' ansi='1252' ebcdic='20278' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1053' ansi='1252' ebcdic='20278' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='2077' ansi='1252' ebcdic='20278' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='30' ansi='874' ebcdic='20838' mac='10021' oem='874' listsep=',' />
-       <textinfo lcid='1054' ansi='874' ebcdic='20838' mac='10021' oem='874' listsep=',' />
-       <textinfo lcid='31' ansi='1254' ebcdic='20905' mac='10081' oem='857' listsep=';' />
-       <textinfo lcid='1055' ansi='1254' ebcdic='20905' mac='10081' oem='857' listsep=';' />
-       <textinfo lcid='32' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='1056' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='33' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1057' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='34' ansi='1251' ebcdic='500' mac='10017' oem='866' listsep=';' />
-       <textinfo lcid='1058' ansi='1251' ebcdic='500' mac='10017' oem='866' listsep=';' />
-       <textinfo lcid='35' ansi='1251' ebcdic='500' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='1059' ansi='1251' ebcdic='500' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='36' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='1060' ansi='1250' ebcdic='20880' mac='10029' oem='852' listsep=';' />
-       <textinfo lcid='37' ansi='1257' ebcdic='500' mac='10029' oem='775' listsep=';' />
-       <textinfo lcid='1061' ansi='1257' ebcdic='500' mac='10029' oem='775' listsep=';' />
-       <textinfo lcid='38' ansi='1257' ebcdic='500' mac='10029' oem='775' listsep=';' />
-       <textinfo lcid='1062' ansi='1257' ebcdic='500' mac='10029' oem='775' listsep=';' />
-       <textinfo lcid='39' ansi='1257' ebcdic='500' mac='10029' oem='775' listsep=';' />
-       <textinfo lcid='1063' ansi='1257' ebcdic='500' mac='10029' oem='775' listsep=';' />
-       <textinfo lcid='41' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='1065' ansi='1256' ebcdic='20420' mac='10004' oem='720' listsep=';' />
-       <textinfo lcid='42' ansi='1258' ebcdic='500' mac='10000' oem='1258' listsep=',' />
-       <textinfo lcid='1066' ansi='1258' ebcdic='500' mac='10000' oem='1258' listsep=',' />
-       <textinfo lcid='43' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1067' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='44' ansi='1254' ebcdic='20905' mac='10081' oem='857' listsep=';' />
-       <textinfo lcid='1068' ansi='1254' ebcdic='20905' mac='10081' oem='857' listsep=';' />
-       <textinfo lcid='2092' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='45' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1069' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='47' ansi='1251' ebcdic='500' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='1071' ansi='1251' ebcdic='500' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='54' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='1078' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='55' ansi='0' ebcdic='500' mac='2' oem='1' listsep=';' />
-       <textinfo lcid='1079' ansi='0' ebcdic='500' mac='2' oem='1' listsep=';' />
-       <textinfo lcid='56' ansi='1252' ebcdic='20277' mac='10079' oem='850' listsep=';' />
-       <textinfo lcid='1080' ansi='1252' ebcdic='20277' mac='10079' oem='850' listsep=';' />
-       <textinfo lcid='57' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1081' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='62' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='1086' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='2110' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=';' />
-       <textinfo lcid='63' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='1087' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='64' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='1088' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='65' ansi='1252' ebcdic='500' mac='10000' oem='437' listsep=',' />
-       <textinfo lcid='1089' ansi='1252' ebcdic='500' mac='10000' oem='437' listsep=',' />
-       <textinfo lcid='67' ansi='1254' ebcdic='500' mac='10029' oem='857' listsep=';' />
-       <textinfo lcid='1091' ansi='1254' ebcdic='500' mac='10029' oem='857' listsep=';' />
-       <textinfo lcid='2115' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='68' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='1092' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='70' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1094' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='71' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1095' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='73' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1097' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='74' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1098' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='75' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1099' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='78' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1102' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='79' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1103' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='80' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='1104' ansi='1251' ebcdic='20880' mac='10007' oem='866' listsep=';' />
-       <textinfo lcid='86' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='1110' ansi='1252' ebcdic='500' mac='10000' oem='850' listsep=',' />
-       <textinfo lcid='87' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1111' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='90' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='1114' ansi='0' ebcdic='500' mac='2' oem='1' listsep=',' />
-       <textinfo lcid='101' ansi='0' ebcdic='500' mac='2' oem='1' listsep='?' />
-       <textinfo lcid='1125' ansi='0' ebcdic='500' mac='2' oem='1' listsep='?' />
-       <textinfo lcid='127' ansi='1252' ebcdic='37' mac='10000' oem='437' listsep=',' />
-       <textinfo lcid='31770' ansi='1250' ebcdic='500' mac='10082' oem='852' listsep=';' />
-</textinfos>
\ No newline at end of file